Bug description
- The method pose_jacobian() of DQ_HolonomicBase is giving a runtime error saying that it tried to access link index 3.
To Reproduce
Code
import numpy as np
from dqrobotics.robot_modeling import DQ_HolonomicBase
q = np.array([0.12, 0.0, 0.0])
holonomic_base = DQ_HolonomicBase()
J = holonomic_base.pose_jacobian(q)
print(J)
Output
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
RuntimeError: Tried to access link index 3 which is unavailable.
Expected behavior
- The code should return a jacobian matrix as in the following matlab code
Matlab code
q = [0.12 0 0];
robot = DQ_HolonomicBase();
J_pose = robot.pose_jacobian(q)
Matlab output
J_pose =
0 0 0
0 0 0
0 0 0
0 0 0.5000
0 0 0
0.5000 0 0
0 0.5000 0.0300
0 0 0
Environment:
- OS: Ubuntu 18.04
- dqrobotics version 20.4.0.17
- Python version 3.6.9
Additional context
- Since the Python code depend on the C++ code, I believe there is a problem on line 64 of the DQ_HolonomicBase.cpp. I would guess it should be
if(to_link > 3 || to_link < 0)
because of the dimension of the configuration space of the holonomic base.
Bug description
To Reproduce
Code
Output
Expected behavior
Matlab code
Matlab output
Environment:
Additional context
because of the dimension of the configuration space of the holonomic base.