Body#

class ansys.mechanical.stubs.v241.Ansys.ACT.Automation.Mechanical.Body#

Bases: object

Defines a Body.

Overview#

Activate

Activate the current object.

AddCommandSnippet

Creates a new CommandSnippet

AddComment

Creates a new child Comment.

AddFigure

Creates a new child Figure.

AddImage

Creates a new child Image.

AddPythonCodeEventBased

Creates a new PythonCodeEventBased

ClearGeneratedData

Run the ClearGeneratedData action.

CopyTo

Copies all visible properties from this object to another.

CreateParameter

Creates a new parameter for a Property.

Duplicate

Creates a copy of the current DataModelObject.

GenerateMesh

Run the GenerateMesh action.

GetChildren

Gets the list of children, filtered by type.

GetGeoBody

Gets the Geo Body

GetParameter

Gets the parameter corresponding to the given property.

GroupAllSimilarChildren

Run the GroupAllSimilarChildren action.

GroupSimilarObjects

Run the GroupSimilarObjects action.

PreviewInflation

Run the PreviewInflation action.

PreviewSurfaceMesh

Run the PreviewSurfaceMesh action.

PropertyByAPIName

Get a property by its API name.

PropertyByName

Get a property by its unique name.

RemoveParameter

Removes the parameter from the parameter set corresponding to the given property.

ShowBody

Run the ShowBody action.

Update

Run the Update action.

Assignment

Gets or sets the Assignment.

Average

Gets the Average.

BeamSection

Gets the BeamSection.

Behavior

Gets or sets the Behavior.

BrickIntegrationScheme

Gets or sets the BrickIntegrationScheme.

CentroidX

Gets the CentroidX.

CentroidY

Gets the CentroidY.

CentroidZ

Gets the CentroidZ.

Children

Gets the list of children.

Color

Gets or sets the Color, encoded as a BGR bitfield.

Comments

Gets the list of associated comments.

ConfigurationId

Gets the related Result Mesh's ConfigurationId.

CoordinateSystem

Gets or sets the CoordinateSystem.

CrossSectionArea

Gets the CrossSectionArea.

CrossSectionIYY

Gets the CrossSectionIYY.

CrossSectionIZZ

Gets the CrossSectionIZZ.

CrossSectionName

Gets CrossSectionName.

CrossSectionSelection

Gets or sets the CrossSectionSelection.

DataModelObjectCategory

Gets the current DataModelObject's category.

Dimension

Gets or sets the Dimension.

Elements

Gets the Elements.

FiberAngle

Gets or sets the FiberAngle.

FiberCrossSectionArea

Gets or sets the FiberCrossSectionArea.

FiberSpacing

Gets or sets the FiberSpacing.

Figures

Gets the list of associated figures.

FluidCrossArea

Gets or sets the FluidCrossArea.

FluidDiscretization

Gets or sets the FluidDiscretization.

FluidSolidPhase

Gets or sets the FluidSolidPhase.

GeometryType

Gets the GeometryType.

Hidden

Hide or show the body.

HomogeneousMembrane

Gets or sets the HomogeneousMembrane.

Images

Gets the list of associated images.

InternalObject

Gets the internal object. For advanced usage only.

IsWindingBody

Gets the IsWindingBody.

Length

Gets the Length.

LengthX

Gets the LengthX.

LengthY

Gets the LengthY.

LengthZ

Gets the LengthZ.

LinkTrussBehavior

Gets or sets the LinkTrussBehavior.

ManualThicknessMode

Gets the ManualThicknessMode.

Mass

Gets the Mass.

Material

Gets or sets the Material.

MaterialPolarizationDirection

Gets or sets the MaterialPolarizationDirection.

Maximum

Gets the Maximum.

MeshMetric

Gets the MeshMetric.

MeshVersion

Gets the MeshVersion.

Minimum

Gets the Minimum.

ModelType

Gets or sets the ModelType.

MomentOfInertiaIp1

Gets the MomentOfInertiaIp1.

MomentOfInertiaIp2

Gets the MomentOfInertiaIp2.

MomentOfInertiaIp3

Gets the MomentOfInertiaIp3.

Nodes

Gets the Nodes.

NonlinearEffects

Gets or sets the NonlinearEffects.

NumberOfTurns

Gets or sets the NumberOfTurns.

OffsetMode

Gets or sets the OffsetMode.

OffsetType

Gets or sets the OffsetType.

OffsetX

Gets or sets the OffsetX.

OffsetY

Gets or sets the OffsetY.

PipeExternalDiameter

Gets the PipeExternalDiameter.

PipeInternalDiameter

Gets the PipeInternalDiameter.

PipeThickness

Gets the PipeThickness.

Properties

