On this page:
7.4.1 Exporting the Finite Element Model
7.4.2 Defining PARAMS for NASTRAN
7.4.3 Instancing Parts with ABAQUS
7.4.4 Exporting ANSYS CDB files
7.4.5 Exporting an Exodus II File
7.4.6 Exporting Fluent Grid Files
7.4.7 Exporting Sierra Files
7.4.8 Transforming Mesh Coordinates
2022.4+26187-e1209cf7 Apr 14, 2022

7.4 Export

7.4.1 Exporting the Finite Element Model

For information on exporting an Exodus File, see Exporting Exodus II Files. Custom translators are available to translate between the Exodus II format and a limited number of other analysis code formats. Contact the Cubit development team for a current list of supported translator formats. The general syntax for the various exporters is as follows. The specific exporter commands are listed below.

Export {Abaqus [Explicit]* [Partial]* | Nastran | Ideas | Patran | LSDyna | Fluent} <’filename’> [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [dimension {2|3}***] [Overwrite] [Everything] [NX]**

Export VRML <’filename’> [Overwrite]

* explicit and partial keywords only available with Abaqus Exporter

** NX keyword only available with I-DEAS Exporter

***The dimension argument is also optional. Most element types have an inherent dimensionality associated with them. For example, a truss or beam element is inherently 2D while a hex or tetra element is 3D. Without this argument, only the x-y location of the nodal coordinates of 2D elements are written to the Exodus II file. Using the argument dimension 3, in this example, permits the full 3D coordinates to be written.

The Abaqus Exporter has a few additional keywords available. See the last paragraph below for an explanation of those keywords:

Export Abaqus <’filename’> [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [dimension {2|3}] [nodefile <’filename’>] [elementfile <’filename’>] [flatfile] [overwrite] [everything]

If no blocks are exported, Cubit will export all nodes and elements in the model. If one or more blocks are entered in the command, only those blocks will be exported. Similarly, if no BCSets are entered in the command, Cubit will export all boundary conditions as a single BCSet. If one or more BCSets are entered into the command, only those BCSets will be exported. Use the overwrite flag to overwrite an existing file.

By default, Cubit will reassign node and element IDs based on which block they are in. If the everything keyword is present, Cubit will export all nodes and elements in the model, whether they are in a block or not.

The I-DEAS Universal file can be read into Siemen’s NX application if the file is generated using the NX keyword. This is because extra information must be written to an I-DEAS Universal file in order for NX to be able to read it.

There are a few keywords specifically for the Abaqus exporter. flatfile can be used if the user desires Cubit to write out the model as a "flat file." Abaqus refers to files a "flat files" when they do not use the *PART/*INSTANCE structure. All nodes and elements will be defined at the global level. The keywords elementfile and nodefile can be used to instruct Cubit to export the nodes and/or elements to a separate file.

If the explicit keyword is used with Abaqus, Cubit will write an Abaqus Explicit deck. The one Explicit-only feature that Cubit supports is fixed mass scaling.

If the partial keyword is used with Abaqus, Cubit will write a partial Abaqus deck. Cubit will output the mesh as defined by the Abaqus keywords PART, NODE, ELEMENT, NSET, ELSET, and SURFACE. Everything else is ignored. Use the Abaqus keyword INCLUDE to include this file in a master Abaqus deck for analysis.

Specific Exporter Commands:

Export Abaqus [explicit] ’<filename>’ [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [group <id_list>] [instance block <id_list> [source_csys <id_list>] target_csys <id_list> [preview]][dimension {2|3}] [overwrite] [everything] [partial]

Set Abaqus Precision <n=6>

Note: This command can be used to control the number of decimal places written to the Abaqus file.

Export Nastran ’<filename>’ [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [dimension {2|3}] [overwrite] [everything]]

Export Ideas ’<filename>’ [NX] [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [dimension {2|3}] [overwrite] [everything]

Export Patran ’<filename>’ [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [overwrite] [everything][dimension {2|3}]

Export Lsdyna ’<filename>’ [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [overwrite]

Export VRML <’filename’> [Overwrite]

Export Fluent ’<filename>’ [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [dimension {2|3}] [overwrite] [everything]

Note: The following command is for exporting mesh geometry:

Export Fluent ’<filename>’ [Surface <id_list>|Volume <id_list>] [Overwrite]

7.4.1.1 Supported element types

Cubit Element Type

ExodusII

Abaqus

Nastran

I-DEAS UNV

Patran

LS-DYNA

Fluent

Sphere

SPHERE

ELEMENT_SPH

Spring

SPRING

SPRINGA/SPRING1/SPRING2

CBUSH1D**

Bar

BAR

B21**

CROD**

121**

Bar2

Bar2

BAR2

B21**

CROD**

121**

Bar2

Bar3

BAR3

B22**

CROD**

121**

Beam

BEAM

B31

CROD**

21**

Bar2

ELEMENT_BEAM

Beam2

BEAM2

B31

CROD**

21**

Bar2

ELEMENT_BEAM

Beam3

BEAM3

B32

CROD**

24**

Truss

TRUSS

T3D2/T3D2T*,**

CROD**

121**

Bar2

ELEMENT_BEAM

Truss2

TRUSS2

T3D2/T3D2T*,**

CROD**

121**

Bar2

ELEMENT_BEAM

Truss3

TRUSS3

T3D2/T3D2T*,**

CROD**

121**

Quad

QUAD

CPE4R/CPE4RT*

CQUAD4

54

Quad4

ELEMENT_SHELL

3

Quad4

QUAD4

CPE4R/CPE4RT*

CQUAD4

54

Quad4

ELEMENT_SHELL

3

Quad5

QUAD5

Quad5

Quad8

QUAD8

CPE8R/CPE8RT*

CQUAD8

55

Quad8

Quad9

QUAD9

S9R5

CQUAD

55

Quad9

Shell

SHELL

S4R/S4RT*

CQUAD4

94***

Quad4

ELEMENT_SHELL

Shell4

SHELL4

S4R/S4RT*

CQUAD4

94***

Quad4

ELEMENT_SHELL

Shell8

SHELL8

S8R/S8RT*

CQUAD8

95***

Quad8

Shell9

SHELL9

S9R5

95***

Quad9

Tri

TRI

CPS3/CPS3T*

CTRIA3

51

Tri3

ELEMENT_SHELL

1

Tri3

TRI3

CPS3/CPS3T*

CTRIA3

51

Tri3

ELEMENT_SHELL

1

Tri6

TRI6

CPS6/CPS6T*

CTRIA6

52

Tri6

Tri7

TRI7

52

Tri7

Trishell

TRISHELL

STRI3

CTRIA3

91

Tri3

ELEMENT_SHELL

Trishell3

TRISHELL3

STRI3

CTRIA3

91

Tri3

ELEMENT_SHELL

Trishell6

TRISHELL6

STRI65

CTRI6

92

Tri6

Trishell7

TRISHELL7

92

Tri7

Hex

HEX

C3D8R/C3D8RT*

CHEXA

115

Hex8

ELEMENT_SOLID

4

Hex8

HEX8

C3D8R/C3D8RT*

CHEXA

115

Hex8

ELEMENT_SOLID

4

Hex9

HEX9

Hex20

HEX20

C3D20R/C3D20RT*

CHEXA

116

Hex20

Hex27

HEX27

Tetra

TETRA

C3D4/C3D4T*

CTETRA

111

Tet4

ELEMENT_SOLID

2

Tetra4

TETRA4

C3D4/C3D4T*

CTETRA

111

Tet4

ELEMENT_SOLID

2

Tetra8

TETRA8

Tetra10

TETRA10

C3D10/C3D10MT*

CTETRA

118

Tet10

ELEMENT_SOLID

Tetra14

TETRA14

Wedge

WEDGE

C3D6/C3D6T*

CPENTA

112

ELEMENT_SOLID

6

Hexshell

HEXSHELL

Pyramid

PYRAMID

CPYRAM

115^

Pyramid5

PYRAMID5

CPYRAM

115^

Pyramid8

PYRAMID8

CPYRAM

116^

Pyramid13

PYRAMID13

CPYRAM

116^

Pyramid18

PYRAMID18

CPYRAM

116^

*Thermal element

**Check to make sure the element’s properties are correct after exporting

***Also exports lofting factor for shell elements (IDEAS)

^ The element type will be HEX but the number of nodes will be the number of nodes in the pyramid

7.4.1.2 Supported boundary conditions types

Cubit Element Type

ExodusII

Abaqus

Nastran

I-DEAS UNV

Patran

LS-DYNA

Fluent

BC Set

*STEP

SUBCASE

2428

Displacement

*BOUNDARY

SPC

791

08

Temperature

*BOUNDARY

TEMP

791

10

Force

*CLOAD

FORCE/MOMENT

790

07

Pressure

*DSLOAD

PLOAD4

790

6

Convection

*SFILM ***

CONV

790

17

Heat Flux

*DSFLUX

QHBDY

790

16

Contact

*CONTACT

2471

Materials

*MATERIAL

MAT1_, MAT4_

1716

03

CFD Boundary Conditions

Interior

2

Wall

3

Inlet Pressure

4

Inlet Massflow

20

Inlet Velocity

10

Outlet Pressure

5

Far-field Pressure

9

Symmetry

7

*** Does not allow separate temperatures for top and bottom of shell elements. Values will be averaged.

7.4.2 Defining PARAMS for NASTRAN

List Nastran Exporter Params

Set  Nastran Exporter Params Add ’<param_string>’

Set  Nastran Exporter Params Remove ’<param_string>’

Set  Nastran Exporter Params Clear

Nastran uses PARAMS to define additional instructions and settings in its Bulk Data file.  Any string can be defined as a Nastran Exporter Param, and it will be exported to the Nastran file as PARAM, <string>.

7.4.3 Instancing Parts with ABAQUS

The ABAQUS file format allows users to instance a mesh multiple times. An example of this would be to create a mesh of a single bolt, but instance the bolt mesh several times in the ABAQUS model file to generate multiple bolts.

To export an ABAQUS file with instanced parts

  1. Click file and then export.

  2. Select the desired location to save the file.

  3. Enter the file name.

  4. Select abaqus from the save as type drop-down menu.

  5. Click save. A new window will appear.

  6. Enter the appropriate settings.

  7. Click finish.

export abaqus <’filename’> [block <id_list>] [sideset <id_list>] [nodeset <id_list>] [bcset <id_list>] [instance block <id_list> [source_csys <id>] [target_csys <id_list>] [overwrite] [everything]

Any block defined in Cubit can be instanced n number of times in the ABAQUS file. To instance a block, a source coordinate system and a target coordinate system (where the mesh will be translated and rotated to) need to be defined. If no source coordinate system is given in the command, the default (global) coordinate system is used. The instance keyword can be used as many times as needed.

Note: By default, the Abaqus exporter writes 6 decimal places. The command set abaqus precision <n> can be used to change the number of decimal places written.

7.4.4 Exporting ANSYS CDB files

Coreform Cubit can export *.cdb files to be used in ANSYS Mechanical simulations via the APDL command cdread,all,filename,cdb. All exported entities must be part of a block. By default, this is a mesh only export. Optionally, the surface geometry may also be exported in a parallel IGES file. The mesh and the geometry are not associated in ANSYS.

Export Ansys CDB <’filename’> [Block <id_list>] [Geometry] [Overwrite]

7.4.5 Exporting an Exodus II File

To export an Exodus II file

  1. Click file and then export.

  2. Select the desired location to save the file.

  3. Enter the file name.

  4. Select exodus from the save as type drop-down menu.

  5. Click save. A new window will appear.

  6. Enter the appropriate settings.

  7. Click finish.

Export [Genesis|Mesh] ’<filename>’ [dimension {2|3}] [Block <id_list>] [XML ’<filename>’]

The genesis or mesh arguments are optional and both indicate that an Exodus II format will be written. The filename can be any valid filename. Where a full path is not specified, the file will be written in the current working directory.

The dimension argument is also optional. Most element types have an inherent dimensionality associated with them. For example, a truss or beam element is inherently 2D while a hex or tetra element is 3D. Without this argument, only the x-y location of the nodal coordinates of 2D elements are written to the Exodus II file. Using the argument dimension 3, in this example, permits the full 3D coordinates to be written.

The optional block argument may also be added to the export command. Without this argument, all blocks defined in the current model will be exported to the Exodus II file. This argument permits the user to specify only a portion of the blocks in the model. The <id_list> may be any valid set of integers corresponding to the Blocks in the current model.

The XML optional argument may also be added to the export command. When this argument is included and assembly data exists in the model, an XML file is written which describes the relationship between block IDs in the Exodus II file and parts in the assembly. See the Parts, Assemblies and Metadata section for details.

7.4.5.1 Element and Node ID Maps

Element ID map and node ID map are always written to the Exodus II file. The IDs written to the node ID map are the node IDs used to refer to nodes at the Cubit command line. The IDs written to the element ID map are the Global Element IDs which are assigned to the hex, tet, quad, etc. when they are added to an element block. The node and element ID maps can be used when a particular element or node is referred to in a downstream application and the corresponding node or element in Cubit must be found. Some analysis and post-processing applications consider these maps to be optional, while others ignore the maps even if they are present. See the https://github.com/gsjaardema/seacas#exodus for more information on element and node ID maps.

7.4.5.2 Exporting a Parallel Mesh for pCAMAL

Export Parallel "<filename>" [Block <id_list>] [Overwrite] [Processor <number>]

The export parallel command is used to output an ExodusII file with the boundary mesh or shell for sweepable volumes that were meshed with set parallel meshing enabled. The options are the same as those for the export genesis command except for the addition of the processor option.

The processor option allows the user to specify the number of processors that will be used to mesh the volume with the pCAMAL option. This same option exists in the pCAMAL application and is more often used there since the number of available processors is known then rather than when the output file is created in Cubit.

If the processor option is given, Cubit attempts to balance the number of sweepable volumes to run on n processors by converting many-to-one sweeps to one-to-one sweeps, subdividing the sweep volume along its sweep direction, or partitioning the source surface of a one-to-one sweep if the number of source quads is much larger than the number of layers.

7.4.5.3 Converting an Exodus II file to ASCII

The Exodus II file format is binary. It is frequently necessary to view the contents of the Exodus II file as plain text. A publicly available tool known as ncdump can be used to view the contents of an Exodus II file. ncdump is part of the netCDF library and is currently available from Unidata at the following URL:

http://www.unidata.ucar.edu/

On a UNIX platform, typical use of the ncdump utility is:

ncdump filename.e > filename.txt

In this format, the ncdump utility will take the Exodus II file, filename.e, and dump the contents to an ASCII file filename.txt

Another option for converting between binary and ASCII formats of Exodus II files is a utility known as exotxt. Exotxt is part of the https://github.com/gsjaardema/seacas tool suite. Contact the Sandia Cubit development team for a copy of this utility.

Note that the ’stock’ ncdump utility should work for most meshes; however, Sandia increases some of the dimensions in order to handle larger meshes (more element blocks, boundary conditions, variables). The dimensions we increase in netcdf.h are:

NC_MAX_DIMS (max dimensions per file) from 100 to 65536
NC_MAX_VARS (max variables per file) from 2000 to 524288

7.4.5.4 Controlling Exodus II Output Precision

By default, exodus files are written with double precision numbers. It may be useful to change this for large meshes to decrease output file size. This can be done using the following command:

Set Exodus Single Precision [On|Off]

This command toggles the Exodus output file between single precision (floats) and double precision.

7.4.5.5 Large Exodus Format

The set large exodus command enables the large exodus file setting to create a model that can store individual datasets larger than 2 gigabytes. This modifies the internal storage used by ExodusII and also puts the underlying netcdf file into the "64-bit offset" mode.

Set Large Exodus [On|OFF]

7.4.6 Exporting Fluent Grid Files

Geometry can be exported from Cubit to the Fluent .msh format. This format can be used to exchange grid information between .msh compatible programs including Fluent, GAMBIT, and TGrid.

To export a fluent grid file

  1. Click file and then export.

  2. Select the desired location to save the file.

  3. Enter the file name.

  4. Select fluent from the save as type drop-down menu.

  5. Click save. A new window will appear.

  6. Enter the appropriate settings.

  7. Click finish.

Export Fluent ’<filename>’ [Block <id_list>] [Sideset <id_list>] [Nodeset <id_list>] [BCSet <id_list>] [Dimension{2|3}] [Overwrite] [Consolidate]

The filename should be enclosed in either single or double quotes. By convention, the file extension .msh is applied to grid files. The extension should be included in the filename section. Other file extensions such as .cas may be used, but they cannot be guaranteed to be compatible with either GAMBIT or TGrid.

In order to guarantee that the grid file will be compatible with Fluent, all bodies must be merged (See Geometry Merging). Several types of Fluent boundary condition zones are now implemented in Cubit. They are:

If consolidate is used, all user defined blocks will be combined into a single block.

Boundary condition zones created in two different ways. The first way involves user-defined mesh groups consisting only of quads (3D), triangles (3D), or element edges (2D) (See Geometry Groups). The second way involves sidesets. Specifying a boundary condition consists of selecting a user-defined mesh group or a sideset, or a surface. Selecting a surface automatically assigns the boundary condition to the sideset associated with that surface. The boundary condition type is specified and is either given a name or an id (See Using CFD Boundary Conditions). Groups or sidesets of mixed type (e.g. hexes and faces) will not be exported. All surfaces not set to one of the first seven boundary condition types are automatically set to type ’wall’. The various parameters for each of the boundary condition types must be set within either Fluent or GAMBIT.

Cell zones are automatically created for 3D meshes containing blocks. Blocks must contain entire and continuous volumes in order to create a valid grid. In 2D models, the cell zones are created from sidesets containing only quads or tris. In order to create a valid grid, these sidesets must contain whole, continuous surfaces. All cell zones are by default set to type ’fluid.’

If no entities are specified, the entire model is exported. In order to export selected entities, the types ’volume’ and ’surface’ can be specified. In 2D cases, use ’surface’ while in the 3D case use ’volume.’

The exporter can handle higher-order elements, although Fluent will convert the elements to first-order upon import.

7.4.7 Exporting Sierra Files

Sierra input decks can be exported from Cubit.This capability was added in response to a need to translate Abaqus input decks to Sierra input decks by importing the Abaqus deck into Cubit and then immediately exporting the Sierra deck.Therefore, it is assumed that most of the input deck information has been created outside of Cubit and that the user will not interact with it in Cubit .

The Sierra input deck writer is simply another export format and as a result it can be used for any currently defined mesh and input deck info defined in Cubit.
The Sierra input deck exporter relies on some of the mesh-specific information that is generated when exporting the Genesis mesh.Therefore, you should export the Genesis mesh before exporting the Sierra input deck.

7.4.8 Transforming Mesh Coordinates

A mesh can be scaled and transformed to a new location as it is written to or read from an Exodus file. To transform a mesh during import or export use the following command:

Transform Mesh {Input|Output}
[Scale <xyz_factor>]
[Scale <x_factor> <y_factor> <z_factor>]]
[Scale {X|Y|Z} <factor>]
[Translate <dx> [<dy> [<dz>]]]
[Translate {X|Y|Z} <distance>]
[Rotate <degrees> about {X|Y|Z}]
[Reset]

This command may be repeated any number of times using any number of options. Transform commands are cumulative, added to the effect of previous transforms. If more than one transformation is entered in the same command, transformations are applied in the order they appear in the command.

To clear a transformation matrix, use the reset option:

Transform Mesh {Input|Output} Reset

Mesh input and output transformations are also cleared when you reset the entire model using the reset command.

Transforming a mesh during output does not change the position of the mesh within Cubit. It only changes the nodal positions written to the Exodus file. Nodal positions may be changed within Cubit by transforming the body that contains the mesh. See Geometry Transforms for information on how to apply transformations to a Body.

Transforming a mesh during input does change the position of the mesh with Cubit. The file being read is not modified.

Transformations applied during mesh input are independent of transformations applied during mesh output.

The following example generates a simple mesh, writes the mesh with its coordinates scaled by a factor of 2, and then re-imports that mesh, restoring the scaling to what it originally was in Cubit.

brick x 10
volume 1 interval 4
mesh vol 1
transform mesh output scale 2
export mesh ’temp.exo’
delete mesh
transform mesh input scale .5
import mesh ’temp.exo’

See Geometry Transforms for information on how to apply transformations to a Body.

See Nodeset and Nodeset Repositioning

See Importing a Mesh

See Mesh Based Geometry