|
Theoretica
Mathematical Library
|
A natural cubic spline interpolation class. More...
#include <splines.h>
Public Member Functions | |
| template<typename DataPoints = std::vector<vec2>> | |
| spline (const DataPoints &p) | |
| Construct the natural cubic spline interpolation from a vector of coordinate pairs. | |
| template<typename Dataset1 , typename Dataset2 > | |
| spline (const Dataset1 &X, const Dataset2 &Y) | |
| Construct the natural cubic spline interpolation from the sets of X and Y data points. | |
| spline & | operator= (const spline &other) |
| Copy from another spline. | |
| real | operator() (real x) const |
| Evaluate the natural cubic spline interpolation at a given point. | |
| real | deriv (real x) const |
| Evaluate the derivative of the natural cubic spline interpolation at a given point. | |
| auto | begin () |
| Get an iterator to the first spline element. | |
| auto | end () |
| Get an iterator to one plus the last spline element. | |
Public Attributes | |
| std::vector< spline_node > | nodes |
| The computed nodes of the natural cubic spline interpolation over the points. | |
A natural cubic spline interpolation class.