curves::helpers::rotation_spline Class Reference

#include <curves/helpers/effector_spline_rotation.h>

Inheritance diagram for curves::helpers::rotation_spline:
Collaboration diagram for curves::helpers::rotation_spline:

Public Member Functions

 rotation_spline (quat_ref_const_t quat_from=quat_t(0, 0, 0, 1), quat_ref_const_t quat_to=quat_t(0, 0, 0, 1), const double min=0., const double max=1.)
 
 ~rotation_spline ()
 
rotation_splineoperator= (const rotation_spline &from)
 
quat_t operator() (const Numeric t) const
 
bool isApprox (const rotation_spline &other, const Numeric prec=Eigen::NumTraits< Numeric >::dummy_precision()) const
 isApprox check if other and *this are approximately equals. Only two curves of the same class can be approximately equals, for comparison between different type of curves see isEquivalent More...
 
virtual bool isApprox (const curve_abc_quat_t *other, const Numeric prec=Eigen::NumTraits< Numeric >::dummy_precision()) const
 
virtual bool operator== (const rotation_spline &other) const
 
virtual bool operator!= (const rotation_spline &other) const
 
virtual quat_t derivate (time_t, std::size_t) const
 
curve_abc_quat_tcompute_derivate_ptr (const std::size_t) const
 Compute the derived curve at order N. More...
 
exact_cubic_constraint_one_dim computeWayPoints () const
 Initialize time reparametrization for spline. More...
 
virtual std::size_t dim () const
 Get dimension of curve. More...
 
virtual time_t min () const
 Get the minimum time for which the curve is defined. More...
 
virtual time_t max () const
 Get the maximum time for which the curve is defined. More...
 
virtual std::size_t degree () const
 Get the degree of the curve. More...
 
- Public Member Functions inherited from curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >
 curve_abc ()
 Constructor. More...
 
virtual ~curve_abc ()
 Destructor. More...
 
virtual point_t operator() (const time_t t) const =0
 Evaluation of the cubic spline at time t. More...
 
virtual point_derivate_t derivate (const time_t t, const std::size_t order) const =0
 Evaluate the derivative of order N of curve at time t. More...
 
bool isEquivalent (const curve_t *other, const Numeric prec=Eigen::NumTraits< Numeric >::dummy_precision(), const size_t order=5) const
 isEquivalent check if other and *this are approximately equal by values, given a precision treshold. This test is done by discretizing both curves and evaluating them and their derivatives. More...
 
virtual bool isApprox (const curve_t *other, const Numeric prec=Eigen::NumTraits< Numeric >::dummy_precision()) const =0
 isApprox check if other and *this are approximately equal given a precision treshold Only two curves of the same class can be approximately equal, for comparison between different type of curves see isEquivalent. More...
 
std::pair< time_t, time_ttimeRange ()
 
template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Public Attributes

Eigen::Quaterniond quat_from_
 
Eigen::Quaterniond quat_to_
 
std::size_t dim_
 
double min_
 
double max_
 
exact_cubic_constraint_one_dim time_reparam_
 

Additional Inherited Members

- Public Types inherited from curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >
typedef Point point_t
 
typedef Point_derivate point_derivate_t
 
typedef Time time_t
 
typedef Numeric num_t
 
typedef curve_abc< Time, Numeric, Safe, point_t, point_derivate_tcurve_t
 
typedef curve_abc< Time, Numeric, Safe, point_derivate_tcurve_derivate_t
 
typedef boost::shared_ptr< curve_tcurve_ptr_t
 

Constructor & Destructor Documentation

◆ rotation_spline()

curves::helpers::rotation_spline::rotation_spline ( quat_ref_const_t  quat_from = quat_t(0, 0, 0, 1),
quat_ref_const_t  quat_to = quat_t(0, 0, 0, 1),
const double  min = 0.,
const double  max = 1. 
)
inline

◆ ~rotation_spline()

curves::helpers::rotation_spline::~rotation_spline ( )
inline

Member Function Documentation

◆ compute_derivate_ptr()

curve_abc_quat_t* curves::helpers::rotation_spline::compute_derivate_ptr ( const std::size_t  ) const
inlinevirtual

Compute the derived curve at order N.

Parameters
order: order of derivative.
Returns
A pointer to $\frac{d^Nx(t)}{dt^N}$ derivative order N of the curve.

Implements curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >.

◆ computeWayPoints()

exact_cubic_constraint_one_dim curves::helpers::rotation_spline::computeWayPoints ( ) const
inline

Initialize time reparametrization for spline.

◆ degree()

virtual std::size_t curves::helpers::rotation_spline::degree ( ) const
inlinevirtual

Get the degree of the curve.

Returns
$degree$, the degree of the curve.

Implements curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >.

◆ derivate()

virtual quat_t curves::helpers::rotation_spline::derivate ( time_t  ,
std::size_t   
) const
inlinevirtual

◆ dim()

virtual std::size_t curves::helpers::rotation_spline::dim ( ) const
inlinevirtual

Get dimension of curve.

Returns
dimension of curve.

Implements curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >.

◆ isApprox() [1/2]

bool curves::helpers::rotation_spline::isApprox ( const rotation_spline other,
const Numeric  prec = Eigen::NumTraits<Numeric>::dummy_precision() 
) const
inline

isApprox check if other and *this are approximately equals. Only two curves of the same class can be approximately equals, for comparison between different type of curves see isEquivalent

Parameters
otherthe other curve to check
precthe precision treshold, default Eigen::NumTraits<Numeric>::dummy_precision()
Returns
true is the two curves are approximately equals

◆ isApprox() [2/2]

virtual bool curves::helpers::rotation_spline::isApprox ( const curve_abc_quat_t other,
const Numeric  prec = Eigen::NumTraits<Numeric>::dummy_precision() 
) const
inlinevirtual

◆ max()

virtual time_t curves::helpers::rotation_spline::max ( ) const
inlinevirtual

Get the maximum time for which the curve is defined.

Returns
$t_{max}$, upper bound of time range.

Implements curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >.

◆ min()

virtual time_t curves::helpers::rotation_spline::min ( ) const
inlinevirtual

Get the minimum time for which the curve is defined.

Returns
$t_{min}$, lower bound of time range.

Implements curves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >.

◆ operator!=()

virtual bool curves::helpers::rotation_spline::operator!= ( const rotation_spline other) const
inlinevirtual

◆ operator()()

quat_t curves::helpers::rotation_spline::operator() ( const Numeric  t) const
inline

◆ operator=()

rotation_spline& curves::helpers::rotation_spline::operator= ( const rotation_spline from)
inline

◆ operator==()

virtual bool curves::helpers::rotation_spline::operator== ( const rotation_spline other) const
inlinevirtual

Member Data Documentation

◆ dim_

std::size_t curves::helpers::rotation_spline::dim_

◆ max_

double curves::helpers::rotation_spline::max_

◆ min_

double curves::helpers::rotation_spline::min_

◆ quat_from_

Eigen::Quaterniond curves::helpers::rotation_spline::quat_from_

◆ quat_to_

Eigen::Quaterniond curves::helpers::rotation_spline::quat_to_

◆ time_reparam_

exact_cubic_constraint_one_dim curves::helpers::rotation_spline::time_reparam_

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