next up previous contents
Next: Example 3 Up: Examples presented in this Previous: Examples presented in this   Contents


Example 2

This example comes from a planar robotics problem. Let the end-effector of the robot be a triangle. Each vertex of this triangle is connected to the ground via a linear actuator whose extremity is fixed point. We know the lengths of the three linear actuators (50, 26, 25) and we want to determine the pose of the end-effector i.e. the location of the vertex $B_1$ and its orientation. We have therefore to solve a system of three equations in three unknowns.

The following Maple program enable to get the equations of this example.

 
with(linalg):
#location of the linear actuator on the ground
xa1:=0:ya1:=0:xa2:=10:ya2:=0:xa3:=3:ya3:=10:
#location of the linear actuator on the end-effector
xb1:=0;yb1:=0:xb2:=4:yb2:=0:xb3:=2:yb3:=2:
for i from 1 to 3 do
	OA.i:=array([xa.i,ya.i]):
	CBr.i:=array([xb.i,yb.i])
od:

rot:=array([[cos(teta),-sin(teta)],[sin(teta),cos(teta)]]):
for i from 1 to 3 do CB.i:=multiply(rot,CBr.i): od:
OC:=array([x,y]):
for i from 1 to 3 do
      AB.i:=evalm(OC-OA.i):
      AB.i:=evalm(AB.i+CB.i):
      ro.i:=dotprod(AB.i,AB.i,'orthogonal'):
      ro.i:=simplify(ro.i):
od:

eq1:=ro1-50:eq2:=ro2-26:eq3:=ro3-25:
The system admit the two solutions:

\begin{displaymath}
(5,5,0)~~~~~~~~~~~~(3.369707132, 6.216516219, -0.8067834380)
\end{displaymath}

Here we may use the general solving algorithm (section 2.3), the general solving algorithm with the gradient (section 2.4), the general solving algorithm with the gradient and Hessian (section 2.5).

These algorithms are implemented in the test program Test_Solve_General1, Test_Solve_Gradient_General1, Test_Solve_JH_General1



Jean-Pierre Merlet 2012-12-20