3.16. Generating the Volume Mesh

You can generate a computational mesh for your fluid volume(s) using the Generate the Volume Mesh task. In many cases, the default values will be sufficient.

  1. Choose the Solver for which you wish to generate the volume mesh. The default is Fluent, however you can also choose CFX.


    Note:  When CFX is chosen as the target Solver, the following settings in this task are changed to ensure a compatible volume mesh:

    • For Volume Fill, you can only choose tetrahedral and hexcore.

    • When using hexcore, then Avoid 1/8 octree transition is set to yes by default.

    • Sets the Use default stair-step handling? prompt to No, Exclude both checks, essentially keeping stair-step handling to a minimum.


  2. Choose the type of Fill With that you require. Available options are:

    • tetrahedral

    • hexcore

    • polyhedra

    • poly-hexcore

  3. Indicate whether to Mesh Fluid Regions or not. This is enabled by default, and can be enabled along with the Mesh Solid Regions option, however, both options cannot be disabled at the same time.

  4. Indicate whether to Mesh Solid Regions or not. This is enabled by default, and can be enabled along with the Mesh Fluid Regions option, however, both options cannot be disabled at the same time.

  5. If the Fill With method is set to tetrahedral or polyhedra, specify the Growth Rate. This value determines the relative length-based size change of cells from the boundary (or the boundary layer cap) towards the interior of the domain.

  6. If the Fill With method is set to hexcore or poly-hexcore, specify the number of Buffer Layers and Peel Layers. The buffer layers are additional layers of cells to alleviate a rapid transition from finer cells to coarser cells (see Buffer Layers for details). The peel layers are additional layers that control the gap between the hexahedra core and the geometry (see Peel Layers for details).

  7. If the Fill With method is set to hexcore or poly-hexcore, specify the Min Cell Length field to determine the minimum length of the volume mesh cell.


    Note:  Clicking in this field displays red boxes in the graphics window, providing a visual representation of the field value. Use the Clear Preview button to hide the visualization display.


  8. Specify the Max Cell Length field to determine the maximum length of the volume mesh cell.


    Note:  Clicking in this field displays red boxes in the graphics window, providing a visual representation of the field value. Use the Clear Preview button to hide the visualization display.


  9. If, when generating your surface mesh, you elected to separate zones based on angle (see Generating the Surface Mesh), you will see the Merge Back the Separated Boundary Zones? prompt. Here, you can elect to re-merge the zones prior to creating the volume mesh. By default, this option is set to No.


    Note:  You should not invoke this option if you want to use body labels on multiple bodies to merge cell zones, or if you plan on using the Manage Zones task (see Managing Zones).


  10. For the Sizing Method, choose how the cell sizing will be evaluated.

    • Select Global (the default) to assign global sizing controls such as Growth Rate and the Max Cell Length.

    • Select Region-based Sizing to display a table of available regions where you can assign local sizing controls on a per-region basis.

      For imported CAD geometries that include body labels (and if you have set the Use Body Labels field to Yes in the Import Geometry task, see Importing Geometries), body label names are also listed alongside region names in the table (though their names cannot be edited).

      When Fill With is set to tetrahedral or polyhedra, you can specify the Max Cell Length and Growth Rate for specific region(s), whereas when Fill With is set to hexcore or poly-hexcore, you can specify the Max Cell Length for specific region(s).


      Note:   A body's target mesh size in the context of local sizing and a region's maximum cell length in the context of volume meshing are not identical. When performing local sizing, the body's target mesh size sets the size on both the boundaries and the interior of the region and should be used to set small sizes within a region. Performing local sizing impacts the surface mesh, and it therefore is performed prior to surface meshing. Setting the region's maximum cell length size only controls the size on the interior of the body and should be used to control the maximum cell length of a region, and has no impact on the surface mesh.

      A recommended approach would be to provide a face size control on a body (rather than a body size control) and, for the target mesh size, provide the same value for the region's maximum cell length, therefore providing the same result as if you were to perform body sizing.


  11. Apply parallel processing of the volume mesh using the Enable Parallel Meshing option (enabled by default). This option is available when the Number of Layers for the boundary layer is greater than 1, and when the number of parallel processors is greater than 1. The option is applicable for any Fill With method, such as polyhedra, poly-hexcore, hexcore, or tetrahedral. For information about parallel processing and automatically partitioning the mesh, see Auto Partitioning. Disable this option if you are interested in only generating the volume mesh in serial mode.

  12. Click Advanced Options to access additional controls prior to performing this task. Options include:

    • Use the Quality Method option to choose from several different types of mesh quality controls (skewness, aspect ratio, change in size, and so on). Choices include Orthogonal (the default for the workflows), Enhanced Orthogonal, and Skewness. For more information, see Quality Measure. The quality method chosen here will also be used in the Improve Volume Mesh task if you later add that task to the workflow, however, you can still choose a different quality method for that task if desired.

    • Use the Invoke Persistent Renaming option to allow the volume mesh components to use persistent and unique names for the solver. This will make zone names equivalent to region names, and will make cell and face zone names unique. Using this field is highly recommended for any parametric study.


      Note:  Persistent renaming only works if all body names are unique.


    • If multiple body labels (named selections) are defined in your imported CAD geometry, you can use the Merge Body Label Bodies field to determine if you would like to merge such bodies or not upon meshing the volume (the default is yes).


      Important:  Body names between each Body Label should be unique, while inside a Body Label they can be the same.​


      If set to yes, after volume meshing, the following occurs:

      • All cell zones within a body label will be merged into a single cell zone and take the name of the body label.

      • All face zones adjacent to the merged cell zones will also be merged.

      • Interior face zones between cells will be renamed. For instance, those between "cell-a" and "cell-b" will be renamed to "cell-a-cell-b".

      • All face labels will always be preserved, and automatic renaming does not change the face labels. Face labels that have been separated are also automatically remerged.

      If set to no, you can insert the Manage Zone task and perform the same merging operations by selecting Body Labels as the Type and select all body labels in the list. See Managing Zones for more information.

    • Use the Use Size Field? option to determine whether or not to use size fields as part of generating the volume mesh.

    • Use the Polyhedral Mesh Feature Angle option to set the angle to preserve features when using a polyhedral-based mesh.

    • Use the Avoid 1/8 Octree Transition? option to determine whether or not you want to avoid any potential 1:8 cell transition in the hexcore region of the volume mesh, replacing any abrupt change in the cell size with polyhedral cells.

    • Use the Fill Polyhedra in Solids? option to fill only polyhedra cells in all solid regions during volume meshing using the poly-hexcore volume fill method. This option is available when there is at least one solid region and one fluid region. The workflow assumes that the largest volume represents a fluid region such that, when using this option, you achieve a higher quality volume mesh by filling the largest (fluid) region with poly-hexcore cells.

    • When using the poly-hexcore volume fill method, use the Use Size Field in Solids? option to use size-field-based sizing for polyhedra regions during volume meshing. This setting is available when the Use Size Field? and Fill Polyhedra in Solids? options are enabled and is recommended when BOI(s) are defined that include polyhedra regions. Size-field based sizing is required for BOI(s) to be respected inside all polyhedra regions.

    • Use the Solid Region Growth Rate field to control the growth rate of all solid regions in the volume mesh. Note that this field is only available for poly-hexcore volume meshes and when the Fill Polyhedra in Solids? option is set to yes. By default, the growth rate is set to a value of 1.5.

    • Use the Quality Improve Limit option to set the threshold for when mesh quality improvements are automatically invoked that employ the orthogonal quality limit.

    • Use the Check Self Proximity option to determine whether or not you are going to check for any proximity issues (such as overlapping surfaces, very small gaps between surfaces, very sharp angles, etc.) while generating the volume mesh. If set to yes, problematic areas will be highlighted in the graphics window.

    • If you have added (or read in) any boundary layers to your workflow, you can write out a boundary layer (prism) control file to save their settings to use later. Use the Write Prism Control File option to specify whether or not you want to save a boundary layer control file that contains your boundary layer specifications. If you select yes, a .pzmcontrol file (based on the CAD file name) will be written to your working directory during volume mesh creation. If the file already exists, you will be notified and you can choose to overwrite the file or not.


      Note:  Advanced options (such as acute angles, invalid normals, etc.) are not supported and cannot be saved to the prism control file.


  13. Click Global Boundary Layer Settings to access additional boundary layer controls prior to performing this task. These options are only available when you have defined a boundary layer using the Add Boundary Layer task (Adding Boundary Layers). Options include:

    • Use the Merge Boundary Layer Cells Within Regions? to determine whether or not you want to have the boundary layer mesh merged into the bulk mesh.

    • Use the Gap Factor option to specify the relative gap between two boundary layer caps in a narrow channel. A value of 1 indicates a gap that is of the same order as the boundary layer cap triangle size in the inflation layer.

    • Use the Max Aspect Ratio option to specify the maximum aspect ratio for the boundary layer when proximity compression is applied.

    • Use the Min Aspect Ratio option to specify the minimum aspect ratio for the boundary layer.

    • Use the Keep First Boundary Layer Height? option to retain the initial boundary layer's height.

    • Use the Adjacent Attach Angle option to set the angle for which the boundary layer would imprint on an adjacent boundary.

    • Use the Use default stair-step handling? option to reduce the stair-stepping at certain locations based on quality or proximity criteria. By default, Yes allows you to retain the default stair-step handling, otherwise you can also choose No, Exclude proximity check, No, Exclude quality check and No, Exclude both checks.

    • Stairstep Exposed Quads can be used when generating a tetrahedral mesh with prism cells and is set to No by default. Selecting Yes for this option will enable stair-stepping for exposed quadrilateral faces (exposed quads) on prism cells. Stair-stepping these exposed quads can prevent the mesh generation from "hanging" or becoming unresponsive during pyramid creation and can enhance pyramid quality.

  14. Click Generate the Volume Mesh to generate a volume mesh for the imported CAD geometry.

    If you need to make adjustments to any of your settings in this task, click Edit, make your changes and click Update, or click Cancel to cancel your changes.

  15. Use the Draw Mesh button to display the fluid and/or solid meshes.

    Figure 3.24: Example of a Fluid and a Solid Volume Mesh

    Example of a Fluid and a Solid Volume Mesh

Additional enhancements can be made to the volume mesh using the Improve Volume Mesh task (see Improving the Volume Mesh ). For more information about volume meshing, see Object-Based Volume Meshing.

When you are satisfied with the volume mesh, you can proceed to setting up your CFD simulation in Fluent solver mode.


Note:  When using the meshing workflows, after generating the volume mesh, the default quality measure is set to Orthogonal Quality, and will be reported as such when querying the mesh quality.