Kinematics of Robots. Alba Perez Gracia



Similar documents
Lecture L3 - Vectors, Matrices and Coordinate Transformations

3D Tranformations. CS 4620 Lecture 6. Cornell CS4620 Fall 2013 Lecture Steve Marschner (with previous instructors James/Bala)

Lecture 7. Matthew T. Mason. Mechanics of Manipulation. Lecture 7. Representing Rotation. Kinematic representation: goals, overview

Metrics on SO(3) and Inverse Kinematics

Mechanics lecture 7 Moment of a force, torque, equilibrium of a body

ME 115(b): Solution to Homework #1

THREE DIMENSIONAL GEOMETRY

13.4 THE CROSS PRODUCT

Section 1.1. Introduction to R n

Lecture 14: Section 3.3

Linear algebra and the geometry of quadratic equations. Similarity transformations and orthogonal matrices

Linear Algebra Notes for Marsden and Tromba Vector Calculus

Chapter 17. Orthogonal Matrices and Symmetries of Space

Chapter 6. Orthogonality

9 Multiplication of Vectors: The Scalar or Dot Product

Recall the basic property of the transpose (for any A): v A t Aw = v w, v, w R n.

Geometric Transformations

Physics 235 Chapter 1. Chapter 1 Matrices, Vectors, and Vector Calculus

discuss how to describe points, lines and planes in 3 space.

Mathematics Course 111: Algebra I Part IV: Vector Spaces

1.3. DOT PRODUCT If θ is the angle (between 0 and π) between two non-zero vectors u and v,

On Motion of Robot End-Effector using the Curvature Theory of Timelike Ruled Surfaces with Timelike Directrix

Cross product and determinants (Sect. 12.4) Two main ways to introduce the cross product

A vector is a directed line segment used to represent a vector quantity.

Vector Algebra II: Scalar and Vector Products

Solving Simultaneous Equations and Matrices

13 MATH FACTS a = The elements of a vector have a graphical interpretation, which is particularly easy to see in two or three dimensions.

Vectors 2. The METRIC Project, Imperial College. Imperial College of Science Technology and Medicine, 1996.

α = u v. In other words, Orthogonal Projection

Essential Mathematics for Computer Graphics fast

Rotation Matrices and Homogeneous Transformations

11.1. Objectives. Component Form of a Vector. Component Form of a Vector. Component Form of a Vector. Vectors and the Geometry of Space

3. INNER PRODUCT SPACES

Lectures notes on orthogonal matrices (with exercises) Linear Algebra II - Spring 2004 by D. Klain

ISOMETRIES OF R n KEITH CONRAD

THEORETICAL MECHANICS

Unified Lecture # 4 Vectors

Eigenvalues and Eigenvectors

A PAIR OF MEASURES OF ROTATIONAL ERROR FOR AXISYMMETRIC ROBOT END-EFFECTORS

1 VECTOR SPACES AND SUBSPACES

Mathematics Notes for Class 12 chapter 10. Vector Algebra

28 CHAPTER 1. VECTORS AND THE GEOMETRY OF SPACE. v x. u y v z u z v y u y u z. v y v z

State of Stress at Point

December 4, 2013 MATH 171 BASIC LINEAR ALGEBRA B. KITCHENS

Figure 1.1 Vector A and Vector F

[1] Diagonal factorization

521493S Computer Graphics. Exercise 2 & course schedule change

is in plane V. However, it may be more convenient to introduce a plane coordinate system in V.

Kyu-Jung Kim Mechanical Engineering Department, California State Polytechnic University, Pomona, U.S.A.

Projective Geometry: A Short Introduction. Lecture Notes Edmond Boyer

Some Comments on the Derivative of a Vector with applications to angular momentum and curvature. E. L. Lady (October 18, 2000)

Vector has a magnitude and a direction. Scalar has a magnitude

Constraint satisfaction and global optimization in robotics

Linear Algebra Done Wrong. Sergei Treil. Department of Mathematics, Brown University

The Matrix Elements of a 3 3 Orthogonal Matrix Revisited

LINEAR ALGEBRA W W L CHEN

Design-Simulation-Optimization Package for a Generic 6-DOF Manipulator with a Spherical Wrist

Similarity and Diagonalization. Similar Matrices

Dot product and vector projections (Sect. 12.3) There are two main ways to introduce the dot product

Principal Rotation Representations of Proper NxN Orthogonal Matrices

Equations Involving Lines and Planes Standard equations for lines in space

Geometric Transformation CS 211A

Linear Algebra: Vectors

Lecture L22-2D Rigid Body Dynamics: Work and Energy

Continuous Groups, Lie Groups, and Lie Algebras

x1 x 2 x 3 y 1 y 2 y 3 x 1 y 2 x 2 y 1 0.

Adding vectors We can do arithmetic with vectors. We ll start with vector addition and related operations. Suppose you have two vectors

Origins of the Unusual Space Shuttle Quaternion Definition

Problem Set 5 Due: In class Thursday, Oct. 18 Late papers will be accepted until 1:00 PM Friday.

Content. Chapter 4 Functions Basic concepts on real functions 62. Credits 11

MAT 1341: REVIEW II SANGHOON BAEK

Recall that two vectors in are perpendicular or orthogonal provided that their dot

Linear Algebra Done Wrong. Sergei Treil. Department of Mathematics, Brown University

Geometry of Vectors. 1 Cartesian Coordinates. Carlo Tomasi

Nonlinear Iterative Partial Least Squares Method

Grassmann Algebra in Game Development. Eric Lengyel, PhD Terathon Software

Solving Systems of Linear Equations

Notes on Orthogonal and Symmetric Matrices MENU, Winter 2013

Factoring Patterns in the Gaussian Plane

NEW YORK STATE TEACHER CERTIFICATION EXAMINATIONS

Linear Algebra Review. Vectors

Notes on the representational possibilities of projective quadrics in four dimensions

Orthogonal Projections

