pw:: VolumeMesher

The volume mesher mode type

Derives From

pw::Object pw::Mode

Notes

This mode is used to create volume (block) grid entities from surface (domain) grid entities.

Unlike other modes, the state of the mode is saved when it is ended and subsequent modes will be created with the same state.  This state is also saved in the application project file, so a new mode created after a file is loaded will have the same state as the last mode ended before saving the file.

To create a mode of this type, use the pw::Application.begin command with the mode VolumeMesher specified, like this:

set mesher [pw::Application begin VolumeMesher $domains]

To modify a volume using this mode, use the pw::Application.begin command with the mode VolumeMesher specified, like this:

set mesher [pw::Application begin VolumeMesher $unstructuredBlock]
Summary
The volume mesher mode type
This attribute controls the mesh type that will be produced.
This attribute controls the shape type that will be used on the farfield of the volume mesh.
This attribute controls how the shape handles symmetry conditions of the enclosed mesh.
This attribute controls the placement of the first symmetry plane.
This attribute controls the placement of the second symmetry plane.
This attribute controls the size field decay factor used when a size field is generated for this entity.
This attribute is the size background spacing when a size field is generated for this entity.
This attribute controls which primary axes the shape is aligned with.
This attribute controls the length dimension of the farfield.
This attribute controls the width dimension of the farfield.
This attribute controls the height dimension of the farfield.
This attribute controls the radii of the farfield caps.
This attribute controls the radius of the farfield.
This attribute controls the boundary layer type to be applied to resulting volume meshes.
This attribute controls the wall normal spacing to be applied to the nearfield boundary mesh.
This attribute is the growth rate of T-Rex layers of an unstructured block when it is created.
This attribute is the minimum buffer to be maintained between encroaching extruded tetrahedrals of an unstructured block when it is created.
This attribute specifies the scale factor to be applied to the local isotropic height at which T-Rex stops layer growth via deformation, decimation or refinement.
This attribute specifies the maximum included angle quality threshold for T-Rex cells.
This attribute specifies the maximum centroid skew quality threshold for T-Rex cells.
This attribute is the minimum voxel size of the voxel mesh.
This attribute is the maximum voxel size of the voxel mesh.
This attribute is the number of layers between voxel size transitions of the voxel mesh of this block.
This command creates the volume grid entities according to the attributes applied to the pw::VolumeMesher mode.
This command creates a new boundary condition filter.
This command deletes a boundary condition filter.
This command gets all boundary condition filter names.
This command updates a boundary condition filter’s name.
This command sets the boundary condition filter’s T-Rex type.
This command gets the boundary condition filter’s T-Rex type.
This command sets the boundary condition filter’s adaption type.
This command gets the boundary condition filter’s adaption type.
This command sets the boundary condition filter’s T-Rex condition value.
This command gets the boundary condition filter’s T-Rex condition value.
This command sets the boundary condition filter’s patterns.
This command gets the boundary condition filter’s patterns.
This action returns a list of domains associated with a boundary condition filter.
This action sets the priority of one or more existing boundary condition filters.

Instance Attributes

MeshType

$mesher get/setMeshType mesh

This attribute controls the mesh type that will be produced.

Type

This attribute is a string with options < Unstructured | Voxel >.

Default

The default for this attribute is Unstructured

FarfieldShapeType

$mesher get/setFarfieldShapeType shape

This attribute controls the shape type that will be used on the farfield of the volume mesh.

Type

This attribute is a string with options < Box | Cylinder | Sphere | None >.  If None is specified, then the volume will be created solely from the domains supplied when the mode began with the requisite that the domains must form a watertight surface.

Default

The default for this attribute is Box

SymmetryMode

$mesher get/setSymmetryMode mode

This attribute controls how the shape handles symmetry conditions of the enclosed mesh.  If set to automatic, then symmetry will be automatically detected and applied to the resulting block.  If set to manual, then symmetry will be applied according to the specified symmetry plane attributes.

This attribute is not applicable with the farfield shape type of None is specified.

Type

This attribute is a string with options < Automatic | Manual >.

Default

The default for this attribute is Automatic

SymmetryPlane1

$mesher get/setSymmetryPlane1 plane

This attribute controls the placement of the first symmetry plane.

This attribute is only applicable when the symmetry mode is set to manual and the farfield shape type is not set to None.

Type

This attribute is a string with options < None | +X | -X | +Y | -Y | +Z | -Z >.

Default

The default for this attribute is None

SymmetryPlane2

