Cubic spline interpolation (GSL) More...
#include <interp.h>
See also the Interpolation section of the O2scl User's guide.
By default, this class uses natural boundary conditions, where the second derivative vanishes at each end point. Extrapolation effectively assumes that the second derivative is linear outside of the endpoints.
Public Types | |
| typedef boost::numeric::ublas::vector< double > | ubvector |
| typedef boost::numeric::ublas::vector_slice< ubvector > | ubvector_slice |
| typedef boost::numeric::ublas::vector_range< ubvector > | ubvector_range |
| typedef boost::numeric::ublas::slice | slice |
| typedef boost::numeric::ublas::range | range |
Public Member Functions | |
| interp_cspline () | |
| Create a base interpolation object with natural or periodic boundary conditions. | |
| virtual void | set (size_t size, const vec_t &xa, const vec2_t &ya) |
| Initialize interpolation routine. More... | |
| virtual double | eval (double x0) const |
Give the value of the function . | |
| virtual double | deriv (double x0) const |
Give the value of the derivative . | |
| virtual double | deriv2 (double x0) const |
Give the value of the second derivative . | |
| virtual double | integ (double a, double b) const |
Give the value of the integral . | |
| virtual const char * | type () const |
Return the type, "interp_cspline". | |
Public Member Functions inherited from o2scl::interp_base< vec_t, vec2_t > | |
| virtual double | operator() (double x0) const |
Give the value of the function . | |
Protected Member Functions | |
| void | coeff_calc (const ubvector &c_array, double dy, double dx, size_t index, double &b, double &c2, double &d) const |
| Compute coefficients for cubic spline interpolation. | |
Protected Member Functions inherited from o2scl::interp_base< vec_t, vec2_t > | |
| double | integ_eval (double ai, double bi, double ci, double di, double xi, double a, double b) const |
| An internal function to assist in computing the integral for both the cspline and Akima types. | |
Protected Attributes | |
| o2scl_linalg::ubvector_4_mem | p4m |
| Memory for the tridiagonalization. | |
Storage for cubic spline interpolation | |
| ubvector | c |
| ubvector | g |
| ubvector | diag |
| ubvector | offdiag |
Protected Attributes inherited from o2scl::interp_base< vec_t, vec2_t > | |
| search_vec< const vec_t > | svx |
| To perform binary searches. More... | |
| const vec_t * | px |
| Independent vector. | |
| const vec2_t * | py |
| Dependent vector. | |
| size_t | sz |
| Vector size. | |
Private Member Functions | |
| interp_cspline (const interp_cspline< vec_t, vec2_t > &) | |
| interp_cspline< vec_t, vec2_t > & | operator= (const interp_cspline< vec_t, vec2_t > &) |
Additional Inherited Members | |
Public Attributes inherited from o2scl::interp_base< vec_t, vec2_t > | |
| size_t | min_size |
| The minimum size of the vectors to interpolate between. More... | |
|
inlinevirtual |
Natural boundary conditions
Implements o2scl::interp_base< vec_t, vec2_t >.
Reimplemented in o2scl::interp_cspline_peri< vec_t, vec2_t >.
Documentation generated with Doxygen. Provided under the
GNU Free Documentation License (see License Information).