#include <sobec/crocomplements/contact/contact1d.hpp>
Public Types | |
typedef crocoddyl::MathBaseTpl< Scalar > | MathBase |
typedef crocoddyl::ContactModel1DTpl< Scalar > | Base |
typedef ContactData1DTpl< Scalar > | Data |
typedef crocoddyl::StateMultibodyTpl< Scalar > | StateMultibody |
typedef MathBase::Vector2s | Vector2s |
typedef MathBase::Vector3s | Vector3s |
typedef MathBase::VectorXs | VectorXs |
typedef MathBase::Matrix3s | Matrix3s |
typedef MathBase::Matrix6s | Matrix6s |
Public Member Functions | |
ContactModel1DTpl (boost::shared_ptr< StateMultibody > state, const pinocchio::FrameIndex id, const Vector3s &xref, const std::size_t nu, const Vector2s &gains=Vector2s::Zero(), const Vector3MaskType &mask=Vector3MaskType::z, const pinocchio::ReferenceFrame ref=pinocchio::LOCAL) | |
Initialize the 1d contact model. More... | |
ContactModel1DTpl (boost::shared_ptr< StateMultibody > state, const pinocchio::FrameIndex id, const Vector3s &xref, const Vector2s &gains=Vector2s::Zero(), const pinocchio::ReferenceFrame ref=pinocchio::LOCAL) | |
Initialize the 1d contact model. More... | |
virtual | ~ContactModel1DTpl () |
virtual void | calc (const boost::shared_ptr< crocoddyl::ContactDataAbstractTpl< Scalar >> &data, const Eigen::Ref< const VectorXs > &x) |
Compute the 1d contact Jacobian and drift. More... | |
virtual void | calcDiff (const boost::shared_ptr< crocoddyl::ContactDataAbstractTpl< Scalar >> &data, const Eigen::Ref< const VectorXs > &x) |
Compute the derivatives of the 1d contact holonomic constraint. More... | |
virtual void | updateForce (const boost::shared_ptr< crocoddyl::ContactDataAbstractTpl< Scalar >> &data, const VectorXs &force) |
Convert the force into a stack of spatial forces. More... | |
virtual boost::shared_ptr< crocoddyl::ContactDataAbstractTpl< Scalar > > | createData (pinocchio::DataTpl< Scalar > *const data) |
Create the 1d contact data. More... | |
const Vector3s & | get_reference () const |
Return the reference frame translation. More... | |
const Vector2s & | get_gains () const |
Create the 1d contact data. More... | |
void | set_reference (const Vector3s &reference) |
Modify the reference frame translation. More... | |
void | set_type (const pinocchio::ReferenceFrame type) |
Modify pinocchio::ReferenceFrame. More... | |
const pinocchio::ReferenceFrame & | get_type () const |
Get pinocchio::ReferenceFrame. More... | |
void | set_mask (const Vector3MaskType mask) |
Modify contact 1D mask. More... | |
const Vector3MaskType & | get_mask () const |
Get contact 1D mask. More... | |
virtual void | print (std::ostream &os) const |
Print relevant information of the 1d contact model. More... | |
Public Attributes | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef _Scalar | Scalar |
typedef crocoddyl::ContactModel1DTpl<Scalar> sobec::newcontacts::ContactModel1DTpl< _Scalar >::Base |
typedef ContactData1DTpl<Scalar> sobec::newcontacts::ContactModel1DTpl< _Scalar >::Data |
typedef crocoddyl::MathBaseTpl<Scalar> sobec::newcontacts::ContactModel1DTpl< _Scalar >::MathBase |
typedef MathBase::Matrix3s sobec::newcontacts::ContactModel1DTpl< _Scalar >::Matrix3s |
typedef MathBase::Matrix6s sobec::newcontacts::ContactModel1DTpl< _Scalar >::Matrix6s |
typedef crocoddyl::StateMultibodyTpl<Scalar> sobec::newcontacts::ContactModel1DTpl< _Scalar >::StateMultibody |
typedef MathBase::Vector2s sobec::newcontacts::ContactModel1DTpl< _Scalar >::Vector2s |
typedef MathBase::Vector3s sobec::newcontacts::ContactModel1DTpl< _Scalar >::Vector3s |
typedef MathBase::VectorXs sobec::newcontacts::ContactModel1DTpl< _Scalar >::VectorXs |
sobec::newcontacts::ContactModel1DTpl< Scalar >::ContactModel1DTpl | ( | boost::shared_ptr< StateMultibody > | state, |
const pinocchio::FrameIndex | id, | ||
const Vector3s & | xref, | ||
const std::size_t | nu, | ||
const Vector2s & | gains = Vector2s::Zero() , |
||
const Vector3MaskType & | mask = Vector3MaskType::z , |
||
const pinocchio::ReferenceFrame | ref = pinocchio::LOCAL |
||
) |
Initialize the 1d contact model.
[in] | state | State of the multibody system |
[in] | id | Reference frame id of the contact |
[in] | xref | Contact position used for the Baumgarte stabilization |
[in] | nu | Dimension of the control vector |
[in] | gains | Baumgarte stabilization gains |
[in] | mask | Constraint 1D axis (default z) |
[in] | ref | Reference type of contact |
sobec::newcontacts::ContactModel1DTpl< Scalar >::ContactModel1DTpl | ( | boost::shared_ptr< StateMultibody > | state, |
const pinocchio::FrameIndex | id, | ||
const Vector3s & | xref, | ||
const Vector2s & | gains = Vector2s::Zero() , |
||
const pinocchio::ReferenceFrame | ref = pinocchio::LOCAL |
||
) |
Initialize the 1d contact model.
The default nu
is obtained from StateAbstractTpl::get_nv()
.
[in] | state | State of the multibody system |
[in] | id | Reference frame id of the contact |
[in] | xref | Contact position used for the Baumgarte stabilization |
[in] | gains | Baumgarte stabilization gains |
[in] | ref | Reference type of contact |
|
virtual |
|
virtual |
Compute the 1d contact Jacobian and drift.
[in] | data | 1d contact data |
[in] | x | State point \(\mathbf{x}\in\mathbb{R}^{ndx}\) |
[in] | u | Control input \(\mathbf{u}\in\mathbb{R}^{nu}\) |
|
virtual |
Compute the derivatives of the 1d contact holonomic constraint.
[in] | data | 1d contact data |
[in] | x | State point \(\mathbf{x}\in\mathbb{R}^{ndx}\) |
[in] | u | Control input \(\mathbf{u}\in\mathbb{R}^{nu}\) |
|
virtual |
Create the 1d contact data.
const crocoddyl::MathBaseTpl< Scalar >::Vector2s & sobec::newcontacts::ContactModel1DTpl< Scalar >::get_gains |
Create the 1d contact data.
const Vector3MaskType & sobec::newcontacts::ContactModel1DTpl< Scalar >::get_mask |
Get contact 1D mask.
const crocoddyl::MathBaseTpl< Scalar >::Vector3s & sobec::newcontacts::ContactModel1DTpl< Scalar >::get_reference |
Return the reference frame translation.
const pinocchio::ReferenceFrame & sobec::newcontacts::ContactModel1DTpl< Scalar >::get_type |
Get pinocchio::ReferenceFrame.
|
virtual |
Print relevant information of the 1d contact model.
[out] | os | Output stream object |
void sobec::newcontacts::ContactModel1DTpl< Scalar >::set_mask | ( | const Vector3MaskType | mask | ) |
Modify contact 1D mask.
void sobec::newcontacts::ContactModel1DTpl< Scalar >::set_reference | ( | const Vector3s & | reference | ) |
Modify the reference frame translation.
void sobec::newcontacts::ContactModel1DTpl< Scalar >::set_type | ( | const pinocchio::ReferenceFrame | type | ) |
Modify pinocchio::ReferenceFrame.
|
virtual |
Convert the force into a stack of spatial forces.
[in] | data | 1d contact data |
[in] | force | 1d force |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef _Scalar sobec::newcontacts::ContactModel1DTpl< _Scalar >::Scalar |