$mesher get/setSymmetryPlane2 plane

This attribute controls the placement of the second symmetry plane.

This attribute is only applicable when the symmetry mode is set to manual and the farfield shape type is not set to None.

Type

This attribute is a string with options < None | X+ | X- | Y+ | Y- | Z+ | Z- >.

Default

The default for this attribute is None

SizeFieldDecay

$mesher get/setSizeFieldDecay < Automatic | value >

This attribute controls the size field decay factor used when a size field is generated for this entity.  The size field will use this decay for entities added to the size field that don’t have a explicitly assigned decay.

This attribute is not applicable if the farfield shape type of None is specified.

Type

This attribute is either the string “Automatic” or a float with the range [0.0, 1.0].

Default

The default for this attribute is the value is Automatic.

SizeFieldBackgroundSpacing

$mesher get/setSizeFieldBackgroundSpacing < Automatic | value >

This attribute is the size background spacing when a size field is generated for this entity.

This attribute is not applicable if the farfield shape type of None is specified.

Type

This attribute is either the string “Automatic” or a float with the range [0, infinity).

Default

The default for this attribute is the value is Automatic.

ShapeAlignment

$mesher get/setShapeAlignment shape

This attribute controls which primary axes the shape is aligned with.

That this attribute is only applicable for cylinder shapes.

Type

This attribute is a string with options < Automatic | X | Y | Z >.

Default

The default for this attribute is X.

FarfieldLength

$mesher get/setFarfieldLength < Automatic | lengths >

This attribute controls the length dimension of the farfield.

That this attribute is only applicable to box and cylinder farfield shapes.

Type

This attribute is either the string “Automatic” or a list of two float values each within the range [0.0, infinity).  The two float values describe the positive and negative length of the shape respectively.

Default

The default for this attribute Automatic.

FarfieldWidth

$mesher get/setFarfieldWidth < Automatic | widths >

This attribute controls the width dimension of the farfield.

That this attribute is only applicable to box farfield shapes.

Type

This attribute is either the string “Automatic” or a list of two float values each within the range [0.0, infinity).  The two float values describe the positive and negative width of the shape respectively.

Default

The default for this attribute Automatic.

FarfieldHeight

$mesher get/setFarfieldHeight < Automatic | heights >

This attribute controls the height dimension of the farfield.

That this attribute is only applicable to box farfield shapes.

Type

This attribute is either the string “Automatic” or a list of two float values each within the range [0.0, infinity).  The two float values describe the positive and negative height of the shape respectively.

Default

The default for this attribute Automatic.

FarfieldCapRadii

$mesher get/setFarfieldCapRadii < Automatic | radii >

This attribute controls the radii of the farfield caps.

That this attribute is only applicable to cylinder farfield shapes.

Type

This attribute is either the string “Automatic” or a list of two float values each within the range [0.0, infinity).  The first float value describes the radius of the top cylinder cap, and the second float value describes the radius of the base cylinder cap.

Default

The default for this attribute Automatic.

FarfieldRadius

$mesher get/setFarfieldRadius < Automatic | radius >

This attribute controls the radius of the farfield.

That this attribute is only applicable to sphere farfield shapes.

Type

This attribute is either the string “Automatic” or a float value within the range [0.0, infinity) that describes the radius of the sphere.

Default

The default for this attribute Automatic.

BoundaryLayerType

$mesher get/setBoundaryLayerType type

This attribute controls the boundary layer type to be applied to resulting volume meshes.

Type

This attribute is a string with options < Off | GeometricGrowth >.

Default

The default for this attribute is Off

WallNormalSpacing

$mesher get/setWallNormalSpacing spacing

This attribute controls the wall normal spacing to be applied to the nearfield boundary mesh.

This attribute only applies when the boundary layer type is set to Geometric Growth and only to those domains which belong to the “Boundary Layer” boundary condition filter.

Type

This attribute is a float with the range [0, infinity).

Default

The default for this attribute is 0.01

GrowthRate

$mesher get/setGrowthRate growth

This attribute is the growth rate of T-Rex layers of an unstructured block when it is created.

This attribute only applies when the boundary layer type is set to Geometric Growth.

Type

This default is a float with the range [1.0, infinity).

Default

The default for this attribute is 1.2

CollisionBuffer

$mesher get/setCollisionBuffer < Automatic | value >

This attribute is the minimum buffer to be maintained between encroaching extruded tetrahedrals of an unstructured block when it is created.

This attribute only applies when the boundary layer type is set to Geometric Growth.

Type

