Orocos KDL
KDL::ChainJntToJacDotSolver Class Reference

Computes the Jacobian time derivative (Jdot) by calculating the partial derivatives regarding to a joint angle, in the Hybrid, Body-fixed or Inertial representation. More...

#include <chainjnttojacdotsolver.hpp>

Inheritance diagram for KDL::ChainJntToJacDotSolver:
KDL::SolverI

Public Member Functions

 ChainJntToJacDotSolver (const Chain &chain)
virtual ~ChainJntToJacDotSolver ()
virtual int JntToJacDot (const KDL::JntArrayVel &q_in, KDL::Twist &jac_dot_q_dot, int seg_nr=-1)
 Computes \( {}_{bs}\dot{J}^{ee}.\dot{q} \).
virtual int JntToJacDot (const KDL::JntArrayVel &q_in, KDL::Jacobian &jdot, int seg_nr=-1)
 Computes \( {}_{bs}\dot{J}^{ee} \).
int setLockedJoints (const std::vector< bool > &locked_joints)
void setHybridRepresentation ()
 JntToJacDot() will compute in the Hybrid representation (ref Frame: base, ref Point: end-effector).
void setBodyFixedRepresentation ()
 JntToJacDot() will compute in the Body-fixed representation (ref Frame: end-effector, ref Point: end-effector).
void setInertialRepresentation ()
 JntToJacDot() will compute in the Inertial representation (ref Frame: base, ref Point: base).
void setRepresentation (const int &representation)
 Sets the internal variable for the representation (with a check on the value).
virtual void updateInternalDataStructures ()
virtual const char * strError (const int error) const
Public Member Functions inherited from KDL::SolverI
 SolverI ()
 Initialize latest error to E_NOERROR.
virtual ~SolverI ()
virtual int getError () const
 Return the latest error.

Static Public Attributes

static const int E_JAC_DOT_FAILED = -100
static const int E_JACSOLVER_FAILED = -101
static const int E_FKSOLVERPOS_FAILED = -102
static const int HYBRID = 0
static const int BODYFIXED = 1
static const int INERTIAL = 2

Protected Member Functions

const Twist & getPartialDerivativeHybrid (const Jacobian &bs_J_ee, const unsigned int &joint_idx, const unsigned int &column_idx)
 Computes \( \frac{\partial {}_{bs}J^{i,ee}}{\partial q^{j}}.\dot{q}^{j} \).
const Twist & getPartialDerivativeBodyFixed (const Jacobian &ee_J_ee, const unsigned int &joint_idx, const unsigned int &column_idx)
 Computes \( \frac{\partial {}_{ee}J^{i,ee}}{\partial q^{j}}.\dot{q}^{j} \).
const Twist & getPartialDerivativeInertial (const Jacobian &bs_J_bs, const unsigned int &joint_idx, const unsigned int &column_idx)
 Computes \( \frac{\partial {}_{bs}J^{i,bs}}{\partial q^{j}}.\dot{q}^{j} \).
const Twist & getPartialDerivative (const Jacobian &J, const unsigned int &joint_idx, const unsigned int &column_idx, const int &representation)
 Computes \( \frac{\partial J^{i,ee}}{\partial q^{j}}.\dot{q}^{j} \).

Additional Inherited Members

Public Types inherited from KDL::SolverI
enum  {
  E_DEGRADED = +1 , E_NOERROR = 0 , E_NO_CONVERGE = -1 , E_UNDEFINED = -2 ,
  E_NOT_UP_TO_DATE = -3 , E_SIZE_MISMATCH = -4 , E_MAX_ITERATIONS_EXCEEDED = -5 , E_OUT_OF_RANGE = -6 ,
  E_NOT_IMPLEMENTED = -7 , E_SVD_FAILED = -8
}
Protected Attributes inherited from KDL::SolverI
int error
 Latest error, initialized to E_NOERROR in constructor.

Detailed Description

Computes the Jacobian time derivative (Jdot) by calculating the partial derivatives regarding to a joint angle, in the Hybrid, Body-fixed or Inertial representation.

This work is based on : Symbolic differentiation of the velocity mapping for a serial kinematic chain H. Bruyninckx, J. De Schutter doi:10.1016/0094-114X(95)00069-B

url : http://www.sciencedirect.com/science/article/pii/0094114X9500069B

Constructor & Destructor Documentation

◆ ChainJntToJacDotSolver()

KDL::ChainJntToJacDotSolver::ChainJntToJacDotSolver ( const Chain & chain)
explicit

◆ ~ChainJntToJacDotSolver()

virtual KDL::ChainJntToJacDotSolver::~ChainJntToJacDotSolver ( )
virtual

Member Function Documentation

◆ getPartialDerivative()

const Twist & KDL::ChainJntToJacDotSolver::getPartialDerivative ( const Jacobian & J,
const unsigned int & joint_idx,
const unsigned int & column_idx,
const int & representation )
protected

Computes \( \frac{\partial J^{i,ee}}{\partial q^{j}}.\dot{q}^{j} \).

Parameters
bs_J_bsThe Jacobian expressed in the base frame with the end effector as the reference point
joint_idxThe indice of the current joint (j in the formula)
column_idxThe indice of the current column (i in the formula)
representationThe representation (Hybrid,Body-fixed,Inertial) in which you want to get dJ/dqj .qdotj
Returns
Twist The twist representing dJi/dqj .qdotj

◆ getPartialDerivativeBodyFixed()

