Mesh

Mesh
This container holds Mesh data for an instance of the Meshing application.

Methods

Edit

Opens the Meshing editor. If the editor has never been opened, the command will import the geometry file associated with the Geometry cell in the Mesh system.

Optional Arguments

Interactive    Specifies whether the editor should open in interactive mode. The default value is true.
    Type     bool
    Default Value    True
Example

To edit the mesh component with default optional parameter values:

    mesh.Edit()

Or by specifying optional parameter values:

    mesh.Edit(Interactive=True )


Exit

Exits the Meshing editor.

Optional Arguments

SaveDatabase    Bool flag to save the database on exit of the editor
    Type     bool
    Default Value    True

Export

Saves the current state of the Meshing editor and exports a *.meshdat file. If the Meshing editor is not currently open, the cached state (the state of the editor the last time it was closed) of the Meshing editor will be exported.

Required Arguments

FilePath    The path and name of the .meshdat file to be written.
    Type     string

ExportASMJournal

Exports an ASM Journal (.wbjn) and supporting files for the model component.

Required Arguments

FilePath    The path and name of the .wbjn file to be written. Supporting files written alongside.
    Type     string

ExportGeometry

Exports a PartManager database (.pmdb) file for the geometry in the model component.

Required Arguments

FilePath    The path and name of the .pmdb file to be written.
    Type     string

ExportMesh

Exports a .acmo file for the mesh in the model component.

Required Arguments

FilePath    The path and name of the .acmo file to be written.
    Type     string

GetMechanicalMeshFile

Returns the data reference to the container's MechanicalMeshFile data entity.

Return     A reference to the requested MechanicalMeshFile data entity.
    Type     DataReference

GetMechanicalModel

Returns the data reference to the container's MechanicalModel data entity.

Return     A reference to the requested MechanicalModel data entity.
    Type     DataReference

GetMechanicalSystemType

Returns the data reference to the container's MechanicalSystemType data entity.

Return     A reference to the requested MechanicalSystemType data entity.
    Type     DataReference

GetMeshingImportOptions

Query to return the data reference to the meshing import options

Return     The Data Entity containing settings for this component.
    Type     DataReference

Required Arguments

Name    The entity of interest.
    Type     string

GetMeshProperties

Query to return the data reference to the meshing properties

Return     The Data Entity containing settings for this component.
    Type     DataReference

Import

Import a mesh data file. This action will delete the geometry container from the Mesh system and convert the Mesh cell into a file container. It is not possible to view meshes that are imported through this command in the Meshing editor; however, the files imported can be transferred to downstream mesh consumers (such as CFX, FLUENT, etc.) by way of normal component to component data transfer.

Required Arguments

FilePath    The data file to be imported.
    Type     string
MeshType    The type of mesh data file.
    Type     MeshFileType
Example

To import a data file into the mesh component with default optional parameter values:

    mesh.Import(FilePath=r"C:\temp\data.cfx", MeshType="CFX")


SendCommand

Sends commands to the Meshing editor using JScript or Python syntax.

If the Meshing editor is not open, then the editor's GUI will not be available to the script, causing some commands to fail. In this case, consider calling Edit() to open the editor before using SendCommand. Furthermore,if the Meshing editor is not open,SendCommand will start the editor without GUI,issue the specified command,and then close the editor. For multiple SendCommands,this may degrade performance.

Required Arguments

Command    The command(s) to execute in the Meshing editor.
    Type    string

Optional Arguments

Language    Language of the command. The default value of Language is "Javascript".
    Type    string
    Default Value    Javascript
Example

To execute some arbitrary command (in this case, causing a dialog box to appear) in the Meshing editor:

    mesh.SendCommand(Command=r"WBScript.Out("My Text",true);" )


Data Entities

GeneralMeshAssemblyProperties

Class used to expose general properties for the mesh assembly workflow

Properties

DisplayText

The general property that defines the user-visible name of an entity. This property is defined for all data entities but is used only in those entities that present a label in the user interface.

Type     string
Read Only    No
GroupObjectsBySource

Group objects in Meshing based on source

Type     bool
Read Only    No
LengthUnit

Target Length Unit for Assembled Model

Type     string
Read Only    No
ObjectRenaming

Name objects in Meshing based on selected option

Type     ObjectRenamingTypeInMeshing
Read Only    No

MechanicalModel

The data entity that contains the identifiers which maintain a relationship between the Mesh data contain and the objects in the Meshing editor tree.

Properties

Caption

Caption to identify the model.

Type     string
Read Only    No
DisplayText

The general property that defines the user-visible name of an entity. This property is defined for all data entities but is used only in those entities that present a label in the user interface.

Type     string
Read Only    No
ModelId

Identifier which corresponds to the Model object in the Meshing editor tree. This ID can be used in conjunction with SendCommand to perform operations such as inserting mesh controls or manipulating mesh settings within the Meshing editor itself.

Type     int
Read Only    No
PrototypeId

