Chapter 2 Rigid Motions and Coordinate Transformations

Slides:



Advertisements
Similar presentations
Links and Joints.
Advertisements

Introduction to ROBOTICS
Kinematic Modelling in Robotics
1 ME 302 DYNAMICS OF MACHINERY Dynamic Force Analysis IV Dr. Sadettin KAPUCU © 2007 Sadettin Kapucu.
Kinematics Pose (position and orientation) of a Rigid Body
Chapter 4.1 Mathematical Concepts
The City College of New York 1 Dr. Jizhong Xiao Department of Electrical Engineering City College of New York Kinematics of Robot Manipulator.
Computer Graphics Recitation 2. 2 The plan today Learn about rotations in 2D and 3D. Representing rotations by quaternions.
Chapter 4.1 Mathematical Concepts. 2 Applied Trigonometry Trigonometric functions Defined using right triangle  x y h.
Ch. 2: Rigid Body Motions and Homogeneous Transforms
Outline for Today More math… Finish linear algebra: Matrix composition
CSCE 590E Spring 2007 Basic Math By Jijun Tang. Applied Trigonometry Trigonometric functions  Defined using right triangle  x y h.
Ch. 4: Velocity Kinematics
3-D Geometry.
3D orientation.
Ch. 3: Forward and Inverse Kinematics
Introduction to Robotics Lecture II Alfred Bruckstein Yaniv Altshuler.
CSCE 689: Computer Animation Rotation Representation and Interpolation
CSCE 441: Computer Graphics Rotation Representation and Interpolation
CSCE 641: Computer Graphics Rotation Representation and Interpolation Jinxiang Chai.
Introduction to ROBOTICS
Introduction to ROBOTICS
Linear Algebra Review CSE169: Computer Animation Instructor: Steve Rotenberg UCSD, Winter 2005.
An Introduction to Robot Kinematics
More details and examples on robot arms and kinematics
CS 450: COMPUTER GRAPHICS 3D TRANSFORMATIONS SPRING 2015 DR. MICHAEL J. REALE.
ME/ECE Professor N. J. Ferrier Forward Kinematics Professor Nicola Ferrier ME Room 2246,
Mathematical Fundamentals
Rotations and Translations
Graphics CSE 581 – Interactive Computer Graphics Mathematics for Computer Graphics CSE 581 – Roger Crawfis (slides developed from Korea University slides)
6.837 Linear Algebra Review Patrick Nichols Thursday, September 18, 2003.
Patrick Nichols Thursday, September 18, Linear Algebra Review.
Geometric Transformation. So far…. We have been discussing the basic elements of geometric programming. We have discussed points, vectors and their operations.
Kinematics of Robot Manipulator
Mathematical Foundations Sections A-1 to A-5 Some of the material in these slides may have been adapted from university of Virginia, MIT and Åbo Akademi.
Chapter 2 Robot Kinematics: Position Analysis
Geometric Transformations Jehee Lee Seoul National University.
6.837 Linear Algebra Review Patrick Nichols Thursday, September 18, 2003.
Rotations and Translations
CSE 681 Review: Transformations. CSE 681 Transformations Modeling transformations build complex models by positioning (transforming) simple components.
Transformations Jehee Lee Seoul National University.
K INEMATICS P OSE ( POSITION AND ORIENTATION ) OF A R IGID B ODY University of Bridgeport 1 Introduction to ROBOTICS.
Kinematics of Robot Manipulator
Advanced Computer Graphics Spring 2014
1 Fundamentals of Robotics Linking perception to action 2. Motion of Rigid Bodies 南台科技大學電機工程系謝銘原.
Rotation and Orientation: Fundamentals Jehee Lee Seoul National University.
What is Kinematics. Kinematics studies the motion of bodies.
Chapter 2: Description of position and orientation Faculty of Engineering - Mechanical Engineering Department ROBOTICS Outline: Introduction. Descriptions:
Comparing Two Motions Jehee Lee Seoul National University.
Geometric Transformations Sang Il Park Sejong University Many slides come from Jehee Lee’s.
Affine Geometry.
CSCE 552 Fall 2012 Math By Jijun Tang. Applied Trigonometry Trigonometric functions  Defined using right triangle  x y h.
City College of New York 1 Dr. John (Jizhong) Xiao Department of Electrical Engineering City College of New York Review for Midterm.
Euler Angles This means, that we can represent an orientation with 3 numbers Assuming we limit ourselves to 3 rotations without successive rotations about.
Geometric Transformations. Transformations Linear transformations Rigid transformations Affine transformations Projective transformations T Global reference.
Week 5 - Monday.  What did we talk about last time?  Lines and planes  Trigonometry  Transforms  Affine transforms  Rotation  Scaling  Shearing.
Linear Algebra Review Tuesday, September 7, 2010.
Learning from the Past, Looking to the Future James R. (Jim) Beaty, PhD - NASA Langley Research Center Vehicle Analysis Branch, Systems Analysis & Concepts.
Fundamentals of Computer Animation Orientation and Rotation.
Graphics Graphics Korea University kucg.korea.ac.kr Mathematics for Computer Graphics 고려대학교 컴퓨터 그래픽스 연구실.
Sect. 4.5: Cayley-Klein Parameters 3 independent quantities are needed to specify a rigid body orientation. Most often, we choose them to be the Euler.
Robotics Chapter 3 – Forward Kinematics
Kinematics 제어시스템 이론 및 실습 조현우
CPSC 641: Computer Graphics Rotation Representation and Interpolation
Ch. 2: Rigid Body Motions and Homogeneous Transforms
Mobile Robot Kinematics
Introduction to Vectors and Frames
Geometric Objects and Transformations (II)
Rotation and Orientation: Fundamentals
Presentation transcript:

Chapter 2 Rigid Motions and Coordinate Transformations Dr. Amit Goradia

Robot Model

Robot Kinematics Mathematical tools needed: Rigid body transformations Vector and matrix algebra Rigid body transformations Translation Rotation Homogenous Transformations used to represent rigid body transformations

Forward Kinematics Given the various joint and link parameters, compute the end-effector (tool) location in task space. Given joint variables End-effector position and orientation, -Formula? Joint Frame World Forward Inverse

Inverse Kinematics Given a position in task space, compute the joint angles required to attain it. End effector position and orientation Formula for joint variables Joint Frame World Forward Inverse

Example 1

Example 2: Three Link Planer Robot Joint Coordinates Task Coordinates Forward Kinematics Calculate Task Coordinates in terms of Joint Coordinates

Linear Algebra Concepts The set of Real numbers is represented by: The set of positive real numbers is formally defined as: is an Eucledian space of real dimension Geometric Objects Points Vectors Transformations Coordinate frames Lines Rays Planes Normals etc.

Points v/s Vectors Points in represented as 3 numbers Vectors in represented as 3 numbers They are not the same thing!!!! They have different operations and different behaviours

1D Example: Time Point in time: class meeting time class meets at 9:00 am Vector in time: class duration class lasts 2 hours Operations: class at 2PM + class at 3PM ≠ class at 5PM !! 2 hour class + 3 hour class = 5 hours of classes class ends at 11AM – starts at 9AM = 3 hour class class starts at 9AM + lasts 2 hours = ends at 11AM 2 classes at 3PM ≠ one class at 6PM !! 2 classes last 3 hours = 6 hours of classes Class from 2PM to 10PM, half done at

“Coordinate Systems” for Time Knowing just the hour number doesn’t tell you everything… AM vs. PM (or use 8h00 vs 20h00) Time zones: same point, many representations 10 (India) == 4:30 (UK) to remove ambiguity, often use GMT (World frame) If always staying in local time zone, not important if scheduling globally, must be careful. convert from one time zone to another. Also, hours only good within one day need to specify date & time UNIX time: seconds since 01/01/1970, 00h00 GMT Notice: time durations are unaffected by all this!

