RAParticle#

class ansys.rocky.app.ra_particle.RAParticle#

Bases: ansys.rocky.app.ra_grid_process_element.RAGridProcessElementItem, ansys.rocky.app.ra_addins.ElementWithAddins, ansys.rocky.app._ra_orientation_mixin._RAOrientationMixin

Rocky PrePost Scripting wrapper for a particle in the project.

The wrapper corresponds to an individual Particle entry in the project’s data tree, below the “Particles” item. Particles can be retrieved from the RAStudy or the RAParticleCollection via:

particle_1 = study.GetElement('Particle 1')
particle_2 = particle_collection[1]
particle_3 = particle_collection.GetParticle('Particle 3')

Most particle properties, such as name, shape, aspect ratios, etc can be set directly via methods in this wrapper class. An exception is size-related methods, which must be configured via the RASizeDistributionList returned in GetSizeDistributionList().

Overview#

ImportFromSTL

Import a custom shape from the given stl filename into this particle.

ImportCustomFiber

Import a custom fiber shape from the given filename into this particle.

GetSizeDistributionList

Get a list of size distribution entries

GetUseMultipleElements

Whether the particle’s Composition is “Multiple Elements”.

SetUseMultipleElements

Set the particle’s Composition to “Multiple Elements” (True) or “Single Elements” (False).

IsConcave

Returns True if the particle is a concave custom polyhedron, and False otherwise.

GetBreakageModel

This docstring is overridden by the _GetBreakageModel’s at the end of the file.

GetValidBreakageModelValues

This docstring is overridden by the _GetValidBreakageModelValues’s at the end of the file.

SetBreakageModel

Set the value of “Breakage Model”.

GetAssemblyParts

GetAssemblyCustom

Deprecated: Use GetCustomProperties() instead.

GetCustomProperties

GetAbt10MaximumT10Value

Get the value of “Abt10 Maximum T10 Value”.

SetAbt10MaximumT10Value

Set the value of “Abt10 Maximum T10 Value”.

GetAbt10ReferenceMinimumSpecificEnergy

Get the value of “Abt10 Reference Minimum Specific Energy”.

SetAbt10ReferenceMinimumSpecificEnergy

Set the value of “Abt10 Reference Minimum Specific Energy”.

GetAbt10MinimumSpecificEnergy

Deprecated: Use GetAbt10ReferenceMinimumSpecificEnergy() instead.

SetAbt10MinimumSpecificEnergy

Deprecated: Use SetAbt10ReferenceMinimumSpecificEnergy() instead.

GetAbt10ReferenceSize

Get the value of “Abt10 Reference Size”.

SetAbt10ReferenceSize

Set the value of “Abt10 Reference Size”.

GetAbt10SelectFunctionCoefficient

Get the value of “Abt10 Select Function Coefficient”.

SetAbt10SelectFunctionCoefficient

Set the value of “Abt10 Select Function Coefficient”.

GetDistributionModel

Get “Distribution Model” as a string.

SetDistributionModel

Set the value of “Distribution Model”.

GetValidDistributionModelValues

Get a list of all possible values for “Distribution Model”.

GetSurfaceEnergy

Get the value of “Surface Energy”.

SetSurfaceEnergy

Set the value of “Surface Energy”.

GetIncludeRotationalDeformations

Get the value of “Include Rotational Deformations”.

SetIncludeRotationalDeformations

Set the value of “Include Rotational Deformations”.

EnableIncludeRotationalDeformations

Set the value of “Include Rotational Deformations” to True.

DisableIncludeRotationalDeformations

Set the value of “Include Rotational Deformations” to False.

IsIncludeRotationalDeformationsEnabled

Check if the “Include Rotational Deformations” is enabled.

GetMinimumSize

Get the value of “Minimum Size”.

SetMinimumSize

Set the value of “Minimum Size”.

GetMinimumSizeRatio

Get the value of “Minimum Size Ratio”.

SetMinimumSizeRatio

Set the value of “Minimum Size Ratio”.

GetMinimumVolumeFractionForFragmentDisabling

Get the value of “Minimum Volume Fraction For Fragment Disabling”.

SetMinimumVolumeFractionForFragmentDisabling

Set the value of “Minimum Volume Fraction For Fragment Disabling”.

GetTavaresA

Get the value of “Tavares A”.

SetTavaresA

Set the value of “Tavares A”.

GetTavaresB

Get the value of “Tavares B”.

SetTavaresB

Set the value of “Tavares B”.

GetTavaresD0

Get the value of “Tavares D0”.

SetTavaresD0

Set the value of “Tavares D0”.

GetTavaresEInf

Get the value of “Tavares E Inf”.

SetTavaresEInf

Set the value of “Tavares E Inf”.

GetTavaresGamma

Get the value of “Tavares Gamma”.

SetTavaresGamma

Set the value of “Tavares Gamma”.

GetTavaresMinimumEnergy

