• CFD, Fluid Flow, FEA, Heat/Mass Transfer
  • +91 987-11-19-383
  • amod.cfd@gmail.com

Open-source CFD toolbox: OpenFOAM is now a mature open-source CFD program with reliability matching that of commercial products. This page describes summary of utilities and dictionaries used in OpenFOAM meshing and visualization such as (blockMesh, snappyHexMesh, ParaView) and OpenFOAM CFD codes and pre-processors such as (simpleFoam, pimpleFoam, engineFoam...).

OpenFOAM CFD: A Beginner's Diary


This content is not approved or endorsed by OpenCFD Limited, the producer of the OpenFOAM CFD software and owner of the OpenFOAM and OpenCFD trademarks.
OpenFOAM Tutorials Catalogue
This page summarizes the cases - especially geometry and flow physics available as test cases in OpenFOAM tutorials folder. This is an attempt to sort of create a catalogue so that any new user can choose which module or application of openFOAM to start with. Sometimes even experience CFD practitioner not familiar with openFOAM may have a "sinking in ocean" feeling like I had! The purpose is to have this visual catalogue and nothing else! This content is prepared as recorded by a new learner (during his ongoing journey to become an OpenFOAM expert) with anticipation that it will be helpful to others as well.

Test Cases in Official Release Tutorial - There are 5 different cases explained in an excellent way the simulations process to be followed in OpenFOAM. An equally impressive set of tutorials for 11 additional cases can be found here.
For users starting to program own solver, this article will of great help!
Combustion Modeling - XiFoam tutorial available from

Combustion Modeling - reactingFoam
The cases demonstrating incompressible, steady state flow based in SIMPLE algorithm are airFoil2D, mixerVessel2D, motorBike, pipeCyclic, pitzDaily, pitzDailyExptInlet, rotorDisk, simpleCar, turbineSiting, windAroundBuildings. They are pictorially described below. All of the case folders have a file named "Allrun". This contains the sequence of operation required to be run. For example, the case "turbineSiting" contains following set of instructions in Allrun file:
    runApplication blockMesh
    \cp system/decomposeParDict.hierarchical system/decomposeParDict
    runApplication decomposePar
    \cp system/decomposeParDict.ptscotch system/decomposeParDict
    runParallel snappyHexMesh -overwrite
    find . -type f -iname "*level*" -exec rm {} \;
    # - set the initial fields
    restore0Dir -processor
    runParallel topoSet
    runParallel $(getApplication)
    runApplication reconstructParMesh -constant
    runApplication reconstructPar
However, if one does not want to run parallel version (using more than 1 processor), simply use blockMesh and then snappyHexMesh on the command prompt to get the desired mesh, thus skipping the utilities decomposePar, reconstructParMesh and reconstructPar.

List of Sampe Cases

OpenFOAM Basic cases

OpenFOAM Incompressible Flow cases pimpleFoam pisoFoam

OpenFOAM Incompressible Flow cases simpleFoam

OpenFOAM heat transfer cases

OpenFOAM multiphase interFoam

OpenFOAM multiphase eulerFoam

OpenFOAM multiphase Lagrangian Particle Tracking

OpenFOAM combustion modeling

OpenFOAM compressible flows

As per user guide: "Steady-state solver for incompressible, 1D turbulent flow, typically to generate boundary layer conditions at an inlet". The description of flow geometry and boundary conditions used are shown below.


A detailed description of this tutorial case by Grant Ingram from Durham University can be found here.

OpenFOAM - Tutorial Case - Airfoil 2D

OpenFOAM - Tutorial Case - Airfoil 2D

No blockMeshDict available in tutorial folder. polyMesh data available for simulation. Typically, the information is provided in utility file Allrun. If there is no mention of mesh in this file, there is not one. For example, in problem case 'flange' under laplacianFoam, there is neither blockMeshDict nor polyMesh. But there is a file 'flange.ans'. Inside 'Allrun' it is explained that flange.ans is ANSYS file.
pitzDaily - flow over back step

This is one of the test cases described in user guide. There are two simulation cases - they differ mainly between the turbulence model used and the way input boundary conditions are specified. "pitzDailyExptInlet" demonstrate how to interpolate or apply non-uniform boundary conditions at the inlet. The differences in U sub-dictionaries are shown below.

pitzDaily - flow over back step

pitzDaily - flow over back step

Go to top
This is a good demonstration of block mesh utility to generate mesh with internal cavities and nice representation of car as simplified geometry.

simpleCar Bluff Body
This demo case shows how to use parameter definition in blockMeshDict, use of #calc utility and create wedge elements [axisymmetric domain with zero inner radius]. The blockMesh utility creates on-the-fly library for few occurrence of #calc [in Windows version of 1606+]. Some messages appearing in the terminal are:
  wmakeLnInclude: linking include files to ./lnInclude
  ln: creating symbolic link './codeStreamTemplate.C': Protocol error
  Making dependency list for source file codeStreamTemplate.C
  Creating new library in "dynamicCode/_9273df81ebe52476e105ce9128b702a57ad95417/platforms/

