Rotations about the coordinate axes are easy to define and work with. Rotation about the x axis by angle θ is. R x (θ) = 0 cos θ sin θ 0 sin θ cos θ

Similar documents
1 Matrices and matrix algebra

THE COMPOUND ANGLE IDENTITIES

Chapter 2 Homogeneous Transformation Matrix

Motion in Three Dimensions

Engineering Notebook

( ) R kj. = y k y j. y A ( ) z A. y a. z a. Derivatives of the second order electrostatic tensor with respect to the translation of ( ) δ yβ.

MA40S Pre-calculus UNIT C Trigonometric Identities CLASS NOTES Analyze Trigonometric Identities Graphically and Verify them Algebraically

Quantum Physics II (8.05) Fall 2002 Assignment 3

Lecture 37: Principal Axes, Translations, and Eulerian Angles

We could express the left side as a sum of vectors and obtain the Vector Form of a Linear System: a 12 a x n. a m2

Homework 2. Solutions T =

Distance Between Ellipses in 2D

Winter 2017 Ma 1b Analytical Problem Set 2 Solutions

Texture, Microstructure & Anisotropy A.D. (Tony) Rollett

Kinematics of a UR5. Rasmus Skovgaard Andersen Aalborg University

These items need to be included in the notebook. Follow the order listed.

Further Pure Mathematics 1

Kinematics. Basilio Bona. Semester 1, DAUIN Politecnico di Torino. B. Bona (DAUIN) Kinematics Semester 1, / 15

Practice 14. imathesis.com By Carlos Sotuyo

Introduction and Vectors Lecture 1

Chapter 5 Trigonometric Functions of Angles

Kinematics. Basilio Bona. October DAUIN - Politecnico di Torino. Basilio Bona (DAUIN - Politecnico di Torino) Kinematics October / 15

3/31/ Product of Inertia. Sample Problem Sample Problem 10.6 (continue)

Lecture 38: Equations of Rigid-Body Motion

Transformations. Chapter D Transformations Translation

CE 530 Molecular Simulation

Trigonometry - Part 1 (12 pages; 4/9/16) fmng.uk

EJL R Sβ. sum. General objective: Reduce the complexity of the analysis by exploiting symmetry. Garth J. Simpson

Lecture 38: Equations of Rigid-Body Motion

Problem Set 5 Math 213, Fall 2016

Omm Al-Qura University Dr. Abdulsalam Ai LECTURE OUTLINE CHAPTER 3. Vectors in Physics

Systems Analysis and Control

REFRESHER. William Stallings

Matrix Theory and Differential Equations Homework 6 Solutions, 10/5/6

( ) Trigonometric identities and equations, Mixed exercise 10

OLLSCOIL NA heireann MA NUAD THE NATIONAL UNIVERSITY OF IRELAND MAYNOOTH MATHEMATICAL PHYSICS EE112. Engineering Mathematics II

Name (print): Lab (circle): W8 Th8 Th11 Th2 F8. θ (radians) θ (degrees) cos θ sin θ π/ /2 1/2 π/4 45 2/2 2/2 π/3 60 1/2 3/2 π/

Mathematics for Graphics and Vision

13. LECTURE 13. Objectives

The choice of origin, axes, and length is completely arbitrary.

Kinematics. Basilio Bona. Semester 1, DAUIN Politecnico di Torino. B. Bona (DAUIN) Kinematics Semester 1, / 15

Rigid Body Rotation. Speaker: Xiaolei Chen Advisor: Prof. Xiaolin Li. Department of Applied Mathematics and Statistics Stony Brook University (SUNY)

Introduction to Matrix Algebra

Ridig Body Motion Homogeneous Transformations

Christoffel Symbols. 1 In General Topologies. Joshua Albert. September 28, W. First we say W : λ n = x µ (λ) so that the world

Math 3C Lecture 20. John Douglas Moore

The Area of Intersecting Ellipses

CLASS XII CBSE MATHEMATICS INTEGRALS

General CORDIC Description (1A)

Mechanics Physics 151

Chapter 3 Vectors. 3.1 Vector Analysis

