Class describing a Chebyshev series which can be used to approximate a function in a defined range [a,b] using Chebyshev polynomials.
It uses the algorithm from GSL
This class does not support copying
Definition at line 71 of file ChebyshevApprox.h.
Public Member Functions | |
ChebyshevApprox (ChebyshevApprox &&)=delete | |
ChebyshevApprox (const ChebyshevApprox &)=delete | |
ChebyshevApprox (const ROOT::Math::IGenFunction &f, double a, double b, size_t n) | |
Construct a Chebyshev series approximation to a Function f in range [a,b]; constructor based on functions of type IGenFunction. | |
ChebyshevApprox (GSLFuncPointer f, void *p, double a, double b, size_t n) | |
Construct a Chebyshev series approximation to a Function f in range [a,b]; constructor based on free functions with gsl_function type signature. | |
virtual | ~ChebyshevApprox () |
ChebyshevApprox * | Deriv () |
Compute the derivative of the series and return a pointer to a new Chebyshev series with the derivatives coefficients. | |
std::pair< double, double > | EvalErr (double x) const |
Evaluate the series at a given point x estimating both the series result and its absolute error. | |
std::pair< double, double > | EvalErr (double x, size_t n) const |
evaluate the series at a given point x to the given order n, estimating both the series result and its absolute error. | |
ChebyshevApprox * | Integral () |
Compute the integral of the series and return a pointer to a new Chebyshev series with the integral coefficients. | |
double | operator() (double x) const |
Evaluate the series at a given point x. | |
double | operator() (double x, size_t n) const |
Evaluate the series at a given point, to (at most) the given order n. | |
ChebyshevApprox & | operator= (ChebyshevApprox &&)=delete |
ChebyshevApprox & | operator= (const ChebyshevApprox &)=delete |
Protected Member Functions | |
void | Initialize (GSLFuncPointer f, void *params, double a, double b) |
Initialize series passing function and range. | |
Private Member Functions | |
ChebyshevApprox (size_t n) | |
construct a Chebyshev series or order n The series must be initialized from a function | |
Private Attributes | |
GSLFunctionWrapper * | fFunction |
size_t | fOrder |
GSLChebSeries * | fSeries |
#include <Math/ChebyshevApprox.h>
ROOT::Math::ChebyshevApprox::ChebyshevApprox | ( | const ROOT::Math::IGenFunction & | f, |
double | a, | ||
double | b, | ||
size_t | n | ||
) |
Construct a Chebyshev series approximation to a Function f in range [a,b]; constructor based on functions of type IGenFunction.
Definition at line 49 of file ChebyshevApprox.cxx.
ROOT::Math::ChebyshevApprox::ChebyshevApprox | ( | GSLFuncPointer | f, |
void * | p, | ||
double | a, | ||
double | b, | ||
size_t | n | ||
) |
Construct a Chebyshev series approximation to a Function f in range [a,b]; constructor based on free functions with gsl_function type signature.
Definition at line 60 of file ChebyshevApprox.cxx.
|
virtual |
Definition at line 68 of file ChebyshevApprox.cxx.
|
private |
construct a Chebyshev series or order n The series must be initialized from a function
Definition at line 75 of file ChebyshevApprox.cxx.
|
delete |
|
delete |
ChebyshevApprox * ROOT::Math::ChebyshevApprox::Deriv | ( | ) |
Compute the derivative of the series and return a pointer to a new Chebyshev series with the derivatives coefficients.
The returned pointer must be managed by the user.
Definition at line 120 of file ChebyshevApprox.cxx.
Evaluate the series at a given point x estimating both the series result and its absolute error.
The error estimate is made from the first neglected term in the series. A pair containing result and error is returned
Definition at line 101 of file ChebyshevApprox.cxx.
evaluate the series at a given point x to the given order n, estimating both the series result and its absolute error.
The error estimate is made from the first neglected term in the series. A pair containing result and error is returned
Definition at line 113 of file ChebyshevApprox.cxx.
|
protected |
Initialize series passing function and range.
Definition at line 82 of file ChebyshevApprox.cxx.
ChebyshevApprox * ROOT::Math::ChebyshevApprox::Integral | ( | ) |
Compute the integral of the series and return a pointer to a new Chebyshev series with the integral coefficients.
The lower limit of the integration is the left range value a. The returned pointer must be managed by the user
Definition at line 130 of file ChebyshevApprox.cxx.
Evaluate the series at a given point x.
Definition at line 96 of file ChebyshevApprox.cxx.
Evaluate the series at a given point, to (at most) the given order n.
Definition at line 108 of file ChebyshevApprox.cxx.
|
delete |
|
delete |
|
private |
Definition at line 161 of file ChebyshevApprox.h.
|
private |
Definition at line 158 of file ChebyshevApprox.h.
|
private |
Definition at line 160 of file ChebyshevApprox.h.