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/)
-   -   buoyantSimpleFoam and watertank (http://www.cfd-online.com/Forums/openfoam-solving/125718-buoyantsimplefoam-watertank.html)

Tobi October 29, 2013 17:05

buoyantSimpleFoam and watertank
 
3 Attachment(s)
Dear Foamers,

I am working (since 2 weeks) on a very simple simulation.

What I want to simulate:

Something like that: http://www.wiga-energietechnik.de/bi...mage/lwsp2.gif


What I did:

- I meshed the whole geometry with a corse and very fine mesh
- I build polynoms for water thermodynamics (30C-70C)
- I changed the thermodynamics for water
- Simulation is LAMINAR

- Inlet 4e-5 m/s

- At the inlet I have a very simple pipe installation but the solver blow up every time so I just set an Inlet + Outlet (thats all - see pictures).

Now my problem:

Every BC I set make problems.

I am not 100% sure how I should set the p_rgh BC for inlet/outlet/wall.

p is calculated.


For U and T its clear.

The solver is working just for 1 or none iterations.
If I set of the gravity the simulation is working.

It seems that the solver is calculating my water with a compressibility because after the first time step I get extrem huge velocity fields in the big domain.


I tried a lot of BC for U + p_rgh - fixed at the outlet - pressureInletOutletVelocty etc.

Does someone can give me a hint how to set these BC right?

Relaxationfactors are decreased to 0.1.
linearUpwind + limitedLinear schemes are used etc...


Interesting fact:

without gravitation the simulation is working.
With gravitation the mass flux cant be calculated:
Code:

--> FOAM FATAL ERROR:
Continuity error cannot be removed by adjusting the outflow.
Please check the velocity boundary conditions and/or run potentialFoam to initialise the outflow.
Total flux              : 102320
Specified mass inflow  : 0.29563
Specified mass outflow  : 0.151702
Adjustable mass outflow : 0

For gravity I have to set the outlet p_rgh to fixedValue that I can calculate the first timestep but after that the solver blow up again. A picture of p, p_rgh and U is included in the attachment.

The error message:
Code:

Time = 2

DILUPBiCG:  Solving for Ux, Initial residual = 0.733571, Final residual = 0.0031127, No Iterations 7
DILUPBiCG:  Solving for Uy, Initial residual = 0.623405, Final residual = 0.000739902, No Iterations 8
DILUPBiCG:  Solving for Uz, Initial residual = 0.701814, Final residual = 0.0023944, No Iterations 7
DILUPBiCG:  Solving for h, Initial residual = 1, Final residual = 0.00132406, No Iterations 2


--> FOAM FATAL ERROR:
Maximum number of iterations exceeded

    From function thermo<Thermo, Type>::T(scalar f, scalar T0, scalar (thermo<Thermo, Type>::*F)(const scalar) const, scalar (thermo<Thermo, Type>::*dFdT)(const scalar) const, scalar (thermo<Thermo, Type>::*limit)(const scalar) const) const
    in file /home/shorty/OpenFOAM/OpenFOAM-2.2.x/src/thermophysicalModels/specie/lnInclude/thermoI.H at line 76.

FOAM aborting

Compared with the velocity field its clear why its blow up but I can not fix it.


Any suggestions would be appreciated.

Regards Tobi

hanness October 30, 2013 03:55

Hi Tobi,

seems to me as your problem might arise due to the initial conditions of p. In your final solution the p field should be close to the hydrostatic field and p_rgh close to constant. However, if you assume p to be constant in the beginning then you get the p_rgh field shown in your plot which leads to high velocities and possibly even to a crash. The problem is that in the very first step the solver uses the p-field to calculate the p_rgh field although your boundary conditions are set for p_rgh and p is set to calculated. So what you can do is either adapt the solver (which is just a change of one line) or probably a little bit easier use funkySetFields to set the initial pressure field to the hydrostatic pressure.

Hope that helps
Hannes

tomf October 30, 2013 05:41

Hi Tobi,

As a by-pass you could run initially with gravity turned off. Than after say 200 iterations turn gravity on. Unfortunately it is not run-time modifiable so you have to stop (and save) the run, change gravity and rerun from latestTime.

Regards,
Tom

Tobi October 31, 2013 05:24

3 Attachment(s)
Hi,

thanks for your replays.


I tried Toms hints.
The pictures show p, p_rgh and U after 500 iterations.

Then i turned gravity on and the 501 step is shown in the 2nd replay.

@hannes: what lines had to be modified?
@all: could it be possible that my polynomes are wrong?

Tobi October 31, 2013 05:49

3 Attachment(s)
Here are the pictures at 501 iterations.
After that my solver blow up:
Code:

[5]
[5]
[5] --> FOAM FATAL ERROR:
[5] Maximum number of iterations exceeded
[5]
[5]    From function thermo<Thermo, Type>::T(scalar f, scalar T0, scalar (thermo<Thermo, Type>::*F)(const scalar) const, scalar (thermo<Thermo, Type>::*dFdT)(const scalar) const, scalar (thermo<Thermo, Type>::*limit)(const scalar) const) const
[5]    in file /home/shorty/OpenFOAM/OpenFOAM-2.2.x/src/thermophysicalModels/specie/lnInclude/thermoI.H at line 76.
[5]
FOAM parallel run aborting
[5]
[5] #0  Foam::error::printStack(Foam::Ostream&) in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
[5] #1  Foam::error::abort() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
[5] #2  Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::T(double, double, double, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double, double) const, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double, double) const, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double) const) const in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
[5] #3  Foam::heRhoThermo<Foam::rhoThermo, Foam::pureMixture<Foam::polynomialTransport<Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>, 8> > >::calculate() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
[5] #4  Foam::heRhoThermo<Foam::rhoThermo, Foam::pureMixture<Foam::polynomialTransport<Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>, 8> > >::correct() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
[5] #5 
[5]  in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/bin/buoyantSimpleFoam"
[5] #6  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
[5] #7 
[5]  in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/bin/buoyantSimpleFoam"

One hint for p_rgh:

Code:

  p0 = p_rgh + rho*gh
Normally I should have such a pressure field shown in the picture, am I not?
Because my tank is 2m high and the fluid is water (1000kg/m).

So as I see in this formula the higher I get in the tank the lower p0 should be because:

Code:

rho ~ 1000kg/m
g = -9,81
h raises

p0 = p_rgh - 1000* 9,81 * 2

Is that correct?
Therefor p and p_rgh should not be the same?

Tobi October 31, 2013 06:08

Hi all,

just one question. Why is in interFoam the p0 calculation for nonclosedVolumes like that:
Code:

p == p_rgh + rho*gh;
and in buoyant***Foam like that:
Code:

p = p_rgh + rho*gh;
Regards
Tobi

Tobi October 31, 2013 14:56

Hi all,

I made a test with chtMultiRegionSimpleFoam with only one region.
Just a very simple case - box with inlet and outlet at the top of the box.

If I use the thermodynamics out of the liquidHeater tutorial:
Code:

thermoType
{
    type            heRhoThermo;
    mixture        pureMixture;
    transport      const;
    thermo          hConst;
    equationOfState rhoConst;
    specie          specie;
    energy          sensibleEnthalpy;
}

mixture
{
    specie
    {
        nMoles          1;
        molWeight      18;
    }
    equationOfState
    {
        rho            1000;
    }
    thermodynamics
    {
        Cp              4181;
        Hf              0;
    }
    transport
    {
        mu              959e-6;
        Pr              6.62;
    }
}

Its working.
After switching to my own thermodynamic with the polynoms its blow up after the 4th iteration:
Code:

thermoType
{
    type            heRhoThermo;
    mixture        pureMixture;
    transport      polynomial;
    thermo          hPolynomial;
    equationOfState icoPolynomial;
    specie          specie;
    energy          sensibleEnthalpy;
}

mixture
{
    specie
    {
        nMoles          1;
        molWeight      18;
    }

    equationOfState
    {
          rhoCoeffs<8>  (611.705 2.78 -0.005 5.58512e-13 -4.3231e-16 0 0 0);
    }

    thermodynamics
    {
        Hf              0;
        Sf              0;
        CpCoeffs<8>    (5158.69 -6.26 0.01 6.17887e-12 -4.78243e-15 0 0 0);
    }

    transport
    {
        muCoeffs<8>    (0.000292721 -3.33273e-6 1.43625e-8 -2.76923e-11 2.0125e-14 0 0 0);
        kappaCoeffs<8>  (-55.2758 0.683843 -0.00315152 6.47667e-6 -5e-9 0 0 0);
    }
}


Therefor I made a test just with the first coefficient like:
Code:


rhoCoeffs<8>  (1000 0 0 0 0 0 0 0);

for all other polynoms too. But the result is the same - after 3 iterations the solver blow up due to maximum Iteration reached:

Code:

--> FOAM FATAL ERROR:
Maximum number of iterations exceeded

    From function thermo<Thermo, Type>::T(scalar f, scalar T0, scalar (thermo<Thermo, Type>::*F)(const scalar) const, scalar (thermo<Thermo, Type>::*dFdT)(const scalar) const, scalar (thermo<Thermo, Type>::*limit)(const scalar) const) const
    in file /home/shorty/OpenFOAM/OpenFOAM-2.2.x/src/thermophysicalModels/specie/lnInclude/thermoI.H at line 76.

FOAM aborting

#0  Foam::error::printStack(Foam::Ostream&) in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#1  Foam::error::abort() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#2  Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::T(double, double, double, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double, double) const, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double, double) const, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double) const) const in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
#3  Foam::heRhoThermo<Foam::rhoThermo, Foam::pureMixture<Foam::polynomialTransport<Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>, 8> > >::calculate() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
#4  Foam::heRhoThermo<Foam::rhoThermo, Foam::pureMixture<Foam::polynomialTransport<Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>, 8> > >::correct() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
#5 
 in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/bin/chtMultiRegionSimpleFoam"
#6  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#7 
 in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/bin/chtMultiRegionSimpleFoam"
Abgebrochen (Speicherabzug geschrieben)

Any hints?
I am out of mind and have no further ideas at the moment.

Regards
Tobi

Tobi October 31, 2013 15:12

Hi all,

just notice:

I am stupid! :p


All values of mu are wrong. Instead of writing:

503,89e-6

I wrote

0,50389e-6


After changing this, the easy test case is working. Now I am going to check if my bigger project is working too.

Tobi October 31, 2013 17:10

Okay.

I checked it out with the other case.
Without gravity its working (bouyantSimpleFoam and chtMultiRegionSimpleFoam).

But after switching on the gravity its still the same. :(

Regards Tobi

jherb October 31, 2013 21:28

Perhaps your problem is the same as described in this thread:
http://www.cfd-online.com/Forums/ope...roperties.html

You could also try the transient solver (buoyantPimpleFoam)

hanness November 4, 2013 05:03

Dear Tobi,

the pictures you showed match exactly the problem we had. I'm pretty sure that your results will improve when you start the simulations with hydrostatic pressure distribution for p. What happens is when you turn on gravity the pressure field rapidly changes in order to be consistent so that's why you get those strong gradients in the p_rgh field which again results in the high velocities.
If you don't want to set your p field with funkySetFields then you should adapt your solver. Copy the solver and the only thing you have to change in createFields.H is the line reading
Code:

p_rgh = p - rho*gh;
For the buoyantSimpleFoam solver it is line 71
Replace it by solving for p:
Code:

p = p_rgh + rho*gh
This way you initialise using the constant p_rgh field instead of the constant p field which is much closer to the real solution.

Regards
Hannes

Tobi November 4, 2013 07:43

1 Attachment(s)
Hi all,

thanks for the hints but it is still not working.
On my easy case the chtMultiRegionSimpleFoam solver (only with one domain) is working. But the buoyantSimpleFoam is not working. Additionally I tryed the hints hannes said but not with success.


In the attachment you find a picture of the chtMultiSImpleFoam solver and the solution.
I have no further idea at the moment.

For me it seems that the buoyantSimpleFoam is not a good solver for the thing I want to do. Furthermore the chtMultiSimpleFoam solver is not working in my big case too.

Thanks for your help but I think I have to give up on that project.
Maybe "WATER" is not very common for the solvers.

At least I had a look into the cht solver and the createFields.H file.
There is the same calculation as in the buoyantSimpleFoam.
So I have no idea why this solver is working and the other one not :/




Regards Tobi

Tobi November 4, 2013 08:26

Hi all,

now the pressure fields are the same (buoyantSimpleFoam and chtMultiRegionSimpleFoam) .

I had to change the schemes to get the same results :)


Now I am going to check if its working wit a bigger domain.

Tobi November 4, 2013 09:50

Summary with a bigger domain:


- chtMultiRegionSimpleFoam isn 't working anymore
- buoyantSimpleFoam isn 't working anymore
- myBuoyantSimpleFoam with the modification in the createFields.H is working.

Hannes I think the work is done now.
I will check my official geometry now.

I keep you posted.

Tobi November 4, 2013 10:26

Quote:

Originally Posted by hanness (Post 460410)
Dear Tobi,

the pictures you showed match exactly the problem we had. I'm pretty sure that your results will improve when you start the simulations with hydrostatic pressure distribution for p. What happens is when you turn on gravity the pressure field rapidly changes in order to be consistent so that's why you get those strong gradients in the p_rgh field which again results in the high velocities.
If you don't want to set your p field with funkySetFields then you should adapt your solver. Copy the solver and the only thing you have to change in createFields.H is the line reading
Code:

p_rgh = p - rho*gh;
For the buoyantSimpleFoam solver it is line 71
Replace it by solving for p:
Code:

p = p_rgh + rho*gh
This way you initialise using the constant p_rgh field instead of the constant p field which is much closer to the real solution.

Regards
Hannes

Hi Hannes - your hint is working fine :)
Thanks a lot.


