
Hi Ryan,
Ondrej gave you some answers already, but to clarify more...
Ryan Krauss wrote:
I am trying to create a .mesh file as an input to SfePy, and all the links I can find for it in google are broken, for example: http://www-rocq.inria.fr/gamma/medit
http://www.ann.jussieu.fr/~frey/logiciels/medit.html
Unfortunately it is in French...
Looking at simple.mesh, the format seems fairly straight forward. After a couple of header lines, it seems to contain coordinates of vertices. I assume this are X Y Z, but I don't understand the 4th column which is always 0. Then there are a bunch of lines describing tetrahedrons. I assume these are being described based on numbers assigned to vertices. But again there is an extra final column I don't understand. One tetrahedron row seems to contain 4 vertices and then the number 6. What does the 6 represent?
The extra column after the vertices enables you to assign a vertex to some vertex-related subdomain. In SfePy, it is not used, but medit needs it, so we use zero.
The extra column after the element nodes defines a group to which the element belongs. This is used in SfePy, for example, to define regions for equations, boundary conditions, etc. I use it often to assign different material properties to subdomains.
So, I am slightly stuck. Can anyone direct me to documentation on .mesh files? Also, are there free utilities or Python scripts for generating them? I don't want to reinvent the wheel and might go a little crazy trying to visualize too many tetrahedra. I don't want to reinvent the wheel.
You can use also the text (legacy) VTK files to define your meshes, see www.vtk.org/pdf/file-formats.pdf, page 9.
cheers, r.