CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Running, Solving & CFD

Accessing sauter diameter defined in createFieldsH

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   March 10, 2008, 11:33
Default I have a sauter mean diameter
  #1
New Member
 
Mateusz Slowikowski
Join Date: Mar 2009
Location: Waterloo, Canada
Posts: 12
Rep Power: 7
mateusz_slowikowski is on a distinguished road
I have a sauter mean diameter defined in the createFields.H file:

volScalarField d32_
(
IOobject
(
"d32",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::NO_WRITE
),
phasea->d()*alpha
);

{
volScalarField d32_temp = scalar(0.0)/d32_;
for (int k = 0; k<N_Bins; k++)
{
d32_temp += popBal->binVolume(k) * (*n_[k]) / phasea->d() / (Foam::pow( 2, (N_Bins - scalar(k-1)) / 3));
}
d32_ = scalar(1.0)/d32_temp;
}

and I want to access it in the kinetic theory model:

Foam::kineticTheoryModel::kineticTheoryModel
([...vars passed in...]):
...
da_ ((*(phasea.U())).DB().lookupObject<const> ("d32")),
...

However, I keep on getting these error:

kineticTheoryModel/kineticTheoryModel.C:51: error: ‚class Foam::tmp<foam::geometricfield<foam::tensor<double >, Foam::fvPatchField, Foam::volMesh> >‚ has no member named ‚DB‚
kineticTheoryModel/kineticTheoryModel.C:51: error: expected primary-expression before ‚const‚

I'm not sure how to correctly write the syntax...
mateusz_slowikowski is offline   Reply With Quote

Old   March 10, 2008, 11:40
Default the line da_ (phasea.U().DB
  #2
New Member
 
Mateusz Slowikowski
Join Date: Mar 2009
Location: Waterloo, Canada
Posts: 12
Rep Power: 7
mateusz_slowikowski is on a distinguished road
the line

da_ (phasea.U().DB().lookupObject<const> ("d32")),

solves it
mateusz_slowikowski is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Hydraulic diameter OFXJ FLUENT 1 September 30, 2008 00:56
particle diameter newbie FLUENT 0 June 12, 2008 14:41
udf - droplet diameter bohis FLUENT 3 April 8, 2008 03:38
particle diameter (user defined function) eulerian nasser FLUENT 0 June 18, 2006 03:39
Droplet diameter Habib CD-adapco 1 June 25, 2005 00:18


All times are GMT -4. The time now is 04:03.