This attribute is either the string “Automatic” or a float with the range [0, infinity).

Default

The default for this attribute is the value is Automatic.

FinalCellAspectRatio

$mesher get/setFinalCellAspectRatio < Automatic | value >

This attribute specifies the scale factor to be applied to the local isotropic height at which T-Rex stops layer growth via deformation, decimation or refinement.

When set to 1.0, anisotropic cell growth continues at each vertex until one of the tets below the vertex reaches its isotropic height.  When a value other that 1.0 is selected, the isotropic height criteria is multiplied by the value, meaning that it is possible to stop vertex advancement prior (value < 1) or beyond (value> 1) true isotropy.

This attribute only applies when the boundary layer type is set to Geometric Growth.

Type

This attribute is either the string “Automatic” or a float with the range (0.0, infinity).

Default

The default for this attribute is the value is Automatic.

MaxIncludedAngle

$mesher get/setMaxIncludedAngle < Automatic | value >

This attribute specifies the maximum included angle quality threshold for T-Rex cells.  If the criterion cannot be met the cell will be discarded and the front is stopped locally.

This attribute only applies when the boundary layer type is set to Geometric Growth.

Type

This attribute is either the string “Automatic” or a float with the range [60.0, 180.0], 180.0 disables the quality check.

Default

The default for this attribute is the value is Automatic.

CentroidSkewness

$mesher get/setCentroidSkewness < Automatic | value >

This attribute specifies the maximum centroid skew quality threshold for T-Rex cells.  If the criterion cannot be met the cell will be discarded and the front is stopped locally.

This attribute only applies when the boundary layer type is set to Geometric Growth.

Type

This attribute is either the string “Automatic” or a float with the range [0.0, 1.0], where 1.0 disables the quality check.

Default

The default for this attribute is the value is Automatic.

VoxelMinimumSize

$mesher get/setVoxelMinimumSize < Automatic | value >

This attribute is the minimum voxel size of the voxel mesh.

This attribute only applies when the mesh type is set to voxel.

Type

This attribute is either the string “Automatic” or a float with the range [0, infinity).

Default

The default for this attribute is the value is Automatic.

VoxelMaximumSize

$mesher get/setVoxelMaximumSize < Automatic | value >

This attribute is the maximum voxel size of the voxel mesh.

This attribute only applies when the mesh type is set to voxel.

Type

This attribute is either the string “Automatic” or a float with the range [0, infinity).

Default

The default for this attribute is the value is Automatic.

VoxelTransitionLayers

$mesher get/setVoxelTransitionLayers < Automatic | value >

This attribute is the number of layers between voxel size transitions of the voxel mesh of this block.

This attribute only applies when the mesh type is set to voxel.

Type

This attribute is either the string “Automatic” or an integer with the range [1, 100].

Default

The default for this attribute is the value is Automatic.

Instance Actions

createGridEntities

$mesher createGridEntities

This command creates the volume grid entities according to the attributes applied to the pw::VolumeMesher mode.

Returns

This action returns a list of pw::GridEntity objects.

addBoundaryConditionFilter

$mesher addBoundaryConditionFilter name

This command creates a new boundary condition filter.  Filters apply to all domains associated with the volume created in the mode.  If a domain’s name matches a filter’s pattern, then that domain will be assigned to the boundary condition that the filter represents.

Parameters

nameThis parameter is the string boundary condition filter name.

Returns

This action returns the name of the added filter.

deleteBoundaryConditionFilter

$mesher deleteBoundaryConditionFilter name

This command deletes a boundary condition filter.

Parameters

nameThis parameter is the string boundary condition filter name.

Returns

This action returns nothing.

getBoundaryConditionFilterNames

$mesher getBoundaryConditionFilterNames

This command gets all boundary condition filter names.

Returns

A list of strings of the boundary condition filter names.

setBoundaryConditionFilterName

$mesher setBoundaryConditionFilterName oldName newName

This command updates a boundary condition filter’s name.

Parameters

oldNameThis parameter is the string boundary condition filter name.
newNameThis parameter is the string name to replace the current name.

Returns

This action returns nothing.

setBoundaryConditionFilterType

$mesher setBoundaryConditionFilterType name type

This command sets the boundary condition filter’s T-Rex type.

parameter

nameThis parameter is the string boundary condition filter name.
typeThis attribute is a string with values < Off | Wall | Angle | Match | AdjacentGrid | AspectRatio | MaximumAspectRatio >.

Returns

This action returns nothing.

getBoundaryConditionFilterType

