Expand description
Base formulas used elsewhere in the crate.
Constants§
- PCG_
MUL_ 64 - This is the suggested multiplier for a PCG with 64 bits of state.
Functions§
- ieee754_
random_ f32 - Generates an
f32
in the signed or unsigned unit range. - ieee754_
random_ f64 - Generates an
f64
in the signed or unsigned unit range. - lcg32_
jump - Advance a 32-bit LCG by
delta
steps inlog2(delta)
time. - lcg32_
step - Advance a 32-bit LCG’s state.
- lcg64_
jump - Advance a 32-bit LCG by
delta
steps inlog2(delta)
time. - lcg64_
step - Advance a 32-bit LCG’s state.
- lcg128_
jump - Advance a 32-bit LCG by
delta
steps inlog2(delta)
time. - lcg128_
step - Advance a 32-bit LCG’s state.
- next_
binary_ exp_ distr32 - Returns
k
with probability2^(-k-1)
, a “binary exponential distribution”. - xsh_
rr_ u64_ to_ u32 - “Xor-shift high bits” then “randomized rotate”,
u64
down tou32
. - xsl_
rr_ u128_ to_ u64 - “Xor-shift low bits” then “randomized rotate”,
u128
tou64
.