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

Foam::error::printStack(Foam::Ostream&) in compressibleInterFoam

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 22, 2020, 13:42
Question Foam::error::printStack(Foam::Ostream&) in compressibleInterFoam
  #1
Member
 
Join Date: Apr 2018
Location: UK
Posts: 78
Rep Power: 8
JM27 is on a distinguished road
Hi,

I am running simulations using compressibleInterFoam but I have been stuck due to a floating point exception error.

The stack trace is as follows:

Code:
Interface Courant Number mean: 1.07354720337e-08 max: 0.0762385595518
deltaT = 5.09274326188e-12
Time = 0.00019657958

PIMPLE: iteration 1
DILUPBiCG:  Solving for alpha.water, Initial residual = 1.57022572868e-08, Final residual = 1.53046969964e-14, No Iterations 1
Phase-1 volume fraction = 0.998899400376  Min(alpha.water) = -4.32331998401e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899400375  Min(alpha.water) = -2.31591150708e-25  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 1.56080207899e-08, Final residual = 1.53223659545e-14, No Iterations 1
Phase-1 volume fraction = 0.998899400761  Min(alpha.water) = -4.32331735935e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899400761  Min(alpha.water) = -1.18574669163e-22  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 1.55715049515e-08, Final residual = 1.53509338253e-14, No Iterations 1
Phase-1 volume fraction = 0.998899401104  Min(alpha.water) = -4.32331473467e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899401103  Min(alpha.water) = -5.92873345813e-23  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 1.55559393032e-08, Final residual = 1.54356211234e-14, No Iterations 1
Phase-1 volume fraction = 0.998899401405  Min(alpha.water) = -4.32331210997e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899401404  Min(alpha.water) = -1.18574669163e-22  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 1.55505880016e-08, Final residual = 1.57701687095e-14, No Iterations 1
Phase-1 volume fraction = 0.998899401688  Min(alpha.water) = -4.32330948523e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899401688  Min(alpha.water) = -9.26364602833e-25  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for Ux, Initial residual = 4.9590779237e-06, Final residual = 3.93619097054e-14, No Iterations 2
DILUPBiCG:  Solving for Uy, Initial residual = 7.40961949378e-07, Final residual = 1.61760127926e-18, No Iterations 3
DILUPBiCG:  Solving for Uz, Initial residual = 2.44516019475e-06, Final residual = 3.54996480259e-14, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 6.32516078894e-05, Final residual = 1.2397304882e-21, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 6.24088501842e-06, Final residual = 7.22027026281e-21, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.000192444189005, Final residual = 6.30284577604e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.000192311595257, Final residual = 3.90252460768e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.00019231352606, Final residual = 3.19250798821e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.000192310954327, Final residual = 2.62862750611e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.00019230874282, Final residual = 2.16065354699e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.000192306816299, Final residual = 1.78044019533e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.000192323081209, Final residual = 1.56580937806e-22, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 0.000192148768483, Final residual = 1.36910248252e-22, No Iterations 1
ExecutionTime = 134163.87 s


fieldMinMax MinMaxU write:
    min(mag(U)) = 0 in cell 17 at location (0.000553379420937 2.07614477632e-22 -0.000375) on processor 0
    max(mag(U)) = 11906.8052657 in cell 118 at location (2.34151926933e-06 1.02232939138e-07 -0.000360966967607) on processor 30

fieldMinMax MinMaxT write:
    min(T) = 293.15 in cell 0 at location (0.000553379420937 -4.04651301151e-23 -0.000373733090168) on processor 0
    max(T) = 293.15 in cell 0 at location (0.000553379420937 -4.04651301151e-23 -0.000373733090168) on processor 0

fieldMinMax MinMaxp write:
    min(p) = 2000 in cell 69 at location (1.04067523081e-06 -1.17266319025e-25 -0.000373407900086) on processor 30
    max(p) = 190085292819 in cell 199 at location (3.95456587709e-06 1.55874087627e-23 -0.000354080798858) on processor 30

fieldMinMax MinMaxp_rgh write:
    min(p_rgh) = 2000 in cell 69 at location (1.04067523081e-06 -1.17266319025e-25 -0.000373407900086) on processor 30
    max(p_rgh) = 190085292819 in cell 199 at location (3.95456587709e-06 1.55874087627e-23 -0.000354080798858) on processor 30

fieldMinMax MinMaxrho write:
    min(rho) = 0.66748147674 in cell 1540 at location (2.73251582034e-05 -1.44129563904e-22 -0.000344079190786) on processor 30
    max(rho) = 24649.2436601 in cell 22 at location (1.04067523081e-06 -1.43602670533e-25 -0.000356666922911) on processor 30

 coded functionObject bubbleRadius compiled successfully and computed.
 Now writing momentary bubble radius, Rb, and sumNumerator
