A probability represented as a threshold over all possible u64 samples.
Ratios are rounded down to the nearest multiple of 2^-64. Sampling consumes one u64 for
probabilities strictly between zero and one, and consumes no randomness for either endpoint.
Given the same sequence of u64 samples, decisions are identical on every platform.
Creates a probability from an f64 that maps exactly to a 64-bit threshold.
Returns None if value is not finite, is outside [0, 1], or would require rounding.
The exact IEEE-754 value is preserved rather than interpreting its source spelling as a
decimal ratio. Use TryFrom when const evaluation is not required.
Converts this probability to an f64 in the inclusive range [0, 1].
This conversion is intended for APIs that require floating-point probabilities. Interior
probabilities remain strictly below one even when rounding to f64.