Вы находитесь на странице: 1из 54

Robotics and Automation

Ch. 1: Introduction
Ch. 2 Craig & Ch. 1 Tsai
Description of position and orientation in 3D space
In order to describe the position and orientation of a body in space,
we will always attach a coordinate system, or frame, rigidly to the
object.

Robotics & Automation 2


©2019 by Roshdy Abo-Shanab
Manipulators consists of nearly rigid links which are
connected by joints that allow relative motion of the
neighboring links.
These joint are usually
instrumented with position
sensors, which allow the
relative position of neighboring
links to be measured.
At the end of the chain of links
that make up the manipulator
is the end-effector.
End-effector could be:
Gripper
Welding torch Kinematic equation describes the tool frame relative
Electromagnet to the base frame as a function of the joint variables
Etc..
Robotics & Automation 5
©2019 by Roshdy Abo-Shanab
Robotics & Automation 6
©2019 by Roshdy Abo-Shanab
Description of an orientation
In order to describe the orientation
of a body, we will attach a
coordinate system to the body and
then give a description of this
coordinate system relative to the
reference system.
Rotation matrix

Robotics & Automation 7


©2019 by Roshdy Abo-Shanab
The scalars 𝑟𝑖𝑗 can be obtained by noting that the components of any
vector are simply the projections of that vector onto the unit directions
of its reference frame.
Hence, each component of 𝐵𝐴𝑅 can be written as the dot product of a
pair of unit vectors:

The dot product of two unit vectors yields the cosine of the angle
between them, so it is clearly why the components of the rotation
matrices is often referred as direction cosines.
Robotics & Automation 8
©2019 by Roshdy Abo-Shanab
Robotics & Automation 9
©2019 by Roshdy Abo-Shanab
Rotation matrix about the principle axes of the
reference coordinate system

1 0 0 1 0 0
𝑅𝑥,𝛼 = 0 𝐶𝛼 −𝑆𝛼 𝑇
𝑅𝑥,𝛼 = 𝑅𝑥,−𝛼
𝑅𝑥,−𝛼 = 0 𝐶𝛼 𝑆𝛼
0 𝑆𝛼 𝐶𝛼 0 −𝑆𝛼 𝐶𝛼

𝐶𝜑 0 𝑆𝜑 𝐶𝜑 0 −𝑆𝜑 𝑇
𝑅𝑦,𝜑 = 𝑅𝑦,−𝜑
𝑅𝑦,𝜑 = 0 1 0 𝑅𝑦,−𝜑 = 0 1 0
−𝑆𝜑 0 𝐶𝜑 𝑆𝜑 0 𝐶𝜑

𝐶𝜃 −𝑆𝜃 0 𝐶𝜃 𝑆𝜃 0
𝑇
𝑅𝑧,𝜃 = 𝑆𝜃 𝐶𝜃 0 𝑅𝑧,−𝜃 = −𝑆𝜃 𝐶𝜃 0 𝑅𝑧,𝜃 = 𝑅𝑧,−𝜃
0 0 1 0 0 1

Robotics & Automation 10


©2019 by Roshdy Abo-Shanab
Description of a frame

: is the vector that locates the


origin of frame B.

The description of a frame


can be thought of as a position
vector and a rotation matrix.

Robotics & Automation 11


©2019 by Roshdy Abo-Shanab
Robotics & Automation 12
©2019 by Roshdy Abo-Shanab
Mapping: changing description from frame to frame
Mapping involving translated frames (only translation)
Mapping involving
translated frames, only
translation, corresponding
axes of each frame are
parallel to each other.

Robotics & Automation 13


©2019 by Roshdy Abo-Shanab
Mapping involving rotated frames (only rotation)

Robotics & Automation 14


©2019 by Roshdy Abo-Shanab
Robotics & Automation 15
©2019 by Roshdy Abo-Shanab
Mapping involving general frames (translation and rotation)
Very often, we know the description of a vector with respect to some
frame B and we would like to know its description with respect to
another frame A.

: is called homogeneous
transform
Robotics & Automation 16
©2019 by Roshdy Abo-Shanab
Robotics & Automation 17
©2019 by Roshdy Abo-Shanab
Robotics & Automation 18
©2019 by Roshdy Abo-Shanab
Robotics & Automation 19
©2019 by Roshdy Abo-Shanab
Robotics & Automation 20
©2019 by Roshdy Abo-Shanab
Robotics & Automation 21
©2019 by Roshdy Abo-Shanab
Robotics & Automation 22
©2019 by Roshdy Abo-Shanab
Robotics & Automation 23
©2019 by Roshdy Abo-Shanab
Robotics & Automation 24
©2019 by Roshdy Abo-Shanab
Consider all transforms are
known except
Then,

