curve Namespace Reference

Namespaces

 helpers
 

Classes

struct  Bern
 
struct  bezier_curve
 
struct  curve_abc
 Represents a curve of dimension Dim is Safe is false, no verification is made on the evaluation of the curve. More...
 
struct  curve_constraints
 
struct  exact_cubic
 
struct  linear_variable
 
class  polynom
 Represents a polynomf arbitrary order defined on the interval [tBegin, tEnd]. More...
 
class  spline_deriv_constraint
 Represents a set of cubic splines defining a continuous function crossing each of the waypoint given in its initialization. More...
 
class  SplineOptimizer
 Mosek connection to produce optimized splines. More...
 
struct  variables
 

Functions

unsigned int fact (const unsigned int n)
 Computes factorial of a number. More...
 
unsigned int bin (const unsigned int n, const unsigned int k)
 Computes a binomal coefficient. More...
 
template<typename Numeric >
std::vector< Bern< Numeric > > makeBernstein (const unsigned int n)
 Computes all Bernstein polynomes for a certain degree. More...
 
template<typename Bezier , typename Polynom >
Polynom from_bezier (const Bezier &curve)
 Provides methods for converting a curve from a bernstein representation to a polynom representation. More...
 
template<typename Point , typename T_Point >
T_Point make_cubic_vector (Point const &a, Point const &b, Point const &c, Point const &d)
 Creates coefficient vector of a cubic spline defined on the interval [tBegin, tEnd]. More...
 
template<typename Time , typename Numeric , std::size_t Dim, bool Safe, typename Point , typename T_Point >
polynom< Time, Numeric, Dim, Safe, Point, T_Point > create_cubic (Point const &a, Point const &b, Point const &c, Point const &d, const Time min, const Time max)
 
template<int D, typename N >
linear_variable< D, N > operator+ (const linear_variable< D, N > &w1, const linear_variable< D, N > &w2)
 
template<int D, typename N >
linear_variable< D, N > operator- (const linear_variable< D, N > &w1, const linear_variable< D, N > &w2)
 
template<int D, typename N >
linear_variable< D, N > operator* (const double k, const linear_variable< D, N > &w)
 
template<int D, typename N >
linear_variable< D, N > operator* (const linear_variable< D, N > &w, const double k)
 
template<int D, typename N >
linear_variable< D, N > operator/ (const linear_variable< D, N > &w, const double k)
 
template<typename V >
variables< V > operator+ (const variables< V > &w1, const variables< V > &w2)
 
template<typename V >
variables< V > operator- (const variables< V > &w1, const variables< V > &w2)
 
template<typename V >
variables< V > operator* (const double k, const variables< V > &w)
 
template<typename V >
variables< V > operator* (const variables< V > &w, const double k)
 
template<typename V >
variables< V > operator/ (const variables< V > &w, const double k)
 
template<typename _Matrix_Type_ >
void PseudoInverse (_Matrix_Type_ &pinvmat)
 
template<typename Point , typename T_Point >
T_Point make_quintic_vector (Point const &a, Point const &b, Point const &c, Point const &d, Point const &e, Point const &f)
 Creates coefficient vector of a quintic spline defined on the interval [tBegin, tEnd]. More...
 
template<typename Time , typename Numeric , std::size_t Dim, bool Safe, typename Point , typename T_Point >
polynom< Time, Numeric, Dim, Safe, Point, T_Point > create_quintic (Point const &a, Point const &b, Point const &c, Point const &d, Point const &e, Point const &f, const Time min, const Time max)
 

Function Documentation

◆ bin()

unsigned int curve::bin ( const unsigned int  n,
const unsigned int  k 
)
inline

Computes a binomal coefficient.

References fact().

◆ create_cubic()

template<typename Time , typename Numeric , std::size_t Dim, bool Safe, typename Point , typename T_Point >
polynom<Time,Numeric,Dim,Safe,Point,T_Point> curve::create_cubic ( Point const &  a,
Point const &  b,
Point const &  c,
Point const &  d,
const Time  min,
const Time  max 
)

◆ create_quintic()

template<typename Time , typename Numeric , std::size_t Dim, bool Safe, typename Point , typename T_Point >
polynom<Time,Numeric,Dim,Safe,Point,T_Point> curve::create_quintic ( Point const &  a,
Point const &  b,
Point const &  c,
Point const &  d,
Point const &  e,
Point const &  f,
const Time  min,
const Time  max 
)

◆ fact()

unsigned int curve::fact ( const unsigned int  n)
inline

Computes factorial of a number.

Referenced by bin(), and from_bezier().

◆ from_bezier()

template<typename Bezier , typename Polynom >
Polynom curve::from_bezier ( const Bezier &  curve)

Provides methods for converting a curve from a bernstein representation to a polynom representation.

Converts a Bezier curve to a polynom

Parameters
bezierthe Bezier curve to be converted from
Returns
the equivalent polynom

References fact().

◆ make_cubic_vector()

template<typename Point , typename T_Point >
T_Point curve::make_cubic_vector ( Point const &  a,
Point const &  b,
Point const &  c,
Point const &  d 
)

Creates coefficient vector of a cubic spline defined on the interval [tBegin, tEnd].

It follows the equation x(t) = a + b(t - t_min_) + c(t - t_min_)^2 + d(t - t_min_)^3

◆ make_quintic_vector()

template<typename Point , typename T_Point >
T_Point curve::make_quintic_vector ( Point const &  a,
Point const &  b,
Point const &  c,
Point const &  d,
Point const &  e,
Point const &  f 
)

Creates coefficient vector of a quintic spline defined on the interval [tBegin, tEnd].

It follows the equation x(t) = a + b(t - t_min_) + c(t - t_min_)^2 + d(t - t_min_)^3 + e(t - t_min_)^4 + f(t - t_min_)^5

◆ makeBernstein()

template<typename Numeric >
std::vector<Bern<Numeric> > curve::makeBernstein ( const unsigned int  n)

Computes all Bernstein polynomes for a certain degree.

◆ operator*() [1/4]

template<int D, typename N >
linear_variable<D,N> curve::operator* ( const double  k,
const linear_variable< D, N > &  w 
)

◆ operator*() [2/4]

template<int D, typename N >
linear_variable<D,N> curve::operator* ( const linear_variable< D, N > &  w,
const double  k 
)

◆ operator*() [3/4]

template<typename V >
variables<V> curve::operator* ( const double  k,
const variables< V > &  w 
)

◆ operator*() [4/4]

template<typename V >
variables<V> curve::operator* ( const variables< V > &  w,
const double  k 
)

◆ operator+() [1/2]

template<int D, typename N >
linear_variable<D,N> curve::operator+ ( const linear_variable< D, N > &  w1,
const linear_variable< D, N > &  w2 
)
inline

◆ operator+() [2/2]

template<typename V >
variables<V> curve::operator+ ( const variables< V > &  w1,
const variables< V > &  w2 
)

◆ operator-() [1/2]

template<int D, typename N >
linear_variable<D,N> curve::operator- ( const linear_variable< D, N > &  w1,
const linear_variable< D, N > &  w2 
)

◆ operator-() [2/2]

template<typename V >
variables<V> curve::operator- ( const variables< V > &  w1,
const variables< V > &  w2 
)

◆ operator/() [1/2]

template<int D, typename N >
linear_variable<D,N> curve::operator/ ( const linear_variable< D, N > &  w,
const double  k 
)

◆ operator/() [2/2]

template<typename V >
variables<V> curve::operator/ ( const variables< V > &  w,
const double  k 
)

◆ PseudoInverse()