Identifier which corresponds to the Geometry object in the Meshing editor tree. This ID can be used in conjunction with SendCommand to perform operations such as inserting mesh controls or manipulating mesh settings within the Meshing editor itself.

Type     int
Read Only    No

MechanicalSystemType

This entity provides string based information about the physics, analysis, and solver settings for the Mesh component. As the Mesh component may be used independent of any specific physics, analysis, or solver, the properties exposed by this entity may take a value of "Any", meaning simply that it is up to the user to initialize and correctly configure the mesh settings within the Meshing editor.

Properties

AnalysisTypeDisplayString

The string which represents the current analysis type setting - this value will always be "Any".

Type     string
Read Only    Yes
DisplayText

The general property that defines the user-visible name of an entity. This property is defined for all data entities but is used only in those entities that present a label in the user interface.

Type     string
Read Only    No
ICEngineAutoSetup

The boolean which represents the IC Engine mesh setup options.

Type     bool
Read Only    No
ICEngineMeshSettings

The string is a hyper link which opens the IC Engine mesh setting dialog.

Type     string
Read Only    No
PhysicsTypeDisplayString

The string which represents current physics type setting - the value can be "Any" or "CFD".

Type     string
Read Only    Yes
RefMeshSize

The quantity represent the reference mesh size for IC Engine mesh settings.

Type     Quantity
Read Only    No
SolverTypeDisplayString

The string which represents the current solver setting - the value can be "Any", "FLUENT", "CFX", or "POLYFLOW".

Type     string
Read Only    Yes

MeshConversionOptions

(Beta) Entity to control the Skin Detection algorithm for importing cdb files.

Properties

BodyGroupingType

Body grouping type

Type     BodyGroupingType
Read Only    No
ComponentKey

If the nodal components will be processed during CDB components the nodal component key will allow filtering of which components to process

Type     string
Read Only    No
CreateGeometry

Flag to create geometry

Type     bool
Read Only    No
CreateGeometryEdgeComponents

Should the geometry edge named selections be created during CDB conversion

Type     bool
Read Only    No
CreateGeometryFaceComponents

Should the geometry face named selections be created during CDB conversion

Type     bool
Read Only    No
CreateGeometryVertexComponents

Should the geometry vertex named selections be created during CDB conversion

Type     bool
Read Only    No
CutAngle

Only displayed if Forbid Close Components equals Yes. It is the angle used to cut closed surfaces to separate the elements into components.

Type     Quantity
Read Only    No
DisplayText

The general property that defines the user-visible name of an entity. This property is defined for all data entities but is used only in those entities that present a label in the user interface.

Type     string
Read Only    No
ForbidCloseComponents

Option to split closed surfaces into several components.If Yes then the algorithm cuts closed surfaces into several components. It provides a simple method to avoid problematic faces on closed surfaces.

Type     bool
Read Only    No
GeometryImportAnalysisType

The geometry attach type for the CDB file

Type     GeometryAttachType
Read Only    No
ProcessLineBodies

Should line bodies be processed during the CDB conversion

Type     bool
Read Only    No
ToleranceAngle

The tolerance angle to seperate two elements into seperate components. If the angle between the normals of two adjacent elements is less than or equal to the Tolerance Angle then the two elements are in the same component, otherwise, they are separated.

Type     Quantity
Read Only    No
VertexInsertionAngle

The Vertex Insertion Angle is the minimunm angle to insert a vertex between two free edges of mesh. During the generation of the geometry, if two segments of an edge abruptly make an angle greater than the Vertex Insertion Angle, then the edge is split and a vertex is inserted.

Type     Quantity
Read Only    No

MeshingImportOptions

Import options for model assembly available on the downstream model

Properties

DisplayText

The general property that defines the user-visible name of an entity. This property is defined for all data entities but is used only in those entities that present a label in the user interface.

Type     string
Read Only    No
MirrorTransform

Mirror Transformations for the Source Geometry

Type     MirrorTransformOptionsForMeshing
Read Only    No
NumberOfCopies

By default this value is 0, specifies how many additional copies of the upstream mesh are needed

Type     int
Read Only    No
RenumberMeshElementsAutomatically

By default this value is true, specifies whether the user would like us to automatically renumber his mesh elements to prevent unique id conflicts during assembly

Type     bool
Read Only    No
RigidTransform

Rigid Transformations for the Source Geometry

Type     RigidTransformOptionsForMeshing
Read Only    No
Source

The upstream mesh source

Type     DataReference
Read Only    No
TransformationType

Which type of transform we should display to the user

Type     TransformType
Read Only    No

MeshProperties

Contains properties to control mesh generation in Meshing application

Properties

DisplayText

The general property that defines the user-visible name of an entity. This property is defined for all data entities but is used only in those entities that present a label in the user interface.

Type     string
Read Only    No
saveMeshFileInSeparateFile

Group objects in Meshing based on source

Type     bool
Read Only    No