Spacecraft Math. Stephen Leake

Size: px
Start display at page:

Download "Spacecraft Math. Stephen Leake"

Transcription

1 Spacecraft Math Stephen Leake 27 Septemer 2008

2 2

3 Chapter 1 Introduction This document presents a thorough summary of vector, quaternion, and matrix math used in spacecraft applications, in oth flight and simulation. It presents a standard notation, shows recommended usage, and provides references to other treatments of these topics as appropriate. We start with a discussion of asic concepts; rotations, translations, poses, rates, wrenches, mass and inertia. Then we discuss various algorithms used in spacecraft software. Each section is composed of four susections; Reference, Coding, Examples, and Derivations. Reference gives the definitions and equations for the section. Coding points to the software source code implementing the section, and discusses any software design issues, in particular variale naming conventions. We present two naming conventions; the SAL naming convention, and the GN&C naming convention adopted y the Goddard Guidance, Navigation and Control ranch. Examples gives numerical examples to illustrate the equations; accompanying Ada code implements the examples. Derivations motivates the definitions in the Reference susection, discusses how they relate to similar equations in other works, and derives the equations from first principles. In many cases, Derivation refers to Macsyma code that provides the detailed algeraic manipulations. The SAL software lirary does not assume the SAL naming convention. This is ecause the lirary supports left and right multiply rotations, and active and passive rotations. It also allows using the lirary with other naming conventions (such as GN&C). The Coding sections of this document define the SAL naming convention for each choice of left/right, active/passive, and show how it relates to the SAL software lirary. All equations are presented in vector notation, with the coordinate frames 3

4 4 CHAPTER 1. INTRODUCTION clearly indicated.

5 Chapter 2 3 Degrees of Freedom The main math of interest in 3 degrees of freedom is rotating vectors. There are many representations of rotations. The two most important for computation are unit quaternions and orthonormal 3-y-3 matrices; these can e multiplied to comine rotations, and used to rotate vectors. On the other hand, the most intuitive representation is angle axis; it is usually easy for people to visualize a rotation as an angle aout an axis. In many situations, the actual representation of a rotation is not important; we can think of an astract rotation R. So we first present notation for astract rotations, then discuss angle axis, quaternions, rotation matrices, and other representations that have special purposes. In general, a position vector represents a displacement from a ase position (usually the origin of a frame) to an oject position, expressed in a coordinate frame. We use the notation ref ase r oj, where ref is the frame the vector is expressed in, ase is the origin of the vector, and oj is the position. Note that negating a vector reverses the direction: ref oj r ase = ref ase r oj ( ) Typically, ase is the origin of ref, and we drop ref. 5

6 6 CHAPTER 2. 3 DOF 2.1 Astract rotations Reference An astract rotation is denoted y R. The inverse rotation (same axis and magnitude, opposite direction) is denoted R 1. There are two different ut similar rotation operations that change the frame of a vector: r oj = R a a r oj r oj = a r oj a R We call R a a left-multiply operator, and a R a right-multiply operator. [4] uses left-multiply rotation matrices and right-multiply quaternions. [6] uses right-multiply quaternions and left-multiply rotation matrices. In this document, we present algorithms for oth left and right multiply operators. The derivations are usually done in full for left-multiply operators; the right-multiply can e otained simply y sustitution. The distinction etween left- and right-multiply only matters for quaternion and matrix representations, which have multiplication operators. We will see elow that R a = a R 1. Left-multiply Rotations can either change the reference frame of a vector, or rotate the vector into a new vector: aser 1 = a R a ase r 1 ( ) a ase r 2 = a a R 1 2 ase r 1 ( ) ase r 1 is the same physical vector as a ase r 1, ut expressed in a different reference frame. This is called a passive rotation. The two laels on the rotation are two frames: a R changes the frame of a vector from a to ; the rotation is also expressed in frame a. On the other hand, a ase r 2 is a different vector. It is not parallel to a ase r 1, ut it is expressed in the same frame; this is called an active rotation. On an active rotation, the pre-superscript laels the frame the rotation is expressed in, the post-suscript 1 2 identifies the start and end orientations; it rotates from orientation 1 to orientation 2. Often the orientations are also frames. We could use a different notation for the active rotation. For example, a R 2 1 a ase r 1 or a 2 R 1 a ase r 1 would make it slightly easier to match the start orientation lael

7 2.1. ABSTRACT ROTATIONS 7 to the vector position lael. However, the first option is confusing, since we normally read left-to-right. The second option is hard to correlate with code notations. The chosen notation works slightly etter for right-multiply rotations (see elow). Since a rotation does not move the ase position of a vector, we can usually drop the ase position from the notation. Note that the notation for a passive rotation gives two frames, while the notation for an active rotation gives one frame and two orientations, which may also e three frames. The notation helps get the frames and usage correct; when changing reference frames of vectors (passive rotation), the post-suscript must match the presuperscript for the equation to make sense. On the other hand, when physically rotating vectors (active rotation), all the pre-superscripts must e the same. This convention is especially useful when more than one rotation is present: c R a = c R R a ( ) c r 1 = c R R a a r 1 ( ) a R 1 3 = a R 1 2 a R 2 3 ( ) a r 3 = a R 2 3 a R 1 2 a r 1 ( ) Note that the inverse of a rotation is otained y swapping laels: Note that this holds for comined rotations: a R 1 = R a ( ) a R2 1 1 = a R 1 2 ( ) c R a = c R R a c R 1 a = R 1 a c R 1 = a R R c = a R c a R 1 3 = a R a 2 3 R 1 2 a R1 3 1 = a R a R = a R a 2 1 R 3 2 = a R 3 2 There are two passive rotations related to an active rotation: a R = a R a R a = a R 1 a ( )

8 8 CHAPTER 2. 3 DOF Note that for these equations to make sense, the reference frame of the active rotation must e either a or. We will see in 2.3 how to change the reference frame of an active rotation quaternion. Rotations are not commutative; R R a is not the same as R a R. However, rotations are associative; (R c R )R a = R c (R R a ). Right-multiply The notation for right-multiply astract rotations is: r 1 a r 2 = a r 1 a R = a r R a ar c = a R R c c r 1 = a r 1 a R R c 1 3R a = 1 2 R a 2 3R a a r 3 = a r R a 2 3R a ( ) R a = a R a ar = a R a 1 ( ) Note that the order of the two orientations (in the suscript) in active rotations is not changed etween left and right multiply notations. Note that we do not have a different notation for vectors in equations when using right-multiply rotations, even though we do in code Coding We summarize the coding conventions for translation vectors, quaternions, and matrices here, to have them all in one place. In the SAL coding naming convention, a variale representing the astract leftmultiply passive rotation a R is written A_Rot_B. The equivalent right-multiply passive rotation R a is writtenb_rot_a; the order of the laels reflects the order in the notation. The type SAL.Gen_Math.Gen_DOF_3.Cart_Vector_Type implements Cartesian vectors. When using left-multiply rotations, a vector a r 1 is written A_Tran_1; when using right multiply rotations, the vector is written 1_Tran_A. Thus ( ) is written: B_Tran_1 := B_Rot_A * A_Tran_1

9 2.1. ABSTRACT ROTATIONS 9 and the right rotation equivalent is written: 1_Tran_B := 1_Tran_A * A_Rot_B However, Ada names cannot start with numers, so care must e taken to use position and orientation laels that start with letters. Since a single program should only use either the right-multiply or left-multiply convention, the notation should not ecome confusing. The left-multiply active rotation a R 1 2 is writtena_rot_1_to_2. Thus ( ) is written: A_Tran_2 := A_Rot_1_To_2 * A_Tran_1 and the right multiply equivalent: 2_Tran_A := 1_Tran_A * 1_To_2_Rot_A In the SAL naming convention, the notation for quaternions is the same as for astract rotations, with Quat instead of Rot. Similarly, for matrices the SAL naming convention uses Rot_Mat instead of Rot. In the GN&C convention (which dictates more than just naming), rotation matrices are always passive left-multiply, and rotation quaternions are always passive right-multiply. The left multiply matrix M a is written Dcm_AToB; the right-multiply quaternion a Q is written Quat_AToB. A position vector for oj expressed in frame a is written Pos_A_Oj. Thus ( ) is written: Pos_B_Oj := Dcm_AToB * Pos_A_Oj and the quaternion right multiply equivalent is written: Pos_B_Oj := Pos_A_Oj * Quat_AToB Thus for rotation matrices, the frame order in the names is swapped etween SAL and GN&C naming conventions - the left-multiply passive rotation matrix a M is : a M = A_Rot_Mat_B = Dcm_BToA ( ) However, for rotation quaternions, the frame order in the names is the same etween SAL and GN&C naming conventions - the right-multiply passive rotation quaternion Q a is : Q a = B_Quat_A = Quat_BToA ( ) When using the GN&C convention, left and right multiplies are mixed in the same program, which will e confusing. To reduce the chances for error, left multiply matrices should only e used as user inputs; they should e immediately converted to right multiply quaternions efore eing used. In addition, the matrices should e named using the GN&C naming convention, while the

10 10 CHAPTER 2. 3 DOF quaternions should use the SAL naming convention. The conversion is given y: Q a = (to unit quaternion( a M )) 1 ( ) B_Quat_A := SAL.Math_Doule.Dof_3.Wertz.To_Unit_Quaternion (Dcm_BToA) where to unit quaternion is given y ( ). Note that SAL.Math_Doule.Dof_3.Wertz.To_Unit_Quaternion comines the inverse with the conversion to quaternion, preserving the frame order in this pair of variale names. This is ecause of the implicit conversion from left to right multiply, and it helps avoid mistakes in user code. There is no Ada type corresponding to an astract rotation. However, similar operations for the concrete rotation types are coded in similar ways, to make it easy to change the rotation type in applications. It is tempting to define two different Ada types for quaternions (or matrices); left-multiply and right-multiply. Then the compiler would guarantee they never got mixed up. However, that would mean any higher-level types that had quaternion components would also need left and right versions. In addition, code for operations that do not depend on the choice of left or right-multiply must e duplicated. This is too heavy a urden. Instead, the SAL math lirary provides one package defining rotation quaternion and rotation matrix types, and all the operations on them that do not depend on the choice of left or right multiply. Then there are two child packages providing the operations that do depend on the choice. One provides left-multiply quaternion and matrix operations. The other, following [6] and [3], supports right-multiply quaternion and left-multiply matrix operations. For higher level packages that use rotations, a similar package structure is used. In any case, careful attention must e paid to whether rotations are active vs passive, to the signs of angles, and to the order of operands in multiplication. 2.2 Angle Axis rotation representation Reference Every active rotation can e expressed as an angle aout an axis. If θ 1 2 is the angle from vector a r 1 to vector a r 2 aout axis aˆn (using the right-hand rule for the sign of θ 1 2 ), then a R 1 2 = (θ 1 2, aˆn) ( )