Gets the list of properties for this object.

ReadOnly

Gets or sets the ReadOnly.

ReferenceFrame

Gets or sets the ReferenceFrame.

ReferenceTemperature

Gets or sets the ReferenceTemperature.

ReferenceTemperatureValue

Gets or sets the ReferenceTemperatureValue.

ReinforcingStressState

Gets or sets the ReinforcingStressState.

ResultMeshId

Gets the related Result Mesh's ObjectId.

ShellOffsetType

Gets or sets the ShellOffsetType.

StandardDeviation

Gets the StandardDeviation.

StiffnessBehavior

Gets or sets the StiffnessBehavior.

StiffnessOption

Gets or sets the StiffnessOption.

Suppressed

Gets or sets the Suppressed.

SuppressedParameterized

Gets if the part suppressed property is parameterized.

SurfaceArea

Gets the SurfaceArea.

ThermalStrainEffects

Gets or sets the ThermalStrainEffects.

Thickness

Gets or sets the Thickness.

ThicknessMode

Gets the ThicknessMode.

Transparency

Gets or sets the Transparency. Values range from 0.0 (fully invisible) to 1.0 (fully visible).

Treatment

Gets or sets the Treatment.

UseReferenceTemperatureByBody

Gets or sets the UseReferenceTemperatureByBody.

UserNameChange

Gets the UserNameChange.

Visible

Gets or sets the Visible.

VisibleProperties

Gets the list of properties that are visible for this object.

Volume

Gets the Volume.

Property detail#

property Body.Assignment: str | None#

Gets or sets the Assignment.

property Body.Average: Ansys.Core.Units.Quantity | None#

Gets the Average.

property Body.BeamSection: Ansys.ACT.Automation.Mechanical.DataModelObject | None#

Gets the BeamSection.

property Body.Behavior: Ansys.Mechanical.DataModel.Enums.Model2DBehavior | None#

Gets or sets the Behavior.

property Body.BrickIntegrationScheme: Ansys.Mechanical.DataModel.Enums.BrickIntegrationScheme | None#

Gets or sets the BrickIntegrationScheme.

property Body.CentroidX: Ansys.Core.Units.Quantity | None#

Gets the CentroidX.

property Body.CentroidY: Ansys.Core.Units.Quantity | None#

Gets the CentroidY.

property Body.CentroidZ: Ansys.Core.Units.Quantity | None#

Gets the CentroidZ.

property Body.Children: List[Ansys.Mechanical.DataModel.Interfaces.IDataModelObject] | None#

Gets the list of children.

property Body.Color: int | None#

Gets or sets the Color, encoded as a BGR bitfield.

property Body.Comments: Iterable[Ansys.ACT.Automation.Mechanical.Comment] | None#

Gets the list of associated comments.

property Body.ConfigurationId: int | None#

Gets the related Result Mesh's ConfigurationId.

property Body.CoordinateSystem: Ansys.ACT.Automation.Mechanical.CoordinateSystem | None#

Gets or sets the CoordinateSystem.

property Body.CrossSectionArea: Ansys.Core.Units.Quantity | None#

Gets the CrossSectionArea.

property Body.CrossSectionIYY: Ansys.Core.Units.Quantity | None#

Gets the CrossSectionIYY.

property Body.CrossSectionIZZ: Ansys.Core.Units.Quantity | None#

Gets the CrossSectionIZZ.

property Body.CrossSectionName: str | None#

Gets CrossSectionName.

property Body.CrossSectionSelection: Ansys.ACT.Automation.Mechanical.CrossSection | None#

Gets or sets the CrossSectionSelection.

property Body.DataModelObjectCategory: Ansys.Mechanical.DataModel.Enums.DataModelObjectCategory | None#

Gets the current DataModelObject's category.

property Body.Dimension: Ansys.Mechanical.DataModel.Enums.ShellBodyDimension | None#

Gets or sets the Dimension.

property Body.Elements: int | None#

Gets the Elements.

property Body.FiberAngle: Ansys.Core.Units.Quantity | None#

Gets or sets the FiberAngle.

property Body.FiberCrossSectionArea: Ansys.Core.Units.Quantity | None#

Gets or sets the FiberCrossSectionArea.

property Body.FiberSpacing: Ansys.Core.Units.Quantity | None#

Gets or sets the FiberSpacing.

property Body.Figures: Iterable[Ansys.ACT.Automation.Mechanical.Figure] | None#

Gets the list of associated figures.

property Body.FluidCrossArea: Ansys.Core.Units.Quantity | None#

Gets or sets the FluidCrossArea.

property Body.FluidDiscretization: Ansys.Mechanical.DataModel.Enums.FluidDiscretizationType | None#

