Single-header C++ library for Monte Carlo (and not only) integration with support for multidimensional integrals and optional multithreading for faster computation.
integrate_MC- integration in 1D with Vegas optimisationintegrate_MC_ndim- integration for multidimensional integralsintegrate_MC_highdim- integration for multidimensional integrals, optimised for large number of dimensionsintegrate_MC_dist- integration with importance sampling
integrate_trapezoid- trapezoidal method with adaptive box partitionintegrate_simpson- Simpson's 1/3 trapezoidal method with adaptive box partition
See include/integrate_quadrature.hpp.
To configure the project and compile tests run:
./build.shTo bundle the library into a single header:
./amalgamate.shTo use the library in your own project download the generated all-in-one header in mc_integrate_cpp.hpp.
See the tests/ directory for example usage of all the integration functions.