11 2.2. ANGLE AXIS ROTATION REPRESENTATION 11 Note that ˆn has magnitude 1: n 2 x + n2 y + n2 z = 1 ( ) The right-hand rule is: hold the right hand with the thum extended and the fingers loosely curled. Then the right thum is aligned with the axis of rotation, and the fingers curl in the positive direction of the rotation. Note that the same rotation can e represented y negating oth θ 1 2 and aˆn: a R 1 2 = ( θ 1 2, aˆn) ( ) So generally we can choose 0 <= θ 1 2 <= π. The Ada code does not enforce this in general, ut it does take advantage of it when converting from other rotation representations to angle axis. The inverse rotation is: a R 2 1 = ( θ 1 2, aˆn) ( ) = (θ 2 1, aˆn) The active rotation is computed y: a r 2 = a r 1 cosθ 1 2 a r 1 aˆnsinθ aˆn a r 1 aˆn(1 cosθ 1 2 ) ( ) Note that if we have two rotations (θ 1 2, ˆn 1 ) and (θ 2 3, ˆn 2 ), there is no simple way to find the equivalent total rotation. Rotation quaternions or matrices provide that operation. We now consider the passive rotations that are related to this active rotation. Since this involves changing frames, we use letters to lael the two orientations involved in the active rotation. Then the passive rotations that change the frame of vectors from to a and vice versa are: a R = (θ a, aˆn) R a = ( θ a, aˆn) ( ) An important case is otaining the minimal rotation that takes one vector into another. Given two unit vectors aˆn 1 and aˆn 2 expressed in a common frame f, the active rotation that moves aˆn 1 to e parallel to aˆn 2 is: a v = aˆn 1 aˆn 2 s = a v c = aˆn 1 aˆn 2 θ 1 2 = atan2(s, c)

12 12 CHAPTER 2. 3 DOF if s = 0 then aˆn = (1.0, 0.0, 0.0) else aˆn = a v/s ( ) end if Coding The type SAL.Gen_Math.Gen_DOF_3.Mag_Axis_Type implements the angle axis rotation representation. Operations are provided for scaling and conversion to quaternions and rotation matrices. SAL.Gen_Math.Gen_DOF_3.Rotate implements ( ). In the SAL naming convention, angle axis rotations are always active. See and for functions related to converting angle axis to quaternions and matrices Examples Some simple numerical examples. See spacecraft_math_examples.ad, Angle_Axis lock for Ada code implementing these. First, an active rotation of a vector in the x-z plane in a positive direction aout the y axis. ase r 1 = (2.0, 0.0, 1.0) ase R 1 2 = (θ 1 2, aseˆn) = (0.1, (0.0, 1.0, 0.0)) ase r 2 = ( , , ) Note that the x component increases, and the z component decreases; the end point of the vector is moved closer to the x axis. Now a spacecraft example; the direction of the z axis of the spacecraft. Assume the Sun is at the origin of the ase frame, and the spacecraft is positioned on the negative z axis of the ase frame. Initially, the z axis of the spacecraft frame is pointing at the sun. Then we rotate the spacecraft in a positive direction aout the y axis. Frame sc0 gives the initial orientation of the spacecraft; it is parallel to frame ase. Frame sc1 gives the final orientation of the spacecraft.

13 2.2. ANGLE AXIS ROTATION REPRESENTATION 13 Unit vector aseˆn scz0 gives the direction of the z axis of the spacecraft in the ase frame in the initial orientation; aseˆn scz1 in the final. aseˆn scz0 = (0.0, 0.0, 1.0) ase R sc0 sc1 = (0.1, (0.0, 1.0, 0.0)) aseˆn scz1 = ase R sc0 sc1 aseˆn scz0 = ( , , ) In the ase frame, the z axis of the spacecraft has moved towards the positive x axis. Now consider the direction from the spacecraft to the Sun; we know what it is in the ase frame, and we need to find it in the spacecraft frame. The unit vector ˆn sc sun gives the direction from the spacecraft to the sun, in a given frame. aseˆn sc sun = (0.0, 0.0, 1.0) sc0ˆn sc sun = (0.0, 0.0, 1.0) sc1 R sc0 = ase R 1 sc0 sc1 = ( 0.1, (0.0, 1.0, 0.0)) sc1ˆn sc sun = sc1 R sc0 sc0ˆn sc sun = ( , , ) In the spacecraft frame, the direction to the sun has moved towards the negative x axis Derivations First we show that ( ) is correct. Let frame a e fixed to the non-rotated vector a r 1 ; frame is fixed to the rotated vector a r 2. We denote the axes of frame a y (ˆx a, ŷ a, ẑ a ). For simplicity, we use r x to denote the x component of vector r in either frame; similarly for y and z. By definition: a r 1 = r xaˆx a + r yaŷ a + r zaẑ a ( ) Because a r 2 is a rotation of a r 1, it has the same values for its components in as a r 1 has in a, so we can write: a r 2 = r xaˆx + r yaŷ + r zaẑ ( ) Without loss of generality, we can let the axis of rotation aˆn = a ẑ = ẑ (this just defines the two frames uniquely). Then the axes of the frames are related y: aˆx = cosθ 1 2aˆx a + sinθ 1 2aŷ a ( ) aŷ = sinθ 1 2aˆx a + cosθ 1 2aŷ a ( ) aẑ = a ẑ a ( )

14 14 CHAPTER 2. 3 DOF Note that when θ 1 2 = 0, = a. Sustituting ( ), ( ), ( ) into ( ): a r 2 = (r x cosθ 1 2 r y sinθ 1 2 ) aˆx a + (r x sinθ r y cosθ 1 2 ) a ŷ a + r zaẑ a ( ) Expanding ( ), we have a r rot = r x cosθ 1 2aˆx a + r y cosθ 1 2aŷ a + r z cosθ 1 2aẑ a ( ) ( r xaŷ a + r yaˆx a )sinθ r z (1 cosθ 1 2 ) a ẑ a = (r x cosθ 1 2 r y sinθ 1 2 ) aˆx a + (r x sinθ r y cosθ 1 2 ) a ŷ + r zaẑ a ( ) which is the same as ( ). Repeating this analysis, picking aˆn = aˆx, a ŷ, shows that ( ) is correct Comparison to Kane ( ) corresponds to [4, eqn 1.1(1)]. The derivation here follows Kane s. 2.3 Quaternion rotation representation Reference A rotation quaternion consists of four numers, where the sum of the squares is 1: Q = (Q x, Q y, Q z, Q s ) ( ) 1 = Q 2 x + Q 2 y + Q 2 z + Q 2 s ( ) This is a unit quaternion; in general, non-unit quaternions (magnitude not restricted to 1) are also useful, ut we do not consider them here. Given an active angle axis rotation, the active left-multiply unit quaternion

15 2.3. QUATERNION ROTATION REPRESENTATION 15 equivalent is given y: a R a = (θ a, aˆn) a R a = a Q a a Q a = (sin(θ a /2) aˆn, cos(θ a /2)) Q x Q y = sin(θ a /2)n x = sin(θ a /2)n y Q z = sin(θ a /2)n z Q s = cos(θ a /2) ( ) Q x, Q y, Qz are called the vector components; Q s is called the scalar component. The related passive rotations are: a Q = (sin(θ a /2) aˆn, cos(θ a /2)) Q a = ( sin(θ a /2) aˆn, cos(θ a /2)) ( ) Negating all elements of the quaternion represents the same rotation: a R a = ( Q x, Q y, Q z, Q s ) ( ) The inverse of a quaternion is given y: Q a = a Q 1 = ( Q x, Q y, Q z, Q s ) ( ) To otain the active angle and axis (θ a, aˆn) from a left-multiply active quaternion a Q a : if Q s < 0 then end if Q = ( Q x, Q y, Q z, Q s ) s = Q 2 x + Q2 y + Q2 z if s > 0 then θ a = 2 atan2(s, Q s ) aˆn = (Q x /s, Q y /s, Q z /s) ( ) else θ a = 0 aˆn = (1, 0, 0)

16 16 CHAPTER 2. 3 DOF end if Note that the resulting θ is in the range [0.0, π]. Given an angle axis with θ in [ π, 0.0], conversion to quaternion and ack will negate the unit vector. To multiply a vector y a quaternion : r = Qr a = (Q y r z Q z r y, Q z r x Q x r z, Q x r y Q y r x ) r x = 2(Q s a x + Q y a z Q z a y ) + r x r y = 2(Q s a y + Q z a x Q x a z ) + r y r z = 2(Q s a z + Q x a y Q y a x ) + r z ( ) If Q is an active quaternion (ie, it represents an active rotation), r is a rotated vector: r = a r 2 = a Q 1 2 a r 1 ( ) If Q is a passive rotation, r is r expressed in a different frame: r = r 1 = Q a a r 1 ( ) To multiply quaternions: Q 3 = Q 1 Q 2 Q 3x = Q 1y Q 2z Q 1z Q 2y + Q 1s Q 2x + Q 1x Q 2s Q 3y = Q 1x Q 2z + Q 1s Q 2y + Q 1z Q 2x + Q 1y Q 2s Q 3z = Q 1s Q 2z + Q 1x Q 2y Q 1y Q 2x + Q 1z Q 2s Q 3s = Q 1z Q 2z Q 1y Q 2y Q 1x Q 2x + Q 1s Q 2s ( ) If the quaternions are active, this represents two successive physical rotations: a Q 1 3 = a Q a 2 3 Q 1 2 a r 3 = a Q a 2 3 Q a 1 2 r 1 ( ) If the quaternions are passive, this represents two successive coordinate transforms: c Q a = c Q Q a c r 1 = c Q Q a a r 1 ( ) The passive quaternions related to an active quaternion, when the reference frame of the active quaternion is either the start or end frame: a Q Q a = a Q a = a Q 1 a ( )

17 2.3. QUATERNION ROTATION REPRESENTATION 17 To change the reference frame of an active quaternion: Q c = Q a a Q c Q 1 a ( ) To convert an active quaternion to a passive quaternion when the reference frame of the active quaternion is aritrary: c Q = Q a a Q 1 c Q 1 a ( ) Successive passive quaternions related to successive active quaternions: a Q a c = a Q c a Q a a Q c = a Q Q c c Q a = c Q Q a ( ) Given two unit vectors, find the minimal rotation that takes one into the other: a v = aˆn 1 aˆn 2 s = a v c = aˆn 1 aˆn 2 if s = 0 then a Q 1 2 = (0.0, 0.0, 0.0, 1.0) else 1 c s2 = c c2 = 2 a Q 1 2 = ( s2 a v, c2) ( ) s end if ( ) defines the function units to quat for left-multiply. Right-multiply For right-multiply quaternions, we have: R a = Q a Q a = a Q 1 ( )

