|
|
◆ ReadGmsh22()
| Sub ReadGmsh22 |
( |
FName As |
String, |
|
|
N As |
Long, |
|
|
X() As |
Double, |
|
|
Y() As |
Double, |
|
|
Z() As |
Double, |
|
|
Ne As |
Long, |
|
|
Kc() As |
Long, |
|
|
Lb() As |
Long, |
|
|
Info As |
Long |
|
) |
| |
Read FEM mesh information from Gmsh file (Version 2.2) [Experimental version]
- Purpose
- Read FEM mesh information from the file in Gmsh format (Version 2.2).
- Only $MeshFormat, $Nodes and $Elements sections are to be read. Other sections will be skipped.
- In the $Elements section, the element information defining boundaries (e.g. line for 2D, triangle for 3D) are included as well as those defining FEM space (e.g. triangle for 2D, tetrahenron for 3D).
- In $Nodes and $Elements sections, node numbers and element numbers must be continuous numbers, i.e. 1 to n and 1 to ne, respectively, and must not be duplicated. However, they need not be ordered.
- Parameters
-
| [in] | Fname | Input file name. |
| [out] | N | Number of points. |
| [out] | X() | Array X(LX - 1) (LX >= N)
X coordinates of points. |
| [out] | Y() | Array Y(LY - 1) (LY >= N)
Y coordinates of points. |
| [out] | Z() | Array Z(LZ - 1) (LZ >= N)
Z coordinates of points. |
| [out] | Ne | Number of elements (including elements for boundary). |
| [out] | Kc() | Array Kc(LKc1 - 1, LKc2 - 1) (LKc1 >= Nn + 1, LKc2 >= Ne)
Connection matrix: Kc(0, K-1) is the type of K-th element, Kc(1, K-1), ..., Kc(Nn, K-1) point to the nodes of K-th element (Nn is the number of nodes in the element).
The type of element value is as follows:
= 1: 2-node line.
= 2: 3-node triangle.
= 3: 4-node quadrangle.
= 4: 4-node tetrahedron.
= 5: 8-node hexahedron.
= 6: 6-node prism.
= 7: 5-node pyramid.
= 8: 3-node second order line.
= 10: 9-node second order quadrangle.
= 11: 10-node second order tetrahedron.
= 12: 27-node second order hexahedron.
= 13: 18-node second order prism.
= 14: 14-node second order pyramid.
= 15: 1-node point.
= 16: 8-node second order quadrangle.
= 17: 20-node second order hexahedron.
= 18: 15-node second order prism.
= 19: 13-node second order pyramid.
= 20: 9-node third order incomplete triangle.
= 21: 10-node third order triangle.
= 22: 12-node fourth order incomplete triangle.
= 23: 15-node fourth order triangle.
= 24: 15-node fifth order incomplete triangle.
= 25: 21-node fifth order complete triangle.
= 26: 4-node third order edge.
= 28: 6-node fifth order edge.
= 29: 20-node third order tetrahedron.
= 30: 35-node fourth order tetrahedron.
= 31: 56-node fifth order tetrahedron.
= 92: 64-node third order hexahedron.
= 93: 125-node fourth order hexahedron. |
| [out] | Lb() | Array Lb(LLb1 - 1, LLb2 - 1) (LLb1 >= Nlb, LLb2 >= Ne)
Label numbers of the elements: Lb(0, K-1) is the number of labels for element K (= Nlb), Lb(1, K-1), ..., Lb(Nlb, K-1) are the labels for the element K.
|
| [out] | Info | Return code.
= 0: Normal return.
= i < 0: The (-i)-th argument is invalid or has an illegal value.
= 11: File open error.
= 13: Data format error.
= 14: Data value error.
= 15: Section sequence error.
= 16: Unexpected end of file. |
|