aligator  0.9.0
A primal-dual augmented Lagrangian-type solver for nonlinear trajectory optimization.
Loading...
Searching...
No Matches
aligator::detail::StateOrControlErrorResidual< _Scalar, arg > Struct Template Reference

Residual \(r(z) = z \ominus z_{tar} \). More...

#include <aligator/modelling/state-error.hpp>

Inheritance diagram for aligator::detail::StateOrControlErrorResidual< _Scalar, arg >:
[legend]
Collaboration diagram for aligator::detail::StateOrControlErrorResidual< _Scalar, arg >:
[legend]

Public Types

using Scalar = _Scalar
 
using Base = StageFunctionTpl<Scalar>
 
using Data = StageFunctionDataTpl<Scalar>
 
using Manifold = ManifoldAbstractTpl<Scalar>
 
using VectorSpace = proxsuite::nlp::VectorSpaceTpl<Scalar, Eigen::Dynamic>
 
- Public Types inherited from aligator::StageFunctionTpl< _Scalar >
using Scalar
 
using Data
 

Public Member Functions

 ALIGATOR_DYNAMIC_TYPEDEFS (Scalar)
 
template<unsigned int N = arg, typename = std::enable_if_t<N == 1>>
 StateOrControlErrorResidual (const int ndx, const xyz::polymorphic< Manifold > &uspace, const ConstVectorRef &target)
 Constructor using the state space dimension, control manifold and control target.
 
auto get_polymorphic (const int &size) const
 Constructor using state space and control space dimensions, the control space is assumed to be Euclidean.
 
template<unsigned int N = arg, typename = std::enable_if_t<N == 1>>
 StateOrControlErrorResidual (const int ndx, const ConstVectorRef &target)
 
template<unsigned int N = arg, typename = std::enable_if_t<N == 1>>
 StateOrControlErrorResidual (const int ndx, const int nu)
 
void evaluate (const ConstVectorRef &, const ConstVectorRef &u, Data &data) const override
 
void computeJacobians (const ConstVectorRef &, const ConstVectorRef &u, Data &data) const override
 
- Public Member Functions inherited from aligator::StageFunctionTpl< _Scalar >
 ALIGATOR_DYNAMIC_TYPEDEFS (_Scalar)
 
 StageFunctionTpl (const int ndx, const int nu, const int nr)
 
virtual void evaluate (const ConstVectorRef &x, const ConstVectorRef &u, Data &data) const=0
 Evaluate the function.
 
virtual void computeJacobians (const ConstVectorRef &x, const ConstVectorRef &u, Data &data) const=0
 Compute Jacobians of this function.
 
virtual void computeVectorHessianProducts (const ConstVectorRef &x, const ConstVectorRef &u, const ConstVectorRef &lbda, Data &data) const
 Compute the vector-hessian products of this function.
 
virtual ~StageFunctionTpl ()=default
 
virtual shared_ptr< DatacreateData () const
 Instantiate a Data object.
 

Public Attributes

xyz::polymorphic< Manifoldspace_
 
VectorXs target_
 
- Public Attributes inherited from aligator::StageFunctionTpl< _Scalar >
const int ndx1
 Current state dimension.
 
const int nu
 Control dimension.
 
const int nr
 Function codimension.
 

Detailed Description

template<typename _Scalar, unsigned int arg>
struct aligator::detail::StateOrControlErrorResidual< _Scalar, arg >

Residual \(r(z) = z \ominus z_{tar} \).

The arg parameter decides with respect to which the error computation operates – state x or control u.. We use SFINAE to enable or disable the relevant constructors.

Definition at line 52 of file state-error.hpp.

Member Typedef Documentation

◆ Scalar

template<typename _Scalar , unsigned int arg>
using aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::Scalar = _Scalar

Definition at line 54 of file state-error.hpp.

◆ Base

template<typename _Scalar , unsigned int arg>
using aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::Base = StageFunctionTpl<Scalar>

Definition at line 56 of file state-error.hpp.

◆ Data

template<typename _Scalar , unsigned int arg>
using aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::Data = StageFunctionDataTpl<Scalar>

Definition at line 57 of file state-error.hpp.

◆ Manifold

template<typename _Scalar , unsigned int arg>
using aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::Manifold = ManifoldAbstractTpl<Scalar>

Definition at line 58 of file state-error.hpp.

◆ VectorSpace

template<typename _Scalar , unsigned int arg>
using aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::VectorSpace = proxsuite::nlp::VectorSpaceTpl<Scalar, Eigen::Dynamic>

Definition at line 59 of file state-error.hpp.

Constructor & Destructor Documentation

◆ StateOrControlErrorResidual() [1/3]

template<typename _Scalar , unsigned int arg>
template<unsigned int N = arg, typename = std::enable_if_t<N == 1>>
aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::StateOrControlErrorResidual ( const int ndx,
const xyz::polymorphic< Manifold > & uspace,
const ConstVectorRef & target )
inline

Constructor using the state space dimension, control manifold and control target.

Definition at line 67 of file state-error.hpp.

◆ StateOrControlErrorResidual() [2/3]

template<typename _Scalar , unsigned int arg>
template<unsigned int N = arg, typename = std::enable_if_t<N == 1>>
aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::StateOrControlErrorResidual ( const int ndx,
const ConstVectorRef & target )
inline

Definition at line 82 of file state-error.hpp.

◆ StateOrControlErrorResidual() [3/3]

template<typename _Scalar , unsigned int arg>
template<unsigned int N = arg, typename = std::enable_if_t<N == 1>>
aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::StateOrControlErrorResidual ( const int ndx,
const int nu )
inline

Definition at line 87 of file state-error.hpp.

Member Function Documentation

◆ ALIGATOR_DYNAMIC_TYPEDEFS()

template<typename _Scalar , unsigned int arg>
aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::ALIGATOR_DYNAMIC_TYPEDEFS ( Scalar )

◆ get_polymorphic()

template<typename _Scalar , unsigned int arg>
auto aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::get_polymorphic ( const int & size) const
inline

Constructor using state space and control space dimensions, the control space is assumed to be Euclidean.

Definition at line 77 of file state-error.hpp.

◆ evaluate()

template<typename _Scalar , unsigned int arg>
void aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::evaluate ( const ConstVectorRef & ,
const ConstVectorRef & u,
Data & data ) const
inlineoverride

Definition at line 92 of file state-error.hpp.

◆ computeJacobians()

template<typename _Scalar , unsigned int arg>
void aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::computeJacobians ( const ConstVectorRef & ,
const ConstVectorRef & u,
Data & data ) const
inlineoverride

Definition at line 103 of file state-error.hpp.

Member Data Documentation

◆ space_

template<typename _Scalar , unsigned int arg>
xyz::polymorphic<Manifold> aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::space_

Definition at line 61 of file state-error.hpp.

◆ target_

template<typename _Scalar , unsigned int arg>
VectorXs aligator::detail::StateOrControlErrorResidual< _Scalar, arg >::target_

Definition at line 62 of file state-error.hpp.


The documentation for this struct was generated from the following file: