Rotation matrix on the plane
Euler angle
Yaw Pitch Roll is to rotate around XYZ respectively
Notice
Rotation around a fixed coordinate system is right multiplication/vector transformation, and the result of vector and point rotation is right multiplication
Each rotation is based on the left multiplication/coordinate transformation of its own coordinate system, and the coordinates of the vector and point in the previous coordinate system are left multiplication
If you rotate α around the X axis, rotate β around the Y axis, and rotate γ around the Z axis,
then R = Rxα Ryβ Rzγ
If you rotate α around the X axis, rotate β around Y', and rotate γ around Z'',
then R = Rz''γ Ry'β Rxα
The rotation of Euler angles depends on the rotation order of the rotation axis, which is called cis-regularity
Rotation matrix around a fixed axis, where the results shown in the figure are wrong
universal joint
Applications: camera gimbal, missile navigation
Degeneracy of Euler angles (Gimbal deadlock
See the example of observing the sky at the North Pole. To put it simply, it is to rotate 90 degrees according to the second axis in the rule, which will result in the loss of the rotation axis
Some Problems Using Euler Angles to Represent Rotation
1. Universal joint deadlock
2. It is difficult to interpolate (not conducive to animation
3. It is difficult to do superposition of rotation (for example, if there are two rotations R1 and R2, the total rotation cannot be simply expressed by R1+R2
4. Around the fixed The rotation of the axis is difficult to represent
Quaternion
Use high-level paraphrase to express the rotation of three-dimensional space, and use group theory to prove that it only works in three-dimensional space, and it will not work in high-dimensional space
Note that there are still doubts about the multiplication calculation of quaternions. Does the quaternion have three multiplications of product, dot, and cross, or does the quaternion have two multiplications of product/cross and dot?
At present, it seems that the quaternion should have Product/cross, dot two kinds of multiplication
product
The product of the quaternion can be expressed in three forms
- The complex number formula
is actually a simple expansion and multiplication, refer to the complex number multiplier table 2. Matrix formula
From the above quaternion expansion and multiplication, it can be intuitively transitioned to the following expression
3. Vector formula
Quaternion basic operation summary
Quaternion multiplication calculation
Euler angles –> Quaternions
Quaternion expression rotation
The conjugate of the unit quaternion == the inverse of the quaternion
Quaternion –> Rotation Matrix
Common operations on quaternions
1. The inverse of the quaternion
2. The quaternion represents the superposition of rotation
3. The rotation between two unit vectors Quaternion solution