rtest.cpp
Go to the documentation of this file.
1 /*
2 ROBOOP -- A robotics object oriented package in C++
3 Copyright (C) 1996-2004 Richard Gourdeau and Etienne Lachance
4 
5 This library is free software; you can redistribute it and/or modify
6 it under the terms of the GNU Lesser General Public License as
7 published by the Free Software Foundation; either version 2.1 of the
8 License, or (at your option) any later version.
9 
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU Lesser General Public License for more details.
14 
15 You should have received a copy of the GNU Lesser General Public
16 License along with this library; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 
19 
20 Report problems and direct all questions to:
21 
22 Richard Gourdeau
23 Professeur Agrege
24 Departement de genie electrique
25 Ecole Polytechnique de Montreal
26 C.P. 6079, Succ. Centre-Ville
27 Montreal, Quebec, H3C 3A7
28 
29 email: richard.gourdeau@polymtl.ca
30 
31 -------------------------------------------------------------------------------
32 Revision_history:
33 
34 2004/07/01: Ethan Tira-Thompson
35  -Added support for newmat's use_namespace #define, using ROBOOP namespace
36 
37 2004/08/13: Etienne Lachance
38  -Modified robot initialisation matrix.
39 -------------------------------------------------------------------------------
40 */
41 
49 static const char rcsid[] = "$Id: rtest.cpp,v 1.15 2005/07/01 17:44:53 gourdeau Exp $";
51 
52 #include "robot.h"
53 #include "quaternion.h"
54 #include "precisio.h"
55 #include <fstream>
56 
57 #ifdef use_namespace
58 using namespace ROBOOP;
59 #endif
60 
62  {0, 0, 0, 0, M_PI/2.0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.35, 0, 0, 0,
63  0, 0, 0, 0.4318, 0, 0, 0, 0, 17.4, -0.3638, 0.006, 0.2275, 0.13, 0, 0, 0.524, 0, 0.539, 0,
64  0, 0, 0.15005, 0.0203, -M_PI/2.0, 0, 0, 0, 4.8, -0.0203, -0.0141, 0.07, 0.066, 0, 0, 0.086, 0, 0.0125, 0,
65  0, 0, 0.4318, 0.0, M_PI/2.0, 0, 0, 0, 0.82, 0, 0.019, 0, 0.0018, 0, 0, 0.0013, 0, 0.0018, 0,
66  0, 0, 0, 0.0, -M_PI/2.0, 0, 0, 0, 0.34, 0.0, 0.0, 0.0, 0.0003, 0.0, 0.0, 0.0004, 0.0, 0.0003, 0,
67  0, 0, 0, 0, 0, 0, 0, 0, 0.09, 0.0, 0.0, 0.032, 0.00015, 0.0, 0.0, 0.00015, 0.0, 0.00004, 0};
69  //joint_type, theta, d, a, alpha
70 {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.35, 0,
71  0, 0, 0, 0.0, -M_PI/2, 0, 0, 0, 17.4, 0.068, 0.006, -0.016, 0.13, 0, 0, 0.524, 0, 0.539, 0,
72  0, 0, -0.15005, 0.4318, 0, 0, 0, 0, 4.8, 0, -0.070, 0.014, 0.066, 0, 0, 0.0125, 0, 0.066, 0,
73  0, 0, -0.4318, 0.0203, -M_PI/2.0, 0, 0, 0, 0.82, 0.0, 0.0, -0.019, 0.0018, 0, 0, 0.0018, 0, 0.0013, 0,
74  0, 0, 0, 0, M_PI/2.0, 0, 0, 0, 0.34, 0, 0, 0.0, 0.0003, 0, 0, 0.0003, 0, 0.0004, 0,
75  0, 0, 0, 0, -M_PI/2, 0, 0, 0, 0.09, 0, 0, 0.032, 0.00015, 0, 0, 0.00015, 0, 0.00004, 0};
77  {200e-6, -62.6111, 1.48e-3, 0, // using + and - directions average
78  200e-6, 107.815, .817e-3, 0,
79  200e-6, -53.7063, 1.38e-3, 0,
80  33e-6, 76.0364, 71.2e-6, 0,
81  33e-6, 71.923, 82.6e-6, 0,
82  33e-6, 76.686, 36.7e-6, 0};
83 
85  {0.0, 0.0, 0.4120, 0.0, -M_PI/2, 0,0,0,9.29, 0.0, 0.0175, -0.1105, 0.276, 0.0, 0, 0.255, 0.0, 0.071,0,0,0,0,0,
86  0.0, 0.0, 0.1540, 0.0, M_PI/2.0, 0,0,0,5.01, 0.0, -1.054, 0.0, 0.108, 0.0, 0.0, 0.018, 0.0, 0.1,0,0,0,0,0,
87  1.0, -M_PI/2.0, 0.0, 0.0, 0.0, 0,0,0,4.25, 0.0, 0.0, -6.447, 2.51, 0.0, 0.0, 2.51, 0.0, 0.006,0,0,0,0,0,
88  0.0, 0.0, 0.0, 0.0, -M_PI/2.0, 0,0,0,1.08, 0.0, 0.092, -0.054, 0.002, 0.0, 0.0, 0.001, 0.0, 0.001,0,0,0,0,0,
89  0.0, 0.0, 0.0, 0.0, M_PI/2.0, 0,0,0,0.63, 0.0, 0.0, 0.566, 0.003, 0.0, 0.0, 0.003, 0.0, 0.0004,0,0,0,0,0,
90  0.0, 0.0, 0.2630, 0.0, 0.0, 0,0,0,0.51, 0.0, 0.0, 1.5540, 0.013, 0.0, 0.0, 0.013, 0.0, 0.0003,0,0,0,0,0};
91 
92 int main(void)
93 {
94  int i;
95  std::ifstream infile;
96  infile.open("source/test.txt");
97  if(!infile) {
98  cerr << "Cannot open file:";
99  cerr << "source/test.txt\n";
100  exit (1);
101  }
102  Matrix Test(4,4), p1(3,1);
103  Real a, eps = FloatingPointPrecision::Epsilon(); /* floating point eps */
104 
105  cout << "=====================================================\n";
106  cout << " ROBOOP -- A robotics object oriented package in C++ \n";;
107  cout << " TEST program \n";
108  cout << "=====================================================\n";
109  cout << "\n";
110  cout << "Machine epsilon = " << eps << endl;
111  eps *= 150.0;
112 
113  cout << "Testing translation : ";
114  Real ott[] = {1.0,2.0,3.0};
115  p1 << ott;
116  for(i = 1; i <= 4; i++) {
117  for(int j = 1; j <= 4; j++) {
118  infile >> Test(i,j);
119  }
120  }
121  a = (Test-trans(p1)).MaximumAbsoluteValue();
122  if(a > eps) {
123  cout << "Erreur = " << a << endl;
124  } else {
125  cout << "Ok" << endl;
126  }
127 
128  cout << "Testing rotx : ";
129  for(i = 1; i <= 4; i++) {
130  for(int j = 1; j <= 4; j++) {
131  infile >> Test(i,j);
132  }
133  }
134  a = (Test-rotx(M_PI/6)).MaximumAbsoluteValue();
135  if(a > eps) {
136  cout << "Erreur = " << a << endl;
137  } else {
138  cout << "Ok" << endl;
139  }
140 
141  cout << "Testing roty : ";
142  for(i = 1; i <= 4; i++) {
143  for(int j = 1; j <= 4; j++) {
144  infile >> Test(i,j);
145  }
146  }
147  a = (Test-roty(M_PI/6)).MaximumAbsoluteValue();
148  if(a > eps) {
149  cout << "Erreur = " << a << endl;
150  } else {
151  cout << "Ok" << endl;
152  }
153 
154  cout << "Testing rotz : ";
155  for(i = 1; i <= 4; i++) {
156  for(int j = 1; j <= 4; j++) {
157  infile >> Test(i,j);
158  }
159  }
160  a = (Test-rotz(M_PI/6)).MaximumAbsoluteValue();
161  if(a > eps) {
162  cout << "Erreur = " << a << endl;
163  } else {
164  cout << "Ok" << endl;
165  }
166 
167  cout << "Testing roll-pitch-yaw : ";
168  for(i = 1; i <= 4; i++) {
169  for(int j = 1; j <= 4; j++) {
170  infile >> Test(i,j);
171  }
172  }
173  a = (Test-rpy(p1)).MaximumAbsoluteValue();
174  if(a > eps) {
175  cout << "Erreur = " << a << endl;
176  } else {
177  cout << "Ok" << endl;
178  }
179 
180  cout << "Testing rotation around vector : ";
181  for(i = 1; i <= 4; i++) {
182  for(int j = 1; j <= 4; j++) {
183  infile >> Test(i,j);
184  }
185  }
186  a = (Test-rotk(M_PI/2,p1)).MaximumAbsoluteValue();
187  if(a > eps) {
188  cout << "Erreur = " << a << endl;
189  } else {
190  cout << "Ok" << endl;
191  }
192 
193  // R(z) with angle=pi/4.
194  cout << "Testing quaternion to rotation matrix : ";
195  for(i = 1; i <= 3; i++) {
196  for(int j = 1; j <= 3; j++) {
197  infile >> Test(i,j);
198  }
199  }
200  {
201  // quaternion from angle + vector
202  ColumnVector v(3); v(1)=v(2)=0.0; v(3)=1.0;
203  Quaternion q(M_PI/4, v);
204  a = (Test.SubMatrix(1,3,1,3)-q.R()).MaximumAbsoluteValue();
205  if(a > eps) {
206  cout << "Erreur = " << a << endl;
207  } else {
208  cout << "Ok" << endl;
209  }
210  }
211 
212  cout << "Testing quaternion to rotation matrix : ";
213  for(i = 1; i <= 3; i++) {
214  for(int j = 1; j <= 3; j++) {
215  infile >> Test(i,j);
216  }
217  }
218 
219  {
220  // quaternion from 4 parameters
221  Quaternion q(M_PI/4, M_PI/6, M_PI/8, 1);
222  q.unit();
223  a = (Test.SubMatrix(1,3,1,3)-q.R()).MaximumAbsoluteValue();
224  if(a > eps) {
225  cout << "Erreur = " << a << endl;
226  } else {
227  cout << "Ok" << endl;
228  }
229 
230  cout << "Testing quaternion to transformation matrix : ";
231  for(i = 1; i <= 4; i++) {
232  for(int j = 1; j <= 4; j++) {
233  infile >> Test(i,j);
234  }
235  }
236  a = (Test-q.T()).MaximumAbsoluteValue();
237  if(a > eps) {
238  cout << "Erreur = " << a << endl;
239  } else {
240  cout << "Ok" << endl;
241  }
242 
243  cout << "Testing rotation matrix to quaternion : ";
244  ColumnVector quat(4);
245  Quaternion qq(q.R());
246  Test = Matrix(4,1);
247  for(i = 1; i <= 4; i++) {
248  infile >> Test(i,1);
249  }
250  quat(1) = qq.s();
251  quat.SubMatrix(2,4,1,1) = qq.v();
252  a = (Test-quat).MaximumAbsoluteValue();
253  if(a > eps) {
254  cout << "Erreur = " << a << endl;
255  } else {
256  cout << "Ok" << endl;
257  }
258 
259  cout << "Testing transformation matrix to quaternion : ";
260  qq = Quaternion(q.T());
261  Test = Matrix(4,1);
262  for(i = 1; i <= 4; i++) {
263  infile >> Test(i,1);
264  }
265  quat(1) = qq.s();
266  quat.SubMatrix(2,4,1,1) = qq.v();
267  a = (Test-quat).MaximumAbsoluteValue();
268  if(a > eps) {
269  cout << "Erreur = " << a << endl;
270  } else {
271  cout << "Ok" << endl;
272  }
273  }
274 
275 
276  // ---------------------- R O B O T S -------------------------------------
277  Robot robot_DH;
278  mRobot robot_mDH;
279  Matrix initrob;
280  Matrix initrobm;
281  short dof;
282 
283  ColumnVector qr, q, qd, qdd;
284  ColumnVector Fext(3), Next(3);
285 
286  // Puma 560 in DH notation without motor
287  cout << "Testing Puma 560 (DH) forward kinematic : ";
288  Test = Matrix(4,4);
289  for(i = 1; i <= 4; i++) {
290  for(int j = 1; j <= 4; j++) {
291  infile >> Test(i,j);
292  }
293  }
294  initrob = Matrix(6,19);
295  initrobm = Matrix(6,4);
296  initrob << PUMA560_data_DH;
297  initrobm << PUMA560_motor;
298  robot_DH = Robot(initrob, initrobm);
299  dof = robot_DH.get_dof();
300  qr = ColumnVector(dof);
301  qr = M_PI/4.0;
302  robot_DH.set_q(qr);
303  a = (Test-robot_DH.kine()).MaximumAbsoluteValue();
304  if(a > eps) {
305  cout << "Erreur = " << a << endl;
306  } else {
307  cout << "Ok" << endl;
308  }
309 
310  cout << "Testing Puma 560 (DH) jacobian in base frame : ";
311  Test = Matrix(6,6);
312  for(i = 1; i <= 6; i++) {
313  for(int j = 1; j <= 6; j++) {
314  infile >> Test(i,j);
315  }
316  }
317  a = (Test-robot_DH.jacobian()).MaximumAbsoluteValue();
318  if(a > eps) {
319  cout << "Erreur = " << a << endl;
320  } else {
321  cout << "Ok" << endl;
322  }
323 
324  cout << "Testing Puma 560 (DH) jacobian in tool frame : ";
325  for(i = 1; i <= 6; i++) {
326  for(int j = 1; j <= 6; j++) {
327  infile >> Test(i,j);
328  }
329  }
330  a = (Test-robot_DH.jacobian(dof)).MaximumAbsoluteValue();
331  if(a > eps) {
332  cout << "Erreur = " << a << endl;
333  } else {
334  cout << "Ok" << endl;
335  }
336 
337  initrobm = Matrix(6,4);
338  initrobm = 0.0;
339  robot_DH = Robot(initrob,initrobm);
340  Test = Matrix(dof,1); Test = 0;
341  cout << "Testing Puma 560 (DH) torque : ";
342  for(i = 1; i <= dof; i++) {
343  infile >> Test(i,1);
344  }
345 
346  qd = qr;
347  qdd = qr;
348  a = (Test-robot_DH.torque(qr, qd, qdd)).MaximumAbsoluteValue();
349  if(a > eps) {
350  cout << "Erreur = " << a << endl;
351  } else {
352  cout << "Ok" << endl;
353  }
354 
355  cout << "Testing Puma 560 (DH) inertia : ";
356  Test = Matrix(6,6);
357  for(i = 1; i <= 6; i++) {
358  for(int j = 1; j <= 6; j++){
359  infile >> Test(i,j);
360  }
361  }
362  a = (Test-robot_DH.inertia(qr)).MaximumAbsoluteValue();
363  if(a > eps) {
364  cout << "Erreur = " << a << endl;
365  } else {
366  cout << "Ok" << endl;
367  }
368 
369  initrobm = Matrix(6,4);
370  initrobm << PUMA560_motor;
371  robot_DH = Robot(initrob,initrobm);
372  dof = robot_DH.get_dof();
373 
374  cout << "Testing Puma 560 (DH) motor, torque : ";
375  Test = Matrix(dof,1);
376  for(i = 1; i <= dof; i++) {
377  infile >> Test(i,1);
378  }
379  a = (Test-robot_DH.torque(qr, qd, qdd)).MaximumAbsoluteValue();
380  if(a > eps) {
381  cout << "Erreur = " << a << endl;
382  } else {
383  cout << "Ok" << endl;
384  }
385 
386  // Stanford in DH notation
387  cout << "Testing Stanford (DH) forward kinematic : ";
388  Test = Matrix(4,4);
389  for(i = 1; i <= 4; i++) {
390  for(int j = 1; j <= 4; j++) {
391  infile >> Test(i,j);
392  }
393  }
394  initrob = Matrix(6,23);
395  initrob << STANFORD_data_DH;
396  robot_DH = Robot(initrob);
397  dof = robot_DH.get_dof();
398  qr = ColumnVector(dof);
399  qr = M_PI/4.0;
400  robot_DH.set_q(qr);
401  a = (Test-robot_DH.kine()).MaximumAbsoluteValue();
402  if(a > eps) {
403  cout << "Erreur = " << a << endl;
404  } else {
405  cout << "Ok" << endl;
406  }
407 
408  cout << "Testing Stanford (DH) jacobian in base frame : ";
409  Test = Matrix(6,6);
410  for(i = 1; i <= 6; i++) {
411  for(int j = 1; j <= 6; j++) {
412  infile >> Test(i,j);
413  }
414  }
415  a = (Test-robot_DH.jacobian()).MaximumAbsoluteValue();
416  if(a > eps) {
417  cout << "Erreur = " << a << endl;
418  } else {
419  cout << "Ok" << endl;
420  }
421 
422  cout << "Testing Stanford (DH) jacobian in tool frame : ";
423  for(i = 1; i <= 6; i++) {
424  for(int j = 1; j <= 6; j++) {
425  infile >> Test(i,j);
426  }
427  }
428  a = (Test-robot_DH.jacobian(dof)).MaximumAbsoluteValue();
429  if(a > eps) {
430  cout << "Erreur = " << a << endl;
431  } else {
432  cout << "Ok" << endl;
433  }
434 
435  Test = Matrix(dof,1); Test = 0;
436  cout << "Testing Stanford (DH) torque : ";
437  for(i = 1; i <= dof; i++) {
438  infile >> Test(i,1);
439  }
440  a = (Test-robot_DH.torque(qr, qd, qdd)).MaximumAbsoluteValue();
441  if(a > eps) {
442  cout << "Erreur = " << a << endl;
443  } else {
444  cout << "Ok" << endl;
445  }
446 
447  cout << "Testing Stanford (DH) torque with load on link n: ";
448  Fext(1)=10; Fext(2)=5; Fext(3)=7;
449  Next(1)=11; Next(2)=22; Next(3)=33;
450  for(i = 1; i <= dof; i++) {
451  infile >> Test(i,1);
452  }
453  a = (Test-robot_DH.torque(qr, qd, qdd, Fext, Next)).MaximumAbsoluteValue();
454  if(a > eps) {
455  cout << "Erreur = " << a << endl;
456  } else {
457  cout << "Ok" << endl;
458  }
459 
460  cout << "Testing Stanford (DH) inertia : ";
461  Test = Matrix(6,6); Test = 0;
462  for(i = 1; i <= 6; i++) {
463  for(int j = 1; j <= 6; j++){
464  infile >> Test(i,j);
465  }
466  }
467  a = (Test-robot_DH.inertia(qr)).MaximumAbsoluteValue();
468  if(a > eps) {
469  cout << "Erreur = " << a << endl;
470  } else {
471  cout << "Ok" << endl;
472  }
473 
474  Test = Matrix(4,4);
475 
476  // ATTENTION J'AI CHANGE LES PARAMETRES DH DANS PUMA560AKD.M, j'ai ecris a P. Corke
477  // Puma 560 DH modified
478  cout << "Testing Puma 560 (mDH) forward kinematic : ";
479  for(i = 1; i <= 4; i++) {
480  for(int j = 1; j <= 4; j++) {
481  infile >> Test(i,j);
482  }
483  }
484  initrob = Matrix(6,19);
485  initrob << PUMA560_data_mDH;
486  initrobm = Matrix(6,4);
487  initrobm = 0.0;
488  robot_mDH = mRobot(initrob, initrobm);
489  dof = robot_mDH.get_dof();
490  qr = ColumnVector(dof);
491  qr = M_PI/4.0;
492  robot_mDH.set_q(qr);
493  a = (Test-robot_mDH.kine()).MaximumAbsoluteValue();
494  if(a > eps) {
495  cout << "Erreur = " << a << endl;
496  } else {
497  cout << "Ok" << endl;
498  }
499 
500  // faut revoir jacobian pour dernier link
501  cout << "Testing Puma 560 (mDH) jacobian in base frame : ";
502  Test = Matrix(6,6);
503  for(i = 1; i <= 6; i++) {
504  for(int j = 1; j <= 6; j++) {
505  infile >> Test(i,j);
506  }
507  }
508  a = (Test-robot_mDH.jacobian()).MaximumAbsoluteValue();
509  if(a > eps) {
510  cout << "Erreur = " << a << endl;
511  } else {
512  cout << "Ok" << endl;
513  }
514 
515  cout << "Testing Puma 560 (mDH) jacobian in tool frame : ";
516  for(i = 1; i <= 6; i++) {
517  for(int j = 1; j <= 6; j++) {
518  infile >> Test(i,j);
519  }
520  }
521  a = (Test-robot_mDH.jacobian(dof)).MaximumAbsoluteValue();
522  if(a > eps) {
523  cout << "Erreur = " << a << endl;
524  } else {
525  cout << "Ok" << endl;
526  }
527 
528  initrobm = Matrix(6,4);
529  initrobm = 0.0;
530  robot_mDH = mRobot(initrob,initrobm);
531 
532  cout << "Testing Puma 560 (mDH) torque : ";
533  Test = Matrix(dof,1);
534  for(i = 1; i <= dof; i++) {
535  infile >> Test(i,1);
536  }
537  a = (Test-robot_mDH.torque(qr, qd, qdd)).MaximumAbsoluteValue();
538  if(a > eps) {
539  cout << "Erreur = " << a << endl;
540  } else {
541  cout << "Ok" << endl;
542  }
543 
544  cout << "Testing Puma 560 (mDH) inertia : ";
545  Test = Matrix(6,6); Test = 0;
546  for(i = 1; i <= 6; i++) {
547  for(int j = 1; j <= 6; j++){
548  infile >> Test(i,j);
549  }
550  }
551  a = (Test-robot_mDH.inertia(qr)).MaximumAbsoluteValue();
552  if(a > eps) {
553  cout << "Erreur = " << a << endl;
554  } else {
555  cout << "Ok" << endl;
556  }
557 
558  cout << "Testing Puma 560 (mDH) motor, torque : ";
559  initrobm = Matrix(6,4);
560  initrobm << PUMA560_motor;
561  robot_mDH = mRobot(initrob,initrobm);
562  Test = Matrix(dof,1);
563  for(i = 1; i <= dof; i++) {
564  infile >> Test(i,1);
565  }
566  a = (Test-robot_mDH.torque(qr, qd, qdd)).MaximumAbsoluteValue();
567  if(a > eps) {
568  cout << "Erreur = " << a << endl;
569  } else {
570  cout << "Ok" << endl;
571  }
572 
573  cout << "Testing Puma 560 (mDH) motor, torque with load on link n: ";
574  Fext(1)=10; Fext(2)=5; Fext(3)=7;
575  Next(1)=11; Next(2)=22; Next(3)=33;
576  for(i = 1; i <= dof; i++) {
577  infile >> Test(i,1);
578  }
579  a = (Test-robot_mDH.torque(qr, qd, qdd, Fext, Next)).MaximumAbsoluteValue();
580  if(a > eps) {
581  cout << "Erreur = " << a << endl;
582  } else {
583  cout << "Ok" << endl;
584  }
585 
586  return(0);
587 }
Quaternion class definition.
Definition: quaternion.h:92
ReturnMatrix R() const
Rotation matrix from a unit quaternion.
Definition: quaternion.cpp:458
int get_dof() const
Return dof.
Definition: robot.h:240
DH notation robot class.
Definition: robot.h:340
Real PUMA560_data_mDH[]
Definition: rtest.cpp:68
virtual ReturnMatrix torque(const ColumnVector &q, const ColumnVector &qp, const ColumnVector &qpp)
Joint torque, without contact force, based on Recursive Newton-Euler formulation. ...
Definition: dynamics.cpp:135
static const char rcsid[]
RCS/CVS version.
Definition: rtest.cpp:50
ReturnMatrix trans(const ColumnVector &a)
Translation.
Definition: homogen.cpp:68
Robots class definitions.
ReturnMatrix rpy(const ColumnVector &a)
Roll Pitch Yaw rotation.
Definition: homogen.cpp:182
double Real
Definition: include.h:307
ReturnMatrix inertia(const ColumnVector &q)
Inertia of the manipulator.
Definition: dynamics.cpp:83
ReturnMatrix rotx(const Real alpha)
Rotation around x axis.
Definition: homogen.cpp:87
virtual ReturnMatrix torque(const ColumnVector &q, const ColumnVector &qp, const ColumnVector &qpp)
Joint torque, without contact force, based on Recursive Newton-Euler formulation. ...
Definition: dynamics.cpp:412
Quaternion & unit()
Normalize a quaternion.
Definition: quaternion.cpp:311
void set_q(const ColumnVector &q)
Set the joint position vector.
Definition: robot.cpp:1137
int main(void)
Definition: rtest.cpp:92
Modified DH notation robot class.
Definition: robot.h:389
Real MaximumAbsoluteValue(const BaseMatrix &B)
Definition: newmat.h:2111
const Real STANFORD_data_DH[]
Definition: rtest.cpp:84
ReturnMatrix rotz(const Real gamma)
Rotation around z axis.
Definition: homogen.cpp:127
const Real PUMA560_motor[]
Definition: rtest.cpp:76
The usual rectangular matrix.
Definition: newmat.h:625
FloatVector FloatVector * a
virtual ReturnMatrix jacobian(const int ref=0) const
Jacobian of mobile links expressed at frame ref.
Definition: robot.h:405
Quaternion class.
ReturnMatrix roty(const Real beta)
Rotation around x axis.
Definition: homogen.cpp:107
void kine(Matrix &Rot, ColumnVector &pos) const
Direct kinematics at end effector.
Definition: kinemat.cpp:92
GetSubMatrix SubMatrix(int fr, int lr, int fc, int lc) const
Definition: newmat.h:2146
static Real Epsilon()
Definition: precisio.h:231
Column vector.
Definition: newmat.h:1008
virtual ReturnMatrix jacobian(const int ref=0) const
Jacobian of mobile links expressed at frame ref.
Definition: robot.h:357
const Real PUMA560_data_DH[]
Definition: rtest.cpp:61
ReturnMatrix T() const
Transformation matrix from a quaternion.
Definition: quaternion.cpp:499
ReturnMatrix rotk(const Real theta, const ColumnVector &k)
Rotation around arbitrary axis.
Definition: homogen.cpp:149


kni
Author(s): Martin Günther
autogenerated on Fri Jun 7 2019 22:06:45