Two possible description


of are

Robotics & Automation 25


©2019 by Roshdy Abo-Shanab
The bolt frame relative
to the hand frame is
computed as:

Robotics & Automation 26


©2019 by Roshdy Abo-Shanab
Position,
Orientation,
and Location
of a Rigid
Body

Robotics & Automation 27


©2019 by Roshdy Abo-Shanab
Description of a position

Robotics & Automation 28


©2019 by Roshdy Abo-Shanab
Description of an Orientation
a. Direction cosines
representation

In order to describe the


orientation of a body,
we will attach a
coordinate system to
the body (moving
frame B) and then give
a description of this
coordinate system
relative to the reference
system (Fixed frame
A).
Robotics & Automation 29
©2019 by Roshdy Abo-Shanab
Rotation matrix

𝑢𝑥 𝑣𝑥 𝑤𝑥 𝑎11 𝑎12 𝑎13


𝐴 𝑤𝑦 = 𝑎21 𝑎22 𝑎23
𝑅𝐵 = 𝑢𝑦 𝑣𝑦
𝑢𝑧 𝑣𝑧 𝑤𝑧 𝑎31 𝑎32 𝑎33

𝐴
𝑅𝐵 is called the rotation matrix of the moving frame B with
respect to the fixed frame A.
The rotation matrix specifies the orientation of frame B
completely with respect to frame A.
The columns of a rotation matrix represents a three orthogonal
unit vectors of the moving coordinates expressed in the
fixed frame.
Therefore, the rotation matrix is orthogonal (orthonormal).
Robotics & Automation 30
©2019 by Roshdy Abo-Shanab
The orthogonality conditions can be stated as follows:

𝒖∙𝒖=1 𝒖𝟐 = 1
𝒗∙𝒗=1 𝒗𝟐 = 1
𝒘∙𝒘=1 𝒘𝟐 = 1

𝒖∙𝒗=0 𝒖𝑻 𝒗 = 0
𝒗∙𝒘=0 𝒗𝑻 𝒘 = 0
𝒘∙𝒖=0 𝒘𝑻 𝒖 = 0

𝒖×𝒗=𝒘 𝒗×𝒘=𝒖 𝒘×𝒖=𝒗

Robotics & Automation 31


©2019 by Roshdy Abo-Shanab
Using orthogonality conditions, it can be shown that:

𝐵
𝑅𝐴 = 𝐴𝑅𝐵𝑇 = 𝐴𝑅𝐵−1
𝐴
det 𝑅𝐵 = 1

𝐵 𝑇
𝒊
𝐴
𝑅𝐵 = 𝐴
𝒖 𝐴
𝒗 𝐴
𝒘 = 𝐵 𝒋𝑇
𝐵 𝑇
𝒌

Robotics & Automation 32


©2019 by Roshdy Abo-Shanab
Rotation matrices about the principle axes of the
reference coordinate system

𝑐𝜃 −𝑠𝜃 0
𝑅𝑧,𝜃 = 𝑠𝜃 𝑐𝜃 0
0 0 1

Robotics & Automation 33


©2019 by Roshdy Abo-Shanab
Rotation matrices about the principle axes of the
reference coordinate system

𝑐𝜃 −𝑠𝜃 0
𝑅𝑧,𝜃 = 𝑠𝜃 𝑐𝜃 0
0 0 1

1 0 0
𝑅𝑥,𝜓 = 0 𝑐𝜓 −𝑠𝜓
0 𝑠𝜓 𝑐𝜓

𝑐𝜑 0 𝑠𝜑
𝑅𝑦,𝜑 = 0 1 0
−𝑠𝜑 0 𝑐𝜑
Robotics & Automation 34
©2019 by Roshdy Abo-Shanab
Euler Angles Representations
Roll – Pitch - Yaw Angles

Robotics & Automation 35


©2019 by Roshdy Abo-Shanab
Roll – Pitch - Yaw Angles
Given the roll, pitch and yaw, we can compute the overall rotation
matrix from the above equation.
Also, given the rotation matrix, we can compute the equivalent roll-
pitch-yaw angles as follows:
𝜃 = sin−1 −𝑎31
𝜓 = Atan2 𝑎32 /𝑐𝜃, 𝑎33 /𝑐𝜃,

