|
| constexpr | rng (std::uint64_t seed) noexcept |
| | Construct from a seed.
|
| |
| constexpr rng & | seed (std::uint64_t seed) noexcept |
| | Reset the engine to the start of the sequence for a seed.
|
| |
| rng & | unseed () |
| | Reseed from std::random_device.
|
| |
| constexpr std::uint64_t | seed () const noexcept |
| | The seed this engine was last seeded with.
|
| |
| constexpr result_type | operator() () noexcept |
| | Advance and return the next value.
|
| |
| constexpr std::uint64_t | child_seed (std::string_view label) const noexcept |
| | Derive the child seed for a label.
|
| |
| constexpr std::uint64_t | child_seed (std::uint64_t index) const noexcept |
| | Derive the child seed for an index.
|
| |
| constexpr rng | split (std::string_view label) const noexcept |
| | A child engine for a label, independent of this engine's state.
|
| |
| constexpr rng | split (std::uint64_t index) const noexcept |
| | A child engine for an index, independent of this engine's state.
|
| |
The core random engine: xoshiro256** (Blackman and Vigna 2018).
Satisfies std::uniform_random_bit_generator, but use the core's own distributions with it: the std:: distributions give different results on different standard libraries.
An engine remembers the seed it was built from. split() derives a child engine from that seed and a label, not from the current state, so the streams a generator hands to its parts do not shift when another part draws more or fewer numbers.
auto height = r.
split(
"height");
auto weight = r.
split(
"weight");
The core random engine: xoshiro256** (Blackman and Vigna 2018).
constexpr rng split(std::string_view label) const noexcept
A child engine for a label, independent of this engine's state.
Definition at line 107 of file rng.hpp.