Rotation Angles to Quaternions
Calculate quaternion from rotation angles
- Library:
Aerospace Blockset / Utilities / Axes Transformations
Description
The Rotation Angles to Quaternions block converts the rotation described by the three rotation angles (R1, R2, R3) into the four-element quaternion vector (q0, q1, q2, q3), where quaternion is defined using the scalar-first convention. Aerospace Blockset™ uses quaternions that are defined using the scalar-first convention. The rotation used in this block is a passive transformation between two coordinate systems. For more information on quaternions, see Algorithms.
Limitations
The limitations for the
ZYX
,ZXY
,YXZ
,YZX
,XYZ
, andXZY
implementations generate an R2 angle that is between ±90 degrees, and R1 and R3 angles that are between ±180 degrees.The limitations for the
ZYZ
,ZXZ
,YXY
,YZY
,XYX
, andXZX
implementations generate an R2 angle that is between 0 and 180 degrees, and R1 and R3 angles that are between ±180 degrees.
Ports
Input
Output
Parameters
Algorithms
A quaternion vector represents a rotation about a unit vector through the angle θ. A unit quaternion itself has unit magnitude, and can be written in the following vector format:
An alternative representation of a quaternion is as a complex number,
where, for the purposes of multiplication:
The benefit of representing the quaternion in this way is the ease with which the quaternion product can represent the resulting transformation after two or more rotations.