const Twist & KDL::ChainJntToJacDotSolver::getPartialDerivativeBodyFixed ( const Jacobian & ee_J_ee,
const unsigned int & joint_idx,
const unsigned int & column_idx )
protected

Computes \( \frac{\partial {}_{ee}J^{i,ee}}{\partial q^{j}}.\dot{q}^{j} \).

Parameters
bs_J_eeThe Jacobian expressed in the end effector frame with the end effector as the reference point
joint_idxThe indice of the current joint (j in the formula)
column_idxThe indice of the current column (i in the formula)
Returns
Twist The twist representing dJi/dqj .qdotj

◆ getPartialDerivativeHybrid()

const Twist & KDL::ChainJntToJacDotSolver::getPartialDerivativeHybrid ( const Jacobian & bs_J_ee,
const unsigned int & joint_idx,
const unsigned int & column_idx )
protected

Computes \( \frac{\partial {}_{bs}J^{i,ee}}{\partial q^{j}}.\dot{q}^{j} \).

Parameters
bs_J_eeThe Jacobian expressed in the base frame with the end effector as the reference point (default in KDL Jacobian Solver)
joint_idxThe index of the current joint (j in the formula)
column_idxThe index of the current column (i in the formula)
Returns
Twist The twist representing dJi/dqj .qdotj

◆ getPartialDerivativeInertial()

const Twist & KDL::ChainJntToJacDotSolver::getPartialDerivativeInertial ( const Jacobian & bs_J_bs,
const unsigned int & joint_idx,
const unsigned int & column_idx )
protected

Computes \( \frac{\partial {}_{bs}J^{i,bs}}{\partial q^{j}}.\dot{q}^{j} \).

Parameters
ee_J_eeThe Jacobian expressed in the base frame with the base as the reference point
joint_idxThe indice of the current joint (j in the formula)
column_idxThe indice of the current column (i in the formula)
Returns
Twist The twist representing dJi/dqj .qdotj

◆ JntToJacDot() [1/2]

virtual int KDL::ChainJntToJacDotSolver::JntToJacDot ( const KDL::JntArrayVel & q_in,
KDL::Jacobian & jdot,
int seg_nr = -1 )
virtual

Computes \( {}_{bs}\dot{J}^{ee} \).

Parameters
q_inCurrent joint positions and velocities
jdotThe jacobian time derivative in the configured representation (HYBRID, BODYFIXED or INERTIAL)
seg_nrThe final segment to compute
Returns
int 0 if no errors happened

◆ JntToJacDot() [2/2]

virtual int KDL::ChainJntToJacDotSolver::JntToJacDot ( const KDL::JntArrayVel & q_in,
KDL::Twist & jac_dot_q_dot,
int seg_nr = -1 )
virtual

Computes \( {}_{bs}\dot{J}^{ee}.\dot{q} \).

Parameters
q_inCurrent joint positions and velocities
jac_dot_q_dotThe twist representing Jdot*qdot
seg_nrThe final segment to compute
Returns
int 0 if no errors happened

◆ setBodyFixedRepresentation()

void KDL::ChainJntToJacDotSolver::setBodyFixedRepresentation ( )
inline

JntToJacDot() will compute in the Body-fixed representation (ref Frame: end-effector, ref Point: end-effector).

Returns
void

◆ setHybridRepresentation()

void KDL::ChainJntToJacDotSolver::setHybridRepresentation ( )
inline

JntToJacDot() will compute in the Hybrid representation (ref Frame: base, ref Point: end-effector).

Returns
void

◆ setInertialRepresentation()

void KDL::ChainJntToJacDotSolver::setInertialRepresentation ( )
inline

JntToJacDot() will compute in the Inertial representation (ref Frame: base, ref Point: base).

Returns
void

◆ setLockedJoints()

int KDL::ChainJntToJacDotSolver::setLockedJoints ( const std::vector< bool > & locked_joints)

◆ setRepresentation()

void KDL::ChainJntToJacDotSolver::setRepresentation ( const int & representation)

Sets the internal variable for the representation (with a check on the value).

Parameters
representationThe representation for Jdot : HYBRID,BODYFIXED or INERTIAL
Returns
void

◆ strError()

virtual const char * KDL::ChainJntToJacDotSolver::strError ( const int error) const
virtual

Return a description of the latest error

Returns
if error is known then a description of error, otherwise "UNKNOWN ERROR"

Reimplemented from KDL::SolverI.

◆ updateInternalDataStructures()

virtual void KDL::ChainJntToJacDotSolver::updateInternalDataStructures ( )
virtual

Update the internal data structures. This is required if the number of segments or number of joints of a chain/tree have changed. This provides a single point of contact for solver memory allocations.

Implements KDL::SolverI.

Member Data Documentation

◆ BODYFIXED

const int KDL::ChainJntToJacDotSolver::BODYFIXED = 1
static

◆ E_FKSOLVERPOS_FAILED

const int KDL::ChainJntToJacDotSolver::E_FKSOLVERPOS_FAILED = -102
static

◆ E_JAC_DOT_FAILED

const int KDL::ChainJntToJacDotSolver::E_JAC_DOT_FAILED = -100
static

◆ E_JACSOLVER_FAILED

const int KDL::ChainJntToJacDotSolver::E_JACSOLVER_FAILED = -101
static

◆ HYBRID

const int KDL::ChainJntToJacDotSolver::HYBRID = 0
static

◆ INERTIAL

const int KDL::ChainJntToJacDotSolver::INERTIAL = 2
static

The documentation for this class was generated from the following file: