CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   convergence problems with omega in kOmegaSSTSAS (https://www.cfd-online.com/Forums/openfoam-solving/187947-convergence-problems-omega-komegasstsas.html)

lukas.lebo May 18, 2017 14:19

convergence problems with omega in kOmegaSSTSAS
 
Dear Foamers

I'm trying to do a SAS simulation (LES model = kOmegaSSTSAS) for a flow around a cube. My domain is 100m long x 80m wide x 80m tall. My cube has size 10m x 10m x 10m. I have a shear flow with 4.5m/s on z=10m. I have a blockmesh with more than 4million cells. yPlus values with wallfunctions is in the range of 50-150 though I'm not sure if I can trust this if my omega does not converge. I'm using timesteps of 0.01s.

My Initial and Boundary Conditions are:
k
Code:

internalField  uniform 0.3;

boundaryField
{
    inlet
    {
            type            fixedValue;
        value          uniform 0.1;
    }
    outlet
    {
            type            zeroGradient;
    }
    ground
    {
        type            kqRWallFunction;
        value          uniform 1e-5;
    }
    top
    {
            type            symmetryPlane;
    }
    side1
    {
            type            cyclic;
    }
    side2
    {
        type            cyclic;
    }
    cube
    {
        type            kqRWallFunction;
        value          uniform 1e-5;
    }
}

omega
Code:

internalField  uniform 1;

boundaryField
{
    inlet
    {
            type            fixedValue;
        value          uniform 1;
    }
    outlet
    {
            type            zeroGradient;
    }
    ground
    {
        type            omegaWallFunction;
        value          uniform 10;
    }
    top
    {
            type            symmetryPlane;
    }
    side1
    {
            type            cyclic;
    }
    side2
    {
        type            cyclic;
    }
    cube
    {
        type            omegaWallFunction;
        value          uniform 10;
    }
}

If I set pimpleFoam to piso-mode omega will quickly diverge to infinity. Im using limitedlinear01 1 for both k and omega in fvSchemes.

k and omega will also sometimes go below zero (as low as ~ -10) so that I get bounding k and omega errors.

I tried using the pimple algorithm with up to 50 inner Loops but omega will still not converge. I have set turbOnFinalIterOnly to false so it does indeed solve omega on every iteration.

Anyone knows what else I can try?

Joshua14 May 18, 2017 15:33

lukas.lebo,

A time step of 0.01 might be to large. Take a look at what your Courant number is and if that is blowing up.

Joshua

lukas.lebo May 18, 2017 16:12

My mean Co is below 0.1 and my max Co fluctuates between 0.5 and 2.0 with an average of ~1.3 ...

It'd be hilarious if max Co < 1.0 is required for all cells at all times. (I'm sampling statistics for over 2100s)

I made the same simulation with LES (oneEqEddy) and had no problems whatsoever except I did not resolve the viscous sublayer at small yPlus. Which is the reason I want to compare it to a SAS case with wallfunctions. I'm also doing it with an hilariously fine mesh in LES which will take over 2 months to complete on a HPC cluster (but results will not be available anytime soon ... ).

piu58 May 19, 2017 01:11

Quote:

Originally Posted by lukas.lebo (Post 649455)
My mean Co is below 0.1 and my max Co fluctuates between 0.5 and 2.0 with an average of ~1.3 ...

It'd be hilarious if max Co < 1.0 is required for all cells at all times. (I'm sampling statistics for over 2100s)

Dear Lukas,

I like to mention two things.
1) Usually the maximum Courant number appears in the most critical parts of the geometry. These parts are the starting point of divergence. If the first few round converge, you may set the writeIntercal to timestep and look what happens. This is very instructive.
2) Even at simple geometries a Courant number of 1 or even 0.5 is not advising. It may be that the simulation converges, but the time needed for that may be longer than necessary. Please keep in mind: The pimple method makes a prediction step which needs to be corrected. It is out of sense to have a large prediction step and then need a lot of time for correcting it. I found that Max Courant numbers of 0.1 or even below lead to remarkably shorter wall clock times for simulation.


Even if the simulation converges, there are signs of a too large Courant number. During my simulations I observe dte Co with the help of awk:
Code:

pimpleFoam | awk -f pr.awk
The print pr.awk file contains:
Code:

/Courant/ { mean=$4;max=$6;}
/^Time/ {print "Time:",$3, ", Co(MW, Max):", mean,max}

If you observe time steps which take much longer than the steps before and after, the you observe an accumulation of deviations, which needs a long time to be corrected. Depending on your settings, the max Co number exceeds the setting for this step. If you observe such tings, reduce the maxCo.

Don't be afraid about the wall time for running the simulation: It will be shorter.

If your simulation has stabilized, you may increase the maxCo on the fly. openFoam detects this and uses the new value with the next time step. There was rarely a need for applying this correction, however: What you gain with the time step you loose with the correction.

shock77 November 3, 2020 15:02

Hi,


could you maybe tell me how you defined your SAS coefficients in turbulence properties? I have some weird error with that and cant find the solution: https://www.cfd-online.com/Forums/op...fficients.html


Kind regards,
shock77


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