RASurface#

class ansys.rocky.app.ra_surface.RASurface#

Bases: ansys.rocky.app.ra_base_geometry.RABaseGeometry, ansys.rocky.app._ra_orientation_mixin._RAOrientationMixin, ansys.rocky.app.motion._with_movement_mixin._WithMovementMixin

Rocky API “Surface” model.

Overview#

HasMotionFrame

Whether the geometry is linked to a motion frame.

GetOriginalCenterCoordinates

Get the coordinates of the center of the original surface area, as it was imported, without motion or any property based transformations.

GetOriginalNormal

Get the normal vector of the original surface, as it was imported, without any motion or property based transformations.

GetPlanarDimensions

Get the width and height of the surface area.

GetTranslation

Get the value of “Translation”.

SetTranslation

Set the values of “Translation”.

GetInvertNormal

Get the value of “Invert Normal”.

SetInvertNormal

Set the value of “Invert Normal”.

GetName

Get the value of “Name”.

SetName

Set the value of “Name”.

GetPivotPoint

Get the value of “Pivot Point”.

SetPivotPoint

Set the values of “Pivot Point”.

Import detail#

from ansys.rocky.app.ra_surface import RASurface

Method detail#

classmethod RASurface.GetWrappedClass() → type[object]#
classmethod RASurface.GetClassName() → str#
RASurface.HasMotionFrame() → bool#

Whether the geometry is linked to a motion frame.

Returns:

True if geometry is linked to a motion frame False otherwise

RASurface.GetOriginalCenterCoordinates(unit: str | None = None) → tuple[float, float, float]#

Get the coordinates of the center of the original surface area, as it was imported, without motion or any property based transformations.

Parameters:

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

RASurface.GetOriginalNormal() → tuple[float, float, float]#

Get the normal vector of the original surface, as it was imported, without any motion or property based transformations.

RASurface.GetPlanarDimensions(unit: str | None = None) → tuple[float, float]#

Get the width and height of the surface area.

Parameters:

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

RASurface.GetTranslation(unit: str | None = None) → list[float]#

Get the value of “Translation”.

Parameters:

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

RASurface.SetTranslation(values: collections.abc.Sequence[str | float], unit: str | None = None) → None#

Set the values of “Translation”.

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 “m”.

Raises:

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

RASurface.GetInvertNormal() → bool#

Get the value of “Invert Normal”.

RASurface.SetInvertNormal(value: bool) → None#

Set the value of “Invert Normal”.

Parameters:

value – The value to set.

RASurface.GetName() → str#

Get the value of “Name”.

RASurface.SetName(value: str) → None#

Set the value of “Name”.

Parameters:

value – The value to set.

RASurface.GetPivotPoint(unit: str | None = None) → list[float]#

Get the value of “Pivot Point”.

Parameters:

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

RASurface.SetPivotPoint(values: collections.abc.Sequence[str | float], unit: str | None = None) → None#

Set the values of “Pivot Point”.

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 “m”.

Raises:

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