#include <tsid/tasks/task-joint-posVelAcc-bounds.hpp>
Public Types | |
typedef math::ConstraintBound | ConstraintBound |
typedef math::ConstraintInequality | ConstraintInequality |
typedef math::VectorXi | VectorXi |
typedef pinocchio::Data | Data |
![]() | |
typedef trajectories::TrajectorySample | TrajectorySample |
![]() | |
typedef math::ConstRefVector | ConstRefVector |
typedef pinocchio::Data | Data |
typedef robots::RobotWrapper | RobotWrapper |
Public Member Functions | |
TaskJointPosVelAccBounds (const std::string &name, RobotWrapper &robot, double dt, bool verbose=true) | |
int | dim () const |
Return the dimension of the task. \info should be overloaded in the child class. More... | |
const ConstraintBase & | compute (const double t, ConstRefVector q, ConstRefVector v, Data &data) |
const ConstraintBase & | getConstraint () const |
void | setTimeStep (double dt) |
void | setPositionBounds (ConstRefVector lower, ConstRefVector upper) |
void | setVelocityBounds (ConstRefVector upper) |
void | setAccelerationBounds (ConstRefVector upper) |
const Vector & | getAccelerationBounds () const |
const Vector & | getVelocityBounds () const |
const Vector & | getPositionLowerBounds () const |
const Vector & | getPositionUpperBounds () const |
void | setVerbose (bool verbose) |
void | setImposeBounds (bool impose_position_bounds, bool impose_velocity_bounds, bool impose_viability_bounds, bool impose_acceleration_bounds) |
void | isStateViable (ConstRefVector q, ConstRefVector dq, bool verbose=true) |
void | computeAccLimitsFromPosLimits (ConstRefVector q, ConstRefVector dq, bool verbose=true) |
void | computeAccLimitsFromViability (ConstRefVector q, ConstRefVector dq, bool verbose=true) |
void | computeAccLimits (ConstRefVector q, ConstRefVector dq, bool verbose=true) |
TSID_DEPRECATED const Vector & | mask () const |
TSID_DEPRECATED void | mask (const Vector &mask) |
virtual void | setMask (math::ConstRefVector mask) |
![]() | |
TaskMotion (const std::string &name, RobotWrapper &robot) | |
virtual const TrajectorySample & | getReference () const |
virtual const Vector & | getDesiredAcceleration () const |
virtual Vector | getAcceleration (ConstRefVector dv) const |
virtual const Vector & | position_error () const |
virtual const Vector & | velocity_error () const |
virtual const Vector & | position () const |
virtual const Vector & | velocity () const |
virtual const Vector & | position_ref () const |
virtual const Vector & | velocity_ref () const |
virtual void | setMask (math::ConstRefVector mask) |
virtual const Vector & | getMask () const |
virtual bool | hasMask () |
![]() | |
TaskBase (const std::string &name, RobotWrapper &robot) | |
const std::string & | name () const |
void | name (const std::string &name) |
virtual int | dim () const =0 |
Return the dimension of the task. \info should be overloaded in the child class. More... | |
virtual const ConstraintBase & | compute (const double t, ConstRefVector q, ConstRefVector v, Data &data)=0 |
virtual const ConstraintBase & | getConstraint () const =0 |
Public Attributes | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef math::Vector | Vector |
![]() | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef math::Vector | Vector |
![]() | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef math::ConstraintBase | ConstraintBase |
typedef pinocchio::Data tsid::tasks::TaskJointPosVelAccBounds::Data |
tsid::tasks::TaskJointPosVelAccBounds::TaskJointPosVelAccBounds | ( | const std::string & | name, |
RobotWrapper & | robot, | ||
double | dt, | ||
bool | verbose = true |
||
) |
|
virtual |
Implements tsid::tasks::TaskBase.
void tsid::tasks::TaskJointPosVelAccBounds::computeAccLimits | ( | ConstRefVector | q, |
ConstRefVector | dq, | ||
bool | verbose = true |
||
) |
Given the current position and velocity, the bounds of position, velocity and acceleration and the control time step, compute the bounds of the acceleration such that all the bounds are respected at the next time step and can be respected in the future. ddqMax is the absolute maximum acceleration.
void tsid::tasks::TaskJointPosVelAccBounds::computeAccLimitsFromPosLimits | ( | ConstRefVector | q, |
ConstRefVector | dq, | ||
bool | verbose = true |
||
) |
Compute acceleration limits imposed by position bounds. Fills in m_ddqLBPos and m_ddqUBPos
void tsid::tasks::TaskJointPosVelAccBounds::computeAccLimitsFromViability | ( | ConstRefVector | q, |
ConstRefVector | dq, | ||
bool | verbose = true |
||
) |
Compute acceleration limits imposed by viability. ddqMax is the maximum acceleration that will be necessary to stop the joint before hitting the position limits.
-sqrt( 2*ddqMax*(q-qMin) ) < dq[t+1] < sqrt( 2*ddqMax*(qMax-q) ) ddqMin[2] = (-sqrt(max(0.0, 2*MAX_ACC*(q[i]+DT*dq[i]-qMin))) - dq[i])/DT; ddqMax[2] = (sqrt(max(0.0, 2*MAX_ACC*(qMax-q[i]-DT*dq[i]))) - dq[i])/DT;
Fills in m_ddqLBVia and m_ddqUBVia
|
virtual |
Return the dimension of the task. \info should be overloaded in the child class.
Implements tsid::tasks::TaskBase.
const Vector & tsid::tasks::TaskJointPosVelAccBounds::getAccelerationBounds | ( | ) | const |
|
virtual |
Implements tsid::tasks::TaskBase.
const Vector & tsid::tasks::TaskJointPosVelAccBounds::getPositionLowerBounds | ( | ) | const |
const Vector & tsid::tasks::TaskJointPosVelAccBounds::getPositionUpperBounds | ( | ) | const |
const Vector & tsid::tasks::TaskJointPosVelAccBounds::getVelocityBounds | ( | ) | const |
void tsid::tasks::TaskJointPosVelAccBounds::isStateViable | ( | ConstRefVector | q, |
ConstRefVector | dq, | ||
bool | verbose = true |
||
) |
Check if the state is viable, otherwise it returns a measure of the violation of the violated inequality. Fills in m_viabViol , if the state of joint i is viable m_viabViol[i] = 0
const Vector & tsid::tasks::TaskJointPosVelAccBounds::mask | ( | ) | const |
void tsid::tasks::TaskJointPosVelAccBounds::mask | ( | const Vector & | mask | ) |
void tsid::tasks::TaskJointPosVelAccBounds::setAccelerationBounds | ( | ConstRefVector | upper | ) |
void tsid::tasks::TaskJointPosVelAccBounds::setImposeBounds | ( | bool | impose_position_bounds, |
bool | impose_velocity_bounds, | ||
bool | impose_viability_bounds, | ||
bool | impose_acceleration_bounds | ||
) |
|
virtual |
Reimplemented from tsid::tasks::TaskMotion.
void tsid::tasks::TaskJointPosVelAccBounds::setPositionBounds | ( | ConstRefVector | lower, |
ConstRefVector | upper | ||
) |
void tsid::tasks::TaskJointPosVelAccBounds::setTimeStep | ( | double | dt | ) |
void tsid::tasks::TaskJointPosVelAccBounds::setVelocityBounds | ( | ConstRefVector | upper | ) |
void tsid::tasks::TaskJointPosVelAccBounds::setVerbose | ( | bool | verbose | ) |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef math::Vector tsid::tasks::TaskJointPosVelAccBounds::Vector |