Get the value of “Tavares Minimum Energy”.

SetTavaresMinimumEnergy

Set the value of “Tavares Minimum Energy”.

GetTavaresPhi

Get the value of “Tavares Phi”.

SetTavaresPhi

Set the value of “Tavares Phi”.

GetTavaresRatioEmax

Get the value of “Tavares Ratio Emax”.

SetTavaresRatioEmax

Set the value of “Tavares Ratio Emax”.

GetRatioEnergyAfterBreakage

Get the value of “Ratio Energy After Breakage”.

SetRatioEnergyAfterBreakage

Set the value of “Ratio Energy After Breakage”.

GetTavaresSigmaSquared

Get the value of “Tavares Sigma Squared”.

SetTavaresSigmaSquared

Set the value of “Tavares Sigma Squared”.

GetT10Formula

Get “T10 Formula” as a string.

SetT10Formula

Set the value of “T10 Formula”.

GetValidT10FormulaValues

Get a list of all possible values for “T10 Formula”.

GetShearStressLimit

Get the value of “Shear Stress Limit”.

SetShearStressLimit

Set the value of “Shear Stress Limit”.

GetTensileStressLimit

Get the value of “Tensile Stress Limit”.

SetTensileStressLimit

Set the value of “Tensile Stress Limit”.

GetEnableBreakage

Get the value of “Enable Breakage”.

SetEnableBreakage

Set the value of “Enable Breakage”.

EnableBreakage

Set the value of “Breakage” to True.

DisableBreakage

Set the value of “Breakage” to False.

IsBreakageEnabled

Check if the “Breakage” is enabled.

GetVonMisesStressLimit

Get the value of “Von Mises Stress Limit”.

SetVonMisesStressLimit

Set the value of “Von Mises Stress Limit”.

GetAllowSelfContacts

Get the value of “Allow Self Contacts”.

SetAllowSelfContacts

Set the value of “Allow Self Contacts”.

GetDeformationModel

Get “Deformation Model” as a string.

SetDeformationModel

Set the value of “Deformation Model”.

GetValidDeformationModelValues

Get a list of all possible values for “Deformation Model”.

GetInternalFriction

Get the value of “Internal Friction”.

SetInternalFriction

Set the value of “Internal Friction”.

GetPlasticLimit

Get the value of “Plastic Limit”.

SetPlasticLimit

Set the value of “Plastic Limit”.

GetFlexible

Get the value of “Flexible”.

SetFlexible

Set the value of “Flexible”.

GetCenterOfMassOffset

Get the value of “Center of Mass Offset”.

SetCenterOfMassOffset

Set the values of “Center of Mass Offset”.

GetChangeMassProperties

Get the value of “Change Mass Properties”.

SetChangeMassProperties

Set the value of “Change Mass Properties”.

GetEnableRotations

Get the value of “Enable Rotations”.

SetEnableRotations

Set the value of “Enable Rotations”.

GetHorizontalAspectRatio

Get the value of “Horizontal Aspect Ratio”.

SetHorizontalAspectRatio

Set the value of “Horizontal Aspect Ratio”.

GetPrincipalMomentOfInertia

Get the value of “Principal Moment of Inertia”.

SetPrincipalMomentOfInertia

Set the values of “Principal Moment of Inertia”.

GetNumberOfCorners

Get the value of “Number of Corners”.

SetNumberOfCorners

Set the value of “Number of Corners”.

GetXDirection

Get the value of “X Direction”.

SetXDirection

Set the values of “X Direction”.

GetYDirection

Get the value of “Y Direction”.

SetYDirection

Set the values of “Y Direction”.

GetZDirection

Get the value of “Z Direction”.

SetZDirection

Set the values of “Z Direction”.

GetRollingResistance

Get the value of “Rolling Resistance”.

SetRollingResistance

Set the value of “Rolling Resistance”.

GetSideAngle

Get the value of “Side Angle”.

SetSideAngle

Set the value of “Side Angle”.

GetSmoothness

Get the value of “Smoothness”.

SetSmoothness

Set the value of “Smoothness”.

GetSuperquadricDegree

Get the value of “Superquadric Degree”.

SetSuperquadricDegree

Set the value of “Superquadric Degree”.

GetThickness

Get the value of “Thickness”.

SetThickness

Set the value of “Thickness”.

GetVerticalAspectRatio

Get the value of “Vertical Aspect Ratio”.

SetVerticalAspectRatio

Set the value of “Vertical Aspect Ratio”.

GetBendingAngleLimit

Get the value of “Bending Angle Limit”.

SetBendingAngleLimit

Set the value of “Bending Angle Limit”.

GetWithFailure

Get the value of “With Failure”.

SetWithFailure

Set the value of “With Failure”.

GetEdgeAngle

Get the value of “Edge Angle”.

SetEdgeAngle

Set the value of “Edge Angle”.

