Vous êtes sur la page 1sur 17

Creating a Tria Mesh for Tetrameshing - HM-3190

For this tutorial, it is recommended that you complete the introductory tutorial, Getting Started with
HyperMesh - HM-1000. Familiarity with the geom cleanup, automesh, and check elems panels is also
useful, although not required.
Whether they are required for a specific type of application, or simply utilized because it is not possible to
easily generate hexahedral elements, tetrahedral elements are often used to model solid parts.
HyperMesh provides an automatic (standard) tetramesher that fills a volume enclosed by shell elements
with tetrahedral elements. In this process, the quality of the resulting tetrahedral mesh is directly
dependent on the quality of the surface mesh with which it starts. While HyperMesh also provides a
tetramesher capable of filling a volume defined by surfaces alone, this volume tetramesher is not
discussed in this tutorial.
In this tutorial, you will learn about the pre-requisites of the standard tetramesher, as well as work through
the process of creating a shell mesh that meets the requirements for generating a quality tetramesh.
In this tutorial, load a file containing the model geometry. Using the geometry cleanup tools, suppress
some of the shared surface edges to eliminate slender surfaces, problematic shapes, and small surface
edges. Use the interactive mode of the automesher to generate a surface mesh of tria elements, then
use the element checks to identify any problem areas. Problem areas can be corrected using
element-editing tools. Finally, once a quality, continuous surface mesh is achieved, generate the
tetrahedral elements using the standard tetramesher.
For detailed information on the panels used in this tutorial, please refer to the Panels section of the
on-line help, or click the help button while in the panel to bring up its context sensitive help.
This tutorial requires about 40 minutes to complete and uses a file located in the
<install_directory>/tutorials/hm directory. If you are unable to locate this directory at your
site, see Finding the Installation Directory <install_directory>, or contact your systems administrator.

The model geometry for this tutorial is as follows:

Model geometry

To understand the tetramesher pre-requisites and the tetramesh process:

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


The standard tetramesher produces tetrahedral elements from a 2-D shell mesh. This shell mesh may
contain both triangular and quadrilateral elements. While the tria elements are used to generate the faces
of tetrahedral elements, the quad elements are first divided into two tria faces before being used for the
underlying tetra elements. Both first order and second order 2-D meshes can be used to produce either
first or second order tetra elements.
To grow a tetramesh, the source 2-D mesh needs to enclose a volume, and only one single volume can
be tetrameshed at a time. This means that the 2-D mesh supplied needs to be continuous (there cannot
be any free edges), and the elements supplied form only one volume (there cannot be any
T-connections). When multiple volumes need to be tetrameshed, each volume needs to be submitted
separately.
When creating tetra elements from shell elements, the quality of the resulting tetra elements is directly
dependent on the quality of the shell elements. It is important to ensure that for the shell mesh:

• There are no duplicates.

• No elements fold on one another.

• Elements do not overlap.

• The minimum tria angle is not too low.

• The difference in size between adjacent elements and elements across a wall is minimal.
Given these considerations, most of the time spent tetrameshing a part using the standard tetramesher is
spent on geometry cleanup and creating a quality 2-D mesh. The general tetramesh process can be
summarized in the following steps:

• Import the geometry and prepare for meshing (geometry cleanup).

• Generate the surface mesh of plate elements.

• Check the quality and continuity of the shell mesh.

• Perform any editing on the shell mesh for quality improvement (as needed).

• Generate the tetra elements in the tetramesh panel.

• Delete the shell elements, and check the quality of the tetra mesh.
This is the process and the pre-requisites we will follow in this tutorial.

To load the geometry and determine the element size:

In this section, retrieve the geometry for the part to tetramesh. Then determine the element size to use
for the shell mesh based on the geometry. While at least two layers of elements are required across the
thinnest walls, too small of an element size may generate too many unneeded elements.

1. From the files panel, retrieve the file <install_directory>/tutorials/hm/ standard_