B4 Computational Geometry

Mechanics 1: Vectors

Orbital Mechanics. Angular Momentum

Lecture 3: Coordinate Systems and Transformations

Orthogonal Projections and Orthonormal Bases

by the matrix A results in a vector which is a reflection of the given

3. KINEMATICS IN TWO DIMENSIONS; VECTORS.

Math for Game Programmers: Dual Numbers. Gino van den Bergen

Numerical Analysis Lecture Notes

Rotation Rate of a Trajectory of an Algebraic Vector Field Around an Algebraic Curve

South Carolina College- and Career-Ready (SCCCR) Pre-Calculus

1 Sets and Set Notation.

Continued Fractions and the Euclidean Algorithm

Math 241, Exam 1 Information.

Inner Product Spaces and Orthogonality

Geometric Algebra Primer. Jaap Suter

ASEN Structures. MDOF Dynamic Systems. ASEN 3112 Lecture 1 Slide 1

Transcription:

Kinematics of Robots Alba Perez Gracia c Draft date August 31, 2007

Contents Contents i 1 Motion: An Introduction 3 1.1 Overview.......................................... 3 1.2 Introduction......................................... 3 1.3 The finite displacement.................................. 4 1.3.1 Translations..................................... 5 1.3.2 Rotations...................................... 6 1.3.3 General finite displacements............................ 10 1.3.4 The invariants of a general displacement..................... 11 1.4 A little bit of line geometry................................ 12 1.4.1 Dual vector algebra................................ 13 1.4.2 More line geometry................................. 15 1.4.3 Line motion..................................... 15 1.4.4 Line Geometry and the Klein Quadric...................... 16 1.5 The screw axis of a general displacement and Chasles Theorem............ 16 1.6 More on Matrix Representation.............................. 19 1.6.1 How to create a rotation matrix......................... 19 1.6.2 Homogeneous matrix representation....................... 21 i

ii CONTENTS 2 Robot Kinematics Using Matrix Algebra 25 2.1 Overview.......................................... 25 2.2 Robot Kinematics..................................... 25 2.3 Basic joints......................................... 27 2.4 Forward Kinematics Equations.............................. 28 2.4.1 Denavit-Hartenberg parameters.......................... 28 2.4.2 Kinematics Equations............................... 30 2.5 Forward Kinematics Example............................... 31 2.6 Inverse Kinematics..................................... 32 2.7 Inverse Kinematics Example................................ 33 3 Group Theory and Motion 35 3.1 Overview.......................................... 35 3.2 Group Theory Review................................... 35 3.2.1 Subgroups...................................... 36 3.2.2 Automorphisms................................... 37 3.2.3 Products of Groups................................ 38 3.2.4 Cosets and Actions................................. 39 3.3 The group of finite displacements............................. 40 3.3.1 Subgroups of the Special Euclidean Group.................... 41 4 Lie Groups and Lie Algebras 43 4.1 Introduction......................................... 43 4.2 Lie groups.......................................... 43 4.3 One-parameter subgroups................................. 44 4.4 The Lie Algebra...................................... 45 4.4.1 The Lie bracket................................... 46

CONTENTS iii 4.4.2 Chasles Theorem again.............................. 48 4.5 The Lie algebra of the Special Euclidean Group SE(3)................. 48 4.5.1 Relative Rotations................................. 48 4.5.2 Relative general motion.............................. 49 4.5.3 Rigid body velocity................................ 50 4.6 Example........................................... 51 5 The Product of Exponentials for Serial Manipulators 53 5.1 Introduction......................................... 53 5.2 Forward Kinematics.................................... 53 5.3 Example: Epson E2L Scara Robot............................ 54 5.4 Velocity and Jacobian................................... 56 5.4.1 Example....................................... 57 5.5 Inverse and pseudoinverse Jacobian............................ 58 6 Grassmann Algebra 59 6.1 Overview.......................................... 59 6.2 Vector spaces and metric spaces.............................. 59 6.3 Algebras........................................... 61 6.4 Grassmann Algebra.................................... 61 6.4.1 Grassmann algebra associated to R 3....................... 62 6.4.2 Grassmann algebra associated to R 2....................... 65 6.4.3 Grassmann algebra associated to R 4....................... 65 6.4.4 The general Grassman algebra.......................... 66 6.5 More on Grassmann algebra................................ 68 7 Quaternions 71 7.1 Overview.......................................... 71

iv CONTENTS 7.2 Quaternions......................................... 71 7.3 Unit Quaternions and Rotations............................. 73 7.3.1 Rotation by a unit quaternion........................... 73 7.4 The Lie Algebra of Unit Quaternions........................... 75 7.4.1 Euler parameters revisited............................. 76 7.5 Applications......................................... 76 7.5.1 Satellite navigation................................. 76 7.5.2 Singularities in the Euler angles matrix representation............. 78 7.5.3 Trajectory planning and interpolation...................... 79 8 Clifford Algebras 81 8.1 Overview.......................................... 81 8.2 Clifford algebras and the Clifford product........................ 82 8.2.1 Properties of the geometric product....................... 83 8.2.2 Creating Clifford algebras............................. 83 8.3 The Even Clifford algebra of the three-dimensional space R 3.............. 83 8.4 The even Clifford algebra of the projective space P 3.................. 84 8.5 The Clifford algebra of dual quaternions......................... 86 8.5.1 Spatial displacements using unit dual quaternions............... 87 8.5.2 Examples...................................... 89 8.6 The geometry of the Clifford algebra C + (P 4, d)..................... 90 8.7 Lie algebra and Clifford algebra.............................. 91 8.8 Clifford Analysis...................................... 92 8.9 Other applications of Clifford algebras.......................... 94 9 Kinematic Synthesis 95 9.1 Overview.......................................... 95

CONTENTS v 9.2 4R Synthesis........................................ 95 Bibliography 73

vi CONTENTS

