3D MESH CHECKER
CALL SEQUENCE
void tcheck_mesh3D (mesh, epsillon, status)
INPUT PARAMETERS
Tmesh3D *mesh;
Pfloat epsilon;
OUTPUT PARAMETERS
Pint *status;
ARGUMENTS
- mesh
- 3D mesh
- epsilon
- Threshold to compare two float values
- status
- Error status.
EFFECT
This utility function checks if a mesh is compliant to PHIGURE mesh
specifications. Parallelepipedic, hexahedral, cylindrical and sperical meshes
may be checked with this function. This function reports check status and error
message(s) explaining error(s) encountered in the mesh. Error messages are
output to standard PHIGURE error message file (see topen_phigure)
If the mesh is not compliant status is 0, else 1.
epsilon is useful to compare two floating point values. Two floating
point values are equal if the absolute value of their difference is less than
epsilon.
Warning: for mesh of hexahedrons, checker supposes that all vertices of a
hexahedron face belong to the same plane. If not checker result is
meaningless.
This function does not check meshes with the following types:
TNS_MESH_OF_HEXAEDRONS
TNS_MESH_OF_TETRAEDRONS
TNS_MESH_NON_HOMO_3D
Following tests are performed:
- parallelepipedic mesh : TPARALLELEPIPEDIC_MESH
- num_x > 1, num_y > 1 and num_z > 1
- x list is strictly increasing or decreasing
- y list is strictly increasing or decreasing
- z list is strictly increasing or decreasing
- Hexahedral mesh : THEXAEDRAL_MESH
- num_x > 1, num_y > 1 and num_z > 1
- Check that the six faces do not self intersect and do not intersect with
other faces of the mesh
- cylindrical mesh : TCYLINDRICAL_MESH
- num_r > 1, num_z > 1 and num_p > 1
- r list is strictly increasing
- z list is strictly increasing or decreasing
- p list is strictly increasing or decreasing
- p[num_p-1] - p[0] < 2[pi] or p[0] - p[num_p-1] <2
[pi]
- spherical mesh : TSPHERICAL_MESH
- num_r > 1, num_p > 1 and num_t > 1
- r list is strictly increasing
- p list is strictly increasing or decreasing
- t list is strictly increasing or decreasing
- p[num_p-1] - p[0] < 2[pi] or p[0] - p[num_p-1]
<2[pi]
- 0 < t[i] < [pi] for all i < num_t