Promesh provides conversion between mesh formats.
A conversion JSON file contains two sections: "Mesh File Options"
, where the names of the input and output meshes are provided, and "Conversion Options"
where the conversion method is specified. Most conversion methods also have their own additional requirements.
{ "Program Type": "Conversion", "Mesh File Options": { "Input Mesh File": "input.msh", "Output Mesh File": "output.vtu", }, "Conversion Options": { "Method": "GMSH->VTK" } }
Mesh conversion options include:
"GMSH->EXO"
"GMSH->VTK"
"VTK->COBALT"
"VTK->PATRAN"
"VTK->PNT"
"VTK-HEX->VTK-TET"
If CFMesh is available, further options are:
"FOAM->MSH"
"FOAM->VTK"
"VTK->FOAM"
Within the "Conversion Options"
, requires:
Number of Mesh
: the number of meshes (must be at least one)Mesh Data
: block which contains:File
: the mesh's file name (Required)Name
: the mesh's name (Optional, default "default"
)Use Physical Groups
: can be true
or false
(Optional, default false
)Node Sets
: gives an array listing the node sets, if anyElement Blocks
: gives an array listing the element blocks, if anyFree Surface Side Set
: can be true
or false
(Optional, default false
)Split Top and Bottom
: can be true
or false
(Optional, default false
)Side Set Names
: (Optional)Element Block Names
: (Optional)Add Global Node Set
: (Optional)Post Processing
: requires a post processing file in JSON format to be specifiedNumber of Tasks
: (default 0)Tasks
: blocks should correspond with the number of tasks input aboveFile
:gives the name of the task file.An example "GMSH->EXO"
JSON file named gmsh2exo.json
can be found in the testing/test_data/ep16pre
directory.
Requires no additional keywords or specifications.
Within the "Mesh File Options"
, requires:
Output Patch Map File
: which is a .cgi
file.Within the "Conversion Options"
, requires:
BC Info
:Patch Number
: corresponds to numbers assigned to patched within the VTK fileBC Type
: can be either: "Face"
or "Node"
, which changes the following options as described:RocFrac FSI Type
: can be 0, 1, or 2 (for "BC Type": "Face"
)Structural
: can be true
or false
(for "BC Type": "Node"
)Mesh Motion
: can be true
or false
(for "BC Type": "Node"
)Thermal
: can be true
or false
(for "BC Type": "Node"
)RocfracControl Type
: can be 1, 2, or 3 (for "BC Type": "Node"
)Node Patch Preference
: lists the preferred order for the node patchesAn example "VTK->PATRAN"
JSON file named vtk2patran.json
can be found in the testing/test_data/PatranGenTest
directory.
Within the "Conversion Options"
, requires:
Check Conversion Quality
: can be either true
or false
Dimension
: can be either 1, 2, or 3Block Data
: a JSON file may have one or more of these sections, depending on the number of blocks present in the meshElement Order
: can be 1 or 2Equation Order
: can be 1 or 2Element Type
: can be "BAR"
for 1D, "TRIANGLE"
, "QUADRILATERAL"
, or "HEXAGON"
for 2D, or "SPHERICAL"
, "CYLINDRICAL"
, "BRICK"
, "LAGRANGE_BRICK"
, "TETRAHEDRON"
, "HEXPRISM"
, or "PRISMATIC"
for 3D. "OTHER"
is also an option.BC Tag
: can be "VOID"
"REFLECTIVE"
Name
: is the name of the regionElement ID Range
: can be two integers enclosed in square brackets, ie [0, 5], representing all integers from 0 to 5Element ID
: can be an array of integers enclosed in square brackets, ie [0, 1, 2]Note that either "Element ID Range"
or "Element ID"
should be specified for each block.
Example "VTK->PNT"
JSON files named bench1.json
, bench5.json
, and bench6.json
can be found in the testing/test_data/PNTGenTest
directory.
Requires no additional keywords or specifications.
Requires no additional keywords or specifications.
Requires no additional keywords or specifications.
Requires no additional keywords or specifications.