GetElasticRatioBending

Get the value of “Elastic Ratio Bending”.

SetElasticRatioBending

Set the value of “Elastic Ratio Bending”.

GetElasticRatioNormal

Get the value of “Elastic Ratio Normal”.

SetElasticRatioNormal

Set the value of “Elastic Ratio Normal”.

GetElasticRatioTangential

Get the value of “Elastic Ratio Tangential”.

SetElasticRatioTangential

Set the value of “Elastic Ratio Tangential”.

GetElasticRatioTorsion

Get the value of “Elastic Ratio Torsion”.

SetElasticRatioTorsion

Set the value of “Elastic Ratio Torsion”.

GetElasticity

Get “Elasticity” as a string.

SetElasticity

Set the value of “Elasticity”.

GetValidElasticityValues

Get a list of all possible values for “Elasticity”.

GetTargetNumberOfElements

Get the value of “Target Number of Elements”.

SetTargetNumberOfElements

Set the value of “Target Number of Elements”.

GetElementDampingRatio

Get the value of “Element Damping Ratio”.

SetElementDampingRatio

Set the value of “Element Damping Ratio”.

GetFailureRatio

Get the value of “Failure Ratio”.

SetFailureRatio

Set the value of “Failure Ratio”.

GetJointDampingRatio

Get the value of “Joint Damping Ratio”.

SetJointDampingRatio

Set the value of “Joint Damping Ratio”.

GetJointElasticRatio

Get the value of “Joint Elastic Ratio”.

SetJointElasticRatio

Set the value of “Joint Elastic Ratio”.

GetJointThermalRatio

Get the value of “Joint Thermal Ratio”.

SetJointThermalRatio

Set the value of “Joint Thermal Ratio”.

GetPlasticRatio

Get the value of “Plastic Ratio”.

SetPlasticRatio

Set the value of “Plastic Ratio”.

GetPlasticityModel

Get “Plasticity Model” as a string.

SetPlasticityModel

Set the value of “Plasticity Model”.

GetValidPlasticityModelValues

Get a list of all possible values for “Plasticity Model”.

GetRemeshToTarget

Get the value of “Remesh To Target”.

SetRemeshToTarget

Set the value of “Remesh To Target”.

GetSecondBendingAngleLimit

Get the value of “Second Bending Angle Limit”.

SetSecondBendingAngleLimit

Set the value of “Second Bending Angle Limit”.

GetTorsionAngleLimit

Get the value of “Torsion Angle Limit”.

SetTorsionAngleLimit

Set the value of “Torsion Angle Limit”.

GetName

Get the value of “Name”.

SetName

Set the value of “Name”.

GetPorosity

Get the value of “Porosity”.

SetPorosity

Set the value of “Porosity”.

GetRandomAnglesHalfRange

Get the value of “Random Angles Half Range”.

SetRandomAnglesHalfRange

Set the values of “Random Angles Half Range”.

GetShape

Get “Shape” as a string.

SetShape

Set the value of “Shape”.

GetValidShapeValues

Get a list of all possible values for “Shape”.

GetCgmScaleFactor

Get the value of “Cgm Scale Factor”.

SetCgmScaleFactor

Set the value of “Cgm Scale Factor”.

GetSizeType

Get “Size Type” as a string.

SetSizeType

Set the value of “Size Type”.

GetValidSizeTypeValues

Get a list of all possible values for “Size Type”.

GetEnableRandomAngle

Get the value of “Enable Random Angle”.

SetEnableRandomAngle

Set the value of “Enable Random Angle”.

EnableRandomOrientation

Set the value of “Random Orientation” to True.

DisableRandomOrientation

Set the value of “Random Orientation” to False.

IsRandomOrientationEnabled

Check if the “Random Orientation” is enabled.

GetMaterial

Get the “Material”.

SetMaterial

Set the “Material”.

GetAvailableMaterials

Get all available Materials.

GetAnisotropic

Deprecated: Use GetElasticity() instead.

SetAnisotropic

Set the value of “Anisotropic”.

Import detail#

from ansys.rocky.app.ra_particle import RAParticle

Method detail#

classmethod RAParticle.GetWrappedClass()#
classmethod RAParticle.GetClassName() str#
RAParticle.ImportFromSTL(stl_filename: str, as_concave: bool, is_open: bool = False) bool#

Import a custom shape from the given stl filename into this particle.

Parameters:
  • stl_filename – The full path to the STL file.

  • as_concave – True whether the particle should be treated as Concave, or False otherwise

  • is_open – True whether the stl is an open one

Returns:

Possible return values: * True if everything went fine with the import process. * False if the import process failed.

RAParticle.ImportCustomFiber(filename: str) bool#

Import a custom fiber shape from the given filename into this particle.

Parameters:

filename – The full path to the TXT/CSV/Excel file.

Returns:

Whether it was possible to import the particle

