TET_MESH_Q2L 10-Node Tet Mesh to 4-Node Tet Mesh

TET_MESH_Q2L is a FORTRAN90 program which reads information describing a tet mesh of a set of points using 10-node ("quadratic") triangles, and creates a 4-node ("linear") tet mesh.

The same nodes are used, but each 10-node tetrahedron is broken up into 8 smaller 4-node tetrahedrons.

Usage:

tet_mesh_q2l prefix
where prefix is the common file prefix:
• prefix_nodes.txt, the node coordinates (not needed by this program);
• prefix_elements.txt, the element definitions.
• prefix_q2l_elements.txt, the linear element definitions created by this program, and based on the same set of nodes.

The input and output files use the simple TABLE format; comment lines begin with a "#" character. Otherwise, each line of the file contains one set of information, either the coordinates of a node (for a node file), or the indices of nodes that make up a tetrahedron, (for a tetrahedron file).

The input file tetras.txt contains the tetrahedron information for the 10-node tet mesh. Each line contains the indices of 10 nodes that form a tetrahedron, in a particular order. The first 4 indices are the vertices. Subsequent nodes can be described by the pair of vertices they lie between, as follows:

```        1  2  3  4  (1+2)  (1+3)  (1+4)  (2+3)  (2+4)  (3+4)
```

The output file tetras.l2q.txt contains the tetrahedron information for the 4-node tet mesh.

Languages:

TET_MESH_Q2L is available in a C++ version and a FORTRAN90 version and a MATLAB version.

Related Programs:

CVT_TET_MESH, a FORTRAN90 library which uses CVT methods to compute a tet mesh in a region.

GEOMPACK, a FORTRAN90 library which contains a routine DTRIS3 that can compute the tet mesh for a set of 3D points, as well as the adjacency information.

TABLE_TET_MESH, a FORTRAN90 program which can compute the tet mesh for a given set of points.

TEST_TET_MESH, a FORTRAN90 library which defines a few test regions for the generation of a tet mesh.

TET_MESH, a FORTRAN90 library which includes a variety of routines for working with tetrahedral meshes.

TET_MESH_DISPLAY, a MATLAB program which reads the node and tetra files defining a tet mesh and displays a wireframe image.

TET_MESH_DISPLAY_OPENGL, a C++ program which reads a tet mesh and displays the nodes and edges using OpenGL.

TET_MESH_L2Q, a FORTRAN90 program which takes a 4-node tet mesh and makes a 10-node tet mesh, by inserting new nodes.

TET_MESH_ORDER4, a directory which contains a description and examples of a tet mesh using order 4 elements.

TET_MESH_ORDER10, a directory which contains a description and examples of a tet mesh using order 10 elements.

TET_MESH_QUALITY, a FORTRAN90 program which computes the "quality" of a mesh.

TET_MESH_RCM, a FORTRAN90 program which takes a 4-node or 10-node tet mesh and relabels the nodes to reduce the bandwidth of the corresponding adjacency matrix.

TET_MESH_REFINE, a FORTRAN90 program which can refine a tet mesh.

TET_MESH_TET_NEIGHBORS, a FORTRAN90 program which computes the tetrahedral adjacency information.

TET_MESH_VOLUMES, a FORTRAN90 program which computes the volume of each tetrahedron in a tet mesh;

TETRAHEDRON_PROPERTIES, a FORTRAN90 program which computes properties of a given tetrahedron.

TETRAHEDRONS, a dataset directory which contains examples of tetrahedrons;

Reference:

1. Herbert Edelsbrunner,
Geometry and Topology for Mesh Generation,
Cambridge, 2001,
ISBN: 0-521-79309-2,
LC: QA377.E36.
2. Barry Joe,
GEOMPACK - a software package for the generation of meshes using geometric algorithms,
Volume 13, 1991, pages 325-331.
3. Anwei Liu, Barry Joe,
Quality Local Refinement of Tetrahedral Meshes Based on 8-Subtetrahedron Subdivision,
Mathematics of Computation,
Volume 65, Number 215, July 1996, pages 1183-1200.
A Simple Mesh Generator in MATLAB,
SIAM Review,
Volume 46, Number 2, June 2004, pages 329-345.

Examples and Tests:

You may copy data for an example problem:

List of Routines:

• MAIN is the main program for TET_MESH_Q2L.
• CH_CAP capitalizes a single character.
• CH_EQI is a case insensitive comparison of two characters for equality.
• CH_TO_DIGIT returns the integer value of a base 10 digit.
• FILE_COLUMN_COUNT counts the number of columns in the first line of a file.
• FILE_ROW_COUNT counts the number of row records in a file.
• GET_UNIT returns a free FORTRAN unit number.
• I4MAT_TRANSPOSE_PRINT_SOME prints some of the transpose of an I4MAT.
• I4MAT_WRITE writes an I4MAT file.
• S_INDEX_LAST finds the LAST occurrence of a given substring.
• S_TO_I4 reads an I4 from a string.
• S_TO_I4VEC reads an I4VEC from a string.
• S_WORD_COUNT counts the number of "words" in a string.
• TET_MESH_ORDER10_TO_ORDER4_COMPUTE linearizes a quadratic tet mesh.
• TET_MESH_ORDER10_TO_ORDER4_SIZE sizes a linear tet mesh from a quadratic one.
• TIMESTAMP prints the current YMDHMS date as a time stamp.

You can go up one level to the FORTRAN90 source codes.

Last revised on 30 September 2009.