FemOperations
Provides tools for managing Finite Element Model (FEM) data on volume meshes. The FemOperations class enables scripting access to FEM model management including materials, parts, node sets, element sets, surfaces, and export to various solver formats.
Import
import ScriptingApi as api
# Access via Application
app = api.Application()
ops = app.get_fem_operations()
Methods
Creation
create_fem_model
Creates or initializes an FEM model for the specified volume mesh. If the volume mesh already has an FEM model, this clears and reinitializes it. The FEM model is automatically synchronized with the mesh geometry (nodes and elements).
Signature:
create_fem_model(volumeMeshName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh to create the FEM model for. |
Returns: bool — True if the FEM model was created successfully; false otherwise.
create_part
Creates a new part in the FEM model. If the volume mesh does not yet have an FEM model, one is created automatically before the part is created.
Signature:
create_part(volumeMeshName: str, params: FemPartParams) -> str
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
params | any | Part parameters including name, material, and section properties. Create using api.FemPartParams(). If params.materialName is set, the named material must already exist or the call fails. |
Returns: str — The name of the created part, or an empty string if creation failed.
create_part_from_element_set
Creates a part from an existing element set. Elements in the set are assigned to the new part. If the volume mesh does not yet have an FEM model, one is created automatically; however, the named element set must already exist in the model or the call fails.
Signature:
create_part_from_element_set(volumeMeshName: str, elementSetName: str, partName: str, materialName: str = "") -> str
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set to convert. |
partName | any | The name for the new part. |
materialName | any | The name of the material to assign (empty for none). |
Returns: str — The name of the created part, or an empty string if creation failed.
create_node_set
Creates a node set in the FEM model. If the volume mesh does not yet have an FEM model, one is created automatically before the node set is created.
Signature:
create_node_set(volumeMeshName: str, params: FemNodeSetParams) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
params | any | Node set parameters including name and node IDs. Create using api.FemNodeSetParams(). |
Returns: bool — True if the node set was created successfully; false otherwise.
create_node_set_from_roi
Creates a node set from nodes inside a visible ROI primitive. If the volume mesh does not yet have an FEM model, one is created automatically. The ROI primitive must currently be visible in the 3D view; the call fails if it is not found or not visible.
Signature:
create_node_set_from_roi(volumeMeshName: str, roiName: str, nodeSetName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
roiName | any | The name of the ROI primitive. |
nodeSetName | any | The name for the new node set. |
Returns: bool — True if the node set was created successfully; false otherwise.
create_element_set
Creates an element set in the FEM model. If the volume mesh does not yet have an FEM model, one is created automatically before the element set is created.
Signature:
create_element_set(volumeMeshName: str, params: FemElementSetParams) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
params | any | Element set parameters including name and element IDs. Create using api.FemElementSetParams(). |
Returns: bool — True if the element set was created successfully; false otherwise.
create_element_set_from_roi
Creates an element set from elements inside a visible ROI primitive. An element is included when its centroid lies inside the ROI. If the volume mesh does not yet have an FEM model, one is created automatically. The ROI primitive must currently be visible in the 3D view; the call fails if it is not found or not visible.
Signature:
create_element_set_from_roi(volumeMeshName: str, roiName: str, elementSetName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
roiName | any | The name of the ROI primitive. |
elementSetName | any | The name for the new element set. |
Returns: bool — True if the element set was created successfully; false otherwise.
create_surface
Creates an empty surface in the FEM model. Creates a named surface with the given type and source metadata but no faces. Use detect_boundary_surfaces or create_surface_from_element_set to add faces to the surface. If the volume mesh does not yet have an FEM model, one is created automatically.
Signature:
create_surface(volumeMeshName: str, params: FemSurfaceParams) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
params | any | Surface parameters including name and type. Create using api.FemSurfaceParams(). |
Returns: bool — True if the surface was created successfully; false otherwise.
create_surface_from_element_set
Creates a surface from the boundary of an element set. Extracts the exterior boundary faces of the elements in the set. If the volume mesh does not yet have an FEM model, one is created automatically; however, the named element set must already exist or the call fails. Returns false if the resulting surface has no faces.
Signature:
create_surface_from_element_set(volumeMeshName: str, elementSetName: str, surfaceName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set. |
surfaceName | any | The name for the new surface. |
Returns: bool — True if the surface was created with at least one face; false otherwise.
create_sets_from_visible_roi
Creates node sets, element sets, and surfaces from all visible ROI primitives. For each visible ROI: - Creates a node set containing nodes inside the ROI - Creates an element set containing elements with centroids inside the ROI - Creates a boundary surface from the element set, named "<elementSetName>_Surface" If the volume mesh does not yet have an FEM model, one is created automatically. The call fails if there are no visible ROI primitives, or if either prefix is empty.
Signature:
create_sets_from_visible_roi(volumeMeshName: str, nodeSetPrefix: str = "ROI_Nodes", elementSetPrefix: str = "ROI_Elements") -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
nodeSetPrefix | any | Prefix for node set names (e.g., "ROI_Nodes" -> "ROI_Nodes_BoxPrimitive"). Defaults to "ROI_Nodes". Must not be empty. |
elementSetPrefix | any | Prefix for element set names. Defaults to "ROI_Elements". Must not be empty. |
Returns: bool — True if at least one set or surface was created; false otherwise.
Properties
has_fem_model
Checks whether the specified volume mesh has an FEM model.
Signature:
has_fem_model(volumeMeshName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh to check. |
Returns: bool — True if the volume mesh has an FEM model; false otherwise.
get_model_statistics
Gets statistics about the FEM model on the specified volume mesh.
Signature:
get_model_statistics(volumeMeshName: str) -> FemModelStatistics
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: FemModelStatistics — The api.FemModelStatistics containing counts of nodes, elements, materials, parts, and sets. If the volume mesh has no FEM model, all counts are zero and hasModel is false.
add_material_from_preset
Adds a material from a preset. If the volume mesh does not yet have an FEM model, one is created automatically before the material is added.
Signature:
add_material_from_preset(volumeMeshName: str, preset: FemMaterialPreset, name: str = "") -> str
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
preset | any | Material preset. Use api.FemMaterialPreset.Steel, Aluminum, etc. |
name | any | Optional custom name for the material. If empty, uses preset name. |
Returns: str — The name of the created material, or an empty string if creation failed.
get_materials
Gets all materials in the FEM model.
Signature:
get_materials(volumeMeshName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: list — List of material information structures as api.FemMaterialInfo.
get_material_by_name
Gets a material by name.
Signature:
get_material_by_name(volumeMeshName: str, materialName: str) -> FemMaterialInfo
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
materialName | any | The name of the material. |
Returns: FemMaterialInfo — Material information as api.FemMaterialInfo, or empty info if not found.
get_parts
Gets all parts in the FEM model.
Signature:
get_parts(volumeMeshName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: list — List of part information structures.
get_part_by_name
Gets a part by its name.
Signature:
get_part_by_name(volumeMeshName: str, partName: str) -> FemPartInfo
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
partName | any | The name of the part. |
Returns: FemPartInfo — Part information, or empty info if not found.
add_nodes_to_set
Adds nodes to an existing node set.
Signature:
add_nodes_to_set(volumeMeshName: str, nodeSetName: str, nodeIds: list) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
nodeSetName | any | The name of the node set. |
nodeIds | any | List of node IDs to add. |
Returns: bool — True if nodes were added successfully; false otherwise.
remove_nodes_from_set
Removes nodes from an existing node set.
Signature:
remove_nodes_from_set(volumeMeshName: str, nodeSetName: str, nodeIds: list) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
nodeSetName | any | The name of the node set. |
nodeIds | any | List of node IDs to remove. |
Returns: bool — True if nodes were removed successfully; false otherwise.
remove_node_set
Removes a node set from the FEM model.
Signature:
remove_node_set(volumeMeshName: str, nodeSetName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
nodeSetName | any | The name of the node set to remove. |
Returns: bool — True if the node set was removed successfully; false otherwise.
rename_node_set
Renames a node set.
Signature:
rename_node_set(volumeMeshName: str, oldName: str, newName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
oldName | any | The current name of the node set. |
newName | any | The new name for the node set. |
Returns: bool — True if the node set was renamed successfully; false otherwise.
get_node_sets
Gets all node sets in the FEM model.
Signature:
get_node_sets(volumeMeshName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: list — List of node set information structures as api.FemNodeSetInfo.
get_node_set_by_name
Gets information about a specific node set.
Signature:
get_node_set_by_name(volumeMeshName: str, nodeSetName: str) -> FemNodeSetInfo
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
nodeSetName | any | The name of the node set. |
Returns: FemNodeSetInfo — Node set information as api.FemNodeSetInfo, or empty info if not found.
get_node_set_node_ids
Gets the node IDs in a node set.
Signature:
get_node_set_node_ids(volumeMeshName: str, nodeSetName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
nodeSetName | any | The name of the node set. |
Returns: list — List of node IDs in the set.
add_elements_to_set
Adds elements to an existing element set.
Signature:
add_elements_to_set(volumeMeshName: str, elementSetName: str, elementIds: list) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set. |
elementIds | any | List of element IDs to add. |
Returns: bool — True if elements were added successfully; false otherwise.
remove_elements_from_set
Removes elements from an existing element set.
Signature:
remove_elements_from_set(volumeMeshName: str, elementSetName: str, elementIds: list) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set. |
elementIds | any | List of element IDs to remove. |
Returns: bool — True if elements were removed successfully; false otherwise.
remove_element_set
Removes an element set from the FEM model.
Signature:
remove_element_set(volumeMeshName: str, elementSetName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set to remove. |
Returns: bool — True if the element set was removed successfully; false otherwise.
rename_element_set
Renames an element set.
Signature:
rename_element_set(volumeMeshName: str, oldName: str, newName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
oldName | any | The current name of the element set. |
newName | any | The new name for the element set. |
Returns: bool — True if the element set was renamed successfully; false otherwise.
get_element_sets
Gets all element sets in the FEM model.
Signature:
get_element_sets(volumeMeshName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: list — List of element set information structures as api.FemElementSetInfo.
get_element_set_by_name
Gets information about a specific element set.
Signature:
get_element_set_by_name(volumeMeshName: str, elementSetName: str) -> FemElementSetInfo
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set. |
Returns: FemElementSetInfo — Element set information as api.FemElementSetInfo, or empty info if not found.
get_element_set_element_ids
Gets the element IDs in an element set.
Signature:
get_element_set_element_ids(volumeMeshName: str, elementSetName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
elementSetName | any | The name of the element set. |
Returns: list — List of element IDs in the set.
get_surfaces
Gets all surfaces in the FEM model.
Signature:
get_surfaces(volumeMeshName: str) -> list
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: list — List of surface information structures as api.FemSurfaceInfo.
get_surface_by_name
Gets information about a specific surface.
Signature:
get_surface_by_name(volumeMeshName: str, surfaceName: str) -> FemSurfaceInfo
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
surfaceName | any | The name of the surface. |
Returns: FemSurfaceInfo — Surface information as api.FemSurfaceInfo, or empty info if not found.
clear_all_fem_visualizations
Clears all FEM visualizations (node sets, element sets, surfaces, parts) from the 3D view. Removes all FEM-related visual actors from the renderer, restoring the default mesh view.
Signature:
clear_all_fem_visualizations() -> None
General
clear_fem_data
Clears all FEM data (materials, parts, sets, surfaces) from the model. The mesh nodes and elements are preserved; only FEM-specific data is removed.
Signature:
clear_fem_data(volumeMeshName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
Returns: bool — True if the FEM data was cleared successfully; false otherwise.
add_material
Adds a material to the FEM model. If the volume mesh does not yet have an FEM model, one is created automatically before the material is added.
Signature:
add_material(volumeMeshName: str, params: FemMaterialParams) -> str
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
params | any | Material parameters including name, properties, and model type. Create using api.FemMaterialParams(). |
Returns: str — The name of the created material (which may differ from the requested name if it had to be made unique), or an empty string if creation failed.
update_material
Updates an existing material's properties.
Signature:
update_material(volumeMeshName: str, materialName: str, params: FemMaterialParams) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
materialName | any | The name of the material to update. |
params | any | New material parameters. Create using api.FemMaterialParams(). |
Returns: bool — True if the material was updated successfully; false otherwise.
remove_material
Removes a material from the FEM model.
Signature:
remove_material(volumeMeshName: str, materialName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
materialName | any | The name of the material to remove. |
Returns: bool — True if the material was removed successfully; false otherwise.
assign_elements_to_part
Assigns elements to a part.
Signature:
assign_elements_to_part(volumeMeshName: str, partName: str, elementIds: list) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
partName | any | The name of the part. |
elementIds | any | List of element IDs to assign to the part. |
Returns: bool — True if elements were assigned successfully; false otherwise.
assign_material_to_part
Assigns a material to a part.
Signature:
assign_material_to_part(volumeMeshName: str, partName: str, materialName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
partName | any | The name of the part. |
materialName | any | The name of the material to assign. |
Returns: bool — True if the material was assigned successfully; false otherwise.
update_part
Updates a part's properties.
Signature:
update_part(volumeMeshName: str, partName: str, params: FemPartParams) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
partName | any | The name of the part to update. |
params | any | New part parameters. Create using api.FemPartParams(). |
Returns: bool — True if the part was updated successfully; false otherwise.
remove_part
Removes a part from the FEM model.
Signature:
remove_part(volumeMeshName: str, partName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
partName | any | The name of the part to remove. |
Returns: bool — True if the part was removed successfully; false otherwise.
detect_boundary_surfaces
Automatically detects and creates external boundary surfaces. Detects the outer (free) faces of the mesh and stores them as a single boundary surface. If the volume mesh does not yet have an FEM model, one is created automatically.
Signature:
detect_boundary_surfaces(volumeMeshName: str, surfaceName: str = "BoundarySurface") -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
surfaceName | any | The name for the boundary surface. Defaults to "BoundarySurface". |
Returns: bool — True if boundary surfaces were detected and created; false otherwise.
remove_surface
Removes a surface from the FEM model.
Signature:
remove_surface(volumeMeshName: str, surfaceName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
surfaceName | any | The name of the surface to remove. |
Returns: bool — True if the surface was removed successfully; false otherwise.
rename_surface
Renames a surface.
Signature:
rename_surface(volumeMeshName: str, oldName: str, newName: str) -> bool
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
oldName | any | The current name of the surface. |
newName | any | The new name for the surface. |
Returns: bool — True if the surface was renamed successfully; false otherwise.
File System
export_to_abaqus
Exports the FEM model to Abaqus format (.inp). The model is validated first; if validation fails, the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_abaqus(volumeMeshName: str, outputPath: str, options: FemAbaqusExportOptions = FemAbaqusExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output file path (should end with .inp). |
options | any | Abaqus-specific export options. Create using api.FemAbaqusExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
export_to_nastran
Exports the FEM model to Nastran format (.nas/.bdf). The model is validated first; if validation fails, the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_nastran(volumeMeshName: str, outputPath: str, options: FemNastranExportOptions = FemNastranExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output file path (should end with .nas or .bdf). |
options | any | Nastran-specific export options. Create using api.FemNastranExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
export_to_ls_dyna
Exports the FEM model to LS-DYNA format (.k/.dyn). The model is validated first; if validation fails, the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_ls_dyna(volumeMeshName: str, outputPath: str, options: FemLsDynaExportOptions = FemLsDynaExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output file path (should end with .k or .dyn). |
options | any | LS-DYNA-specific export options. Create using api.FemLsDynaExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
export_to_open_foam
Exports the FEM model to OpenFOAM polyMesh format. The model is validated first; if validation fails, the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_open_foam(volumeMeshName: str, outputPath: str, options: FemOpenFOAMExportOptions = FemOpenFOAMExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output directory path for the OpenFOAM case. |
options | any | OpenFOAM-specific export options. Create using api.FemOpenFOAMExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
export_to_fluent
Exports the FEM model to Fluent format (.msh). The model is validated first; if validation fails, the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_fluent(volumeMeshName: str, outputPath: str, options: FemFluentExportOptions = FemFluentExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output file path (should end with .msh). |
options | any | Fluent-specific export options. Create using api.FemFluentExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
export_to_gmsh
Exports the FEM model to Gmsh format (.msh). The model is validated first; if validation fails, the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_gmsh(volumeMeshName: str, outputPath: str, options: FemGmshExportOptions = FemGmshExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output file path (should end with .msh). |
options | any | Gmsh-specific export options. Create using api.FemGmshExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
export_to_format
Exports the FEM model to a specified format. Uses only the common export options; format-specific options are left at their defaults. For finer control, use the dedicated export function for the target format. The model is validated first; if validation fails (or the format is unsupported), the returned result has success=false and errorMessage set, and no file is written. Raises an error if the volume mesh has no FEM model.
Signature:
export_to_format(volumeMeshName: str, outputPath: str, format: FemExportFormat, options: FemExportOptions = FemExportOptions()) -> FemExportResult
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh. |
outputPath | any | The output file path. |
format | any | The export format. Use api.FemExportFormat.Abaqus, Nastran, etc. |
options | any | Common export options. Create using api.FemExportOptions(). |
Returns: FemExportResult — Export result with status and statistics as api.FemExportResult.
UI
show_node_sets
Shows or hides visualization for specific node sets in the 3D view. Displays selected node sets as colored points in the 3D viewport. Each node set is rendered with a distinct color from the predefined color palette.
Signature:
show_node_sets(volumeMeshName: str, nodeSetNames: list, visible: bool = True) -> None
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh containing the FEM model. |
nodeSetNames | any | List of node set names to visualize. Empty list shows all node sets. |
visible | any | True to show visualization, false to hide. |
show_element_sets
Shows or hides visualization for specific element sets in the 3D view. Displays selected element sets as colored semi-transparent cells with edges. Useful for inspecting specific regions or material zones in the mesh.
Signature:
show_element_sets(volumeMeshName: str, elementSetNames: list, visible: bool = True) -> None
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh containing the FEM model. |
elementSetNames | any | List of element set names to visualize. Empty list shows all element sets. |
visible | any | True to show visualization, false to hide. |
show_surfaces
Shows or hides visualization for specific surfaces in the 3D view. Displays boundary surfaces with color coding and edge highlighting. Surfaces are rendered semi-transparently to allow viewing internal structures.
Signature:
show_surfaces(volumeMeshName: str, surfaceNames: list, visible: bool = True) -> None
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh containing the FEM model. |
surfaceNames | any | List of surface names to visualize. Empty list shows all surfaces. |
visible | any | True to show visualization, false to hide. |
show_parts
Shows or hides visualization for specific parts in the 3D view. Displays parts as colored regions using their assigned material colors (if set) or automatic color assignment from the palette. Parts are rendered with edges for clear boundary identification.
Signature:
show_parts(volumeMeshName: str, partNames: list, visible: bool = True) -> None
Parameters:
| Parameter | Type | Description |
|---|---|---|
volumeMeshName | any | The name of the volume mesh containing the FEM model. |
partNames | any | List of part names to visualize. Empty list shows all parts. |
visible | any | True to show visualization, false to hide. |