Mesh Generation

What is Mesh Generation?

Mesh (grid) generation is the practice of generating a polygonal (surface) or polyhedral (volume) mesh that approximates a geometric domain. A mesh — nodes and elements — is commonly associated with the finite element method. A grid — gridpoints and zones — is sometimes associated with Lagrangian finite volume or finite difference methods. Mesh and grid are used interchangeably in this document, since their geometry and connectivity are identical (only the solution method is different).

A 2D mesh is required in order to run a numerical simulation in UDEC or FLAC and a 3D mesh is required for 3DEC or FLAC3D. The input geometry to build the mesh can vary. Common sources are CAD, NURBS, STL, contour lines or a point cloud from scanned datasets.

Three-dimensional meshes created for finite difference and finite element methods typically consist of tetrahedrons, pyramids, prisms, or hexahedrons. Meshes are often categorized as: structured, unstructured, or hybrid meshes. Mesh quality is crucial for the stability, accuracy, and fast convergence of a numerical simulation. There are numerous measures of mesh or element quality, such as element aspect ratio, Jacobian, planarity of element faces, maximum and minimum angles at corners, etc.

Structured Meshes

Structured meshes are identified by regular connectivity. For example, a quadrilateral mesh in 2D is structured if each internal node is joined to 4 neighboring quadrilaterals, forming a regular array of elements. FLAC (2D) meshes are structured. In 3D, a structured hexahedral grid has each internal node connected to 8 elements. This type of mesh is highly space efficient because the neighborhood relationships are defined by storage arrangement. Structured meshes typically have well-shaped elements. Generating these elements for simple geometry is straightforward. BlockRanger, FLAC3D primitives, FLAC3D extruder, FLAC3D Building Blocks allow users to create meshes by connecting primitive shapes (hexahedrons, prism, tetrahedrons, etc.), with each shape containing a pre-defined, mapped, structured mesh. These primitive shapes can be used to build relatively complex grids. The main advantage of a structured grid over unstructured is typically better shaped elements (better accuracy in each element); the disadvantage is the time required to build geometrically complex models.

Examples of primitive shapes available in FLAC3D (from left to right “brick”, “cylinder”, “cshell”, and “radcylinder”).

Structured mesh in FLAC3D generated using the Extrusion tool. The lower right insert shows the decomposition of the volume into 20 simple solids as seen in the Extrusion pane.

Examples of primitive shapes available in 3DEC (from left to right “brick”, “drum”, and “tunnel”).

Unstructured Meshes

An unstructured grid is identified by irregular connectivity. It cannot be expressed easily as a two-dimensional or three-dimensional array in computer memory. This allows for any possible element type and arrangement. Compared to structured meshes, this type of mesh can be highly space inefficient since it relies on explicit storage of neighborhood relationships. It is very common for these meshes to employ triangles in 2D and tetrahedrons in 3D. However, some meshers allow you to build hex-dominant unstructured meshes that contain a majority of quadrilaterals (2D) or hexahedrons (3D) with far fewer numbers of other element types (triangles in 2D or tetrahedrons, prisms, pyramids in 3D). Automatic meshers usually output unstructured meshes. They have the advantage of generating meshes for any geometry, especially complex geometries, significantly faster than the operations required to build a similar model with a mapped mesher. Itasca just introduced a new powerful and easy-to-use automatic mesher called Griddle. Griddle is accessible from the Rhino CAD-system and can output both all-tetrahedral and hex-dominant meshes. The new version of FLAC3D (v 6.0) also offers some basic automeshing capabilitites that allow you to fill any closed-volume geometry with tetrahedrons.

FLAC3D unstructured mesh generated by Griddle in Rhino.

Octree Meshes

Consider an initial structured hexahedral grid. If we refine this grid by subdividing hexahedrons (a hex is subdivided into eight smaller hexahedrons) in areas of interest, a non-conformal mesh with smaller elements in some areas and larger elements in others would result. We continue subdividing the smaller hexahedrons in our areas of interest up to a certain level of refinement (e.g., a minimum element-edge length). If we then enforce the rule that an element’s neighbor must be either ½, 1, or 2 times its size (by subdividing further), we obtain a balanced octree mesh (like that shown below). With this method, the user initially creates a regular structured hexahedral grid independent of the geometry and then densifies this grid close to the features that need to be modeled and analyzed. The level of densification will depend on the precision that is required. The densification process consists of dividing a hexahedron into eight hexahedrons and repeating this until the desired zone size is achieved. The main advantage of the octree method is its ability to generate a mesh for complex geometries very quickly. The main disadvantage is that the resulting mesh does not conform to the geometry, but rather results in “stair step” boundaries that approximate the modeled features, which is not acceptable for all types of problems.