𝜙 = Atan2 𝑎21 /𝑐𝜃, 𝑎11 /𝑐𝜃,


Provided 𝑐𝜃 ≠ 0. sin−1 𝑥 is the arcsine function and Atan2(𝑥, 𝑦) is a
two-argument function that yields one unique solution for the angle.
Hence, corresponding to a given rotation matrix, there are generally
two solutions of the roll-pitch-yaw angles.
If 𝜃 = ±90𝑜 , the solution degenerate, for this special case, only the
sum and the difference of 𝜑 and 𝜓 can be computed.
Robotics & Automation 36
©2019 by Roshdy Abo-Shanab
w-u- w Euler Angles
Consider three successive rotations of the rigid body about the
coordinate axes of a moving frame.

The resulting rotation matrix can derived by a kinematic inversion,


that is, by considering the orientation of frame A with respect to
frame B. Under kinematic inversion, the coordinate axes of B are
considered as fixed. Robotics & Automation 37
©2019 by Roshdy Abo-Shanab
w-u- w Euler Angles (cont.)
𝐵
𝑅𝐴 −𝜙, −𝜃, −𝜓 = 𝐵𝑅𝐴 𝑤, −𝜓 𝐵
𝑅𝐴 𝑢, −𝜃 𝐵
𝑅𝐴 𝑤, −𝜙
𝐴 𝐵 −1
Since 𝑅𝐵 = 𝑅𝐴 and 𝐵𝑅𝐴−1 𝑤, −𝜙 = 𝐵𝑅𝐴 𝑤, 𝜙

Robotics & Automation 38


©2019 by Roshdy Abo-Shanab
w-u- w Euler Angles (cont.)
Given the w-u- w Euler angles , we can compute the overall rotation
matrix from the above equation.
Also, given the rotation matrix, we can compute the w-u- w Euler
angles as follows:
𝜃 = cos −1 𝑎33
𝜙 = Atan2 𝑎13 /𝑠𝜃, −𝑎23 /𝑠𝜃,

𝜓 = Atan2 𝑎31 /𝑠𝜃, 𝑎32 /𝑠𝜃,


Provided s𝜃 ≠ 0. When 𝜃 = 0 or 𝜃 = 180𝑜 , the solution of the
above equation degenerates. For this degenerated case, only the sum
or the difference ∅ and 𝜓 can be computed.

Robotics & Automation 39


©2019 by Roshdy Abo-Shanab
Robotics & Automation 40
©2019 by Roshdy Abo-Shanab
Robotics & Automation 41
©2019 by Roshdy Abo-Shanab
Robotics & Automation 42
©2019 by Roshdy Abo-Shanab
Euler’s Theorem:
The general displacement of a rigid body with some point
fixed is a rotation about some axis.

This unique axis of rotation is called the screw axis.

𝑎11 + 𝑎22 + 𝑎33 − 1


𝜃= cos −1
2

Robotics & Automation 43


©2019 by Roshdy Abo-Shanab
Also, if the elements of the rotation matrix are given, we can
calculate the angle of rotation by summing the diagonal elements:
𝑎11 + 𝑎22 + 𝑎33 − 1
𝜃= cos −1
2
The direction of the screw axis is obtained by taking the difference
between each pair of the two opposing off-diagonal elements:
𝑎32 − 𝑎23
𝑠𝑥 =
2 𝑠𝜃
𝑎13 − 𝑎31
𝑠𝑦 =
2 𝑠𝜃
𝑎21 − 𝑎12
𝑠𝑧 =
2 𝑠𝜃
Robotics & Automation 44
©2019 by Roshdy Abo-Shanab
Rotation matrices about the principle axes of the
reference coordinate system

𝑎11 = 𝑠𝑥2 − 1 1 − 𝑐𝜃 + 1
𝑠𝑥 = 𝑠𝑦 = 0, 𝑠𝑧 = 1 𝑎12 = 𝑠𝑥 𝑠𝑦 1 − 𝑐𝜃 − 𝑠𝑧 𝑠𝜃
𝑎13 = 𝑠𝑥 𝑠𝑧 1 − 𝑐𝜃 + 𝑠𝑦 𝑠𝜃
𝑐𝜃 −𝑠𝜃 0
𝑅𝑧,𝜃 = 𝑠𝜃 𝑐𝜃 0 𝑎21 = 𝑠𝑦 𝑠𝑥 1 − 𝑐𝜃 + 𝑠𝑧 𝑠𝜃
0 0 1
𝑎22 = 𝑠𝑦2 − 1 1 − 𝑐𝜃 + 1
𝑎23 = 𝑠𝑦 𝑠𝑧 1 − 𝑐𝜃 − 𝑠𝑥 𝑠𝜃
𝑎31 = 𝑠𝑧 𝑠𝑥 1 − 𝑐𝜃 − 𝑠𝑦 𝑠𝜃
𝑎32 = 𝑠𝑧 𝑠𝑦 1 − 𝑐𝜃 + 𝑠𝑥 𝑠𝜃
𝑎33 = 𝑠𝑧2 − 1 1 − 𝑐𝜃 + 1
Robotics & Automation 45
©2019 by Roshdy Abo-Shanab
Rotation matrices about the principle axes of the
reference coordinate system

𝑐𝜃 −𝑠𝜃 0
𝑅𝑧,𝜃 = 𝑠𝜃 𝑐𝜃 0 𝑠𝑥 = 𝑠𝑦 = 0, 𝑠𝑧 = 1
0 0 1

1 0 0
𝑅𝑥,𝜓 = 0 𝑐𝜓 −𝑠𝜓 𝑠𝑦 = 𝑠𝑧 = 0, 𝑠𝑥 = 1
0 𝑠𝜓 𝑐𝜓

𝑐𝜑 0 𝑠𝜑
𝑅𝑦,𝜑 = 0 1 0 𝑠𝑥 = 𝑠𝑧 = 0, 𝑠𝑦 = 1
−𝑠𝜑 0 𝑐𝜑
Robotics & Automation 46
©2019 by Roshdy Abo-Shanab
Description of a
Location of a rigid body
𝐴
𝑷 = 𝑂𝑃
𝐵
𝑷 = 𝑄𝑃
𝐴
𝒒 = 𝑂𝑄
𝐴
𝑷 = 𝑂𝑄 + 𝑄𝑃
𝐴 𝐴 𝐴 𝐵
𝑷 = 𝒒 + 𝑅𝐵 𝑷
Location means the position and orientation of the
frame attached to the body.
Robotics & Automation 47
©2019 by Roshdy Abo-Shanab
Homogeneous
Transformation
𝐴
𝑷 = 𝐴𝒒 + 𝐴𝑅𝐵 𝐵𝑷
𝐴෡ 𝐴 𝐵෡
𝑷 = 𝑇𝐵 𝑷
𝐴෡ 𝑇
𝑷 = 𝑝𝑥 𝑝𝑥 𝑝𝑥 1
𝐵෡ 𝑇
𝑷 = 𝑝𝑢 𝑝𝑣 𝑝𝑤 1
𝐴 𝐴
𝐴
𝑇𝐵 = 𝑅𝐵 𝒒
000 1

Robotics & Automation 48


©2019 by Roshdy Abo-Shanab
Homogeneous Transformation

𝐵෡ 𝐴 −1 𝐴 ෡
𝑷= 𝑇𝐵 𝑷

𝐴 𝑇 𝐴 𝑇𝐴
𝐴 −1
𝑇𝐵 = 𝑅𝐵 − 𝑅𝐵 𝒒
000 1

Robotics & Automation 49


©2019 by Roshdy Abo-Shanab
The term line vector refers to a vector that is dependent on its line of
action along with direction and magnitude.
Example: the effects of a force vector depend upon its line of action
or point of application, so it would then be considered a line vector.
A free vector refers to a vector that may be positioned anywhere in
space without loss or change of meaning, provided that the
magnitude and direction are preserved.

Velocity is a free vector, then

Robotics & Automation 50


©2019 by Roshdy Abo-Shanab
Then,
Do you know how?

Robotics & Automation 51


©2019 by Roshdy Abo-Shanab
Find 𝐵𝑇𝐶 and 𝐴𝑇𝐶

Robotics & Automation 52


©2019 by Roshdy Abo-Shanab
Homework
Chapter 1
Problems #: 4, 5, 7, 8, 10, 11.

Robotics & Automation 53


©2019 by Roshdy Abo-Shanab
Homework 1

2.1, 2.2, 2.4, 2.7, 2.12, 2.27, 2.28,


2.30, 2.32, 2.34, and 2.37

Matlab Homework:
2A-a, 2B-a, 2B-b, 2B-e.

Robotics & Automation 54


©2019 by Roshdy Abo-Shanab

Вам также может понравиться