Template Class AffineHelperBase
Defined in File Affine.h
Class Documentation
-
template<typename DerivedM, typename DerivedQ>
class AffineHelperBase This class models an affine mapping between an “input variable” x, and an “output variable” y.
The underlying math is:
y = M*x + q
This is useful to make a task/constraint aware about the formatting of the optimization vector w.r.t. to its own variable of interest
Example: in the context of an optimization problem where x = joint acceleration, a torque constraint must know that y = B*x + h. The task can be used also in problems where x = tau, by passing the affine mapping y = x.
Public Types
Public Functions
-
AffineHelperBase() = default
-
inline AffineHelperBase(int input_size, int output_size)
-
template<typename OtherM, typename OtherQ>
inline AffineHelperBase(const AffineHelperBase<OtherM, OtherQ> &other)
-
template<typename OtherM, typename OtherQ>
inline AffineHelperBase<DerivedM, DerivedQ> &operator=(const AffineHelperBase<OtherM, OtherQ> &other)
-
template<typename OtherM, typename OtherQ>
AffineHelperBase<DerivedM, DerivedQ> &operator+=(const AffineHelperBase<OtherM, OtherQ> &other)
-
inline int getInputSize() const
-
inline int getOutputSize() const
-
inline void setZero(int input_size, int output_size)
-
inline void setZero()
-
inline auto segment(int start_idx, int size) const -> AffineHelperBase<decltype(std::declval<ConstPtrM>()->block(0, 0, 0, 0)), decltype(std::declval<ConstPtrQ>()->segment(0, 0))>
-
inline auto head(int size) -> decltype(this->segment(0, 0))
-
inline auto tail(int size) -> decltype(this->segment(0, 0))
-
template<typename Derived>
inline void getValue(const Eigen::VectorXd &x, Eigen::MatrixBase<Derived> &value) const
-
inline virtual void update()
Public Static Functions
-
static inline AffineHelperBase<DerivedM, DerivedQ> Identity(int size)
-
static inline AffineHelperBase<DerivedM, DerivedQ> Zero(int input_size, int output_size)
Protected Functions
-
inline AffineHelperBase<DerivedM, DerivedQ> &self()
-
inline const AffineHelperBase<DerivedM, DerivedQ> &self() const
-
inline void check_consistency()
-
AffineHelperBase() = default