wbc
wbc::ContactsFrictionSurfaceConstraint Class Reference

Polyhedral wrench friction (coulomb) cone constraint according to https://scaron.info/robotics/wrench-friction-cones.html (Wrench friction cone for surface contacts). More...

#include <ContactsFrictionSurfaceConstraint.hpp>

Inheritance diagram for wbc::ContactsFrictionSurfaceConstraint:
wbc::Constraint

Public Member Functions

 ContactsFrictionSurfaceConstraint (bool _reduced=false, bool _use_slack=false)
 Default constructor.
virtual ~ContactsFrictionSurfaceConstraint ()=default
virtual void update (RobotModelPtr robot_model) override
 Update constraint matrix and vectors, depending on the type. Abstract method.
void setUseSlack (bool enable)
 Enable/disable softening of the friction cone using one slack variable per contact.
bool useSlack () const
 Return whether the friction cone is softened using slack variables.
Public Member Functions inherited from wbc::Constraint
virtual ~Constraint ()=default
Type type ()
 Return the type of this constraint.
const Eigen::MatrixXd & A ()
 return constraint matrix A
const Eigen::VectorXd & b ()
 return constraint vector b
const Eigen::VectorXd & lb ()
 return constraint lower bound lb
const Eigen::VectorXd & ub ()
 return constraint upper bound ub
uint size ()
 return size of the constraint (i.e. number of rows of the constraint matrix)

Additional Inherited Members

Public Types inherited from wbc::Constraint
enum  Type { equality = 0 , inequality = 1 , bounds = 2 }
Protected Member Functions inherited from wbc::Constraint
 Constraint ()
 Default constructor.
 Constraint (Type type)
 Constructor. Initialiye the type of this constraint.
Protected Attributes inherited from wbc::Constraint
Type c_type
Eigen::MatrixXd A_mtx
Eigen::VectorXd b_vec
Eigen::VectorXd lb_vec
Eigen::VectorXd ub_vec

Detailed Description

Polyhedral wrench friction (coulomb) cone constraint according to https://scaron.info/robotics/wrench-friction-cones.html (Wrench friction cone for surface contacts).

If use_slack is set, the cone is softened using a single slack variable s per contact: A*f <= s, s >= 0. The slack variables are assumed to be appended to the qp variables, i.e., the variable order becomes (qdd,f_ext,s). The bounds s >= 0 and the penalty on s have to be added by the scene.

Constructor & Destructor Documentation

◆ ContactsFrictionSurfaceConstraint()

wbc::ContactsFrictionSurfaceConstraint::ContactsFrictionSurfaceConstraint ( bool _reduced = false,
bool _use_slack = false )
inlineexplicit

Default constructor.

◆ ~ContactsFrictionSurfaceConstraint()

virtual wbc::ContactsFrictionSurfaceConstraint::~ContactsFrictionSurfaceConstraint ( )
virtualdefault

Member Function Documentation

◆ setUseSlack()

void wbc::ContactsFrictionSurfaceConstraint::setUseSlack ( bool enable)
inline

Enable/disable softening of the friction cone using one slack variable per contact.

◆ update()

void wbc::ContactsFrictionSurfaceConstraint::update ( RobotModelPtr robot_model)
overridevirtual

Update constraint matrix and vectors, depending on the type. Abstract method.

Implements wbc::Constraint.

◆ useSlack()

bool wbc::ContactsFrictionSurfaceConstraint::useSlack ( ) const
inline

Return whether the friction cone is softened using slack variables.


The documentation for this class was generated from the following files: