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

kOmegaSSTLM - Floating Point exception during ReThetat solving

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 2, 2020, 10:30
Default kOmegaSSTLM - Floating Point exception during ReThetat solving
  #1
New Member
 
Iason Tsiapkinis
Join Date: Jul 2019
Posts: 8
Rep Power: 7
souvlaki41 is on a distinguished road
Hello community,


I'm simulating an airfoil with pimpleFoam and kOmegaSST model.


As a next step I wanted to try out the kOmegaSSTLM model. I copied the boundary files for ReThetaT and gammaInt from the tutorial case T3A and changed the parameters according to my case. I also added solver and schemes for the two transport equations.



Unfortunately I get an Floating point error during the first iteration of ReThetat (see below).


As far as troubleshooting goes I tried different divSchemes and Solvers dor Rethetat and gammaInt, without any success.


According to the error message the problem lies in kOmegaSSTLM.C, specifically in the Fthetat function:
Code:
const volScalarField::Internal Fthetat(this->Fthetat(Us, Omega, nu));

    {
        const volScalarField::Internal t(500*nu/sqr(Us));
        const volScalarField::Internal Pthetat
        (
            alpha()*rho()*(cThetat_/t)*(1 - Fthetat)
        );

        // Transition onset momentum-thickness Reynolds number equation
        tmp<fvScalarMatrix> ReThetatEqn
        (
            fvm::ddt(alpha, rho, ReThetat_)
          + fvm::div(alphaRhoPhi, ReThetat_)
          - fvm::laplacian(alpha*rho*DReThetatEff(), ReThetat_)
         ==
            Pthetat*ReThetat0(Us, dUsds, nu) - fvm::Sp(Pthetat, ReThetat_)
          + fvOptions(alpha, rho, ReThetat_)
        );

        ReThetatEqn.ref().relax();
        fvOptions.constrain(ReThetatEqn.ref());
        solve(ReThetatEqn);
        fvOptions.correct(ReThetat_);
        bound(ReThetat_, 0);
    }

The problematic variables are either sqrt(Us) or t.
I can't find out what t is.

Has anyone had any similar issues? The tutorial case T3A is working as intended and I can't find anything I did different, besides using pimpleFoam instead of simpleFoam.



Code:
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v1612+                                |
|   \\  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : v1612+
Exec   : pimpleFoam
Date   : Apr 02 2020
Time   : 15:14:37
Host   : "c8.hfi.lan"
PID    : 23326
Case   : /home/tsiapkinis/sims191214/sim200214_a174_h10_u10_w20_yplus4_komegaSSTL
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster (fileModificationSkew 10)
allowSystemOperations : Allowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0


PIMPLE: Operating solver in PISO mode

Reading field p

Reading field U

Reading/calculating face flux field phi

Selecting incompressible transport model Newtonian
Selecting turbulence model type RAS
Selecting RAS turbulence model kOmegaSSTLM
Selecting patchDistMethod meshWave
kOmegaSSTCoeffs
{
    alphaK1         0.85;
    alphaK2         1;
    alphaOmega1     0.5;
    alphaOmega2     0.856;
    gamma1          0.555556;
    gamma2          0.44;
    beta1           0.075;
    beta2           0.0828;
    betaStar        0.09;
    a1              0.31;
    b1              1;
    c1              10;
    F3              false;
}

No MRF models present

No finite volume options present


Starting time loop

forces forceCoeffs1:
    Not including porosity effects

forceCoeffs forceCoeffs1:
    Not including porosity effects

Courant Number mean: 0.00154654 max: 0.561152
deltaT = 1.14233e-06
Time = 1.14233e-06

PIMPLE: iteration 1
DILUPBiCG:  Solving for Ux, Initial residual = 1, Final residual = 9.64608e-08, No Iterations 13
DILUPBiCG:  Solving for Uy, Initial residual = 1, Final residual = 3.67252e-08, No Iterations 13
DICPCG:  Solving for p, Initial residual = 1, Final residual = 9.60166e-06, No Iterations 964
DICPCG:  Solving for p, Initial residual = 0.824066, Final residual = 9.74111e-06, No Iterations 804
DICPCG:  Solving for p, Initial residual = 0.0603952, Final residual = 9.87242e-06, No Iterations 748
time step continuity errors : sum local = 3.8042e-11, global = 1.6609e-13, cumulative = 1.6609e-13
DICPCG:  Solving for p, Initial residual = 0.0361928, Final residual = 9.95209e-06, No Iterations 743
DICPCG:  Solving for p, Initial residual = 0.0665034, Final residual = 9.97027e-06, No Iterations 719
DICPCG:  Solving for p, Initial residual = 0.011146, Final residual = 9.9849e-06, No Iterations 619
time step continuity errors : sum local = 3.47666e-11, global = -4.71376e-13, cumulative = -3.05287e-13
#0  Foam::error::printStack(Foam::Ostream&) at ??:?
#1  Foam::sigFpe::sigHandler(int) at ??:?
#2  ? in "/lib64/libc.so.6"
#3  Foam::divide(Foam::Field<double>&, Foam::UList<double> const&, Foam::UList<double> const&) at ??:?
#4  Foam::tmp<Foam::DimensionedField<double, Foam::volMesh> > Foam::operator/<Foam::volMesh>(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::DimensionedField<double, Foam::volMesh> const&) at ??:?
#5  Foam::RASModels::kOmegaSSTLM<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::Fthetat(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::DimensionedField<double, Foam::volMesh> const&) const at ??:?
#6  Foam::RASModels::kOmegaSSTLM<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::correctReThetatGammaInt() at ??:?
#7  Foam::RASModels::kOmegaSSTLM<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::correct() at ??:?
#8  ? at ??:?
#9  __libc_start_main in "/lib64/libc.so.6"
#10  ? at ??:?
Floating point exception (core dumped)
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  plus                                  |
|   \\  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       volScalarField;
    location    "0";
    object      ReThetat;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 0 0 0 0 0 0];