18 18 CHAPTER 2. 3 DOF Active quaternion and active angle axis: 1 2Q a = ( sin(θ 1 2 /2) aˆn, cos(θ 1 2 /2)) ( ) r = r Q a = ( Q yr z + Q zr y, Q zr x + Q xr z, Q xr y + Q yr x ) r x = 2(Q s a x Q y a z + Q z a y) + r x r y = 2(Q sa y Q za x + Q xa z ) + r y r z = 2(Q s a z Q x a y + Q y a x) + r z ( ) 1 3Q a = 1 2 Q a 2 3Q a ( ) a r 3 = a r Q a 2 3Q a ( ) Passive quaternions: Q a = a Q a aq = a Q a 1 aq c = a Q Q c c r 1 = a r 1 a Q Q c ( ) To otain the active angle and axis (θ 1 2, aˆn) from a right-multiply active quaternion 1 2 Q a : if Q s < 0 then Q = ( Q x, Q y, Q z, Q s ) end if s = Q 2 x + Q2 y + Q2 z if s > 0 then θ 1 2 = 2 atan2(s, Q s ) aˆn = (Q x /s, Q y /s, Q z /s) ( ) else θ 1 2 = 0 aˆn = (1, 0, 0) end if

19 2.3. QUATERNION ROTATION REPRESENTATION 19 Changing the frame of an active quaternion, and successive rotations: Function units to quat: aq = a Q a 1 ( ) cq = a Q 1 cq a aq ( ) Q c = a Q 1 cq a 1 aq ( ) a cq a = a Q a cq a cq a = c Q Q a aq c = a Q Q c ( ) a v = aˆn 1 aˆn 2 s = a v c = aˆn 1 aˆn 2 if s = 0 then a Q 1 2 = (0.0, 0.0, 0.0, 1.0) else 1 c s2 = c c2 = 2 a Q 1 2 = ( s2 a v, c2) ( ) s end if Coding The type SAL.Gen_Math.Gen_DOF_3.Unit_Quaternion_Type implements the quaternion rotation representation. The child package SAL.Gen_Math.Gen_DOF_3.Gen_Left provides left-multiply operations, the child package SAL.Gen_Math.Gen_DOF_3.Gen_Wertz provides right-multiply quaternion and left-multiply matrix operations. It is up to the user to decide whether the quaternions are passive or active, when using these packages. In particular, in the conversions etween quaternions and angle axis, the quaternion and angle axis are either oth active or oth passive. In the SAL convention, a variale representing the passive left-multiply quaternion a Q is written A_Quat_B; a right-multiply quaternion Q a is written

20 20 CHAPTER 2. 3 DOF B_Quat_A. An active left-multiply quaternion a Q 1 2 is written A_Quat_1_2; a right-multiply quaternion 1 2 Q a is written 1_2_Quat_A. Any single program should use only left or right multiply, so this convention should not e confusing. In the GN&C software naming convention a variale representing the passive right-multiply quaternion Q a is writtenquat_btoa. The GN&C software naming convention has no notation for left-multiply or active quaternions Examples See spacecraft_math_examples.ad, Quaternions_Left lock for Ada code implementing these. Some of these examples are the same as in 2.2.3, ut using left-multiply quaternions. We duplicate the descriptions here for convenience. The Ada code also shows the right-multiply equivalents. First, an active rotation of a vector in the x-z plane in a positive direction aout the y axis. ase Q 1 2 = to unit quaternion(θ 1 2, aseˆn) = to unit quaternion(0.1, (0.0, 1.0, 0.0)) = ( , , , ) ase r 1 = (2.0, 0.0, 1.0) ase r 2 = ( , , ) Note that the y component of the quaternion has the same sign as the angle. Note that the x component of ase r 2 increases, and the z component decreases; the end point of the vector is moved closer to the x axis. Now we apply a second active rotation, and show that quaternion multiplication is associative: ase Q 2 3 = to unit quaternion(π/2, (1.0, 0.0, 0.0)) = ( , , , ) ase Q 1 3 = ase Q 2 3 ase Q 1 2 = ( , , , ) ase r 3 = ase Q 2 3 ase r 2 = ( , , ) ase r 3 = ase Q 1 3 ase r 1 = ( , , ) Now a spacecraft example; the direction of the z axis of the spacecraft. Assume the Sun is at the origin of the ase frame, and the spacecraft is positioned on the

21 2.3. QUATERNION ROTATION REPRESENTATION 21 negative z axis of the ase frame. Initially, the z axis of the spacecraft frame is pointing at the sun. First we rotate the spacecraft in a positive direction aout the ase y axis, then aout the ase x axis. Frame sc0 gives the initial orientation of the spacecraft; it is parallel to frame ase. Frame sc1 gives the orientation of the spacecraft after the first rotation, sc2 after the second. Unit vector aseˆn scz0 gives the direction of the z axis of the spacecraft in the ase frame in the initial orientation; aseˆn scz1 after the first rotation. aseˆn scz0 = (0.0, 0.0, 1.0) ase Q sc0 sc1 = to unit quaternion(0.1, (0.0, 1.0, 0.0)) = ( , , , ) aseˆn scz1 = ( , , ) In the ase frame, the z axis of the spacecraft has moved towards the positive x axis. Now we apply a second rotation, aout the ase x axis. ase R sc1 sc2 = to unit quaternion(π/2, (0.0, 1.0, 0.0))) = ( , , , ) aseˆn scz2 = ( , , ) Now consider the direction from the spacecraft to the Sun; we know what it is in the ase frame, and we need to find it in the spacecraft frame. The unit vector ˆn sc sun gives the direction from the spacecraft to the sun, in a given frame. We use the same two rotations as aove; we need passive quaternions for this, so the result of converting from active angle axis is inverted. aseˆn sc sun = (0.0, 0.0, 1.0) sc0ˆn sc sun = (0.0, 0.0, 1.0) sc1 Q ase = (to unit quaternion(0.1, (0.0, 1.0, 0.0))) 1 = ( , , , ) sc1ˆn sc sun = ( , , ) In the spacecraft frame, the direction to the sun has moved towards the negative x axis. Now we apply a second rotation, aout the ase x axis. We show the angle axis equivalent to each quaternion, since that may e easier to visualize. The Ada

22 22 CHAPTER 2. 3 DOF code also shows that quaternion multiply is associative. sc1 Q sc1 sc2 = sc1 Q ase ase Q sc1 sc1 sc2 Q 1 ase = ( , , , ) sc1 R sc1 sc2 = ( , ( , , )) sc2 Q sc1 = sc1 Q 1 sc1 sc2 = ( , , , ) sc2 R sc1 = ( , ( , , )) sc2ˆn sc sun = ( , , ) Vector Scalar formulation The equations for quaternion times quaternion and quaternion times vector can also e expressed in pure vector notation, without reference to any Cartesian frame. First, we denote the vector and scalar parts of a quaternion y: Q 1 = (q 1v, Q 1s ) ( ) Then ( ) ecomes Q 3 = Q 1 Q 2 = (q 2v Q 1s + q 1v Q 2s + q 1v q 2v, Q 1s Q 2s q 1v q 2v ) ( ) This illustrates that there is a frame involved in a quaternion that is not shown in the quaternion notation; the reference frame of the vector part. However, the vector part is an eigenvector of the rotation (it is parallel to the axis of rotation), so it does not matter whether it is expressed in a or. To actively rotate a vector in this formulation, form a quaternion (not a unit quaternion) from the vector y setting the scalar part to zero. Then ( ) ecomes a r 2 = a Q 1 2 a r 1 ( ) = a Q 1 2 ( a r 1, 0) a Q 1 2 ( ) where a Q 1 2 is the conjugate quaternion, and is the same as a Q The multiplication operator in ( ) is given y ( ); in ( ), it is given y ( ). Expanding and applying vector and trig identities, this reduces to ( ). See derive_vect_scalar_quat.maxima for details.

23 2.3. QUATERNION ROTATION REPRESENTATION 23 Similarly, for a passive rotation, ( ) ecomes r 1 = Q a a r 1 = Q a ( a r 1, 0) Q a ( ) When comining rotations, as in ( ), this is: c Q a = c Q Q a c r 1 = c Q a ( a r 1, 0) c Q a c r 1 = c Q Q a ( a r 1, 0) Q a c Q ( ) Right-multiply For right-multiply quaternions, the non-conjugate quaternion is on the right: a r 2 r 1 = a r Q a = 1 2 Q a ( a r 1, 0) 1 2 Q a ( ) = a r 1 a Q = a Q ( a r 1, 0) a Q ( ) aq c = a Q Q c c r 1 = a Q c ( a r 1, 0) a Q c c r 1 = Q c aq ( a r 1, 0) a Q Q c ( ) This is the motivation for the names left-multiply, right-multiply for quaternions Derivations ( ) is simply the definition of an active left-multiply rotation quaternion. ( ) is otained from ( ) y sustituting θ 1 2 for θ 1 2. To see that ( ) gives the same rotation, note that Q i always occurs in pairs in ( ). Thus changing the sign of all Q i has no effect on the rotated vector. Also compare this to ( ). Note that we could restrict Q s >= 0. However, enforcing that condition in every quaternion operation is inefficient; instead we only enforce it where it is useful, such as in conversion to angle axis. ( ) is derived from ( ) and ( ). We negate the vector components of the quaternion rather than the scalar component, ecause then the

24 24 CHAPTER 2. 3 DOF inverse operation is the same as the conjugate operation, used in the vectorscalar formulation of quaternion times vector (see 2.3.4). ( ) is derived from ( ) using the trigonometric identity θ = atan2(sin(θ), cos(θ)). Q s is forced positive to ensure that θ is in the range [0, 2π); otherwise it would e in the range [0, 4π). Care is taken to ensure that conversion from angle to axis to quaternion and ack is identity for the angle in [0.0, π). ( ) is singular when s is zero. To see how to handle the singularity, consider the quaternion (ǫ, 0, 0, 1), where ǫ is the largest numer such that 1 + ǫ = 1 to machine precision. Note that this satisfies ( ), since 1 + ǫ 2 = 1. Note that s = ǫ, and ( ) is well-ehaved. Thus there is only a prolem when s is identically zero. In that case, the magnitude of the rotation is zero, and the axis is undetermined, so we simply pick the x axis. To prove that ( ) is the equation for rotating a vector, sustitute ( ) into ( ), and compare to ( ). See derive_quat_times_vect.maxima for the details. Note that the temporary variale a provides a significant optimization; this was first pulished in [5]. To prove that ( ) is the equation for comining rotations, we evaluate (Q a Q )r and Q a (Q r) using ( ) and ( ), and show they are the same. See derive_quat_times_quat.maxima for the details. To prove ( ), start with a vector rotation, and change the frame of the vectors: a r 2 = a Q a c r 1 a r 1 = Q 1 a r 1 r 2 = Q a a r 2 Q c = Q a a Q a c r 1 = Q a a Q c Q 1 a r 1 = Q a a Q c Q 1 a ( ) is derived from ( ) and ( ), simplifying the inverses: c Q = Q 1 c = ( Q a a Q c Q 1 a ) 1 = Q a a Q 1 c Q 1 a To prove ( ), start y simply inverting the active quaternions: a Q a c a Q 1 a c c Q a = a Q a c Q a = a Q 1 a a Q 1 c = Q a a Q 1 c

