CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM (
-   -   OpenFoam vs Fluent (

mechy October 11, 2013 18:15

OpenFoam vs Fluent
Hi All

I have run several test case with OF and Fluent with similar settings.
I have found that fluent is more stable , accrue and faster than OF
also OF is very sensitive to mesh quality but Fluent not.

I hope it is be useful for anyone who like to compare OF with fluent

Best Regards

fumiya October 11, 2013 22:09


I'd like to know in a bit more detail your comparison.
What kind of test cases do you have?

Best regards,

mechy October 12, 2013 00:47

the equivalent of pimpleFoam, in fluent is PISO. therefore ,
I have compared pimpleFoam in OF vs PISO in fluent

my test cases are, flow around airfoil with flap , cylinder + square, ....

setting for both software:
grad========> leastSquares (in OF, I should cellLimited for convergency)
spatial Discretization ===========> linearUpwind and limitedLiniear for OF and second order Upwind for fluent
turbulence =============> kw-SST
convergence criteria in each time step =============> 1e-5

in the case of airfoil I have 430,000 element and this mesh is very orthogonal but for reducing cell numbers I have large aspect ratio up to 200


Create polyMesh for time = 0

Time = 0

Mesh stats
    points:          858672
    internal points:  0
    faces:            1712256
    internal faces:  853584
    cells:            427640
    faces per cell:  6
    boundary patches: 5
    point zones:      0
    face zones:      0
    cell zones:      0

Overall number of cells of each type:
    hexahedra:    427640
    prisms:        0
    wedges:        0
    pyramids:      0
    tet wedges:    0
    tetrahedra:    0
    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                 
    outlet              440      882      ok (non-closed singly connected) 
    inlet              1946    3894    ok (non-closed singly connected) 
    airfoil            840      1682    ok (non-closed singly connected) 
    flap              166      334      ok (non-closed singly connected) 
    frontAndBackPlanes  855280  858672  ok (non-closed singly connected) 

Checking geometry...
    Overall domain bounding box (-5.550127737 -5.591641676 -0.2026569752) (11.32561672 5.629220361 0.2026569752)
    Mesh (non-empty, non-wedge) directions (1 1 0)
    Mesh (non-empty) directions (1 1 0)
    All edges aligned with or perpendicular to non-empty directions.
    Boundary openness (1.17593747628e-16 -2.70071155431e-18 3.75564274317e-19) OK.
    Max cell openness = 3.09499812379e-14 OK.
    Max aspect ratio = 32.785960966 OK.
    Minimum face area = 6.61643707061e-09. Maximum face area = 0.103614464857.  Face area magnitudes OK.
    Min volume = 2.68173424667e-09. Max volume = 0.0170019640072.  Total volume = 69.3839936096.  Cell volumes OK.
    Mesh non-orthogonality Max: 39.555341894 average: 7.02685898042
    Non-orthogonality check OK.
    Face pyramids OK.
    Max skewness = 0.729335018151 OK.
    Coupled point location match (average 0) OK.

Mesh OK.

the fluent is converged very rapidly with large time step (1e-4) but OF is converged slowly only with cellLimited grad scheme and time step 1e-5

also the OF results is not smooth as Fluent

jherb October 14, 2013 15:25

Could you please post your fvSchemes and fvSolution files for your OpenFOAM setup.

mechy October 14, 2013 16:22


    default Euler;

    default                leastSquares ;

    default        none;
    div(phi,U)    Gauss linearUpwind grad(U)
    div(phi,k)      Gauss limitedLinear 1
    div(phi,omega)  Gauss limitedLinear 1; 
    div((nuEff*dev(T(grad(U))))) Gauss linear;


    default        Gauss linear corrected;

    default        linear;

    default        corrected;


        solver          GAMG;
        tolerance        1e-6;
        relTol          .0001;
        smoother        GaussSeidel;
        nPreSweeps      0;
        nPostSweeps      2;
        cacheAgglomeration true;
 //      directSolveCoarsest true;
        agglomerator    faceAreaPair;
        nCellsInCoarsestLevel 20;
        mergeLevels      1;
        minIter          1;
        solver          GAMG;
        tolerance        1e-6;
        relTol          0;
        smoother        GaussSeidel;
        nPreSweeps      0;
        nPostSweeps      2;
        cacheAgglomeration true;
        agglomerator    faceAreaPair;
        nCellsInCoarsestLevel 20;
        mergeLevels      1;
        minIter          1;

        solver          PBiCG;
        preconditioner  DILU;
        tolerance        1e-6;
        relTol          0.0001;
        nSweeps          1;   
        minIter          1;
        solver          PBiCG;
        preconditioner  DILU;
        tolerance        1e-6;
        relTol          0.0;
        nSweeps          1; 
        minIter          1;


    nOuterCorrectors    5;
    nCorrectors        2;
    nNonOrthogonalCorrectors 4;


mechy October 14, 2013 17:49

I have found that the main deficiency of openfoam is that it is very sensitive to mesh quality.
if I divide the mesh quality to very good, good , medium,bad ,very bad then
the OF and Fluent have the same performance on the very good meshes.
OF performance on the good meshes is lower than FLUENT and it can not handle other meshes.
FLUENT can handle medium and bad meshes very well.

Best Regards

skyinventorbt October 15, 2013 01:05

Dear Yasser,

OpenFOAM is an open-source CFD tool -- you could optimize for your needs.

I found lot of advantages in OpenFOAM while post processing my simulation data.

in particular --> Tensorial operations.

mechy October 15, 2013 02:45


I agree with you that OF is a good Open Source code
I hope in the future OF remove its dependency to meshes and it become a very powerful
the current deficiency is a big problem. in the complex geometries we can not create a
very good mesh

Best Regards

olivierG October 15, 2013 05:18


I may disagree with you mechy, but your post is not "useful for anyone who like to compare OF with fluent", since a lot of things are missing.

If you want to add usefull info, add your full OF case and Fluent case.
Because you don"t give your BC setting for OF, neither Fluent setting, initialization method, etc ...


elvis October 15, 2013 05:26


did you follow Discretisation Best Practice for Industrial CFD with OpenFOAM or like that?

mechy October 15, 2013 06:42

in post reply number 3 and 5 you can find setting for OF and FLUENT
for OF my fvScheme and fvSolution are added to post reply5 ;
the BC are as follow

inlet | fixedValue | velocityInlet

outlet | inletOutlet |
| or zeroGradient | pressureOutlet

to Elvis
please see my fvScheme , it is equal to recommended setting by JASAK
also I check Gauss for Grad but nothing changed.

olivierG October 15, 2013 08:17


This is better, not perfect:
- Did you use hybrid initialisation in Fluent ?
- initial value in OF ?
- about CFL: (i didn't see your controlDict by the way .... upload the full case again) if Fluent use 10x bigger time step, this is probably not Euler fort the temporal discretisation ...
- what maxCo do you use ?
- residus are not the same in OF / Fluent: did you use another convergence criterious, like Cp/ Cl convergence , which is more valid ?
- in your fvsolution, p tolerance should be smaller
- you say you follow the LASAK rules, but use nNonOrthogonalCorrectors=4: you should use 0 in your case.
- you use "zeroGradient" for pressus outlet, while Fluent use "pressurOutlet" : this is _not_ the same BC at all. In your case, the chord length seem to be really too small for a zeroGradient BC (if you look in this forum, you willl see good result with 20 to 40, and use other BC like freestreamPressure and cie.)

This is some critics (in the constructive way) i can make, and i am not an expert here. I use OF and Fluent almost every day, and i disagree with your first post. Sometime, Fluent are faster, sometime this is OF. same for accuracy.

So in short, try to improve your settings ... this take time (a real difference with Fluent), and we can share info about this ...

best regards,

mechy October 15, 2013 08:30

HI oliver
in both software the initial velocity and pressure is zero and initial k and omega is inlet conditions.
in both software I use constant deltaT=5e-5
for airfoil I use a very good mesh and a good mesh in both mesh fluent give the same result but on good mesh the OF convergence is very slow.
fvSolution with current p tolerance is sufficient on very good mesh and it give the fluent results
also if I use nNonOrthogonalCorrectors=0 the solution convergence become slower

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