tetra.hm.

2. From the Disp page of the macro menu, set Vis opts: 3 to shade the surfaces in the model.
The model is a symmetric part of a solid bracket for which a hexa mesh would be very difficult to
create.

3. Use the view panel from the permanent menu to restore View1.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


This area of the model presents some of the narrowest portions of the solid part. When tetrameshing
this location, we need to ensure that we create at least two layers of solid elements.

4. Use the length panel to measure the length of the various edges defining these areas.

- From the Geom page, select the length panel.

- With the lines selector active, pick one of the edges from the graphics area (see figure below).

- Click length.

- The length displays in the length = field.

- Click reset under lines, and repeat the above steps for any other edge to measure.

Edges to measure
Most of these edges are between 5 and 10 units long. These would probably require an element
size of around 5 units. While this would allow us to achieve the goal of two layers of elements in
these areas, it would produce too refined a mesh in the rest of the model, and produce more
elements than necessary. An increased number of trias would produce more tetras, and increase
the number of degrees of freedom of the model, requiring more computation time.
For this model, we will use an element size of 10 units. With this size, we will simply make sure to
manually increase the density of elements where needed, while still avoiding too great of a size
difference between neighboring elements.

5. From the global panel on the permanent menu, set element size = to 10.0.

In this section, we loaded the geometry to tetramesh and chose an element size for the tria and tetra
elements to create based on the dimensions present in the geometry.

To clean up the geometry:

To ensure that the shell mesh we create on the surfaces encloses a volume, we can first make sure that
the surface themselves enclose a volume. This is done by cleaning up the geometry, and making sure
that there are no free (red) edges left in the model. Additionally, we may want to suppress shared (green)
edges to avoid creating elements of poor quality based on the element size we picked in the previous
section.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


In this section, start by equivalencing any free (red) edges in the model into shared (green) edges to
ensure that the surfaces are attached to one another. Then suppress any shared edges that are not
needed or would produce poor quality elements. Use the geom cleanup and automesh panels to
identify and correct the areas requiring cleanup.

1. Use the geom cleanup panel to equivalence free edges into shared edges.

- From the Geom page, select the geom cleanup panel.

- Select the edges sub-panel and select the equivalence function.

- Click surfs and select displayed.

- Verify the box for equiv free edges only is checked.

- Set cleanup tol = to 0.01.

- Click equivalence.
Notice how some free (red) edges turn green (shared) while others remain red. This is because
of the tolerance (maximum distance between neighboring free edges to be equivalenced) we set.
- Repeat the steps above with a tolerance of 0.1.

All the red edges turn green.

Note For more information on the display of surface edges in HyperMesh and geometry
cleanup, click the help button and review the on-line help for the geom cleanup panel
as well as the HyperMesh Geometry Terminology topic.

The next step is to identify and suppress shared edges, which separate surfaces with a continuous
curvature. This is often subjective as the angle between the surfaces defines how continuous the
curvature is, and whether the edge should be suppressed or not. In general, edges capturing an
angle of up to 30 degrees between surfaces can be suppressed.

2. Use the toggle function to toggle shared edges (green) into suppressed edges (blue).

- From the geom cleanup panel, select the edges sub-panel.

- Select the toggle function.

- Leave cleanup tol = unchanged.

- With the line selector active, pick in the graphics region any shared (green) edge you want to
suppress (see figures below).

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Edges to suppress

Note While suppressing some edges creates larger and more logical areas, it is often just as
desirable to limit the size of some areas so as to conserve additional control on the resulting
mesh.
The next step is to suppress any shared edges that would produce elements of poor quality. When
meshing surfaces, HyperMesh forces nodes on all shared and free surface edges, and also at all
fixed point locations. When shared edges define areas with dimensions close to the element size,
this creates the potential for elements of poor quality.

3. Using the view panel, restore View2.

