Professional Documents
Culture Documents
ROBOTICS
SEM 4143
CHAPTER 2
Robot Kinematics
The Robot System
Kinematics Hardware
Mechanical Design
Actuators
Dynamics
Control System
Task Planning
Sensors
Software
Prof Dr Shamsudin Hj Mohd Amin 2
Introduction to Kinematics
Tool Frame
x
Link Frame
Goal Frame
x
x
Base
x Frame
5
Kinematic Relationship
– Between two frames we have a kinematic
relationship - basically a translation and a
rotation.
z
y
x
– This relationship is mathematically represented
by a 4 4 Homogeneous Transformation
Matrix.
Prof Dr Shamsudin Hj Mohd Amin 6
Homogeneous Transformations
r1 r2 r3 x
3 3 Rotational
Matrix r4 r5 r6 y 3 1 Translation
r7 r8 r9 z
0 0 0 1 Global Scale
1 3 Perspective
Goal
z
y
x
12
Prof Dr Shamsudin Hj Mohd Amin 13
An Example - The PUMA 560
2
4 6
5 There are two more
joints on the end
1 effector (the gripper)
The PUMA 560 has SIX revolute joints
A revolute joint has ONE degree of freedom ( 1 DOF) that is
defined by its angle
Matrix Representation: B
ax bx
A B a xb x ayby
ay by
Unit Vector
Vector in the direction of a chosen vector but whose magnitude is 1.
B
uB
B B
uB
Matrix Multiplication:
An (m x n) matrix A and an (n x p) matrix B, can be multiplied since
the number of columns of A is equal to the number of rows of B.
Non-Commutative Multiplication
AB is NOT equal to BA
a b e f ae bg af bh
c d g h ce dg cf dh
Matrix Addition:
a b e f a e b f
c d g h c g d h
(VN,VO)
VO
P
N
X VN
Px
Px = distance between the XY and NO coordinate planes
XY VX VN Px
V V NO P
Notation: VY 0
VO
18
Writing V XY in terms of V NO
Y O
VO
P
N
X VN
PX V N
V XY P V NO
VO
VO
N
VN
XY
Px
X P
PY
PX V N
V XY P V NO
PY VO
VN V NO cosθ V NO cosθ V NO n
V NO
VO V NO sinθ V NO cos(90 θ) V NO o
X
Rotation (around the Z-Axis) Y Z
VY
X
VX
= Angle of rotation between the XY and NO coordinate axis
VX VN
V XY V NO
VY VO
22
x
Y Unit vector along X-Axis
V
Can be considered with respect to
the XY coordinates or NO coordinates
V
V XY V NO
VY
X
VX
VX V XY cosα V NO cosα V NO x
X N O (Substituting for VNO using the N and O components of
V (V n V o) x the vector)
VX V N (x n ) V O (x o)
V N (cosθ) V O (cos(θ 90))
V N (cosθ) V O (sinθ)
VY V NO sinα V NO cos(90 α) V NO y
VY (V N n V O o ) y
VY V N (y n ) V O (y o )
V N (cos(90 θ)) V O (cosθ)
V N (sinθ) V O (cosθ)
So…. VX V N (cosθ) V O (sinθ)
VY V N (sinθ) V O (cosθ) VX
V XY
Written in Matrix Form VY
VX cosθ sinθ V N
V XY
VY sinθ cosθ V O Rotation Matrix about the z-axis
(VN,VO)
Y0
VNO
VXY
P X1
XY VX Px cosθ sinθ V N
V
VY Py sinθ cosθ V O
(Note : Px, Py are relative to the original coordinate frame. Translation followed by rotation is different
than rotation followed by translation.)
In other words, knowing the coordinates of a point (VN,VO) in some coordinate
frame (NO) you can find the position of that point relative to your original
coordinate frame (X0Y0).
VX Px cosθ sinθ 0 VN
Padding with 0’s and 1’s
VY Py sinθ cosθ 0 VO
1 1 0 0 1 1
VX cosθ sinθ Px VN
VY sinθ cosθ Py VO
Simplifying into a matrix form
1 0 0 1 1
cosθ sinθ Px
H sinθ cosθ Py Homogenous Matrix for a Translation in XY plane,
0 0 1 followed by a Rotation around the z-axis
cosθ 0 sinθ
Ry 0 1 0 Rotation around the Y-Axis
sinθ 0 cosθ
1 0 0
Rz 0 cosθ sinθ
Rotation around the X-Axis
0 sinθ cosθ
VN
The (n,o,a) position of a point relative to the current
VO
V XY H A coordinate frame you are in.
V
1
nx ox ax Px VN
XY ny oy ay Py VO VX nxV N oxVO axV A Px
V
nz oz az Pz VA
0 0 0 1 1
The rotation and translation part can be combined into a single homogeneous matrix IF and ONLY
IF both are relative to the same coordinate frame.
Y WN
WO
WA
T
P
X
Z
W X WI WN
Point relative to the Point relative to the Point relative to the
W Y WJ I-J-K frame WO N-O-A frame
X-Y-Z frame
WZ WK WA
WI Pi ni oi ai WN WI ni oi ai Pi WN
WJ Pj nj oj aj WO WJ nj oj aj Pj WO
WK Pk nk ok ak WA WK nk ok ak Pk WA
1 0 0 0 1 1
30
WN
Y WO
WA
T
P
X
X I WX ix jx kx Tx WI
W Tx ix jx kx W
WY iy jy ky Ty WJ
WY Ty iy jy ky WJ
WZ iz jz kz Tz WK
WZ Tz iz jz kz Wk
1 0 0 0 1 1
I
WX ix jx kx Tx n i oi ai Pi WN
W
Substituting for WJ WY iy jy ky Ty n j oj aj Pj WO
WK WZ iz jz kz Tz n k ok ak Pk WA
1 0 0 0 1 0 0 0 1 1
WN
Y WO
WA
T
P
X
Z
One more variation on finding H:
H = (Rotate so that the X-axis is aligned with T)
* ( Translate along the new t-axis by || T || (magnitude of T))
33
F o r w a r d K i n e m a t i c s
The Quest:
What is the position of the end
of the robotic arm?
Solution:
1. Geometric Approach
This might be the easiest solution for the simple situation. However, notice
that the angles are measured relative to the direction of the previous link. (The first link
is the exception. The angle is measured relative to it’s initial position.) For robots with
more links and whose arm extends into 3 dimensions the geometry gets much more
tedious.
2. Algebraic Approach
Involves coordinate transformations.
36
Example Problem:
You have a three link arm that starts out
aligned in the x-axis. Each link has lengths l1, l2, l3,
respectively. You tell the first one to move by 1 ,
and so on as the diagram suggests. Find the
Y3
Homogeneous matrix to get the position of the
yellow dot in the X0Y0 frame.
3
Y2 2 X3 3
2 X2
H = Rz( 1 ) * Tx1(l1) * Rz( 2 ) * Tx2(l2) * Rz( 3 )
i.e. Rotating by 1 will put you in the X1Y1 frame. Translate in the along
Y0
1 the X1 axis by l1.
Rotating by 2 will put you in the X2Y2 frame.
and so on until you are in the X3Y3 frame.
1
X0 The position of the yellow dot relative to the X3Y3 frame is
(l1, 0). Multiplying H by that position vector will give you the
coordinates of the yellow point relative the the X0Y0 frame.
37
Slight variation on the last solution:
Make the yellow dot the origin of a new
coordinate X4Y4 frame
Y3
Y4
3
Y2 2 X3 3
2 X2
X4
This takes you from the X0Y0 frame to the X4Y4 frame.
1
X0
The position of the yellow dot relative to the X4Y4 frame is (0,0).
X 0
Y 0
H Notice that multiplying by the (0,0,0,1) vector will equal
Z 0
the last column of the H matrix.
1 1
Applied in control
Revolute and
Finding :
Prismatic Joints
y
Combined θ arctan( )
x
More Specifically:
(x ,
y) y arctan2() specifies that it’s in the first
θ arctan 2( ) quadrant
x
Y
S
1 Finding S:
X
S (x 2 y 2 )
2
Find: 1, 2
l2 Redundancy:
A unique solution to this problem does
not exist. Notice, that using the ‚givens‛ two
solutions are possible.
l1
1 Sometimes no solution is possible.
(x ,
y)
44
The Geometric Solution
(x , y) Using the Law of Cosines:
l2
2
c2 a 2 b 2 2ab cos C
2 2
(x2 y 2 ) l1 l2 2l1l2 cos(180 θ 2 )
cos(180 θ 2 ) cos(θ 2 )
2 2
l1 x2 y 2 l1 l2
cos(θ 2 )
2l1l2
1
2 2
x2 y 2 l1 l2
Using the Law of Cosines: θ 2 arccos
sin B sin C 2l1l2
b c Redundant since could be in the first or
2
sinθ1 sin(180 θ 2 ) sin(θ 2 ) fourth quadrant.
l2 x 2 y2 x 2 y2
θ1 θ1 α Redundancy caused since 2 has two possible values
y
α arctan 2 l2 sin(θ 2 ) y
x θ1 arcsin arctan 2
x 2 y2 x
45
The Algebraic Solution
l2 c1 cosθ1
2
(x , y) c1 2 cos(θ 2 θ1 )
(1) x l1 c1 l2 c1 2
(2) y l1 s1 l2 sin1 2
l1 1 (3) θ θ1 θ 2
(1)2 (2) 2 x 2 y2
2 2 2 2 2 2 2
l1 c1 l2 (c1 2 ) 2l1l2 c1 (c1 2 ) l1 s1 l2 (sin1 2 ) 2 2l1l2 s1 (sin1 2 )
2 2
l1 l2 2l1l2 c1 (c1 2 ) s1 (sin1 2 )
2 2
l1 l2 2l1l2 c 2 Note :
Only Unknown
2 2 2 2 cos(a b) (cos a)(cosb) (sin a)(sin b)
x y l1 l2
θ2 arccos sin(a b) (cos a)(sin b) (cosb)(sin a)
2l1l2
46
Note :
cos(a b) (cosa)(cosb) (sin a)(sinb)
x l1 c1 l2 c1 2
l1 c1 l2 c1c 2 l2 s1s2
sin(a b) (cosa)(sinb) (cosb)(sin a)
c1 (l1 l2 c 2 ) s1 (l2 s2 )
We know what 2 is from the previous slide.
y l1 s1 l2 sin1 2
We need to solve for 1 . Now we have two
l1 s1 l2 s1c 2 l2 s 2 c1 equations and two unknowns (sin 1 and
c1 (l2 s 2 ) s1 (l1 l2 c 2 ) cos 1 )
x s1 (l 2 s 2 ) Substituting for c1 and simplifying many
c1
(l1 l 2 c 2 ) times
x s1 (l 2 s 2 )
y (l 2 s 2 ) s1 (l1 l2 c 2 ) Notice this is the law of cosines and can
(l1 l 2 c 2 )
be replaced by x2+ y2
1
x l2 s2 s1 (l12 l2 2 2l1l 2 c 2 )
(l1 l2 c 2 )
y(l1 l2 c 2 ) x l2 s2 y(l1 l2 c 2 ) x l2 s2
s1 2 2 θ1 arcsin
x y
x2 y2