Library of Assembled Shared Sources
|
xorshift128+ pseudorandom number generator More...
#include <random.h>
Public Types | |
using | result_type = num::Tuint64 |
type of return value. | |
typedef num::Tuint64 | TValue |
type of return value. | |
Static Public Member Functions | |
static constexpr result_type | min () |
minimum return value. | |
static constexpr result_type | max () |
maximum return value. | |
xorshift128+ pseudorandom number generator
Variation on xorshift generator that avoids the linear artifacts the xorshift generators are prone to. In contrast to the XSadd variants, it also passes the BigCrush tests even when bit reversed! As a disadvantage, xorshift128+ is only 1-dimensionally equidistributed while the underlying xorshift128 is 2-dimensionally equidistributed.
This implementation uses 128 bits of state with following shifts: a=23, b=17, c=26. It has a maximal period of 2^128-1
S. Vigna, "Further scramblings of Marsaglia's xorshift generators", Dec 2015, arXiv:1404.0390v2 [cs.DS], http://arxiv.org/abs/1404.0390v2
typedef num::Tuint64 lass::num::RandomXorShift128Plus::TValue |