CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Oodles and more (http://www.cfd-online.com/Forums/openfoam-solving/59429-oodles-more.html)

r2d2 July 6, 2005 11:14

Hi, I am trying to add an equ
 
Hi,
I am trying to add an equation to oodles and then run it for a "cold jet" simulation. The equation would be for a non-reacting scalar and itīs done in a similar way as "ftEqn.H" of XiFoam. I will breafly describe what Iīve done ("mixf", it`s the name of my variable):
firstly: mixfEqn.H reads:
tmp<fv::convectionscheme<scalar> > mvConvection
(
fv::convectionScheme<scalar>::New
(
mesh,
phi,
mesh.divScheme("div(phi,mixf_2)")
)
);


solve
(
fvm::ddt(mixf)
+ mvConvection->fvmDiv(phi, mixf)
- fvm::laplacian(sgsModel->nuEff(), mixf)
);


I added in "createAverages.H"

volScalarField* mixfMeanPtr;
if (nAveragingStepsFile.good())
{
...
Info<< "Creating field mixfMean\n" << endl;
mixfMeanPtr = new volScalarField
(
IOobject
(
"mixfMean",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);

}
else
{
...
Info<< "Creating field mixfMean\n" << endl;
mixfMeanPtr = new volScalarField
(
IOobject
(
"mixfMean",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
mixf
);
}
....
volScalarField& mixfMean = *mixfMeanPtr;

Then in "calculateAverages.H" I added:

mixfMean = nm1Coeff*mixfMean + nCoeff*mixf;

and in "createFields.H"

Info<< "Reading field mixf\n" << endl;
volScalarField mixf
(
IOobject
(
"mixf",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);

now, at runtime, in the 0 directory I added the "mixf" file with all the definitions of patch values and all that

I run the case in parallel using LAM and it seems to run fine, for as long as I left it running Co did not go over 0.5. The trouble that I have is that at finalising the program I get a message like:

--> FOAM FATAL ERROR : NO_READ specified for read-constructor of object Umean of class IOobject

Function: regIOobject::readStream(const word&)
in file: db/regIOobject/regIOobjectRead.C at line: 53.

FOAM parallel run aborting

...and this Umean can be something else like mixf_0, or pmean or mixfmean ...with the same error. Then, of course (I guess) when I want to reconstructPar the simulation I get (e.g. in the aforementioned error case):
Time = 0.0005

Reconstructing FV fields

Reconstructing volScalarFields

mixf_0
nuSgs
epsilonMean
k
mixfMean


--> FOAM FATAL IO ERROR : cannot open file

file: /mnt/store1/radu/OpenFOAM/radu-1.1/run/oodles2/coldjet/processor9/0.0005/mixfMea n at line 0.

Function: regIOobject::readStream(const word&)
in file: db/regIOobject/regIOobjectRead.C at line: 68.

FOAM exiting

Am I missing something? Help...please!
Cheers,
Radu

henry July 6, 2005 11:21

Because mixf is not part of a
 
Because mixf is not part of a thermodynamic or other coupled system there is no need to use multivariate discretisation for it. So instead of

mvConvection->fvmDiv(phi, mixf)

use

fvm::iv(phi, mixf)

and then you don't need

tmp<fv::convectionscheme<scalar> > mvConvection
(
fv::convectionScheme<scalar>::New
(
mesh,
phi,
mesh.divScheme("div(phi,mixf_2)")
)
);

henry July 6, 2005 11:22

Sorry I mean fvm::div(p
 
Sorry I mean

fvm::div(phi, mixf)

r2d2 July 6, 2005 11:29

Thanks, I will try this and
 
Thanks,
I will try this and see how it goes. Will keep
the fvScheme for it like this, then...

div(phi,mixf) Gauss Gamma201 1;

Radu

r2d2 July 6, 2005 11:43

Did what you said...got the sa
 
Did what you said...got the same, as in now:

--> FOAM FATAL ERROR : NO_READ specified for read-constructor of object R of class IOobject

Function: regIOobject::readStream(const word&)
in file: db/regIOobject/regIOobjectRead.C at line: 53.

FOAM parallel run aborting


I MUST be doing something wrong...

henry July 6, 2005 11:48

To get rid of this error messa
 
To get rid of this error message you must specify MUST_READ rather than NO_READ for your constructors of objects you are reading.

r2d2 July 7, 2005 07:39

Did that in "createAverages.H"
 
Did that in "createAverages.H" and now seems fine. Not that I understand it very well, though: I mean at startup if I donīt have anything I thought I should be putting:
Info<< "Creating field mixfMean\n" << endl;
mixfMeanPtr = new volScalarField
(
IOobject
(
"mixfMean",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
mixf
);

rather than:

Info<< "Creating field mixfMean\n" << endl;
mixfMeanPtr = new volScalarField
(
IOobject
(
"mixfMean",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mixf
);

Thanks anyway.
Radu

henry July 7, 2005 08:02

Yes that is a copy-constructor
 
Yes that is a copy-constructor not a read-constructor so you should use IOobject::NO_READ for it.

ralph September 14, 2005 12:50

I tried version 1.2. I played
 
I tried version 1.2. I played around with "oodles" (problem on 3 processors) and noticed, that it has about 25% less performance, compared to version 1.1.
Is this a common attribute or is this my specific problem?
Iīve seen, that there is some new implementation of "phi"-calculation in "oodles". May this be the cause?

Ralph

cedric_duprat July 23, 2007 04:02

hi, I feel bad to ask you thi
 
hi,
I feel bad to ask you this question with all the explication before but;
I also have a FOAM FATAL ERROR mistake after ...lot's of iterations (which is hurtful):
NO_READ specified for read-constructor of object phi_0.

The problem is that I can't find the phi_0 IOobject in oodles (in createAverages.H) someone know where it is implement ? Or someone can just help me there ?

Thank you,

Cedric

marhamat September 23, 2007 01:54

Hi When i add body force (
 
Hi

When i add body force (F) to oodles and icoFoam solvers it seems that vorticity generation in the test case using with icoFoam is more than oodles.
My test case is a channel that it sides are symmetryplane and inlet velocity is zero.
And F is exponential subject that acts on the geometry center and affect limited domain for several time step.
Any hint?

Thanks in advance
Marhamat


All times are GMT -4. The time now is 01:14.