CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   Can't simulate pressures over 80 bar in sonicFoam (https://www.cfd-online.com/Forums/openfoam/69639-cant-simulate-pressures-over-80-bar-sonicfoam.html)

shangzung October 29, 2009 08:24

Can't simulate pressures over 80 bar in sonicFoam
 
Hello!

(sorry, I meant 900 bar, threshold value is : 89984650Pa)

Somehow with the sonicFoam I can not set the pressure in the setFields over 80.000.000 Pa without the simulation crashing. Is this something of a border?:confused:

Did someone ever simulated pressures around 1kbar?

alberto October 30, 2009 00:18

Quote:

Originally Posted by shangzung (Post 234491)
Hello!

(sorry, I meant 900 bar, threshold value is : 89984650Pa)

Somehow with the sonicFoam I can not set the pressure in the setFields over 80.000.000 Pa without the simulation crashing. Is this something of a border?:confused:

Did someone ever simulated pressures around 1kbar?

Error message?

shangzung October 30, 2009 05:06

It does not simulate even one timestep. I have to add that I modified the sonicFoam.C for the adjustable timestep to work.


I get this error:

Creating turbulence model

Selecting turbulence model type laminar

Starting time loop

Time = 1e-12

Courant Number mean: 0 max: 0
deltaT = 1.2e-12
diagonal: Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
DILUPBiCG: Solving for Ux, Initial residual = 1, Final residual = 1.50669e-16, No Iterations 1
DILUPBiCG: Solving for e, Initial residual = 6.66672e-16, Final residual = 6.66672e-16, No Iterations 0
#0 Foam::error::printStack(Foam::Ostream&) in "/home/simulation/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libOpenFOAM.so"
#1 Foam::sigFpe::sigFpeHandler(int) in "/home/simulation/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libOpenFOAM.so"
#2 ?? in "/lib64/libc.so.6"
#3 Foam::LimitedScheme<double, Foam::limitedLinearLimiter<Foam::NVDTVD>, Foam::limitFuncs::magSqr>::limiter(Foam::Geometric Field<double, Foam::fvPatchField, Foam::volMesh> const&) const in "/home/simulation/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libfiniteVolume.so"
#4 Foam::limitedSurfaceInterpolationScheme<double>::w eights(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&) const in "/home/simulation/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libfiniteVolume.so"
#5 Foam::fv::gaussConvectionScheme<double>::fvmDiv(Fo am::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>&) const in "/home/simulation/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libfiniteVolume.so"
#6 Foam::tmp<Foam::fvMatrix<double> > Foam::fvm::div<double>(Foam::GeometricField<double , Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>&, Foam::word const&) in "/home/simulation/OpenFOAM/OpenFOAM-1.6/applications/bin/linux64GccDPOpt/sonicFoam"
#7 Foam::tmp<Foam::fvMatrix<double> > Foam::fvm::div<double>(Foam::GeometricField<double , Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>&) in "/home/simulation/OpenFOAM/OpenFOAM-1.6/applications/bin/linux64GccDPOpt/sonicFoam"
#8 main in "/home/simulation/OpenFOAM/OpenFOAM-1.6/applications/bin/linux64GccDPOpt/sonicFoam"
#9 __libc_start_main in "/lib64/libc.so.6"
#10 _start at /usr/src/packages/BUILD/glibc-2.9/csu/../sysdeps/x86_64/elf/start.S:116
Gleitkomma-Ausnahme

shangzung October 30, 2009 09:33

I found out that with the solver "rhopSonicFoam" the problem does not occur!

cnsidero October 30, 2009 10:07

Quote:

Originally Posted by shangzung (Post 234606)
It does not simulate even one timestep. I have to add that I modified the sonicFoam.C for the adjustable timestep to work.

Not an answer to your question but I am interested in getting adjustable timestep working in my solver. Would you be willing to share your adjustable timestep modifications to sonicFoam?

shangzung October 30, 2009 10:51

Yeah, here's the code: (I use OF 1.6)

#include "fvCFD.H"
#include "basicPsiThermo.H"
#include "turbulenceModel.H"

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

int main(int argc, char *argv[])
{
#include "setRootCase.H"
#include "createTime.H"
#include "createMesh.H"
#include "createFields.H"
#include "initContinuityErrs.H"
#include "readTimeControls.H"

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

Info<< "\nStarting time loop\n" << endl;

while (runTime.loop())
{
Info<< "Time = " << runTime.timeName() << nl << endl;

#include "readPISOControls.H"
#include "CourantNo.H"
#include "setDeltaT.H"
#include "rhoEqn.H"

#include "UEqn.H"

#include "eEqn.H"


// --- PISO loop

for (int corr=0; corr<nCorr; corr++)
{
#include "pEqn.H"
}

turbulence->correct();

rho = thermo.rho();

runTime.write();

Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
<< nl << endl;
}

Info<< "End\n" << endl;

return 0;
}

cnsidero October 30, 2009 11:21

Oops sorry, I mistook "adjustable timestep" to be "local timstep". I am trying to implement a timestep that varies throughout the field dependent on the local Co.


All times are GMT -4. The time now is 18:13.