GCOP  1.0
Public Types | Public Member Functions | Public Attributes
gcop::Cost< T, _nx, _nu, _np, Tc > Class Template Reference

#include <cost.h>

Inheritance diagram for gcop::Cost< T, _nx, _nu, _np, Tc >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef Matrix< double, _nx, 1 > Vectornd
typedef Matrix< double, _nu, 1 > Vectorcd
typedef Matrix< double, _np, 1 > Vectormd
typedef Matrix< double, _nx, _nx > Matrixnd
typedef Matrix< double, _nx, _nu > Matrixncd
typedef Matrix< double, _nu, _nx > Matrixcnd
typedef Matrix< double, _nu, _nu > Matrixcd
typedef Matrix< double, _np, _np > Matrixmd
typedef Matrix< double, _nx, _np > Matrixnmd
typedef Matrix< double, _np, _nx > Matrixmnd

Public Member Functions

 Cost (System< T, _nx, _nu, _np > &sys, double tf)
virtual double L (double t, const T &x, const Vectorcd &u, double h, const Vectormd *p=0, Vectornd *Lx=0, Matrixnd *Lxx=0, Vectorcd *Lu=0, Matrixcd *Luu=0, Matrixncd *Lxu=0, Vectormd *Lp=0, Matrixmd *Lpp=0, Matrixmnd *Lpx=0)
virtual bool SetContext (const Tc &c)

Public Attributes

System< T, _nx, _nu, _np > & sys
 system
double tf
 final time of trajectory

Detailed Description

template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
class gcop::Cost< T, _nx, _nu, _np, Tc >

Cost interface for optimal control on manifolds. Defines a cost function and means to compute difference between two states on a manifold.

Subclasses should provide implementation of either a regular const function L or a parameter-dependent cost function Lp (e.g. for sys id / adaptive control / optimal design problems)

Author: Marin Kobilarov marin(at)jhu.edu


Member Typedef Documentation

template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nu, _nu> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixcd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nu, _nx> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixcnd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _np, _np> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixmd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _np, _nx> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixmnd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nx, _nu> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixncd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nx, _nx> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixnd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nx, _np> gcop::Cost< T, _nx, _nu, _np, Tc >::Matrixnmd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nu, 1> gcop::Cost< T, _nx, _nu, _np, Tc >::Vectorcd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _np, 1> gcop::Cost< T, _nx, _nu, _np, Tc >::Vectormd
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
typedef Matrix<double, _nx, 1> gcop::Cost< T, _nx, _nu, _np, Tc >::Vectornd

Constructor & Destructor Documentation

template<typename T, int _nx, int _nu, int _np, typename Tc >
gcop::Cost< T, _nx, _nu, _np, Tc >::Cost ( System< T, _nx, _nu, _np > &  sys,
double  tf 
)

create a cost interface

Parameters:
Xthe state manifold which is used to perform addition/subtraction of states
tftime horizon: when the cost function L is called it will internally check whether its argument t is equation to tf and return the terminal cost

Member Function Documentation

template<typename T, int _nx, int _nu, int _np, typename Tc >
double gcop::Cost< T, _nx, _nu, _np, Tc >::L ( double  t,
const T &  x,
const Vectorcd u,
double  h,
const Vectormd p = 0,
Vectornd Lx = 0,
Matrixnd Lxx = 0,
Vectorcd Lu = 0,
Matrixcd Luu = 0,
Matrixncd Lxu = 0,
Vectormd Lp = 0,
Matrixmd Lpp = 0,
Matrixmnd Lpx = 0 
) [virtual]
template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
virtual bool gcop::Cost< T, _nx, _nu, _np, Tc >::SetContext ( const Tc &  c) [inline, virtual]

Member Data Documentation

template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
System<T, _nx, _nu, _np>& gcop::Cost< T, _nx, _nu, _np, Tc >::sys

system

template<typename T, int _nx = Dynamic, int _nu = Dynamic, int _np = Dynamic, typename Tc = T>
double gcop::Cost< T, _nx, _nu, _np, Tc >::tf

final time of trajectory


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