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

p_rgh diverges and is calculated multiple times?

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 8, 2021, 06:10
Default p_rgh diverges and is calculated multiple times?
  #1
Member
 
Claudia
Join Date: Mar 2021
Posts: 43
Rep Power: 5
Clau.77 is on a distinguished road
Hey guys!


I am trying to simulate an air flow around a Geometry. I have attached a foto of the geometry as well as a close up of the mesh. I need to use chtMultiRegion because later on I will study the heat transfer. Right now i am using k-epsilon turbulence and steadyState. The objective is to use this solution as a start for a transient simulation with heat exchange.



Problem: My solution does not converge, especially p_rgh. I tried playing around with the mesh, the relaxation factor, the nonOrthogonalCorrectors... but everything is just making it worse.


Question:

1. Is it a problem with my mesh? I have some non-orthogonal an skew faces.

2. How can I improve my simulation?

3. In my log file you can see that OF calculates p_rgh multiple times during 1 timestep. Is that an error?




the fvSolution file for the air:

Code:
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system/Luft";
    object      fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solvers
{
  "h.*"
    {
      solver           PBiCGStab;
      preconditioner   DILU;
      tolerance        1e-7;
      relTol           1e-7;
      minIter          5;
      maxIter          50;
    }
  "hFinal.*"
    {
      $h;
    }
  "e.*"
    {
      $h;
    }
  "eFinal.*"
    {
      $h;
    }

    rho
    {
        solver           GAMG;
        smoother         GaussSeidel;
        tolerance        0.0001;
        relTol           0.0001;
    // maxIter         10;
    }

    rhoFinal
    {
        $rho;
    relTol           0;
    // maxIter       20;
    }

    p_rgh
    {
        solver           GAMG;
        smoother         GaussSeidel;
        tolerance        0.0001;
        relTol           0.0001;
    maxIter         20;
    }

    p_rghFinal
    {
        $p_rgh;
        tolerance        0.0001;
    relTol         0.0001; 
    }


    "(U|k|epsilon|omega|R).*"
    {
        solver           PBiCGStab;
        preconditioner   DILU;
        tolerance        0.0001;
        relTol           0.0001;
    }

    "(U|k|epsilon|omega|R)Final.*"
    {
        $U;
    tolerance     0.0001;
        relTol           0;
    //    maxIter   20;
    }
}

PIMPLE
{
    momentumPredictor   yes;
    nOuterCorrectors    1;
    nCorrectors         2;
    nNonOrthogonalCorrectors 0;//1 leads to extreme fluctuation of p_rgh;
    
    outerCorrectorResidualControl
      {
    "(U|k|epsilon|omega|p_rgh).*"
      {
        tolerance   1e-4;
        relTol      0;
      }
    "h.*"
      {
        tolerance   1e-7;
        relTol      0;
      }
    "e.*"
      {
        tolerance   1e-7;
        relTol      0;
      }
      }

}

relaxationFactors
{
    fields
    {
      p_rgh              1;
      p_rghFinal        1;
      rho               1;
      rhoFinal          1;

    }       

 equations
    {
      h                0.001;
      e                0.001;
      hFinal            0.001;
      eFinal            0.001;
      U                 0.1;
      UFinal            0.1;
      k             0.1;
      omega        0.1;
      epsilon        0.1;
      kFinal            0.1;
      epsilonFinal      0.1;
      omegaFinal        0.1; 
    }
}
Code:
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system/Luft";
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

ddtSchemes
{
    default         steadyState;//CrankNicolson 0.9;
}

gradSchemes
{
    default         Gauss linear;
}

divSchemes
{
    default         none;

    div(phi,U)      bounded Gauss upwind;  //bounded weg für transient?
    div(phi,K)      bounded Gauss upwind;;
    div(phi,h)      bounded Gauss upwind;
    div(phi,e)      bounded Gauss upwind;
    div(phi,k)      bounded Gauss upwind;
    div(phi,epsilon)    bounded Gauss upwind;
    div(phi,omega)  bounded Gauss upwind;
    div(phi,R)      bounded Gauss upwind;
    div(phi,K)      bounded Gauss linear;
    div(phi,Ekp)    bounded Gauss linear;
    div(R)          Gauss linear;
    div(U)          Gauss linear;
    div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear;
}

laplacianSchemes
{
    default         Gauss linear uncorrected;
}

interpolationSchemes
{
    default         linear;
}

snGradSchemes
{
    default         corrected;
}

wallDist
{
method        meshWave;
}
i also attached the first steps of my log file.


Can someone give me advice?
Attached Images
File Type: png 2d.PNG (113.0 KB, 21 views)
File Type: jpg 2d_Mesh.jpg (54.8 KB, 29 views)
Attached Files
File Type: txt log_chtMRF.txt (177.9 KB, 3 views)
Clau.77 is offline   Reply With Quote

Old   July 7, 2021, 01:39
Default
  #2
New Member
 
Hosam Alrefaie
Join Date: Jul 2021
Posts: 24
Rep Power: 4
HosamAlrefaie is on a distinguished road
I have the same problem with p_rgh, it has high residuals and too many iterations each time.

I am using fixedFluxPressure BC for the inner pipe walls.
HosamAlrefaie is offline   Reply With Quote

Old   July 7, 2021, 02:13
Default
  #3
Senior Member
 
piu58's Avatar
 
Uwe Pilz
Join Date: Feb 2017
Location: Leipzig, Germany
Posts: 744
Rep Power: 15
piu58 is on a distinguished road
I recommend using relaxationFactors in fvSolution. You should at least some kind of result then.

I don't like your mesh, I found the steps of refinement to steep. May be a coarser mesh is at least a better starting point. But this is hard to say without a result.

I recommend simplifying your geometry and investigating the "bump" and the "pits" isolated, at least at the beginning.
__________________
Uwe Pilz
--
Die der Hauptbewegung überlagerte Schwankungsbewegung ist in ihren Einzelheiten so hoffnungslos kompliziert, daß ihre theoretische Berechnung aussichtslos erscheint. (Hermann Schlichting, 1950)
piu58 is offline   Reply With Quote

Reply

Tags
chtmultiregion, chtmultiregionfoam, p_rgh devergence

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



All times are GMT -4. The time now is 01:58.