RAParticle.GetSizeDistributionList() ansys.rocky.app.ra_size_distribution.RASizeDistributionList#

Get a list of size distribution entries

RAParticle.GetUseMultipleElements() bool#

Whether the particle’s Composition is “Multiple Elements”.

RAParticle.SetUseMultipleElements(value) None#

Set the particle’s Composition to “Multiple Elements” (True) or “Single Elements” (False).

Parameters:

value (bool)

RAParticle.IsConcave()#

Returns True if the particle is a concave custom polyhedron, and False otherwise.

Return type:

bool

RAParticle.GetBreakageModel() str#

This docstring is overridden by the _GetBreakageModel’s at the end of the file.

RAParticle.GetValidBreakageModelValues() list[str]#

This docstring is overridden by the _GetValidBreakageModelValues’s at the end of the file.

RAParticle.SetBreakageModel(value: str) None#

Set the value of “Breakage Model”. If the particle is not flexible, setting the model to any value other than “none” also enables breakage.

Parameters:

value (str) – The value to set. Must be one of [‘none’, ‘ab_t10’, ‘professor_tavares’, ‘instantaneous_custom’, ‘griffith_surface_energy’, ‘shear_stress_criterion’, ‘tensile_stress_criterion’, ‘tensile_or_shear_criterion’, ‘von_mises_stress_criterion’, ‘discrete_custom’].

Raises:

RockyApiError – If value is not a valid “Breakage Model” option.

RAParticle.GetAssemblyParts() ansys.rocky.app.ra_particle_assembly.RAParticleAssemblyPartList#
RAParticle.GetAssemblyCustom() ansys.rocky.app.ra_particle_assembly.RAParticleAssemblyCustom#

Deprecated: Use GetCustomProperties() instead.

RAParticle.GetCustomProperties() ansys.rocky.app.ra_particle_assembly.RAParticleAssemblyCustom#
RAParticle.GetAbt10MaximumT10Value(unit: str | None = None) float#

Get the value of “Abt10 Maximum T10 Value”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “%”.

RAParticle.SetAbt10MaximumT10Value(value: str | float, unit: str | None = None) None#

Set the value of “Abt10 Maximum T10 Value”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “%”.

RAParticle.GetAbt10ReferenceMinimumSpecificEnergy(unit: str | None = None) float#

Get the value of “Abt10 Reference Minimum Specific Energy”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/kg”.

RAParticle.SetAbt10ReferenceMinimumSpecificEnergy(value: str | float, unit: str | None = None) None#

Set the value of “Abt10 Reference Minimum Specific Energy”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/kg”.

RAParticle.GetAbt10MinimumSpecificEnergy(unit: str | None = None) float#

Deprecated: Use GetAbt10ReferenceMinimumSpecificEnergy() instead.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/kg”.

RAParticle.SetAbt10MinimumSpecificEnergy(value: float, unit: str | None = None) None#

Deprecated: Use SetAbt10ReferenceMinimumSpecificEnergy() instead.

Parameters:
  • value – The value to set.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/kg”.

RAParticle.GetAbt10ReferenceSize(unit: str | None = None) float#

Get the value of “Abt10 Reference Size”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “m”.

RAParticle.SetAbt10ReferenceSize(value: str | float, unit: str | None = None) None#

Set the value of “Abt10 Reference Size”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “m”.

RAParticle.GetAbt10SelectFunctionCoefficient(unit: str | None = None) float#

Get the value of “Abt10 Select Function Coefficient”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “kg/J”.

RAParticle.SetAbt10SelectFunctionCoefficient(value: str | float, unit: str | None = None) None#

Set the value of “Abt10 Select Function Coefficient”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “kg/J”.

RAParticle.GetDistributionModel() str#

Get “Distribution Model” as a string.

Returns:

The returned value will be one of [‘gaudin_schumann’, ‘incomplete_beta’, ‘custom’].

RAParticle.SetDistributionModel(value: str) None#

Set the value of “Distribution Model”.

Parameters:

value – The value to set. Must be one of [‘gaudin_schumann’, ‘incomplete_beta’, ‘custom’].

Raises:

RockyApiError – If value is not a valid “Distribution Model” option.

RAParticle.GetValidDistributionModelValues() list[str]#

Get a list of all possible values for “Distribution Model”.

Returns:

The returned list is [‘gaudin_schumann’, ‘incomplete_beta’, ‘custom’].

RAParticle.GetSurfaceEnergy(unit: str | None = None) float#

Get the value of “Surface Energy”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/m2”.

RAParticle.SetSurfaceEnergy(value: str | float, unit: str | None = None) None#

Set the value of “Surface Energy”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/m2”.

RAParticle.GetIncludeRotationalDeformations() bool#

Get the value of “Include Rotational Deformations”.

RAParticle.SetIncludeRotationalDeformations(value: bool) None#

Set the value of “Include Rotational Deformations”.

Parameters:

value – The value to set.