$mesher getBoundaryConditionFilterType name

This command gets the boundary condition filter’s T-Rex type.

parameter

nameThis parameter is the string boundary condition filter name.

Returns

This action returns a string with values < Off | Wall | Angle | Match | AdjacentGrid | AspectRatio | MaximumAspectRatio >.

setBoundaryConditionFilterAdaptation

$mesher setBoundaryConditionFilterAdaptation name adapt

This command sets the boundary condition filter’s adaption type.

parameter

nameThis parameter is the string boundary condition filter name.
adaptThis attribute is a string with values < Off | On >.

Returns

This action returns nothing.

getBoundaryConditionFilterAdaptation

$mesher getBoundaryConditionFilterAdaptation name

This command gets the boundary condition filter’s adaption type.

parameter

nameThis parameter is the string boundary condition filter name.

Returns

This action returns a string with values < Off | On >

setBoundaryConditionFilterValue

$mesher setBoundaryConditionFilterValue name value

This command sets the boundary condition filter’s T-Rex condition value.  If the boundary condition filter’s T-Rex condition type is Wall, the value is the spacing.  If the condition type is Angle, the value is the angle.  If the condtion type is AspectRatio or MaximumAspectRatio, the value is the aspect ratio.

parameter

nameThis parameter is the string boundary condition filter name.
valueThis attribute is a float.

Returns

This action returns nothing.

getBoundaryConditionFilterValue

$mesher getBoundaryConditionFilterValue name

This command gets the boundary condition filter’s T-Rex condition value.  If the boundary condition filter’s T-Rex condition type is Wall, the value is the spacing.  If the condition type is Angle, the value is the angle.  If the condtion type is AspectRatio or MaximumAspectRatio, the value is the aspect ratio.

parameter

nameThis parameter is the string boundary condition filter name.
valueThis attribute is a float.

Returns

This action returns a float.

setBoundaryConditionFilterPatterns

$mesher setBoundaryConditionFilterPatterns name patterns

This command sets the boundary condition filter’s patterns.  The filter’s pattern is used to select grid entities for boundary condition assignment.

parameter

nameThis parameter is the string boundary condition filter name.
patternsThis parameter defines a list of string patterns that will be used to match against domains in the volume created by the mode.  The order of the patterns is important and is applied from first to last.  Domains on the sides of the grid shape that is used to create the volume will not have names until after the volume is generated.  To match against these domains, use the following special names: “TopSide”, “BaseSide”, “MiddleSide-1”, “MiddleSide-2”, “MiddleSide-3”, “MiddleSide-4”, “SymmetrySide-1”, and “SymmetrySide-2”.

Returns

This action returns nothing.

getBoundaryConditionFilterPatterns

$mesher getBoundaryConditionFilterPatterns name

This command gets the boundary condition filter’s patterns.  The filter’s pattern is used to select grid entities for boundary condition assignment.

parameter

nameThis parameter is the string boundary condition filter name.

Returns

This action returns the list of string patterns that are used to match against domains in the volume created by the mode.

getBoundaryConditionFilterGroups

$mesher getBoundaryConditionFilterGroups ?-shapeSides sidesVar? name

This action returns a list of domains associated with a boundary condition filter.

Parameters

-shapeSides sidesVarThis optional parameter is a string variable name which will be assigned with a list of string names that correspond to grid shape sides.  The possible grid shape side names and “TopSide”, “BaseSide”, “MiddleSide1”, “MiddleSide2”, “MiddleSide3”, “MiddleSide4”, “SymmetrySide1” and “SymmetrySide2”.
nameThis parameter is the string boundary condition filter name.  In addition to any boundary filters created with addBoundaryConditionFilter, the reserved boundary filter names of “Boundary Layer”, “Match”, “Symmetry”, “Isotropic”, and “Periodic” can be used to get the domains associated with those classifications.  These reserved names are populated with domains that were not filtered out by any of the added boundary filters.

Returns

This action returns the list of pw::Domain that match the specified filter.

setBoundaryConditionFilterPriority

$mesher setBoundaryConditionFilterPriority nameList

This action sets the priority of one or more existing boundary condition filters.

Parameters

nameListThis parameter is a list of string boundary condition filter names.  Any filters not in nameList will be prioritized after the entities in nameList.

Returns

This action returns nothing.