Pipe Cyclic

Go to top
Flow of Buildings - snappyHexMesh
This case demonstrates snappyHexMesh utility. User should follow the steps defined in file Allrun. surfaceFeatureExtract needs to be run before blockMesh and snappyHexMesh.

Wind Buildings

Wind Buildings

sHM requires other utilities such as surfaceCheck which can check the input STL geometry and prints overall size (bounding box) of the geometry. Output from surfaceCheck utility:
Reading surface from "constant/triSurface/Fan_in_Duct.stl" ...

Triangles    : 23474
Vertices     : 11749
Bounding Box : (-550 -185 -185) (540 185 185)

Region  Size
------  ----
patch0  23474

Surface has no illegal triangles.

Triangle quality (equilateral=1, collapsed=0):
    0.00 .. 0.05  : 0.1744
    0.05 .. 0.10  : 0.1612
    min 4.76e-06 for triangle 19519
    max 0.999899 for triangle 11050

    min 0.00290 for edge 352 points (-22.92 108.37 143.69)(-22.9 108.37 143.7)
    max 500.073 for edge 101 points (-550.0 152.62 104.55)(-50.0 157.29 97.39)

Checking for points less than 1e-6 of bounding box ((1090 370 370) metre) apart.
Found 0 nearby points.

Surface is not closed since not all edges connected to two faces:
    connected to one face : 24
    connected to >2 faces : 8
Conflicting face labels:48
Dumping conflicting face labels to "problemFaces"
Paste this into the input for surfaceSubset

Number of unconnected parts : 2
Splitting surface into parts ...

Writing zoning to "zone_Fan_in_Duct.vtk"...

writing part 0 size 1084 to "Fan_in_Duct_0.obj"
writing part 1 size 2239 to "Fan_in_Duct_1.obj"

Number of zones (connected area with consistent normal) : 10
More than one normal orientation. 

Rotating Walls and Domains
mixerVessel2D - simpleFoam
This case can be obtained by adding baffles to the case 2D rotor. However, note that 2D rotor case uses simpleFoam and not SRFSimpleFoam.
mixerVessel2D - 2D Rotor
SRFSimpleFoam - mixer
SRFSimpleFoam - mixer
Go to top
SRFPimpleFoam - 2D Rotor
SRFPimpleFoam - 2D Rotor
Go to top
pimpleDyMFoam - Moving Cone
This tutorial demonstrates the moving mesh without any re-meshing or addition/deletion of layer. The size of elements expands and contracts during the mesh motion with constant velocity 1 [m/s] defined in dictionary 0/pointMotionUx.

pimpleDyMFoam - Rotating Cone

pimpleDyMFoam - Rotating Cone

Go to top
pimpleDyMFoam - propeller with AMI (Arbitrary Mesh Interface)
pimpleDyMFoam - propeller blade

pimpleDyMFoam - propeller domain

pimpleDyMFoam - propeller domain

pimpleDyMFoam - propeller domain

snappyHexMesh [sHM]
Used to create high quality hex-dominant meshes [similar to but not exactly Cartesian Mesh in ICEM CFD] based on arbitrary geometry, the controlling dictionary is system/snappyHexMeshDict. Requires a starting [hexahedral] mesh created by blockMesh [designated as base mesh or level 0 mesh] and geometry data in STL and Nastran (.nas) files format. A snappyHexMeshDict file created after reading through such files used in various tutorial application can be found here. This is a generic dictionary which demonstrates all the features of this utility. Different stages of mesh generation in snappyHexMesh utility is shown in following images.

snappyHexMesh Stage 1

snappyHexMesh Stage 3

snappyHexMesh Stage 3

Examples of snappyHexMesh application can be found in tutorial cases:
  • incompressible/windSimpleFoam/turbineSiting
  • incompressible/simpleFoam/turbineSiting
  • incompressible/pisoFoam/les/motorBike/motorBike


laplacianFoam in OpenFOAM

Conductive heat transfer using laplacianFoam in openFOAM

laplacianFoam in OpenFOAM

Go to top
Conjugate Heat Transfer - a well documented PDF version can be found here.

Conjugate Heat Transfer in OpenFOAM

Conjugate Heat Transfer in OpenFOAM

Conjugate Heat Transfer in OpenFOAM

Conjugate Heat Transfer in OpenFOAM

Go to top



This module demonstrates use of PISO-SIMPLE (PIMPLE) algorithm in test cases such as TEE-junction and fan pressure jump boundary conditions.

pimpleFoam: T-Junction

pimpleFoam: T-Junction Fan

pimpleFoam: T-Junction Fan

Multiphase flow using VOF method for 4 immiscible phases.

multiphaseInterFoam Four Immiscible Phases

Contact us
Disclaimers and Policies

The content on CFDyna.com is being constantly refined and improvised with on-the-job experience, testing, and training. Examples might be simplified to improve insight into the physics and basic understanding. Linked pages, articles, references, and examples are constantly reviewed to reduce errors, but we cannot warrant full correctness of all content.