oa::Random
Random class in the OA Core public surface.
Public Types
Public Methods
Constructor & Destructor Documentation
Fixed default seed → reproducible by default. Provide a seed for a specific stream; inSeq selects an independent stream for the same seed (two generators with the same seed but different inSeq never correlate).
Parameters
inSeedoa::U64Default: 0x853C49E6748FEA9BULL
inSeqoa::U64Default: 1u
Public Method Documentation
No public source comment is attached to this declaration.
Returns
CheckpointThe declared return value.
Bernoulli — true with probability inP.
Parameters
inPoa::F64Default: 0.5
Returns
boolThe declared return value.
No public source comment is attached to this declaration.
Returns
oa::F64The declared return value.
── Uniform reals in [0, 1) ─────────────────────────────────────────────
Returns
oa::F32The declared return value.
── Gaussian (Box–Muller, caches the paired variate) ────────────────────
Parameters
inMeanoa::F64Default: 0.0
inStdDevoa::F64Default: 1.0
Returns
oa::F64The declared return value.
── Uniform integer in [inMin, inMax] inclusive (unbiased via rejection) ─
Parameters
inMinT—
inMaxT—
Returns
TThe declared return value.
Uniform real in [inMin, inMax).
Parameters
inMinoa::F64—
inMaxoa::F64—
Returns
oa::F64The declared return value.
No public source comment is attached to this declaration.
Parameters
inMinoa::I64—
inMaxoa::I64—
Returns
oa::I64The declared return value.
── Core engine: PCG32 (32 random bits) ─────────────────────────────────
Returns
oa::U32The declared return value.
No public source comment is attached to this declaration.
Returns
oa::U64The declared return value.
No public source comment is attached to this declaration.
Returns
oa::U64The declared return value.
The complete state includes the Box-Muller cached variate. Raw state/inc access remains for compatibility with integer-only checkpoints; use checkpoint/restoreCheckpoint for exact continuation across all APIs.
Returns
oa::U64The declared return value.
No public source comment is attached to this declaration.
Parameters
inCheckpointconst Checkpoint &—
Returns
voidThe declared return value.
No public source comment is attached to this declaration.
Parameters
inSeedoa::U64—
inSeqoa::U64Default: 1u
Returns
voidThe declared return value.
No public source comment is attached to this declaration.
Parameters
inStateoa::U64—
inIncoa::U64—
Returns
voidThe declared return value.
── Fisher–Yates shuffle over a contiguous range ────────────────────────
Parameters
inDataT *—
inCountoa::U64—
Returns
voidThe declared return value.