imaging::PeriodicBspline< DATA_t > Class Template Reference
[B-Spline Module]

Class template for periodic B-Splines of arbitrary data type. More...

#include <PeriodicBspline.hpp>

Inheritance diagram for imaging::PeriodicBspline< DATA_t >:

imaging::Bspline< DATA_t >

List of all members.

Public Member Functions

 PeriodicBspline (const PeriodicBspline &source)
 PeriodicBspline (size_t spline_order, size_t n_coefficients)
const PeriodicBsplineoperator= (const PeriodicBspline &rhs)
size_t spline_order () const
float_t knot (size_t i) const
float_t first_knot () const
float_t last_knot () const
void set_knot (size_t i, float_t value)
void set_coefficient (size_t i, const DATA_t &value)
const DATA_t & coefficient (size_t i) const
void resize (size_t spline_order, size_t n_coefficients)
size_t n_coefficients () const
size_t n_knots () const
DATA_t operator() (float_t t, DATA_t &first_derivative) const
DATA_t operator() (float_t t) const
DATA_t operator() (float_t t, DATA_t &first_derivative, DATA_t &second_derivative) const
void regular_knots (float_t x_0, float_t x_1)
bool is_in_basis_spline_support (size_t i, float_t t) const


Detailed Description

template<class DATA_t>
class imaging::PeriodicBspline< DATA_t >

Class template for periodic B-Splines of arbitrary data type.

This class template implements a periodic B-Spline of spline arbitrary order. For template parameter DATA_t vector space operations (scalar multiplication, addition) and explicit construction from a float value must be implemented. Instantiating this class for 2-dimensional vectors creates a closed B-Spline curve.

The last knot of a periodic B-spline is identified with the first one, i.e. the number of knots equals the number of coefficients plus 1. E.g. the knot vector [1, 2, 3, 4] corresponds to an equilateral "knot triangle".

See also:
Bspline

Constructor & Destructor Documentation

template<class DATA_t>
imaging::PeriodicBspline< DATA_t >::PeriodicBspline ( const PeriodicBspline< DATA_t > &  source  )  [inline]

Copy constructor.

template<class DATA_t>
imaging::PeriodicBspline< DATA_t >::PeriodicBspline ( size_t  spline_order,
size_t  n_coefficients 
) [inline]

Construct a periodic B-Spline of spline_order with n_coefficients. The number of knots is then the number of coefficients plus 1.


Member Function Documentation

template<class DATA_t>
const PeriodicBspline& imaging::PeriodicBspline< DATA_t >::operator= ( const PeriodicBspline< DATA_t > &  rhs  )  [inline]

Copy assignement.

template<class DATA_t>
size_t imaging::PeriodicBspline< DATA_t >::spline_order (  )  const [inline]

template<class DATA_t>
float_t imaging::PeriodicBspline< DATA_t >::knot ( size_t  i  )  const [inline]

template<class DATA_t>
float_t imaging::PeriodicBspline< DATA_t >::first_knot (  )  const [inline]

Returns the first knot.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
float_t imaging::PeriodicBspline< DATA_t >::last_knot (  )  const [inline]

Returns the last knot.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
void imaging::PeriodicBspline< DATA_t >::set_knot ( size_t  i,
float_t  value 
) [inline]

template<class DATA_t>
void imaging::PeriodicBspline< DATA_t >::set_coefficient ( size_t  i,
const DATA_t &  value 
) [inline]

Sets the i-th coefficient to value.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
const DATA_t& imaging::PeriodicBspline< DATA_t >::coefficient ( size_t  i  )  const [inline]

Returns the i-th coefficient.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
void imaging::PeriodicBspline< DATA_t >::resize ( size_t  spline_order,
size_t  n_coefficients 
) [inline]

Sets the order of the B-Spline to spline_order and its number of coefficients to n_coefficients.

Reimplemented from imaging::Bspline< DATA_t >.

Referenced by imaging::PeriodicBspline< boost::numeric::ublas::fixed_vector< double, 2 > >::PeriodicBspline().

template<class DATA_t>
size_t imaging::PeriodicBspline< DATA_t >::n_coefficients (  )  const [inline]

template<class DATA_t>
size_t imaging::PeriodicBspline< DATA_t >::n_knots (  )  const [inline]

template<class DATA_t>
DATA_t imaging::PeriodicBspline< DATA_t >::operator() ( float_t  t,
DATA_t &  first_derivative 
) const [inline]

Evaluates the B-Spline at t and computes its first_derivative at t. If t is outside the spline support, first_derivative is set to 0 and 0 is returned.

Reimplemented from imaging::Bspline< DATA_t >.

Referenced by imaging::PeriodicBspline< boost::numeric::ublas::fixed_vector< double, 2 > >::operator()().

template<class DATA_t>
DATA_t imaging::PeriodicBspline< DATA_t >::operator() ( float_t  t  )  const [inline]

Evaluates the B-Spline at t. If t is outside the spline support, 0 is returned.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
DATA_t imaging::PeriodicBspline< DATA_t >::operator() ( float_t  t,
DATA_t &  first_derivative,
DATA_t &  second_derivative 
) const [inline]

Evaluates the B-Spline at t and computes its first_derivative and second_derivative at t. If t is outside the spline support, first_derivative and second_derivative are set to 0 and 0 is returned.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
void imaging::PeriodicBspline< DATA_t >::regular_knots ( float_t  x_0,
float_t  x_1 
) [inline]

Initializes the knots of the B-Spline to be equally distributed between x_0 and x_1.

Reimplemented from imaging::Bspline< DATA_t >.

template<class DATA_t>
bool imaging::PeriodicBspline< DATA_t >::is_in_basis_spline_support ( size_t  i,
float_t  t 
) const [inline]

Returns true if t is in the support of the i-th basis spline defined by the current knots of this spline.

Reimplemented from imaging::Bspline< DATA_t >.


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

Generated on Tue Feb 10 10:01:31 2009 for imaging2 by  doxygen 1.5.5