4. Two-level systems. 4.1 Generalities

Minimal representations of orientation

MCE/EEC 647/747: Robot Dynamics and Control. Lecture 2: Rigid Motions and Homogeneous Transformations

ENGI 9420 Lecture Notes 2 - Matrix Algebra Page Matrix operations can render the solution of a linear system much more efficient.

Integrals in cylindrical, spherical coordinates (Sect. 15.7)

Section 7.3 Double Angle Identities

Vectors in Physics. Topics to review:

Analytic Trigonometry. Copyright Cengage Learning. All rights reserved.

8 Velocity Kinematics

3 + 4i 2 + 3i. 3 4i Fig 1b

11 a 12 a 13 a 21 a 22 a b 12 b 13 b 21 b 22 b b 11 a 12 + b 12 a 13 + b 13 a 21 + b 21 a 22 + b 22 a 23 + b 23

COMPOSITION OF CONCURRENT FORCES

Matrices and Vectors

Information About Ellipses

Vectors. In kinematics, the simplest concept is position, so let s begin with a position vector shown below:

A-Level Mathematics TRIGONOMETRY. G. David Boswell - R2S Explore 2019

Classical Mechanics. Luis Anchordoqui

Generalization of the Euler Angles

The Bloch Sphere. Ian Glendinning. February 16, QIA Meeting, TechGate 1 Ian Glendinning / February 16, 2005

THE DIFFERENTIAL GEOMETRY OF PARAMETRIC PRIMITIVES

ROBOTICS: ADVANCED CONCEPTS & ANALYSIS

C3 A Booster Course. Workbook. 1. a) Sketch, on the same set of axis the graphs of y = x and y = 2x 3. (3) b) Hence, or otherwise, solve the equation

Demonstration of the Coupled Evolution Rules 163 APPENDIX F: DEMONSTRATION OF THE COUPLED EVOLUTION RULES

Chapter 9: Complex Numbers

FUNDAMENTAL TRIGONOMETRIC INDENTITIES 1 = cos. sec θ 1 = sec. = cosθ. Odd Functions sin( t) = sint. csc( t) = csct tan( t) = tant

CBE 6333, R. Levicky 1. Orthogonal Curvilinear Coordinates

arxiv: v1 [math.ds] 18 Nov 2008

Elementary Matrices. MATH 322, Linear Algebra I. J. Robert Buchanan. Spring Department of Mathematics

Chapter 2 A Mathematical Toolbox

Course Name : Physics I Course # PHY 107

Practice Problems for MTH 112 Exam 2 Prof. Townsend Fall 2013

Complex Numbers. The set of complex numbers can be defined as the set of pairs of real numbers, {(x, y)}, with two operations: (i) addition,

(c) cos Arctan ( 3) ( ) PRECALCULUS ADVANCED REVIEW FOR FINAL FIRST SEMESTER

Calculation in the special cases n = 2 and n = 3:

We will discuss matrix diagonalization algorithms in Numerical Recipes in the context of the eigenvalue problem in quantum mechanics, m A n = λ m

Background ODEs (2A) Young Won Lim 3/7/15

CHAPTER 4 Stress Transformation

A Quantum Mechanical Model for the Vibration and Rotation of Molecules. Rigid Rotor

2.1 Scalars and Vectors

Introduction to Linear Algebra, Second Edition, Serge Lange

Why Transforms? Want to animate objects and camera Translations Rotations Shears And more.. Want to be able to use projection transforms

Fair Divsion in Theory and Practice

Transformation Matrices; Geometric and Otherwise As examples, consider the transformation matrices of the C 3v

Math 132 Exam 3 Fall 2016

Inverse Circular Functions and Trigonometric Equations. Copyright 2017, 2013, 2009 Pearson Education, Inc.

cauchy s integral theorem: examples

The matrix will only be consistent if the last entry of row three is 0, meaning 2b 3 + b 2 b 1 = 0.

:25 1. Rotations. A rotation is in general a transformation of the 3D space with the following properties:

Math Section 4.3 Unit Circle Trigonometry

Transcription:

