Numerical Differentiation on arbitrarily spaced grids. More...
#include <ql/methods/finitedifferences/operators/numericaldifferentiation.hpp>
Public Types | |
enum | Scheme { Central, Backward, Forward } |
typedef Real | argument_type |
typedef Real | result_type |
Public Member Functions | |
NumericalDifferentiation (const ext::function< Real(Real)> &f, Size orderOfDerivative, const Array &x_offsets) | |
NumericalDifferentiation (const ext::function< Real(Real)> &f, Size orderOfDerivative, Real stepSize, Size steps, Scheme scheme) | |
Real | operator() (Real x) const |
const Array & | offsets () const |
const Array & | weights () const |
Numerical Differentiation on arbitrarily spaced grids.
References:
B. Fornberg, 1988. Generation of Finite Difference Formulas on Arbitrarily Spaced Grids, http://amath.colorado.edu/faculty/fornberg/Docs/MathComp_88_FD_formulas.pdf