4. Use the toggle function to suppress additional shared edges (see image below).

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Suppressed edges
While some of these situations can be corrected by looking at the geometry, you may not always
find all of these situations with this approach alone. For a larger model, it may not always be
practical to spend large amounts of time trying to identify these features on the geometry. One
alternative is to preview a mesh on surfaces and look for any edge element density that reads 1.
Such a density is an indication that the edge is less than the element size, which is often a cause for
quality issues.

5. From the Disp page of the macro menu, set Vis opts: 0 and Gfx: Per.

6. Use the automesh panel to preview a tria mesh on the surfaces.

- From the 2D page, select the automesh panel.

- Select the create mesh sub-panel.

- Click surfs and select displayed.

- Check the box for reset meshing parameters to:.

- Set the type of elements to trias.

- Verify elem size = is set to 10.

- Set the mode to interactive and click mesh.

- Click mesh to preview the mesh.

- Do not return out of the automesh secondary panel.


Observe the model and look for any edge density set to 1.

7. Use the view panel to restore View3.


Observe the node densities set to 1, and use the view manipulation tools to understand what
causes these densities.

8. Use the view panel to restore View4.


Observe element densities set to 1 in this area as well.

9. In the automesh secondary menu, click abort to return out of the menu without accepting a mesh.

10. Use the cleanup sub-panel of the automesh panel to toggle any shared edge identified from the

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


mesh preview.

- From the automesh panel, select the cleanup sub-panel.

- Click vis opts and set the toggle to shaded.

- Click line next to toggle: to make it active.

- Toggle shared edges from the views View3 and View4 (see figures below).

Suppressed edges

Notes In the figure above, you can see that one of the densities of 1 was the result of fixed points
distant by less than the element size. This is another common cause for distorted elements.
While one approach consists in removing unneeded fixed points, it is not possible to do this
here are both these fixed points are required by the edges they belong to. To remove the
fixed points, we would need to suppress the edges they belong to first and this is not
desirable here.
While cleaning up the geometry helps avoid some of the poor quality elements, it is not
desirable to spend extensive time trying to fix the geometry. One alternative is to simply fix
bad elements once they have been generated. While for some situations it is easier to
clean-up the geometry, for others, it is better to fix elements after the fact.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


In this section, we performed some cleanup operations on the geometry to simplify it and also avoid
creating some poor quality elements. We used various approaches to identify edges to suppress and
also various tools to carry out the operations.

To generate the tria mesh:

In this section, generate the tria mesh on the surfaces using the automesh panel. Use various tools from
the automesh secondary panel to create a tria mesh of a quality that meets the following requirements:

• At least two tria elements are created across the smallest surfaces.

• Mesh patterns capture the curvature of the surfaces.

1. Fit the model to the screen using the f key on your keyboard.

2. Use the automesh panel to generate the tria mesh according to the requirements.

- From the 2D page, select the automesh panel.

- Select the create sub-panel.

- Set vis opts to wireframe.

- Click surfs and select displayed.

- Verify the box for reset meshing parameters to: is checked, elem size = is set to 10 and the
type of element is trias.

- Set the middle lower toggle to elements to current comp to send the elements to the trias
component.

- Click mesh to enter the automesh secondary panel, and click mesh to preview the mesh.

Note If you have difficulties performing any of the steps described, click help to review the
on-line help for this panel.

- Use the view panel to restore View1.


Observe how only one layer of elements is generated across the smallest three features.

- Use the density sub-panel to adjust edge to 2 elements for these four features.

- Click mesh to preview the changes (see figure below)

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Densities updated to two layers of elements
Observe how the mesh patterns on these surfaces is not very regular. To resolve this, R-trias
can be generated on these surfaces instead.

- Select the type sub-panel.


As you enter this sub-panel, edge densities are turned off and icons are placed at the center of
each surface to signify the type of element with which the surface is meshed.

- Set element type: to R-trias using the switch.