Gets or sets the FluidDiscretization.

property Body.FluidSolidPhase: Ansys.Mechanical.DataModel.Enums.PhaseType | None#

Gets or sets the FluidSolidPhase.

property Body.GeometryType: Ansys.Mechanical.DataModel.Enums.GeometryType | None#

Gets the GeometryType.

property Body.Hidden: bool | None#

Hide or show the body.

property Body.HomogeneousMembrane: bool | None#

Gets or sets the HomogeneousMembrane.

property Body.Images: Iterable[Ansys.ACT.Automation.Mechanical.Image] | None#

Gets the list of associated images.

property Body.InternalObject: Ansys.Common.Interop.DSObjectsAuto.IDSPrototypeAuto | None#

Gets the internal object. For advanced usage only.

property Body.IsWindingBody: bool | None#

Gets the IsWindingBody.

property Body.Length: Ansys.Core.Units.Quantity | None#

Gets the Length.

property Body.LengthX: Ansys.Core.Units.Quantity | None#

Gets the LengthX.

property Body.LengthY: Ansys.Core.Units.Quantity | None#

Gets the LengthY.

property Body.LengthZ: Ansys.Core.Units.Quantity | None#

Gets the LengthZ.

property Body.LinkTrussBehavior: Ansys.Mechanical.DataModel.Enums.PrototypeLinkBehavior | None#

Gets or sets the LinkTrussBehavior.

property Body.ManualThicknessMode: bool | None#

Gets the ManualThicknessMode.

property Body.Mass: Ansys.Core.Units.Quantity | None#

Gets the Mass.

property Body.Material: str | None#

Gets or sets the Material.

property Body.MaterialPolarizationDirection: Ansys.Mechanical.DataModel.Enums.MaterialPolarizationDirection | None#

Gets or sets the MaterialPolarizationDirection.

property Body.Maximum: Ansys.Core.Units.Quantity | None#

Gets the Maximum.

property Body.MeshMetric: Ansys.Mechanical.DataModel.Enums.MeshMetricType | None#

Gets the MeshMetric.

property Body.MeshVersion: int | None#

Gets the MeshVersion.

property Body.Minimum: Ansys.Core.Units.Quantity | None#

Gets the Minimum.

property Body.ModelType: Ansys.Mechanical.DataModel.Enums.PrototypeModelType | None#

Gets or sets the ModelType. Note: ModelType is applicable to line bodies and surface bodies only.

property Body.MomentOfInertiaIp1: Ansys.Core.Units.Quantity | None#

Gets the MomentOfInertiaIp1.

property Body.MomentOfInertiaIp2: Ansys.Core.Units.Quantity | None#

Gets the MomentOfInertiaIp2.

property Body.MomentOfInertiaIp3: Ansys.Core.Units.Quantity | None#

Gets the MomentOfInertiaIp3.

property Body.Nodes: int | None#

Gets the Nodes.

property Body.NonlinearEffects: bool | None#

Gets or sets the NonlinearEffects.

property Body.NumberOfTurns: int | None#

Gets or sets the NumberOfTurns.

property Body.OffsetMode: Ansys.Mechanical.DataModel.Enums.AutomaticOrManual | None#

Gets or sets the OffsetMode.

property Body.OffsetType: Ansys.Mechanical.DataModel.Enums.BeamOffsetType | None#

Gets or sets the OffsetType.

property Body.OffsetX: Ansys.Core.Units.Quantity | None#

Gets or sets the OffsetX.

property Body.OffsetY: Ansys.Core.Units.Quantity | None#

Gets or sets the OffsetY.

property Body.PipeExternalDiameter: Ansys.Core.Units.Quantity | None#

Gets the PipeExternalDiameter.

property Body.PipeInternalDiameter: Ansys.Core.Units.Quantity | None#

Gets the PipeInternalDiameter.

property Body.PipeThickness: Ansys.Core.Units.Quantity | None#

Gets the PipeThickness.

property Body.Properties: tuple[Ansys.ACT.Automation.Mechanical.Property] | None#

Gets the list of properties for this object.

property Body.ReadOnly: bool | None#

Gets or sets the ReadOnly.

property Body.ReferenceFrame: Ansys.Mechanical.DataModel.Enums.ReferenceFrameType | None#

Gets or sets the ReferenceFrame.

property Body.ReferenceTemperature: bool | None#

Gets or sets the ReferenceTemperature.

property Body.ReferenceTemperatureValue: Ansys.Core.Units.Quantity | None#

Gets or sets the ReferenceTemperatureValue.

property Body.ReinforcingStressState: Ansys.Mechanical.DataModel.Enums.ReinforcingStressState | None#

Gets or sets the ReinforcingStressState.