FLAC3D mesh using the built-in octree generation commands.

Hybrid Meshes

A hybrid mesh usually refers to a mesh that contains a combination of structured and unstructured meshes.

Conformal vs. Non-conformal Meshes

A non-technical definition of a conformal mesh is a mesh where each element, if it has a neighbor, completely shares a face with the neighbor (and by extension the edges and nodes of that face as well). An example of a non-conformal mesh includes a hexahedral element sharing one of its quadrilateral faces with two faces of adjoining tetrahedra (two triangle faces). Another example includes the case where two meshes might be laterally offset from each other, where some of the nodes and edges do not match at element boundaries (sometimes referred to as "hanging nodes"). FLAC3D is capable of handling both of these grid types. Non-conformal grids can be handled with FLAC3D interfaces or attach logic. 3DEC zones are always conformal within a block. By default, 3DEC grids are also conformal between blocks; however, there is a switch in the GENERATE command that will not enforce gridpoint matching between blocks (GEN EDGE ALT).

Both of the following meshes are comformal; the former is structured, the second is unstructured.  The geometry for the following mesh was decomposed into hexahedral, tetrahedral, and prism solids with the Rhino CAD system and meshed with BlockRanger. The solid geometry creation in Rhino required about five hours of effort. The resulting mesh is an all-hexahedral structured mesh.

All-hexahedral structured mesh generated by BlockRanger for FLAC3D.

This next mesh was created with Griddle by using the bounding surfaces of tunnels and soil layers as input. Manual decomposition into simple primitive shapes was not required and hence model creation time was reduced to less than one hour. The resulting mesh is a hexahedral-dominant unstructured mesh.

Hexahedral dominant unstructured mesh generated by Griddle for FLAC3D.

What is a Good Mesh?

A good mesh is a mesh that allows you to solve your problem at the expected level of accuracy within the time available for the project. At the point where mesh size and complexity become computational factors, mesh generation is always a compromise between time and accuracy.

Mesh generation can be a very time-consuming process. Therefore judgement is needed to determine if a given mesh will perform well enough for a given model or if more effort is needed to improve its quality. Given the geometrical complexity of some models and the tools available for mesh creation, it is often necessary to accept meshes that deviate significantly from the known ideal shape.

The density of the mesh is required to be sufficiently high in order to capture details (e.g., displacements, stress) in areas of interest as well as properly mimic the physical mechanisms of the problem. On the same note, mesh density should not be so high that it captures unnecessary details that are not of interest to the project or beyond the precision of the field measurements. These burden the CPU and waste time.

How do I decide the type of mesh?

In terms of accuracy, a structured hexahedral mesh usually results in the best-shaped elements.

In terms of user efficiency, an unstructured mesh is usually easier to assemble, especially when dealing with complex geometries that include several features. An unstructured mesh can usually be built in a very limited time with an automatic mesher and is composed of less zones than an equivalent structured mesh, which also reduces the computational time of your model — the smaller number of zones in your model, the faster the simulation.

Which tools should I use to generate my mesh?

There are multiple ways to generate a mesh for a given geometry. As observed above, mesh generation is a compromise between efficiency and accuracy. In turn efficiency is dependent not only on the type of mesh but also on the user’s experience. Even if a new tool offers excellent new capabilities, one might prefer to use an existing tool where proficiency is established. Different people might choose different tools to mesh the same geometry in a given amount of time.

The following guidelines are general. They provide a broad overview of 3D meshing problems and solutions. Each user may decide to follow or deviate from them depending on experience, preference, and capability.

Which tools can I use to generate a mesh for FLAC3D or 3DEC?

Itasca offers a number of mesh generation tools. They may be divided into two categories.

Itasca offers several approaches in each category. Each approach has advantages and drawbacks that are outlined as follows.

The following tables summarize the different built-in (FLAC3D, 3DEC) or Rhino CAD-based (Griddle, BlockRanger) meshing tools for building structured and unstructured meshes. Building hybrid meshes (combinations of structured and unstructured meshes) simply requires a combination of these tools.

FLAC3D Meshing

Type Tool Application Main Advantage Description

Structured

Command line
primitives and FISH