List of Figures 1.1 Description of the motion of a rigid body........................ 4 1.2 (a) A pure translation and (b) a pure rotation of a rigid body............. 5 1.3 A rigid displacement.................................... 6 1.4 Composition of displacements............................... 11 1.5 A relative displacement.................................. 12 1.6 A line defined using Plücker coordinates......................... 13 1.7 Dual vector geometry................................... 14 1.8 The screw axis, rotation angle and slide of a displacement............... 18 1.9 Euler angles......................................... 20 2.1 Reachable workspace, Adept Viper m650 robot (Adept Technologies, Inc.)...... 27 2.2 Common types of joints.................................. 28 2.3 Local transformations along the links of a robot..................... 29 2.4 Example: a three-jointed serial robot........................... 31 2.5 Welding Robot (Fanuc Robotics)............................. 34 2.5 Welding Robot (Fanuc Robotics)............................. 32 5.1 SCARA robot Epson E2L65................................ 54 6.1 H.G. Grassmann...................................... 62 6.2 The wedge product of two vectors............................ 64 vii

viii LIST OF FIGURES 7.1 Sir W.R. Hamilton..................................... 72 7.2 ECI coordinates....................................... 78 7.3 A spherical wrist...................................... 79 7.4 The Agile Eye........................................ 80 8.1 W. H. Clifford........................................ 82

List of Tables 2.1 Denavit-Hartenberg parameters.............................. 30 2.2 Denavit-Hartenberg parameters for the robot of Figure 2.4............... 31 3.1 Subgroups of the group of spatial displacements..................... 41 6.1 Basis multivectors for the Grassman algebra of R 3................... 65 6.2 Basis multivectors for the Grassman algebra of R 4................... 66 6.3 Basis multivectors for the Grassman algebra of R m................... 67 8.1 Matrix and Clifford algebra expressions for rotations and general displacements... 86 1

2 LIST OF TABLES

Chapter 1 Motion: An Introduction 1.1 Overview This notes are designed as a gentle introduction to the use of Clifford algebras in robot kinematics. In the process, other key concepts will be reviewed, concepts that Clifford algebras build upon. Basic group theory, linear spaces, Grassman spaces and Lie algebras, as well as line geometry and projective geometry, will be introduced. Each of these topics is accompanied by examples and applications of increasing difficulty. 1.2 Introduction Kinematics is defined as the study of the motion, regardless of the forces causing it and caused by it. Motion is a concept that includes position and its derivatives, mainly velocity and acceleration. The subjects that we study are modeled as rigid bodies. A rigid body is a set of particles such that the distance between them remains fixed. This means that, unlike individual particles, we can define not only location, velocity and acceleration of a particle in the body, but also orientation, angular velocity and angular acceleration of the body. Orientation is defined as a shortcut to avoid describing the motion of a set of particles in the body; for completely defining the position of a rigid body, we need to define the location of at least three particles on it, p 1, p 2 and p 3, that is 9 parameters. However, the three locations are not independent, because the distance between each two particles must remain constant; this adds three constraints to the set of nine parameters. Or we can define the location of one particle and the orientation of a frame attached to the body at that point, in which case we just need to define six parameters, given by d and [R] in Fig 1.1. The 3

4 CHAPTER 1. MOTION: AN INTRODUCTION concept of orientation is also well suited for algebraic operations. Figure 1.1: Description of the motion of a rigid body A transformation that preserves the distance between points is called an isometry and motion of rigid bodies is one of them. There is no meaning in describing a translation (a change in location) and a rotation (a change in orientation) at the level of an individual particle; particles undergo only translations. When the particles form a rigid body, we can characterize the translation because all the particles perform the same displacement, while during a rotation the particles of the rigid body move in different trajectories (still keeping the distance among them), and there is always a set of particles that do not move. To model the motion of a rigid body, we consider the whole space as moving attached to it; this allows us to use some results in group theory. Figure 1.2 shows a rigid body undergoing a translation and a rotation. In this chapter, we will become familiar with the basic concepts of motion and the most common tools to describe it. 1.3 The finite displacement The motion of a rigid body is modeled as the motion of a three-dimensional space. We attach a coordinate frame to the rigid body, in which the coordinates of points of the body remain fixed (Figure 1.3). Every point can be given coordinates with respect to a frame; we use right-handed orthogonal frames. In Figure 1.3, a point P has coordinates (X 1, X 2, X 3 ) when measured in frame {F } and

1.3. THE FINITE DISPLACEMENT 5 Figure 1.2: (a) A pure translation and (b) a pure rotation of a rigid body p = (x 1, x 2, x 3 ) with respect to frame {M}. A finite motion is called a displacement. A displacement can be either a translation, a rotation, or a combination of both. We will see how a general motion can always be seen as a composition of a rotation and a translation. A displacement is modeled as the change in the coordinates (in the fixed frame) of the points of the rigid body when it moves from the original location (when the fixed frame {F } and the moving frame {M} are coincident) to the final location in space. Equivalently, it can be seen as the change of coordinates from points expressed in the moving frame {M} to points expressed in the fixed frame {F }. 1.3.1 Translations During a translation, all points of the space move by the same amount in the same direction. If the direction and magnitude of translation is given by a non-unitary vector t as in Figure 1.2 (a), a point that had coordinates x in frame {F } before the translation, is transformed to a point of coordinates X = x + t (1.1) in the fixed frame {F } after the translation. Here, both points and vectors have coordinates in the three-dimensional space; however, they are different objects. The same vector t is used to transform any point of the space to the new

