35
Kinematics Pose (position and orientation) of a Rigid Body University of Bridgeport 1 Introduction to ROBOTICS

Kinematics Pose (position and orientation) of a Rigid Body

  • Upload
    mandel

  • View
    40

  • Download
    2

Embed Size (px)

DESCRIPTION

Introduction to ROBOTICS. Kinematics Pose (position and orientation) of a Rigid Body. University of Bridgeport. Representing Position (2D). (“column” vector). A vector of length one pointing in the direction of the base frame x axis. - PowerPoint PPT Presentation

Citation preview

Page 1: Kinematics  Pose (position and orientation)  of a Rigid Body

Kinematics Pose (position and orientation)

of a Rigid Body

University of Bridgeport

1

Introduction to ROBOTICS

Page 2: Kinematics  Pose (position and orientation)  of a Rigid Body

Representing Position (2D)

x

y

p

5

2

2

5p (“column” vector)

yxp ˆ2ˆ5

x A vector of length one pointing in the direction of the base frame x axis

A vector of length one pointing in the direction of the base frame y axis

y

2

Page 3: Kinematics  Pose (position and orientation)  of a Rigid Body

Representing Position: vectors

• The prefix superscript denotes the reference frame in which the vector should be understood

4

8

2

3

2

5pb 3

2a p

Same point, two different reference frames

p

5

2

b

ˆax

bx

by

ˆay

3

2

3

Page 4: Kinematics  Pose (position and orientation)  of a Rigid Body

Representing Position: vectors (3D)

x

y

z

right-handed coordinate frame

x

y

z

2

5

2

p

p

4

zyxp ˆ2ˆ5ˆ2 x A vector of length one pointing in the

direction of the base frame x axis

A vector of length one pointing in the direction of the base frame y axis

y

A vector of length one pointing in the direction of the base frame z axis

z

Page 5: Kinematics  Pose (position and orientation)  of a Rigid Body

pRp BB

AA

The rotation matrix

cossin

sincosB

AR

cossin

sincos1B

AA

B RR

ˆAx

ˆAy

ˆBx

ˆBy

pRp AA

BB

:To specify the coordinate vectors for the fame B with respect to frame A

BAR

p

5

ˆAx ˆBxθ: The angle between and

in anti clockwise direction

Page 6: Kinematics  Pose (position and orientation)  of a Rigid Body

The rotation matrix

1212 xBA

xBA

BA yxR

6

2 1 ˆ ˆcos sin .AB x A Ax x y

2 1 ˆ ˆsin cosAB x A Ay x y

ˆAx

ˆAy

ˆBx

ˆBy

Page 7: Kinematics  Pose (position and orientation)  of a Rigid Body

Useful formulas