• Available from the command line
• Any type of problem
• Better suited for simple geometries
• Very time consuming for complex geometries
• Quality
• Includes pre-meshed primitive shapes (hex, cylinder, tunnel intersections, ...), and topography conforming functionality (for v. 5.0 and up)
• FISH language can be used to deform the grid to better fit the geometry to be modeled
• ZONE SPLIT split command allows automatically dividing all tetrahedral and wedge shaped zones into hexahedrons (v 5.0 and up)
• Basic unstructured tetrahedral mesh generation on closed volumes (new in v 6.0)

Structured

Primitives Commands & FISH – Octree mesh

• Available from the command line
• Any type of numerical problem
• Better suited for complex geometries
• Efficiency
• In addition to primitives, topography (v 5.0 and up) and geometric data (v 5.0 and up) commands, the DENSIFY command automatically builds octree meshes from surfaces and volumes
• FISH language can also be used to deform the grid to better fit the geometry to be modeled

Structured

Interactive 2D extrusion (v 5.0 and up required)

• Available from the FLAC3D interface
• For extruded geometries only
• Efficiency
• Quality
• Allows interactive definition of a 2D section and then extrusion to create zones
• DXF or bitmap can be imported and used as a background, with snapping available

Structured

Interactive Building Block (NEW in v 6.0)

• Available from the FLAC3D interface
• Any type of problem
• Better suited for simple to moderately complex geometries
• Quality
• Structured meshing capabilities
• Option to automatically block geometries for subsequent editing
• DRAPE command automatically conforms the surface of the model to a supplied topography

Structured

Interactive BlockRanger (Free with v 6.0)

• Available from the Rhino interface
• Any type of problem
• Better suited for simple to moderately complex geometries
• Quality
• Itasca interactive mapped mesher
• Generates all-hex meshes

Unstructured

Interactive Griddle (NEW)

• Available from the Rhino interface
• Any type of problem
• Better suited for complex geometries
• Efficiency
• NEW Itasca interactive automesher
• Generates tetrahedral and hex-dominant meshes

3DEC Meshing

In 3DEC, a discontinuous medium is represented as an assemblage of discrete blocks. Boundaries between blocks are treated as discontinuities along which large displacements and rotations between blocks are allowed. Individual blocks can behave as deformable material, in which case the block is subdivided into a mesh of finite difference elements (i.e., continuous assemblages of zones).

Itasca CAD-based meshing tools allow you to build block models to input to 3DEC. Zoning of deformable blocks is usually done directly in 3DEC, automatically.

Type Tool Application Main Advantage Description
Structured

Primitives Commands & FISH

• Available from the command line
• Any type of problem
• Better suited for simple geometries
• Can results in poor quality and heavy mesh for complex geometries
• Efficiency
• Includes tunnel primitive
• Planar cuts commands can be used to intersect blocks with any number of planes
• Includes cube command to generate a region based on a user-defined outline
• FISH language can be used to automate planar cuts to construct the desired geometry (such as complex tunnel shapes, for example)
Structured

VRML to Block converter EXE

• Executable requiring VRML input file
• Any type of problem
• Handles any closed convex volumes
• Distributed free with 3DEC
• Efficiency
• Quality
• Uses common VRML CAD format
• Allows automatically creation of blocks for import into 3DEC based on closed convex volumes (input in VRML format)
Structured

Interactive BlockRanger (Free with v 6.0)

• Available from the Rhino interface
• Any type of problem
• Better suited for simple to moderately complex geometries
• Output of hex blocks (v1.2 and up) and tetrahedral blocks
• Quality
• Itasca interactive mapped mesher
• Generates hexahedral blocks
Unstructured

Interactive Griddle (NEW)

• Available from the Rhino interface
• Any type of problem
• Better suited for complex geometries
• Efficiency
• NEW Itasca interactive automesher
• Generates tetrahedral and hex-dominant meshes

Itasca offers two CAD-based interactive meshers: Griddle and BlockRanger.

Griddle and BlockRanger are both used with the Rhino CAD system. The entire meshing process done within the Rhino interface.  Resulting meshes can be imported into FLAC3D or 3DEC.

What is Rhino?

Rhino is a solid modeling tool for designers and engineers. With Rhino you can import, create, edit, and export geometrical objects in a variety of formats for use in Itasca software (FLAC3D, 3DEC, PFC).

Note that:

• Itasca CAD-based meshers require the Rhino CAD system. Rhino allows you to build the geometry and directly use the surface and/or volume meshing capabilities offered by Griddle and BlockRanger.
• Rhino CAD system can be optionally purchased, at a reduced price, with the purchase of FLAC3D, 3DEC, or PFC3D.
• Itasca’s meshing tool BlockRanger is included free with the purchase of FLAC3D Version 6 and up or 3DEC Version 5.2 and up.

What is BlockRanger?

