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/)
-   -   Oscillating residuals and no convergence! (https://www.cfd-online.com/Forums/openfoam-solving/140658-oscillating-residuals-no-convergence.html)

Sherlock_1812 August 20, 2014 08:35

Oscillating residuals and no convergence!
 
Hi all,

I am facing a problem while using buoyantBoussinesqSimpleFoam to solve a problem in natural convection. My residuals plot is attached herewith. There is huge oscillation in the residuals as the case runs. My last time step residuals are
Code:

DILUPBiCG:  Solving for Ux, Initial residual = 1.13167e-09, Final residual = 1.13167e-09, No Iterations 0
DILUPBiCG:  Solving for Uy, Initial residual = 3.7544e-10, Final residual = 3.7544e-10, No Iterations 0
DILUPBiCG:  Solving for Uz, Initial residual = 0.000492656, Final residual = 4.17232e-06, No Iterations 1
DILUPBiCG:  Solving for T, Initial residual = 9.9924e-06, Final residual = 9.9924e-06, No Iterations 0
DICPCG:  Solving for p_rgh, Initial residual = 1.05994e-08, Final residual = 7.33015e-09, No Iterations 1
time step continuity errors : sum local = 3.02676e-11, global = 9.96442e-20, cumulative = -1.45381e-16

However my fvSolution file reads as follows,

Code:

solvers
{
    p_rgh
    {
        solver          PCG;
        preconditioner  DIC;
        tolerance      1e-08;
        relTol          0.01;
    }

    "(U|T|k|epsilon|R)"
    {
        solver          PBiCG;
        preconditioner  DILU;
        tolerance      1e-05;
        relTol          0.1;
    }
}

SIMPLE
{
    nNonOrthogonalCorrectors 0;
    pRefCell        0;
    pRefValue      0;

    residualControl
    {
        p_rgh          1e-4;
        U              1e-5;
        T              1e-2;
    }

.
Q: Why hasn't the solution converged even though the SIMPLE tolerances have been met?

Any help would be great!

Sherlock_1812 August 20, 2014 08:37

1 Attachment(s)
Apologies.

The snapshot of the Residuals.

RodriguezFatz August 20, 2014 09:14

Hi.
Well, eventually the residuals look fine, after about 17000 iterations. The noise looks like numerical noise to me.
Why do they jump like that in the beginning? Is there any sort of additional regulation (flux, ...) in you setup?

Sherlock_1812 August 20, 2014 09:19

Hi,

There is nothing in the setup that would cause that jump, so even I'm assuming that it has to be numerical. I'm just not able to pinpoint the reason which is why I posted my fvSolution file to see if there needs to be any change made.

UPDATE: I have tried increasing the pseudo time step in the controlDict. There are no oscillation if I do that but the solution diverges after a few iterations. Again, have no idea why.

I'm using OF 2.2.2, by the way

RodriguezFatz August 20, 2014 09:25

1) Did you try to start with a better initialization? Such as one made by potentialFoam?
2) If you increase the pseudo time step you will of course get divergence at some point. It's like increasing the under-relaxation. You need to decrease the time step if you encounter numerical problems.

Sherlock_1812 August 20, 2014 09:33

1) Could you explain 'better initialisation'. Its primarily buoyancy driven flow without any initial velocity field. What should I expect the potentialFoam run to give me?

2) My bad. I'll correct that and re run.

Sorry if the questions are too novice-llike

RodriguezFatz August 20, 2014 09:37

1) But you run for steady-state. If your initial values are closer to the final steady-state you can expect better convergence. There is no reason to initialize with velocity=0. For a complete buoyancy driven flow (without inlet and outlet) I don't know how to find a good initialization...

Sherlock_1812 August 20, 2014 09:39

Thank you for your inputs. :) I'll give a very small uniform velocity field initially and see if the solution readjusts and converges.

Will get back with results.


All times are GMT -4. The time now is 04:51.