Points and Vectors in Space Point describes a location in space can subtract points to get a vector can take weighted average of points to get a point Vector describes a displacement in space has a magnitude and direction can add, subtract, scale vectors can add vector to a point to get a point Has a dot product and cross product defined To represent them as three numbers, you must specify which coordinate system

Vector Interpretation Think of a vector as a line in 2D or 3D Think of a matrix as a transformation on a line or set of lines V V’

(use the head-to-tail method to combine vectors) Vectors: Dot Product Interpretation: the dot product measures to what degree two vectors are aligned A A+B = C (use the head-to-tail method to combine vectors) B C B A

Vectors: Dot Product Think of the dot product as a matrix multiplication The magnitude is the dot product of a vector with itself The dot product is also related to the angle between the two vectors

Vectors: Cross Product The cross product of vectors A and B is a vector C which is perpendicular to A and B The magnitude of C is proportional to the sine of the angle between A and B The direction of C follows the right hand rule – this why we call it a “right-handed coordinate system”

Arithmetic for Points and Vectors

Coordinate Frames in 3D Origin point, and 3 orthonormal vectors for x,y,z axes (right-handed) f g h a b x y z O P Q c

Coordinates If you have coordinate triples such as: Then, with frame such as you can construct a point or vector: Same coordinates, different frame  different point or vector Coordinates have no real meaning without a frame vectors don’t depend on the origin of the frame, only the axes

Coordinates of a Frame Suppose you have a frame In world coordinates, might have But in itself always have coordinates:

Coordinate equivalences Given a frame: Can have a point with some coords: Can have a vector with same coords: Formally, we have: Informally, p and look and act about the same People often sloppy, don’t distinguish point from vector Can only get away with it if you stay in same frame! And even then need to be careful… O

Coordinate Transformation Rotation only Point p can be represented in both coordinate frames How to relate the coordinate in these two frames?

Rotations Basic Rotation , , and represent the projections of onto OX, OY, OZ axes, respectively Since

Rotations Basic Rotation Matrix Rotation about x-axis by angle

Rotations Is it True? Rotation about x axis by angle

Basic Rotation Matrices Rotation about x-axis by angle Rotation about y-axis by angle Rotation about z-axis by angle

Properties of Rotation Matrices Basic Rotation Matrix Obtain the coordinate of from the coordinate of R is an orthogonal matrix (inverse equal to transpose) Dot products are commutative! <== 3X3 identity matrix

Properties of Rotation Matrices Columns of R are unit vectors and are mutually orthogonal Columns of R represent a vector in the UVW frame w.r.t. XYZ frame Rows of r are also unit vectors and represent a basis in XYZ frame wrt UVW Space of all possible rotation matrices is denoted as (special orthogonal group of order 3)

Rotation Matrix as a Direction Cosine Matrix Elements of the rotation matrix are the cosines of the unsigned angles between the moving axes and the fixed axes. is the unsigned angle between x’ and y

Example

Example 3 A point is attached to a rotating frame, the frame rotates 60 degree about the OZ axis of the reference frame. Find the coordinates of the point relative to the reference frame after the rotation.

Example 4 A point is the coordinate w.r.t. the reference coordinate system, find the corresponding point w.r.t. the rotated OU-V-W coordinate system if it has been rotated 60 degree about OZ axis.

Composition of Rotations Consider a point p represented in 3 coordinate frames. Substituting: Which implies:

Composite Rotation Matrix A sequence of finite rotations matrix multiplications do not commute rules: if rotating coordinate O-U-V-W is rotating about principal axis of OXYZ frame, then Pre-multiply the previous (resultant) rotation matrix with an appropriate basic rotation matrix if rotating coordinate OUVW is rotating about its own principal axes, then post-multiply the previous (resultant) rotation matrix with an appropriate basic rotation matrix

Example 5 Find the rotation matrix for the following operations: Pre-multiply if rotate about the OXYZ axes Post-multiply if rotate about the OUVW axes

Composite Rotations (Intermediate Reference Frame) Successive Rotations about Intermediate axes: Post-Multiply successive rotation matrices

Composite Rotations (Fixed Reference Frame) Successive Rotations about fixed reference frames: Pre-multiply successive rotation matrices R is a rotation about the fixed Z axis

Orientation Representation Revisited Rotation matrix representation needs 9 elements to completely describe the orientation of a rotating rigid body. There are only 3 unique quantities in a rotation matrix There are 6 redundant elements!!!!!! Compact method to represent orientation? Euler Angles Representation

Orientation Representation Problems: 6 extra elements need to be specified Long series of computations with inherent numerical errors causes R to loose orthogonal property. Need to orthogonalize from time to time Can calculate a rotation difference but canot smoothly interpolate over a difference. Cannot smoothly rotate from one orientation to another.

Orientation Representation Euler Angles Representation ( , , ) Many different types Description of Euler angle representations Euler Angle I Euler Angle II Roll-Pitch-Yaw Sequence about OZ axis about OZ axis about OX axis of about OU axis about OV axis about OY axis Rotations about OW axis about OW axis about OZ axis X convention Y convention Cardanian

Euler Angle I, Animated w'= z w'"= w" f v'" v "  v' y u'"  u' =u" x

Orientation Representation Euler Angle I

Euler Angle I Resultant eulerian rotation matrix:

Euler Angle II, Animated w'= z w"'= w"  v"'  v' =v"  y u"' u" Note the opposite (clockwise) sense of the third rotation, f. u' x

Euler Angles → Rotation Matrix Rotation Matrix with Euler Angle II

Rotation Matrix → Euler Angles What if θ = nπ, n Є Z??

Singularity - Gimbal Lock Two out of three axes are aligned Loss of one degree of freedom Apollo 11 and gimbal lock

Orientation Representation Description of Roll Pitch Yaw Z` Description of Yaw, Pitch, Roll A rotation of about the OX axis ( ) -- yaw A rotation of about the OY axis ( ) -- pitch A rotation of about the OZ axis ( ) -- roll Y X

Roll Pitch Yaw Pre-multiply using the basic rotation matrices

Valid Rotation Sequences 6 sets of Euler Angles ZXZ, ZYZ, XZX, XYX, YZY, YXY 6 sets of Cardanian angles XYZ, YZX, ZXY, XZY, ZYX, YXZ Euler Rotation Theorem: In three-dimensional space, any displacement of a rigid body such that a point on the rigid body remains fixed, is equivalent to a rotation about a fixed axis through that point.

Universality of Euler Angles Consider Euler 1 notation (X Convention) Remember that: Rotation matrix represents moving frame basis wrt fixed frame basis Columns represent moving axes wrt fixed axes Rows represent fixed axes wrt moving axes

Universality of Euler Angles Show that: Parameterization of R can represent any proper orthonormal matrix Columns of R can be transformed into any arbitrary set of orthonormal vectors Proof: Column 3 : Representation of unit vector with spherical angle coordinates Can be made to coincide with any arbitrary vector by choosing proper angles

Universality of Euler Angles Column 1: Where, Now, u1 , u2 are unit vectors and So u1 and u2 span the plane perpendicular to e3 and we can choose phi to generate any angle in that plane

Universality of Euler Angles With choice of and , we can locate the Z axis of the new coordinate system arbitrarily With the choice of , we can locate the X axis perpendicular to Z and at any desired angle in that plane Choose Y to complete the triad Proof complete

Angle Axis Representation (Rodriguez formula)

Angle Axis Representation Define rotation axis r and an angle of rotation about r Results in a compact but non-minimal representation Procedure Rotate by about axis Z till r is coplaner with axis X Rotate by about axis Y to align r with Z Rotate about Z by Return r to original position by rotating about Y by and about z by Result

Angle Axis Representation Consider following simplification: Now:

Angle Axis Representation Total 4 parameters: 1 vector (3 parameters) A rotation angle about the vector Selected vector is normalized: If , then inverse is not defined. Singularities located at Not unique:

Rotation Representation using Quaternions Quaternions were first introduced for complex number analysis Generalization of complex number representation 4 dimensional quantity One scalar A three tuple representing a vector. Avoid drawbacks of angle axis representation by Distinguish between rotations of different signs Avoid singularity at

Quaternions Popularized for use in rigid motion representation in Invented by Hamilton in 1843: Along the royal canal in Dublin… Popularized for use in rigid motion representation in computer graphics by Shoemake in 80’s Increases computational efficiency as it requires less number of additions and multiplications for computing a given pose of a rigid body

Quaternions: Basic Properties Properties of complex dimensions Consider 2 quaternions: Multiplication Complex Conjugate

Quaternions Let’s consider the set of unit quaternions: This is a four-dimensional hypersphere, i.e. the 3-sphere The identity quaternion is: Consider: Therefore, the inverse of a unit quaternion is:

Quaternions Associate a rotation with a unit quaternion as follows: Given a unit axis, , and an angle, : The associated quaternion is: Therefore, represents the same rotation as Let be the quaternion associated with the vector You can rotate from frame a to b: Composition: Inversion:

Example 6 What rotation is this? Rotate by

Example 7 Find the difference between these two axis angle rotations:

Quaternions: Interpolations Suppose you’re given two rotations, and How do you calculate intermediate rotations? Do quaternions help? Suprisingly, this actually works Finds a geodesic (shortest path between points in space)

Affine Transformations In Euclidean space, an affine transformation preserves following properties Collinearity of points Distance ratios Affine transformation composed of linear transformations and a translation.

Rigid Motions position vector of P in {B} is transformed to position vector of P in {A} description of {B} as seen from an observer in {A} Rigid body motions are Affine transformations Rotation of {B} with respect to {A} Translation of the origin of {B} with respect to origin of {A}

Rigid Motions Two Special Cases 1. Translation only Axes of {B} and {A} are parallel 2. Rotation only Origins of {B} and {A} are coincident

Homogeneous Representation Coordinate transformation from {B} to {A} Homogeneous transformation matrix Rotation matrix Position vector Scaling

Homogeneous Transformation Special cases 1. Translation 2. Rotation

Homogeneous Coordinates Add an extra component. 1 for a point, 0 for a vector: Transform a point: Top 3 rows are the affine transform Bottom row stays 1 Transform a vector Top 3 rows are the linear transform Bottom row stays 0

Homogeneous Arithmetic Legal operations always end in 0 or 1!

Example 8 Translation along Z-axis by h: O, O’ O, O’ h

Example 9 Rotation about the X-axis by

Composite Homogeneous Transformation Rules: Transformation (rotation/translation) w.r.t (X,Y,Z) (OLD FRAME), using pre-multiplication Transformation (rotation/translation) w.r.t (U,V,W) (NEW FRAME), using post-multiplication

Example 10 Find the homogeneous transformation matrix (T) for the following operations:

Homogeneous Representation A frame in space (Geometric Interpretation) (z’) (y’) (X’) Principal axis n w.r.t. the reference coordinate system

Homogeneous Transformation Translation

Homogeneous Transformation Composite Homogeneous Transformation Matrix ? Transformation matrix for adjacent coordinate frames Chain product of successive coordinate transformation matrices

Example 11 For the figure shown below, find the 4x4 homogeneous transformation matrices and for i=1, 2, 3, 4, 5 Can you find the answer by observation based on the geometric interpretation of homogeneous transformation matrix?

Inverse Homogenous Transformation Inverse of the rotation submatrix is equivalent to its transpose