GCOP
1.0
|
#include <splinetparam.h>
Public Member Functions | |
SplineTparam (System< T, nx, nu, np > &sys, const VectorXd tks, int degree=2) | |
bool | To (Vectorntpd &s, const vector< double > &ts, const vector< T > &xs, const vector< Vectorcd > &us, const Vectormd *p=0) |
bool | From (vector< double > &ts, vector< T > &xs, vector< Vectorcd > &us, const Vectorntpd &s, Vectormd *p=0) |
Public Attributes | |
VectorXd | tks |
control times | |
double | tf |
Final time for spline. | |
int | degree |
Degree of the spline p = (m - n - 1) where m is knot vector size(used by bspline to find the basis etc); n is the control vector size (tks size) |
This version implements the non uniform spline interpolation of the data. It also implements least square fitting of the given control data using spline
Author: Marin Kobilarov (c) 2005--2013 Author2: Gowtham Garimella
gcop::SplineTparam< T, nx, nu, np, _ntp >::SplineTparam | ( | System< T, nx, nu, np > & | sys, |
const VectorXd | tks, | ||
int | degree = 2 |
||
) |
Constructor
sys | System used for manifold |
tks | Knot times for spline |
degree | Spline degree |
References gcop::SplineTparam< T, nx, nu, np, _ntp >::tf, and gcop::SplineTparam< T, nx, nu, np, _ntp >::tks.
bool gcop::SplineTparam< T, nx, nu, np, _ntp >::From | ( | vector< double > & | ts, |
vector< T > & | xs, | ||
vector< Vectorcd > & | us, | ||
const Vectorntpd & | s, | ||
Vectormd * | p = 0 |
||
) | [virtual] |
Convert from trajectory (ts,xs,us,p) to parameters s
ts | times |
xs | states |
us | controls |
s | trajectory parametrization vector |
p | system parameters (optional) |
Reimplemented from gcop::Tparam< T, nx, nu, np, _ntp >.
bool gcop::SplineTparam< T, nx, nu, np, _ntp >::To | ( | Vectorntpd & | s, |
const vector< double > & | ts, | ||
const vector< T > & | xs, | ||
const vector< Vectorcd > & | us, | ||
const Vectormd * | p = 0 |
||
) | [virtual] |
Convert from paramer s to trajectory (ts,xs,us,p)
s | trajectory parametrization vector |
ts | times |
xs | states |
us | controls |
p | system parameters (optional) |
Reimplemented from gcop::Tparam< T, nx, nu, np, _ntp >.
int gcop::SplineTparam< T, nx, nu, np, _ntp >::degree |
Degree of the spline p = (m - n - 1) where m is knot vector size(used by bspline to find the basis etc); n is the control vector size (tks size)
double gcop::SplineTparam< T, nx, nu, np, _ntp >::tf |
Final time for spline.
Referenced by gcop::SplineTparam< T, nx, nu, np, _ntp >::SplineTparam().
VectorXd gcop::SplineTparam< T, nx, nu, np, _ntp >::tks |
control times
Referenced by gcop::SplineTparam< T, nx, nu, np, _ntp >::SplineTparam().