Introduction to Robotics
MEC281
Denavit–Hartenberg
Convention
(DH Convention)
Denavit–Hartenberg Convention
(DH Convention)
Frames Transformation α𝒊−𝟏 𝒂𝒊−𝟏 θ𝒊 𝒅𝒊
(Link)
0
1𝑇
1
2𝑇
𝑖−1
𝑖𝑇
𝑖 𝑇 : represents the homogeneous transformation matrix that holds the position and
𝑖−1
•
orientation,
0 𝑖−1
• 𝑖𝑇 = 01𝑇 12𝑇……… 𝑖𝑇
Assigning Z-axes
• Rotational Joint:
• Take the Z-axis to be the joint’s rotational axis
• Prismatic Joint:
• The Z-axis should point in the direction of translation
• For the end Effector:
• Z should point in the direction of the end effector approach
Assigning X-axes
القديمةz الجديدة عمودية ومتقاطعة مع الX الزم تكون ال •
• Case 1: 𝑍𝑖−1 and 𝑍𝑖 aren’t coplanar
• There is only one line possible for 𝑋𝑖 , which is the shortest line
from 𝑍𝑖−1 to 𝑍𝑖
• The 𝑥𝑖 (common line) is the shortest distance between 𝑍𝑖−1
and 𝑍𝑖
Assigning X-axes
• Case 2: 𝑍𝑖−1 and 𝑍𝑖 are parallel
• There are an infinite number of possibilities for 𝑋𝑖 from 𝑍𝑖−1 to 𝑍𝑖
• Usually easiest to choose an 𝑋𝑖 that passes through 𝑂𝑖−1 , so that
𝑑𝑖 = 0
• 𝑂𝑖 is the intersection of 𝑋𝑖 and 𝑍𝑖
• α𝑖 is always 0 for that case
Assigning X-axes
• Case 3: 𝑍𝑖−1 and 𝑍𝑖 are Intersected
• 𝑋𝑖 is normal to the plane of 𝑍𝑖−1 and 𝑍𝑖
• Positive direction of 𝑋𝑖 is arbitrary
• 𝑎𝑖 is always 0 for that case
Assigning Y-axes
• Right hand rule to know the Y-axis direction (DH convention
doesn’t use Y-axis)
Assigning Base Frame (World Frame)
• World Frame is arbitrary
Denavit–Hartenberg Convention
(DH Convention)
Frames α𝒊−𝟏 𝒂𝒊−𝟏 θ𝒊 𝒅𝒊
Transforma
tion (Link)
0
1𝑇
1
2𝑇
𝑖−1
𝑖𝑇
• 𝛼𝑖−1 : represents the link twist and defined as the rotation angle between z-axis of frame 𝑖 and
frame 𝑖 − 1 around x-axis of frame 𝑖,
• The angle from 𝑍𝑖 to 𝑍𝑖+1 measured about 𝑋𝑖 ,
الجديدةX-axis ولكن الدوران حول ال،) اللى بعدهاZ( ) والZ(• الزاوية بين ال
• 𝑎𝑖−1 : represents the link length and defined as the distance between the origin of frame 𝑖 − 1
and frame 𝑖 along the x-axis,
• The distance from 𝑍𝑖 to 𝑍𝑖+1 measured along 𝑋𝑖 (perpendicular distance)
الجديدةX-axis ولكن في اتجاه ال،) اللى بعدهاZ( ) والZ(• المسافة بين ال
Denavit–Hartenberg Convention
(DH Convention)
Frames α𝒊−𝟏 𝒂𝒊−𝟏 θ𝒊 𝒅𝒊
Transforma
tion (Link)
0
1𝑇
1
2𝑇
𝑖−1
𝑖𝑇
• 𝜃𝑖 :represents the joint angle and defined as the rotation angle between x-axis of frame 𝑖 and
frame 𝑖 − 1 around z-axis of frame 𝑖 − 1,
• The angle from 𝑋𝑖−1 to 𝑋𝑖 measured about 𝑍𝑖−1
القديمةZ-axis ولكن الدوران حول ال،) اللى بعدهاX( ) والX(• الزاوية بين ال
• 𝑑𝑖 :represents the link offset and defined as the distance between the origin of frame 𝑖 − 1 and
frame 𝑖 along the z-axis.
• The distance from 𝑋𝑖−1 to 𝑋𝑖 measured along 𝑍𝑖−1 (perpendicular distance)
القديمةZ-axis ولكن في اتجاه ال،) اللى بعدهاX( ) والX(• المسافة بين ال
SCARA Robot
https://www.youtube.com/watch?v=xyJDUyxwD2I&ab_channel=AngelaSodemann
SCARA Robot
• With a team obtain the DH Convention (you have 10 minutes)
Considered rotation motion before prismatic motion
SCARA Robot
SCARA Robot
Considered prismatic motion before rotation motion
Modified DH Convention
https://www.researchgate.net/publication/322713238_ANFIS_based_kinematic_analysis_of_a_4-DOFs_SCARA_robot
SCARA Robot
https://www.youtube.com/watch?v=0NZZgq9FrRA&ab_channel=NinadJangle
PUMA 560
https://www.youtube.com/watch?v=tjOhGqOHfhg&ab_channel=YvanBourquin
PUMA 560
PUMA 560
PUMA 560
PUMA 560
https://www.youtube.com/watch?v=tjOhGqOHfhg&ab_channel=YvanBourquin
PUMA 560
https://mr-iitkgp.vlabs.ac.in/exp/forward-kinematics/theory.html
PUMA 560
From Introductory robotics
PUMA 560
https://www.youtube.com/watch?app=desktop&v=VeCRh-t9hfM&ab_channel=AdapalaAcademy
Stanford Robotic Arm
https://www.youtube.com/watch?v=r4aNOM3IK7A&ab_channel=EmmanuelAyala
https://www.youtube.com/watch?v=CcNjG1VO0iA
Stanford Robotic Arm
Stanford Robotic Arm
Stanford Robotic Arm
https://www.youtube.com/watch?v=wNBM4EmRze8&ab_channel=EngineeringEducatorAcademy
Stanford Robotic Arm
https://www.researchgate.net/publication/220553251_Non-uniform_rational_B-spline-based_minimum_cost_trajectory_planning_for_autonomous_robots
Example
Example
Example
Previously Studied
A System of Linear Equations
• m: is the number of equations
• n: is the number of unknowns
• If m=n there is a unique (finite) solution
• If m<n there are infinite number of solutions
• If m>n there is no solution
A System of Linear Equations
• If m=n there is a unique solution
•a–b=5
• a + b = 10
• a=7.5 a unique solution
• b= 2.5 a unique solution
A System of Linear Equations
• If m<n there are infinite number of solutions
• a + b = 10
• Then may be a=10 & b=0
• Or a = 9.5 and b = 0.5,
• Or a=-20 and b=30, …………… infinity number of solutions
A System of Linear Equations
• If m>n there is no solution
• a = 10 & a = 5 there is no solution
• Or
a + b = 10
a – b = 15
-a + b = 100 ………. there is no solution
A system of Nonlinear Equations
• 𝑎𝑥 2 + 𝑏𝑥 + 𝑐 = 0
• Then there are two roots (solutions)
• number of dimensions = number of roots
Inverse Kinematics
Inverse Kinematics Methods
• Analytical Solution
• Geometric Solution (closed form)
• Algebraic Solution (used for low DOFs) (hard to obtain) (closed form)
• Numerical Solution and Iterative Solution
• Wrist Partitioning (6 DOF)
2-Link Planar Manipulator
• need to find θ1 and θ2
2-Link Planar Manipulator
• Geometric (Graphical) method
2
• 𝑃2 = 𝑥𝑒 + 𝑦𝑒 2 (1)
• 𝜃2 = 180 − 𝛼 (2)
• 𝑃2 = 𝐿1 2 + 𝐿2 2 − 2𝐿1 𝐿2 cos 𝛼
−1 𝐿1 2 +𝐿2 2 −𝑃2
• 𝛼= cos (3)
2𝐿1 𝐿2
• 𝜃1 = γ − 𝛽 (4)
𝑦𝑒
• γ= tan−1 (5)
𝑥𝑒
• 𝐿2 2 = 𝐿1 + 𝑃2 − 2𝐿1 𝑃 cos 𝛽
2
−1 𝐿1 2 +𝑃2 −𝐿2 2
• 𝛽= cos (6)
2𝐿1 𝑃
2-Link Planar Manipulator
2-Link Planar Manipulator
(Algebraic Solution)
• 𝑥𝑒 = 𝐿1 cos θ1 + 𝐿2 cos θ1 + θ2
• 𝑦𝑒 = 𝐿1 sin θ1 + 𝐿2 sin θ1 + θ2
• ∵ cos θ1 + θ2 = cos θ1 cos θ2 − sin θ1 sin θ2
• ∵ sin θ1 + θ2 = sin θ1 cos θ2 + cos θ1 sin θ2
• 𝑥𝑒 = 𝐿1 cos θ1 + 𝐿2 cos θ1 cos θ2 − 𝐿2 sin θ1 sin θ2
• 𝑦𝑒 = 𝐿1 sin θ1 + 𝐿2 sin θ1 cos θ2 + 𝐿2 cos θ1 sin θ2
2-Link Planar Manipulator
• 𝑥𝑒 = 𝐿1 cos θ1 + 𝐿2 cos θ1 cos θ2 − 𝐿2 sin θ1 sin θ2 (1)
• 𝑦𝑒 = 𝐿1 sin θ1 + 𝐿2 sin θ1 cos θ2 + 𝐿2 cos θ1 sin θ2 (2)
• To solve these equations
first square equation (1) and add it to the square of equation (2)
𝑥𝑒 2 + 𝑦𝑒 2 = 𝐿1 2 cos θ1 2 + sin θ1 2
+𝐿2 2 cos θ1 2 + sin θ1 2 cos θ2 2
+𝐿2 2 cos θ1 2 + sin θ1 2 sin θ2 2
+2𝐿1 𝐿2 cos θ1 2 + sin θ1 2 cos θ2
2-Link Planar Manipulator
• 𝑥𝑒 2 + 𝑦𝑒 2 = 𝐿1 2 cos θ1 2 + sin θ1 2 + 𝐿2 2 cos θ1 2 + sin θ1 2 cos θ2 2 +
+ 𝐿2 2 cos θ1 2 + sin θ1 2 sin θ2 2 + 2𝐿 𝐿
1 2 cos θ1
2 + sin θ
1
2 cos θ
2
• ∵ cos θ1 2 + sin θ1 2 =1 (3)
• ∵ cos θ2 2 + sin θ 2 =1 (4)
2
• 𝑥𝑒 2 + 𝑦𝑒 2 = 𝐿1 2 + 𝐿2 2 + 2𝐿1 𝐿2 cos θ2 …….. This is the cosine rule
1
• cos θ2 = 𝑥𝑒 2 + 𝑦𝑒 2 − 𝐿1 2 + 𝐿2 2 =
2𝐿1 𝐿2
2-Link Planar Manipulator
1
• = 𝑥𝑒 2 + 𝑦𝑒 2 − 𝐿1 2 + 𝐿2 2 = cos θ2
2𝐿1 𝐿2
• From equation (4)
• ∵ cos θ2 2 + sin θ2 2 =1 (4)
• sin θ2 2 = 1 − cos θ2 2 = 1 − 2
• sin θ2 = ± 1 − 2
• From here there are two possible solutions
± 1 − 2
θ2 = tan−1
2-Link Planar Manipulator
• Let's find cos θ1 and sin θ1
• حلل ال 𝑒𝑥 وال 𝑒𝑦 على األحمر
𝑥𝑒 cos θ1 + 𝑦𝑒 sin θ1 = 𝐿1 + 𝐿2 cos θ2
𝑥𝑒 cos θ1 + 𝑦𝑒 sin θ1 = 𝐿1 + 𝐿2 (5)
• حلل ال 𝑒𝑥 وال 𝑒𝑦 على األصفر
𝑥𝑒 −sin θ1 + 𝑦𝑒 cos θ1 = 𝐿2 sin θ2
−𝑥𝑒 sin θ1 + 𝑦𝑒 cos θ1 = ±𝐿2 1 − 2 (6)
2-Link Planar Manipulator
• 𝑥𝑒 cos θ1 + 𝑦𝑒 sin θ1 = 𝐿1 + 𝐿2 (5)
• −𝑥𝑒 sin θ1 + 𝑦𝑒 cos θ1 = ±𝐿2 1 − 2 (6)
• Multiply equation 5 * 𝑥𝑒 then add the multiply of equation 6 * 𝑦𝑒
• Eq)5( ∗𝑥𝑒 + Eq)6( ∗𝑦𝑒
𝑥𝑒 2 cos θ1 + 𝑦𝑒 2 cos θ1 = 𝑥𝑒 𝐿1 + 𝐿2 ± 𝑦𝑒 𝐿2 1 − 2
1
cos θ1 = 𝑥𝑒 𝐿1 + 𝐿2 ± 𝑦𝑒 𝐿2 1 − 2
𝑥𝑒 2 +𝑦𝑒 2
2-Link Planar Manipulator
• 𝑥𝑒 cos θ1 + 𝑦𝑒 sin θ1 = 𝐿1 + 𝐿2 (5)
• −𝑥𝑒 sin θ1 + 𝑦𝑒 cos θ1 = ±𝐿2 1 − 2 (6)
Multiply equation 5*𝑦𝑒 then subtract the multiply of equation 6*𝑥𝑒
Eq)5( ∗𝑦𝑒 + Eq)6( ∗𝑥𝑒
𝑥𝑒 2 sin θ1 + 𝑦𝑒 2 sin θ1 = 𝑦𝑒 𝐿1 + 𝐿2 ± 𝑥𝑒 𝐿2 1 − 2
1
sin θ1 = ±𝑥𝑒 𝐿2 1 − 2 + 𝑦𝑒 𝐿1 + 𝐿2
𝑥𝑒 2 +𝑦𝑒 2
±𝑥𝑒 𝐿2 1 − 2 + 𝑦𝑒 𝐿1 + 𝐿2
θ1 = tan−1
𝑥𝑒 𝐿1 + 𝐿2 ± 𝑦𝑒 𝐿2 1 − 2
2-Link Planar Manipulator
• The following equations are the inverse kinematics
1
cos θ1 = 2 2
𝑥𝑒 𝐿1 + 𝐿2 ± 𝑦𝑒 𝐿2 1 − 2
𝑥𝑒 + 𝑦𝑒
1
sin θ1 = 2 2
±𝑥𝑒 𝐿2 1 − 2 + 𝑦𝑒 𝐿1 + 𝐿2
𝑥𝑒 + 𝑦𝑒
1
cos θ2 = 𝑥𝑒 2 + 𝑦𝑒 2 − 𝐿1 2 + 𝐿2 2 =
2𝐿1 𝐿2
sin θ2 = ± 1 − 2
Posture
• For the 2-link planar manipulator there are generally two
solutions for the inverse kinematics
• They arise from the sign of term sin θ2 = ± 1 − 2
• Physically this means there are two ways of reaching any point
in the plane
• Elbow up and elbow down
• However not every point (𝑥𝑒 , 𝑦𝑒 ) has two postures
Posture
Case 1: = ±1
• sin θ2 = ± 1 − 2 = 0
• This means there is only one solution
• θ2 = 0 or θ2 = π
Posture
Case 1: = ±1
1
• For = 1 = cos θ2 = 𝑥𝑒 2 + 𝑦𝑒 2 − 𝐿1 2 + 𝐿2 2
2𝐿1 𝐿2
𝑥𝑒 2 + 𝑦𝑒 2 = 𝐿1 + 𝐿2 𝟐
---> equation of a circle with radius = 𝐿1 + 𝐿2
Means the arm is fully stretched
Posture
Case 1: = ±1
1
• For = −1 = cos θ2 = 𝑥𝑒 2 + 𝑦𝑒 2 − 𝐿1 2 + 𝐿2 2
2𝐿1 𝐿2
𝑥𝑒 2 + 𝑦𝑒 2 = 𝐿1 − 𝐿2 𝟐
---> equation of a circle with radius = 𝐿1 − 𝐿2
Means the second link is double back on itself
Posture
• Singular points: is points where the robot loses one or more
DOF
• On the boundary of the workspace the arm has no freedom to
move in a radial direction
• In other mean, it loses its DOFs
Posture
• Case 2: 𝐿1 = 𝐿2
• The length of the 𝐿1 & 𝐿2 doesn’t affect posters except in some
special cases like 𝐿1 − 𝐿2
• The inner circle shrunk to a point
Assignment
• For a 2-link planar manipulator 𝐿1 = 2 units & 𝐿2 = 1 unit
• The required position of the end effector 𝑥𝑒 = 3 & 𝑦𝑒 = 2
• Find the joint variables (postures) describing this motion