task-joint-bounds.hpp
Go to the documentation of this file.
1 //
2 // Copyright (c) 2017 CNRS
3 //
4 // This file is part of tsid
5 // tsid is free software: you can redistribute it
6 // and/or modify it under the terms of the GNU Lesser General Public
7 // License as published by the Free Software Foundation, either version
8 // 3 of the License, or (at your option) any later version.
9 // tsid is distributed in the hope that it will be
10 // useful, but WITHOUT ANY WARRANTY; without even the implied warranty
11 // of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // General Lesser Public License for more details. You should have
13 // received a copy of the GNU Lesser General Public License along with
14 // tsid If not, see
15 // <http://www.gnu.org/licenses/>.
16 //
17 
18 #ifndef __invdyn_task_joint_bounds_hpp__
19 #define __invdyn_task_joint_bounds_hpp__
20 
23 
24 namespace tsid
25 {
26  namespace tasks
27  {
28 
29  class TaskJointBounds : public TaskMotion
30  {
31  public:
32  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
33 
37 
38  TaskJointBounds(const std::string & name,
39  RobotWrapper & robot,
40  double dt);
41 
42  int dim() const;
43 
44  const ConstraintBase & compute(const double t,
47  Data & data);
48 
49  const ConstraintBase & getConstraint() const;
50 
51  void setTimeStep(double dt);
54  const Vector & getAccelerationLowerBounds() const;
55  const Vector & getAccelerationUpperBounds() const;
56  const Vector & getVelocityLowerBounds() const;
57  const Vector & getVelocityUpperBounds() const;
58 
59  virtual void setMask(math::ConstRefVector mask);
60 
61  protected:
66  double m_dt;
67  int m_nv, m_na;
68  };
69 
70  }
71 }
72 
73 #endif // ifndef __invdyn_task_joint_bounds_hpp__
tsid::tasks::TaskJointBounds::Data
pinocchio::Data Data
Definition: task-joint-bounds.hpp:36
tsid::tasks::TaskJointBounds::m_constraint
ConstraintBound m_constraint
Definition: task-joint-bounds.hpp:65
tsid::tasks::TaskJointBounds::m_a_ub
Vector m_a_ub
Definition: task-joint-bounds.hpp:63
tsid::tasks::TaskJointBounds::getAccelerationUpperBounds
const Vector & getAccelerationUpperBounds() const
Definition: task-joint-bounds.cpp:60
Data
pinocchio::Data Data
Definition: inverse-dynamics-formulation-acc-force.cpp:29
task-motion.hpp
tsid::math::ConstraintBase
Abstract class representing a linear equality/inequality constraint. Equality constraints are represe...
Definition: constraint-base.hpp:36
tsid::math::Vector
Eigen::Matrix< Scalar, Eigen::Dynamic, 1 > Vector
Definition: fwd.hpp:37
tsid::math::ConstraintBound
Definition: constraint-bound.hpp:28
tsid::tasks::TaskJointBounds::setTimeStep
void setTimeStep(double dt)
Definition: task-joint-bounds.cpp:69
tsid::tasks::TaskJointBounds::getAccelerationLowerBounds
const Vector & getAccelerationLowerBounds() const
Definition: task-joint-bounds.cpp:57
tsid::tasks::TaskJointBounds::TaskJointBounds
TaskJointBounds(const std::string &name, RobotWrapper &robot, double dt)
Definition: task-joint-bounds.cpp:29
tsid::tasks::TaskJointBounds::m_a_lb
Vector m_a_lb
Definition: task-joint-bounds.hpp:63
tsid::tasks::TaskJointBounds::m_nv
int m_nv
Definition: task-joint-bounds.hpp:67
tsid::tasks::TaskJointBounds::m_dt
double m_dt
Definition: task-joint-bounds.hpp:66
tsid::tasks::TaskJointBounds::setMask
virtual void setMask(math::ConstRefVector mask)
Definition: task-joint-bounds.cpp:96
tsid::tasks::TaskJointBounds::ConstraintBound
math::ConstraintBound ConstraintBound
Definition: task-joint-bounds.hpp:35
tsid::tasks::TaskJointBounds::setVelocityBounds
void setVelocityBounds(ConstRefVector lower, ConstRefVector upper)
Definition: task-joint-bounds.cpp:75
tsid::tasks::TaskJointBounds
Definition: task-joint-bounds.hpp:29
tsid::tasks::TaskJointBounds::m_na
int m_na
Definition: task-joint-bounds.hpp:67
tsid::tasks::TaskJointBounds::getVelocityLowerBounds
const Vector & getVelocityLowerBounds() const
Definition: task-joint-bounds.cpp:63
tsid::tasks::TaskMotion
Definition: task-motion.hpp:28
tsid::math::ConstRefVector
const typedef Eigen::Ref< const Vector > ConstRefVector
Definition: fwd.hpp:50
tsid::tasks::TaskBase::Data
pinocchio::Data Data
Definition: task-base.hpp:43
tsid::tasks::TaskJointBounds::m_v_lb
Vector m_v_lb
Definition: task-joint-bounds.hpp:62
tsid
Definition: constraint-bound.hpp:26
tsid::tasks::TaskJointBounds::getVelocityUpperBounds
const Vector & getVelocityUpperBounds() const
Definition: task-joint-bounds.cpp:66
tsid::robots::RobotWrapper
Wrapper for a robot based on pinocchio.
Definition: robot-wrapper.hpp:40
tsid::tasks::TaskJointBounds::setAccelerationBounds
void setAccelerationBounds(ConstRefVector lower, ConstRefVector upper)
Definition: task-joint-bounds.cpp:83
tsid::tasks::TaskJointBounds::getConstraint
const ConstraintBase & getConstraint() const
Definition: task-joint-bounds.cpp:91
tsid::tasks::TaskJointBounds::Vector
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef math::Vector Vector
Definition: task-joint-bounds.hpp:34
constraint-bound.hpp
tsid::tasks::TaskBase::name
const std::string & name() const
Definition: task-base.cpp:30
tsid::tasks::TaskJointBounds::compute
const ConstraintBase & compute(const double t, ConstRefVector q, ConstRefVector v, Data &data)
Definition: task-joint-bounds.cpp:101
tsid::tasks::TaskJointBounds::m_ddq_min_due_to_vel
Vector m_ddq_min_due_to_vel
Definition: task-joint-bounds.hpp:64
tsid::tasks::TaskJointBounds::m_ddq_max_due_to_vel
Vector m_ddq_max_due_to_vel
Definition: task-joint-bounds.hpp:64
tsid::tasks::TaskBase::ConstRefVector
math::ConstRefVector ConstRefVector
Definition: task-base.hpp:42
tsid::tasks::TaskJointBounds::dim
int dim() const
Return the dimension of the task. \info should be overloaded in the child class.
Definition: task-joint-bounds.cpp:54
tsid::tasks::TaskJointBounds::m_v_ub
Vector m_v_ub
Definition: task-joint-bounds.hpp:62