11#include <OpenMS/OpenMSConfig.h>
39 std::vector<double>
a_;
40 std::vector<double>
b_;
41 std::vector<double>
c_;
42 std::vector<double>
d_;
43 std::vector<double>
x_;
59 CubicSpline2d(
const std::vector<double>& x,
const std::vector<double>& y);
83 double eval(
double x)
const;
128 void init_(
const std::vector<double>& x,
const std::vector<double>& y);
Natural cubic-spline interpolation of a 2D data set.
Definition CubicSpline2d.h:37
std::vector< double > c_
Per-segment quadratic coefficient (degree 2); contains one extra trailing zero from the natural bound...
Definition CubicSpline2d.h:41
double derivative(double x) const
First derivative of the spline at x.
double eval(double x) const
Evaluate the spline at x.
std::vector< double > a_
Per-segment constant coefficient (degree 0); same value as the y at the segment's left knot.
Definition CubicSpline2d.h:39
std::vector< double > b_
Per-segment linear coefficient (degree 1).
Definition CubicSpline2d.h:40
CubicSpline2d(const std::map< double, double > &m)
Build the spline from a map of (x, y) knots.
void init_(const std::vector< double > &x, const std::vector< double > &y)
Initialise the spline coefficients from the supplied knots.
std::vector< double > x_
Sorted knot abscissae (length = number of segments + 1).
Definition CubicSpline2d.h:43
std::vector< double > d_
Per-segment cubic coefficient (degree 3).
Definition CubicSpline2d.h:42
CubicSpline2d(const std::vector< double > &x, const std::vector< double > &y)
Build the spline from parallel x / y vectors.
double derivatives(double x, unsigned order) const
Derivative of the spline at x.
Main OpenMS namespace.
Definition openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19