RobWorkProject  24.5.15-
Static Public Member Functions | List of all members
CubicSplineFactory Class Reference

Factory for creating cubic splines. More...

#include <CubicSplineFactory.hpp>

Static Public Member Functions

static rw::core::Ptr< InterpolatorTrajectory< rw::math::Q > > makeNaturalSpline (rw::core::Ptr< rw::trajectory::Path< rw::math::Q >> qpath, double timeStep=1.0)
 constructs a free/natural cubic spline A natural cubic spline has free boundary conditions. Only one condition can be said for the end points namely acceleration is zero. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Q > > makeNaturalSpline (rw::core::Ptr< rw::trajectory::Path< rw::trajectory::Timed< rw::math::Q >>> tqpath)
 constructs a natural cubic spline, see above. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Q > > makeNaturalSpline (const rw::trajectory::Path< rw::math::Q > &qpath, const std::vector< double > &times)
 Construct a natural cubic spline. See documentation of CubicSplineFactory::makeNaturalSpline(QPath::Ptr, double) More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Transform3DVector< double > > > makeNaturalSpline (const rw::trajectory::Path< rw::math::Transform3D< double >> &path, double timeStep=1.0)
 constructs a free/natural cubic spline A natural cubic spline has free boundary conditions. Only one condition can be said for the end points namely acceleration is zero. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Transform3DVector< double > > > makeNaturalSpline (const rw::trajectory::Path< rw::trajectory::Timed< rw::math::Transform3D< double >>> &path)
 constructs a natural cubic spline, see above. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Transform3DVector< double > > > makeNaturalSpline (const rw::trajectory::Path< rw::math::Transform3D< double >> &path, const std::vector< double > &times)
 Construct a natural cubic spline. See documentation of CubicSplineFactory::makeNaturalSpline(QPath::Ptr, double) More...
 
template<typename T >
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< T > > makeNaturalSpline (const rw::trajectory::Path< T > &path, double timeStep=1.0)
 constructs a free/natural cubic spline A natural cubic spline has free boundary conditions. Only one condition can be said for the end points namely acceleration is zero. More...
 
template<typename T >
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< T > > makeNaturalSpline (const rw::trajectory::Path< rw::trajectory::Timed< T >> &path)
 constructs a natural cubic spline, see above. More...
 
template<typename T >
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< T > > makeNaturalSpline (const rw::trajectory::Path< T > &path, const std::vector< double > &times)
 Construct a natural cubic spline. See documentation of CubicSplineFactory::makeNaturalSpline(QPath::Ptr, double) More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Q > > makeClampedSpline (rw::core::Ptr< rw::trajectory::Path< rw::math::Q >> qpath, const rw::math::Q &dqStart, const rw::math::Q &dqEnd, double timeStep=1.0)
 creates a clamped spline trajectory with equally spaced via points. That is time between samples is 1. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Q > > makeClampedSpline (rw::core::Ptr< rw::trajectory::Path< rw::trajectory::Timed< rw::math::Q >>> tqpath, const rw::math::Q &dqStart, const rw::math::Q &dqEnd)
 creates a clamped spline trajectory where the timed label is used to determine the time between samples. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points. More...
 
template<typename T >
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< T > > makeClampedSpline (const rw::trajectory::Path< T > &path, const T &dStart, const T &dEnd, double timeStep=1.0)
 creates a clamped spline trajectory with equally spaced via points. That is time between samples is 1. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points. More...
 
template<typename T >
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< T > > makeClampedSpline (const rw::trajectory::Path< rw::trajectory::Timed< T >> &tpath, const T &dStart, const T &dEnd)
 creates a clamped spline trajectory where the timed label is used to determine the time between samples. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points. More...
 
template<typename T >
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< T > > makeClampedSpline (const rw::trajectory::Path< T > &path, const std::vector< double > &times, const T &dStart, const T &dEnd)
 creates a clamped spline trajectory where the timed label is used to determine the time between samples. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Quaternion< double > > > makeSQUAD (const rw::trajectory::Path< rw::math::Quaternion< double >> &path, double timeStep=1.0)
 constructs a Spherical Spline Quaternion interpolation (SQUAD) A natural SQUAD has free boundary conditions. The SQUAD passes through each data point. The SQUAD forms a continuous function over [a,b]. The SQUAD forms a smooth function. The second derivative is continuous. More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Quaternion< double > > > makeSQUAD (const rw::trajectory::Path< rw::trajectory::Timed< rw::math::Quaternion< double >>> &tpath)
 constructs a Spherical Spline Quaternion interpolation (SQUAD) More...
 
