Fluent3DMeshToFoam

From OpenFOAMWiki
Revision as of 14:36, 6 February 2009 by Hellorishi (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Convert a mesh generated by Fluent/Gambit to OpenFOAM.

1. Save the file in Fluent/Gambit in ASCII format (uncheck the "Write Binary Files" option)

2. Create a new case (e.g. Beispiel) for OpenFOAM (easy option: copy the following files from a comparable tutorial, e.g. icoFoam)

 a. Create case directory: mkdir Beispiel
 b. Create the following directories inside Beispiel folder (or copy from the icoFoam tutorial)
    mkdir Beispiel/system
    mkdir Beispiel/constant
    mkdir Beispiel/constant/polymesh
    mkdir Beispiel/0
 c. Create the following files: (or copy from icoFoam tutorial)
    Beispiel/system/controlDict
    Beispiel/system/fvScheme
    Beispiel/system/fvSolution
    Beispiel/constant/transportProperties

3. Copy the fluent.msh file into Beispiel folder.

4. Run the fluent3DMeshtoFoam converter (within the Beispiel folder)

  without scaling:  
                  fluent3DMeshtoFoam fluent.msh 
  OR
  with appropriate scaling if required (e.g. from meters to millimeters):
                  fluent3DMeshtoFoam fluent.msh -scale 0.001 


4. Edit the Beispiel/constant/polyMesh/boundary file and set proper names. Typically every surface might be a wall. If one needs inlet, outlet, etc as boundary condition, change wall to patch.

5. Run checkMesh(from Beispiel root folder) to check if the mesh has been converted properly.

  checkMesh 
  OR 
  checkMesh -allTopology -allGeometry 

6. Copy the initial/boundary condition files into Beispiel/0 folder and edit them appropriately.

  e.g. Beispiel/0/U and Beispiel/0/p from icoFoam tutorial.

7. Make further appropriate changes (e.g. nu in Beispiel/constant/transportProperties )

8. The case is ready to run (from Beispiel root folder):

   icoFoam
   or
   foamJob icoFoam