coded functionObject rhoBubble compiled successfully and bubbleMass computed.
 Writing bubble interior properties to /postProcessing/bubbleMassPres
Expression bubbleCentreZ :  min=-0.000212662815053 max=-0.000212662815053 sum=-408.312604901 average=-0.000212662815053
Expression bubbleCentreX :  min=0.000164893077618 max=0.000164893077618 sum=316.594709026 average=0.000164893077618
Expression bubbleMassSwak :  min=-3.2892505305e-35 max=4.51728209988e-08 sum=3.16875222503e-06 average=1.65039178387e-12
Expression xDiameter :  min=2.31693360292e-08 max=0.00072521198297 average=0.000106190662097 sum=1.31304753683
Expression zDiameter :  min=-0.000372242671923 max=0.000374991094654 average=-9.56219286259e-05 sum=-1.18236514746
Courant Number mean: 3.75575908e-06 max: 0.100495704098
Interface Courant Number mean: 1.06628675356e-08 max: 0.0757328727341
deltaT = 5.06761513237e-12
Time = 0.00019657958

PIMPLE: iteration 1
DILUPBiCG:  Solving for alpha.water, Initial residual = 4.66204797253e-06, Final residual = 4.48294660333e-14, No Iterations 1
Phase-1 volume fraction = 0.998899402628  Min(alpha.water) = -4.32330687313e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899402628  Min(alpha.water) = -2.88060569595e-26  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 4.66161492462e-06, Final residual = 2.75752343725e-14, No Iterations 1
Phase-1 volume fraction = 0.998899402955  Min(alpha.water) = -4.323304261e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899402955  Min(alpha.water) = -1.15224227838e-25  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.89548147184e-08, Final residual = 1.6074677542e-14, No Iterations 1
Phase-1 volume fraction = 0.998899403204  Min(alpha.water) = -4.32330164884e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899403204  Min(alpha.water) = -5.7612113919e-26  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.2825035081e-08, Final residual = 7.74834739591e-14, No Iterations 1
Phase-1 volume fraction = 0.998899403446  Min(alpha.water) = -4.32329903666e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899403446  Min(alpha.water) = -2.88060569595e-26  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 8.93547408991e-09, Final residual = 6.5827819204e-20, No Iterations 2
Phase-1 volume fraction = 0.998899403688  Min(alpha.water) = -4.32329642445e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899403688  Min(alpha.water) = -5.8994804653e-23  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for Ux, Initial residual = 4.79676514434e-06, Final residual = 2.26382423253e-14, No Iterations 2
DILUPBiCG:  Solving for Uy, Initial residual = 7.21602919534e-07, Final residual = 5.72281628261e-15, No Iterations 2
DILUPBiCG:  Solving for Uz, Initial residual = 2.17246028357e-06, Final residual = 1.46764683663e-14, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 7.7064164104e-06, Final residual = 1.10494698183e-21, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 5.22456340119e-06, Final residual = 1.62360397422e-21, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 3.55769508126e-05, Final residual = 7.91926415067e-20, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 6.46133410276e-05, Final residual = 3.51346513638e-24, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 8.43358014277e-05, Final residual = 6.08666791173e-23, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 8.45166032684e-05, Final residual = 1.102075708e-21, No Iterations 3
DICPBiCGStab:  Solving for p_rgh, Initial residual = 5.70403734164e-05, Final residual = 8.00584925252e-20, No Iterations 2
DICPBiCGStab:  Solving for p_rgh, Initial residual = 5.07722276351e-05, Final residual = 1.81105512706e-21, No Iterations 4
DICPBiCGStab:  Solving for p_rgh, Initial residual = 4.94621136394e-05, Final residual = 3.83717046428e-21, No Iterations 6
DICPBiCGStab:  Solving for p_rgh, Initial residual = 5.02673842218e-05, Final residual = 3.127065549e-21, No Iterations 7
ExecutionTime = 134165.42 s


fieldMinMax MinMaxU write:
    min(mag(U)) = 0 in cell 17 at location (0.000553379420937 2.07614477632e-22 -0.000375) on processor 0
    max(mag(U)) = 2.66764171341e+13 in cell 107 at location (2.42824220523e-06 -1.69416226575e-24 -0.000352169061949) on processor 30

fieldMinMax MinMaxT write:
    min(T) = 293.15 in cell 0 at location (0.000553379420937 -4.04651301151e-23 -0.000373733090168) on processor 0
    max(T) = 293.15 in cell 0 at location (0.000553379420937 -4.04651301151e-23 -0.000373733090168) on processor 0