BlockRanger allows you to interactively build, using the powerful CAD capabilities of Rhino, all-hexahedral, structured (mapped) meshes for simple to fairly complex 3D geometries. BlockRanger requires the user to partition the 3D geometry to be meshed into simple solids like brick-, wedge-, or tetrahedral-type shapes. Users have control over the maximum number of elements and the number of subdivisions (number of elements) on the edges of those solid shapes. For very complex geometries, subdividing your model into simpler solid shapes can be very time consuming. For these cases Itasca recommends Griddle.

What is Griddle?

Griddle is a new Itasca interactive Rhino CAD-based meshing product. Griddle allows you to easily build unstructured meshes for simple to very complex 3D geometries. This powerful, easy-to-use, automatic mesher requires minimal input from the user to build meshes for simple to very complex geometries. After the model geometry is built or imported into Rhino, Griddle allows you to automatically remesh the surfaces to the desired density and type (triangles, quadrilaterals). The Griddle volume mesher is then called to fill the geometry with zones (all-tetrahedral or hex-dominant). A Griddle meshing workflow is shown below.

Surface remeshing allows excellent control over element sizing, including honoring hard edges and points (edges and points that need to be on the surface). Griddle can produce triangle, quad-dominant, or all-quadrilateral surface meshes.

Surface meshes are used directly by the Griddle volume mesher. The final solid elements composing the mesh (hexahedrons, tetrahedrons, prisms, pyramids) have faces that coincide with the input surface mesh.

 Built-in Capabilities CAD-based Capabilities (based on Rhino CAD system) —Pros— No additional cost Very precise control on zones edge length and zone size gradation in the whole model Can result in 100 % nicely shaped regular hexahedral elements (required for some problems) Mesh can be parametrized (>>if the geometry needs to be modified, the user does not have to start the meshing process from the beginning) New in Version 6.0! The FLAC3D building block facility offers structured meshing and basic unstructured meshing capabilities. The FLAC3D extrusion tool (v 5.0 and up) is an interactive mesher that is easy to use to build linearly extruded geometries (e.g., tunnels) The FLAC3D extrusion tool and FLAC3D building block tools are interactive 3DEC built-in blocking capabilities allow for easy creation of extruded polygons and tunnels of any shape Tetrahedral meshing of convex blocks is done automatically in 3DEC 3D geometries can be created in 3DEC by specifying coordinates defining each face 3DEC can automatically convert tetrahedral zones into blocks for bonded-block modeling Build very complex 3D geometries in a few hours Flexibility and convenience of a fully interactive 3D-CAD system (Rhino) to build and modify the model’s geometry Parameterized mesh creation possible (Rhino VB or Python scripting knowledge required) Rhino CAD-system is intuitive and very easy to use Griddle (automatic mesher; NEW) BlockRanger (mapped mesher; Free update to V 1.2) Unstructured tetrahedral and hex-dominant meshing capabilities Griddle auto-meshing only requires surfaces of model as input (almost any volume shape is allowed) Excellent control over element sizes A must, if you are dealing with complex geometries All-hex (mapped meshes) inside hex-, prism-, tet-like solid shapes that are interactively constructed with Rhino to conform to your geometry —Cons— Usually more time consuming Requires experience to build complex meshes Usually requires subdividing the volumes to mesh into primitive shapes (can be very difficult for complex 3D geometries, sometimes leading to poor quality zones) The Building Block facility has limited CAD-system capabilities Cost associated with the purchase of an additional tool All-hex meshing not available in Griddle

Note: *A hex-dominant mesh is a mesh composed mostly of hexahedral elements but also wedge, pyramid, and tetrahedral elements where necessary to conform to the geometry.

References

Abbasi, B., D. Russell, and R. Taghavi (2013). “FLAC3D mesh and zone quality,” Continuum and Distinct Element Numerical Modeling in Geomechanics, Zhu, Detournay, Hart, and Nelson (eds.), Paper: 11-02, Itasca International Inc., Minneapolis, 12 pages, ISBN 978-0-9767577-3-3.

Wikipedia. "Mesh generation," accessed January 10, 2017. "https://en.wikipedia.org/wiki/Mesh_generation"

Wikipedia. "Principles of grid generation," accessed January 10, 2017. "https://en.wikipedia.org/wiki/Principles_of_grid_generation"

Wikipedia. "Types of mesh," accessed January 10, 2017. "https://en.wikipedia.org/wiki/Types_of_mesh"

Wikipedia. "Unstructured grid," accessed January 10, 2017. "https://en.wikipedia.org/wiki/Unstructured_grid"