- With set surf active, click the center icon for the three sliver surfaces until it changes to a right
angle tria.

- Click mesh to preview the changes to the mesh on these three surfaces.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Mesh using R-trias
The first requirement for creating at least two layers of trias on the smallest features of the solid
has been met. We can now make sure that quality mesh patterns are obtained in all areas
capturing the curvature.

- Use the view panel and restore View5.

Mesh pattern does not capture curvature


Observe the mesh pattern in the through hole and how the mesh does not seem regular. This
can be resolved by first making sure that densities match across the through hole, and then by
setting the type of element on this surface to R-trias.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Note Edge densities do not match because the lengths of the two edges are different.

Hint From the automesh panel, create mesh sub-panel, select the link edge densities
option to ensure that opposite edges of surfaces have the same densities when they are
comparable in length.
Using this option would have saved us from having to manually change the densities in
this case.

- Use the density sub-panel to set both element densities to 10.

- Click mesh to preview the new mesh.

- Use the type sub-panel to set the type of elements on this surface to R-trias.

- Click mesh to preview the new mesh.

Regular mesh pattern conforming to surface curvature


- Repeat this same approach for the remaining through holes.

- When you are satisfied with the mesh, click return to accept it.

In this section, we used the automesh panel and several of its options to obtain the mesh that would
meet both of our requirements.

To evaluate and correct element quality:

In the previous sections, we cleaned up the geometry as much as possible to avoid creating poor quality
elements. Now that the tria mesh has been created, we need to perform a battery of quality checks to
make sure it suitable to generate tetra elements.

In this section, use the check elems panel to check for duplicates and review the quality of the 2-D mesh
against the following quality criteria:

• Min length: 3

• Aspect: 5

• Trias - Min angle: 20


These criteria are typically most important when it comes to generating tetra elements, as poor tria
elements for these checks will typically yield poor tetra elements.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


1. Use the check elems panel to check for duplicates.

- From the Tool page, select the check elems panel.

- Select the 2-d sub-panel.

- Click duplicates.

The header bar should read 0 duplicate elements were found.

Note Should you find duplicates in your mesh, use the save failed option to save these
elements to a user mark. Then, select elements and use the retrieve extended entity
selection option to select these elements in the delete panel and delete them.

2. Use the check elems panel to evaluate the mesh against the quality criteria listed earlier.

- In the check elems panel, 2-d sub-panel, set the values for aspect, length and trias: min angle.

- Click aspect.
The header bar reports how many elements fail this check, what percentage of the elements it is,
and what is the maximum aspect ratio found. The elements failing the check are highlighted in
the graphics area.

- Click length.
The header bar reports again how the mesh fares against this check.

- Click min angle under trias.


Visually identifying the elements that fail specific checks is not necessarily easy from the elements
simply being highlighted. One technique is to save these elements that fail on a user mark, then
limit the display of elements in the model to these failing elements using the mask panel.

3. Check the elements against the length check and place them in a user mark.

- Click length in the check elems panel.

- Click save failed.

4. Use the mask panel to turn off all other elements.

- From the Tool page, select the mask panel

- Select the mask sub-panel.

- Set the entity selector to elems.

- Click elems and select retrieve.


This loads the elements that were placed on the user mark.

- Click elems and select reverse.

- Click mask.

5. Use the Disp page of the macro menu and select Geom: Off to turn off the geometry.

6. Fill the display to the screen using f on your keyboard.


You can now see the elements that fail the length check.

7. Use the Find Attached macro from the QA page of the macro menu to turn back on one layer of

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


elements surrounding the elements displayed.
Bringing back layers of elements helps determine in which area the failing elements are located as
well as devise plans for resolving the problems.

8. Return to the check elems panel and click length again to highlight the failing elements.
Elements may fail in various areas of the model. Here is one example in the figure below:

In most cases, to resolve this issue, you can delete these elements and close the gaps by
equivalencing the nodes across the gap with the replace panel.

