17th February 2014

OpenFOAM 2.3.0: foamyHexMesh

Introduction to foamyHexMesh

This version of OpenFOAM includes a new, fully parallelised, meshing tool called foamyHexMesh. It is designed to generate hex-dominant meshes from the same type of surface geometries as used by snappyHexMesh, i.e. triangulated surfaces and in-built analytical surfaces such as spheres, cylinders and planes. The basic principles of the foamyHexMesh meshing process is described below.

  • The volume region(s) to be meshed are filled with vertices of a 3-dimensional Delaunay tesselation , i.e. a set of tetrahedra in which no vertex falls inside the circumsphere of any tetrahedra (below, left).
  • The Voronoi dual is formed by connecting the centres (red) of the circumspheres of the Delaunay tetrahedra (below, right); the Voronoi dual ultimately becomes the mesh generated by foamyHexMesh.


    Wikipedia: Delaunay Triangulation

  • The Delaunay vertices are positioned so that the faces of the polyhedra of the corresponding Voronoi dual represent well the geometry surfaces (e.g., dotted line, images below)
  • The positions of the vertices of the Delaunay tetrahedra are moved iteratively such that the resulting Voronoi polyhedra have favourable shapes, size and orientation for accurate and stable CFD simulation. In particular, we aim to generate hexahedron-shaped cells as shown below, right.


  • The final phase involves filtering out small faces and edges that are typically generated when aiming to produce meshes of hexahedra by this meshing process (see centre of geometry, above right). The image below left highlights small faces of a typical section of mesh in red, and right, the mesh after those faces are filtered.



Meshes from foamyHexMesh

The foamyHexMesh mesher produces hex-dominant meshes which align well with surface geometry and captures features accurately. There is generally low non-orthogonality and cells are of a very regular shape and of uniform size. The user can control mesh density, but high aspect ratio meshes cannot be reliably achieved. The main limitation of foamyHexMesh, particularly compared to snappyHexMesh, is that it is a requirement that surface geometry is perfectly closed. The example meshes shown below are: the flange, where surface alignment and feature conformation can be seen to be very good; and a cell cut of a mixer vessel, where the mixer baffles and other geometry are captured well.


Source code

  • foamyHexMesh


  • mixer vessel
  • flange