Exporting Meshes
You can export a mesh to a COMSOL Multiphysics file (.mphbin for a binary file format or .mphtxt for a text file format) or to a NASTRAN file (.nas, .bdf, .nastran, or .dat).
To open the Export window for exporting meshes, from the Mesh toolbar, click Export (), or right-click the Mesh node and select Export () from the menu.
Export
Select a file type among the available formats in the File type list and enter a filename including the path in the Filename field (or click Browse to specify the filename).
Click Export to export a mesh to the specified file. A confirmation message appears in the Messages window.
Exporting to a COMSOL Multiphysics File
If you export a mesh to a COMSOL Multiphysics binary (.mphbin) or text (.mphtxt) file, you specify the type of elements to export using the Domain elements, Boundary elements, Edge elements (available in 3D), and Vertex elements (available in 2D and 3D) check boxes under Data to export. By selecting the Geometric entity information check box, the export operation also writes information on the corresponding geometric entity index for each element to the file. Select the Selections check box to also include mesh selections that are defined on the current geometry in the mesh export. Such selections can then be included when importing a mesh.
Exporting to a NASTRAN File
If you export a 2D or 3D mesh to a NASTRAN file, you specify the type of elements to export using the Domain elements and Boundary elements (available in 3D) check boxes. By selecting the Geometric entity information check box, the export operation also writes information on each element’s corresponding geometric entity index to the corresponding property identification field of the resulting NASTRAN file.
Under Output settings, use the Field format list to specify if the output NASTRAN file should be stored in the small field format (single precision), large field format (double precision), or free field format (comma separated). Select the Export as linear elements check box to export the linear element information only. By default, second-order elements are exported if second-order elements are available. Second-order elements are available for meshes generated in COMSOL Multiphysics and for imported meshes already containing second-order elements.
Exporting a 3D Mesh to an STL File
You can export the boundary elements of a 3D mesh to an STL file in the binary or text format. Because the STL format only supports triangles, the export operation writes two triangles (defining a quad split) to the STL file for each quad element in the mesh.
There is also a mesh export option available under Results>Export (see Mesh (Export)). Use that mesh export if you have computed a solution and want to export the mesh from a deformed configuration or a (geometric) parameter configuration, for example. From the Mesh node under Results>Export you can also export the second-order element nodes used by the COMSOL Multiphysics solvers, which are not available in the mesh itself. Exporting the mesh on the NASTRAN file format is only available from the Mesh node’s Export option.