fieldMinMax MinMaxp write:
    min(p) = 2000 in cell 11 at location (1.04067523081e-06 -3.28773807419e-25 -0.00034538350307) on processor 30
    max(p) = 1.77608566644e+21 in cell 106 at location (2.42824220523e-06 3.8181859444e-24 -0.00035115206386) on processor 30

fieldMinMax MinMaxp_rgh write:
    min(p_rgh) = 2000 in cell 11 at location (1.04067523081e-06 -3.28773807419e-25 -0.00034538350307) on processor 30
    max(p_rgh) = 1.77608566644e+21 in cell 106 at location (2.42824220523e-06 3.8181859444e-24 -0.00035115206386) on processor 30

fieldMinMax MinMaxrho write:
    min(rho) = 0.667591267263 in cell 1540 at location (2.73251582034e-05 -1.44129563904e-22 -0.000344079190786) on processor 30
    max(rho) = 7.66509950917e+14 in cell 106 at location (2.42824220523e-06 3.8181859444e-24 -0.00035115206386) on processor 30

 coded functionObject bubbleRadius compiled successfully and computed.
 Now writing momentary bubble radius, Rb, and sumNumerator
coded functionObject rhoBubble compiled successfully and bubbleMass computed.
 Writing bubble interior properties to /postProcessing/bubbleMassPres
Expression bubbleCentreZ :  min=-0.000212662683396 max=-0.000212662683396 sum=-408.312352121 average=-0.000212662683396
Expression bubbleCentreX :  min=0.000164893229862 max=0.000164893229862 sum=316.595001336 average=0.000164893229862
Expression bubbleMassSwak :  min=-3.55392170227e-33 max=34559.2309537 sum=45667.8261212 average=0.0237853261048
Expression xDiameter :  min=2.43568952916e-08 max=0.000725211980275 average=0.000105646462622 sum=1.31318553039
Expression zDiameter :  min=-0.000372243427136 max=0.000374991094667 average=-9.68560805698e-05 sum=-1.20392108148
Courant Number mean: 0.541682802791 max: 550388285.949
Interface Courant Number mean: 0.263790093629 max: 411295022.447
deltaT = 9.20734554449e-22
Time = 0.00019657958

PIMPLE: iteration 1
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.53318750558e-09, Final residual = 1.64733804029e-14, No Iterations 1
Phase-1 volume fraction = 0.998899403788  Min(alpha.water) = -4.32329642445e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899403788  Min(alpha.water) = -1.07187609473e-32  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.51188012698e-09, Final residual = 1.57331855556e-14, No Iterations 1
Phase-1 volume fraction = 0.998899403884  Min(alpha.water) = -4.32329642445e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899403884  Min(alpha.water) = -1.04675399876e-35  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.49201029634e-09, Final residual = 1.47232669396e-14, No Iterations 1
Phase-1 volume fraction = 0.998899403976  Min(alpha.water) = -4.32329642445e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899403976  Min(alpha.water) = -1.07187609473e-32  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.47329831421e-09, Final residual = 1.32946136987e-14, No Iterations 1
Phase-1 volume fraction = 0.998899404062  Min(alpha.water) = -4.32329642445e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899404062  Min(alpha.water) = -8.3740319901e-35  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for alpha.water, Initial residual = 3.4557342653e-09, Final residual = 1.12128646818e-14, No Iterations 1
Phase-1 volume fraction = 0.998899404138  Min(alpha.water) = -4.32329642445e-44  Max(alpha.water) = 1.00000000001
MULES: Correcting alpha.water
Phase-1 volume fraction = 0.998899404138  Min(alpha.water) = -1.07187609473e-32  Max(alpha.water) = 1.00000000001
DILUPBiCG:  Solving for Ux, Initial residual = 0.654607631324, Final residual = 7.88933757693e-14, No Iterations 2
DILUPBiCG:  Solving for Uy, Initial residual = 0.943150657799, Final residual = 2.81250904466e-16, No Iterations 2
DILUPBiCG:  Solving for Uz, Initial residual = 0.684412775126, Final residual = 8.28003892286e-21, No Iterations 3
DICPBiCGStab:  Solving for p_rgh, Initial residual = 8.86903116418e-06, Final residual = 5.63820936862e-23, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 1.10839503706e-05, Final residual = 5.36653804837e-23, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 6.36755150348e-07, Final residual = 9.63137150777e-39, No Iterations 1
DICPBiCGStab:  Solving for p_rgh, Initial residual = 1.46453301358e-11, Final residual = 7.05461921279e-31, No Iterations 1
[30] #0  Foam::error::printStack(Foam::Ostream&) at ??:?
[30] #1  Foam::sigFpe::sigHandler(int) at ??:?
[30] #2  ? in "/lib64/libpthread.so.0"
[30] #3  Foam::divide(Foam::Field<double>&, Foam::UList<double> const&, Foam::UList<double> const&) at ??:?
[30] #4  Foam::tmp<Foam::GeometricField<double, Foam::volMesh> > Foam::operator/<Foam::fvPatchField, Foam::volMesh>(Foam::tmp<Foam::GeometricField<double, Foam::volMesh> > const&, Foam::GeometricField<double, Foam::volMesh> const&) at ??:?
[30] #5  ? at ??:?
[30] #6  __libc_start_main in "/lib64/libc.so.6"
[30] #7  ? at ??:?
srun: error: cnode80: task 30: Floating point exception (core dumped)
As one can see from the max values of pressure and velocity these are extremely high, I would say unphysical ! So it is important to point out that this error is observed when using upwind for the convection of velocity, i.e. div(rhoPhi,U). That said, I am aware that the velocity can still go unbounded even when using upwind (interested readers, OF Tips & Tricks slides). The problem is that if the simulation does not work with upwind, it's likely there are problems elsewhere in the setup, I just haven't been able to find where for a very very long time

