export_FEA_model#
- Model.export_FEA_model(project, cca_name, export_file, analysis, drill_hole_parameters, detect_lead_modeling, lead_model_parameters, display_model, clear_FEA_database, use_FEA_model_id, coordinate_units)#
Export a FEA model.
- Parameters:
- project: str
Name of the Sherlock project.
- cca_name: str
Name of the CCA.
- export_file: str
Full path for saving exported files to. The file extension must be
.wbjn
.- analysis: str
The type of analysis that is being exported. Valid values are
NaturalFreq
,HarmonicVibe
,ICTAnalysis
,MechanicalShock
orRandomVibe
.- drill_hole_parameters: list[dict[str, str | Measurement]]
List of the drill hole parameters consisting of these properties:
- drill_hole_modeling: str
The status of the drill hole modeling feature. If enabled, automatically enable drill hole modeling. Valid values are
ENABLED/enabled
orDISABLED/disabled
.
- min_hole_diameter: MinHoleDiameter
The properties of the minimum hole diameter.
- max_edge_length: MaxEdgeLength
The properties of the maximum edge length.
- detect_lead_modeling: str
The status of the detect lead modeling feature. If enabled, automatically enable lead modeling if any part has lead geometry defined. Valid values are
ENABLED
orDISABLED
.- lead_model_parameters: list[dict[str, int | str | Measurement]]
List of the lead model parameters consisting of these properties:
- lead_modeling: str
The status of the lead modeling feature. If enabled, automatically enable lead modeling. Valid values are
ENABLED
orDISABLED
.
- lead_element_order: str
The type of the element order. Valid values are
First Order (Linear)
,Second Order (Quadratic)
, orSolid Shell
.
- max_mesh_size: MaxMeshSize
The properties of the maximum mesh size.
- vertical_mesh_size: VerticalMeshSize
The properties of the vertical mesh size.
- thicknessCount: int, optional
- The number of elements through the lead thickness that will be created per lead.
The default value is 3 and the maximum is 5. Only used when the advanced lead mesh setting is enabled.
- aspectRatio: int, optional
The aspect ratio is multiplied by the lead thickness divided by the through thickness count to give the lead element height. The default value is 2 and the maximum is 10. Only used when the advanced lead mesh setting is enabled.
- display_model: bool
Whether to display the model after export.
- clear_FEA_database: bool
Whether to clear FEA database before defining model.
- use_FEA_model_id: bool
Whether to use FEA model ID.
- coordinate_units: str
Units of the model coordinates to use when exporting a model.
- Returns:
- :
int
Status code of the response. 0 for success.
- Return type:
Examples
>>> from ansys.sherlock.core.launcher import launch_sherlock >>> from ansys.sherlock.core.types.common_types import ( Measurement, ) >>> sherlock = launch_sherlock() >>> sherlock.model.export_FEA_model( project="Test Project", cca_name="Main Board", export_file="C:/Temp/export.wbjn", analysis="NaturalFreq", drill_hole_parameters=[ { "drill_hole_modeling": "ENABLED", "min_hole_diameter": Measurement(value=0.5, unit="mm"), "max_edge_length": Measurement(value=1.0, unit="mm") } ], detect_lead_modeling="ENABLED", lead_model_parameters=[ { "lead_modeling": "ENABLED", "lead_element_order": "First Order (Linear)", "max_mesh_size": Measurement(value=0.5, unit="mm"), "vertical_mesh_size": Measurement(value=0.1, unit="mm"), "thicknessCount": 3, "aspectRatio": 2 } ], display_model=True, clear_FEA_database=True, use_FEA_model_id=True, coordinate_units="mm" )