6 CHAPTER 1. MOTION: AN INTRODUCTION Figure 1.3: A rigid displacement coordinates after the translation. It is a free vector whose origin can be located anywhere in the 3-D space. Notice that translations are not linear transformations. If we denote the translation as g t (x) = x+t, g t (x + y) = x + y + t g t (x) + g t (y) = x + y + 2t (1.2) Let us now show that translations are isometries, that is, they keep the distance between points. Consider two points X and Y, X = x + t and Y = y + t, before and after a translation by a vector t. The distance between them is d 2 = (X Y) (X Y) = (x + t (y + t)) (x + t (y t)) = (x y) (x y). (1.3) Last, let us notice that translations do not have invariants, that is, do not leave any point fixed. For a point to be fixed by a translation g t, there must exist a point x such that g t (x) = x + t = x. But this is true only if t = 0, which is the zero translation and leaves all points in the space fixed. 1.3.2 Rotations During a rotation, a subspace of points (in the body or outside) can be found that remains fixed, while the rest of the points of the space move by different amounts and in different directions according to their location with respect to the fixed points. Because of the distance-preserving property of the rigid body, it is enough to define the change of direction along three independent directions to define a rotation.

1.3. THE FINITE DISPLACEMENT 7 Intuitively, we can consider two different entities associated to rigid bodies: directions and points. Directions are free vectors and hence translations have no effects on them; however, they can be transformed by rotations. On the other hand, points are transformed by translations and also by rotations. We attach a moving frame {M} to a point of the rigid body, see Figure 1.2 (b). The orientation of the body is defined as the coordinates of the three perpendicular vectors that form the moving frame, expressed in the fixed frame. The most common way of representing rotations is by using matrices. The matrix that contains the expression of the column vectors of the moving frame {x, y, z} expressed in the fixed frame, [R] = [ ] x y z, (1.4) defines the rotation from an initial position in which the fixed and moving frames were coincident, to the final position of the moving frame. At the same time, the matrix [R] defines also the change in coordinates from points of the body expressed in coordinates of the moving frame, to the expression of the same point in the fixed frame, see Figure 1.3. A point that had coordinates x (expressed in the fixed frame) before the rotation, is transformed to a point of coordinates X = [R]x (1.5) after the rotation. That is, if E i is the basis vector e i of the moving frame expressed in the fixed frame, ] 1 0 0 [R]x = [R](x 1 e 1 +x 2 e 2 +x 3 e 3 ) = [E 1 E 2 E 3 (x 1 0 +x 2 1 +x 3 0 ) = x 1E 1 +x 2 E 2 +x 3 E 3. 0 0 1 (1.6) Rotations are linear transformations. If we denote the transformation as r(x) = [R]x, r(x + y) = [R](x + y) = [R]x + [R]y = r(x) + r(y). (1.7) Because we are using orthonormal frames, the rotation matrix is an orthogonal matrix, that is, its columns are mutually orthogonal and unitary. This, together with the fact that we use right-handed frames, leads to the result: Proposition 1.3.1 A rotation matrix satisfies the following properties: [R][R] T = [R] T [R] = [I]

8 CHAPTER 1. MOTION: AN INTRODUCTION det[r] = +1 Proof: Exercise. Let us check now that rotations are isometries. Consider X = [R]x and Y = [R]y being two points transformed by the same rotation. The distance between them is (X Y) (X Y) =([R]x [R]y) ([R]x [R]y) = ([R](x y)) ([R](x y)) = ([R](x y)) T ([R](x y)) = (x y) T [R] T [R](x y) = (x y) (x y) (1.8) We can use our knowledge of matrix algebra to determine whether there are points that remain fixed during a rotation (they are called invariants) and how to find these points. Let us look at the eigenvalues of [R]. A scalar λ is an eigenvalue of a matrix [R] if [R]x = λx. To obtain some information about their values, we can compute the length of the eigenvector before and after the transformation. For doing that, we compute the dot product; if we transpose the above expression (taking into account that λ may be a complex number), and we multiply them together, we obtain x T [R] T [R]x = λλx T x, (1.9) and using the fact that [R] T [R] = [I] and λλ = λ 2, λ 2 = 1 (1.10) for all λ being an eigenvalue of the rotation matrix. This, together with the fact that det[r] = λ 1 λ 2 λ 3 = +1, leaves us with the following eigenvalues: Proposition 1.3.2 A three-dimensional rotation matrix has the following eigenvalues: λ 1 = 1 λ 2 = e iθ λ 3 = e iθ Proof: See the construction above. For a different construction involving the characteristic polynomial of the rotation matrix, see [10]. A fixed point will have the same coordinates before and after the transformation, that is, [R]x = x. (1.11) From here we have ([R] [I])x = 0. (1.12)

1.3. THE FINITE DISPLACEMENT 9 The obvious solution is x = 0, which tells us that the origin is an invariant. A possible subspace of fixed points exists if det([r] [I]) = 0. This is always true, as we know that one of the eigenvalues of [R] is λ 1 = 1. We will find not a point, but a whole direction of points being invariants. The only other possibility of fixed points is when the other two eigenvalues also become equal to 1; in that case we get the identity matrix. We know that the direction of fixed points includes the origin; it is called the rotation axis and it can be found using Cayley s formula. For the derivation of this formula we follow [11]. We start with the length-preserving property of rotations as seen in Eq.(1.9). We can express it as X X x x = 0. This is transformed to (X x) (X + x) = 0, (1.13) so that the addition and difference vectors are perpendicular. Notice that, if we express X = [R]x, we obtain the expression, X x = [R I][R + I] 1 (X + x). (1.14) We define the matrix [B] = [R I][R + I] 1. (1.15) By construction we have seen that applying [B] to a vector y makes it perpendicular. Hence, y T [B]y = 0. From this equation we can see that [B] is a skew-symmetric matrix, that is, [B] T = [B] and its elements are 0 b 3 b 2 [B] = b 3 0 b 1. (1.16) b 2 b 1 0 The only three different elements of the matrix can be assembled in the vector b = (b 1, b 2, b 3 ), and the matrix product with [B] can be substituted by the vector cross product, [B]y = b y. From Eq.(1.15) we can derive the expression of [R] as a function of [B], also known as Cayley s formula, When we substitute this expression in Eq.(1.11), we obtain [R] = [I B] 1 [I + B]. (1.17) [B]x = 0, (1.18) hence b x = 0, which means that b is a solution of the fixed point equation. The rotation axis is given by the direction of vector b. The set of invariant points that form the direction b defines the rotation axis and it is also called Rodrigues vector. It can also be shown that the length of this vector is b = tan φ 2, where φ is the rotation angle about the rotation axis. We usually write b = tan φ 2 s, where s is the unit direction, or rotation axis.

10 CHAPTER 1. MOTION: AN INTRODUCTION The following relation between the skew-symmetric matrix [B] and the rotation matrix [R] is also useful, [R I] = 2 1 + tan 2 φ 2 ([B] [B] T [B]). (1.19) 1.3.3 General finite displacements A general finite displacement can be always described as a composition of a translation and a rotation. In this context, composition means just the concatenation of two transformations, one realized after the other. We will formalize this within the context of group theory. We will write the general displacement g T as composed of a rotation by an orthogonal matrix [R] and a translation by a vector d, X = g T (x) = [R]x + d. (1.20) In this definition we are assuming that the translation is performed first, followed by the rotation, g T (x) = (g d g R )(x) = g d (g R (x)) = g d ([R]x) = [R]x + d. (1.21) It is easy to see that the properties of rotation matrices and translation vectors studied above hold for the general displacement, that is, a general displacement is an isometry, as both translation and rotation are isometries, but it is not linear due to the nonlinearity of the translation. We will study the invariants of a general displacement later; we are now going to derive some formulas that will be useful for us when dealing with displacements. Composition of displacements Let us derive the displacement that we obtain when we apply two successive displacements to a point. Let g T 1 transform the point X = [R 1 ]y + d 1 and g T 2 be such that y = [R 2 ]x + d 2, see Figure 1.4. We obtain that the total transformation is X = g T 3 (x) = g T 1 (y)g T 2 (x) = [R 1 ][R 2 ]x + ([R 1 ]d 2 + d 1 ) (1.22) Inverse displacement Given a displacement g T = ([R], d), we want now to calculate a displacement that, when composed with it, brings all the points of the space to their initial positions. For doing that, just consider the

1.3. THE FINITE DISPLACEMENT 11 Figure 1.4: Composition of displacements composition of displacements in Eq.(1.22) and solve for [R 2 ] and d 2 such that the resulting matrix is the identity and the resulting translation vector is zero. We obtain g T 1 = ([R] T, [R] T d) (1.23) Relative displacements A relative displacement expresses a displacement from an initial point to a final point, all measured in the fixed reference frame. Let x be a point expressed in the moving frame, and let g T 1 and g T 2 be two different displacements of this point with respect to a fixed frame. We want to calculate what is the displacement between the first and the second motion, relative to the fixed frame. That is, from the coordinates X 1 = g T 1 (x) and X 2 = g T 2 (x), we want to obtain the relative transformation X 2 = g T 12 (X 1 ) as shown in Figure 1.5. Substituting the value of x from the first equation in the second, we obtain and in general, the relative displacement is X 2 = g T 12 (X 1 ) = [R 2 ][R 1 ] T X 1 + (d 2 [R 2 ][R 1 ] T d 1 ), (1.24) X 2 = g T 12 (X 1 ) = (g T 2 g 1 T 1 )(X 1) (1.25) 1.3.4 The invariants of a general displacement We may be interested now in studying the invariants of a general displacement, that is, whether there is a point or set of points such that g T (x) = x. This gives the expression [R I]x = d, (1.26)

12 CHAPTER 1. MOTION: AN INTRODUCTION Figure 1.5: A relative displacement and knowing that λ = 1 is an eigenvalue of the rotation matrix and hence [R I] is singular, we can determine that there are no fixed points in a general displacement. However, there is a line which is an invariant of the displacement. In order to calculate this line, we need to study some line geometry. We will come back to this calculation after next section. 1.4 A little bit of line geometry This section is intended as an introduction to become familiar with line geometry. At this point, we are interested in having a good, useful definition of a line in space. Later on we may be interested in how to define planes, volumes, etc., and we will see that we can do it in a similar fashion. Lines are heavily used in spatial kinematics, and the reason was pointed out at the end of last section: for every displacement, we can find an invariant line. We find these invariant lines everywhere in mechanisms that perform motion; they usually define where the joints are located. A line has a direction and it has a location in space. The parameterized expression of a line uses a point c on the line, a direction vector s and a parameter t, describing the points belonging to the line as L : c + ts, t R (1.27) However, this description is not very good for algebraic operations. We want to determine distances between lines, angles between lines and so on. We use a description of a line called the Plücker coordinates. They define the line as two vectors, a direction vector and a moment vector, L = s + ɛs 0 = s + ɛc s, (1.28)

1.4. A LITTLE BIT OF LINE GEOMETRY 13 where s is a three-dimensional vector indicating the direction of the line and s 0 is also a threedimensional vector, called the moment of the line, and it is obtained by computing the cross product of any point c on the line times the direction s. The symbol ɛ is the dual unit and it is used to separate both vectors; it has the property that ɛ 2 = 0. It is important to remark that any point on the line gives the same moment vector s 0. Figure 1.6 shows the parameters that define a line. Figure 1.6: A line defined using Plücker coordinates In a more general context, an object of the form S = v + ɛw is known as a dual vector or a screw, and lines are particular cases of dual vectors, in which the following constraints hold: v = 1 and v w = 0. (1.29) Vector algebra extends naturally to dual vector algebra by operating component-wise and using the property of the dual unit. (We can similarly define dual numbers as pairs of scalars separated by the dual unit). 1.4.1 Dual vector algebra We can naturally extend to dual vectors the operations of three-dimensional vector algebra. Addition of dual vectors is performed component-wise. We can also extend both the dot product and the cross product of vectors. Let S 1 = v 1 + ɛw 1 and S 2 = v 2 + ɛw 2 be two dual vectors. The dual dot product is defined as: S 1 S 2 = v 1 v 2 + ɛ(v 1 w 2 + w 1 v 2 ), (1.30) where is the usual dot product. Similarly, we define the dual cross product of two dual vectors as S 1 S 2 = v 1 v 2 + ɛ(v 1 w 2 + w 1 v 2 ), (1.31)

14 CHAPTER 1. MOTION: AN INTRODUCTION where is the usual cross product of three-dimensional vectors. The dual dot and cross product have geometric meaning; it can be derived from the geometry of vector algebra. We are going to show this meaning for the case in which the dual vectors are lines. Figure 1.7: Dual vector geometry Let L 1 = s 1 + ɛc 1 s 1 and L 2 = s 2 + ɛc 2 s 2 be two lines arbitrarily located in space as shown in Figure 1.7. The dual number obtained as the dual dot product of the lines is L 1 L 2 = cos α ɛa sin α, (1.32) where α is the angle between the direction vectors s 1 and s 2 and a is the distance between the two lines along their common normal line. Similarly, the dual vector obtained by the cross product of the lines is L 1 L 2 = (sin α + ɛa cos α)n, (1.33) where N is the common normal line between L 1 and L 2. Exercise: Prove Eqs.(1.32,1.33). Use points c 1, c 2 as the intersection points of L 1, L 2 with the common normal line. What happens if the dual vectors L 1 and L 2 are not lines? Remember that the only conditions for a dual vector to be a line are given in Eq.(1.29). If the real part (the direction) of the dual vector is not unit, we can compute its length, which we will denote as m. If the dual part (the moment) is not perpendicular to the real part, we can always write it as a perpendicular component plus a component parallel to the direction. So finally we can express a general dual vector, also called a screw, as S = ms + ɛ(mc s + mks), (1.34) where the magnitude k along the real part is called the pitch of the screw.

1.4. A LITTLE BIT OF LINE GEOMETRY 15 1.4.2 More line geometry Sometimes we may be interested in computing a point in the line, given its Plücker coordinates. This can be done in general, for a screw S = v + ɛw, c = v w v v. (1.35) We can see how it works: take the general expression of a screw in Eq.(1.34), and let us compute the cross product of w = mc s + mks by v = ms, ms (mc s + mks) = m 2 s (c s) + m 2 ks s. (1.36) Now we apply the identity a (b c) = ba c ca b to obtain m 2 s (c s) = m 2 (c(s s) s(s c)) = m 2 c (1.37) if we consider c as the point perpendicular to the direction s - remember that we can take any point on the line. Notice also that m 2 is the dot product of the direction of the dual vector by itself. The fact that any point can be used to compute the moment of the line can be easily seen: imagine that c is the point on the line perpendicular to the direction, and consider now the point k = c + ts which has a component along the direction s. Compute the moment of the line using k, k s = (c + ts) s = c s + ts s = c s. (1.38) The component along the direction does not contribute to the moment. From all the information on this section we can define how to compute the common normal line, the line which is perpendicular to two given lines. Using Eq.(1.33), we obtain a screw which is perpendicular to both lines. In order to make it a line, Make the direction a unit vector, n. Find a point p in the screw as indicated above. Construct the common normal line as N = n + ɛp n. 1.4.3 Line motion A question that relates to our interests is, how do we specify the motion of a line? We need to be able to apply a displacement to a line and obtain the displaced line. One way is to use the rotation matrix to compute the change in orientation of the direction, and apply separately the displacement to a point on the line, assembling the Plücker coordinates of the line afterwards. We can also create a matrix that captures all these operations.

16 CHAPTER 1. MOTION: AN INTRODUCTION Let [R] be the rotation matrix and d = (d 1, d 2, d 3 ) the translation vector of a spatial displacement. We can create the dual orthogonal matrix [ ˆT ] as [ ˆT ] = [R] + ɛ[r] 0 = [R] + ɛ[d][r], (1.39) with 0 d 3 d 2 [D] = d 3 0 d 1 (1.40) d 2 d 1 0 which, as any skew-symmetric matrix, has the property [D]y = d y. We operate dual vectors and dual matrices distributing over the two components and applying the dual unit property ɛ 2 = 0, to get S + ɛc S = ([R] + ɛ[r] 0 )(s + ɛc s) = [R]s + ɛ ( ([R]c + d) [R]s ), (1.41) if we notice that [R](c s) = [R]c [R]s when [R] is an orthogonal matrix. 1.4.4 Line Geometry and the Klein Quadric Using Plücker coordinates, a line is defined as a dual vector, S = s + ɛs 0. However, the six coordinates of the line are not general: because the first vector is a direction, we can multiply by a constant and we obtain the same line. The line is hence an object of the projective space PR 5. In addition, we have the condition s s 0 = 0, which is a quadratic equation. The dual vectors that result form a four-dimensional quadric hypersurface in PR 5, called the Klein quadric. In this quadric, we need to discard the two-dimensional plane formed by the dual vectors such that s = 0, which are the lines at infinity. In summary, we have the bijection between lines in R 3 and the points of the four-dimensional Klein quadric minus the points on a two-dimensional plane, in the projective space PR 5. Because distance and angle between lines are preserved by rigid transformations, the Klein quadric is also preserved by them. 1.5 The screw axis of a general displacement and Chasles Theorem We now go back to finding the invariants of a general displacement. Based on Eq.(1.26), we decided that there are no fixed points. We know that for every rotation there is a fixed direction, called the rotation axis. Is there any other entity that remains fixed by the action of a general displacement? The answer is yes, there is an invariant line, called the screw axis of the displacement.

1.5. THE SCREW AXIS OF A GENERAL DISPLACEMENT AND CHASLES THEOREM 17 To find this line, let us apply a general displacement to a line, using the dual orthogonal matrix. A fixed line S = s + ɛc s is such that [ ˆT ]S = S. (1.42) We can see the effect of this transformation in the real and dual parts of the line. For the real part, [R]s = s, (1.43) and we saw that this equation always have a vector as a solution, the vector b defining the rotation axis, constructed from the skew-symmetric matrix [B]. For the dual part, [R](c s) + [D][R]s = c s. (1.44) If we consider s = b/ b, the rotation axis from the previous equation, then [R]s = s and we can collect as ([R]c + d) s = c s. (1.45) The cross product does not get affected by the addition of a component along the direction s, so we add a component ts to the transformed point to get the equation [R]c + d + ts = c, (1.46) that we want to solve for the point c. Rearranging the terms and using Cayley s equation for [R], 2[B]c = [I + B](d + ts), (1.47) and using the skew-symmetry of [B], 2b c = d ts b d. (1.48) To solve for c, we compute the cross product with b, 2b (b c) = b d b (b d), (1.49) which simplifies to c = 1 2 (b d b b + (b d b b b d)). (1.50) Recall that this point will not be fixed by the transformation; it is just one of the points lying on the line so that the moment of the line does not change due to the displacement. Just how much does this particular point (which is, BTW, the point perpendicular to the direction s) translate along the line? In general, the translation vector d of the displacement will not be perpendicular to the direction of the rotation axis. The perpendicular component is given by the expression in the second parenthesis

18 CHAPTER 1. MOTION: AN INTRODUCTION in Eq.(1.50). The component parallel to the rotation axis is given by its projection and will define the amount of slide along the line. We can write t= b d. b (1.51) Chasles theorem can be used to summarize the results of this section. Figure 1.8 shows the equivalent descriptions of a displacement. Figure 1.8: The screw axis, rotation angle and slide of a displacement Theorem 1.5.1 (Chasles, approx. 1830). A general displacements in 3-dimensional space is equivalent to a screw motion consisting of a rotation of angle φ about and a translation t along a line S = s + s0. The direction s and rotation angle φ are computed from the rotation. The moment vector s0 and the slide are computed using the equations just derived above. In total, we need to define six parameters: four to define the direction and location of the line, and two to define the rotation and slide values. The screw axis is a very efficient way of representing a general displacement.

1.6. MORE ON MATRIX REPRESENTATION 19 1.6 More on Matrix Representation 1.6.1 How to create a rotation matrix When we covered rotations, we defined the rotation matrix as containing as columns the coordinates of the vectors of the moving frame, expressed in the fixed frame. This description, even though it is correct, is of little practical use when we want to compute the matrix defining a rotation. Methods to generate a rotation matrix include: Euler angles, roll-pitch-yaw angles, longitudelatitude-roll angles, product of two reflections, use of the rotation axis and rotation angle. We will cover here Euler angles and the use of the rotation axis; for more information, see [7] or [4]. Euler angles A rotation about one of the coordinate axes of the fixed frame adopts a very simple expression and it is also easy to visualize. The coordinate rotations about axes X, Y and Z are given by the matrices 1 0 0 cos β 0 sin β cos θ sin θ 0 [X(α)] = 0 cos α sin α [Y (β)] = 0 1 0 [Z(θ)] = sin θ cos θ 0. 0 sin α cos α sin β 0 cos β 0 0 1 (1.52) We can create a general rotation as the composition of three rotations about perpendicular axes. We could use X Y Z, [R(α, β, θ)] = [X(α)][Y (β)][z(θ)], (1.53) or any other combination, like Z Y Z. Notice that the first rotation happens about X, and the second rotation is about the rotated Y axis, not the original one, and the third rotation is about an axis Z that has been transformed by the two previous rotations; see Figure 1.9. A somehow similar way of describing a rotation is by using three coordinate rotations about fixed axis. See [7] for a description of this method. Equivalent axis-angle representation and Euler parameters We proved in section 1.3.2 that a rotation can be characterized by the rotation axis and rotation angle about the axis. Using Cayley s equation, we can express the components of the rotation matrix as a function of the parameters of the vector b. Recall that b = (b 1, b 2, b 3 ) = tan φ 2 (s x, s y, s z ). We

20 CHAPTER 1. MOTION: AN INTRODUCTION Figure 1.9: Euler angles obtain [R] = [I B] 1 [I + B] = 1 + b 2 1 1 b2 2 b2 3 2(b 1 b 2 b 3 ) 2(b 1 b 3 + b 2 ) 1 + b 2 1 + b2 2 + 2(b 1 b 2 + b 3 ) 1 b 2 b2 1 + b2 2 b2 3 2(b 2 b 3 b 1 ) 3 2(b 1 b 3 b 2 ) 2(b 2 b 3 + b 1 ) 1 b 2 1 b2 2 + b2 3 (1.54) We can see that using the invariant axis and angle to define the rotation matrix gives a not so simple expression. There is a similar expression of the rotation matrix as a function of the rotation axis and angle. If we multiply vector b by cos φ 2, with cos φ 2 0, we can define the following four coefficients, which are called the Euler parameters of the rotation, c 1 = cos φ 2 b 1 = sin φ 2 s 1, c 2 = cos φ 2 b 2 = sin φ 2 s 2, c 3 = cos φ 2 b 3 = sin φ 2 s 3, c 0 = cos φ 2. (1.55) The rotation matrix can be written then as 1 [R] = c 2 0 + c2 1 + c2 2 + c2 3 c 2 0 + c2 1 c2 2 c2 3 2(c 1 c 2 c 0 c 3 ) 2(c 1 c 3 + c 0 c 2 ) 2(c 1 c 2 + c 0 c 3 ) c 2 0 c2 1 + c2 2 c2 3 2(c 2 c 3 c 0 c 1 ) 2(c 1 c 3 c 0 c 2 ) 2(c 2 c 3 + c 0 c 1 ) c 2 0 c2 1 c2 2 + c2 3 (1.56) These parameters will be revisited when we study Clifford algebras.

1.6. MORE ON MATRIX REPRESENTATION 21 1.6.2 Homogeneous matrix representation The homogeneous matrix representation is a convenient (and meaningful, as we will see later in detail) way of describing a general displacement. Given a displacement g T = ([R], d), we can create the 4 4 homogeneous transform as [T ] = [R] d. (1.57) 0 0 0 1 This four-dimensional matrix contains all the information about the displacement. match the dimensions, we need to add a fourth component to our vectors. In order to Notice that we are transforming two types of things with a general displacement: we transform points (their position) and we also transform directions. Up until now, we have treated these two in the same manner, as three-dimensional vectors, even though we knew that they were different things. In the homogeneous representation, they will have also different expressions. For transforming position of points, we will add a unit as the last element of the vectors, so that X 1 X 2 X 3 1 = [T ] x 1 x 2 x 3 1 For transforming directions, we will add zero as the last element, X 1 X 2 X 3 0 = [T ] x 1 x 2 x 3 0. (1.58). (1.59) We will cover the geometric explanation of this fourth component in subsequent sections dealing with projective geometry. For our purpose now, the addition of that last component allows us to operate a displacement by using a single matrix. The expressions found above for composition of displacements, inverse displacement and relative displacement hold, that is, Composition: X = g T 3 (x) = g T 1 (y)g T 2 (x) = [T 1 ][T 2 ]x, Inverse: x = g T 1(X) = (g T ) 1 (X) = [T ] 1 X, Relative displacement: X 2 = g T 12 (X 1 ) = (g T 2 g 1 T 1 )(X 1) = [T 2 ][T 1 ] 1 X 1. (1.60) Exercise: Check that the rotation matrix and displacement vector obtained with the 4 4 homogeneous matrix for the composition of displacements, inverse displacement and relative displacement are the same as the ones derived above.

22 CHAPTER 1. MOTION: AN INTRODUCTION We denote a rotation and a translation about and along an axis as a screw displacement. The screw displacements along the coordinate axes X, Y and Z take a simple form, 1 0 0 a cos β 0 sin β 0 [X(α, a)] = 0 cos α sin α 0 0 sin α cos α 0 [Y (β, b)] = 0 1 0 b sin β 0 cos β 0 (1.61) 0 0 0 1 0 0 0 1 and cos θ sin θ 0 0 [Z(θ, t)] = sin θ cos θ 0 0 0 0 1 t. (1.62) 0 0 0 1

1.6. MORE ON MATRIX REPRESENTATION 23 Homework 1 Chapter 1 1. Prove that the rotation matrix satisfies the properties stated in Proposition 1.3.1. 2. Write the matrix (using Euler angles) corresponding to the following rotation: a rotation about the Z axis of 30 o, followed by a rotation about the Y axis of 40 o, followed by another rotation about the Z axis of 35 o. Find the rotation axis and the rotation angle about this axis. 3. Show that, for a general displacement g T, g T (x + y) g T (x) + g T (y). 4. Show that a general displacement is an isometry. 5. Write a 4 4 homogeneous matrix representing the following displacements of a spoon: from the side of the plate to a resting position inside of the soup, and from this second position to the mouth. 6. Check that the results of the composition of displacements, inverse displacement and relative displacement hold when using the 4 4 homogeneous transform. 7. Compute the composition of displacements of problem 5. 8. Prove that a point in the line S = v + ɛw (in fact, the point of intersection with the perpendicular line from the origin) can be found as c = v w v v. 9. Compute the invariants (screw axis, rotation about and translation along it) of the displacement in problem 7. 10. Compute the common normal line, and the distance and angle between the following lines: L 1 = (0.82, 0.41, 0.41) + ɛ( 1.22, 1.22, 1.22) and L 2 = (0.45, 0, 0.89) + ɛ(0.89, 0.89, 0.45)

Bibliography [1] Ablamowicz, R. and Sobczyk, G., Lectures on Clifford (Geometric) Algebras and Applicatons, Birkhauser, Boston 2004. [2] Artin, M., Algebra, Prentice-Hall, New Jersey, 1991. [3] Bayro Corrochano, E., Geometric Computing for Perception Action Systems, Springer-Verlag, New York, 2001. [4] Bottema, O., and Roth, B., Theoretical Kinematics, North Holland Press, NY, 1979. [5] Browne, J., Grassmann Algebra: Exploring applications of extended vector algebra with Mathematica, Swinburne University of Technology, Melbourne, Australia, 2001. (Draft from http://www.ses.swin.edu.au/homes/browne/grassmannalgebra/book/index.htm). [6] Cohn, P.M., Algebra, 2nd. edition, John Wiley & Sons, 1989. [7] Craig, J. J., Introduction to Robotics, Mechanics and Control, Addison Wesley Publ. Co., 1989. [8] Gosselin, C.M., St-Pierre, E. and Gagne, M., 1996, On the development of the agile eye: mechanical design, control issues and experimentation, IEEE Robotics and Automation Society Magazine, 3(4):29-37. [9] Kumar, A., and Waldron, K.J., 1981, The Workspace of a Mechanical Manipulator, ASME J. Mech. Design, 103: 665-672. [10] McCarthy, j.m., Introduction to Theoretical Kinematics, The MIT Press, 1990. [11] McCarthy, J.M., Geometric Design of Linkages, Springer, New York 2000. [12] Murray, R., Li, Z. and Sastry, S., A Mathematical Introduction to Robotic Manipulation, CRC Press, Boca Raton, 1994. [13] Releaux, F., 1875, The Kinematics of Machinery: Outlines of a Theory of Machines, Dover Publications, New York, translation of 1963. [14] Selig, J.M., Geometrical Methods in Robotics, Springer, London 1996. 73

74 BIBLIOGRAPHY [15] Sugimoto, K., 1987, Kinematic and Dynamic Analysis of Parallel Manipulators by Means of Motor Algebra, ASME Journal of Mechanisms, Transmissions and Automation in Design, 109(1):3-5. [16] Tsai, L. W., 1999, Robot Analysis: The Mechanics of Serial and Parallel Manipulators, John Wiley and Sons, New York, NY.