9. Use F2 to go to the delete panel and delete the elements failing the length check (see figure above).

10. Use F3 to go to the replace panel and equivalence nodes.

- Verify that the box for equivalence is checked.

- With the node selector next to replace: active, select the node to move.

- With the node selector next to with: active, select the node to replace it with.
11. Repeat steps 9 and 10 until all elements failing the length check have been resolved.

12. Use the mask panel (F5) to unmask all.

13. Use the check elems panel (F10) to verify that no more elements fail the length check.

14. Use the check elems panel to check for elements failing the aspect check.
In many cases, elements that fail the length check will also fail the aspect check and vice versa. If
you have elements failing the aspect ratio, use the same technique to delete them and close open
gaps.

15. Use the check elems panel to check for elements failing the min angle check.
At this point, there should be very few elements failing this check with a minimum angle found close
to 20 degrees. We will accept these elements as they are.

Hints To check the actual values for an element for the various quality checks, simply click on
the element in the check elems panel. A dialog is displayed and disappears the next
time you do a left mouse click. If the element is close to the requirements, it is often
better to accept it as it is.
To resolve issues with elements failing the min angle check, use the same technique as

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


described for the length check, or simply delete the elements and re-create some by
hand using the edit element panel from the 2D page.

Notes It may not always be possible to apply either technique and sometimes you need to leave
some elements as they are. It is all a function of what the minimum angle is.
In general, when all other quality requirements are met, the tetramesher succeeds in
generating tetra elements when the min angle is above 20 degrees. The rate of success
is good with a min angle between 10 and 20 degrees. With a min angle of less than 10
degrees, it will sometimes fail. With a min angle less than 5 degrees, there is a good
chance it will fail.
In this section we checked the quality of our tria mesh and used some element editing tools to ensure
that the elements would satisfy some quality criteria.

To check for free edges and T-connections:

The next step in the process is to make sure that the elements enclose a volume (no discontinuities in
the mesh representing a volume), and that the elements, in our example, form only one volume.

In this section, use the edges panel to check for free edges in the model as well as T-connections. While
free edges are edges that are not shared between elements and therefore are an indication that the
mesh is discontinuous, T-connections are edges that are shared by more than two elements. When
T-connections exist, it means that multiple volumes may be present.

1. Use the edges panel to check for free edges.

- From the Tool page, select the edges panel.

- With the entity selector set to comps, pick any tria elements from the graphics region.
The element highlights briefly to signify the component has been selected.

- Leave tolerance = unchanged as it has no bearing on finding free edges.

- Set the toggle next to find: to free edges.

- Click find edges.


HyperMesh posts a message in the header with the number of free edges found. A temporary
component collector called ^edges is also created with plot elements created at the location of
free edges.

2. Use the disp panel from the permanent menu to turn off all elements except the ones in the ^edges
component.

3. Use the Find Attached macro several times to display elements in this region and understand the
situation.

4. Use the Geom: On and Vis opts: 0 options from the Disp page of the macro menu to turn back on
the geometry in the default mode.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Checking for free edges
In this case it looks as if an inner surface existed in the model and was meshed by mistake causing
the mesh to be discontinuous throughout.
This is a situation where we also find T-connected elements. Check for T-connections to confirm this.

5. Use the edges panel to check for T-connections.

- From the Tool page, select the edges panel.

- With the entity selector set to comps, pick any tria elements from the graphics region.

- Set the toggle next to find: to T-connections.

- Click find edges.

Checking for T-connections


Both issues of free edges and T-connections can be resolved here by simply deleting these extra
elements from the model.

Notes In general, free edges are a sign of discontinuity in the mesh, which is resolved by
performing an equivalence function on the edges panel. For more details on this
procedure, click help to bring up the edges panel on-line help.
Unless there is a clear need for T-connected elements (as is the case when you check a
mesh that defines multiple volumes), this situation is typically resolved by deleting the
unwanted elements.

