BSplinebasis
Loading...
Searching...
No Matches
Public Member Functions | List of all members
bspline::BSplineGenerator< T > Class Template Referencefinal

Generates the BSplines on a grid. More...

#include <BSplineGenerator.h>

Public Member Functions

 BSplineGenerator (std::vector< T > knots)
 Constructor generating the grid from the knots vector.
 
 BSplineGenerator (std::vector< T > knots, const Grid< T > &grid)
 Constructor using the provided grid instance.
 
Grid< TgetGrid () const
 Returns the grid.
 
template<size_t order>
std::vector< Spline< T, order > > generateBSplines () const
 Generates all BSplines with respect to the knots vector.
 

Detailed Description

template<typename T>
class bspline::BSplineGenerator< T >

Generates the BSplines on a grid.

Factory class generating all BSplines of a given order for a given knots vector.

Template Parameters
TThe datatype of the spline and grid.

Constructor & Destructor Documentation

◆ BSplineGenerator() [1/2]

template<typename T >
bspline::BSplineGenerator< T >::BSplineGenerator ( std::vector< T knots)
inlineexplicit

Constructor generating the grid from the knots vector.

Parameters
knotsThe knots, the BSplines shall be generated on.
Exceptions
BSplineExceptionIf the knots are not in increasing order.

◆ BSplineGenerator() [2/2]

template<typename T >
bspline::BSplineGenerator< T >::BSplineGenerator ( std::vector< T knots,
const Grid< T > &  grid 
)
inline

Constructor using the provided grid instance.

Parameters
knotsThe knots, the BSplines shall be generated on.
gridThe Grid instance to use. Must be logically equivalent to the Grid generated from knots. If that is not the case, an exception is thrown.
Exceptions
BSplineExceptionIf the knots are not in increasing order.
BSplineExceptionIf the grid derived from the knots vector is not logically equivalent to the Grid grid.

Member Function Documentation

◆ generateBSplines()

template<typename T >
template<size_t order>
std::vector< Spline< T, order > > bspline::BSplineGenerator< T >::generateBSplines ( ) const
inline

Generates all BSplines with respect to the knots vector.

Template Parameters
orderOrder of the BSplines to generate.
Exceptions
BSplineExceptionIf the knots vector does not contain enough entries to generate a spline of the requested order.
Returns
All BSplines of order order defined on the knots vector.

◆ getGrid()

template<typename T >
Grid< T > bspline::BSplineGenerator< T >::getGrid ( ) const
inline

Returns the grid.

Returns
The _grid member of this instance.

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