internalField   uniform 200;

boundaryField
{
    #includeEtc "caseDicts/setConstraintTypes"
    inlet
    {
        type            fixedValue;
        value           $internalField;
    }

    outlet
    {
        type            zeroGradient;
    }

    airfoil
    {
        type            zeroGradient;
    }

    topAndBottom
    {
        type            zeroGradient;
    }

    frontAndBack
    {
        type            empty;
    }
}


// ************************************************************************* //
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  plus                                  |
|   \\  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       volScalarField;
    location    "0";
    object      gammaInt;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 0 0 0 0 0 0];

internalField   uniform 1;

boundaryField
{
    #includeEtc "caseDicts/setConstraintTypes"
    inlet
    {
        type            fixedValue;
        value           $internalField;
    }

    outlet
    {
        type            zeroGradient;
    }

    airfoil
    {
        type            zeroGradient;
    }

    topAndBottom
    {
        type            zeroGradient;
    }

    frontAndBack
    {
        type            empty;
    }
}

// ************************************************************************* //
souvlaki41 is offline   Reply With Quote

Old   April 13, 2020, 13:19
Default
  #2
New Member
 
Iason Tsiapkinis
Join Date: Jul 2019
Posts: 8
Rep Power: 7
souvlaki41 is on a distinguished road
I fixed it.

Apparently the kOmegaSSTLM Model has a problem with my grad(U) specification. I had it at cellLimited Gauss linear 1. Gauss linear works just fine.
souvlaki41 is offline   Reply With Quote

Old   April 13, 2020, 16:16
Default
  #3
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 931
Rep Power: 13
HPE is on a distinguished road
Hmm interesting. Any chance for you to provide a minimal working example? Might be useful to report such example as a bug by using one of the links below corresponding to the relevant OpenFOAM version?
HPE is offline   Reply With Quote

Old   April 13, 2020, 16:29
Default
  #4
New Member
 
Iason Tsiapkinis
Join Date: Jul 2019
Posts: 8
Rep Power: 7
souvlaki41 is on a distinguished road
Hey,


you can reproduce the error by running the T3A tutorial case with a different grad scheme:


Code:
gradSchemes
{
    default         Gauss linear;
    grad(U)        cellLimited Gauss linear 1;
}

Shouldn't this normally work? At least for kOmegaSST.
I tried with openfoam5 and v1612+
souvlaki41 is offline   Reply With Quote

Old   April 13, 2020, 16:31
Default
  #5
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 931
Rep Power: 13
HPE is on a distinguished road
I will try it tomorrow or the earliest time possible. Thank you.

>> Shouldn't this normally work?

Yes, it should, I would expect so.
HPE is offline   Reply With Quote

Old   April 14, 2020, 05:15
Default
  #6
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 931
Rep Power: 13
HPE is on a distinguished road
For
- OpenFOAM-v2002 patch=200316, which is the latest development state,
- `tutorials/incompressible/simpleFoam/T3A`,
- `grad` scheme changes above,

the tutorial simulation has been completed.

Might the version update a solution?

FYI: I couldn't find a `T3A` tutorial using `pimpleFoam`.
HPE is offline   Reply With Quote

Old   April 14, 2020, 07:48
Default
  #7
New Member
 
Iason Tsiapkinis
Join Date: Jul 2019
Posts: 8
Rep Power: 7
souvlaki41 is on a distinguished road
Yes this is exactly what I tested. With simpleFoam.
Seems like it was fixed, but I can't see any differences in the source code.

I'll try out the new version, thank you!
souvlaki41 is offline   Reply With Quote

Reply

Tags
floating point exception, komegasst, komegasstlm

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Maximum number of iterations exceeded chtmultiregionsimpleFoam Moncef OpenFOAM Running, Solving & CFD 28 July 13, 2020 15:26
problem with Min/max rho tH3f0rC3 OpenFOAM 8 July 31, 2019 10:48
Suppress twoPhaseEulerFoam energy AlmostSurelyRob OpenFOAM Running, Solving & CFD 33 September 25, 2018 18:45
Unstabil Simulation with chtMultiRegionFoam mbay101 OpenFOAM Running, Solving & CFD 13 December 28, 2013 14:12
Differences between serial and parallel runs carsten OpenFOAM Bugs 11 September 12, 2008 12:16


All times are GMT -4. The time now is 15:48.