|
QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.38
|
Integral of a one-dimensional function. More...
#include <filonintegral.hpp>
Inheritance diagram for FilonIntegral:
Collaboration diagram for FilonIntegral:Public Types | |
| enum | Type { Sine , Cosine } |
Public Member Functions | |
| FilonIntegral (Type type, Real t, Size intervals) | |
Public Member Functions inherited from Integrator | |
| Integrator (Real absoluteAccuracy, Size maxEvaluations) | |
| virtual | ~Integrator ()=default |
| Real | operator() (const std::function< Real(Real)> &f, Real a, Real b) const |
| void | setAbsoluteAccuracy (Real) |
| void | setMaxEvaluations (Size) |
| Real | absoluteAccuracy () const |
| Size | maxEvaluations () const |
| Real | absoluteError () const |
| Size | numberOfEvaluations () const |
| virtual bool | integrationSuccess () const |
Protected Member Functions | |
| Real | integrate (const std::function< Real(Real)> &f, Real a, Real b) const override |
Protected Member Functions inherited from Integrator | |
| void | setAbsoluteError (Real error) const |
| void | setNumberOfEvaluations (Size evaluations) const |
| void | increaseNumberOfEvaluations (Size increase) const |
Private Attributes | |
| const Type | type_ |
| const Real | t_ |
| const Size | intervals_ |
| const Size | n_ |
Integral of a one-dimensional function.
Given a number \( N \) of intervals, the integral of a function \( f \) between \( a \) and \( b \) is calculated by means of Filon's sine and cosine integrals
References: Abramowitz, M. and Stegun, I. A. (Eds.). Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables, 9th printing. New York: Dover, pp. 890-891, 1972.
Definition at line 46 of file filonintegral.hpp.
| enum Type |
| Enumerator | |
|---|---|
| Sine | |
| Cosine | |
Definition at line 48 of file filonintegral.hpp.
| FilonIntegral | ( | Type | type, |
| Real | t, | ||
| Size | intervals | ||
| ) |
Definition at line 33 of file filonintegral.cpp.
|
overrideprotectedvirtual |
Implements Integrator.
Definition at line 42 of file filonintegral.cpp.
Here is the call graph for this function:
|
private |
Definition at line 55 of file filonintegral.hpp.
|
private |
Definition at line 56 of file filonintegral.hpp.
|
private |
Definition at line 57 of file filonintegral.hpp.
|
private |
Definition at line 57 of file filonintegral.hpp.