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

SimpleFoam convergence problem with really simple simulation

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

Reply
 
LinkBack Thread Tools Display Modes
Old   November 6, 2013, 02:04
Default SimpleFoam convergence problem with really simple simulation
  #1
Member
 
India
Join Date: Oct 2012
Posts: 84
Rep Power: 4
mayank.dce2k7 is on a distinguished road
Hi Foamers,

I am facing SimpleFoam convergence problem with a really basic simulation i.e steady state flow simulation in a single bifurcation tube by specifying fully developed velocity profile at inlet(using swak4Foam toolbox).

After digging through various threads related to convergence problem, I tried changing divergence schemes, played with relaxation factors and tried grid refinement but nothing helped. Situation became so bad the case is not converging using first order upwind scheme let one second order schemes. Below are some details of my case set up:

1.) Mesh is generated on ANSYS ICEM using tetrahedral and prism elements. My model contains about 0.6 million elements.

2.) checkMesh result:

Create time

Create polyMesh for time = 0

Time = 0

Mesh stats
points: 195781
faces: 1354300
internal faces: 1310124
cells: 603415
boundary patches: 4
point zones: 0
face zones: 1
cell zones: 1

Overall number of cells of each type:
hexahedra: 0
prisms: 250764
wedges: 0
pyramids: 0
tet wedges: 0
tetrahedra: 352651
polyhedra: 0

Checking topology...
Boundary definition OK.
Cell to face addressing OK.
Point usage OK.
Upper triangular ordering OK.
Face vertices OK.
Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces ...
Patch Faces Points Surface topology
WALL 41794 20988 ok (non-closed singly connected)
INLET 1047 787 ok (non-closed singly connected)
OUTLET1 666 523 ok (non-closed singly connected)
OUTLET2 669 528 ok (non-closed singly connected)

Checking geometry...
Overall domain bounding box (-0.108855 -0.161689 -0.01905) (0.108855 0.127 0.01905)
Mesh (non-empty, non-wedge) directions (1 1 1)
Mesh (non-empty) directions (1 1 1)
Boundary openness (6.33376e-17 2.25628e-17 -1.46543e-16) OK.
Max cell openness = 3.10378e-16 OK.
Max aspect ratio = 18.7479 OK.
Minumum face area = 1.85691e-07. Maximum face area = 4.16397e-06. Face area magnitudes OK.
Min volume = 1.38121e-11. Max volume = 2.46223e-09. Total volume = 0.000347757. Cell volumes OK.
Mesh non-orthogonality Max: 76.7538 average: 13.2348
*Number of severely non-orthogonal faces: 1.
Non-orthogonality check OK.
<<Writing 1 non-orthogonal faces to set nonOrthoFaces
Face pyramids OK.
Max skewness = 2.96438 OK.
Coupled point location match (average 0) OK.

Mesh OK.

End

3.) 0/U file

Code:
FoamFile
{
    version     2.0;
    format      ascii;
    class       volVectorField;
    object      U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 1 -1 0 0 0 0];

internalField  uniform (0 -0.172 0);

boundaryField
{
    INLET
    {

       type            groovyBC;
       variables "r2=(pow(pos().x,2)+pow(pos().z,2));R2=pow(0.019,2);para=-((R2-r2)/R2)*normal();";
       valueExpression "2*0.172*para"; //where 0.351 is the average velocity
       value        uniform (0 0 0);      
     
    }

    WALL
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }

    OUTLET1
    {

        type            flowRateInletVelocity;
        flowRateExpression "0";
        flowRate swak { 
            variables "phi1{INLET}=-0.52*0.172*sum(area());"; 
            expression "phi1"; // volume flow going out of domain from outlet 1 which 0.52 times that at inlet
            valueType patch;
            patchName OUTLET1;};

     value           uniform ( 0 0 0 );
    }

    OUTLET2
    {

      type  zeroGradient;
       
    }
}
2.) 0/p

Code:
FoamFile
{
    version     2.0;
    format      ascii;
    class       volScalarField;
    object      p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 2 -2 0 0 0 0];

internalField   uniform 0;

