Mesh generation software used with Elmer

Elmer software suite does not include proper mesh generation tools for complex geometries. The open source business logic just isn’t very suitable for developing the mesh generation capabilities of the code. Most of the development work in Elmer goes to the solver part of the software suite.

For the shortcoming people use a large variety of different meshing tools.
Based on the static survey on the discussion forum people mostly use Gmsh (44%), Salome (19%), netgen (11%), ElmerGrid native (9%), or ElmerGUI plugins (9%). For all formats (except netgen) the conversion is done with ElmerGrid.

To convert a mesh into Elmer you need to know the “magic numbers” relating to different formats in ElmerGrid. For this purpose call ElmerGrid without any arguments:

The first parameter defines the input file format:
1)  .grd      : Elmergrid file format
2)  .mesh.*   : Elmer input format
3)  .ep       : Elmer output format
4)  .ansys    : Ansys input format
5)  .inp      : Abaqus input format by Ideas
6)  .fil      : Abaqus output format
7)  .FDNEUT   : Gambit (Fidap) neutral file
8)  .unv      : Universal mesh file format
9)  .mphtxt   : Comsol Multiphysics mesh format
10) .dat      : Fieldview format
11) .node,.ele: Triangle 2D mesh format
12) .mesh     : Medit mesh format
13) .msh      : GID mesh format
14) .msh      : Gmsh mesh format
15) .ep.i     : Partitioned ElmerPost format

The second parameter defines the output file format:
1)  .grd      : ElmerGrid file format
2)  .mesh.*   : ElmerSolver format (also partitioned .part format)
3)  .ep       : ElmerPost format
4)  .msh      : Gmsh mesh format
5)  .vtu      : VTK ascii XML format

For instance, to translater Gmsh format into ElmerSolver mesh format you would type

ElmerGrid 14 2 mesh.msh -autoclean

The “autoclean” flag renumbers the entities continuously to start from 1. However, if you have taken the effort to predefine the physical entities you may skip this flag and use the numbering of the physical entities.

Similarly to transfer universal format (UNV) to vtu format you would say

ElmerGrid 8 5 mesh.unv

Often people also build their own workflows including in-house code performing mesh manipulation. If you have a format that you feel that should be supported by Elmer suite you may contact the developers and suggest that it be added.