Celeritas
0.5.0-86+4a8eea4
|
Perform numerical integration of a generic 1-D function. More...
#include <Integrator.hh>
Public Types | |
Type aliases | |
using | argument_type = real_type |
using | result_type = real_type |
using | Options = IntegratorOptions |
Public Member Functions | |
Integrator (F &&func, Options opts) | |
Construct with the function and options. | |
Integrator (F &&func) | |
Construct with the function and default options. | |
result_type | operator() (argument_type lo, argument_type hi) |
Calculate the integral over the given dx. | |
Perform numerical integration of a generic 1-D function.
Currently this is a simple nonrecursive Newton-Coates integrator extracted from NuclearZoneBuilder. It should be improved for robustness, accuracy, and efficiency, probably by using a Gauss-Legendre quadrature.
This class is to be used only during setup.