Implicit (hwx.inspire.implicit)#

class Implicit(assembly=None)#

Bases: Part

Implicit modelling represents geometry as a field and is highly efficient in terms of computation and rendering. Users can design very intricate geometries, such as lattices, whilst exploiting exceptional robustness during Boolean operations, offsets, shells, fillets, etc. It also enables field-driven design, where geometry can be tightly controlled using relationships with other geometry, simulation results, custom equations, and much more.

Attribute Table#

Name

Type

bodies

property

visualizationQuality

property

Method Table#

Name

Description

abs (self, bodyA)

Implicit absolute value operation.

acos (self, bodyA)

Implicit Trigonometry ACos operation.

acosh (self, bodyA)

Implicit Trigonometry ACosh operation.

add (self, bodyA, bodyB)

Implicit Add operation.

asin (self, bodyA)

Implicit Trigonometry ASin operation.

asinh (self, bodyA)

Implicit Trigonometry ASinh operation.

atan (self, bodyA)

Implicit Trigonometry ATan operation.

atan2 (self, bodyA)

Implicit Trigonometry ATan2 operation.

atanh (self, bodyA)

Implicit Trigonometry ATanh operation.

ceil (self, bodyA)

Implicit ceil operation.

clamp (self, bodyA, bodyB, bodyC)

Implicit clamp operation.

combine (self, targets, transition=’SHARP’, transitionValue=0.002, transitionField=None)

The Combine tool is a Boolean Union operation between implicit bodies.

constant (self, value)

Implicit constant.

convertToImplicit (self, part)

The Convert tool accepts geometry in BRep or surface mesh formats and

cos (self, bodyA)

Implicit Trigonometry Cos operation.

createAxis (self, positionX=0, positionY=0, positionZ=0, normalX=0, normalY=0, normalZ=0)

Tool to create axis implicit body.

createBlankPart (assembly=None)

Creates Implicit blank part in space.

createCuboid (self, x=0.1, y=0.1, z=0.1, uniform=True, originX=0, originY=0, originZ=0)

Tool to create cubical implicit body.

createCustomImplicitBody (self, customUnitCell, minBounds, maxBounds)

Custom Implicit Body capability is available through the Python API.

createCylinder (self, radius=0.05, height=0.1, originX=0, originY=0, originZ=0)

Tool to create cylindrical implicit body.

createField (self, drivingObject, inputRangeMin=0, inputRangeMax=1, clamp=False, unitType=’Unitless’, outputRangeMin=0, outputRangeMax=1)

The Field tool is used to construct a field from a source that is not yet

createLine (self, startX=0, startY=0, startZ=0, endX=0, endY=0, endZ=0, thickness=0)

Tool to create line implicit body.

createPlane (self, positionX=0, positionY=0, positionZ=0, normalX=0, normalY=0, normalZ=0)

Tool to create plane implicit body.

createPoint (self, x=0, y=0, z=0)

Tool to create point implicit body.

createSphere (self, radius=0.05, originX=0, originY=0, originZ=0)

Tool to create spherical implicit body.

difference (self, targets, tools, transition=’SHARP’, transitionValue=0.002, transitionField=None)

The difference tool is used to cut ‘tool’ implicit bodies from ‘target’

divide (self, bodyA, bodyB)

Implicit Divide operation.

e (self)

Implicit Euler’s number(E).

edit (self)

Contextmanager to group multiple updates for performance.

equalTo (self, bodyA, bodyB)

Implicit equal to operation.

fillet (self, body, type=’ROUNDS’, filletRadius=0.002, roundRadius=0.002)

The Fillet tool applies a circular fillet of defined radius to sharp

floorDivision (self, bodyA, bodyB)

Implicit Floor Division operation.

fraction (self, bodyA)

Implicit fraction operation.

generalStrutLattice (self, body, hollow=False, solidRegion=False, coordinateSystemType=’CARTESIAN’, localOrigin=None, strutDiameter=0.005, strutDiameterField=None, strutInnerDiameter=0.003, strutInnerDiameterField=None, shell=False, combine=False, shellDirection=’OUTWARD’, shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition=’SHARP’, distance=0.01, distanceField=None, verts=None, beams=None)

Strut lattices are constructed from nodes and these nodes are connected

getBody (self, name)

To get the implicit bodies based on their names.

greaterOrEqualTo (self, bodyA, bodyB)

Implicit greater or equal to operation.

greaterThan (self, bodyA, bodyB)

Implicit greater than operation.

implIf (self, bodyA, bodyB, bodyC)

Implicit if operation.

intersect (self, targets, tools, transition=’SHARP’, transitionValue=0.002, transitionField=None)

The Intersection tool is used to find volumes of overlap between two or

invert (self, body)

The Invert tool swaps the convention of ‘inside’ and ‘outside’ for an

lessOrEqualTo (self, bodyA, bodyB)

Implicit less or equal to operation.

lessThan (self, bodyA, bodyB)

Implicit less than operation.

max (self, bodyA, bodyB)

Implicit min operation.

min (self, bodyA, bodyB)

Implicit min operation.

mod (self, bodyA, bodyB)

Implicit Mod operation.

