55 template <
class RBDDynamics, 
bool QUAT_INTEGRATION = false>
    59                               typename RBDDynamics::SCALAR>
    65     typedef typename RBDDynamics::SCALAR 
SCALAR;
    67     const static size_t N_EE = RBDDynamics::N_EE;
    68     const static size_t STATE_DIM = RBDDynamics::NSTATE + QUAT_INTEGRATION;
    76     ProjectedFDSystem(
typename RBDDynamics::EE_in_contact_t eeInContact = 
true) : eeInContact_(eeInContact){};
    80     virtual RBDDynamics& 
dynamics()
 override { 
return dynamics_; }
    81     virtual const RBDDynamics& 
dynamics()
 const override { 
return dynamics_; }
    84         const ControlVector& control,
    85         StateVector& derivative)
 override    88         typename RBDDynamics::RBDAcceleration_t xd;
    90         dynamics_.ProjectedForwardDynamics(eeInContact_, x, control, xd);
    91         derivative = toStateDerivative<QUAT_INTEGRATION>(xd, x);
    94     void setEEInContact(
typename RBDDynamics::EE_in_contact_t& eeInContact) { eeInContact_ = eeInContact; }
    97         return RBDStateFromVectorImpl<QUAT_INTEGRATION>(state);
   102         typename std::enable_if<T, bool>::type = 
true)
   105         x.fromStateVectorQuaternion(state);
   111         typename std::enable_if<!T, bool>::type = 
true)
   114         x.fromStateVectorEulerXyz(state);
   120         const typename RBDDynamics::RBDState_t& state,
   121         typename std::enable_if<T, bool>::type = 
true)
   123         return acceleration.toStateUpdateVectorQuaternion(state);
   128         const typename RBDDynamics::RBDState_t& state,
   129         typename std::enable_if<!T, bool>::type = 
true)
   131         return acceleration.toStateUpdateVectorEulerXyz(state);
   137         throw std::runtime_error(
"clone not implemented");
   141     typename RBDDynamics::EE_in_contact_t eeInContact_;
   143     RBDDynamics dynamics_;
 RBDDynamics::RBDState_t RBDStateFromVector(const StateVector &state)
Definition: ProjectedFDSystem.h:95
core::ControlledSystem< RBDDynamics::RBDState_t::NSTATE+QUAT_INTEGRATION, RBDDynamics::NJOINTS > Base
Definition: ProjectedFDSystem.h:74
StateVector toStateDerivative(const typename RBDDynamics::RBDAcceleration_t &acceleration, const typename RBDDynamics::RBDState_t &state, typename std::enable_if< T, bool >::type=true)
Definition: ProjectedFDSystem.h:119
static const size_t CONTROL_DIM
Definition: ProjectedFDSystem.h:69
Pose of a single rigid body. 
Definition: RigidBodyPose.h:29
RBDDynamics::RBDState_t RBDStateFromVectorImpl(const StateVector &state, typename std::enable_if< T, bool >::type=true)
Definition: ProjectedFDSystem.h:101
core::StateVector< STATE_DIM, SCALAR > StateVector
Definition: ProjectedFDSystem.h:71
core::ControlVector< CONTROL_DIM, SCALAR > ControlVector
Definition: ProjectedFDSystem.h:72
RBDDynamics Dynamics
Definition: ProjectedFDSystem.h:62
ProjectedFDSystem(typename RBDDynamics::EE_in_contact_t eeInContact=true)
Definition: ProjectedFDSystem.h:76
RBDDynamics::SCALAR SCALAR
Definition: ProjectedFDSystem.h:65
virtual ProjectedFDSystem< RBDDynamics, QUAT_INTEGRATION > * clone() const override
Definition: ProjectedFDSystem.h:135
ct::rbd::TestIrb4600::tpl::Kinematics< double > Kinematics_t
Definition: FixBaseIKTest.cpp:14
virtual void computeControlledDynamics(const StateVector &state, const SCALAR &t, const ControlVector &control, StateVector &derivative) override
Definition: ProjectedFDSystem.h:82
StateVector toStateDerivative(const typename RBDDynamics::RBDAcceleration_t &acceleration, const typename RBDDynamics::RBDState_t &state, typename std::enable_if<!T, bool >::type=true)
Definition: ProjectedFDSystem.h:127
This is a common interface class for an RBDSystem. 
Definition: RBDSystem.h:15
void setEEInContact(typename RBDDynamics::EE_in_contact_t &eeInContact)
Definition: ProjectedFDSystem.h:94
virtual RBDDynamics & dynamics() override
Definition: ProjectedFDSystem.h:80
ct::core::StateVector< state_dim > x
static const size_t STATE_DIM
Definition: ProjectedFDSystem.h:68
A floating base rigid body system that uses forward dynamics. The input vector is assumed to consist ...
Definition: ProjectedFDSystem.h:56
typename RBDDynamics::Kinematics_t Kinematics
Definition: ProjectedFDSystem.h:63
virtual ~ProjectedFDSystem()
Definition: ProjectedFDSystem.h:78
static const size_t N_EE
Definition: ProjectedFDSystem.h:67
RBDDynamics::RBDState_t RBDStateFromVectorImpl(const StateVector &state, typename std::enable_if<!T, bool >::type=true)
Definition: ProjectedFDSystem.h:110
virtual const RBDDynamics & dynamics() const override
Definition: ProjectedFDSystem.h:81