Figure 1: 2D arm. Figure 2: 2D arm with labelled angles

Similar documents
Linear algebra deals with matrixes: two-dimensional arrays of values. Here s a matrix: [ x + 5y + 7z 9x + 3y + 11z

Here are a couple of warnings to my students who may be here to get a copy of what happened on a day that you missed.

2D and 3D Transformations AUI Course Denbigh Starkey

Kinematic Analysis of a Family of 3R Manipulators

To graph the point (r, θ), simply go out r units along the initial ray, then rotate through the angle θ. The point (1, 5π 6

Dual Arm Robot Research Report

Worksheet 5. 3 Less trigonometry and more dishonesty/linear algebra knowledge Less trigonometry, less dishonesty... 4

Hello, welcome to the video lecture series on Digital Image Processing. So in today's lecture

Laboratory I.7 Linking Up with the Chain Rule

1 Finding Trigonometric Derivatives

To do this the end effector of the robot must be correctly positioned relative to the work piece.

Chapter 7: Analytic Trigonometry

6 Computing Derivatives the Quick and Easy Way

0607 CAMBRIDGE INTERNATIONAL MATHEMATICS

Basics of Computational Geometry

Module13:Interference-I Lecture 13: Interference-I

Graphics and Interaction Transformation geometry and homogeneous coordinates

COMP30019 Graphics and Interaction Transformation geometry and homogeneous coordinates

Classical Mechanics Examples (Lagrange Multipliers)

SNAP Centre Workshop. Introduction to Trigonometry

Kinematics, Kinematics Chains CS 685

0607 CAMBRIDGE INTERNATIONAL MATHEMATICS

A Classification of 3R Orthogonal Manipulators by the Topology of their Workspace

Affine Transformations Computer Graphics Scott D. Anderson

Polar Coordinates. 2, π and ( )

10.2 Calculus with Parametric Curves

Answers to practice questions for Midterm 1

Bends, Jogs, And Wiggles for Railroad Tracks and Vehicle Guide Ways

CALCULATING TRANSFORMATIONS OF KINEMATIC CHAINS USING HOMOGENEOUS COORDINATES

MATHEMATICS FOR ENGINEERING TUTORIAL 5 COORDINATE SYSTEMS

Unit 2: Trigonometry. This lesson is not covered in your workbook. It is a review of trigonometry topics from previous courses.

2D Image Transforms Computer Vision (Kris Kitani) Carnegie Mellon University

Exercises of PIV. incomplete draft, version 0.0. October 2009

Differentiation Using Product and Quotient Rule 1

Math Boot Camp: Coordinate Systems

Vector Calculus: Understanding the Cross Product

Inverse Kinematics. Given a desired position (p) & orientation (R) of the end-effector

A Quick Review of Trigonometry

Ch. 7.4, 7.6, 7.7: Complex Numbers, Polar Coordinates, ParametricFall equations / 17

Fundamentals of Robotics Study of a Robot - Chapter 2 and 3

+ i a y )( cosφ + isinφ) ( ) + i( a x. cosφ a y. = a x

Trigonometry. 9.1 Radian and Degree Measure

Table of Laplace Transforms

MTH 120 Fall 2007 Essex County College Division of Mathematics Handout Version 6 1 October 3, 2007

Forward kinematics and Denavit Hartenburg convention

(a) Find the equation of the plane that passes through the points P, Q, and R.

COMP30019 Graphics and Interaction Three-dimensional transformation geometry and perspective

Computer Graphics with OpenGL ES (J. Han) Chapter IV Spaces and Transforms

521493S Computer Graphics Exercise 2 Solution (Chapters 4-5)

CONSTRUCTION AND ANALYSIS OF INVERSIONS IN S 2 AND H 2. Arunima Ray. Final Paper, MATH 399. Spring 2008 ABSTRACT

Graphing Trigonometric Functions: Day 1

Robot Inverse Kinematics Asanga Ratnaweera Department of Mechanical Engieering

AP Calculus Summer Review Packet

autorob.github.io Inverse Kinematics UM EECS 398/598 - autorob.github.io

Modeling Transformations

1 Introduction to Matlab

Planar Robot Kinematics

Matrix Inverse 2 ( 2) 1 = 2 1 2

3D Rotations and Complex Representations. Computer Graphics CMU /15-662, Fall 2017

Math 231E, Lecture 34. Polar Coordinates and Polar Parametric Equations

Lecture 3.5: Sumary of Inverse Kinematics Solutions

Robotics kinematics and Dynamics

TABLE OF CONTENTS CHAPTER 1 LIMIT AND CONTINUITY... 26

Section 4.1: Introduction to Trigonometry

Fall 2015 Trigonometry: Week 7

4.7a Trig Inverses.notebook September 18, 2014

Visualisation Pipeline : The Virtual Camera

Chapter 2 Trigonometry

GCSE Maths: Formulae you ll need to know not

A Simple Introduction to Omni Roller Robots (3rd April 2015)

Supplementary Material: The Rotation Matrix

Introduction to Homogeneous Transformations & Robot Kinematics

1 Surprises in high dimensions

SECTION 2. Objectives. Identify appropriate coordinate systems for solving problems with vectors.

Math 7 Elementary Linear Algebra PLOTS and ROTATIONS

Today. Parity. General Polygons? Non-Zero Winding Rule. Winding Numbers. CS559 Lecture 11 Polygons, Transformations

3D Transformations and Complex Representations. Computer Graphics CMU /15-662, Fall 2016

CS 106 Winter 2016 Craig S. Kaplan. Module 01 Processing Recap. Topics

Industrial Robots : Manipulators, Kinematics, Dynamics

EEE 187: Robotics Summary 2

Game Engineering CS S-05 Linear Transforms

PreCalculus Unit 1: Unit Circle Trig Quiz Review (Day 9)

Trig for right triangles is pretty straightforward. The three, basic trig functions are just relationships between angles and sides of the triangle.

Polar Coordinates. OpenStax. 1 Dening Polar Coordinates

Introduction to Robotics

Sec 4.1 Coordinates and Scatter Plots. Coordinate Plane: Formed by two real number lines that intersect at a right angle.

2.0 Trigonometry Review Date: Pythagorean Theorem: where c is always the.

A Versatile Model-Based Visibility Measure for Geometric Primitives

UPCAT Reviewer Booklet

Considering bounds for approximation of 2 M to 3 N

Holy Halved Heaquarters Riddler

CS269I: Incentives in Computer Science Lecture #8: Incentives in BGP Routing

Lesson #6: Basic Transformations with the Absolute Value Function

Polynomials. Math 4800/6080 Project Course

4. Use of complex numbers in deriving a solution to an LTI ODE with sinusoidal signal, and getting from such an expression to amplitude and phase lag

AQA GCSE Further Maths Topic Areas

METR 4202: Advanced Control & Robotics

CALCULUS II. Parametric Equations and Polar Coordinates. Paul Dawkins

Game Engineering CS S-07 Homogenous Space and 4x4 Matrices

Additional Divide and Conquer Algorithms. Skipping from chapter 4: Quicksort Binary Search Binary Tree Traversal Matrix Multiplication

Transcription:

2D Kinematics Consier a robotic arm. We can sen it commans like, move that joint so it bens at an angle θ. Once we ve set each joint, that s all well an goo. More interesting, though, is the question of once we set these angles, where is the en of the robotic han? This is kinematics. We ll also look at the problem of inverse kinematics, where we want the en of the han to be at a certain point, an so nee to figure out what angles to set the joints to. Before we move on to the full arm, with all of its possible egrees of freeom, it is easier to consier a two-imensional arm like the following, where our goal is to fin at which point in Cartesian XY plane the en of the arm is locate. Now, suppose that we know the following: Figure : 2D arm We set the first joint to rise from the X-axis at an angle of π/4 raians (the re angle in Figure 2, an the first link (the name for the part of the arm connecting two joints) is 5 meters long. We set the secon joint to be π/6 raians from straight (the blue angle in Figure 2), an the secon link is 3 meters long. Figure 2: 2D arm with labelle angles Notice that on the secon joint, our information is relative from the location of the first link. So, where is the en of the arm? Your first solution may involve trigonometry, so let s o that. The secon joint is locate at (5 cos(π/4), 5 sin(π/4)). That s easy enough. This means the en of the arm is at (5 cos(π/4) + 3 cos(π/4 π/6), 5 sin(π/4) + 3 sin(π/4 π/6), or about (6.4, 4.3). An that s right, it works! But, perhaps you can see why we won t want to o this for a more complicate arm.

You have to be constantly keeping track of the total angles (like when we ha to o π/4 π/6 above). A in another imension, an the trigonometric solution woul get very hairy inee. So let s try something else. Matrix Aition an Multiplication To get this one, we re going to nee some very basic linear algebra, which we ve seen before. First, note that to a (or subtract) two matrices, they must be the same size an shape. This is because matrix aition (an subtraction) is merely piecewise: a b c + g h i j a + g b + h c + i + j. e f k l e + k f + l So, if they re not the same size, aition or subtraction just oesn t make any sense. Before we talk about matrix multiplication, let s efine how we talk about matrix sizes. If a matrix M is m n, that means it has m rows, an n columns. Now, if A an B are matrices, an we want to perform the multiplication AB, then the number of columns in A an the number of rows of B must match. In other wors, if A is m n, then B must be n p. The result of this multiplication woul be m p, where the ith row an the jth column are the ot prouct of the ith row of A an the jth column of B. Consier, for example, the following multiplication: a b c e f Transformational Matrices g h i ag + bh + ci g + eh + f i Now the thing that s going to make our life easier is we can represent a point (x, y) in some coorinate frame x as a vector,. It turns out that we can move this point aroun in our space by using transformation y matrices. Scaling Suppose we have some point (x, y), an we like to move it so that the x-coorinate is five times bigger than it was before. What matrix can we use to perform this transformation? If you look at how matrices are multiplie, hopefully it s clear this can be accomplishe with 5 0 x 5x + 0y 5x 0 x + y y To expan this a bit, if you like to scale x by some factor a, an y by some factor b, you nee the following transformation: a 0 x ax 0 b y by Rotation Now suppose we have some point (x 0, ), an we woul like to perform a rotation aroun the origin by some angle φ, like in Figure 3. x0 x It s not immeiately clear how to change into. So let s just start writing own things that we know, an see if we can solve for x an y. We ll efine to be the istance from the origin for both points (since it s a rotation, it will be the same). y 2

(x_, y_) ϕ (x_0, y_0) θ Figure 3: Rotating a point aroun the origin φ raians cos(θ) x 0 () sin(θ) (2) cos(φ + θ) x (3) sin(φ + θ) y (4) cos(φ + θ) cos(φ) cos(θ) sin(φ) sin(θ) (5) sin(φ + θ) sin(φ) cos(θ) + cos(φ) sin(θ) (6) OK, so an 2 are true just because that s how we convert the polar coorinates (θ, ) to the Cartesian coorinates (x 0, ). 3 an 4 are similar. 5 an 6 are just trigonometric ientities. So now we can set 3 equal to 5, an set 4 equal to 6, an then plug in an 2 wherever possible. Multiply both sies by... x y x cos(φ) cos(θ) sin(φ) sin(θ) sin(φ) cos(θ) cos(φ) sin(θ) cos(φ) x 0 sin(φ) y sin(φ) x 0 + cos(φ) x cos(φ)x 0 sin(φ) y sin(φ)x 0 + cos(φ) An we ve got it! That, we can o as a matrix. To rotate by φ, cos(φ) sin(φ) x0 sin(φ) cos(φ) x y Translation Translating by some istance (not scaling, but just picking it up an moving it some istance in some irection) requires a little bit ifferent intuition. No 2 2 matrix exists that will perform this translation, since our only tool is multiplication, an we nee to o aition. The key is to use Homogeneous Matrices, an a a imension to our points. To move our point in the x irection by m, an in the y irection by n, we multiply as follows: 0 m 0 n x 0 x 0 + m + n 0 0 3

Translation an Rotation Combine If we want to perform a single transformation, in which we both translate an rotate, we can combine these into a single matrix: cos(φ) sin(φ) m sin(φ) cos(φ) n x0 cos(φ)x 0 sin(φ) + m sin(φ)x + cos(φ) + n 0 0 0 We will rarely o this explicitly, but it will be useful to refer to later. 2D Kinematics using Transformations Let s consier the rotational transformation of Figure 3. One way to look at this is that we move the point within the axes. Another way to look at it is that we ha two ifferent points, an we foun a new set of axes such that the coorinates remaine the same, but the axes were ifferent between the two points. In other wors, x x 0, but on ifferent axes (re axes vs. black axes in the figure 4). (x_, y_) ϕ (x_0, y_0) θ Figure 4: Rotating the axis aroun the origin φ raians This is what we will o for our arm; we will rotate an translate the axes, so that our final point is at the origin. So, we ll take our reference frame, or the original black axes, an rotate it π/4, creating a new frame N. We ll then translate along that frame s x-axis 5 meters, creating a new frame N 2. We ll then rotate π/6 raians, creating N 3. We ll then translate along the x-axis to the en of the arm, creating N 4. These can be seen in Figure 5. N_ N_2 N_3 N_4 N_R Figure 5: Transforme axes 4

The matrix transformations to o this, therefore, are: cos(π/4) sin(π/4) 0 sin(π/4) cos(π/4) 0 0 5 0 0 0 0 0 0 } {{ } Rotate to N ( R T ) Translate to N 2 ( T 2 ) When you perform all this multiplication, you get cos( π/6) sin(π/6) 0 sin(π/6) cos(π/6) 0 0 0 } {{ } Rotate to N 3 ( 2 T 3 ) 6.4 4.3 0 3 0 0 0 0 Translate to N 4 ( 3 T 4 ) 0 0 Starting at the origin, or, the same location in the reference frame that we got from our trigonometry. You ll notice our notation, A T B, which is how we notate a transition matrix from frame A to frame B. R T 4 R T T 2 2 T 3 3 T 4. It turns out all of this is much, much easier than trying to o trig, because everything is relative to where you were before. In our thir transformation matrix above, we in t nee to know that before, we ha alreay rotate π/4 raians; we only neee to know that now, we rotate own π/6 from wherever it is we alreay are. This concept keeps things much simpler with 3D arms. Calculating Orientation The above etails how to fin the position of the enpoint of the arm. But, what if we are also intereste in the orientation? In 3D, this will mean the roll, pitch, an yaw of the en of the arm. In 2D, this means only the angle from the X axis in the reference frame. This is remarkably easy. We note that our matrix R T 4 in the above example, is itself a general transformation matrix from the reference frame R to the frame N 4, of the form iscusse in the paragram Translation an Rotation Combine. So, whatever is in the 0, 0 spot of that matrix, is the cosine of our total rotation ψ. So, ψ cos ( R T 4 0, 0). With a perfect computer, with no roun-off or precision errors, this woul be exactly correct. Unfortunately... those on t exist. The problem comes from the fact that arccos an arcsin are pretty volatile. As x approaches or -, small changes in x (like from roun-off errors) result in huge changes in arccos(x) an arcsin(x). So, just using one of those on their own is out. What s left, of course, is arctan, which is fortunately much more stable. If you remember your SOHC- AHTOA, tan(ψ) y x, so ψ tan ( y x ). But, note that because the single fraction is entere, we on t know which quarant we re in. If x an y are both positive, (meaning ψ shoul be between 0 an π/2) we ll get the same answer as if x an y are both negative (meaning ψ shoul be between π an π/2). OK. Fine. For exactly this reason, we won t use arctan(x). Instea, we ll use a commonly-provie arctan2(y,x). Notice this function takes both arguments, meaning the function knows which quarant we re suppose to be in. OK! So, arctan2 will give us a stable answer in the correct quarant... but what o we enter for its two parameters x an y? It s not the final point s x an y, as that gives us the angle from the x axis, not the orientation of the final arm segment. Remember that tan(ψ) sin(ψ) cos(ψ)... an those two things we have (sin(ψ) R T 4, 0 an cos(ψ) R T 4 0, 0). So, our final, stable answer in the correct quarant is: Huzzah! ψ arctan2( R T 4, 0, R T 4 0, 0). 5