examples for sir john

profileZeelex
lecture_15.pdf

EET 477

Robotics

Lecture 15: 23Jul14

Objective:

 Introduce Linear Interpolation

 Use Linear Interpolation in trajectory generation

Warmup:

Given a manipulator with the following DH Parameters, determine the minimum holding torque required

for each joint if the maximum load capacity of the end effector is 25 kg.

[ 00 00 00 00

0 40 25 10 𝜃1 𝜃2 𝜃3 0

]

Solution:

For 𝜃1,

𝜏1⃗⃗ ⃗ = 𝑟1⃗⃗⃗ × 𝐹 = | 𝑖 𝑗 𝑘

75 0 0 0 0 −245

| = [0,18375,0]

|𝜏1⃗⃗ ⃗| = 18375 𝑁𝑚 For 𝜃2,

𝜏2⃗⃗ ⃗ = 𝑟2⃗⃗ ⃗ × 𝐹 = | 𝑖 𝑗 𝑘

35 0 0 0 0 −245

| = [0,8575,0]

|𝜏1⃗⃗ ⃗| = 8575 𝑁𝑚 For 𝜃3,

𝜏3⃗⃗ ⃗ = 𝑟3⃗⃗ ⃗ × 𝐹 = | 𝑖 𝑗 𝑘

10 0 0 0 0 −245

| = [0,2450,0]

|𝜏3⃗⃗ ⃗| = 2450 𝑁𝑚

Introduce linear interpolation

Linear interpolation is the process of approximating the point on the interior of two boundaries by

assuming a linear relation.

Can use the equation of the line between the boundaries, then select an “x” to determine the “y”

𝑦 − 𝑦0 𝑥 − 𝑥0

= 𝑦1 − 𝑦0 𝑥1 − 𝑥0

𝑥, 𝑦 = 𝑖𝑛𝑡𝑒𝑟𝑝𝑜𝑙𝑎𝑡𝑖𝑜𝑛 𝑝𝑜𝑖𝑛𝑡 𝑥0, 𝑦0 = 𝑖𝑛𝑖𝑡𝑖𝑎𝑙 𝑏𝑜𝑢𝑛𝑑𝑎𝑟𝑦

𝑥1, 𝑦1 = 𝑡𝑒𝑟𝑚𝑖𝑛𝑎𝑙 𝑏𝑜𝑢𝑛𝑑𝑎𝑟𝑦

Example:

Assume two points are located at [2,3] and [7,1]. Determine the coordinate of the point at 𝑥 = 5.

Solution:

𝑦 − 3

5 − 2 =

1 − 3

7 − 2 → 𝑦 = 1.8

To implement linear interpolation in matlab, can divide the line segment into a particular number of division.

This code segment divides the x and y range into 200 steps, then plots each step.

cla;

hold on; %retains plots between plot statements

grid on;

Workspace = 100;

axis([-1*Workspace,Workspace,-1*Workspace,Workspace,-1*Workspace,Workspace]); %defines

min_x, max_x, ...

view([0,0,15]); %defines point of view

[x_init,y_init]=ginput(1)

plot3([x_init x_init],[y_init y_init],[0 0],'r+')

[x_dest,y_dest]=ginput(1)

plot3([x_dest x_dest],[y_dest y_dest],[0 0],'r+')

for n = 0:200

x=n*(x_dest-x_init)/200+x_init;

y=n*(y_dest-y_init)/200+y_init;

plot([x x],[y y],'black','linewidth',4);

end

To implement linear interpolation in trajectory planning, we need to:

1. Determine the initial end effector location 2. Determine the destination of the end effector 3. Use linear interpolation to determine a series of steps between the initial location and destination 4. Use the CCD algorithm at each of these locations to determine the set of joint parameters needed to arrive

at the location.