aligator
0.6.1
A primal-dual augmented Lagrangian-type solver for nonlinear trajectory optimization.
|
Represents a function of which the output is a subset of another function, for instance \(x \mapsto f_\{0, 1, 3\}(x) \) where \(f\) is given. More...
#include <aligator/modelling/function-xpr-slice.hpp>
Public Types | |
using | BaseData = StageFunctionDataTpl<Scalar> |
using | SliceImpl = detail::slice_impl_tpl<StageFunctionTpl<Scalar>> |
using | Data = FunctionSliceDataTpl<Scalar> |
Public Types inherited from aligator::StageFunctionTpl< _Scalar > | |
using | Scalar = _Scalar |
using | Data = StageFunctionDataTpl<Scalar> |
Public Types inherited from aligator::detail::slice_impl_tpl< Base > | |
using | Scalar = typename Base::Scalar |
using | BaseData = StageFunctionDataTpl<Scalar> |
using | Data = FunctionSliceDataTpl<Scalar> |
Public Member Functions | |
ALIGATOR_DYNAMIC_TYPEDEFS (Scalar) | |
FunctionSliceXprTpl (shared_ptr< Base > func, std::vector< int > const &indices) | |
FunctionSliceXprTpl (shared_ptr< Base > func, const int idx) | |
void | evaluate (const ConstVectorRef &x, const ConstVectorRef &u, const ConstVectorRef &y, BaseData &data) const override |
Evaluate the function. | |
void | computeJacobians (const ConstVectorRef &x, const ConstVectorRef &u, const ConstVectorRef &y, BaseData &data) const override |
Compute Jacobians of this function. | |
void | computeVectorHessianProducts (const ConstVectorRef &x, const ConstVectorRef &u, const ConstVectorRef &y, const ConstVectorRef &lbda, BaseData &data) const override |
Compute the vector-hessian products of this function. | |
shared_ptr< BaseData > | createData () const override |
Instantiate a Data object. | |
Public Member Functions inherited from aligator::StageFunctionTpl< _Scalar > | |
ALIGATOR_DYNAMIC_TYPEDEFS (Scalar) | |
StageFunctionTpl (const int ndx1, const int nu, const int ndx2, const int nr) | |
StageFunctionTpl (const int ndx, const int nu, const int nr) | |
Constructor where ndx2 = ndx1. | |
virtual | ~StageFunctionTpl ()=default |
Public Member Functions inherited from aligator::detail::slice_impl_tpl< Base > | |
ALIGATOR_DYNAMIC_TYPEDEFS (Scalar) | |
slice_impl_tpl (shared_ptr< Base > func, std::vector< int > const &indices) | |
slice_impl_tpl (shared_ptr< Base > func, int idx) | |
Additional Inherited Members | |
Public Attributes inherited from aligator::StageFunctionTpl< _Scalar > | |
const int | ndx1 |
Current state dimension. | |
const int | nu |
Control dimension. | |
const int | ndx2 |
Next state dimension. | |
const int | nr |
Function codimension. | |
Public Attributes inherited from aligator::detail::slice_impl_tpl< Base > | |
shared_ptr< Base > | func |
std::vector< int > | indices |
Protected Member Functions inherited from aligator::detail::slice_impl_tpl< Base > | |
template<typename... Args> | |
void | evaluate_impl (BaseData &data, Args &&...args) const |
template<typename... Args> | |
void | computeJacobians_impl (BaseData &data, Args &&...args) const |
template<typename... Args> | |
void | computeVectorHessianProducts_impl (BaseData &data, const ConstVectorRef &lbda, Args &&...args) const |
Represents a function of which the output is a subset of another function, for instance \(x \mapsto f_\{0, 1, 3\}(x) \) where \(f\) is given.
Definition at line 20 of file function-xpr-slice.hpp.
using aligator::FunctionSliceXprTpl< Scalar, Base >::BaseData = StageFunctionDataTpl<Scalar> |
Definition at line 22 of file function-xpr-slice.hpp.
using aligator::FunctionSliceXprTpl< Scalar, Base >::SliceImpl = detail::slice_impl_tpl<StageFunctionTpl<Scalar>> |
Definition at line 23 of file function-xpr-slice.hpp.
using aligator::FunctionSliceXprTpl< Scalar, Base >::Data = FunctionSliceDataTpl<Scalar> |
Definition at line 24 of file function-xpr-slice.hpp.
|
inline |
Definition at line 26 of file function-xpr-slice.hpp.
|
inline |
Definition at line 30 of file function-xpr-slice.hpp.
aligator::FunctionSliceXprTpl< Scalar, Base >::ALIGATOR_DYNAMIC_TYPEDEFS | ( | Scalar | ) |
|
inlineoverridevirtual |
Evaluate the function.
x | Current state. |
u | Controls. |
y | Next state. |
data | Data holding struct. |
Implements aligator::StageFunctionTpl< _Scalar >.
Definition at line 33 of file function-xpr-slice.hpp.
|
inlineoverridevirtual |
Compute Jacobians of this function.
This computes the Jacobians \( (\frac{\partial f}{\partial x}, \frac{\partial f}{\partial u}, \frac{\partial f}{\partial x'}) \)
x | Current state. |
u | Controls. |
y | Next state. |
data | Data holding struct. |
Implements aligator::StageFunctionTpl< _Scalar >.
Definition at line 39 of file function-xpr-slice.hpp.
|
inlineoverridevirtual |
Compute the vector-hessian products of this function.
x | Current state. |
u | Controls. |
y | Next state. |
lbda | Multiplier estimate. |
data | Data holding struct. |
Reimplemented from aligator::StageFunctionTpl< _Scalar >.
Definition at line 45 of file function-xpr-slice.hpp.
|
inlineoverridevirtual |
Instantiate a Data object.
Reimplemented from aligator::StageFunctionTpl< _Scalar >.
Definition at line 53 of file function-xpr-slice.hpp.