public class XorShift128Plus extends AbstractRng64
xorshift128+ pseudo random generator suggested by
Sebastiano
Vigna (2017). It is about 40% faster than XorShift64Star
despite its larger state size.
This generator has a period of 2128 − 1.
At least the two lowest bits of a xorshift* generator satisfy a
linear recurrence and will therefore fail linearity tests (MatrixRank and
LinearComp in TestU01) which were designed to catch these linear relations.
However, low linear complexity of the lowest bits has rarely an effect in
practice, and certainly has no impact at all when the generator is only used
to generate floating-point numbers.
This generator is 1-dimensionally equidistributed.
DOUBLE_NORM, FLOAT_NORM, nextGaussian, unused| Constructor and Description |
|---|
XorShift128Plus() |
XorShift128Plus(long seed) |
XorShift128Plus(long[] seed) |
| Modifier and Type | Method and Description |
|---|---|
static PseudoRandom |
getDefault() |
long |
nextLong() |
beta, beta, cauchy, cauchy, chiSquare, chiSquare, doubles, doubles, doubles, doubles, exponential, exponential, gamma, gamma, getAlgorithm, getSeed, ints, ints, ints, ints, logNormal, logNormal, longs, longs, longs, longs, next, nextBoolean, nextBytes, nextDouble, nextDouble, nextDoubles, nextFloat, nextFloat, nextGaussian, nextGaussian, nextInt, nextInt, nextInt, nextLong, nextLong, nextLongs, normal, normal, saveSeed, saveSeed, studentT, studentT, weibull, weibullpublic XorShift128Plus()
public XorShift128Plus(long seed)
public XorShift128Plus(long[] seed)
public final long nextLong()
nextLong in interface PseudoRandomnextLong in class AbstractRng64public static PseudoRandom getDefault()
Copyright © 2022. All rights reserved.