CS B659: Principles of Intelligent Robot Motion Rigid Transformations.

Slides:



Advertisements
Similar presentations
John C. Hart CS 318 Interactive Computer Graphics
Advertisements

Animation Following “Advanced Animation and Rendering Techniques” (chapter 15+16) By Agata Przybyszewska.
Chris Hall Aerospace and Ocean Engineering
Dynamics of Articulated Robots Kris Hauser CS B659: Principles of Intelligent Robot Motion Spring 2013.
3D Kinematics Eric Whitman 1/24/2010. Rigid Body State: 2D p.
Configuration Space CS 326 A: Motion Planning
Computer Graphics Recitation 2. 2 The plan today Learn about rotations in 2D and 3D. Representing rotations by quaternions.
1 Last lecture  Path planning for a moving Visibility graph Cell decomposition Potential field  Geometric preliminaries Implementing geometric primitives.
CS 326A: Motion Planning Configuration Space. Motion Planning Framework Continuous representation (configuration space and related spaces + constraints)
Ch. 2: Rigid Body Motions and Homogeneous Transforms
3D Coordinate Systems and Transformations Revision 1
3D orientation.
Ch. 3: Forward and Inverse Kinematics
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
Orientations Goal: –Convenient representation of orientation of objects & characters in a scene Applications to: – inverse kinematics –rigid body simulation.
Computer Animation Rick Parent Computer Animation Algorithms and Techniques Technical Background.
CS 445 / 645 Introduction to Computer Graphics Lecture 21 Representing Rotations Lecture 21 Representing Rotations.
The linear algebra of Canadarm
CS I400/B659: Intelligent Robotics Rigid Transformations.
Forward Kinematics and Jacobians Kris Hauser CS B659: Principles of Intelligent Robot Motion Spring 2013.
Computer Vision Group Prof. Daniel Cremers Autonomous Navigation for Flying Robots Lecture 3.1: 3D Geometry Jürgen Sturm Technische Universität München.
ME/ECE Professor N. J. Ferrier Forward Kinematics Professor Nicola Ferrier ME Room 2246,
1 Kinematics ( 運動學 ) Primer Jyun-Ming Chen Fall 2009.
Rotations and Translations
3D Kinematics Consists of two parts 3D rotation 3D translation  The same as 2D 3D rotation is more complicated than 2D rotation (restricted to z- axis)
Geometric Transformation. So far…. We have been discussing the basic elements of geometric programming. We have discussed points, vectors and their operations.
CS 450: COMPUTER GRAPHICS QUATERNIONS SPRING 2015 DR. MICHAEL J. REALE.
Inverse Kinematics Kris Hauser
Computer Graphics Bing-Yu Chen National Taiwan University.
Key Frame Animation and Inverse Kinematics
Geometric Transformations Jehee Lee Seoul National University.
CSE 681 Review: Transformations. CSE 681 Transformations Modeling transformations build complex models by positioning (transforming) simple components.
Rick Parent - CIS681 ORIENTATION Use Quaternions Interpolating rotations is difficult.
CS 376 Introduction to Computer Graphics 02 / 16 / 2007 Instructor: Michael Eckmann.
1 CS 430/536 Computer Graphics I 3D Transformations World Window to Viewport Transformation Week 2, Lecture 4 David Breen, William Regli and Maxim Peysakhov.
Advanced Computer Graphics Spring 2014
1 Fundamentals of Robotics Linking perception to action 2. Motion of Rigid Bodies 南台科技大學電機工程系謝銘原.
CS B659: Principles of Intelligent Robot Motion Configuration Space.
Sect. 4.2: Orthogonal Transformations
Chapter 2 Rigid Motions and Coordinate Transformations
CS B659: Principles of Intelligent Robot Motion Rigid Transformations and Collision Detection.
Kinematics Primer Jyun-Ming Chen. Contents General Properties of Transform 2D and 3D Rigid Body Transforms Representation Computation Conversion … Transforms.
EEE. Dept of HONG KONG University of Science and Technology Introduction to Robotics Page 1 Lecture 2. Rigid Body Motion Main Concepts: Configuration Space.
Animating Rotations and Using Quaternions. What We’ll Talk About Animating Translation Animating 2D Rotation Euler Angle representation 3D Angle problems.
Rotation and Orientation: Fundamentals Jehee Lee Seoul National University.
CS 551/645 Fall 2000 Parameterized Rotations, Curves, and Surfaces.
Kinematics. The function of a robot is to manipulate objects in its workspace. To manipulate objects means to cause them to move in a desired way (as.
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.
Forward Kinematics and Configurations
Affine Geometry.
Euler Angles This means, that we can represent an orientation with 3 numbers Assuming we limit ourselves to 3 rotations without successive rotations about.
Learning from the Past, Looking to the Future James R. (Jim) Beaty, PhD - NASA Langley Research Center Vehicle Analysis Branch, Systems Analysis & Concepts.
Forward Kinematics and Configurations
Computer Animation Algorithms and Techniques
CPSC 641: Computer Graphics Rotation Representation and Interpolation
CS 445 / 645 Introduction to Computer Graphics
3D Kinematics Consists of two parts
Ch. 2: Rigid Body Motions and Homogeneous Transforms
More Rigid Transforms, 3D Rotations
Mobile Robot Kinematics
ECE 383/ME 442: Intro to Robotics and Automation
Forward Kinematics and Configuration Space
VIRTUAL ENVIRONMENT.
UNIVERSITY OF ILLINOIS AT URBANA-CHAMPAIGN
Rotation and Orientation: Fundamentals
Presentation transcript:

CS B659: Principles of Intelligent Robot Motion Rigid Transformations

Agenda Principles, Ch

Rigid Objects

Biological systems, virtual characters

Articulated Robot Robot: usually a rigid articulated structure Geometric CAD models, relative to reference frames A configuration specifies the placement of those frames q1q1q1q1 q2q2q2q2

reference point Rigid Transformation in 2D q = (t x,t y,  ) with   [0,2  ) Robot R 0  R 2 given in reference frame T 0 What’s the new robot R q ? txtx tyty  robot reference direction workspace

Rigid Transformation in 2D q = (t x,t y,  ) with   [0,2  ) Robot R 0  R 2 given in reference frame T 0 What’s the new robot R q ? {T q (x,y) | (x,y)  R 0 } Define rigid transformation T q (x,y) : R 2  R 2 T q (x,y) = cos θ -sin θ sin θ cos θ xyxy txtytxty + 2D rotation matrixAffine translation

2D Rigid Rotations A rotation matrix A has: det(A) = +1 Orthogonal rows and columns: A T A=I, AA T =I ||Ax|| = ||x|| for any x, L 2 norm ||.|| Product of two rotations is a rotation cos θ -sin θ sin θ cos θ θ (cos θ, sin θ) (-sin θ, cos θ) (1,0) (0,1)

Rigid Transformation in 3D q = (t x,t y,t z,R) with R a 3x3 rotation matrix Robot R 0  R 3 given in reference frame T 0 What’s the new robot R q ? R q = {T q (x,y,z) | (x,y,z)  R 0 } Define rigid transformation T q (x,y,z) : R 3  R 3 T q (x,y,z) = R xyzxyz txtytztxtytz + Affine translation3D rotation matrix

3-D Rigid Rotations r 11 r 12 r 13 r 21 r 22 r 23 r 31 r 32 r 33 (1,0,0) (0,1,0) (0,0,1) (Right-handed coordinate system) det(A) = +1 Orthogonal rows and columns: A T A=I, AA T =I ||Ax|| = ||x|| for any x, L 2 norm ||.|| Product of two rotations is a rotation (1,0,0) (r 11,r 21,r 31 ) (0,0,1) (r 13,r 23,r 33 ) (r 12,r 22,r 32 )

Coordinate Frames (1,0,0) (0,1,0) (0,0,1) (r 11,r 21,r 31 ) (r 13,r 23,r 33 ) (r 12,r 22,r 32 ) R R -1 = R T Local frame World frame [x,y,z] T R[x,y,z] T

3 representations Euler angles R Euler (  Axis angle R AA (v,  ) Quaternion R Quat (q) All representations are “equivalent” but may have certain mathematical or computational advantages

Axis-aligned rotations cos θ -sin θ 0 sin θ cos θ Rotate about: Z axis Y axis X axis cos θ 0 sin θ sin θ 0 cos θ cos θ -sin θ 0 sin θ cos θ

Parameterization of SO(3)  Euler angles: (  x yz x yz x y z  x yz 1  2  3  4

Euler Angles  Which axes to pick, and what order?  Convention A,B,C  R Euler (  ) = R A (  )R B (  )R C (  )  E.g., ZYZ, ZYX (roll-pitch-yaw), etc

Euler Angles  Which axes to pick, and what order?  Convention A,B,C  R Euler (  ) = R A (  )R B (  )R C (  )  E.g., ZYZ, ZYX (roll-pitch-yaw), etc  Disadvantages  Must constrain to range of values  Singularities, e.g. ZYZ when  =0 or  (Gimbal lock)  Interpolation?

Axis-Angle Representation Every rotation matrix R can be obtained by rotating the identity matrix by some angle θ about some axis v! R v = v

Axis-Angle Representation Axis v (||v||=1), angle θ Rodrigues’ formula: rotate x about v -> x’ x’ = x cos θ + (v x x) sin θ + v (v T x) (1 - cos θ) R AA (θ,v) = cos θ I + sin θ [v] + (1 - cos θ) v v T Cross product matrix Or in matrix form… 0 -v z v y v z 0 -v x -v y v x 0

Recovering Axis and Angle from the Rotation Matrix θ = Angle(R) = cos -1 ((r 11 +r 22 +r 33 -1)/2) = cos -1 ((tr(R)-1)/2) v = Axis(R) = 1/(2 sin θ) r 32 -r 23 r 13 -r 31 r 21 -r 12

Properties of Axis-Angle Disadvantages: Non unique: R AA (θ,v)=R AA (-θ,-v) (can constrain θ to range [0,  ]) 4 parameters + one unit length constraint ||v||=1; dealing with this constraint is sometimes annoying, for example, in interpolation, optimization, or sampling Unique encoding: vector w = θv θ = ||w||, v = w/||w|| “Exponential map” R EM (w) = R AA ( ||w||, w/||w|| )

Quaternion representation Generalization of complex numbers Complex z=z 0 +i z 1, with |z|=1 can represent a 2D rotation. What’s the 3D analogue? Quaternions were a forerunner of vectors and were once mandatory of all students of physics and math! q = q 0 +q 1 i + q 2 j +q 3 k, where i 2 = j 2 = k 2 = -1 i = jk = -kj j = ki = -ik k = ij = -ji

Unit quaternion representation q = (q 0,q 1,q 2,q 3 ), ||q||=1 Related to axis angle: q = (cos  /2,v x sin  /2, v y sin  /2, v z sin  /2) R Q (q) = 2(q 0 2 +q 1 2 )-12(q 1 q 2 -q 0 q 3 )2(q 1 q 3 +q 0 q 2 ) 2(q 1 q 2 +q 0 q 3 ) 2(q 0 2 +q 2 2 )-1 2(q 2 q 3 -q 0 q 1 ) 2(q 1 q 3 -q 0 q 2 ) 2(q 2 q 3 +q 0 q 1 ) 2(q 0 2 +q 3 2 )-1

Properties of Unit Quaternions 4-sphere: 3D manifold in 4D space Non-unique: Double cover of SO(3) Advantages (widely used in computer animation): Quaternion multiplication = rotation composition (slightly faster than matrix *) Curve interpolation formulas (Shoemake, ‘85)

Summary Rotation matrix 9 parameters R ij in range [-1,1] Constraint: determinant +1 Advantages: composition, inversion are easy Euler angles 3 parameters (  in range [0,2  ) Axes picked by convention (e.g., Roll-Pitch-Yaw) Advantages: no constraints, simple interpolation “works” Disadvantages: multiple representation, singularities, inversion not easy Axis-angle 4 parameters (  v),  in [0,  Constraint: |v|=1 Advantages: inversion is easy Disadvantages: constraint, interpolation, multiple representation at  Moment representation (aka exponential map) 3 parameters w (=  v), ||w||<=  Advantages: no constraints, inversion is easy Disadvantages: interpolation, multiple representation at  Quaternion 4 parameters q=(q 0,q 1,q 2,q 3 ) Constraint: |q|=1 Advantages: interpolation formulas, inversion easy Disadvantages: constraint, multiple representation R(q) = R(-q)

Notion of Distance θ(R 1 T R 2 ) = cos -1 ((tr(R 1 T R 2 )-1)/2) measures the minimum angle needed to rotate from frame R 1 to R 2 Makes a good distance metric

Rotation in Motion Interpolating between two rotation matrices A and B We want a path X(s) : [0,1] -> SO(3) with R(0) = A and R(1) = B Let v = Axis(A T B), θ = Angle(A T B) Verify that X(s) = A R AA (sθ,v) satisfies the desired properties Actually a geodesic in SO(3)!

Angular Velocities For parameterized rotation trajectory R EM (wt), we can show: d/dt R EM (wt) = [w] R EM (wt) => |w| is the speed of rotation => w x x is the velocity of some point x, specified in world coordinates, attached to the frame as it rotates => w is the angular velocity

Recap Multiple representations of SO(3) All four implemented robustly in C++ in KrisLibrary Axis angle / moment implemented in Python Notion of distance, straight line, speed in SO(3)

Next Lecture Read Principles Ch. 3.8 Optional: A Mathematical Introduction to Robotic Manipulation, Ch