Frame
#
- class ansys.geometry.core.math.frame.Frame(origin: numpy.ndarray | ansys.geometry.core.typing.RealSequence | ansys.geometry.core.math.point.Point3D = ZERO_POINT3D, direction_x: numpy.ndarray | ansys.geometry.core.typing.RealSequence | ansys.geometry.core.math.vector.UnitVector3D | ansys.geometry.core.math.vector.Vector3D = UNITVECTOR3D_X, direction_y: numpy.ndarray | ansys.geometry.core.typing.RealSequence | ansys.geometry.core.math.vector.UnitVector3D | ansys.geometry.core.math.vector.Vector3D = UNITVECTOR3D_Y)#
Representation of a frame.
- Parameters:
- origin
ndarray
|RealSequence
|Point3D
, default:ZERO_POINT3D
Centered origin of the`frame. The default is
ZERO_POINT3D
, which is the Cartesian origin.- direction_x
ndarray
|RealSequence
|UnitVector3D
|Vector3D
, default:UNITVECTOR3D_X
X-axis direction.
- direction_y
ndarray
|RealSequence
|UnitVector3D
|Vector3D
, default:UNITVECTOR3D_Y
Y-axis direction.
- origin
Overview#
Transform a 2D point to a global 3D point. |
Origin of the frame. |
|
X-axis direction of the frame. |
|
Y-axis direction of the frame. |
|
Z-axis direction of the frame. |
|
Global to local space transformation matrix. |
|
Local to global space transformation matrix. |
|
Full 4x4 transformation matrix. |
Import detail#
from ansys.geometry.core.math.frame import Frame
Property detail#
- property Frame.origin: ansys.geometry.core.math.point.Point3D#
Origin of the frame.
- property Frame.direction_x: ansys.geometry.core.math.vector.UnitVector3D#
X-axis direction of the frame.
- property Frame.direction_y: ansys.geometry.core.math.vector.UnitVector3D#
Y-axis direction of the frame.
- property Frame.direction_z: ansys.geometry.core.math.vector.UnitVector3D#
Z-axis direction of the frame.
- property Frame.global_to_local_rotation: ansys.geometry.core.math.matrix.Matrix33#
Global to local space transformation matrix.
- Returns:
Matrix33
3x3 matrix representing the transformation from global to local coordinate space, excluding origin translation.
- property Frame.local_to_global_rotation: ansys.geometry.core.math.matrix.Matrix33#
Local to global space transformation matrix.
- Returns:
Matrix33
3x3 matrix representing the transformation from local to global coordinate space.
- property Frame.transformation_matrix: ansys.geometry.core.math.matrix.Matrix44#
Full 4x4 transformation matrix.
- Returns:
Matrix44
4x4 matrix representing the transformation from global to local coordinate space.
Method detail#
- Frame.transform_point2d_local_to_global(point: ansys.geometry.core.math.point.Point2D) ansys.geometry.core.math.point.Point3D #
Transform a 2D point to a global 3D point.
This method transforms a local, plane-contained
Point2D
object in the global coordinate system, thus representing it as aPoint3D
object.- Parameters:
- point
Point2D
Point2D
local object to express in global coordinates.
- point
- Returns:
Point3D
Global coordinates for the 3D point.