6. Use the delete panel to delete the extra elements by face.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


- Use the F2 function key to access the delete panel.

- With the type of entity set to elems, pick one of the elements to delete in the graphics window.

- Click elems and select by face.

- Click delete entity.

7. Use the mask panel to unmask all elements.

8. From the edges panel, check for free edges and T-connections.

The header bar should now tell you that No edges were found. Selected elements may enclose a
volume and No T-connected edges were found.
The model is now ready for tetramesh generation.

To generate the tetra mesh and check its quality:

The tetramesh panel from the 3D page contains several sub-panels. Refer to the on-line help for detailed
information on these functions. In this section, use the tetra mesh sub-panel to generate a mesh of tetra
elements in the volume we defined using tria elements. Then check the quality of the tetra elements
against the tetra collapse tet collapse, tetra aspect ratio tetra AR, and volume skew vol skew checks.

1. Use the global panel to set the current component collector to tetras.
This component collector was pre-defined to store the tetra elements.

2. Use the tetra mesh sub-panel of the tetramesh panel to generate the tetras.

- From the 3D page select the tetramesh panel.

- Select the tetra mesh sub-panel.

- With the comps selector under floatable trias/quads: active, select one of the tria elements
from the graphics region.

- Set the options to generate mesh normally and standard using the corresponding switches.

- Click tetmesh.

Notes When defining the trias/quads as floatable, you allow HyperMesh to create underlying
tetras for which the outer faces do not line up with the trias, although using the same
nodes. With the fixed option, the faces of the underlying tetra are forced to match the tria
elements. This leaves less flexibility to create higher quality tetras but is useful when
trying to match tetra meshes between multiple volume.
Several options are available for the creation of the tetras. Refer to the on-line help for a
complete description.

3. Use the disp panel to turn off the display of the trias and the geometry.

4. Use the mask panel to temporarily mask, by window, some of the elements and review the inside of
the model.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com


Tetramesh

5. Delete the components that are no longer needed: trias and lvl2.

6. Use the check elems panel to check the quality of the tetramesh.

- From the Tool page, select the check elems panel.

- Select the 3-d sub-panel.

- Check the tetras against a tet collapse of 0.3.

The header bar displays the corresponding statistics.

- Check the tetras against a vol skew of 0.6.

- Check the tetras against a tetra AR of 5.0.

Note For a definition of these checks, see the on-line help for the check elems panel.

Overall, the mesh is of good quality as only a marginal number of elements failed our checks. These
elements could be isolated using the same approach that was used with the tria elements (save failed,
mask panel, Find Attached macro).
In order to improve the quality of tetra elements, you can either remesh clusters of elements using the
remesh sub-panel of the tetramesh panel, or go back to the tria mesh and improve its quality to obtain
better tetra elements.
This concludes this tutorial. You may discard this model, or save it to your working directory for your own
reference.
In this tutorial, the tetrameshing process was presented and followed for a bracket. We experimented
with ways to correct the geometry, create a quality pattern mesh, and correct poor quality elements. We
checked for free edges and T-connections to complete the pre-requisites and we created the tetra mesh.

For more details on the tetramesh panel, refer to the tutorials Generating 3-D Tetrahedral Elements -
HM-3210 and Tetrameshing a Volume in a Single Step - HM-3230. If you want to learn more about
geometry cleanup, refer to Fixing Geometry for Meshing - HM-2020. If you more information regarding
checking and improving the quality of 2-D elements, refer to the tutorials Measuring and Improving 2-D
Mesh Quality using a Quality Index - HM-3320 and Troubleshooting 2-D Mesh Quality Issues Manually -
HM-3330.

See HyperMesh Tutorials for a complete list of tutorials.

PDF created with FinePrint pdfFactory Pro trial version http://www.pdffactory.com

Vous aimerez peut-être aussi