property Body.ResultMeshId: int | None#

Gets the related Result Mesh's ObjectId.

property Body.ShellOffsetType: Ansys.Mechanical.DataModel.Enums.ShellOffsetType | None#

Gets or sets the ShellOffsetType.

property Body.StandardDeviation: Ansys.Core.Units.Quantity | None#

Gets the StandardDeviation.

property Body.StiffnessBehavior: Ansys.Mechanical.DataModel.Enums.StiffnessBehavior | None#

Gets or sets the StiffnessBehavior.

property Body.StiffnessOption: Ansys.Mechanical.DataModel.Enums.ShellElementStiffnessOption | None#

Gets or sets the StiffnessOption.

property Body.Suppressed: bool | None#

Gets or sets the Suppressed.

property Body.SuppressedParameterized: bool | None#

Gets if the part suppressed property is parameterized.

property Body.SurfaceArea: Ansys.Core.Units.Quantity | None#

Gets the SurfaceArea.

property Body.ThermalStrainEffects: bool | None#

Gets or sets the ThermalStrainEffects.

property Body.Thickness: Ansys.Core.Units.Quantity | None#

Gets or sets the Thickness.

property Body.ThicknessMode: bool | None#

Gets the ThicknessMode.

property Body.Transparency: float | None#

Gets or sets the Transparency. Values range from 0.0 (fully invisible) to 1.0 (fully visible).

property Body.Treatment: Ansys.Mechanical.DataModel.Enums.BodyTreatment | None#

Gets or sets the Treatment.

property Body.UseReferenceTemperatureByBody: bool | None#

Gets or sets the UseReferenceTemperatureByBody.

property Body.UserNameChange: bool | None#

Gets the UserNameChange.

property Body.Visible: bool | None#

Gets or sets the Visible.

property Body.VisibleProperties: tuple[Ansys.ACT.Automation.Mechanical.Property] | None#

Gets the list of properties that are visible for this object.

property Body.Volume: Ansys.Core.Units.Quantity | None#

Gets the Volume.

Method detail#

Body.Activate() None#

Activate the current object.

Body.AddCommandSnippet() Ansys.ACT.Automation.Mechanical.CommandSnippet#

Creates a new CommandSnippet

Body.AddComment() Ansys.ACT.Automation.Mechanical.Comment#

Creates a new child Comment.

Body.AddFigure() Ansys.ACT.Automation.Mechanical.Figure#

Creates a new child Figure.

Body.AddImage(filePath: str) Ansys.ACT.Automation.Mechanical.Image#
Creates a new child Image.
If a filePath is provided, the image will be loaded from that file,
if not, the image will be a screen capture of the Geometry window.
Body.AddPythonCodeEventBased() Ansys.ACT.Automation.Mechanical.PythonCodeEventBased#

Creates a new PythonCodeEventBased

Body.ClearGeneratedData() None#

Run the ClearGeneratedData action.

Body.CopyTo(other: Ansys.ACT.Automation.Mechanical.DataModelObject) None#

Copies all visible properties from this object to another.

Body.CreateParameter(propName: str) Ansys.ACT.Interfaces.Mechanical.IParameter#

Creates a new parameter for a Property.

Body.Duplicate() Ansys.Mechanical.DataModel.Interfaces.IDataModelObject#

Creates a copy of the current DataModelObject.

Body.GenerateMesh() None#

Run the GenerateMesh action.

Body.GetChildren(recurses: bool, children: List[ChildrenType]) List[ChildrenType]#

Gets the list of children, filtered by type.

Body.GetGeoBody() Ansys.ACT.Interfaces.Geometry.IGeoBody#

Gets the Geo Body

Body.GetParameter(propName: str) Ansys.ACT.Interfaces.Mechanical.IParameter#

Gets the parameter corresponding to the given property.

Body.GroupAllSimilarChildren() None#

Run the GroupAllSimilarChildren action.

Body.GroupSimilarObjects() Ansys.ACT.Automation.Mechanical.TreeGroupingFolder#

Run the GroupSimilarObjects action.

Body.PreviewInflation() None#

Run the PreviewInflation action.

Body.PreviewSurfaceMesh() None#

Run the PreviewSurfaceMesh action.

Body.PropertyByAPIName(name: str) Ansys.ACT.Automation.Mechanical.Property#
Get a property by its API name.
If multiple properties have the same API Name, only the first property with that name will be returned.
Body.PropertyByName(name: str) Ansys.ACT.Automation.Mechanical.Property#

Get a property by its unique name.

Body.RemoveParameter(propName: str) None#

Removes the parameter from the parameter set corresponding to the given property.

Body.ShowBody() None#

Run the ShowBody action.

Body.Update() None#

Run the Update action.