$mesher get/setMeshType mesh
This attribute controls the mesh type that will be produced.
$mesher get/setFarfieldShapeType shape
This attribute controls the shape type that will be used on the farfield of the volume mesh.
$mesher get/setSymmetryMode mode
This attribute controls how the shape handles symmetry conditions of the enclosed mesh.
$mesher get/setSymmetryPlane1 plane
This attribute controls the placement of the first symmetry plane.
$mesher get/setSymmetryPlane2 plane
This attribute controls the placement of the second symmetry plane.
$mesher get/setSizeFieldDecay < Automatic | value >
This attribute controls the size field decay factor used when a size field is generated for this entity.
$mesher get/setSizeFieldBackgroundSpacing < Automatic | value >
This attribute is the size background spacing when a size field is generated for this entity.
$mesher get/setShapeAlignment shape
This attribute controls which primary axes the shape is aligned with.
$mesher get/setFarfieldLength < Automatic | lengths >
This attribute controls the length dimension of the farfield.
$mesher get/setFarfieldWidth < Automatic | widths >
This attribute controls the width dimension of the farfield.
$mesher get/setFarfieldHeight < Automatic | heights >
This attribute controls the height dimension of the farfield.
$mesher get/setFarfieldCapRadii < Automatic | radii >
This attribute controls the radii of the farfield caps.
$mesher get/setFarfieldRadius < Automatic | radius >
This attribute controls the radius of the farfield.
$mesher get/setBoundaryLayerType type
This attribute controls the boundary layer type to be applied to resulting volume meshes.
$mesher get/setWallNormalSpacing spacing
This attribute controls the wall normal spacing to be applied to the nearfield boundary mesh.
$mesher get/setGrowthRate growth
This attribute is the growth rate of T-Rex layers of an unstructured block when it is created.
$mesher get/setCollisionBuffer < Automatic | value >
This attribute is the minimum buffer to be maintained between encroaching extruded tetrahedrals of an unstructured block when it is created.
$mesher get/setFinalCellAspectRatio < Automatic | value >
This attribute specifies the scale factor to be applied to the local isotropic height at which T-Rex stops layer growth via deformation, decimation or refinement.
$mesher get/setMaxIncludedAngle < Automatic | value >
This attribute specifies the maximum included angle quality threshold for T-Rex cells.
$mesher get/setCentroidSkewness < Automatic | value >
This attribute specifies the maximum centroid skew quality threshold for T-Rex cells.
$mesher get/setVoxelMinimumSize < Automatic | value >
This attribute is the minimum voxel size of the voxel mesh.
$mesher get/setVoxelMaximumSize < Automatic | value >
This attribute is the maximum voxel size of the voxel mesh.
$mesher get/setVoxelTransitionLayers < Automatic | value >
This attribute is the number of layers between voxel size transitions of the voxel mesh of this block.
$mesher createGridEntities
This command creates the volume grid entities according to the attributes applied to the pw::VolumeMesher mode.
The volume mesher mode type
$mesher addBoundaryConditionFilter name
This command creates a new boundary condition filter.
$mesher deleteBoundaryConditionFilter name
This command deletes a boundary condition filter.
$mesher getBoundaryConditionFilterNames
This command gets all boundary condition filter names.
$mesher setBoundaryConditionFilterName oldName newName
This command updates a boundary condition filter’s name.
$mesher setBoundaryConditionFilterType name type
This command sets the boundary condition filter’s T-Rex type.
$mesher getBoundaryConditionFilterType name
This command gets the boundary condition filter’s T-Rex type.
$mesher setBoundaryConditionFilterAdaptation name adapt
This command sets the boundary condition filter’s adaption type.
$mesher getBoundaryConditionFilterAdaptation name
This command gets the boundary condition filter’s adaption type.
$mesher setBoundaryConditionFilterValue name value
This command sets the boundary condition filter’s T-Rex condition value.
$mesher getBoundaryConditionFilterValue name
This command gets the boundary condition filter’s T-Rex condition value.
$mesher setBoundaryConditionFilterPatterns name patterns
This command sets the boundary condition filter’s patterns.
$mesher getBoundaryConditionFilterPatterns name
This command gets the boundary condition filter’s patterns.
$mesher getBoundaryConditionFilterGroups ?-shapeSides sidesVar? name
This action returns a list of domains associated with a boundary condition filter.
$mesher setBoundaryConditionFilterPriority nameList
This action sets the priority of one or more existing boundary condition filters.
Base type for all glyph types
The mode base type
pw::Application begin ?-mode_specific_flags? mode ?entities?
This action begins a mode in the application.
A string is an array of characters.
A float is a fractional number.
An integer is a whole number.
Base type for all grid entities
Domain type