RAParticle.EnableIncludeRotationalDeformations() None#

Set the value of “Include Rotational Deformations” to True.

RAParticle.DisableIncludeRotationalDeformations() None#

Set the value of “Include Rotational Deformations” to False.

RAParticle.IsIncludeRotationalDeformationsEnabled() bool#

Check if the “Include Rotational Deformations” is enabled.

RAParticle.GetMinimumSize(unit: str | None = None) float#

Get the value of “Minimum Size”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “m”.

RAParticle.SetMinimumSize(value: str | float, unit: str | None = None) None#

Set the value of “Minimum Size”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “m”.

RAParticle.GetMinimumSizeRatio() float#

Get the value of “Minimum Size Ratio”.

RAParticle.SetMinimumSizeRatio(value: str | float) None#

Set the value of “Minimum Size Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetMinimumVolumeFractionForFragmentDisabling() float#

Get the value of “Minimum Volume Fraction For Fragment Disabling”.

RAParticle.SetMinimumVolumeFractionForFragmentDisabling(value: str | float) None#

Set the value of “Minimum Volume Fraction For Fragment Disabling”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetTavaresA(unit: str | None = None) float#

Get the value of “Tavares A”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “%”.

RAParticle.SetTavaresA(value: str | float, unit: str | None = None) None#

Set the value of “Tavares A”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “%”.

RAParticle.GetTavaresB(unit: str | None = None) float#

Get the value of “Tavares B”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “-“.

RAParticle.SetTavaresB(value: str | float, unit: str | None = None) None#

Set the value of “Tavares B”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “-“.

RAParticle.GetTavaresD0(unit: str | None = None) float#

Get the value of “Tavares D0”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “m”.

RAParticle.SetTavaresD0(value: str | float, unit: str | None = None) None#

Set the value of “Tavares D0”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “m”.

RAParticle.GetTavaresEInf(unit: str | None = None) float#

Get the value of “Tavares E Inf”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/kg”.

RAParticle.SetTavaresEInf(value: str | float, unit: str | None = None) None#

Set the value of “Tavares E Inf”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/kg”.

RAParticle.GetTavaresGamma(unit: str | None = None) float#

Get the value of “Tavares Gamma”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “-“.

RAParticle.SetTavaresGamma(value: str | float, unit: str | None = None) None#

Set the value of “Tavares Gamma”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “-“.

RAParticle.GetTavaresMinimumEnergy(unit: str | None = None) float#

Get the value of “Tavares Minimum Energy”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/kg”.

RAParticle.SetTavaresMinimumEnergy(value: str | float, unit: str | None = None) None#

Set the value of “Tavares Minimum Energy”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/kg”.

RAParticle.GetTavaresPhi(unit: str | None = None) float#

Get the value of “Tavares Phi”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “-“.

RAParticle.SetTavaresPhi(value: str | float, unit: str | None = None) None#

Set the value of “Tavares Phi”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “-“.

RAParticle.GetTavaresRatioEmax(unit: str | None = None) float#

Get the value of “Tavares Ratio Emax”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “-“.

RAParticle.SetTavaresRatioEmax(value: str | float, unit: str | None = None) None#

Set the value of “Tavares Ratio Emax”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “-“.

RAParticle.GetRatioEnergyAfterBreakage(unit: str | None = None) float#

Get the value of “Ratio Energy After Breakage”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “-“.

RAParticle.SetRatioEnergyAfterBreakage(value: str | float, unit: str | None = None) None#

Set the value of “Ratio Energy After Breakage”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “-“.

RAParticle.GetTavaresSigmaSquared(unit: str | None = None) float#

Get the value of “Tavares Sigma Squared”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “-“.

RAParticle.SetTavaresSigmaSquared(value: str | float, unit: str | None = None) None#

Set the value of “Tavares Sigma Squared”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “-“.

RAParticle.GetT10Formula() str#

Get “T10 Formula” as a string.

Returns:

The returned value will be one of [‘it10E_50b’, ‘it10E_fract’].

RAParticle.SetT10Formula(value: str) None#

Set the value of “T10 Formula”.

Parameters:

value – The value to set. Must be one of [‘it10E_50b’, ‘it10E_fract’].

Raises:

RockyApiError – If value is not a valid “T10 Formula” option.

RAParticle.GetValidT10FormulaValues() list[str]#

Get a list of all possible values for “T10 Formula”.

Returns:

The returned list is [‘it10E_50b’, ‘it10E_fract’].

RAParticle.GetShearStressLimit(unit: str | None = None) float#

Get the value of “Shear Stress Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “N/m2”.

RAParticle.SetShearStressLimit(value: str | float, unit: str | None = None) None#

Set the value of “Shear Stress Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “N/m2”.

RAParticle.GetTensileStressLimit(unit: str | None = None) float#

Get the value of “Tensile Stress Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “N/m2”.

RAParticle.SetTensileStressLimit(value: str | float, unit: str | None = None) None#

Set the value of “Tensile Stress Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “N/m2”.

RAParticle.GetEnableBreakage() bool#

Get the value of “Enable Breakage”.

RAParticle.SetEnableBreakage(value: bool) None#

Set the value of “Enable Breakage”.

Parameters:

value – The value to set.

RAParticle.EnableBreakage() None#

Set the value of “Breakage” to True.

RAParticle.DisableBreakage() None#

Set the value of “Breakage” to False.

RAParticle.IsBreakageEnabled() bool#

Check if the “Breakage” is enabled.

RAParticle.GetVonMisesStressLimit(unit: str | None = None) float#

Get the value of “Von Mises Stress Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “N/m2”.

RAParticle.SetVonMisesStressLimit(value: str | float, unit: str | None = None) None#

Set the value of “Von Mises Stress Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “N/m2”.

RAParticle.GetAllowSelfContacts() bool#

Get the value of “Allow Self Contacts”.

RAParticle.SetAllowSelfContacts(value: bool) None#

Set the value of “Allow Self Contacts”.

Parameters:

value – The value to set.

RAParticle.GetDeformationModel() str#

Get “Deformation Model” as a string.

Returns:

The returned value will be one of [‘none’, ‘elastic’, ‘plastic’].

RAParticle.SetDeformationModel(value: str) None#

Set the value of “Deformation Model”.

Parameters:

value – The value to set. Must be one of [‘none’, ‘elastic’, ‘plastic’].

Raises:

RockyApiError – If value is not a valid “Deformation Model” option.

RAParticle.GetValidDeformationModelValues() list[str]#

Get a list of all possible values for “Deformation Model”.

Returns:

The returned list is [‘none’, ‘elastic’, ‘plastic’].

RAParticle.GetInternalFriction() float#

Get the value of “Internal Friction”.

RAParticle.SetInternalFriction(value: str | float) None#

Set the value of “Internal Friction”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetPlasticLimit(unit: str | None = None) float#

Get the value of “Plastic Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “Pa”.

RAParticle.SetPlasticLimit(value: str | float, unit: str | None = None) None#

Set the value of “Plastic Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “Pa”.

RAParticle.GetFlexible() bool#

Get the value of “Flexible”.

RAParticle.SetFlexible(value: bool) None#

Set the value of “Flexible”.

Parameters:

value – The value to set.

RAParticle.GetCenterOfMassOffset(unit: str | None = None) list[float]#

Get the value of “Center of Mass Offset”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “%”.