25 2.3. QUATERNION ROTATION REPRESENTATION 25 To proceed from here, we need to get the second term into the form of ( ). So we insert Q 1 a Q a, which is identity, and regroup: c Q a = Q a ( Q 1 a Q a ) a Q 1 c ( Q 1 a Q a ) = Q a Q 1 a ( Q a a Q 1 c Q 1 a ) Q a = c Q Q a Right-multiply The right-multiply equations ( ) thru ( ) are otained from the corresponding left multiply equations y consistently negating the vector components of the quaternions, and reversing the order of multiplied quaternions Comparison to Kane [4] calls quaternion components Euler parameters, with symol ǫ. Set Q x = ǫ 1, Q y = ǫ 2, Q z = ǫ 3, Q s = ǫ 4 to otain our notation. ( ) is equivalent to [4, eqn 1.2(1)-(2)]; oth are active rotations. ( ) is equivalent to [4, eqn 1.3(21)]. See derive_quat_times_vect_kane.maxima for details. ( ) is the same as [4, eqn 1.6(12)] Comparison to Wertz For historical reasons, this section compares left-multiply quaternions to Wertz. It was in the process of doing this comparison that I recognized the existence of right-multiply quaternions, and finally understood the origin of the sign difference etween Kane and Wertz quaternions. ( ) is the same as [6, eqn (D-8)], with q = Q 3 q = Q 1 q = Q 2 ( ) is equivalent to [6, eqn (D-11)], with U = r 1,U = a r 1,q = Q 1 a.

26 26 CHAPTER 2. 3 DOF Thus (D-11) is equivalent to ( ), if we set: Q x = q 1 Q y = q 2 Q z = q 3 Q s = q 4 ( ) See derive_quat_times_vect_wertz.maxima for detailed proof. Now consider comining passive rotations, as in ( ). In Wertz s notation, this is: q = qq U = q Uq U = q q Uqq Thus, in our notation, c Q is the second passive rotation, and is on the left, while in Wertz, q is the second passive rotation, and is on the right. This corresponds to whether the non-conjugate is on the left or the right in ( ); Wertz uses the right-multiply convention. ( ) is equivalent to [6, eqns (12-11a) - (12-11d)], with ( ) and φ = θ. Note that Wertz does not carefully define the direction of φ. 2.4 Matrix rotation representation Reference A rotation matrix is a 3 y 3 orthonormal matrix, with determinant +1. The inverse of a rotation matrix is given y the transpose: M 1 = M T ( ) The active rotation matrix a M 1 2 equivalent to the active angle axis rotation defined in ( ) is given y: a M 1 2 = ( ) cosθ n 2 x versθ 1 2 n z sinθ n x n y versθ 1 2 n y sinθ n x n z versθ 1 2 n z sinθ n x n y versθ 1 2 cosθ n 2 y versθ 1 2 n x sinθ n y n z versθ 1 2 n y sinθ n x n z versθ 1 2 n x sinθ n y n z versθ 1 2 cosθ n 2 zversθ 1 2 where versθ 1 2 = 1 cosθ 1 2.

27 2.4. MATRIX ROTATION REPRESENTATION 27 To otain the angle axis from an active rotation matrix: if a > 0 then a = (Mxy M yx ) 2 + (M zx M xz ) 2 + (M yz M zy ) 2 = M xx + M yy + Mzz 1 2 θ 1 2 = atan2(a, ) 2 aˆn = (M yz M zy, M zx M xz, M xy M yx ) 2a ( ) else aˆn = (1, 0, 0) end if To otain the active rotation matrix a M 1 2 equivalent to the active unit quaternion a Q 1 2 : a M 1 2 = 1 2Q 2 z 2Q2 y 2Q x Q y 2Q s Q z 2Q x Q z + 2Q s Q y 2Q s Q z + 2Q x Q y 1 2Q 2 z 2Q 2 x 2Q y Q z 2Q s Q x 2Q x Q z 2Q s Q y 2Q y Q z + 2Q s Q x 1 2Q 2 y 2Q2 x ( ) To otain the active quaternion a Q 1 2 from the active rotation matrix a M 1 2 : a = M xx + M yy + M zz = M xx M yy M zz c = M xx + M yy M zz d = M xx M yy + M zz ( ) if a > max(, max(c, d)) then e = a Q x = M zy M yz e Q y = M xz M zx e Q z = M yx M xy e Q s = e 4

28 28 CHAPTER 2. 3 DOF elsif > max(a, max(c, d)) then e = elsif c > max(a, max(, d)) then else end if Q x = e 4 Q y = M xy + M yx e Q z = M xz + M zx e Q s = M zy M yz e e = c Q x = M xy + M yx e Q y = e 4 Q z = M yz + M zy e Q s = M xz M zx e e = d Q x = M xz + M zx e Q y = M yz + M zy e Q z = e 4 Q s = M yx M xy e It may e desireale to normalize the quaternion after applying ( ), to eliminate roundoff errors, or small orthogonality errors in the original matrix. To rotate a vector using a rotation matrix, use normal matrix multiply: r = Mr ( ) If M is an active matrix (ie, it represents an active rotation), r is a rotated vector: r = a r 2 = a M 1 2 a r 1 ( )

29 2.4. MATRIX ROTATION REPRESENTATION 29 If M is a passive rotation, r is r expressed in a different frame: r = r 1 = M a a r 1 ( ) To multiply rotation matrices, use normal matrix multiply: M c = M a M ( ) If the matrices are active, this represents two successive physical rotations: a r 3 = a M a 2 3 M a 1 2 r 1 ( ) If the matrices are passive, this represents two successive coordinate transforms: c r 1 = c M M a a r 1 ( ) Right-multiply Since the SAL math lirary does not provide right-multiply matrices, we do not present them here Coding The type SAL.Gen_Math.Gen_DOF_3.Rot_Matrix_Type implements the orthonormal matrix rotation representation. The child packages SAL.Gen_Math.Gen_DOF_3.Gen_Left and SAL.Gen_Math.Gen_DOF_3.Gen_Wertz oth provide left-multiply rotation matrix operations. Right-multiply rotation matrix operations are not provided. A variale representing the passive left-multiply rotation matrix a M is written A_Rot_Mat_B. In the GN&C convention the passive left multiply matrix a M is writtendcm_btoa. SAL.Math_Doule.Dof_3.Left.To_Unit_Quaternion implements ( ); SAL.Math_Doule.Dof_3.Wertz.To_Unit_Quaternion implements ( ) with an additional inverse, so that the result represents the same rotation (the left multiply quaternion is the numerical inverse of the right multiply quaternion) Examples See spacecraft_math_examples.ad, Rot_Matrix lock for Ada code implementing these. This example is the same as the first one in 2.3.3, ut using left-multiply rotation matrices. Since the primary use of rotation matrices is to convert them to quaternions, the other examples are not relevant.

30 30 CHAPTER 2. 3 DOF An active rotation of a vector in the x-z plane in a positive direction aout the y axis. ase M 1 2 = to rot matrix(θ 1 2, aseˆn) = to rot matrix(0.1, (0.0, 1.0, 0.0)) = ase Q 1 2 = to unit quaternion( ase M 1 2 ) = ( , , , ) ase r 1 = (2.0, 0.0, 1.0) ase r 2 = ase M ase 1 2 r 1 = ( , , ) Derivations ( ) is simply the definition of matrix multiplication. ( ) is the correct way to comine rotations, ecause of the associativity of matrix multiply. ( ) is derived from ( ) y finding the coefficient matrix for a r 1 ; see derive_angle_axis_to_rot_matrix.maxima for details. To derive ( ), start with ( ), take various cominations of M ij, and use n 2 x + n2 y + n2 z = 1. M xy M yx = 2n z sin(θ) ( ) M zx M xz = 2n y sin(θ) ( ) M yz M zy = 2n x sin(θ) ( ) M xx + M yy + Mzz = 3cos(θ) + (n 2 x + n 2 y + n 2 z)vers(θ) = 1 + 2cos(θ) ( ) Now we can find θ from ( ), ( ), ( ), and ( ): (Mxy M yx ) sin(θ) = 2 + (M zx M xz ) 2 + (M yz M zy ) 2 2 cos(θ) = M xx + M yy + Mzz 1 2 θ = atan2(sin(θ), cos(θ)) ( ) Note we have chosen sin(θ) >= 0, so we have 0 <= θ < π. The axis n is found y: ˆn = (M yz M zy, M zx M xz, M xy M yx ) 2sin(θ) ( )

31 2.4. MATRIX ROTATION REPRESENTATION 31 This is singular when sin(θ) = 0. Consider θ = ǫ; then cos(theta) = 1, sin(theta) = ǫ, and ( ) ecomes: ˆn = (2n xǫ, 2n y ǫ, 2n z ǫ) 2ǫ ( ) This is well ehaved unless sin(θ) is exactly zero. In that case, the axis is indeterminate, so we simply choose the x axis. See derive_rot_matrix_to_angle_axis.maxima for details of the aove derivation. To derive ( ), start with ( ), and find the coefficients of each vector component; see derive_quat_to_rot_matrix.maxima. To derive ( ), start with the diagonal elements of ( ), and ( ); this gives us four equations in the four unknowns Q 2 i. We solve for one of them (call it Q j ); then we can take various cominations of M ij and divide y Q j to find the remaining Q i. We want the largest magnitude divisor, to avoid singularities. So first we need to decide which divisor is the largest. 1 = Q 2 s + Q2 x + Q2 y + Q2 z M xx = 1 2Q 2 z 2Q2 y M yy = 1 2Q 2 z 2Q 2 x M zz = 1 2Q 2 y 2Q2 x ( ) To solve for Q s : M xx + M yy + M zz = 1 2Q 2 z 2Q2 y + 1 2Q 2 z 2Q 2 x + 1 2Q 2 y 2Q2 x = 3 4(Q 2 x + Q2 y + Q2 z ) = 3 4(1 Q 2 s) = 1 + 4Q 2 s Q s = 1 + Mxx + M yy + M zz 4 ( ) To solve for Q x : M xx M yy M zz = 1 2Q 2 z 2Q 2 y 1 + 2Q 2 z + 2Q2 x 1 + 2Q 2 y + 2Q 2 x = 1 + 4Q 2 x Q x = 1 + Mxx M yy M zz 4 ( )

32 32 CHAPTER 2. 3 DOF Q y and Q z are similar. Thus to pick the largest magnitude divisor, we find the maximum of the four cominations of M ii : a = M xx + M yy + M zz = M xx M yy M zz c = M xx + M yy M zz d = M xx M yy + M zz ( ) Now we can take various cominations of M ij and divide y Q j. For example, to find Q x when we have Q s : M zy M yz = 2Q y Q z + 2Q s Q x (2Q y Q z 2Q s Q x ) = 4Q s Q x Q x = M zy M yz 4Q s ( ) Similarly for the other Q i. Note we can save some computations y first computing 4Q j instead of Q j. See derive_rot_matrix_to_quat.maxima for full details Comparison to Kane ( ) corresponds to [4, eqn 1.2(9)]: B v = A v A C B However, Kane uses the right-multiply convention for matrices. Thus A C B is related to our notation y M a = A C B. ( ) corresponds to [4, eqn 1.2(23)-(31)]. However, Kane s C is a passive matrix corresponding to an active angle axis rotation, using the right-multiply convention, while a M is an active matrix using the left-multiply convention. These two differences cancel, and we have a M = C. ( ) is similar to [4, eqn 1.3(6)-(14)]. However, Kane s C is a right-multiplying passive matrix, while our a M is a left-multiply active matrix. The quaternions are the same. Thus we have C = a M. ( ) is similar to [4, 1.3(6)-(14)]. In addition to the differences in the matrix convention, Kane does not consider the singularity. Similarly, ( ) is similar to [4, eqn 1.6(4)].

