1. Description
The MSH extension is a mesh format associated with FreeFemm++ software, a multiphysics non linear solver. You can find the description of this format and a lot of information about this software in the FreeFemm++ manual.
2. Features supported by FEconv
FEconv supports the reading and writing of 2D and 3D FreeFem++ MSH files.
3. Data structure
The FreeFem++ MSH is a simple format that contains vertices, edges and triangles for a 2D mesh or vertices, triangles and tetrahedrons for a 3D mesh.
In the 3D MSH file structure, nver
denotes de number of vertices, nel
the number o tetrahedra and ntri
the number of triangles. Following this numbers you will found the vertices, tetrahedrons an triangles information.
The data for defining each vertex contains the 3 coordinates (Cn
)and a vertex label (VL
):
C1 C2 C3 VL
The data for each tetrahedron contains the 4 node labels (Nn
) and a region label (RL
):
N1 N2 N3 N4 RL
The data for each triangle contains the 3 node labels (Nn
) and a boundary label (BL
):
N1 N2 N3 BL
Here you can see a complete example:
69 224 35 0.000000000000000E+000 0.000000000000000E+000 0.000000000000000E+000 0 0.000000000000000E+000 1.00000000000000 0.000000000000000E+000 0 1.00000000000000 1.00000000000000 0.000000000000000E+000 1 1.00000000000000 0.000000000000000E+000 0.000000000000000E+000 1 ... 11 9 10 1 1 1 12 10 11 1 12 13 10 11 2 13 16 14 10 2 ... 65 66 67 3 65 66 69 3 66 64 62 0 67 69 68 0 ...