RAParticle.SetCenterOfMassOffset(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “Center of Mass Offset”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “%”.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAParticle.GetChangeMassProperties() bool#

Get the value of “Change Mass Properties”.

RAParticle.SetChangeMassProperties(value: bool) None#

Set the value of “Change Mass Properties”.

Parameters:

value – The value to set.

RAParticle.GetEnableRotations() bool#

Get the value of “Enable Rotations”.

RAParticle.SetEnableRotations(value: bool) None#

Set the value of “Enable Rotations”.

Parameters:

value – The value to set.

RAParticle.GetHorizontalAspectRatio() float#

Get the value of “Horizontal Aspect Ratio”.

RAParticle.SetHorizontalAspectRatio(value: str | float) None#

Set the value of “Horizontal Aspect Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetPrincipalMomentOfInertia(unit: str | None = None) list[float]#

Get the value of “Principal Moment of Inertia”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “m5”.

RAParticle.SetPrincipalMomentOfInertia(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “Principal Moment of Inertia”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “m5”.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAParticle.GetNumberOfCorners() int#

Get the value of “Number of Corners”.

RAParticle.SetNumberOfCorners(value: str | int) None#

Set the value of “Number of Corners”.

Parameters:

value – The value to set. This value can be an expression with input variables or int type.

RAParticle.GetXDirection(unit: str | None = None) list[float]#

Get the value of “X Direction”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “-“.

RAParticle.SetXDirection(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “X Direction”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “-“.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAParticle.GetYDirection(unit: str | None = None) list[float]#

Get the value of “Y Direction”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “-“.

RAParticle.SetYDirection(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “Y Direction”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “-“.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAParticle.GetZDirection(unit: str | None = None) list[float]#

Get the value of “Z Direction”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “-“.

RAParticle.SetZDirection(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “Z Direction”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “-“.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAParticle.GetRollingResistance() float#

Get the value of “Rolling Resistance”.

RAParticle.SetRollingResistance(value: str | float) None#

Set the value of “Rolling Resistance”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetSideAngle() float#

Get the value of “Side Angle”.

RAParticle.SetSideAngle(value: str | float) None#

Set the value of “Side Angle”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetSmoothness() float#

Get the value of “Smoothness”.

RAParticle.SetSmoothness(value: str | float) None#

Set the value of “Smoothness”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetSuperquadricDegree() float#

Get the value of “Superquadric Degree”.

RAParticle.SetSuperquadricDegree(value: str | float) None#

Set the value of “Superquadric Degree”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetThickness(unit: str | None = None) float#

Get the value of “Thickness”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “m”.

RAParticle.SetThickness(value: str | float, unit: str | None = None) None#

Set the value of “Thickness”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “m”.

RAParticle.GetVerticalAspectRatio() float#

Get the value of “Vertical Aspect Ratio”.

RAParticle.SetVerticalAspectRatio(value: str | float) None#

Set the value of “Vertical Aspect Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetBendingAngleLimit(unit: str | None = None) float#

Get the value of “Bending Angle Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “dega”.

RAParticle.SetBendingAngleLimit(value: str | float, unit: str | None = None) None#

Set the value of “Bending Angle Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “dega”.

RAParticle.GetWithFailure() bool#

Get the value of “With Failure”.

RAParticle.SetWithFailure(value: bool) None#

Set the value of “With Failure”.

Parameters:

value – The value to set.

RAParticle.GetEdgeAngle(unit: str | None = None) float#

Get the value of “Edge Angle”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “dega”.

RAParticle.SetEdgeAngle(value: str | float, unit: str | None = None) None#

Set the value of “Edge Angle”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “dega”.

RAParticle.GetElasticRatioBending() float#

Get the value of “Elastic Ratio Bending”.

RAParticle.SetElasticRatioBending(value: str | float) None#

Set the value of “Elastic Ratio Bending”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetElasticRatioNormal() float#

Get the value of “Elastic Ratio Normal”.

RAParticle.SetElasticRatioNormal(value: str | float) None#

Set the value of “Elastic Ratio Normal”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetElasticRatioTangential() float#

Get the value of “Elastic Ratio Tangential”.

RAParticle.SetElasticRatioTangential(value: str | float) None#

Set the value of “Elastic Ratio Tangential”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetElasticRatioTorsion() float#

Get the value of “Elastic Ratio Torsion”.

RAParticle.SetElasticRatioTorsion(value: str | float) None#

Set the value of “Elastic Ratio Torsion”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetElasticity() str#

Get “Elasticity” as a string.

Returns:

The returned value will be one of [‘isotropic’, ‘anisotropic’].

RAParticle.SetElasticity(value: str) None#

Set the value of “Elasticity”.

Parameters:

value – The value to set. Must be one of [‘isotropic’, ‘anisotropic’].

Raises:

RockyApiError – If value is not a valid “Elasticity” option.

RAParticle.GetValidElasticityValues() list[str]#

Get a list of all possible values for “Elasticity”.

Returns:

The returned list is [‘isotropic’, ‘anisotropic’].

RAParticle.GetTargetNumberOfElements() int#

Get the value of “Target Number of Elements”.

RAParticle.SetTargetNumberOfElements(value: str | int) None#

Set the value of “Target Number of Elements”.

Parameters:

value – The value to set. This value can be an expression with input variables or int type.

RAParticle.GetElementDampingRatio() float#

Get the value of “Element Damping Ratio”.

RAParticle.SetElementDampingRatio(value: str | float) None#

Set the value of “Element Damping Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetFailureRatio() float#

Get the value of “Failure Ratio”.

RAParticle.SetFailureRatio(value: str | float) None#

Set the value of “Failure Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetJointDampingRatio() float#

Get the value of “Joint Damping Ratio”.

RAParticle.SetJointDampingRatio(value: str | float) None#

Set the value of “Joint Damping Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetJointElasticRatio() float#

Get the value of “Joint Elastic Ratio”.

RAParticle.SetJointElasticRatio(value: str | float) None#

Set the value of “Joint Elastic Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetJointThermalRatio() float#

Get the value of “Joint Thermal Ratio”.

RAParticle.SetJointThermalRatio(value: str | float) None#

Set the value of “Joint Thermal Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetPlasticRatio() float#

Get the value of “Plastic Ratio”.

RAParticle.SetPlasticRatio(value: str | float) None#

Set the value of “Plastic Ratio”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetPlasticityModel() str#

Get “Plasticity Model” as a string.

Returns:

The returned value will be one of [‘LinearElastic’, ‘BilinearElastoplastic’, ‘Custom’].

RAParticle.SetPlasticityModel(value: str) None#

Set the value of “Plasticity Model”.

Parameters:

value – The value to set. Must be one of [‘LinearElastic’, ‘BilinearElastoplastic’, ‘Custom’].

Raises:

RockyApiError – If value is not a valid “Plasticity Model” option.

RAParticle.GetValidPlasticityModelValues() list[str]#

Get a list of all possible values for “Plasticity Model”.

Returns:

The returned list is [‘LinearElastic’, ‘BilinearElastoplastic’, ‘Custom’].

RAParticle.GetRemeshToTarget() bool#

Get the value of “Remesh To Target”.

RAParticle.SetRemeshToTarget(value: bool) None#

Set the value of “Remesh To Target”.

Parameters:

value – The value to set.

RAParticle.GetSecondBendingAngleLimit(unit: str | None = None) float#

Get the value of “Second Bending Angle Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “dega”.

RAParticle.SetSecondBendingAngleLimit(value: str | float, unit: str | None = None) None#

Set the value of “Second Bending Angle Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “dega”.

RAParticle.GetTorsionAngleLimit(unit: str | None = None) float#

Get the value of “Torsion Angle Limit”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “dega”.

RAParticle.SetTorsionAngleLimit(value: str | float, unit: str | None = None) None#

Set the value of “Torsion Angle Limit”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “dega”.

RAParticle.GetName() str#

Get the value of “Name”.

RAParticle.SetName(value: str) None#

Set the value of “Name”.

Parameters:

value – The value to set.

RAParticle.GetPorosity(unit: str | None = None) float#

Get the value of “Porosity”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “”.

RAParticle.SetPorosity(value: str | float, unit: str | None = None) None#

Set the value of “Porosity”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “”.

RAParticle.GetRandomAnglesHalfRange(unit: str | None = None) list[float]#

Get the value of “Random Angles Half Range”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “rad”.

RAParticle.SetRandomAnglesHalfRange(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “Random Angles Half Range”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “rad”.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAParticle.GetShape() str#

Get “Shape” as a string.

Returns:

The returned value will be one of [‘sphere’, ‘polyhedron’, ‘sphero_cylinder’, ‘sphero_polygon’, ‘sphero_polyhedron’, ‘briquete’, ‘faceted_cylinder’, ‘assembly’, ‘straight_fiber’, ‘custom_fiber’, ‘custom_shell’, ‘custom_polyhedron’].

RAParticle.SetShape(value: str) None#

Set the value of “Shape”.

Parameters:

value – The value to set. Must be one of [‘sphere’, ‘polyhedron’, ‘sphero_cylinder’, ‘sphero_polygon’, ‘sphero_polyhedron’, ‘briquete’, ‘faceted_cylinder’, ‘assembly’, ‘straight_fiber’, ‘custom_fiber’, ‘custom_shell’, ‘custom_polyhedron’].

Raises:

RockyApiError – If value is not a valid “Shape” option.

RAParticle.GetValidShapeValues() list[str]#

Get a list of all possible values for “Shape”.

Returns:

The returned list is [‘sphere’, ‘polyhedron’, ‘sphero_cylinder’, ‘sphero_polygon’, ‘sphero_polyhedron’, ‘briquete’, ‘faceted_cylinder’, ‘assembly’, ‘straight_fiber’, ‘custom_fiber’, ‘custom_shell’, ‘custom_polyhedron’].

RAParticle.GetCgmScaleFactor() float#

Get the value of “Cgm Scale Factor”.

RAParticle.SetCgmScaleFactor(value: str | float) None#

Set the value of “Cgm Scale Factor”.

Parameters:

value – The value to set. This value can be an expression with input variables or float type.

RAParticle.GetSizeType() str#

Get “Size Type” as a string.

Returns:

The returned value will be one of [‘sieve’, ‘equivalent_diameter’, ‘original_size_scale’].

RAParticle.SetSizeType(value: str) None#

Set the value of “Size Type”.

Parameters:

value – The value to set. Must be one of [‘sieve’, ‘equivalent_diameter’, ‘original_size_scale’].

Raises:

RockyApiError – If value is not a valid “Size Type” option.

RAParticle.GetValidSizeTypeValues() list[str]#

Get a list of all possible values for “Size Type”.

Returns:

The returned list is [‘sieve’, ‘equivalent_diameter’, ‘original_size_scale’].

RAParticle.GetEnableRandomAngle() bool#

Get the value of “Enable Random Angle”.

RAParticle.SetEnableRandomAngle(value: bool) None#

Set the value of “Enable Random Angle”.

Parameters:

value – The value to set.

RAParticle.EnableRandomOrientation() None#

Set the value of “Random Orientation” to True.

RAParticle.DisableRandomOrientation() None#

Set the value of “Random Orientation” to False.

RAParticle.IsRandomOrientationEnabled() bool#

Check if the “Random Orientation” is enabled.

RAParticle.GetMaterial()#

Get the “Material”.

Return type:

RASolidMaterial

RAParticle.SetMaterial(value) None#

Set the “Material”.

:param unicode, RASolidMaterial value:

Either the API object wrapping the desired entity or its name.

RAParticle.GetAvailableMaterials()#

Get all available Materials.

Return type:

List[RASolidMaterial] A list of RASolidMaterial.

RAParticle.GetAnisotropic() bool#

Deprecated: Use GetElasticity() instead.

Return type:

bool

RAParticle.SetAnisotropic(value: bool) None#

Set the value of “Anisotropic”.

Parameters:

value (bool) – The value to set.