13 tree(tree_in), jnttojacsolver(tree),
14 J(Eigen::MatrixXd::Zero(6 * endpoints.size(), tree.getNrOfJoints())),
15 Wy(Eigen::MatrixXd::Identity(J.rows(),J.rows())),
16 Wq(Eigen::MatrixXd::Identity(J.cols(),J.cols())),
17 J_Wq(J.rows(),J.cols()),Wy_J_Wq(J.rows(),J.cols()),
18 U(Eigen::MatrixXd::Identity(J.rows(),J.cols())),
19 V(Eigen::MatrixXd::Identity(J.cols(),J.cols())),
20 Wy_U(J.rows(),J.rows()),Wq_V(J.cols(),J.cols()),
21 t(Eigen::VectorXd::Zero(J.rows())), Wy_t(Eigen::VectorXd::Zero(J.rows())),
22 qdot(Eigen::VectorXd::Zero(J.cols())),
23 tmp(Eigen::VectorXd::Zero(J.cols())),S(Eigen::VectorXd::Zero(J.cols())),
27 for (
size_t i = 0; i < endpoints.size(); ++i) {
51 for (Twists::const_iterator v_it = v_in.begin(); v_it != v_in.end(); ++v_it) {
61 for (Jacobians::iterator jac_it =
jacobians.begin(); jac_it
69 const Twist& twist=v_in.find(jac_it->first)->second;
70 t.segment(6*k,3) = Eigen::Map<const Eigen::Vector3d>(twist.vel.data);
71 t.segment(6*k+3,3) = Eigen::Map<const Eigen::Vector3d>(twist.rot.data);
87 Wq_V.noalias() = Wq *
V;
90 for (
unsigned int i = 0; i <
J.cols(); i++) {
92 for (
unsigned int j = 0; j <
J.rows(); j++) {
94 sum +=
U(j, i) *
Wy_t(j);
int JntToJac(const JntArray &q_in, Jacobian &jac, const std::string &segmentname)
void setWeightTS(const Eigen::MatrixXd &Mx)
TreeJntToJacSolver jnttojacsolver
virtual double CartToJnt(const JntArray &q_in, const Twists &v_in, JntArray &qdot_out)
unsigned int getNrOfJoints() const
This class represents an fixed size array containing joint values of a KDL::Chain.
virtual ~TreeIkSolverVel_wdls()
unsigned int rows() const
represents both translational and rotational velocities.
void setLambda(const double &lambda)
int svd_eigen_HH(const Eigen::MatrixXd &A, Eigen::MatrixXd &U, Eigen::VectorXd &S, Eigen::MatrixXd &V, Eigen::VectorXd &tmp, int maxiter, double epsilon)
TreeIkSolverVel_wdls(const Tree &tree, const std::vector< std::string > &endpoints)
Child SVD failed.
void setWeightJS(const Eigen::MatrixXd &Mq)
std::map< std::string, Twist > Twists
This class encapsulates a tree kinematic interconnection structure. It is built out of segments...
static const int E_SVD_FAILED