static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory< rw::math::Quaternion< double > > > makeSQUAD (const rw::trajectory::Path< rw::math::Quaternion< double >> &path, const std::vector< double > &times)
 constructs a Spherical Spline Quaternion interpolation (SQUAD) More...
 

Detailed Description

Factory for creating cubic splines.

Member Function Documentation

◆ makeClampedSpline() [1/5]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<T> > makeClampedSpline ( const rw::trajectory::Path< rw::trajectory::Timed< T >> &  tpath,
const T &  dStart,
const T &  dEnd 
)
static

creates a clamped spline trajectory where the timed label is used to determine the time between samples. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points.

Parameters
tpath[in] the path over which the spline should be generated.
dStart[in] the velocity in the first point
dEnd[in] the velocity in the last point.
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeClampedSpline() [2/5]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<T> > makeClampedSpline ( const rw::trajectory::Path< T > &  path,
const std::vector< double > &  times,
const T &  dStart,
const T &  dEnd 
)
static

creates a clamped spline trajectory where the timed label is used to determine the time between samples. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points.

Parameters
path[in] the path over which the spline should be generated.
times[in] the times associated to the configurations in path.
dStart[in] the velocity in the first point
dEnd[in] the velocity in the last point.
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeClampedSpline() [3/5]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<T> > makeClampedSpline ( const rw::trajectory::Path< T > &  path,
const T &  dStart,
const T &  dEnd,
double  timeStep = 1.0 
)
static

creates a clamped spline trajectory with equally spaced via points. That is time between samples is 1. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points.

Parameters
path[in] the path over which the spline should be generated.
dStart[in] the velocity in the first point
dEnd[in] the velocity in the last point.
timeStepdocumentation missing !
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeClampedSpline() [4/5]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<rw::math::Q> > makeClampedSpline ( rw::core::Ptr< rw::trajectory::Path< rw::math::Q >>  qpath,
const rw::math::Q dqStart,
const rw::math::Q dqEnd,
double  timeStep = 1.0 
)
static

creates a clamped spline trajectory with equally spaced via points. That is time between samples is 1. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points.

Parameters
qpath[in] the path over which the spline should be generated.
dqStart[in] the velocity in the first point
dqEnd[in] the velocity in the last point.
timeStepdocumentation missing !
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeClampedSpline() [5/5]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<rw::math::Q> > makeClampedSpline ( rw::core::Ptr< rw::trajectory::Path< rw::trajectory::Timed< rw::math::Q >>>  tqpath,
const rw::math::Q dqStart,
const rw::math::Q dqEnd 
)
static

creates a clamped spline trajectory where the timed label is used to determine the time between samples. A clamped spline controls the velocity in the end points. The acceleration is 0 in the end points.

Parameters
tqpath[in] the path over which the spline should be generated.
dqStart[in] the velocity in the first point
dqEnd[in] the velocity in the last point.
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeNaturalSpline() [1/9]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<rw::math::Q> > makeNaturalSpline ( const rw::trajectory::Path< rw::math::Q > &  qpath,
const std::vector< double > &  times 
)
static

Construct a natural cubic spline. See documentation of CubicSplineFactory::makeNaturalSpline(QPath::Ptr, double)

Parameters
qpath[in] Path to follow
times[in] Times associated to the different configurations in qpath
Returns
a trajectory of CubicSplineInterpolators

◆ makeNaturalSpline() [2/9]

static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory<rw::math::Transform3DVector<double> > > makeNaturalSpline ( const rw::trajectory::Path< rw::math::Transform3D< double >> &  path,
const std::vector< double > &  times 
)
static

Construct a natural cubic spline. See documentation of CubicSplineFactory::makeNaturalSpline(QPath::Ptr, double)

Parameters
path[in] Path to follow
times[in] Times associated to the different configurations in path
Returns
a trajectory of CubicSplineInterpolators

◆ makeNaturalSpline() [3/9]

static rw::core::Ptr< rw::trajectory::InterpolatorTrajectory<rw::math::Transform3DVector<double> > > makeNaturalSpline ( const rw::trajectory::Path< rw::math::Transform3D< double >> &  path,
double  timeStep = 1.0 
)
static

constructs a free/natural cubic spline A natural cubic spline has free boundary conditions. Only one condition can be said for the end points namely acceleration is zero.

  • The spline passes through each data point.
  • The spline forms a continuous function over [a,b].
  • The spline forms a smooth function.
  • The second derivative is continuous.
Parameters
path[in] a list of points that the spline should intersect
timeStep[in] the duration of each spline path

◆ makeNaturalSpline() [4/9]

constructs a natural cubic spline, see above.

Parameters
path[in] a list of points with associated timestaps. The spline will intersect the points at the time specified in tqpath
Returns
a trajectory of CubicSplineInterpolators

◆ makeNaturalSpline() [5/9]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<T> > makeNaturalSpline ( const rw::trajectory::Path< rw::trajectory::Timed< T >> &  path)
static

constructs a natural cubic spline, see above.

Parameters
path[in] a list of points with associated timestaps. The spline will intersect the points at the time specified in tqpath
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeNaturalSpline() [6/9]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<T> > makeNaturalSpline ( const rw::trajectory::Path< T > &  path,
const std::vector< double > &  times 
)
static

Construct a natural cubic spline. See documentation of CubicSplineFactory::makeNaturalSpline(QPath::Ptr, double)

Parameters
path[in] Path to follow
times[in] Times associated to the different configurations in path
Returns
a trajectory of CubicSplineInterpolators
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeNaturalSpline() [7/9]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<T> > makeNaturalSpline ( const rw::trajectory::Path< T > &  path,
double  timeStep = 1.0 
)
static

constructs a free/natural cubic spline A natural cubic spline has free boundary conditions. Only one condition can be said for the end points namely acceleration is zero.

  • The spline passes through each data point.
  • The spline forms a continuous function over [a,b].
  • The spline forms a smooth function.
  • The second derivative is continuous.
Parameters
path[in] a list of points that the spline should intersect
timeStep[in] the duration of each spline path
Returns
the Interpolated Trajectory of the Cubic spline
Note
the following template parameters are currently supported: Transform3DVector, Vector3D, Quaternion

◆ makeNaturalSpline() [8/9]

static rw::core::Ptr<InterpolatorTrajectory<rw::math::Q> > makeNaturalSpline ( rw::core::Ptr< rw::trajectory::Path< rw::math::Q >>  qpath,
double  timeStep = 1.0 
)
static

constructs a free/natural cubic spline A natural cubic spline has free boundary conditions. Only one condition can be said for the end points namely acceleration is zero.

  • The spline passes through each data point.
  • The spline forms a continuous function over [a,b].
  • The spline forms a smooth function.
  • The second derivative is continuous.
Parameters
qpath[in] a list of points that the spline should intersect
timeStep[in] the duration of each spline path

◆ makeNaturalSpline() [9/9]

constructs a natural cubic spline, see above.

Parameters
tqpath[in] a list of points with associated timestaps. The spline will intersect the points at the time specified in tqpath
Returns
a trajectory of CubicSplineInterpolators

◆ makeSQUAD() [1/3]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<rw::math::Quaternion<double> > > makeSQUAD ( const rw::trajectory::Path< rw::math::Quaternion< double >> &  path,
const std::vector< double > &  times 
)
static

constructs a Spherical Spline Quaternion interpolation (SQUAD)

Parameters
path[in] Path to follow
times[in] Times associated to the different configurations in qpath
Returns
a trajectory of CubicSplineInterpolators

◆ makeSQUAD() [2/3]

static rw::core::Ptr<rw::trajectory::InterpolatorTrajectory<rw::math::Quaternion<double> > > makeSQUAD ( const rw::trajectory::Path< rw::math::Quaternion< double >> &  path,
double  timeStep = 1.0 
)
static

constructs a Spherical Spline Quaternion interpolation (SQUAD) A natural SQUAD has free boundary conditions. The SQUAD passes through each data point. The SQUAD forms a continuous function over [a,b]. The SQUAD forms a smooth function. The second derivative is continuous.

Parameters
path[in] a list of points that the SQUAD should intersect
timeStep[in] the duration of each SQUAD path
Returns
a trajectory of SQUADInterpolators

◆ makeSQUAD() [3/3]

constructs a Spherical Spline Quaternion interpolation (SQUAD)

Parameters
tpath[in] a list of points with associated timestaps. The SQUAD will intersect the points at the time specified in tpath
Returns
a trajectory of SQUADInterpolators

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