33 2.5. ROTATION VECTOR REPRESENTATION Comparison to Wertz ( ) is the same as [6, eqn (12-4)]. Note that Wertz s notation does not include frames. ( ) corresponds to [6, eqn (12-7a)], with φ = θ 1 2, except that Wertz s A is an active left-multiply matrix (see figure 12-2), so the matrix is inverted (transposed). ( ) is similar to [6, eqn (12-9) - (12-10c)], ut Wertz does not consider the singularity. ( ) is equivalent to [6, eqn (12-13a)], with ( ). Note that Wertz s q is right-multiply, while our a Q is left-multiply; the matrices are oth leftmultiply. ( ) is equivalent to [6, eqns (12-14a) d)], with ( ), and we have slightly optimized the handling of the singularity. 2.5 Rotation vector representation Reference A rotation vector comines the magnitude and axis information into one vector: θ = θˆn ( ) where θ is the magnitude of the rotation, and ˆn is the rotation axis. This is useful mainly for differential rotations, since then the rotation vectors can simply e added. To find the rotation vector from a quaternion or rotation matrix: (θ, ˆn) = to angle axis(r) where to angle axis is either ( ) or ( ). θ = θ ˆn ( ) To find a quaternion or rotation matrix from a rotation vector: θ = θ ˆn = θ/θ Q = to unit quaternion(θ, ˆn) ( ) M = to rot matrix(θ, ˆn) ( )

34 34 CHAPTER 2. 3 DOF where to unit quaternion is given y ( ), and to rot matrix is given y ( ). ( ) defines the function rotvect to quat. An important case is otaining the rotation due to a rotational velocity acting over a finite time; see section Coding The type SAL.Gen_Math.DOF_3.Cart_Vector_Type is used for the rotation vector representation; there are functions to convert etween rotation vectors and quaternions. A variale representing the active rotation vector a θ 1 2 is writtena_rot_vect_1_2 when using the left-multiply convention, 1_2_Rot_Vect_A when using the rightmultiply convention. 2.6 Rate Reference The time rate of change of the position of an oject is called the translation rate or velocity of an oject. It is defined y the time rate of change of the position of a point fixed in the oject (normally the origin of the oject s coordinate frame). The translation rate is measured relative to a ase frame, and is expressed in a coordinate frame. To indicate all these frames, we use the notation coord ase v oj. Often we need to deal with velocities measured in frames that are moving with respect to each other. Assume frame is moving with velocity a a v with respect to frame a; framesaand are parallel. The velocity a av oj with respect to frame a given the velocity with respect to frame is computed y: a a v oj = a v oj + a a v ( ) However, if the velocities involved are a significant fraction of the speed of light,

35 2.6. RATE 35 this must e replaced y the Lorentz transform: a v oj = a a v oj aa v a a v 2 a a v v oj = a v oj a v oj γ = 1 a av 2 c 2 a a v oj = see section for one use of this. a a v + a v oj + γ a v oj 1 + a v oj aa v ( ) c 2 The time rate of change of orientation of an oject is called the rotation rate of an oject. It is defined y the time rate of change of an oject frame (rigidly attached to the oject). An oject rate is measured relative to a ase frame, and is expressed in a coordinate frame. To indicate all these frames, we use the notation ref ase ω oj. ω is called a rotation velocity vector. Usually, the ase frame is an inertial frame, and is not specified. In order to integrate the rotation position of a ody over time, or to compute the rotation rate from a sequence of rotation positions, we need to show how to relate ω to the time derivative of the orientation of an oject. In the SAL convention the orientation of an oject is represented y a passive quaternion that transforms vectors in the oject frame to the ase frame: ase r a = ase Q oj oj r a ( ) In the GNC (right-multiply) convention, the orientation of an oject is represented y ase Q oj. If the rotation rate of the oject oj ω oj is constant over a finite time, the resultant active rotation of the oject from time t 1 to time t 2 is: oj θ t1 t 2 = oj ω oj (t 2 t 1 ) ( ) Left-multiply A passive left-multiply quaternion equivalent to the active rotation oj θ t1 t 2 is (see ( )): t 1 Q t2 = rotvect to quat( oj θ t1 t 2 ) ( ) Note that the reference frame of the rotation vector must e the oject frame at time t1 or t2 for this operation to e valid; see ( ).

36 36 CHAPTER 2. 3 DOF A series of finite passive rotations can e comined to give a sequence of oject orientations: ase Q t2 = ase Q t1 t 1 Q t2 ( ) ase Q t3 = ase Q t2 t 2 Q t3 ( ) Then we can compute the rate oj ω oj from the sequence: oj ω oj = quat to rotvect( ase Q 1 t 1 ase Q t2 )/(t 2 t 1 ) ( ) ω ehaves like a vector under coordinate transforms: ω = a Q 1 a ω a ( ) Note that since frames a and oj are oth rigidly attached to the same oject at the same point, we can simply change the lael on a ω oj. The translational velocity of a point on the rotating ody is given y: oj v 1 = oj ω oj oj r 1 ( ) This can e expressed as a left-multiply matrix operator: a v 1 = a r a 1 ω a a r 1 = 0 r z r y r z 0 r x r y r x 0 ( ) Right-multiply SAL convention: GNC convention: t 2 Q t1 = rotvect to quat( oj θ t1 t 2 ) ( ) t 2 Q ase = t2 Q t1 t 1 Q ase ( ) oj ω oj = quat to rotvect( t2 Q ase t 1 Q ase 1 )/(t 2 t 1 ) ( ) t 1 Q t2 = rotvect to quat( oj θ t1 t 2 ) ( ) aseq t2 = ase Q t1 t 1 Q t2 ( ) oj ω oj = quat to rotvect( ase Q t1 1 aseq t2 )/(t 2 t 1 ) ( ) Since a r 1 is a left-multiply matrix, and the SAL lirary does not provide rightmultiply matrices, there is no right-multiply version of a r 1.

37 2.6. RATE Coding A variale representing frame ω oj is written Frame_Rot_Rate_Oj in the leftmultiply convention, Oj_Rot_Rate_Frame in right-multiply. A variale representing coord ase v oj is writtencoord_vel_oj_wrt_base in the left multiply convention, Oj_Wrt_Base_Vel_Coord in right-multiply. wrt means with respect to. The function SAL.Gen_Math.Gen_DOF_3.Lorentz_Transform implements ( ) Examples See spacecraft_math_examples.ad, Rotation_Rate_Left lock for Ada code implementing these. To clarify the difference etween active and passive rotations, we relate all rotations to the oresight of a star tracker mounted on a spacecraft. First we present the example using SAL convention left-multiply quaternions, then SAL and GNC orientation conventions for right-multiply quaternions. Note that the oresight vector, and the spacecraft rate vector, are the same for all three representations, ut the quaternions are different. We use the International Celestial Reference Frame (ICRF) as the ase frame for this example. In the star tracker frame st, the oresight stˆn ore is a constant. Assume the initial star tracker orientation is ICRF Q st,t1 ; a passive quaternion. Then rotate it y 0.1 radians aout the X axis in 0.5 seconds (an active rotation), to orientation ICRF Q st,t2, and compute the oresight in ICRF in oth

38 38 CHAPTER 2. 3 DOF orientations: stˆn ore = (0.0, 0.0, 1.0) ICRF Q st,t1 = ( , , , ) ICRF ˆn ore,t1 = ICRF Q st,t1 stˆn ore = ( , , ) θ = 0.1 (t 2 t 1 ) = 0.5 st ω st = ( θ/(t 2 t 1 ), 0.0, 0.0) = ( , , ) ICRF Q st,t1 t 2 = rotvect to quat( st ω st (t 2 t 1 )) = ( , , , ) = st,t1 Q st,t2 ICRF Q st,t2 ICRF ˆn ore,t2 = ICRF Q st,t1 st,t 1 Q st,t2 = ( , , , ) = ICRF Q st,t2 stˆn ore = ( , , ) Now we have two ways to compute the rate; from the two oresight unit vectors, and from the two orientation quaternions: st,t 1 Q st,t2,a = ICRF Q st,t1 t 2 = units to quat( ICRF ˆn ore,t1, ICRF ˆn ore,t2 ) = ( , , , ) st,t 1 Q st,t2, = ICRF Q 1 st,t ICRF 1 Q st,t2 = ( , , , ) st ω st = quat to rotvect( st,t1 Q st,t2 )/(t 2 t 1 ) = ( , , )

Solving Systems of Linear Equations Symbolically

Solving Systems of Linear Equations Symbolically " Solving Systems of Linear Equations Symolically Every day of the year, thousands of airline flights crisscross the United States to connect large and small cities. Each flight follows a plan filed with

More information

PHYS 705: Classical Mechanics. Introduction and Derivative of Moment of Inertia Tensor

PHYS 705: Classical Mechanics. Introduction and Derivative of Moment of Inertia Tensor 1 PHYS 705: Classical Mechanics Introduction and Derivative of Moment of Inertia Tensor L and N depends on the Choice of Origin Consider a particle moving in a circle with constant v. If we pick the origin

More information

9. Diffraction. Lattice vectors A real-space (direct) lattice vector can be represented as

9. Diffraction. Lattice vectors A real-space (direct) lattice vector can be represented as 1 9. Diffraction Direct lattice A crystal is a periodic structure in real space. An ideal crystal would have complete translational symmetry through all of space - infinite, that is. So, oviously, there

More information

Lesson Rigid Body Dynamics

Lesson Rigid Body Dynamics Lesson 8 Rigid Body Dynamics Lesson 8 Outline Problem definition and motivations Dynamics of rigid bodies The equation of unconstrained motion (ODE) User and time control Demos / tools / libs Rigid Body

More information

45. The Parallelogram Law states that. product of a and b is the vector a b a 2 b 3 a 3 b 2, a 3 b 1 a 1 b 3, a 1 b 2 a 2 b 1. a c. a 1. b 1.

45. The Parallelogram Law states that. product of a and b is the vector a b a 2 b 3 a 3 b 2, a 3 b 1 a 1 b 3, a 1 b 2 a 2 b 1. a c. a 1. b 1. SECTION 10.4 THE CROSS PRODUCT 537 42. Suppose that all sides of a quadrilateral are equal in length and opposite sides are parallel. Use vector methods to show that the diagonals are perpendicular. 43.

More information

CSE 167: Introduction to Computer Graphics Lecture #2: Linear Algebra Primer

CSE 167: Introduction to Computer Graphics Lecture #2: Linear Algebra Primer CSE 167: Introduction to Computer Graphics Lecture #2: Linear Algebra Primer Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2016 Announcements Monday October 3: Discussion Assignment