boundaryField
{
    INLET
    {
        type            zeroGradient;
    }

    OUTLET1
    {
      type            zeroGradient;
    }
   
    OUTLET2
    {
      type            fixedValue;
      value           uniform 0;
    }  

    WALL
    {
        type            zeroGradient;
    }

    
}
3.)
Code:
fvSchemes

FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

ddtSchemes
{
    default         steadyState;
}

gradSchemes
{
    default         Gauss linear;
    grad(p)         Gauss linear;
    grad(U)         Gauss linear;
}

divSchemes
{
    default         none;
    div(phi,U)      Gauss upwind;
    div(phi,nuTilda) Gauss upwind grad(nuTilda);
    div((nuEff*dev(T(grad(U))))) Gauss linear;
}

laplacianSchemes
{
    default         none;
    laplacian(nuEff,U) Gauss linear limited 0.333;
    laplacian((1|A(U)),p) Gauss linear limited 0.333;
    laplacian(DnuTildaEff,nuTilda) Gauss linear limited 0.333;
    laplacian(1,p)  Gauss linear limited 0.333;
}

interpolationSchemes
{
    default         linear;
    interpolate(U)  linear;
}

snGradSchemes
{
    default         limited 0.333;
}

fluxRequired
{
    default         no;
    p               ;
}


// ****************************************************//
4.)

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

solvers
{
    p
    {
        solver          GAMG;
        tolerance       1e-02;
        relTol          0.1;
        smoother        GaussSeidel;
        nPreSweeps      0;
        nPostSweeps     2;
        cacheAgglomeration true;
        nCellsInCoarsestLevel 10;
        agglomerator    faceAreaPair;
        mergeLevels     1;
    }

    U
    {
        solver          smoothSolver;
        smoother        GaussSeidel;
        nSweeps         2;
        tolerance       1e-02;
        relTol          0.1;
    }

    nuTilda
    {
        solver          smoothSolver;
        smoother        GaussSeidel;
        nSweeps         2;
        tolerance       1e-02;
        relTol          0.1;
    }
}

SIMPLE
{
    nNonOrthogonalCorrectors 2;
    pRefCell        0;
    pRefValue       0;

    residualControl
    {
        p               1e-4;
        U               1e-4;
        nuTilda         1e-4;
    }
}

relaxationFactors
{
    fields
    {
        p               0.9;
    }
    equations
    {
        U               0.1;
        nuTilda         0.2;
    }
}


// ************************************************************************* //
Any help will be appreciated!
mayank.dce2k7 is offline   Reply With Quote

Old   November 6, 2013, 05:21
Default
  #2
Member
 
India
Join Date: Oct 2012
Posts: 84
Rep Power: 4
mayank.dce2k7 is on a distinguished road
ok, one improvement on my part. I got it converged for first order upwind scheme but still no luck with second schemes(SFDCV, linearUpwind etc). I took first order result and used it for my simulation with second order divergence scheme but with no luck.
mayank.dce2k7 is offline   Reply With Quote

Old   November 19, 2013, 06:28
Default
  #3
Senior Member
 
RodriguezFatz's Avatar
 
Philipp
Join Date: Jun 2011
Location: Germany
Posts: 1,097
Rep Power: 16
RodriguezFatz will become famous soon enough
Hi, did you try to use some limiters on the gradients? Sounds like this could be a problem here, since first order works and second order doesn't.
__________________
The skeleton ran out of shampoo in the shower.
RodriguezFatz is offline   Reply With Quote

Reply

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Convergence of jet flow simulation MiraLisa FLUENT 0 August 15, 2013 04:44
SimpleFoam Convergence problem skabilan OpenFOAM Running, Solving & CFD 6 May 31, 2013 03:21
Force can not converge colopolo CFX 13 October 4, 2011 22:03
2D SST Simulation Airfoil - Convergence Problem Kraemer CFX 10 April 16, 2011 07:22
Convergence problem with simpleFoam solver on tilted channel daev OpenFOAM Running, Solving & CFD 1 December 23, 2010 17:20


All times are GMT -4. The time now is 21:05.