Just one question to that.
Why isn 't it implemented as you wrote?

I think there is any reason for that?

Additionally with the PIMPLE algorithm it is not working.
Do you have any experience with that?

Maybe I will initialize it with simple and then switch to pimple.

Regards Tobi

Tobi November 5, 2013 13:25

Hi all,

with the modified buoyantSimpleFoam solver my case is working and the steady state result is very nice.

After initialize this solution with the buoyantPimpleFoam solver I get crazy p_rgh and p fields again :(

hanness November 6, 2013 10:53

Hi Tobi,

I can't really tell you why it is implemented that way, I'm not aware of any restrictions at that point. Maybe the thinking is, that it is easier to initialise a pressure field which is a little more intuitiv then to initialise p_rgh when not starting with constant fields.
However, concerning the problem with buoyantPimpleFoam I could only guess. First of all, one thing that might become neccessary is to increase your writePrecision in controlDict, the standard six (or eight?) digits are by far not sufficient when small fluctuations in p_rgh are concerned, so that might be a reason why a restart might fail. Otherwise it should be possible to run the simulation with the buoyantPimpleFoam starting from a constant field when the same change to the solver is performed (change in createFields.H).
Could you provide some more information on the crash if the above does not help?

Hannes

Tobi November 6, 2013 12:03

3 Attachment(s)
Dear Hannes,

thanks for your replay.

I also tried to start the simulation with the change in the createField.H.
But without success.

Additionally I changed the time precision like you said but the same - crash.
Here is the output:

Code:

Starting time loop

Courant Number mean: 6.92740210013e-09 max: 4.85034908134e-06
deltaT = 1.199999616e-07
Time = 1.2e-07

diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
DILUPBiCG:  Solving for Ux, Initial residual = 2.28465064941e-09, Final residual = 2.28465064941e-09, No Iterations 0
DILUPBiCG:  Solving for Uy, Initial residual = 2.43944451461e-09, Final residual = 2.43944451461e-09, No Iterations 0
DILUPBiCG:  Solving for Uz, Initial residual = 1.09072719922e-09, Final residual = 1.09072719922e-09, No Iterations 0
DILUPBiCG:  Solving for h, Initial residual = 3.35094034737e-06, Final residual = 2.93432135474e-18, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.999966166727, Final residual = 4.61953060743e-07, No Iterations 25
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 7.21330773016e-17, global = 3.97805509428e-17, cumulative = 3.97805509428e-17
ExecutionTime = 42.62 s  ClockTime = 60 s

Courant Number mean: 8.31290630685e-09 max: 5.82512408095e-06
deltaT = 1.43999933184e-07
Time = 2.64e-07

diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
DILUPBiCG:  Solving for Ux, Initial residual = 0.000359951353176, Final residual = 2.99850393754e-17, No Iterations 1
DILUPBiCG:  Solving for Uy, Initial residual = 0.000406515147044, Final residual = 4.7022285039e-17, No Iterations 1
DILUPBiCG:  Solving for Uz, Initial residual = 5.62159242983e-05, Final residual = 3.53128489406e-18, No Iterations 1
DILUPBiCG:  Solving for h, Initial residual = 0.000118849971877, Final residual = 8.30419637485e-17, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.503136149457, Final residual = 2.61630245853e-07, No Iterations 26
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 3.97094383529e-17, global = 1.86616925674e-17, cumulative = 5.84422435102e-17
ExecutionTime = 66.02 s  ClockTime = 89 s

Courant Number mean: 9.97543173077e-09 max: 6.99668194517e-06
deltaT = 1.72799880008e-07
Time = 4.368e-07

diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
DILUPBiCG:  Solving for Ux, Initial residual = 0.00020724814406, Final residual = 5.63890977966e-17, No Iterations 1
DILUPBiCG:  Solving for Uy, Initial residual = 0.000235776423607, Final residual = 4.17515596363e-17, No Iterations 1
DILUPBiCG:  Solving for Uz, Initial residual = 3.23259354164e-05, Final residual = 1.41492437006e-17, No Iterations 1
DILUPBiCG:  Solving for h, Initial residual = 0.999999131419, Final residual = 1.4011399717e-14, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.999982729227, Final residual = 9.81585468245e-07, No Iterations 52
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 1.90312676653e-13, global = -1.04003980939e-14, cumulative = -1.03419558504e-14
ExecutionTime = 100.86 s  ClockTime = 130 s

Courant Number mean: 0.00016710031461 max: 0.221478550247
deltaT = 3.90105209282e-08
Time = 4.7581e-07

diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
DILUPBiCG:  Solving for Ux, Initial residual = 0.0892826131216, Final residual = 3.47960960238e-10, No Iterations 2
DILUPBiCG:  Solving for Uy, Initial residual = 0.0860767448894, Final residual = 2.07507793124e-10, No Iterations 2
DILUPBiCG:  Solving for Uz, Initial residual = 0.00526497170747, Final residual = 5.00604327108e-07, No Iterations 1
DILUPBiCG:  Solving for h, Initial residual = 0.999999999974, Final residual = 1.22827994334e-07, No Iterations 1
#0  Foam::error::printStack(Foam::Ostream&) in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#1  Foam::sigFpe::sigHandler(int) in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#2  in "/lib/x86_64-linux-gnu/libc.so.6"
#3  Foam::GAMGSolver::scale(Foam::Field<double>&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, Foam::Field<double> const&, unsigned char) const in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#4  Foam::GAMGSolver::Vcycle(Foam::PtrList<Foam::lduMatrix::smoother> const&, Foam::Field<double>&, Foam::Field<double> const&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::PtrList<Foam::Field<double> >&, Foam::PtrList<Foam::Field<double> >&, unsigned char) const in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#5  Foam::GAMGSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#6  Foam::fvMatrix<double>::solveSegregated(Foam::dictionary const&) in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfiniteVolume.so"
#7  Foam::fvMatrix<double>::solve(Foam::dictionary const&) in "/home/shorty/OpenFOAM/shorty-2.2.x/platforms/linux64Gcc47DPOpt/bin/myBuoyantPimpleFoam"
#8 
 in "/home/shorty/OpenFOAM/shorty-2.2.x/platforms/linux64Gcc47DPOpt/bin/myBuoyantPimpleFoam"
#9  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#10 
 in "/home/shorty/OpenFOAM/shorty-2.2.x/platforms/linux64Gcc47DPOpt/bin/myBuoyantPimpleFoam"
Gleitkomma-Ausnahme (Speicherabzug geschrieben)

I added a picture of the initial solution.

Regards Tobi

jherb November 6, 2013 12:32

If I read your log file correctly, you don't use the nOuterCorrectors loop. Have you tried nOuterCorrectors > 1 with underrelaxation?

Tobi November 6, 2013 18:34

Hi,

PIMPLE and underrelaxation?
Is underrelaxation not changing the real solution (accuracy in time)?

Well I used nOuterCorrectors > 1 but without success anyway. The error is different. I reach the maximum iteration in the temperature calculation:

Code:

Courant Number mean: 6.92740210013e-09 max: 4.85034908134e-06
deltaT = 1.199999616e-07
Time = 1.2e-07

diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
PIMPLE: iteration 1
DILUPBiCG:  Solving for Ux, Initial residual = 4.38718521517e-07, Final residual = 4.38718521517e-07, No Iterations 0
DILUPBiCG:  Solving for Uy, Initial residual = 4.74501872065e-07, Final residual = 4.74501872065e-07, No Iterations 0
DILUPBiCG:  Solving for Uz, Initial residual = 1.12086811751e-07, Final residual = 1.12086811751e-07, No Iterations 0
DILUPBiCG:  Solving for h, Initial residual = 3.35094034737e-06, Final residual = 2.93432135474e-18, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.997921524511, Final residual = 0.00514407773528, No Iterations 3
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 1.62324329599e-14, global = 2.43019772121e-17, cumulative = 2.43019772121e-17
PIMPLE: iteration 2
DILUPBiCG:  Solving for Ux, Initial residual = 8.49053274605e-06, Final residual = 1.56889161256e-18, No Iterations 1
DILUPBiCG:  Solving for Uy, Initial residual = 9.2706169794e-06, Final residual = 1.7128784731e-18, No Iterations 1
DILUPBiCG:  Solving for Uz, Initial residual = 2.42439406856e-06, Final residual = 6.15472389836e-19, No Iterations 1
DILUPBiCG:  Solving for h, Initial residual = 9.4741734031e-05, Final residual = 4.43794077117e-17, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.19770073244, Final residual = 0.00135321069298, No Iterations 3
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 7.92499613563e-15, global = -2.83812616391e-17, cumulative = -4.07928442704e-18
PIMPLE: iteration 3
DILUPBiCG:  Solving for Ux, Initial residual = 5.83420314596e-06, Final residual = 9.42862909442e-19, No Iterations 1
DILUPBiCG:  Solving for Uy, Initial residual = 6.40245339442e-06, Final residual = 1.01498615559e-18, No Iterations 1
DILUPBiCG:  Solving for Uz, Initial residual = 1.25166849944e-06, Final residual = 2.97094658592e-19, No Iterations 1
DILUPBiCG:  Solving for h, Initial residual = 0.999998344609, Final residual = 1.3555675042e-14, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.999975236161, Final residual = 9.72118583228e-07, No Iterations 53
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 9.88922463867e-14, global = -5.09467127861e-15, cumulative = -5.09875056304e-15
ExecutionTime = 55.77 s  ClockTime = 56 s

Courant Number mean: 8.77396468445e-05 max: 0.116223720973
deltaT = 5.162455599e-08
Time = 1.71625e-07

diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
PIMPLE: iteration 1
DILUPBiCG:  Solving for Ux, Initial residual = 0.157070886327, Final residual = 5.76405070912e-06, No Iterations 1
DILUPBiCG:  Solving for Uy, Initial residual = 0.150534403994, Final residual = 6.62063104725e-06, No Iterations 1
DILUPBiCG:  Solving for Uz, Initial residual = 0.0099884610888, Final residual = 9.50614332261e-07, No Iterations 1
DILUPBiCG:  Solving for h, Initial residual = 0.999999999998, Final residual = 1.22959247587e-07, No Iterations 1
GAMG:  Solving for p_rgh, Initial residual = 0.999999956955, Final residual = 0.00978329204882, No Iterations 132
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = -0.00980931633566, global = 1.15347141494e-05, cumulative = 1.15347141443e-05
PIMPLE: iteration 2
DILUPBiCG:  Solving for Ux, Initial residual = 0.999932390446, Final residual = 0.0990621421236, No Iterations 1
DILUPBiCG:  Solving for Uy, Initial residual = 0.999999756929, Final residual = 0.0923265680759, No Iterations 1
DILUPBiCG:  Solving for Uz, Initial residual = 0.998134013837, Final residual = 0.046339171224, No Iterations 3
DILUPBiCG:  Solving for h, Initial residual = 1, Final residual = 0.0804871336416, No Iterations 25


--> FOAM FATAL ERROR:
Maximum number of iterations exceeded

    From function thermo<Thermo, Type>::T(scalar f, scalar T0, scalar (thermo<Thermo, Type>::*F)(const scalar) const, scalar (thermo<Thermo, Type>::*dFdT)(const scalar) const, scalar (thermo<Thermo, Type>::*limit)(const scalar) const) const
    in file /home/shorty/OpenFOAM/OpenFOAM-2.2.x/src/thermophysicalModels/specie/lnInclude/thermoI.H at line 76.

FOAM aborting

#0  Foam::error::printStack(Foam::Ostream&) in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#1  Foam::error::abort() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libOpenFOAM.so"
#2  Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::T(double, double, double, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double, double) const, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double, double) const, double (Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>::*)(double) const) const in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
#3  Foam::heRhoThermo<Foam::rhoThermo, Foam::pureMixture<Foam::polynomialTransport<Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>, 8> > >::calculate() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
#4  Foam::heRhoThermo<Foam::rhoThermo, Foam::pureMixture<Foam::polynomialTransport<Foam::species::thermo<Foam::hPolynomialThermo<Foam::icoPolynomial<Foam::specie, 8>, 8>, Foam::sensibleEnthalpy>, 8> > >::correct() in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/lib/libfluidThermophysicalModels.so"
#5 
 in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/bin/buoyantPimpleFoam"
#6  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#7 
 in "/home/shorty/OpenFOAM/OpenFOAM-2.2.x/platforms/linux64Gcc47DPOpt/bin/buoyantPimpleFoam"
Abgebrochen (Speicherabzug geschrieben)



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