More information

58. The Triangle Inequality for vectors is. dot product.] 59. The Parallelogram Law states that

58. The Triangle Inequality for vectors is. dot product.] 59. The Parallelogram Law states that 786 CAPTER 12 VECTORS AND TE GEOETRY OF SPACE 0, 0, 1, and 1, 1, 1 as shown in the figure. Then the centroid is. ( 1 2, 1 2, 1 2 ) ] x z C 54. If c a a, where a,, and c are all nonzero vectors, show that

More information

1 Systems of Differential Equations

1 Systems of Differential Equations March, 20 7- Systems of Differential Equations Let U e an open suset of R n, I e an open interval in R and : I R n R n e a function from I R n to R n The equation ẋ = ft, x is called a first order ordinary

More information

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

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 Chapter 2 (3 3) Matrices The methods used described in the previous chapter for solving sets of linear equations are equally applicable to 3 3 matrices. The algebra becomes more drawn out for larger matrices,

More information

Module 9: Further Numbers and Equations. Numbers and Indices. The aim of this lesson is to enable you to: work with rational and irrational numbers

Module 9: Further Numbers and Equations. Numbers and Indices. The aim of this lesson is to enable you to: work with rational and irrational numbers Module 9: Further Numers and Equations Lesson Aims The aim of this lesson is to enale you to: wor with rational and irrational numers wor with surds to rationalise the denominator when calculating interest,

More information

Course 2BA1: Hilary Term 2007 Section 8: Quaternions and Rotations

Course 2BA1: Hilary Term 2007 Section 8: Quaternions and Rotations Course BA1: Hilary Term 007 Section 8: Quaternions and Rotations David R. Wilkins Copyright c David R. Wilkins 005 Contents 8 Quaternions and Rotations 1 8.1 Quaternions............................ 1 8.

More information

CSE 167: Introduction to Computer Graphics Lecture #2: Linear Algebra Primer

CSE 167: Introduction to Computer Graphics Lecture #2: Linear Algebra Primer CSE 167: Introduction to Computer Graphics Lecture #2: Linear Algebra Primer Jürgen P. Schulze, Ph.D. University of California, San Diego Spring Quarter 2016 Announcements Project 1 due next Friday at

More information

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

MCE/EEC 647/747: Robot Dynamics and Control. Lecture 2: Rigid Motions and Homogeneous Transformations MCE/EEC 647/747: Robot Dynamics and Control Lecture 2: Rigid Motions and Homogeneous Transformations Reading: SHV Chapter 2 Mechanical Engineering Hanz Richter, PhD MCE503 p.1/22 Representing Points, Vectors

More information

Flight Dynamics & Control Equations of Motion of 6 dof Rigid Aircraft-Kinematics

Flight Dynamics & Control Equations of Motion of 6 dof Rigid Aircraft-Kinematics Flight Dynamic & Control Equation of Motion of 6 dof Rigid Aircraft-Kinematic Harry G. Kwatny Department of Mechanical Engineering & Mechanic Drexel Univerity Outline Rotation Matrix Angular Velocity Euler

More information

This appendix provides a very basic introduction to linear algebra concepts.

This appendix provides a very basic introduction to linear algebra concepts. APPENDIX Basic Linear Algebra Concepts This appendix provides a very basic introduction to linear algebra concepts. Some of these concepts are intentionally presented here in a somewhat simplified (not

More information

Vector Spaces. EXAMPLE: Let R n be the set of all n 1 matrices. x 1 x 2. x n

Vector Spaces. EXAMPLE: Let R n be the set of all n 1 matrices. x 1 x 2. x n Vector Spaces DEFINITION: A vector space is a nonempty set V of ojects, called vectors, on which are defined two operations, called addition and multiplication y scalars (real numers), suject to the following

More information

Sample Solutions from the Student Solution Manual

Sample Solutions from the Student Solution Manual 1 Sample Solutions from the Student Solution Manual 1213 If all the entries are, then the matrix is certainly not invertile; if you multiply the matrix y anything, you get the matrix, not the identity

More information

A DARK GREY P O N T, with a Switch Tail, and a small Star on the Forehead. Any

A DARK GREY P O N T, with a Switch Tail, and a small Star on the Forehead. Any Y Y Y X X «/ YY Y Y ««Y x ) & \ & & } # Y \#$& / Y Y X» \\ / X X X x & Y Y X «q «z \x» = q Y # % \ & [ & Z \ & { + % ) / / «q zy» / & / / / & x x X / % % ) Y x X Y $ Z % Y Y x x } / % «] «] # z» & Y X»

More information

P = ρ{ g a } + µ 2 V II. FLUID STATICS

P = ρ{ g a } + µ 2 V II. FLUID STATICS II. FLUID STATICS From a force analysis on a triangular fluid element at rest, the following three concepts are easily developed: For a continuous, hydrostatic, shear free fluid: 1. Pressure is constant

More information

Research Article Relative Status Determination for Spacecraft Relative Motion Based on Dual Quaternion

Research Article Relative Status Determination for Spacecraft Relative Motion Based on Dual Quaternion Mathematical Prolems in Engineering Volume 214, Article ID 62724, 7 pages http://dx.doi.org/1.1155/214/62724 Research Article Relative Status Determination for Spacecraft Relative Motion Based on Dual

More information

Chapter 2 Canonical Correlation Analysis

Chapter 2 Canonical Correlation Analysis Chapter 2 Canonical Correlation Analysis Canonical correlation analysis CCA, which is a multivariate analysis method, tries to quantify the amount of linear relationships etween two sets of random variales,

More information

Matrices and Vectors

Matrices and Vectors Matrices and Vectors James K. Peterson Department of Biological Sciences and Department of Mathematical Sciences Clemson University November 11, 2013 Outline 1 Matrices and Vectors 2 Vector Details 3 Matrix

More information

1Number ONLINE PAGE PROOFS. systems: real and complex. 1.1 Kick off with CAS

1Number ONLINE PAGE PROOFS. systems: real and complex. 1.1 Kick off with CAS 1Numer systems: real and complex 1.1 Kick off with CAS 1. Review of set notation 1.3 Properties of surds 1. The set of complex numers 1.5 Multiplication and division of complex numers 1.6 Representing

More information

Classical Mechanics. Luis Anchordoqui

Classical Mechanics. Luis Anchordoqui 1 Rigid Body Motion Inertia Tensor Rotational Kinetic Energy Principal Axes of Rotation Steiner s Theorem Euler s Equations for a Rigid Body Eulerian Angles Review of Fundamental Equations 2 Rigid body

More information

Representation theory of SU(2), density operators, purification Michael Walter, University of Amsterdam

Representation theory of SU(2), density operators, purification Michael Walter, University of Amsterdam Symmetry and Quantum Information Feruary 6, 018 Representation theory of S(), density operators, purification Lecture 7 Michael Walter, niversity of Amsterdam Last week, we learned the asic concepts of

More information

Dynamics. 1 Copyright c 2015 Roderic Grupen

Dynamics. 1 Copyright c 2015 Roderic Grupen Dynamics The branch of physics that treats the action of force on bodies in motion or at rest; kinetics, kinematics, and statics, collectively. Websters dictionary Outline Conservation of Momentum Inertia

More information

(3.1) a 2nd-order vector differential equation, as the two 1st-order vector differential equations (3.3)

(3.1) a 2nd-order vector differential equation, as the two 1st-order vector differential equations (3.3) Chapter 3 Kinematics As noted in the Introduction, the study of dynamics can be decomposed into the study of kinematics and kinetics. For the translational motion of a particle of mass m, this decomposition

More information

Chapter 2 Math Fundamentals

Chapter 2 Math Fundamentals Chapter 2 Math Fundamentals Part 1 2.1 Conventions and Definitions 2.2 Matrices 2.3 Fundamentals of Rigid Transforms 1 Outline 2.1 Conventions and Definitions 2.2 Matrices 2.3 Fundamentals of Rigid Transforms

More information

School of Business. Blank Page

School of Business. Blank Page Equations 5 The aim of this unit is to equip the learners with the concept of equations. The principal foci of this unit are degree of an equation, inequalities, quadratic equations, simultaneous linear

More information

Expansion formula using properties of dot product (analogous to FOIL in algebra): u v 2 u v u v u u 2u v v v u 2 2u v v 2

Expansion formula using properties of dot product (analogous to FOIL in algebra): u v 2 u v u v u u 2u v v v u 2 2u v v 2 Least squares: Mathematical theory Below we provide the "vector space" formulation, and solution, of the least squares prolem. While not strictly necessary until we ring in the machinery of matrix algera,

More information

Vectors and Matrices

Vectors and Matrices Chapter Vectors and Matrices. Introduction Vectors and matrices are used extensively throughout this text. Both are essential as one cannot derive and analyze laws of physics and physical measurements

More information

Matrices. Chapter What is a Matrix? We review the basic matrix operations. An array of numbers a a 1n A = a m1...

