Ravelin
PrismaticJoint.h
1 /****************************************************************************
2  * Copyright 2014 Evan Drumwright
3  * This library is distributed under the terms of the Apache V2.0 License
4  ****************************************************************************/
5 
6 #ifndef PRISMATICJOINT
7 #error This class is not to be included by the user directly. Use PrismaticJointd.h or PrismaticJointf.h instead.
8 #endif
9 
11 class PRISMATICJOINT : public virtual JOINT
12 {
13  public:
15  virtual void update_spatial_axes();
16  virtual void determine_q(VECTORN& q);
17  virtual boost::shared_ptr<const POSE3> get_induced_pose();
18  virtual const std::vector<SVELOCITY>& get_spatial_axes_dot();
19  virtual unsigned num_dof() const { return 1; }
20  virtual void evaluate_constraints(REAL C[]);
21  VECTOR3 get_axis() const { return _u; }
22  void set_axis(const VECTOR3& axis);
23  virtual void calc_constraint_jacobian(bool inboard, MATRIXN& Cq);
24  virtual void calc_constraint_jacobian_dot(bool inboard, MATRIXN& Cq);
25 
27  virtual bool is_singular_config() const { return false; }
28 
29  protected:
30 
33 
36 
39 
41  VECTOR3 _v1i, _v1j;
42 
45 
47  std::vector<SVELOCITY> _s_dot;
48 }; // end class
49 
virtual bool is_singular_config() const
Prismatic joint can never be in a singular configuration.
Definition: PrismaticJoint.h:27
virtual void calc_constraint_jacobian_dot(bool inboard, MATRIXN &Cq)
Computes the time derivative of the constraint Jacobian for this joint with respect to the given body...
virtual void update_spatial_axes()
Abstract method to update the local spatial axes.
virtual boost::shared_ptr< const POSE3 > get_induced_pose()
Abstract method to get the local transform for this joint.
std::vector< SVELOCITY > _s_dot
The time derivative of the spatial axis – should be zero vector 6x1.
Definition: PrismaticJoint.h:47
virtual void calc_constraint_jacobian(bool inboard, MATRIXN &Cq)
Computes the constraint Jacobian for this joint with respect to the given body.
A generic, possibly non-square matrix.
Definition: MatrixN.h:18
virtual void evaluate_constraints(REAL C[])
Evaluates the constraint equations for this joint.
VECTOR3 _v2
The joint axis on the outboard pose; vector specified in outboard pose frame.
Definition: PrismaticJoint.h:44
VECTOR3 _uj
Vector attached to outboard pose and initially orthogonal to joint axis; vector specified in outer po...
Definition: PrismaticJoint.h:38
VECTORN q
The position of this joint.
Definition: Joint.h:144
VECTOR3 _u
The axis of the joint (inboard pose frame)
Definition: PrismaticJoint.h:32
virtual const std::vector< SVELOCITY > & get_spatial_axes_dot()
Abstract method to get the spatial axes derivatives for this joint.
A generic N-dimensional floating point vector.
Definition: VectorN.h:16
VECTOR3 _ui
The vector from the inboard pose to the outboard pose in inboard pose frame.
Definition: PrismaticJoint.h:35
A three-dimensional floating point vector used for representing points and vectors in 3D with associa...
Definition: Vector3.h:15
Defines a bilateral constraint (a joint)
Definition: Joint.h:14
Defines a sliding joint.
Definition: PrismaticJoint.h:11
virtual void determine_q(VECTORN &q)
Abstract method to determine the value of Q (joint position) from current transforms.
virtual unsigned num_dof() const
Gets the number of degrees-of-freedom for this joint.
Definition: PrismaticJoint.h:19
VECTOR3 _v1i
Vectors orthogonal to the joint axis defined in the inboard pose.
Definition: PrismaticJoint.h:41