wbc
wbc::Constraint Class Referenceabstract

Abstract class to represent a generic hard (linear) constraint for a WBC optimization problem. the constraint belongs to one of three types: equality Ax = b inequality lb <= Ax <= ub bounds lb <= x <= ub. More...

#include <Constraint.hpp>

Inheritance diagram for wbc::Constraint:
wbc::ContactsAccelerationConstraint wbc::ContactsFrictionPointConstraint wbc::ContactsFrictionSurfaceConstraint wbc::ContactsVelocityConstraint wbc::EffortLimitsAccelerationConstraint wbc::JointLimitsAccelerationConstraint wbc::JointLimitsVelocityConstraint wbc::RigidbodyDynamicsConstraint

Public Types

enum  Type { equality = 0 , inequality = 1 , bounds = 2 }
 

Public Member Functions

virtual ~Constraint ()=default
 
virtual void update (RobotModelPtr robot_model)=0
 Update constraint matrix and vectors, depending on the type. Abstract method.
 
Type type ()
 Return the type of this constraint.
 
const base::MatrixXd & A ()
 return constraint matrix A
 
const base::VectorXd & b ()
 return constraint vector b
 
const base::VectorXd & lb ()
 return constraint lower bound lb
 
const base::VectorXd & ub ()
 return constraint upper bound ub
 
uint size ()
 return size of the constraint (i.e. number of rows of the constraint matrix)
 

Protected Member Functions

 Constraint ()
 Default constructor.
 
 Constraint (Type type)
 Constructor. Initialiye the type of this constraint.
 

Protected Attributes

Type c_type
 
base::MatrixXd A_mtx
 
base::VectorXd b_vec
 
base::VectorXd lb_vec
 
base::VectorXd ub_vec
 

Detailed Description

Abstract class to represent a generic hard (linear) constraint for a WBC optimization problem. the constraint belongs to one of three types: equality Ax = b inequality lb <= Ax <= ub bounds lb <= x <= ub.

Member Enumeration Documentation

◆ Type

Enumerator
equality 
inequality 
bounds 

Constructor & Destructor Documentation

◆ ~Constraint()

virtual wbc::Constraint::~Constraint ( )
virtualdefault

◆ Constraint() [1/2]

wbc::Constraint::Constraint ( )
protected

Default constructor.

◆ Constraint() [2/2]

wbc::Constraint::Constraint ( Type type)
protected

Constructor. Initialiye the type of this constraint.

Member Function Documentation

◆ A()

const base::MatrixXd & wbc::Constraint::A ( )

return constraint matrix A

◆ b()

const base::VectorXd & wbc::Constraint::b ( )

return constraint vector b

◆ lb()

const base::VectorXd & wbc::Constraint::lb ( )

return constraint lower bound lb

◆ size()

uint wbc::Constraint::size ( )

return size of the constraint (i.e. number of rows of the constraint matrix)

◆ type()

Constraint::Type wbc::Constraint::type ( )

Return the type of this constraint.

◆ ub()

const base::VectorXd & wbc::Constraint::ub ( )

return constraint upper bound ub

◆ update()

Member Data Documentation

◆ A_mtx

base::MatrixXd wbc::Constraint::A_mtx
protected

Constraint matrix

◆ b_vec

base::VectorXd wbc::Constraint::b_vec
protected

Constraint vector

◆ c_type

Type wbc::Constraint::c_type
protected

◆ lb_vec

base::VectorXd wbc::Constraint::lb_vec
protected

Constraint lower bound

◆ ub_vec

base::VectorXd wbc::Constraint::ub_vec
protected

Constraint upper bound


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