morph (self, bodyA, bodyB, morphValue=0.5, morphValueField=None)

The Morph tool performs a morphing operation between two implicit

moveBodies (self, body, position)

The Move Bodies tool is used to transform implicit bodies in terms of

multiply (self, bodyA, bodyB)

Implicit Multiply operation.

offset (self, body, direction=’OUTWARD’, outwardOffset=0.01, outwardOffsetField=None, inwardOffset=0.01, inwardOffsetField=None, shell=False)

The Offset tool can be used to inwardly (negative) or outwardly

pi (self)

Implicit pi.

planarLattice (self, body, unitCellType=’HEXAGON’, solidRegion=False, coordinateSystemType=’CARTESIAN’, localOriginX=0, localOriginY=0, localOriginZ=0, localOrigin=None, thickness=0.005, thicknessField=None, unitCellSize=False, uniform=True, unitCellSizeX=4, unitCellSizeXField=None, unitCellSizeY=4, unitCellSizeYField=None, planeVectorX=0, planeVectorY=0, planeVectorZ=1, shell=False, combine=False, shellDirection=’OUTWARD’, shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition=’SHARP’, distance=0.01, distanceField=None)

Planar lattices are 2.5 dimensional cellular structures, with a clearly

pointCloud (self, points, weights, interpolation=’INVERSE_DISTANCE’, exponent=2)

Create a custom implicit field or geometry from a set of points with

power (self, bodyA, bodyB)

Implicit Power operation.

sign (self, bodyA)

Implicit sign operation.

sin (self, bodyA)

Implicit Trigonometry Sin operation.

smooth (self, body, type=’GAUSSIAN’, width=1, iterations=1, strength=100)

The Smooth tool is used to reduce the size of, or remove, unwanted small

sqrt (self, bodyA)

Implicit sqrt operation.

step (self, bodyA, bodyB)

Implicit step operation.

strutLattice (self, body, unitCellType=’CORNERDIAGONAL’, hollow=False, solidRegion=False, coordinateSystemType=’CARTESIAN’, localOriginX=0, localOriginY=0, localOriginZ=0, localOrigin=None, strutDiameter=0.005, strutDiameterField=None, strutInnerDiameter=0.003, strutInnerDiameterField=None, unitCellSize=False, uniform=True, cellSizeX=4, cellSizeY=4, cellSizeZ=4, shell=False, combine=False, shellDirection=’OUTWARD’, shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition=’SHARP’, distance=0.01, distanceField=None, unitCellName=None, nodes=None, connectivity=None)

Strut lattices are constructed from nodes and these nodes are connected

subtract (self, bodyA, bodyB)

Implicit Subtract operation.

surfaceLattice (self, body, unitCellType=’GYROID’, surfaceType=True, solidRegion=False, coordinateSystemType=’CARTESIAN’, localOriginX=0, localOriginY=0, localOriginZ=0, localOrigin=None, density=0.5, densityField=None, bias=0.5, unitCellSize=False, uniform=True, cellSizeX=4, cellSizeXField=None, cellSizeY=4, cellSizeYField=None, cellSizeZ=4, cellSizeZField=None, shell=False, combine=False, shellDirection=’OUTWARD’, shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition=’SHARP’, distance=0.01, distanceField=None)

Surface lattices are cellular structures constructed from one or

tan (self, bodyA)

Implicit Trigonometry Tan operation.

xRef (self)

Implicit X Reference.

yRef (self)

Implicit Y Reference.

zRef (self)

Implicit Z Reference.

Example

from hwx import inspire
inspire.newModel()

# Creating Implicit blank part.
implicitPart = inspire.Implicit()
implicitPart.name = "Implicit Part1"

# Creating Cuboid primitive in implicit part.
implicitPart.createCuboid(x="300 mm", originX=0.5)

# Creating Cuboid primitive in implicit part.
cuboid1 = implicitPart.createCuboid(x="200 mm")

# Creating Sphere primitive in implicit part.
sphere = implicitPart.createSphere(radius="200 mm", originX=1)

# Creating Planar Lattice with sphere
implicitPart.planarLattice(sphere, thickness=0.01, unitCellType= "DIAMOND")
print("Planar Lattice has been created using implicit sphere body.")


# Creating Cylinder primitive in implicit part.
cylinder = implicitPart.createCylinder(height="300 mm", radius="150 mm", originX=1.5)

# Smooth operation on cylinder.
implicitPart.smooth(cylinder, width=2)
print("Smooth has been created from Cylinder with round fillet type.")

# Offset operation on cuboid .
implicitPart.offset(cuboid1, outwardOffset=0.1)
print("Offset has been created from Cuboid in outward direction.")

# Creating Surface Lattice with cuboid
cuboid = implicitPart.bodies[0]
implicitPart.surfaceLattice(cuboid, density=0.3)
print("Surface Lattice has been created using implicit cuboid body.")

# Updating Surface Lattice.
with implicitPart.edit():
  surfaceLattice = implicitPart.bodies[-1]
  surfaceLattice.density = 0.6
  surfaceLattice.solidRegion = True

inspire.fitView()
getBody(name)#

To get the implicit bodies based on their names.

property visualizationQuality#

Returns the visualization quality of implicit part from the GUI.

property bodies#

“Returns list of implicit bodies.

edit()#

Contextmanager to group multiple updates for performance.

createSphere(radius=0.05, originX=0, originY=0, originZ=0)#

Tool to create spherical implicit body.

Parameters:
  • radius (float | str) – Radius of the spherical implicit object.

  • originX (float | str) – Origin value in X direction.

  • originY (float | str) – Origin value in Y direction.

  • originZ (float | str) – Origin value in Z direction.

Returns:

The newly created Sphere object.

Return type:

Sphere

createCuboid(x=0.1, y=0.1, z=0.1, uniform=True, originX=0, originY=0, originZ=0)#

Tool to create cubical implicit body.

Parameters:
  • x (float | str) – Length of cuboid.

  • y (float | str) – Breadth of cuboid.

  • z (float | str) – Height of cuboid.

  • uniform (bool) – If True, all sides are equal.

  • originX (float | str) – Origin value in X direction.

  • originY (float | str) – Origin value in Y direction.

  • originZ (float | str) – Origin value in Z direction.

Returns:

The newly created Cuboid object.

Return type:

Cuboid

createCylinder(radius=0.05, height=0.1, originX=0, originY=0, originZ=0)#

Tool to create cylindrical implicit body.

Parameters:
  • radius (float | str) – Radius of the cylindrical implicit object.

  • height (float | str) – Height of the cylindrical implicit object.

  • originX (float | str) – Origin value in X direction.

  • originY (float | str) – Origin value in Y direction.

  • originZ (float | str) – Origin value in Z direction.

Returns:

The newly created Cylinder object.

Return type:

Cylinder

createPoint(x=0, y=0, z=0)#

Tool to create point implicit body.

Parameters:
  • x (float | str) – Value in X direction for implicit point body.

  • y (float | str) – Value in Y direction for implicit point body.

  • z (float | str) – Value in Z direction for implicit point body.

Returns:

The newly created Point object.

Return type:

Point

createAxis(positionX=0, positionY=0, positionZ=0, normalX=0, normalY=0, normalZ=0)#

Tool to create axis implicit body.

Parameters:
  • positionX (float | str) – Position value in X direction for implicit axis body.

  • positionY (float | str) – Position value in Y direction for implicit axis body.

  • positionZ (float | str) – Position value in Z direction for implicit axis body.

  • normalX (float | str) – Normal value in X direction for implicit axis body.

  • normalY (float | str) – Normal value in Y direction for implicit axis body.

  • normalZ (float | str) – Normal value in Z direction for implicit axis body.

Returns:

The newly created Axis object.

Return type:

Axis

createLine(startX=0, startY=0, startZ=0, endX=0, endY=0, endZ=0, thickness=0)#

Tool to create line implicit body.

Parameters:
  • startX (float | str) – Start point value in X direction for implicit line body.

  • startY (float | str) – Start point value in Y direction for implicit line body.

  • startZ (float | str) – Start point value in Z direction for implicit line body.

  • endX (float | str) – End point value in X direction for implicit line body.

  • endY (float | str) – End point value in Y direction for implicit line body.

  • endZ (float | str) – End point value in Z direction for implicit line body.

  • thickness (float | str) – Thickness of the line.

Returns:

The newly created Line object.

Return type:

Line

createPlane(positionX=0, positionY=0, positionZ=0, normalX=0, normalY=0, normalZ=0)#

Tool to create plane implicit body.

Parameters:
  • positionX (float | str) – Position value in X direction for implicit plane body.

  • positionY (float | str) – Position value in Y direction for implicit plane body.

  • positionZ (float | str) – Position value in Z direction for implicit plane body.

  • normalX (float | str) – Normal value in X direction for implicit plane body.

  • normalY (float | str) – Normal value in Y direction for implicit plane body.

  • normalZ (float | str) – Normal value in Z direction for implicit plane body.

Returns:

The newly created Plane object.

Return type:

Plane

convertToImplicit(part)#

The Convert tool accepts geometry in BRep or surface mesh formats and converts into Altair’s implicit geometry format. The output is typically a Signed Distance Field (SDF) for the converted geometry.

Parameters:

part (Part) – Part to be converted in implicit object.

Returns:

The newly created ConvertToImplicit object.

Return type:

ConvertToImplicit

createCustomImplicitBody(customUnitCell, minBounds, maxBounds)#

Custom Implicit Body capability is available through the Python API. Here, we create a 3D voxel grid within a bounding box, and then populates each voxel (grid point) with a scalar value to create the field for the geometry. The computation of the scalar values is executed in user-defined Python scripts (including imported libraries, if needed). In this sense, the Custom Implicit Body makes Inspire Implicit Modelling infinitely customisable and extensible.

Parameters:
  • customUnitCell (Body) – Custom unit cell, created through implicit math functions.

  • minBounds (math.Point) – Minimum custom bounds for custom implicit body.

  • maxBounds (math.Point) – Maximum custom bounds for custom implicit body.

Returns:

The newly created CustomBody object.

Return type:

CustomBody

createField(drivingObject, inputRangeMin=0, inputRangeMax=1, clamp=False, unitType='Unitless', outputRangeMin=0, outputRangeMax=1)#

