MDF (Mesh Data File) is a data file format to store finite element mesh data.
An MDF file is a simple text file containing the definition of any
finite element mesh. Also a user can either implement himself another procedure to read his
finite element data or develop a simple program to convert his favorite mesh file structure to
an MDF file.
The main principle here is that any information in the file is contained in a line and is defined
by a keyword following the rules :
label |
Label of node (integer) |
x[1] |
First coordinate of node (real number) |
... |
... ... |
x[dim] |
dim-th coordinate of node (real number) |
nb_dof |
Number of d.o.f. associated to node (integer) |
code[1] |
Code associated to first d.o.f. (integer) |
... |
... ... |
code[nb_dof] |
Code associated to nb_dof-th d.o.f. (integer) |
shape |
String defining the element number (string) |
el |
Label of element (integer) |
nb_nod |
Number of element nodes (integer) |
code |
Code associated to element (integer) |
el_node[1] |
Label of first node of element (integer) |
... |
... ... |
el_nod[nb_nod] |
Label of nb_nod-th node of element (integer) |
The element shape is given by a string of at most 10 characters. This string must be recognized among the
stored element shapes in the library. In addition, there must be an concordance between the shape and the number
of nodes.
Shape |
Shape Name |
Dimension |
Min. Nb. of Nodes |
Line |
line | 2 | 2 |
Triangle |
tria | 2 | 3 |
Quadrilateral |
quad | 2 | 4 |
Tetrahedron |
tetra | 3 | 4 |
Hexahedron |
hexa | 3 | 8 |
shape |
String defining the side number (string) |
sd |
Label of side (integer) |
nb_nod |
Number of side nodes (integer) |
sd_node[1] |
Label of first node of side ( integer) |
... |
... ... |
sd_nod[nb_nod] |
Label of nb_dof-th node of side (integer) |
code[1] |
Code associated to first d.o.f. of side (integer) |
... |
... ... |
code[nb_nod] |
Code associated to nb_dof-th d.o.f. of side (integer) |
code |
code number (integer) |
mat_name |
Name of the material associated to code (string) |
The code number is a prescribed element code. If the material name is unknown (i.e. if it does
not occur among element codes) the program looks for a class that you have probably developed with this name.
The package contains a class called MyMaterial that gives an example of user defined material.
If no material is associated to an element code, the program associates to
this code a fictive material called GenericMaterial and whose
properties are all equal to unity.
c |
Code of degrees of freedom to which a value is to be associated (integer) |
v |
Value to prescribe (double) |
This method to introduce Dirichlet boundary conditions is much simpler than via a user defined class. But there are some limitations.