Template Class ContactModelAbstractTpl
Defined in File contact-base.hpp
Inheritance Relationships
Base Type
public crocoddyl::ContactModelBase(Class ContactModelBase)
Derived Types
public crocoddyl::ContactModel1DTpl< _Scalar >(Template Class ContactModel1DTpl)public crocoddyl::ContactModel2DTpl< _Scalar >(Template Class ContactModel2DTpl)public crocoddyl::ContactModel3DTpl< _Scalar >(Template Class ContactModel3DTpl)public crocoddyl::ContactModel6DTpl< _Scalar >(Template Class ContactModel6DTpl)public crocoddyl::ContactModelNumDiffTpl< _Scalar >(Template Class ContactModelNumDiffTpl)
Class Documentation
-
template<typename _Scalar>
class ContactModelAbstractTpl : public crocoddyl::ContactModelBase Subclassed by crocoddyl::ContactModel1DTpl< _Scalar >, crocoddyl::ContactModel2DTpl< _Scalar >, crocoddyl::ContactModel3DTpl< _Scalar >, crocoddyl::ContactModel6DTpl< _Scalar >, crocoddyl::ContactModelNumDiffTpl< _Scalar >
Public Types
-
typedef MathBaseTpl<Scalar> MathBase
-
typedef ContactDataAbstractTpl<Scalar> ContactDataAbstract
-
typedef StateMultibodyTpl<Scalar> StateMultibody
Public Functions
Initialize the contact abstraction.
- Parameters:
state – [in] State of the multibody system
type – [in] Type of contact
nc – [in] Dimension of the contact model
nu – [in] Dimension of the control vector
- DEPRECATED ("Use constructor that passes the type type of contact, this assumes is " "pinocchio::LOCAL", ContactModelAbstractTpl(std::shared_ptr< StateMultibody > state, const std::size_t nc, const std::size_t nu);) DEPRECATED("Use const ructor that passes the type type of contact
- this assumes is ContactModelAbstractTpl (std::shared_ptr< StateMultibody > state, const std::size_t nc)
-
virtual ~ContactModelAbstractTpl() = default
Compute the contact Jacobian and acceleration drift.
- Parameters:
data – [in] Contact data
x – [in] State point \(\mathbf{x}\in\mathbb{R}^{ndx}\)
u – [in] Control input \(\mathbf{u}\in\mathbb{R}^{nu}\)
Compute the derivatives of the acceleration-based contact.
- Parameters:
data – [in] Contact data
x – [in] State point \(\mathbf{x}\in\mathbb{R}^{ndx}\)
u – [in] Control input \(\mathbf{u}\in\mathbb{R}^{nu}\)
Convert the force into a stack of spatial forces.
- Parameters:
data – [in] Contact data
force – [in] Contact force
Convert the force into a stack of spatial forces.
- Parameters:
data – [in] Contact data
force – [in] Contact force
Set the stack of spatial forces to zero.
- Parameters:
data – [in] Contact data
Set the stack of spatial forces Jacobians to zero.
- Parameters:
data – [in] Contact data
-
virtual std::shared_ptr<ContactDataAbstract> createData(pinocchio::DataTpl<Scalar> *const data)
Create the contact data.
-
const std::shared_ptr<StateMultibody> &get_state() const
Return the state.
-
std::size_t get_nc() const
Return the dimension of the contact.
-
std::size_t get_nu() const
Return the dimension of the control vector.
-
pinocchio::FrameIndex get_id() const
Return the reference frame id.
-
void set_id(const pinocchio::FrameIndex id)
Modify the reference frame id.
-
void set_type(const pinocchio::ReferenceFrame type)
Modify the type of contact.
-
pinocchio::ReferenceFrame get_type() const
Return the type of contact.
-
virtual void print(std::ostream &os) const
Print relevant information of the contact model.
- Parameters:
os – [out] Output stream object
Public Members
- EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef _Scalar Scalar
Protected Functions
-
inline ContactModelAbstractTpl()
Protected Attributes
-
std::shared_ptr<StateMultibody> state_
-
std::size_t nc_
-
std::size_t nu_
-
pinocchio::FrameIndex id_
Reference frame id of the contact.
-
pinocchio::ReferenceFrame type_
Type of contact.
Friends
-
template<class Scalar>
friend std::ostream &operator<<(std::ostream &os, const ContactModelAbstractTpl<Scalar> &model) Print information on the contact model.
-
typedef MathBaseTpl<Scalar> MathBase