You are on page 1of 18

Robotics

Lecture 3

Forward Kinematics

Emam Fathy

Department of Electrical and Control Engineering

email: emfmz@aast.edu

http://www.aast.edu/cv.php?disp_unit=346&ser=68525
1
Basic Rotation Matrices
– Rotation about x-axis with 
1 0 0 
Rot ( x, )  0 C  S 
0 S C 
– Rotation about y-axis with 
 C 0 S 
Rot ( y,  )   0 1 0 
 S 0 C 

– Rotation about z-axis with 


C  S 0
Pxyz  RPuvw Rot ( z ,  )   S C 0
 0 0 1
2
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
3
Example 4: finding a rotation matrix
 Find the rotation matrix for the following
operations: R  Rot ( y,  ) I Rot ( w,  ) Rot (u ,  )
3

Rotation  about OY axis


Rotation  about OW axis  C 0 S  C  S 0 1 0 0 
  0 1 0   S C 0 0 C  S 
Rotation  about OU axis - S 0 C   0 0 1 0 S C 
 CC SS  CSC CSS  SC 
Answer...   S CC  CS 

 SC SSC  CS CC  SSS 

Pre-multiply if rotate about the OXYZ axes


Post-multiply if rotate about the OUVW axes
Reference coordinate frame OXYZ 4
Body-attached frame O’uvw
Example
 Find the rotation matrix for the following
operations:
i - Rotation about Z axis by 45
ii - Rotation about V axis by 90
iii - Rotation about U axis by - 45
iv - Rotation about Y axis by 60

R  Rot ( y,60) Rot ( z ,45) Rot (v,90) Rot (u ,45)

5
Coordinate Transformations
Rotation and Translation
• 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}

Rotation of {B} with respect to {A}


Translation of the origin of {B} with respect to origin of {A} 6
Coordinate Transformations
• Two Special Cases
r  RB r  r
A P A B P A o'

1. Translation only
– Axes of {B} and {A} are
parallel A R  1
B

2. Rotation only
– Origins of {B} and {A}
are coincident A r o '  0

7
Homogeneous Representation
• Coordinate transformation from {B} to {A}
r  ARB B r P  Ar o'
A P

 A r P   A RB 
A o'
r  r 
B P

   
 1   013 1  1 
• Homogeneous transformation matrix
 RB r   R33 P31 
A A o' Rotation
matrix
TB  
A
 
 013 1   0 1  Position
vector
Scaling
8
Homogeneous Transformation
• Special cases
1. Translation
 I 33 r 
A o'
A
TB   
013 1 

2. Rotation

 A
RB 031 
A
TB   
 013 1 

9
Homogeneous Representation
• A frame in space (Geometric
Interpretation) P( px , p y , pz )
z
 R33 P31  a (z’)
F  
s(y’)
 0 1  n (X’)
y
 nx sx ax px 
n sy ay p y 
F  y
 nz sz az pz  x
 
0 0 0 1
Example 5: translation
• Translation along Z-axis with h:
z z P
P
w y
y
w v
v
x O, O’
u x
u h
O, O’

1 0 0 0  x  1 0 0 0  pu   pu 
0 1 0 0  y  0 1 0 0  pv   pv 
Trans ( z , h)     
0 0 1 h  z  0 
0 1 h pw    pw  h 
        
0 0 0 1  1  0 0 0 1  1   1  12
Example 6: rotation
• Rotation about the X-axis by θ
z
w
P v

y
u
x
1 0 0 0  x  1 0 0 0  pu 
0 C  S 0  y  0 C  S 0  pv 
Rot ( x, )    
0 S C 0  z  0 S C 0  p w 
      
0 0 0 1  1  0 0 0 1  1 
13
Homogeneous Transformation
• Composite Homogeneous Transformation
Matrix

• 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

14
Example 7: homogeneous transformation
• Find the homogeneous transformation matrix (T)
for the following operations:
Rot  about OX axis
Trans of n along OX axis
Trans d along OZ axis
Rot  about OZ axis

T  Tz , Tz ,d Tx ,nTx , I 44
C  S 0 0 1 0 0 0  1 0 0 n  1 0 0 0
 S C 0 0 0 1 0 0  0 1 0 0  0 C  S 0

 0 0 1 0  0 0 1 d  0 0 1 0   0 S C 0
    
 0 0 0 1  0 0 0 1  0 0 0 1  0 0 0 1
Homogeneous Transformation
Composite Homogeneous Transformation Matrix

z1 z2 y2

y1 x2
z0 0
A1 1
A2
y0
x1
0
A2  A1 A2
0 1

x0
?
i 1
Ai
16
Homogeneous Transformation
• Translation and Rotation a
s
1 0 0 d x   nx sx ax px  z a n
0 1 0 d y  n y sy ay p y  s
Fnew  
0 0 1 d z   nz sz az pz  n
   
0 0 0 1 0 0 0 1 y
 nx sx ax px  d x 
n sy ay p y  d y 
 y x
 nz sz az pz  d z 
 
0 0 0 1 
homogeneous transformation based on geometry
For the figure shown below, find the 4x4 homogeneous transformation matrices i 1 A
c i
and 0 Ai for i=1, 2, 3, 4, 5
z3
b y3 x3
z5 d
 nx sx ax px  x5
n s y a y p y 
y5 z4
F  y e

 nz sz az pz  a x4 y4 z2
  x2
0 0 0 1 z1 x1 y2
z0
y1
y0
x0
 1 0 0 0  0  1 0 b  0 1 0 b 
 0 0 1 e  c  0 0  1 a  d   1 0 0 e  c 
0
A1    1
A2    0
A2  
 0 1 0 a  d  1 0 0 0  0 0 1 0 
     
 0 0 0 1   0 0 0 1  0 0 0 1 
End of Lec

20

You might also like