XLPack 7.0
XLPack Numerical Library (Excel VBA) Reference Manual
Loading...
Searching...
No Matches

◆ ReadMsh3()

Sub ReadMsh3 ( FName As  String,
N As  Long,
X() As  Double,
Y() As  Double,
Z() As  Double,
Lp() As  Long,
Ne As  Long,
Kc() As  Long,
Le() As  Long,
Nb As  Long,
Ks() As long  ,
Lb() As  Long,
Info As  Long 
)

Read FEM mesh information from FreeFEM++ msh (3D) file [Experimental version]

Purpose
Read FEM mesh information from the file in FreeFEM++ msh (3D) format.
Parameters
[in]FnameInput file name.
[out]NNumber 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]Lp()Array Lp(LLp - 1) (LLp >= N) Label of each node.
[out]NeNumber of elements.
[out]Kc()Array Kc(LKc1 - 1, LKc2 - 1) (LKc1 >= 5, LKc2 >= Ne)
Connection matrix: Kc(0, K-1) is the type of K-th element, Kc(1, K-1), ..., Kc(4, K-1) point to the nodes of K-th element.
The type of element value is as follows:
= 4: 4-node tetrahedron.
[out]Le()Array Le(LLe - 1) (LLe >= Ne)
Label numbers of the elements.
[out]NbNumber of elements defining boundaries.
[out]Ks()Array Ks(LKs1 - 1, LKs2 - 1) (LKs1 >= 4, LKs2 >= Nb)
Connection matrix for the boundary elements: Ks(0, K-1) is the type of K-th element, Ks(1, K-1), ..., Ks(3, K-1) point to the nodes of K-th element.
The type of element value is as follows:
= 2: 3-node triangle.
[out]Lb()Array Lb(LLb - 1) (LLb >= Nb)
Label numbers of the boundary sides.
[out]InfoReturn 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.
= 16: Unexpected end of file.