Download presentation
Presentation is loading. Please wait.
1
Rotation Matrices and Quaternion
Siamak Faal 1/2 04/20/2016
2
Orientation and Rotation
Move and Rotate The object is now at a new position and orientation.
3
Orientation and Rotation
Rotation Matrices Quaternion
4
Preliminaries and notations
Unit vectors: π = π ; π = π ; π = π Transpose: π΄ π ππ = π΄ ππ Inner product: π₯,π¦ =π₯β
π¦= π₯ π π¦ Notation simplifications: π π = sin π π π = cos π π 12 = sin π 1 + π 2 π 12 = cos π 1 + π 2
5
Reference Frames z y z x x y p y y {2} y {1} x x {0} x
A point p can have different coordinates in different reference frames. Frames can be fixed in space or attached to moving objects (inertial or non-inertial frames) x y z p x y {2} x y {1} x y {0}
6
Rotation Matrix A 2D example 2 π = 2 π₯ π β 2 π + 2 π¦ π β 2 π
2 π = 2 π₯ π β 2 π π¦ π β 2 π 1 π₯ π = 2 π₯ π π , 1 π π¦ π π , 1 π 1 π¦ π = 2 π₯ π π , 1 π π¦ π π , 1 π π,π = π π cos π π = π =1 1 π₯ π π¦ π = cos π cos π 2 +π cos π 2 βπ cos π π₯ π π¦ π 1 π₯ π π¦ π = cos π β sin π sin π cos π π₯ π π¦ π A 2D example y y x p ΞΈ {2} x {1}
7
Rotation Matrix A 2D example
1 π₯ π π¦ π = cos π β sin π sin π cos π π₯ π π¦ π 1 π = cos π β sin π sin π cos π π 1 π = 2 1 π
2 π y y x p The π
matrix is both and operator and a description! ΞΈ {2} x {1}
8
Rotation Matrix (Direction Cosines)
π΅ π΄ π
= π΄ π π΅ π΄ π π΅ π΄ π π΅ π΅ π΄ π
= π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π
9
Standard Axis Rotations
π
π₯ π = cos π β sin π 0 sin π cos π π
π¦ π = cos π 0 sin π β sin π 0 cos π π
π§ π = cos π β sin π 0 sin π cos π
10
Rotation Matrix Identities
Claim: Rotation matrix from A to B is equal to the transpose of a rotation matrix from B to A π΅ π΄ π
= π΄ π΅ π
π Proof: π΄ π΅ π
= π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π π΄ π β π΅ π β π΄ π΅ π
π = π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π π΅ π β π΄ π = π΅ π΄ π
11
Rotation Matrix Identities
Claim: The transpose of a rotation matrix is equal to its inverse π΅ π΄ π
= π΄ π΅ π
β1 = π΄ π΅ π
π Proof: π΅ π΄ π
π π΅ π΄ π
= π΄ π π΅ π π΄ π π΅ π π΄ π π΅ π π΄ π π΅ π΄ π π΅ π΄ π π΅ = πΌ 3 where πΌ 3 is the 3Γ3 identity matrix. Hence, π΄ π΅ π
β1 = π΄ π΅ π
π
12
Rotation Matrix Identities
Claim: The determinant of a rotation matrix is 1 det π
=1 Proof: π
π π
=πΌ det π΄ = det π΄ π det π
2 = det πΌ =Β±1 Rotation matrix preserves dimensions, hence: π
π£ = π£ π
π£ β€ π πππ₯ π
π£ β π πππ₯ π
= +1 π πππ π
π£ 2 2 β€ π
π£,π£ β π πππ π
π£ π π£β€ π£ π π
π π£ Using length perversity of π
implies: π£ π π£= π
π£,π£ ; thus: π πππ π
=1 Implies that all the eigenvalues of π
are 1, consequently: det π
= π 1 π 2 π 3 =+1
13
Rotation Matrix Identities
Claim: Multiplication of two rotation matrices is another rotation matrix π
= π
1 π
2 Proof: Using π
π = π
β1 and consequently π
π π
=πΌ: π
1 π
2 π π
1 π
2 = π
2 π π
1 π π
1 π
2 =πΌ Also: det π
1 π
2 = det π
1 det π
2 =+1
14
Rotation Matrix Identities
det π
=1 π΅ π΄ π
= π΄ π΅ π
π π
π = π
β1 π
3 = π
1 π
2 π
1 π
2 β π
2 π
1 βπ>2 n is space dimension
15
Intrinsic vs. Extrinsic Rotations
Intrinsic rotations Extrinsic rotations
16
Euler Angles Leonhard Euler April 15, 1707, Basel, Switzerland
September 18, 1783, Saint Petersburg, Russia
17
Intrinsic rotations (Euler)
Rotations about βnewβ axes z z' z' z'' π z'' π zf yf y'' y' y' y'' y x' x' x π xf x'' x'' For intrinsic rotations, rotation matrices are post-multiplied: π
= π
π§ π π
π¦ π π
π₯ π
18
Extrinsic rotations Rotations about βfixedβ axes z z z yf π zf y y xf
π π For extrinsic rotations, rotation matrices are pre-multiplied: π
= π
π₯ π π
π¦ π π
π§ π
19
More on Rotation Matrix
π
β1 = π
π βπ
is an orthogonal matrix, thus for: π
= π₯ π¦ π§ The following statements hold: π₯ β
π¦ = π₯ β
π§ = π¦ β
π§ =0 π₯ β
π₯ = π¦ β
π¦ = π§ β
π§ =1 This implies only 3 of the 9 components of π
are independent! Consequently, any orientation is achievable through 3 successive rotations about linearly independent axes.
20
Euler Angles Proper Euler angles:
z-x-z, x-y-x, y-z-y, z-y-z, x-z-x, y-x-y Tait-Bryan angles: x-y-z, y-z-x, z-x-y, x-z-y, z-y-x, y-x-z
21
z-y-x Euler Angles π΅ π΄ π
π§π¦π₯ = π
π§ π π
π¦ π π
π₯ π π΅ π΄ π
π§π¦π₯ = π π β π π 0 π π π π π π 0 π π β π π 0 π π π π β π π 0 π π π π π΅ π΄ π
π§π¦π₯ = π π π π π π π π π π β π π π π π π π π π π + π π π π π π π π π π π π π π + π π π π π π π π π π β π π π π β π π π π π π π π π π
22
z-y-x Euler Angles π΅ π΄ π
π§π¦π₯ = π π π π π π π π π π β π π π π π π π π π π + π π π π π π π π π π π π π π + π π π π π π π π π π β π π π π β π π π π π π π π π π π΅ π΄ π
= π ππ if π π β 0 π=atan2 β π 31 , π π 21 2 π=atan2 π 21 π π , π 11 π π π=atan2 π 32 π π , π 33 π π if π=90Β° π=0 π=atan2 π 12 , π 22 if π=β90Β° π=0 π=βatan2 π 12 , π 22
23
Rotations in Constrained Objects
Exercise: find 2 0 π
1 0 π
= π π 1 β π π π π 1 π π 2 1 π
= π π 2 β π π π π 2 π π 2 0 π
= 1 0 π
2 1 π
2 0 π
= π 12 β π π 12 π y x π 2 y {2} y x π 1 {1} x {0}
24
Rotations in Constrained Objects
Example: 1 0 π
= π
π§ π 1 45Β° 2 1 π
= π
π₯ π 2 {2} x y z y z {3} x y {4} x z π 3 3 2 π
= π
π§ 45Β° π 2 4 3 π
= π
π₯ π 3 {1} x y z 4 2 π
= 3 2 π
4 3 π
4 1 π
= 2 1 π
4 2 π
= 2 1 π
3 2 π
4 3 π
x y z {0} π 1 4 0 π
= 1 0 π
4 1 π
= 1 0 π
2 1 π
3 2 π
4 3 π
25
Roll-Picth-Yaw x-y-z or z-y-x Euler Angles π
1 = π
π₯ π π
π¦ π π
π§ π π
2 = π
π₯ π π
π¦ π π
π§ π x y z π π π
26
Rotations in free bodies
Question: If we assume any type of Euler angles, how can we guarantee that rotations are preserved? z π= π π₯ π + π π¦ π + π π π π π§ y π π¦ π π₯ Answer: We can not! x
27
Rotations in free bodies
π x y z x' y' z' z'' y'' x'' xf yf zf π π π π π π π= π π + π
π₯ π π π π + π
π¦ π π
π₯ π π π π
28
Singularity! Singularities at:
π= π π + π
π₯ π π π π + π
π¦ π π
π₯ π π π π π π₯ = π β π sin π π π¦ = π cos π sin π + π cos π π π§ = π cos π cos π β π sin π π = π π₯ + π π¦ sin π tan π + π π§ cos π tan π π = π π¦ cos π β π π§ sin π π = π π¦ sin π + π π§ cos π / cos π π= (2πβ1)π 2 Singularities at:
29
Time derivative of a Rotation Matrix
y z π π₯ π π¦ π π§ For angular velocity vector π defined in body frame: π= π π₯ π + π π¦ π + π π π And a rotation matrix 1 0 π
that maps {1} into {0}. The time derivative of the rotation matrix is defined as: π ππ‘ π
π‘ =π π π
where: π π = 0 β π π§ π π¦ π π§ 0 β π π₯ β π π¦ π π₯ 0 {1} {0} x y z
30
Quaternion Sir William Rowan Hamilton
August 4, 1805, Dublin, Republic of Ireland September 2, 1865, Dublin, Republic of Ireland
31
Quaternion Broom Bridge Dublin, Irland π 2 + π 2 + π 2 =πππ=β1
32
End of Session 1 of 2 To be continuedβ¦
33
References: A good reference on Rotation matrices and some of the underlying theories is presented in chapter 2 of: Craig, John J. βIntroduction to robotics: mechanics and control.β Vol. 3. Upper Saddle River: Pearson Prentice Hall, 2005. Proof of the time derivative of a rotation matrix: Hamano, Fumio. βDerivative of Rotation Matrix Direct Matrix Derivation of Well Known Formula.β arXiv preprint arXiv: (2013).
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.