template<class vec_t, class vec2_t = vec_t>
class o2scl::interp_base< vec_t, vec2_t >
See also the Interpolation section of the O2scl User's guide.
To interpolate a set vectors x
and y
, call set() and then the interpolation functions eval(), deriv(), deriv2() and integ(). If the x
and y
vectors do not change, then you may call the interpolation functions multiple times in succession. These classes do not copy the user-specified vectors but store pointers to them. Thus, if the vector is changed without a new call to interp_base::set(), the behavior of the interpolation functions is undefined.
Definition at line 107 of file interp.h.
|
virtual void | set (size_t size, const vec_t &x, const vec2_t &y)=0 |
| Initialize interpolation routine.
|
|
virtual double | eval (double x0) const =0 |
| Give the value of the function .
|
|
virtual double | operator() (double x0) const |
| Give the value of the function .
|
|
virtual double | deriv (double x0) const =0 |
| Give the value of the derivative .
|
|
virtual double | deriv2 (double x0) const =0 |
| Give the value of the second derivative .
|
|
virtual double | integ (double a, double b) const =0 |
| Give the value of the integral .
|
|
virtual const char * | type () const =0 |
| Return the type.
|
|