I have tried changing several things: made my mesh uniform, played around with schemes and solver settings, set a smaller deltaT, and I'm now changing some BCs. And yes, I've checked my mesh using checkMesh -allGeometry -allTopology and set my fvSchemes accordingly (at least, to the best of my knowledge).

However the most perplexing thing is that my results look perfectly OK until the point when the simulation crashes, and surprisingly, in excellent agreement with experiments. I doubt this would be the case if the boundary conditions were wrong?

Someone please help me figure out what is causing this error or at least point me in the right direction. I've been stuck on this for weeks and really running out of ideas of what could be wrong and things to try.

I'm happy to provide a minimal working example to anyone who is interested in this issue.
JM27 is offline   Reply With Quote

Old   May 25, 2020, 11:52
Unhappy
  #2
Member
 
Join Date: Apr 2018
Location: UK
Posts: 78
Rep Power: 8
JM27 is on a distinguished road
No one is interested in this problem ?

I feel like I'm going round in circles on this one...
JM27 is offline   Reply With Quote

Old   May 26, 2020, 08:13
Thumbs down to continue this monologue
  #3
Member
 
Join Date: Apr 2018
Location: UK
Posts: 78
Rep Power: 8
JM27 is on a distinguished road
To continue this monologue, I now think that the problem might be arising from the BCs for p and U on my atmospheric outlet. As stated in the user guide,
Quote:
a combination of totalPressure BC for pressure and pressureInletOutletVelocity BC could be the cause instabilities when the velocity increases rapidly.
To give a bit more background on my simulation, I am modelling a bubble confined between two parallel plates. The setup is axisymmetric with the bubble initially placed at the axis of symmetry.

The max velocity and pressure in the domain start to increase rapidly when the jetting starts, so this seems to suggest that the problem is in fact arising from the BCs at the outlet. Furthermore, the stack-trace error refers to fvPatchField therefore indicating something is wrong with one of the boundaries (please correct me if I'm wrong).
I am using adaptive time-stepping, so as the velocity increases, the deltaT is decreased to extremely small values until the simulation finally crashes.

I have tried using fixedValue for p with zeroGradient at the outlet for U but the error still occurs around the same time.

Can someone please suggest any suitable BCs for this problem?

Here is a summary of my current BC setup from patchSummary:

Code:
Create time

Create mesh for time = 0

Time = 0

Valid fields:
    volScalarField alpha.water
    volVectorField U
    volScalarField p_rgh
    volScalarField p
    volScalarField T

group : wall
    scalar alpha.water zeroGradient
    scalar p_rgh fixedFluxPressure
    scalar p calculated
    scalar T zeroGradient
    vector U noSlip

patch : right // outlet
    scalar alpha.water inletOutlet
    scalar p_rgh totalPressure
    scalar p calculated
    scalar T inletOutlet
    vector U pressureInletOutletVelocity

empty : left
    scalar alpha.water empty
    scalar p_rgh empty
    scalar p empty
    scalar T empty
    vector U empty

group : wedge
    scalar alpha.water wedge
    scalar p_rgh wedge
    scalar p wedge
    scalar T wedge
    vector U wedge

End
JM27 is offline   Reply With Quote

Reply

Tags
compressibleinterfoam, floating point exception, stack trace


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 Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 00:02.