|
RandLib 2.0.0
Probability distributions, fitting, and heavy-tail tools for C++20
|
#include <bit>#include <cmath>#include <concepts>#include <cstdint>#include <limits>#include <random>#include <type_traits>

Go to the source code of this file.
Classes | |
| class | randlib::detail::EngineRef |
| The EngineRef class Non-owning, type-erased reference to any uniform random bit generator. More... | |
Namespaces | |
| namespace | randlib |
| namespace | randlib::detail |
Functions | |
| template<std::uniform_random_bit_generator G> | |
| constexpr int | randlib::detail::engineBits () noexcept |
| Number of uniformly distributed bits in one output of G: floor(log2(max - min + 1)) | |
| template<std::uniform_random_bit_generator G> | |
| std::uint64_t | randlib::detail::randomBits (G &g, int count) |
| template<std::floating_point Real, std::uniform_random_bit_generator G> | |
| Real | randlib::detail::uniform01 (G &g) |
| template<std::floating_point Real, std::uniform_random_bit_generator G> | |
| Real | randlib::detail::uniform01Closed (G &g) |
| k / (2^b - 1) for b = min(digits, 64) random bits: uniform on [0, 1] | |
| template<std::floating_point Real, std::uniform_random_bit_generator G> | |
| Real | randlib::detail::uniform01HalfClosed (G &g) |
| k / 2^b for b = min(digits, 64) random bits: uniform on [0, 1) | |
| template<std::uniform_random_bit_generator G> | |
| std::uint64_t | randlib::detail::uniformBelow (G &g, std::uint64_t n) |