cloudHPC today is releasing the new snappyHexMesh calculator. This is a tool which helps users into choosing the main geometrical parameters of a CFD mesh built using snappyHexMesh, the opensource meshing software included in OpenFOAM. Thanks to this tool, using few parameters, the user can obtain geometrial info about his mesh and define the blockMeshDict – background structured mesh.
To generate a CFD ready mesh, snappyHexMesh requires a certain number of routines to be performed. These are:
- blockMesh -> generator of a structured mesh
- surfaceFeatures or surfaceFeatureExtract -> generate info about geometry edges
- snappyHexMesh -> generate unstructured mesh and refinement close to geometry
The following calculator provides info about the blockMeshDict file generation and the snappyHexMeshDict file. It starts from the assumption the user knows the main physical properties involved with his simulation: flow velocity and fluid properties. Beyond that, a little knowledge about turbulence and y+ requirements is obviously mandatory to use this snappyHexMesh calculator.
Add the following simulation data:
U_inf -> characteristic velocity in m/s Density -> density in kg/m3 Viscosity -> dynamic viscosity in Pa s y+ -> wall mesh resolution
From these info you can get the wall cell height (firstLayerThickness) to insert into the snappyHexMeshDict. After then you can move on by adding some more data:
nSurfaceLayers -> number of boundary layer wall extruded cells expansionRatio -> height ration between two consecutive layers finalLayerThickness -> final extruded layer height
These data must be entered in snappyHexMeshDict file as well. From these the calculator returns the smallest castellated cells dimension in metres.
The last data to enter is the number of layer of the castellated mesh. This data, to enter in snappyHexMeshDict, allows the calculator to obtain the max dimension of the cells in blockMeshDict.
We have not all the main settings of snappyHexMeshDict and blockMeshDict ready to use!