The Field tool is used to construct a field from a source that is not yet described in a field format and/or remap field values to different ranges. A field is a 3D grid, and each grid point contains a signed scalar value.

Parameters:
  • drivingObject (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • inputRangeMin (float | str) – Input Range minimum distance.

  • inputRangeMax (float | str) – Input Range maximum distance.

  • clamp (bool) – If True, it limits the values to between the range instead of extrapolating beyond the range otherwise not.

  • unitType (str) – Unit type for output range. - Length - Angle - Unitless - Percent

  • outputRangeMin (float | str) – Minimum output range.

  • outputRangeMax (float | str) – Maximum output range.

Returns:

The newly created Field object.

Return type:

Field

surfaceLattice(body, unitCellType='GYROID', surfaceType=True, solidRegion=False, coordinateSystemType='CARTESIAN', localOriginX=0, localOriginY=0, localOriginZ=0, localOrigin=None, density=0.5, densityField=None, bias=0.5, unitCellSize=False, uniform=True, cellSizeX=4, cellSizeXField=None, cellSizeY=4, cellSizeYField=None, cellSizeZ=4, cellSizeZField=None, shell=False, combine=False, shellDirection='OUTWARD', shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition='SHARP', distance=0.01, distanceField=None)#

Surface lattices are cellular structures constructed from one or sometimes two surfaces. Rather than tiling/patterning a base unit cell, the natural repetition of the surfaces creates a lattice-like structure automatically. Popular examples are Triply Periodic Minimal Surfaces (TPMS), such as the Gyroid.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • unitCellType (str) – Surface type for surface lattice. - GYROID - SCHWARZ_P - SCHWARZ_D - NEOVIUS - LIDINOID - FISCHER_KOCH_S - FISCHER_KOCH_Cs - FISCHER_KOCH_Y - FISCHER_KOCH_Cy - FRD - IWP - SPLIT_P - KARCHER_K - G_PRIME

  • surfaceType (bool) – If True, Surface type will be Single otherwise Double.

  • solidRegion (bool) – if True, solid region of surface is inverted otherwise regular.

  • coordinateSystemType (str) – Surface Lattice Layout. - CARTESIAN - CYLINDRICAL - SPHERICAL

  • localOriginX (float | str) – Local origin x direction value for surface lattice.

  • localOriginY (float | str) – Local origin y direction value for surface lattice.

  • localOriginZ (float | str) – Local origin z direction value for surface lattice.

  • localOrigin (math.Matrix44) – Local origin for the surface lattice.

  • density (float | str) – Density for surface lattice. Value range from 0 to 100.

  • densityField (Field) – Density field input, if density is not provided.

  • bias (float | str) – Bias for surface lattice. Applicable only when surfaceType is Double.

  • unitCellSize (bool) – If True, Unit cell size will be Absolute otherwise Cell Count.

  • uniform (bool) – If True, Unit cell will be uniform otherwise not.

  • cellSizeX (float | str) – Cell size for surface lattice in X direction.

  • cellSizeXField (Field) – Cell size field input, if cellSizeX not provided.

  • cellSizeY (float | str) – Cell size for surface lattice in Y direction.

  • cellSizeYField (Field) – Cell size field input, if cellSizeY not provided.

  • cellSizeZ (float | str) – Cell size for surface lattice in Z direction.

  • cellSizeZField (Field) – Cell size field input, if cellSizeZ not provided.

  • shell (bool) – It’s a outer body option. If True, outer body of surface lattice will be shell otherwise not.

  • combine (bool) – It’s a outer body option. If True, outer body of surface lattice will be combine otherwise not. At a time only one option can be true among combine and shell option.

  • shellDirection (str) – Shell Direction. - OUTWARD - INWARD - BOTH - SYMMETRY

  • shellThicknessIn (float | str) – Shell thickness inward for outer body of surface lattice.

  • shellThicknessInField (Field) – Shell inward thickness field input, if shellThicknessIn is not provided.

  • shellThicknessOut (float | str) – Shell thickness outward for outer body of surface lattice.

  • shellThicknessOutField (Field) – Shell outward thickness field input, if shellThicknessOut is not provided.

  • trimmingBody (Body) – Trim implicit body for surface lattice.

  • combineBody (Body) – Combine implicit body for surface lattice.

  • transition (str) – Transition type for outer body options. - SHARP - FILLET - CHAMFER

  • distance (float | str) – Distance for outer body options.

  • distanceField (Field) – Distance field input, if distance is not provided.

Returns:

The newly created SurfaceLattice object.

Return type:

SurfaceLattice

planarLattice(body, unitCellType='HEXAGON', solidRegion=False, coordinateSystemType='CARTESIAN', localOriginX=0, localOriginY=0, localOriginZ=0, localOrigin=None, thickness=0.005, thicknessField=None, unitCellSize=False, uniform=True, unitCellSizeX=4, unitCellSizeXField=None, unitCellSizeY=4, unitCellSizeYField=None, planeVectorX=0, planeVectorY=0, planeVectorZ=1, shell=False, combine=False, shellDirection='OUTWARD', shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition='SHARP', distance=0.01, distanceField=None)#

Planar lattices are 2.5 dimensional cellular structures, with a clearly defined 2D cross-section that is drawn or extruded along the third dimension. A popular example is a honeycomb structure.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • unitCellType (str) – UnitCellType for planar lattice. - HEXAGON - DIAMOND - RECTANGLE - TRIANGLE - ISOGRID - CIRCLE

  • coordinateSystemType (str) – Planar Lattice Layout. - CARTESIAN - CYLINDRICAL - SPHERICAL

  • solidRegion (bool) – if True, solid region of planar is inverted otherwise regular.

  • localOriginX (float | str) – Local origin x direction value for planar lattice.

  • localOriginY (float | str) – Local origin y direction value for planar lattice.

  • localOriginZ (float | str) – Local origin z direction value for planar lattice.

  • localOrigin (math.Matrix44) – Local origin for the planar lattice.

  • thickness (float | str) – Cell thickness of planar lattice.

  • thicknessField (Field) – Thickness field input, if thickness is not provided.

  • unitCellSize (bool) – If True, Unit cell size will be Absolute otherwise Cell Count.

  • uniform (bool) – If True, Unit cell will be uniform otherwise not.

  • unitCellSizeX (float | str) – Unit cell size value in X direction.

  • unitCellSizeXField (Field) – Unit cell size field in X direction, if unitCellSizeX is not provided.

  • unitCellSizeY (float | str) – Unit cell size value in Y direction.

  • unitCellSizeYField (Field) – Unit cell size field in Y direction, if unitCellSizeY is not provided.

  • planeVectorX (float | str) – Plane vector value in X direction.

  • planeVectorY (float | str) – Plane vector value in Y direction.

  • planeVectorZ (float | str) – Plane vector value in Z direction.

  • shell (bool) – It’s a outer body option. If True, outer body of planar lattice will be shell otherwise not.

  • combine (bool) – It’s a outer body option. If True, outer body of planar lattice will be combine otherwise not. At a time only one option can be true among combine and shell option.

  • shellDirection (str) – Shell Direction. - OUTWARD - INWARD - BOTH - SYMMETRY

  • shellThicknessIn (float | str) – Shell thickness inward for outer body of planar lattice.

  • shellThicknessInField (Field) – Shell inward thickness field input, if shellThicknessIn is not provided.

  • shellThicknessOut (float | str) – Shell thickness outward for outer body of planar lattice.

  • shellThicknessOutField (Field) – Shell outward thickness field input, if shellThicknessOut is not provided.

  • trimmingBody (Body) – Trim implicit body for planar lattice.

  • combineBody (Body) – Combine implicit body for planar lattice.

  • transition (str) – Transition type for outer body options. - SHARP - FILLET - CHAMFER

  • distance (float | str) – Distance for outer body options.

  • distanceField (Field) – Distance field input, if distance is not provided.

Returns:

The newly created PlanarLattice object.

Return type:

PlanarLattice

strutLattice(body, unitCellType='CORNERDIAGONAL', hollow=False, solidRegion=False, coordinateSystemType='CARTESIAN', localOriginX=0, localOriginY=0, localOriginZ=0, localOrigin=None, strutDiameter=0.005, strutDiameterField=None, strutInnerDiameter=0.003, strutInnerDiameterField=None, unitCellSize=False, uniform=True, cellSizeX=4, cellSizeY=4, cellSizeZ=4, shell=False, combine=False, shellDirection='OUTWARD', shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition='SHARP', distance=0.01, distanceField=None, unitCellName=None, nodes=None, connectivity=None)#

Strut lattices are constructed from nodes and these nodes are connected by beams. Typically, there is a base unit cell that is tiled/patterned in one, two, or three dimensions to form the overall lattices structure. A popular example is the Body Centred Cubic lattice.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • unitCellType (str) – UnitCellType for strut lattice. - CORNERDIAGONAL - FACECENTRE - FACEDIAGONAL - FACEEDGE - OCTAGON - HEXTRUSS - TETRAKAIDECAHEDRONEDGE - CUSTOM_UNIT_CELL

  • hollow (bool) – if True, Strut surface type will be hollow otherwise solid.

  • solidRegion (bool) – if True, solid region of strut is inverted otherwise regular.

  • coordinateSystemType (str) – Strut Lattice Layout. - CARTESIAN - CYLINDRICAL - SPHERICAL

  • localOriginX (float | str) – Local origin x direction value for strut lattice.

  • localOriginY (float | str) – Local origin y direction value for strut lattice.

  • localOriginZ (float | str) – Local origin z direction value for strut lattice.

  • localOrigin (math.Matrix44) – Local origin for the strut lattice.

  • strutDiameter (float | str) – Strut thickness of struct lattice.

  • strutDiameterField (Field) – Strut diameter field input, if strutDiameter is not provided.

  • strutInnerDiameter (float | str) – Shell thickness of strut lattice if it is hollow.

  • strutInnerDiameterField (Field) – Strut inner diameter field input, if strutInnerDiameter is not provided.

  • unitCellSize (bool) – If True, Unit cell size will be Absolute otherwise Cell Count.

  • uniform (bool) – If True, Unit cell will be uniform otherwise not.

  • cellSizeX (float | str) – Cell size for strut lattice in X direction.

  • cellSizeY (float | str) – Cell size for strut lattice in Y direction.

  • cellSizeZ (float | str) – Cell size for strut lattice in Z direction.

  • shell (bool) – It’s a outer body option. If True, outer body of strut lattice will be shell otherwise not.

  • combine (bool) – It’s a outer body option. If True, outer body of strut lattice will be combine otherwise not. At a time only one option can be true among combine and shell option.

  • shellDirection (str) – Shell Direction. - OUTWARD - INWARD - BOTH - SYMMETRY

  • shellThicknessIn (float | str) – Shell thickness inward for outer body of strut lattice.

  • shellThicknessInField (Field) – Shell inward thickness field input, if shellThicknessIn is not provided.

  • shellThicknessOut (float | str) – Shell thickness outward for outer body of strut lattice.

  • shellThicknessOutField (Field) – Shell outward thickness field input, if shellThicknessOut is not provided.

  • trimmingBody (Body) – Trim implicit body for strut lattice.

  • combineBody (Body) – Combine implicit body for strut lattice.

  • transition (str) – Transition type for outer body options. - SHARP - FILLET - CHAMFER

  • distance (float | str) – Distance for outer body options.

  • distanceField (Field) – Distance field input, if distance is not provided.

  • unitCellName (str) – Name of the custom unit cell for strut lattice.

  • nodes (list[math.Point]) – Node list of the custom unit cell for strut lattice.

  • connectivity (list[int]) – Connectivity of the custom unit cell for strut lattice.

Returns:

The newly created StrutLattice object.

Return type:

StrutLattice

generalStrutLattice(body, hollow=False, solidRegion=False, coordinateSystemType='CARTESIAN', localOrigin=None, strutDiameter=0.005, strutDiameterField=None, strutInnerDiameter=0.003, strutInnerDiameterField=None, shell=False, combine=False, shellDirection='OUTWARD', shellThicknessIn=0.1, shellThicknessInField=None, shellThicknessOut=0.1, shellThicknessOutField=None, trimmingBody=None, combineBody=None, transition='SHARP', distance=0.01, distanceField=None, verts=None, beams=None)#

Strut lattices are constructed from nodes and these nodes are connected by beams. Typically, there is a base unit cell that is tiled/patterned in one, two, or three dimensions to form the overall lattices structure. A popular example is the Body Centred Cubic lattice.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • hollow (bool) – if True, Strut surface type will be hollow otherwise solid.

  • solidRegion (bool) – if True, solid region of strut is inverted otherwise regular.

  • coordinateSystemType (str) – Strut Lattice Layout. - CARTESIAN - CYLINDRICAL - SPHERICAL

  • localOrigin (math.Matrix44) – Local origin for the strut lattice.

  • strutDiameter (float | str) – Strut thickness of struct lattice.

  • strutDiameterField (Field) – Strut diameter field input, if strutDiameter is not provided.

  • strutInnerDiameter (float | str) – Shell thickness of strut lattice if it is hollow.

  • strutInnerDiameterField (Field) – Strut inner diameter field input, if strutInnerDiameter is not provided.

  • shell (bool) – It’s a outer body option. If True, outer body of strut lattice will be shell otherwise not.

  • combine (bool) – It’s a outer body option. If True, outer body of strut lattice will be combine otherwise not. At a time only one option can be true among combine and shell option.

  • shellDirection (str) – Shell Direction. - OUTWARD - INWARD - BOTH - SYMMETRY

  • shellThicknessIn (float | str) – Shell thickness inward for outer body of strut lattice.

  • shellThicknessInField (Field) – Shell inward thickness field input, if shellThicknessIn is not provided.

  • shellThicknessOut (float | str) – Shell thickness outward for outer body of strut lattice.

  • shellThicknessOutField (Field) – Shell outward thickness field input, if shellThicknessOut is not provided.

  • trimmingBody (Body) – Trim implicit body for strut lattice.

  • combineBody (Body) – Combine implicit body for strut lattice.

  • transition (str) – Transition type for outer body options. - SHARP - FILLET - CHAMFER

  • distance (float | str) – Distance for outer body options.

  • distanceField (Field) – Distance field input, if distance is not provided.

  • verts (list[math.Point]) – Node list of the custom unit cell for strut lattice.

  • beams (list[int]) – Connectivity of the custom unit cell for strut lattice.

Returns:

The newly created GeneralStrutLattice object.

Return type:

GeneralStrutLattice

pointCloud(points, weights, interpolation='INVERSE_DISTANCE', exponent=2)#

Create a custom implicit field or geometry from a set of points with scalar values attached to them.

Parameters:
  • points (list[math.Point]) – A list of positional coordinates contained within the point cloud.

  • weights (list[Float]) – A list of scalar values associated with each point. A surface is created at the boundary between positive and negative regions.

  • interpolation (str) –

    Interpolation Type. - INVERSE_DISTANCE (Smooth gradient of values between the points) - NEAREST_NEIGHBOURS (The value in the field will correspond to the

    value associated with the closest point. This creates hard boundaries similar to Voronoi cells).

  • exponent (float) – The exponent used for the inverse distance interpolation 1 / (Distance^Exponent). A larger value will produce a gentler gradient between points.

Returns:

The newly created PointCloud object.

Return type:

PointCloud

moveBodies(body, position)#

The Move Bodies tool is used to transform implicit bodies in terms of their position and orientation in space.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • position (math.Matrix44) – Position for the body to move.

combine(targets, transition='SHARP', transitionValue=0.002, transitionField=None)#

The Combine tool is a Boolean Union operation between implicit bodies. This tool creates a new body that envelopes any volume that falls within at least one of bodies being combined. It is equivalent to a logical OR / disjunction.

Parameters:
  • targets (list[Body]) – List of Implicit target body, use bodies property to get all bodies from implicit part.

  • transition (str) – Transition Type. - SHARP - FILLET - CHAMFER

  • transitionValue (float | str) – Transition value for boolean combine.

  • transitionField (Field) – Transition field input if transitionValue is not provided.

Returns:

The newly created Combine object.

Return type:

Combine

difference(targets, tools, transition='SHARP', transitionValue=0.002, transitionField=None)#

The difference tool is used to cut ‘tool’ implicit bodies from ‘target’ implicit bodies. This tool creates a new implicit body that envelopes any volume that falls within any target but NOT within any tools. It is equivalent to a logical NOT / negation.

Parameters:
  • targets (list[Body]) – List of Implicit target body, use bodies property to get all bodies from implicit part.

  • tools (list[Body]) – List of Implicit tool body, use bodies property to get all bodies from implicit part.

  • transition (str) – Transition Type. - SHARP - FILLET - CHAMFER

  • transitionValue (float | str) – Transition value for boolean difference.

  • transitionField (Field) – Transition field input if transitionValue is not provided.

Returns:

The newly created Difference object.

Return type:

Difference

intersect(targets, tools, transition='SHARP', transitionValue=0.002, transitionField=None)#

The Intersection tool is used to find volumes of overlap between two or more implicit bodies.

Parameters:
  • targets (list[Body]) – List of Implicit target body, use bodies property to get all bodies from implicit part.

  • tools (list[Body]) – List of Implicit tool body, use bodies property to get all bodies from implicit part.

  • transition (str) – Transition Type. - SHARP - FILLET - CHAMFER

  • transitionValue (float | str) – Transition value for boolean intersect.

  • transitionField (Field) – Transition field input if transitionValue is not provided.

Returns:

The newly created Intersect object.

Return type:

Intersect

offset(body, direction='OUTWARD', outwardOffset=0.01, outwardOffsetField=None, inwardOffset=0.01, inwardOffsetField=None, shell=False)#

The Offset tool can be used to inwardly (negative) or outwardly (positive) offset the surface of an implicit body. The surface always moves in a direction that is normal to the original surface.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • direction (str) – Direction for offset. - OUTWARD - INWARD - BOTH - SYMMETRY BOTH and SYMMETRY are valid only if shell is True.

  • outwardOffset (float | str) – Outward Offset value for implicit body.

  • outwardOffsetField (Field) – Outward offset field input, if outwardOffset is not provided.

  • inwardOffset (float | str) – Inward Offset value for implicit body.

  • inwardOffsetField (Field) – Inward offset field input, if inwardOffset is not provided.

  • shell (True) – If True, create a shell for implicit body otherwise not.

Returns:

The newly created Offset object.

Return type:

Offset

invert(body)#

The Invert tool swaps the convention of ‘inside’ and ‘outside’ for an implicit body by reversing the sign of all scalar values in the underlying field.

Parameters:

body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

Returns:

The newly created Invert object.

Return type:

Invert

morph(bodyA, bodyB, morphValue=0.5, morphValueField=None)#

The Morph tool performs a morphing operation between two implicit bodies.

Parameters:
  • bodyA (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • morphValue (float | str) – The Morph Amount should lie between 0 and 100 and this controls the percentage of the morphing operation between Bodies A and B. A Morph Value of 0 would result in a perfect copy of the Body A, and a Morph amount of 100 would result in a perfect copy of the Body B.

  • morphValueField (Field) – The Morph Amount field input, if morphValue is not provided.

Returns:

The newly created Morph object.

Return type:

Morph

fillet(body, type='ROUNDS', filletRadius=0.002, roundRadius=0.002)#

The Fillet tool applies a circular fillet of defined radius to sharp edges in an implicit body. It can be separately applied to convex and concave edges. Unlike traditional CAD, the fillet effect will be applied to any qualifying edges in the model rather than those that are manually selected by a user.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • type (str) – Fillet type. - FILLETS - ROUNDS - BOTH

  • filletRadius (float | str) – Fillet radius if type is ‘FILLETS’.

  • roundRadius (float | str) – Round radius if type is ‘ROUNDS’.

Returns:

The newly created Fillet object.

Return type:

Fillet

smooth(body, type='GAUSSIAN', width=1, iterations=1, strength=100)#

The Smooth tool is used to reduce the size of, or remove, unwanted small and/or sharp features in an implicit body. It is analogous to ‘blurring’ in digital image processing. It operates by moving a window through the underlying field, performing filtering operations on the field values that fall within the window. Example smoothing filters include Mean, Median, Gaussian and Laplacian. Each of these have relative pros and cons, giving different smoothing effects.

Parameters:
  • body (Body) – Implicit body, use bodies property to get all bodies from implicit part.

  • type (str) – Smoothing type. - GAUSSIAN - LAPLACIAN - MEDIAN - MEAN

  • width (int | str) – Size of the smoothing kernel.

  • iterations (int | str) – Number of times the smoothing kernel runs for.

  • strength (float | str) – Smooth strength from 0 to 100.

Returns:

The newly created Smooth object.

Return type:

Smooth

add(bodyA, bodyB)#

Implicit Add operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created Add object.

Return type:

Add

subtract(bodyA, bodyB)#

Implicit Subtract operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created Subtract object.

Return type:

Subtract

multiply(bodyA, bodyB)#

Implicit Multiply operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created Multiply object.

Return type:

Multiply

divide(bodyA, bodyB)#

Implicit Divide operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created Divide object.

Return type:

Divide

floorDivision(bodyA, bodyB)#

Implicit Floor Division operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created FloorDivision object.

Return type:

FloorDivision

power(bodyA, bodyB)#

Implicit Power operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created Power object.

Return type:

Power

mod(bodyA, bodyB)#

Implicit Mod operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created Mod object.

Return type:

Mod

lessThan(bodyA, bodyB)#

Implicit less than operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created LessThan object.

Return type:

LessThan

lessOrEqualTo(bodyA, bodyB)#

Implicit less or equal to operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created LessOrEqualTo object.

Return type:

LessOrEqualTo

equalTo(bodyA, bodyB)#

Implicit equal to operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created EqualTo object.

Return type:

EqualTo

greaterThan(bodyA, bodyB)#

Implicit greater than operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created GreaterThan object.

Return type:

GreaterThan

greaterOrEqualTo(bodyA, bodyB)#

Implicit greater or equal to operation.

Parameters:
  • bodyA (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math operation, use bodies property to get all bodies from implicit part.

Returns:

The newly created GreaterOrEqualTo object.

Return type:

GreaterOrEqualTo

sin(bodyA)#

Implicit Trigonometry Sin operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Sin object.

Return type:

Sin

cos(bodyA)#

Implicit Trigonometry Cos operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Cos object.

Return type:

Cos

tan(bodyA)#

Implicit Trigonometry Tan operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Tan object.

Return type:

Tan

atan2(bodyA)#

Implicit Trigonometry ATan2 operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ATan2 object.

Return type:

ATan2

asin(bodyA)#

Implicit Trigonometry ASin operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ASin object.

Return type:

ASin

acos(bodyA)#

Implicit Trigonometry ACos operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ACos object.

Return type:

ACos

atan(bodyA)#

Implicit Trigonometry ATan operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ATan object.

Return type:

ATan

asinh(bodyA)#

Implicit Trigonometry ASinh operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ASinh object.

Return type:

ASinh

acosh(bodyA)#

Implicit Trigonometry ACosh operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ACosh object.

Return type:

ACosh

atanh(bodyA)#

Implicit Trigonometry ATanh operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ATanh object.

Return type:

ATanh

abs(bodyA)#

Implicit absolute value operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Abs object.

Return type:

Abs

ceil(bodyA)#

Implicit ceil operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Ceil object.

Return type:

Ceil

clamp(bodyA, bodyB, bodyC)#

Implicit clamp operation.

Parameters:
  • bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyC (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Clamp object.

Return type:

Clamp

implIf(bodyA, bodyB, bodyC)#

Implicit if operation.

Parameters:
  • bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyC (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created ImplIf object.

Return type:

ImplIf

min(bodyA, bodyB)#

Implicit min operation.

Parameters:
  • bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Min object.

Return type:

Min

max(bodyA, bodyB)#

Implicit min operation.

Parameters:
  • bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Max object.

Return type:

Max

step(bodyA, bodyB)#

Implicit step operation.

Parameters:
  • bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

  • bodyB (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Step object.

Return type:

Step

sign(bodyA)#

Implicit sign operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Sign object.

Return type:

Sign

sqrt(bodyA)#

Implicit sqrt operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Sqrt object.

Return type:

Sqrt

constant(value)#

Implicit constant.

Parameters:

value (float | str) – Constant value for implicit.

Returns:

The newly created Constant object.

Return type:

Constant

fraction(bodyA)#

Implicit fraction operation.

Parameters:

bodyA (Body) – Implicit body for math functions, use bodies property to get all bodies from implicit part.

Returns:

The newly created Fraction object.

Return type:

Fraction

pi()#

Implicit pi.

Returns:

The newly created Pi object.

Return type:

Pi

e()#

Implicit Euler’s number(E).

Returns:

The newly created E object.

Return type:

E

xRef()#

Implicit X Reference.

Returns:

The newly created XRef object.

Return type:

XRef

yRef()#

Implicit Y Reference.

Returns:

The newly created YRef object.

Return type:

YRef

zRef()#

Implicit Z Reference.

Returns:

The newly created ZRef object.

Return type:

ZRef