Matrices. Chapter What is a Matrix? We review the basic matrix operations. An array of numbers a a 1n A = a m1... Chapter Matrices We review the basic matrix operations What is a Matrix? An array of numbers a a n A = a m a mn with m rows and n columns is a m n matrix Element a ij in located in position (i, j The elements

More information

We are already familiar with the concept of a scalar and vector. are unit vectors in the x and y directions respectively with

We are already familiar with the concept of a scalar and vector. are unit vectors in the x and y directions respectively with Math Review We are already familiar with the concept of a scalar and vector. Example: Position (x, y) in two dimensions 1 2 2 2 s ( x y ) where s is the length of x ( xy, ) xi yj And i, j ii 1 j j 1 i

More information

Rotational Motion. Chapter 4. P. J. Grandinetti. Sep. 1, Chem P. J. Grandinetti (Chem. 4300) Rotational Motion Sep.

Rotational Motion. Chapter 4. P. J. Grandinetti. Sep. 1, Chem P. J. Grandinetti (Chem. 4300) Rotational Motion Sep. Rotational Motion Chapter 4 P. J. Grandinetti Chem. 4300 Sep. 1, 2017 P. J. Grandinetti (Chem. 4300) Rotational Motion Sep. 1, 2017 1 / 76 Angular Momentum The angular momentum of a particle with respect

More information

QUADRATIC EQUATIONS EXPECTED BACKGROUND KNOWLEDGE

QUADRATIC EQUATIONS EXPECTED BACKGROUND KNOWLEDGE 6 QUADRATIC EQUATIONS In this lesson, you will study aout quadratic equations. You will learn to identify quadratic equations from a collection of given equations and write them in standard form. You will

More information

Section 8.5. z(t) = be ix(t). (8.5.1) Figure A pendulum. ż = ibẋe ix (8.5.2) (8.5.3) = ( bẋ 2 cos(x) bẍ sin(x)) + i( bẋ 2 sin(x) + bẍ cos(x)).

Section 8.5. z(t) = be ix(t). (8.5.1) Figure A pendulum. ż = ibẋe ix (8.5.2) (8.5.3) = ( bẋ 2 cos(x) bẍ sin(x)) + i( bẋ 2 sin(x) + bẍ cos(x)). Difference Equations to Differential Equations Section 8.5 Applications: Pendulums Mass-Spring Systems In this section we will investigate two applications of our work in Section 8.4. First, we will consider

More information

Mathematics Background

Mathematics Background UNIT OVERVIEW GOALS AND STANDARDS MATHEMATICS BACKGROUND UNIT INTRODUCTION Patterns of Change and Relationships The introduction to this Unit points out to students that throughout their study of Connected

More information

SNAP Centre Workshop. Exponents and Radicals

SNAP Centre Workshop. Exponents and Radicals SNAP Centre Workshop Exponents and Radicals 25 Introduction Exponents are used as a way of representing repeated multiplication. For instance, when we see 4 3, we know that it is equivalent to (4)(4)(4),

More information

Closed-Form Solution Of Absolute Orientation Using Unit Quaternions

Closed-Form Solution Of Absolute Orientation Using Unit Quaternions Closed-Form Solution Of Absolute Orientation Using Unit Berthold K. P. Horn Department of Computer and Information Sciences November 11, 2004 Outline 1 Introduction 2 3 The Problem Given: two sets of corresponding

More information

Ridig Body Motion Homogeneous Transformations

Ridig Body Motion Homogeneous Transformations Ridig Body Motion Homogeneous Transformations Claudio Melchiorri Dipartimento di Elettronica, Informatica e Sistemistica (DEIS) Università di Bologna email: claudio.melchiorri@unibo.it C. Melchiorri (DEIS)

More information

Translational and Rotational Dynamics!

Translational and Rotational Dynamics! Translational and Rotational Dynamics Robert Stengel Robotics and Intelligent Systems MAE 345, Princeton University, 217 Copyright 217 by Robert Stengel. All rights reserved. For educational use only.

More information

10 Lorentz Group and Special Relativity

10 Lorentz Group and Special Relativity Physics 129 Lecture 16 Caltech, 02/27/18 Reference: Jones, Groups, Representations, and Physics, Chapter 10. 10 Lorentz Group and Special Relativity Special relativity says, physics laws should look the

More information

Topic 2: The mathematical formalism and the standard way of thin

Topic 2: The mathematical formalism and the standard way of thin The mathematical formalism and the standard way of thinking about it http://www.wuthrich.net/ MA Seminar: Philosophy of Physics Vectors and vector spaces Vectors and vector spaces Operators Albert, Quantum

More information

Introduction to quaternions

Introduction to quaternions . Introduction Introduction to uaternions Invented and developed by William Hamilton in 843, uaternions are essentially a generalization of complex numbers to four dimensions (one real dimension, three

More information

Artificial Intelligence & Neuro Cognitive Systems Fakultät für Informatik. Robot Dynamics. Dr.-Ing. John Nassour J.

Artificial Intelligence & Neuro Cognitive Systems Fakultät für Informatik. Robot Dynamics. Dr.-Ing. John Nassour J. Artificial Intelligence & Neuro Cognitive Systems Fakultät für Informatik Robot Dynamics Dr.-Ing. John Nassour 25.1.218 J.Nassour 1 Introduction Dynamics concerns the motion of bodies Includes Kinematics

More information

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

Transformation Matrices; Geometric and Otherwise As examples, consider the transformation matrices of the C 3v Transformation Matrices; Geometric and Otherwise As examples, consider the transformation matrices of the v group. The form of these matrices depends on the basis we choose. Examples: Cartesian vectors:

More information

Vectors and Matrices Statistics with Vectors and Matrices

Vectors and Matrices Statistics with Vectors and Matrices Vectors and Matrices Statistics with Vectors and Matrices Lecture 3 September 7, 005 Analysis Lecture #3-9/7/005 Slide 1 of 55 Today s Lecture Vectors and Matrices (Supplement A - augmented with SAS proc

More information

Three-Dimensional Coordinate Systems. Three-Dimensional Coordinate Systems. Three-Dimensional Coordinate Systems. Three-Dimensional Coordinate Systems

Three-Dimensional Coordinate Systems. Three-Dimensional Coordinate Systems. Three-Dimensional Coordinate Systems. Three-Dimensional Coordinate Systems To locate a point in a plane, two numbers are necessary. We know that any point in the plane can be represented as an ordered pair (a, b) of real numbers, where a is the x-coordinate and b is the y-coordinate.

More information

Rotational & Rigid-Body Mechanics. Lectures 3+4

Rotational & Rigid-Body Mechanics. Lectures 3+4 Rotational & Rigid-Body Mechanics Lectures 3+4 Rotational Motion So far: point objects moving through a trajectory. Next: moving actual dimensional objects and rotating them. 2 Circular Motion - Definitions

More information

The Mean Version One way to write the One True Regression Line is: Equation 1 - The One True Line

The Mean Version One way to write the One True Regression Line is: Equation 1 - The One True Line Chapter 27: Inferences for Regression And so, there is one more thing which might vary one more thing aout which we might want to make some inference: the slope of the least squares regression line. The

More information

COMP 175 COMPUTER GRAPHICS. Lecture 04: Transform 1. COMP 175: Computer Graphics February 9, Erik Anderson 04 Transform 1

COMP 175 COMPUTER GRAPHICS. Lecture 04: Transform 1. COMP 175: Computer Graphics February 9, Erik Anderson 04 Transform 1 Lecture 04: Transform COMP 75: Computer Graphics February 9, 206 /59 Admin Sign up via email/piazza for your in-person grading Anderson@cs.tufts.edu 2/59 Geometric Transform Apply transforms to a hierarchy

More information

Vector calculus background

Vector calculus background Vector calculus background Jiří Lebl January 18, 2017 This class is really the vector calculus that you haven t really gotten to in Calc III. Let us start with a very quick review of the concepts from

More information

Differential Geometry of Surfaces

Differential Geometry of Surfaces Differential Geometry of urfaces Jordan mith and Carlo équin C Diision, UC Berkeley Introduction These are notes on differential geometry of surfaces ased on reading Greiner et al. n. d.. Differential

More information

Contravariant and Covariant as Transforms

Contravariant and Covariant as Transforms Contravariant and Covariant as Transforms There is a lot more behind the concepts of contravariant and covariant tensors (of any rank) than the fact that their basis vectors are mutually orthogonal to

More information

FeynCalc Tutorial 1 (Dated: September 8, 2015)

FeynCalc Tutorial 1 (Dated: September 8, 2015) FeynCalc Tutorial 1 (Dated: Septemer 8, 2015) In this tutorial, we will learn to use Mathematica and FeynCalc to contract Lorentz indices. After some practice to get familiar with FeynCalc, we will do

More information

EXERCISES ON DETERMINANTS, EIGENVALUES AND EIGENVECTORS. 1. Determinants

EXERCISES ON DETERMINANTS, EIGENVALUES AND EIGENVECTORS. 1. Determinants EXERCISES ON DETERMINANTS, EIGENVALUES AND EIGENVECTORS. Determinants Ex... Let A = 0 4 4 2 0 and B = 0 3 0. (a) Compute 0 0 0 0 A. (b) Compute det(2a 2 B), det(4a + B), det(2(a 3 B 2 )). 0 t Ex..2. For

More information

Math 216 Second Midterm 28 March, 2013

Math 216 Second Midterm 28 March, 2013 Math 26 Second Midterm 28 March, 23 This sample exam is provided to serve as one component of your studying for this exam in this course. Please note that it is not guaranteed to cover the material that

More information

MAE 323: Lecture 1. Review

MAE 323: Lecture 1. Review This review is divided into two parts. The first part is a mini-review of statics and solid mechanics. The second part is a review of matrix/vector fundamentals. The first part is given as an refresher

More information

Rigid Body Motion. Greg Hager Simon Leonard

Rigid Body Motion. Greg Hager Simon Leonard Rigid ody Motion Greg Hager Simon Leonard Overview Different spaces used in robotics and why we need to get from one space to the other Focus on Cartesian space Transformation between two Cartesian coordinate

More information

PHYS 705: Classical Mechanics. Rigid Body Motion Introduction + Math Review

PHYS 705: Classical Mechanics. Rigid Body Motion Introduction + Math Review 1 PHYS 705: Classical Mechanics Rigid Body Motion Introduction + Math Review 2 How to describe a rigid body? Rigid Body - a system of point particles fixed in space i r ij j subject to a holonomic constraint:

More information

Section 2.1: Reduce Rational Expressions

Section 2.1: Reduce Rational Expressions CHAPTER Section.: Reduce Rational Expressions Section.: Reduce Rational Expressions Ojective: Reduce rational expressions y dividing out common factors. A rational expression is a quotient of polynomials.

More information

03 - Basic Linear Algebra and 2D Transformations

03 - Basic Linear Algebra and 2D Transformations 03 - Basic Linear Algebra and 2D Transformations (invited lecture by Dr. Marcel Campen) Overview In this box, you will find references to Eigen We will briefly overview the basic linear algebra concepts

More information

GG303 Lecture 6 8/27/09 1 SCALARS, VECTORS, AND TENSORS

GG303 Lecture 6 8/27/09 1 SCALARS, VECTORS, AND TENSORS GG303 Lecture 6 8/27/09 1 SCALARS, VECTORS, AND TENSORS I Main Topics A Why deal with tensors? B Order of scalars, vectors, and tensors C Linear transformation of scalars and vectors (and tensors) II Why

More information

The Matrix Algebra of Sample Statistics

The Matrix Algebra of Sample Statistics The Matrix Algebra of Sample Statistics James H. Steiger Department of Psychology and Human Development Vanderbilt University James H. Steiger (Vanderbilt University) The Matrix Algebra of Sample Statistics

More information

7. FORCE ANALYSIS. Fundamentals F C

7. FORCE ANALYSIS. Fundamentals F C ME 352 ORE NLYSIS 7. ORE NLYSIS his chapter discusses some of the methodologies used to perform force analysis on mechanisms. he chapter begins with a review of some fundamentals of force analysis using

More information

The Jacobian. Jesse van den Kieboom

The Jacobian. Jesse van den Kieboom The Jacobian Jesse van den Kieboom jesse.vandenkieboom@epfl.ch 1 Introduction 1 1 Introduction The Jacobian is an important concept in robotics. Although the general concept of the Jacobian in robotics

More information

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

Why Transforms? Want to animate objects and camera Translations Rotations Shears And more.. Want to be able to use projection transforms Why Transforms? Want to animate objects and camera Translations Rotations Shears And more.. Want to be able to use projection transforms ITCS 3050:Game Engine Programming 1 Geometric Transformations Implementing

More information

ENGINEERING COMPUTATION Second Year Lectures. Stephen Roberts Michaelmas Term

ENGINEERING COMPUTATION Second Year Lectures. Stephen Roberts Michaelmas Term ENGINEERING COMPUTATION Second Year Lectures Stephen Roerts Michaelmas Term Engineering Computation ENGINEERING COMPUTATION Second Year Lectures Stephen Roerts Michaelmas Term The handouts are rief lecture

More information

Polynomial Degree and Finite Differences

Polynomial Degree and Finite Differences CONDENSED LESSON 7.1 Polynomial Degree and Finite Differences In this lesson, you Learn the terminology associated with polynomials Use the finite differences method to determine the degree of a polynomial

More information

Lecture 1.2 Pose in 2D and 3D. Thomas Opsahl

Lecture 1.2 Pose in 2D and 3D. Thomas Opsahl Lecture 1.2 Pose in 2D and 3D Thomas Osahl Motivation For the inhole camera, the corresondence between observed 3D oints in the world and 2D oints in the catured image is given by straight lines through

More information

Chapter 2 Math Fundamentals

Chapter 2 Math Fundamentals Chapter 2 Math Fundamentals Part 5 2.8 Quaternions 1 Outline 2.8.1 Representations and Notation 2.7.2 Quaternion Multiplication 2.7.3 Other Quaternion Operations 2.7.4 Representing 3D Rotations 2.7.5 Attitude

More information

Kinematics of a UR5. Rasmus Skovgaard Andersen Aalborg University

Kinematics of a UR5. Rasmus Skovgaard Andersen Aalborg University Kinematics of a UR5 May 3, 28 Rasmus Skovgaard Andersen Aalborg University Contents Introduction.................................... Notation.................................. 2 Forward Kinematics for

More information

Getting Started with Communications Engineering. Rows first, columns second. Remember that. R then C. 1

Getting Started with Communications Engineering. Rows first, columns second. Remember that. R then C. 1 1 Rows first, columns second. Remember that. R then C. 1 A matrix is a set of real or complex numbers arranged in a rectangular array. They can be any size and shape (provided they are rectangular). A

More information

Introduction and Vectors Lecture 1

Introduction and Vectors Lecture 1 1 Introduction Introduction and Vectors Lecture 1 This is a course on classical Electromagnetism. It is the foundation for more advanced courses in modern physics. All physics of the modern era, from quantum

More information

Applications of Eigenvalues & Eigenvectors

Applications of Eigenvalues & Eigenvectors Applications of Eigenvalues & Eigenvectors Louie L. Yaw Walla Walla University Engineering Department For Linear Algebra Class November 17, 214 Outline 1 The eigenvalue/eigenvector problem 2 Principal

More information

MATH 583A REVIEW SESSION #1

MATH 583A REVIEW SESSION #1 MATH 583A REVIEW SESSION #1 BOJAN DURICKOVIC 1. Vector Spaces Very quick review of the basic linear algebra concepts (see any linear algebra textbook): (finite dimensional) vector space (or linear space),

More information

Quaternions. R. J. Renka 11/09/2015. Department of Computer Science & Engineering University of North Texas. R. J.

Quaternions. R. J. Renka 11/09/2015. Department of Computer Science & Engineering University of North Texas. R. J. Quaternions R. J. Renka Department of Computer Science & Engineering University of North Texas 11/09/2015 Definition A quaternion is an element of R 4 with three operations: addition, scalar multiplication,

More information

Number Plane Graphs and Coordinate Geometry

Number Plane Graphs and Coordinate Geometry Numer Plane Graphs and Coordinate Geometr Now this is m kind of paraola! Chapter Contents :0 The paraola PS, PS, PS Investigation: The graphs of paraolas :0 Paraolas of the form = a + + c PS Fun Spot:

More information

8 Velocity Kinematics

8 Velocity Kinematics 8 Velocity Kinematics Velocity analysis of a robot is divided into forward and inverse velocity kinematics. Having the time rate of joint variables and determination of the Cartesian velocity of end-effector

More information

Simplified Analytical Model of a Six-Degree-of-Freedom Large-Gap Magnetic Suspension System

Simplified Analytical Model of a Six-Degree-of-Freedom Large-Gap Magnetic Suspension System NASA Technical Memorandum 112868 Simplified Analytical Model of a Six-Degree-of-Freedom Large-Gap Magnetic Suspension System Nelson J. Groom Langley Research Center, Hampton, Virginia June 1997 National

More information

Part 8: Rigid Body Dynamics

Part 8: Rigid Body Dynamics Document that contains homework problems. Comment out the solutions when printing off for students. Part 8: Rigid Body Dynamics Problem 1. Inertia review Find the moment of inertia for a thin uniform rod

More information

A VERY BRIEF LINEAR ALGEBRA REVIEW for MAP 5485 Introduction to Mathematical Biophysics Fall 2010

A VERY BRIEF LINEAR ALGEBRA REVIEW for MAP 5485 Introduction to Mathematical Biophysics Fall 2010 A VERY BRIEF LINEAR ALGEBRA REVIEW for MAP 5485 Introduction to Mathematical Biophysics Fall 00 Introduction Linear Algebra, also known as matrix theory, is an important element of all branches of mathematics

More information

In this section of notes, we look at the calculation of forces and torques for a manipulator in two settings:

In this section of notes, we look at the calculation of forces and torques for a manipulator in two settings: Introduction Up to this point we have considered only the kinematics of a manipulator. That is, only the specification of motion without regard to the forces and torques required to cause motion In this

More information

6. 3D Kinematics DE2-EA 2.1: M4DE. Dr Connor Myant

6. 3D Kinematics DE2-EA 2.1: M4DE. Dr Connor Myant DE2-EA 2.1: M4DE Dr Connor Myant 6. 3D Kinematics Comments and corrections to connor.myant@imperial.ac.uk Lecture resources may be found on Blackboard and at http://connormyant.com Contents Three-Dimensional

More information

3.5 Solving Quadratic Equations by the

3.5 Solving Quadratic Equations by the www.ck1.org Chapter 3. Quadratic Equations and Quadratic Functions 3.5 Solving Quadratic Equations y the Quadratic Formula Learning ojectives Solve quadratic equations using the quadratic formula. Identify

More information

Linear Algebra & Geometry why is linear algebra useful in computer vision?

Linear Algebra & Geometry why is linear algebra useful in computer vision? Linear Algebra & Geometry why is linear algebra useful in computer vision? References: -Any book on linear algebra! -[HZ] chapters 2, 4 Some of the slides in this lecture are courtesy to Prof. Octavia

More information

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

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

More information

Chapter 2. Vectors and Vector Spaces

Chapter 2. Vectors and Vector Spaces 2.2. Cartesian Coordinates and Geometrical Properties of Vectors 1 Chapter 2. Vectors and Vector Spaces Section 2.2. Cartesian Coordinates and Geometrical Properties of Vectors Note. There is a natural

More information

AB-267 DYNAMICS & CONTROL OF FLEXIBLE AIRCRAFT

AB-267 DYNAMICS & CONTROL OF FLEXIBLE AIRCRAFT FLÁIO SILESTRE DYNAMICS & CONTROL OF FLEXIBLE AIRCRAFT LECTURE NOTES LAGRANGIAN MECHANICS APPLIED TO RIGID-BODY DYNAMICS IMAGE CREDITS: BOEING FLÁIO SILESTRE Introduction Lagrangian Mechanics shall be

More information

Essential Maths 1. Macquarie University MAFC_Essential_Maths Page 1 of These notes were prepared by Anne Cooper and Catriona March.

Essential Maths 1. Macquarie University MAFC_Essential_Maths Page 1 of These notes were prepared by Anne Cooper and Catriona March. Essential Maths 1 The information in this document is the minimum assumed knowledge for students undertaking the Macquarie University Masters of Applied Finance, Graduate Diploma of Applied Finance, and

More information

Singularity-Free Dynamic Equations of Spacecraft-Manipulator Systems

Singularity-Free Dynamic Equations of Spacecraft-Manipulator Systems Singularity-Free Dynamic Equations of Spacecraft-Manipulator Systems Pål J. From Kristin Y. Pettersen Jan T. Gravdahl Engineering Cyernetics, Norwegian University of Science & Technology, Norway Astract:

More information

Course MA2C02, Hilary Term 2010 Section 4: Vectors and Quaternions

Course MA2C02, Hilary Term 2010 Section 4: Vectors and Quaternions Course MA2C02, Hilary Term 2010 Section 4: Vectors and Quaternions David R. Wilkins Copyright c David R. Wilkins 2000 2010 Contents 4 Vectors and Quaternions 47 4.1 Vectors...............................

More information

Lagrangian Dynamics of Open Multibody Systems with Generalized Holonomic and Nonholonomic Joints

Lagrangian Dynamics of Open Multibody Systems with Generalized Holonomic and Nonholonomic Joints Proceedings of the 2007 IEEE/RSJ International Conference on Intelligent Roots and Systems San Diego, CA, USA, Oct 29 - Nov 2, 2007 ThB6.4 Lagrangian Dynamics of Open Multiody Systems with Generalized

More information

Non-Linear Regression Samuel L. Baker

Non-Linear Regression Samuel L. Baker NON-LINEAR REGRESSION 1 Non-Linear Regression 2006-2008 Samuel L. Baker The linear least squares method that you have een using fits a straight line or a flat plane to a unch of data points. Sometimes

More information

2.003J Spring 2011: Dynamics and Control I On Notation Massachusetts Institute of Technology Department of Mechanical Engineering Feb.

2.003J Spring 2011: Dynamics and Control I On Notation Massachusetts Institute of Technology Department of Mechanical Engineering Feb. 2.J Spring 211: Dynamics and Control I On Notation Department of Mechanical Engineering Feb. 8, 211 On Notation Much of 2.j involves defining then manipulating points, frames of reference, and vectors.

More information

A Symbolic Vector/Dyadic Multibody Formalism For Tree- Topology Systems

A Symbolic Vector/Dyadic Multibody Formalism For Tree- Topology Systems A Symbolic Vector/Dyadic Multibody Formalism For Tree- Topology Systems Michael W. Sayers * The University of Michigan Transportation Research Institute Abstract A multibody formalism is presented that

More information

Linear Algebra March 16, 2019

Linear Algebra March 16, 2019 Linear Algebra March 16, 2019 2 Contents 0.1 Notation................................ 4 1 Systems of linear equations, and matrices 5 1.1 Systems of linear equations..................... 5 1.2 Augmented

More information

REFRESHER. William Stallings

REFRESHER. William Stallings BASIC MATH REFRESHER William Stallings Trigonometric Identities...2 Logarithms and Exponentials...4 Log Scales...5 Vectors, Matrices, and Determinants...7 Arithmetic...7 Determinants...8 Inverse of a Matrix...9

More information

Orthogonality. 6.1 Orthogonal Vectors and Subspaces. Chapter 6

Orthogonality. 6.1 Orthogonal Vectors and Subspaces. Chapter 6 Chapter 6 Orthogonality 6.1 Orthogonal Vectors and Subspaces Recall that if nonzero vectors x, y R n are linearly independent then the subspace of all vectors αx + βy, α, β R (the space spanned by x and

More information

STEP Support Programme. STEP 2 Matrices Topic Notes

STEP Support Programme. STEP 2 Matrices Topic Notes STEP Support Programme STEP 2 Matrices Topic Notes Definitions............................................. 2 Manipulating Matrices...................................... 3 Transformations.........................................

More information