Euler Angle Formulas David Eberly Magic Software, Inc. http://www.magic-software.com Created: December 1, 1999 1 Introduction Rotations about the coordinate axes are easy to define and work with. Rotation about the x axis by angle θ is 1 0 0 R x (θ) = 0 cos θ sin θ 0 sin θ cos θ where θ > 0 indicates a counterclockwise rotation in the plane x = 0. The observer is assumed to be positioned on the side of the plane with x > 0 and looking at the origin. Rotation about the y axis by angle θ is cos θ 0 sin θ R y (θ) = 0 1 0 sin θ 0 cos θ where θ > 0 indicates a counterclockwise rotation in the plane y = 0. The observer is assumed to be positioned on the side of the plane with y > 0 and looking at the origin. Rotation about the z axis by angle θ is cos θ sin θ 0 R z (θ) = sin θ cos θ 0 0 0 1 where θ > 0 indicates a counterclockwise rotation in the plane z = 0. The observer is assumed to be positioned on the side of the plane with z > 0 and looking at the origin. Rotation by an angle θ about an arbitrary axis containing the origin and having unit length direction U = (U x, U y, U z ) is given by R U (θ) = I + (sin θ)s + (1 cos θ)s 2 where I is the identity matrix, S = 0 U z U y U z 0 U x U y U x 0 1

and θ > 0 indicates a counterclockwise rotation in the plane U (x, y, z) = 0. The observer is assumed to be positioned on the side of the plane to which U points and is looking at the origin. 2 Factoring Rotation Matrices A common problem is to factor a rotation matrix as a product of rotations about the coordinate axes. The form of the factorization depends on the needs of the application and what ordering is specified. For example, one might want to factor a rotation as R = R x (θ x )R y (θ y )R z (θ z ) for some angles θ x, θ y, and θ z. The ordering is xyz. Five other possibilities are xzy, yxz, yzx, zxy, and zyx. One might also envision factorizations such as xyx these are not discussed here. The following discussion uses the notation c a = cos(θ a ) and s a = sin(θ a ) for a = x, y, z. 2.1 Factor as R x R y R z Setting R = [r ij ] for 0 i 2 and 0 j 2, formally multiplying R x (θ x )R y (θ y )R z (θ z ), and equating yields r 00 r 01 r 02 c y c z c y s z s y z s x s y + c x s z c x c z s x s y s z c y s x r 20 r 21 r 22 c x c z s y + s x s z c z s x + c x s y s z c x c y From this we have s y = r 02, so θ y = asin(r 02 ). If θ y ( π/2, π/2), then c y 0 and c y (s x, c x ) = ( r 12, r 22 ) in which case θ x = Tan 1 ( r 12, r 22 ). Similarly, c y (s z, c z ) = ( r 01, r 00 ) in which case θ z = Tan 1 ( r 01, r 00 ). If θ y = π/2, then s y = 1 and c y = 0. In this case r 10 r 11 r 20 r 21 c zs x + c x s z c x c z s x s z c x c z + s x s z c z s x + c x s z sin(θ z + θ x ) cos(θ z + θ x ) cos(θ z + θ x ) sin(θ z + θ x ) Therefore, θ z + θ x = Tan 1 (r 10, r 11 ). There is one degree of freedom, so the factorization is not unique. One choice is θ z = 0 and θ x = Tan 1 (r 10, r 11 ). If θ y = π/2, then s y = 1 and c y = 0. In this case r 10 r 11 r 20 r 21 c zs x + c x s z c x c z + s x s z c x c z + s x s z c z s x c x s z sin(θ z θ x ) cos(θ z θ x ) cos(θ z θ x ) sin(θ z θ x ) Therefore, θ z θ x = Tan 1 2(r 10, r 11 ). There is one degree of freedom, so the factorization is not unique. One choice is θ z = 0 and θ x = Tan 1 2(r 10, r 11 ). Pseudocode for the factorization is thetay = asin(r02); if ( thetay < PI/2 ) if ( thetay > -PI/2 ).. 2

thetax = atan2(-r12,r22); thetaz = atan2(-r01,r00); thetax = -atan2(r10,r11); thetaz = 0; thetax = atan2(r10,r11); thetaz = 0; 2.2 Factor as R x R z R y Setting R = [r ij ] for 0 i 2 and 0 j 2, formally multiplying R x (θ x )R z (θ z )R y (θ y ), and equating yields r 00 r 01 r 02 c y c z s z c z s y s x s y + c x c y s z c x c z c y s x + c x s y s z r 20 r 21 r 22 c x s y + c y s x s z c z s x c x c y + s x s y s z thetaz = asin(-r01); if ( thetaz < PI/2 ) if ( thetaz > -PI/2 ) thetax = atan2(r21,r11); thetay = atan2(r02,r00); thetax = -atan2(-r20,r22); thetay = 0; 3

thetax = atan2(-r20,r22); thetay = 0; 2.3 Factor as R y R x R z Setting R = [r ij ] for 0 i 2 and 0 j 2, formally multiplying R y (θ y )R x (θ x )R z (θ z ), and equating yields r 00 r 01 r 02 c y c z + s x s y s z c z s x s y c y s z c x s y x s z c x c z s x r 20 r 21 r 22 c z s y + c y s x s z c y c z s x + s y s z c x c y thetax = asin(-r12); if ( thetax < PI/2 ) if ( thetax > -PI/2 ) thetay = atan2(r02,r22); thetaz = atan2(r10,r11); thetay = -atan2(-r01,r00); thetaz = 0; thetay = atan2(-r01,r00); thetaz = 0; 2.4 Factor as R y R z R x Setting R = [r ij ] for 0 i 2 and 0 j 2, formally multiplying R y (θ y )R z (θ z )R x (θ x ), and equating yields r 00 r 01 r 02 c y c z s x s y c x c y s z c x s y + c y s x s z s z c x c z c z s x r 20 r 21 r 22 c z s y c y s x + c x s y s z c x c y s x s y s z 4

thetaz = asin(r10); if ( thetaz < PI/2 ) if ( thetaz > -PI/2 ) thetay = atan2(-r20,r00); thetax = atan2(-r12,r11); thetay = -atan2(r21,r22); thetax = 0; thetay = atan2(r21,r22); thetax = 0; 2.5 Factor as R z R x R y Setting R = [r ij ] for 0 i 2 and 0 j 2, formally multiplying R z (θ z )R x (θ x )R y (θ y ), and equating yields r 00 r 01 r 02 c y c z s x s y s z c x s z c z s y + c y s x s z z s x s y + c y s z c x c z c y c z s x + s y s z r 20 r 21 r 22 c x s y s x c x c y thetax = asin(r21); if ( thetax < PI/2 ) if ( thetax > -PI/2 ) thetaz = atan2(-r01,r11); thetay = atan2(-r20,r22); thetaz = -atan2(r02,r00); thetay = 0; 5

thetaz = atan2(r02,r00); thetay = 0; 2.6 Factor as R z R y R x Setting R = [r ij ] for 0 i 2 and 0 j 2, formally multiplying R z (θ z )R y (θ y )R x (θ x ), and equating yields r 00 r 01 r 02 c y c z c z s x s y c x s z c x c z s y + s x s z y s z c x c z + s x s y s z c z s x + c x s y s z r 20 r 21 r 22 s y c y s x c x c y thetay = asin(-r20); if ( thetay < PI/2 ) if ( thetay > -PI/2 ) thetaz = atan2(r10,r00); thetax = atan2(r21,r22); thetaz = -atan2(-r01,r02); thetax = 0; thetaz = atan2(-r01,r02); thetax = 0; 3 Factor Product of Two Given a rotation R that is a product of two coordinate axis rotations, the problem is to factor it into three coordinate axis rotations using the ordering xyz. Derivations for the other orderings are similar. In 6

