RandLib 2.0.0
Probability distributions, fitting, and heavy-tail tools for C++20
Loading...
Searching...
No Matches
variates.hpp File Reference
#include <randlib/core/ziggurat_tables.hpp>
#include <randlib/engine/uniform.hpp>
#include <cmath>
#include <concepts>
#include <cstddef>
#include <random>
#include <stdexcept>
Include dependency graph for variates.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  randlib
 
namespace  randlib::detail
 

Functions

template<std::floating_point Real, std::uniform_random_bit_generator G>
Real randlib::detail::standardExponential (G &g)
 Ziggurat algorithm of Marsaglia and Tsang with 256 layers.
 
template<std::floating_point Real, std::uniform_random_bit_generator G>
Real randlib::detail::standardNormal (G &g)
 Ziggurat algorithm of Marsaglia and Tsang with 256 layers and an explicit sign bit.
 

Variables

constexpr std::size_t randlib::detail::MAX_ITER_REJECTION = 1000
 Upper bound on the iterations of rejection samplers; reaching it means there is a bug.