1)(

.

)()(1

1

RDet

IRR

IRR

RRR

AB

BA

TAB

AB

BA

7

Page 8: Kinematics  Pose (position and orientation)  of a Rigid Body

10

10pB

Example 1

pRp BB

AA

30cos30sin

30sin30cosB

AR30

30

xA ˆ

yA ˆ

xB ˆ

yB ˆ

8

pfind A

2

3

2

12

1

2

3

BAR

13.6603

3.6603

10

10

2

3

2

12

1

2

3

PA

Page 9: Kinematics  Pose (position and orientation)  of a Rigid Body

10

10pA

Example 1

pRp AA

BB

30cos30sin

30sin30cosA

BR30

30

xA ˆ

yA ˆ

xB ˆ

yB ˆ

9

pfind B

2

3

2

12

1

2

3

ABR

3.6603

13.6603

10

10

2

3

2

12

1

2

3

PB

Page 10: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 1

1 BA

AB RR

30cos30sin

30sin30cosA

BR

10

30cos30sin

30sin30cosB

AR

Another Solution

ORT

BA

AB RR

Page 11: Kinematics  Pose (position and orientation)  of a Rigid Body

Basic Rotation Matrix– Rotation about x-axis with

CS

SCxRot

0

0

001

),(

x

z

y

v

wP

u

cossin

sincos

),(

wvz

wvy

ux

w

v

u

z

y

x

ppp

ppp

pp

p

p

p

xR

p

p

p

11

Page 12: Kinematics  Pose (position and orientation)  of a Rigid Body

Basic Rotation Matrices– Rotation about x-axis with

– Rotation about y-axis with

– Rotation about z-axis with

uvwxyz RPP

CS

SCxRotRx

0

0

001

),(,

0

010

0

),(,

CS

SC

yRotRy

100

0

0

),( ,

CS

SC

zRotRz

12

Page 13: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 2• 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.

)2,3,4(uvwp

2

964.4

598.0

2

3

4

100

05.0866.0

0866.05.0

)60,( uvwxyz pzRotp

13

Page 14: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 3• A point is the coordinate w.r.t. the

reference coordinate system, find the corresponding point w.r.t. the rotated OUVW coordinate system if it has been rotated 60 degree about OZ axis.

)2,3,4(xyza

uvwa

1

( ,60)

: ( ,60)

: ( , 60)

0.5 0.866 0 4 4.598

0.866 0.5 0 3 1.964

0 0 1 2 2

Tuvw xyz

uvw xyz

uvw xyz

p Rot z p

OR p Rot z p

OR p Rot z p

14

Page 15: Kinematics  Pose (position and orientation)  of a Rigid Body

Composite Rotation Matrix• A sequence of finite rotations

– matrix multiplications do not commute– rules:

• if rotating coordinate OUVW is rotating about principal axis of OXYZ frame, then Pre-multiply the previous (resultant) rotation matrix with an appropriate basic rotation matrix [rotation about fixed frame]

• 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 [rotation about current frame]

15

Page 16: Kinematics  Pose (position and orientation)  of a Rigid Body

Rotation with respect to Current Frame

16

BB

AA PRPC

CBB PRP

DD

CC PRP

DD

CC

BB

ADD

AA PRRRPRP

DB

BA

DA RRR

DC

CB

BA

DA RRRR

Page 17: Kinematics  Pose (position and orientation)  of a Rigid Body

17

Example 4• Find the rotation matrix for the following

operations:

Post-multiply if rotate about the current frame

Pre-multiply if rotate about the fixed frame

Rotation about Y axis

Rotation about current Z axis

Rotation about current X axis

SSSCCSCCSSCS

SCCCS

CSSSCCSCSSCC

CS

SCCS

SC

xRotzRotyRotR

0

0

001

100

0

0

C0S-

010

S0C

),(),(),(

Page 18: Kinematics  Pose (position and orientation)  of a Rigid Body

18

Example 5• Find the rotation matrix for the following

operations:

axis Y fixedabout Rotation

axis Zfixedabout Rotation

axis Xabout Rotation

SSSCCSCCSSCS

SCCCS

CSSSCCSCSSCC

CS

SCCS

SC

xRotzRotyRotR

0

0

001

100

0

0

C0S-

010

S0C

),(),(),(

Pre-multiply if rotate about the fixed frame

Post-multiply if rotate about the current frame

Page 19: Kinematics  Pose (position and orientation)  of a Rigid Body

19

Example 6• Find the rotation matrix for the following

operations:

axis X fixedabout Rotation

axis Ycurrent about Rotation

axis Zfixedabout Rotation

axis current Zabout Rotation

axis Xabout Rotation

Pre-multiply if rotate about the fixed frame

Post-multiply if rotate about the current frame

Page 20: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 6• Find the rotation matrix for the following

operations:

axis X fixedabout Rotation

axis Ycurrent about Rotation

axis Zfixedabout Rotation

axis current Zabout Rotation

axis Xabout Rotation

),(),(),(),(),( yRotzRotxRotzRotxRotR

20

Page 21: Kinematics  Pose (position and orientation)  of a Rigid Body

Quiz• Description of Roll Pitch Yaw• Find the rotation matrix for the following

operations:

X

Y

Z

axis{YAW} Zfixedabout Rotation

}axis{PITCH Y fixedabout Rotation

axis{ROLL} Xabout Rotation

21

Page 22: Kinematics  Pose (position and orientation)  of a Rigid Body

Answer

X

Y

Z

axis Zfixedabout Rotation

axis Y fixedabout Rotation

axis Xabout Rotation

CCSCS

CSSSCSCSSCCS

SSCSCSSCSSCC

CS

SCCS

SC

xRotyRotzRotR

0

0

001

C0S-

010

S0C

100

0

0

),(),(),(

22

Page 23: Kinematics  Pose (position and orientation)  of a Rigid Body

Coordinate Transformations• position vector of P in {B} is transformed to position vector of P in {A}

• description of frame{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} 23

Page 24: Kinematics  Pose (position and orientation)  of a Rigid Body

Homogeneous Representation• Coordinate transformation from {B} to {A}

Can be written as

'oA

pB

BA

PA rrRr

Position vector (3*1)

1310

R ABB

A

BA p

H

Rotation matrix (3*3)

24

PHP BB

AA

Page 25: Kinematics  Pose (position and orientation)  of a Rigid Body

Homogeneous Representation

Position vector of the origin of frame B wrt frame A (3*1)

1310

R ABB

A

BA p

H

Rotation matrix (3*3)

25

PHP BB

AA

1p

Ap

Ap

A

A

z

y

x

P

1p

Bp

Bp

B

B

z

y

x

P

Page 26: Kinematics  Pose (position and orientation)  of a Rigid Body

Homogeneous Transformation• Special cases

1. Translation

2. Rotation

10

0

31

13BA

BA RH

10 31

33AB

BA pIH

26

Page 27: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 7• Translation along Z-axis with h:

1000

100

0010

0001

),(h

hzTrans

111000

100

0010

0001

11

1

1

1

1

1

hp

p

p

p

p

p

hz

y

x

z

y

x

z

y

x

x

y

z P

xB

yBzB

O

hx

y

z

P

u

vw

O 27

Page 28: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 7• Translation along Z-axis with h:

111000

100

0010

0001

1

hp

p

p

p

p

p

hz

y

x

B

B

B

B

B

B

z

y

x

y

y

x

28

PHP BB

00

Page 29: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 8• Rotation about the X-axis by

1000

00

00

0001

),(

CS

SCxRot

11000

00

00

0001

11

1

1

z

y

x

p

p

p

CS

SC

z

y

x

29x

z

y

1y

1zP

1x

Page 30: Kinematics  Pose (position and orientation)  of a Rigid Body

Homogeneous Transformation

• Composite Homogeneous Transformation Matrix

• Rules:– Transformation (rotation/translation) w.r.t fixed

frame, using pre-multiplication– Transformation (rotation/translation) w.r.t

current frame, using post-multiplication

30

Page 31: Kinematics  Pose (position and orientation)  of a Rigid Body

Example 9• Find the homogeneous transformation matrix

(H) for the following operations:

:

axis OZabout ofRotation

axis OZ along d ofn Translatio

axis OX along a ofn Translatio

axis OXabout Rotation

Answer

,,,, xaxdzz RotTransTransRotH

1000

00

00

0001

1000

0100

0010

001

1000

100

0010

0001

1000

0100

00

00

CS

SC

a

d

CS

SC

31

Page 32: Kinematics  Pose (position and orientation)  of a Rigid Body

Remember those double-angle formulas…

sincoscossinsin

sinsincoscoscos

32

Page 33: Kinematics  Pose (position and orientation)  of a Rigid Body

333231

232221

131211

aaa

aaa

aaa

A

332313

322212

312111

aaa

aaa

aaaTA

333231

232221

131211

aaa

aaa

aaa

2

5p 25Tp

Review of matrix transpose

TTT BABA Important property:

33

Page 34: Kinematics  Pose (position and orientation)  of a Rigid Body

2221

1211

aa

aaA

2221

1211

bb

bbB

and matrix multiplication…

2222122121221121

2212121121121111

2221

1211

2221

1211

babababa

babababa

bb

bb

aa

aaAB

bab

baabababa T

y

xyxyyxx

Can represent dot product as a matrix multiply:

34

Page 35: Kinematics  Pose (position and orientation)  of a Rigid Body

HW

• Problems 2.10, 2.11, 2.12, 2.13, 2.14 ,2.15, 2.22, 2.24, 2.37, and 2.39

• Quiz next class

35