Represents a curve of dimension Dim. If value of parameter Safe is false, no verification is made on the evaluation of the curve.
More...
|
| curve_abc () |
| Constructor.
|
|
virtual | ~curve_abc () |
| Destructor.
|
|
virtual point_t | operator() (const time_t t) const =0 |
| Evaluation of the cubic spline at time t.
|
|
virtual curve_derivate_t * | compute_derivate_ptr (const std::size_t order) const =0 |
| Compute the derived curve at order N.
|
|
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.
|
|
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 threshold. This test is done by discretizing both curves and evaluating them and their derivatives.
|
|
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 threshold Only two curves of the same class can be approximately equal, for comparison between different type of curves see isEquivalent.
|
|
virtual std::size_t | dim () const =0 |
| Get dimension of curve.
|
|
virtual time_t | min () const =0 |
| Get the minimum time for which the curve is defined.
|
|
virtual time_t | max () const =0 |
| Get the maximum time for which the curve is defined.
|
|
virtual std::size_t | degree () const =0 |
| Get the degree of the curve.
|
|
std::pair< time_t, time_t > | timeRange () |
|
template<class Archive > |
void | serialize (Archive &ar, const unsigned int version) |
|
template<class Derived > |
void | loadFromText (const std::string &filename) |
| Loads a Derived object from a text file.
|
|
template<class Derived > |
void | saveAsText (const std::string &filename) const |
| Saved a Derived object as a text file.
|
|
template<class Derived > |
void | loadFromXML (const std::string &filename, const std::string &tag_name) |
| Loads a Derived object from an XML file.
|
|
template<class Derived > |
void | saveAsXML (const std::string &filename, const std::string &tag_name) const |
| Saved a Derived object as an XML file.
|
|
template<class Derived > |
void | loadFromBinary (const std::string &filename) |
| Loads a Derived object from an binary file.
|
|
template<class Derived > |
void | saveAsBinary (const std::string &filename) const |
| Saved a Derived object as an binary file.
|
|
template<
typename Time = double,
typename Numeric = Time,
bool Safe = false,
typename Point = Eigen::Matrix<Numeric, Eigen::Dynamic, 1>,
typename Point_derivate = Point>
struct ndcurves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >
Represents a curve of dimension Dim. If value of parameter Safe is false, no verification is made on the evaluation of the curve.
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.
Implemented in ndcurves::bezier_curve< Time, Numeric, Safe, Point >, ndcurves::cubic_hermite_spline< Time, Numeric, Safe, Point >, ndcurves::piecewise_curve< Time, Numeric, Safe, Point, Point_derivate, CurveType >, ndcurves::piecewise_curve< double, double, false, Eigen::Matrix< double, Eigen::Dynamic, 1 > >, ndcurves::piecewise_curve< Numeric, Numeric, Safe, point_one_dim_t >, ndcurves::polynomial< Time, Numeric, Safe, Point, T_Point >, ndcurves::SE3Curve< Time, Numeric, Safe >, ndcurves::sinusoidal< Time, Numeric, Safe, Point >, ndcurves::SO3Linear< Time, Numeric, Safe >, ndcurves::constant_curve< Time, Numeric, Safe, Point, Point_derivate >, and ndcurves::helpers::rotation_spline.
Evaluate the derivative of order N of curve at time t.
- Parameters
-
t | : time when to evaluate the spline. |
order | : order of derivative. |
- Returns
- \(\frac{d^Nx(t)}{dt^N}\), point corresponding on derivative curve of order N at time t.
Implemented in ndcurves::piecewise_curve< Time, Numeric, Safe, Point, Point_derivate, CurveType >, ndcurves::bezier_curve< Time, Numeric, Safe, Point >, ndcurves::cubic_hermite_spline< Time, Numeric, Safe, Point >, ndcurves::polynomial< Time, Numeric, Safe, Point, T_Point >, ndcurves::SE3Curve< Time, Numeric, Safe >, ndcurves::sinusoidal< Time, Numeric, Safe, Point >, ndcurves::SO3Linear< Time, Numeric, Safe >, and ndcurves::constant_curve< Time, Numeric, Safe, Point, Point_derivate >.
template<typename Time = double, typename Numeric = Time, bool Safe = false, typename Point = Eigen::Matrix<Numeric, Eigen::Dynamic, 1>, typename Point_derivate = Point>
virtual bool ndcurves::curve_abc< Time, Numeric, Safe, Point, Point_derivate >::isApprox |
( |
const curve_t * |
other, |
|
|
const Numeric |
prec = Eigen::NumTraits< Numeric >::dummy_precision() |
|
) |
| const |
|
pure virtual |
isApprox check if other and *this are approximately equal given a precision threshold Only two curves of the same class can be approximately equal, for comparison between different type of curves see isEquivalent.
- Parameters
-
other | the other curve to check |
prec | the precision threshold, default Eigen::NumTraits<Numeric>::dummy_precision() |
- Returns
- true if the two curves are approximately equal
Implemented in ndcurves::piecewise_curve< Time, Numeric, Safe, Point, Point_derivate, CurveType >, ndcurves::SE3Curve< Time, Numeric, Safe >, and ndcurves::SO3Linear< Time, Numeric, Safe >.