the subsections the matrices are P x = R x (φ x ), P y = R y (φ y ), and P z = R z (φ z ). Define s a = sin(φ x ), s b = sin(φ y ), s c = sin(φ z ), c a = cos(φ x ), c b = cos(φ y ), and c c = cos(φ z ). 3.1 Factor P x P y This is a trivial case. The factorization is R = R x (φ x )R y (φ y ) = R x (θ x )R y (θ y )R z (θ z ). Therefore, θ x = φ x, θ y = φ y, and θ z = 0. 3.2 Factor P y P x The factorization is R = R y (φ y )R x (φ x ) = R x (θ x )R y (θ y )R z (θ z ). Formal multiplication of the various terms leads to the equation c b s a s b c a s b c y c z c y s z s y 0 c a s a z s x s y + c x s z c x c z s x s y s z c y s x. s b c b s a c a c b c x c z s y + s x s z c z s x + c x s y s z c x c y It is easy to see that s y = c a s b in which case θ y = asin(cos θ y sin θ x ). Adding the 10 and 21 terms yields 0 + c b s a = (c z s x s y + c x s z ) + (c z s x + c x s y s z ) = (1 + s y )(c z s x + c x s z ) which leads to sin(θ x + θ z ) = c b s a /(1 + c a s b ). In the even that c a s b = 1, this leads to a special case in the coding that is easy to solve. Subtracting the 10 term from the 21 term yields c b s a 0 = (c z s x s y + c x s z ) (c z s x + c x s y s z ) = (1 s y )(c z s x c x s z ) which leads to sin(θ x θ z ) = c b s a /(1 c a s b ). In the event that c a s b = 1, this also leads to a special case in the coding that is easy to solve. The sine functions can be inverted and the two resulting equations for θ x and θ z can be solved. For the case c a s b < 1, θ x = 1 2 asin cb s a 1+c b s a + asin cb s a 1 c b s a θ y = asin(c a s b ) θ z = 1 2 asin cb s a 1+c b s a asin cb s a 1 c b s a 3.3 Factor P x P z This is a trivial case. The factorization is R = R x (φ x )R z (φ z ) = R x (θ x )R y (θ y )R z (θ z ). Therefore, θ x = φ x, θ y = 0, and θ z = φ z. 7

3.4 Factor P z P x A construction similar to the case P y P x leads to θ x = 1 c 2 asin a c c c 1+s a s c + asin a c c 1 s a s c θ y = asin(s a s c ) [ ( ) ( θ z = 1 c 2 asin ac c 1+s as c asin )] c ac c 1 s as c 3.5 Factor P y P z This is a trivial case. The factorization is R = R y (φ y )R z (φ z ) = R x (θ x )R y (θ y )R z (θ z ). Therefore, θ x = 0, θ y = φ y, and θ z = φ z. 3.6 Factor P z P y A construction similar to the case P y P x leads to θ x = 1 2 asin cb s c 1+s b c c asin cb s c 1 s b c c θ y = asin(s b c c ) θ z = 1 2 asin cb s c 1+s b c c + asin cb s c 1 s b c c 4 Product of Coordinate Rotation with zyx Factorization Given R = R z (θ z )R y (θ y )R x (θ x ) and coordinate axis rotation P, factor P R = R z (ψ z )R y (ψ y )R x (ψ x ). 4.1 P = P z Trivial case. P = R z (φ z ) and P R = R z (θ z + φ z )R y (θ y )R x (θ x ). Thus, ψ z = θ z + φ z, ψ y = θ y, and ψ x = θ x. 8

4.2 P = P y Set P = R y (φ y ) = P y. Then P R = P y R z R y R x = (P y R z )R y R x = (A z A x A y )R y R x = A z (A x B y )R x = A z (C z C y C x )R x = D z C y D x This requires factorization P y R z = A z A x A y, B y = A y R y, factorization A x B y = C z C y C x, D z = A z C z, and D x = C x R x. 4.3 P = P x Set P = R x (φ y ) = P x. Then P R = P x R z R y R x = (P x R z )R y R x = (A z A x A y )R y R x = A z (A x B y )R x = A z (C z C y C x )R x = D z C y D x This requires factorization P x R z = A z A x A y, B y = A y R y, factorization A x B y = C z C y C x, D z = A z C z, and D x = C x R x. 9