visual3d:documentation:pipeline:expressions:array_and_matrix_functions
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
visual3d:documentation:pipeline:expressions:array_and_matrix_functions [2024/06/19 13:59] – created sgranger | visual3d:documentation:pipeline:expressions:array_and_matrix_functions [2025/06/20 13:38] (current) – [Pose_4x4] wikisysop | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Array and Matrix Functions ====== | ||
+ | |||
+ | These array and matrix functions can be used anywhere Visual3D allows [[visual3d: | ||
+ | |||
===== Arrays ===== | ===== Arrays ===== | ||
- | ==== Vector ==== | + | Arrays can be thought of as a 1-dimensional ordered list of numerical values. |
- | **Vector**(a,b, etc) | + | ==== Vector |
- | creates a vector of the number of components specified | + | **Vector**(a, |
+ | < | ||
! Create a metric signal with 2 components and one frame | ! Create a metric signal with 2 components and one frame | ||
- | [Metric_Explicit] | + | Metric_Explicit |
! / | ! / | ||
/ | / | ||
/ | / | ||
- | **;** | + | ; |
! Create a vector containing a constant, a two dimensional metric and a 3 dimensional model based signal. | ! Create a vector containing a constant, a two dimensional metric and a 3 dimensional model based signal. | ||
- | **Evaluate_Expression** | + | Evaluate_Expression |
/ | / | ||
! / | ! / | ||
Line 23: | Line 29: | ||
/ | / | ||
! / | ! / | ||
- | **;** | + | ; |
+ | </ | ||
The resulting signal will have the first three columns (one for the constant, one for the vector of 2 components) buffered to the number of frames of RKNEE_ANGLE by replicating the first frame. | The resulting signal will have the first three columns (one for the constant, one for the vector of 2 components) buffered to the number of frames of RKNEE_ANGLE by replicating the first frame. | ||
+ | |||
==== List ==== | ==== List ==== | ||
- | **list(a, | + | **list(a, |
==== Unit_Vector ==== | ==== Unit_Vector ==== | ||
- | **unit_vector (a, b, etc)** | + | **unit_vector (a, b, etc)** - creates a unit vector of the number of components specified. |
===== Rotation Matrices ===== | ===== Rotation Matrices ===== | ||
+ | |||
+ | Rotation matrices are used throughout Visual3D because they can entirely contain the information regarding a segment' | ||
==== Rotation Multiply ==== | ==== Rotation Multiply ==== | ||
- | **Rotation_Multiply**(a, | + | **Rotation_Multiply**(a, |
Example: Multiply two ROTATION signals | Example: Multiply two ROTATION signals | ||
- | **Evaluate_Expression** | + | < |
+ | Evaluate_Expression | ||
/ | / | ||
/ | / | ||
Line 45: | Line 59: | ||
/ | / | ||
! / | ! / | ||
- | / | + | / |
/ | / | ||
- | **;** | + | ; |
+ | </ | ||
==== Rotation Inverse ==== | ==== Rotation Inverse ==== | ||
- | **Rotation_Inverse**(a) | + | **Rotation_Inverse**(a) |
Example: Inverse of a 4x4 ROTATION signal or a 3x3 LINK_MODEL_BASED ROTATION | Example: Inverse of a 4x4 ROTATION signal or a 3x3 LINK_MODEL_BASED ROTATION | ||
- | A good description of the inverse of a ROTATION signals can be found [[[http:// | + | |
- | **Evaluate_Expression** | + | < |
+ | Evaluate_Expression | ||
/ | / | ||
/ | / | ||
Line 61: | Line 78: | ||
/ | / | ||
! / | ! / | ||
- | / | + | / |
/ | / | ||
- | **;** | + | ; |
- | \\ | + | </ |
+ | **Note**: A good description of the inverse of a ROTATION signals can be found [[http:// | ||
==== Rotation Transpose ==== | ==== Rotation Transpose ==== | ||
- | **Rotation_Transpose**(a) | + | **Rotation_Transpose**(a) |
Example: Transpose of a 3x3 LINK_MODEL_BASED ROTATION signal | Example: Transpose of a 3x3 LINK_MODEL_BASED ROTATION signal | ||
- | **Evaluate_Expression** | + | < |
+ | Evaluate_Expression | ||
/ | / | ||
/ | / | ||
Line 79: | Line 98: | ||
/ | / | ||
! / | ! / | ||
- | / | + | / |
/ | / | ||
- | **;** | + | ; |
- | ==== Pose_Euler2Rotation4x4 | + | </ |
+ | |||
+ | ==== Pose_4x4 | ||
+ | |||
+ | **Pose_4x4(a, | ||
+ | |||
+ | This function was created in support of the [[visual3d: | ||
- | This was created for the Shadow segments introduced in 2024. | + | Example: |
- | Create a 4x4 Rotation from the Visual3D pose of a segment, with the translation | + | < |
- | POSE_EULER2ROTATION4X4(R_HEEL, | + | POSE_4X4(R_HEEL, |
+ | </ | ||
+ | ===== See Also ===== | ||
+ | Go back to see other [[visual3d: |
visual3d/documentation/pipeline/expressions/array_and_matrix_functions.1718805559.txt.gz · Last modified: 2024/06/19 13:59 by sgranger