public class XorShift1024Star extends AbstractRng64 implements SplittablePseudoRandom
XorShift64Star and other
64-bit xorshift generators and is about 25% faster despite its larger state
size.
This generator has a period of 21024 − 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 16-dimensionally equidistributed.
DOUBLE_NORM, FLOAT_NORM, nextGaussian, unused| Modifier | Constructor and Description |
|---|---|
|
XorShift1024Star() |
|
XorShift1024Star(long seed) |
|
XorShift1024Star(long[] seed) |
protected |
XorShift1024Star(long[] seed,
boolean unused) |
| Modifier and Type | Method and Description |
|---|---|
static SplittablePseudoRandom |
getDefault() |
long |
nextLong() |
XorShift1024Star |
split()
Constructs and returns a new SplittablePseudoRandom instance that shares
no mutable state with the current instance.
|
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, weibullclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAlgorithm, getSeed, next, nextBoolean, nextBytes, nextDouble, nextDouble, nextDoubles, nextFloat, nextFloat, nextGaussian, nextGaussian, nextInt, nextInt, nextInt, nextLong, nextLong, nextLongsbeta, beta, cauchy, cauchy, chiSquare, chiSquare, doubles, doubles, doubles, doubles, exponential, exponential, gamma, gamma, ints, ints, ints, ints, logNormal, logNormal, longs, longs, longs, longs, normal, normal, studentT, studentT, weibull, weibullpublic XorShift1024Star()
public XorShift1024Star(long seed)
public XorShift1024Star(long[] seed)
protected XorShift1024Star(long[] seed,
boolean unused)
public final long nextLong()
nextLong in interface PseudoRandomnextLong in class AbstractRng64public XorShift1024Star split()
SplittablePseudoRandomSplittablePseudoRandom instance. Instances of SplittablePseudoRandom are
not thread-safe. They are designed to be split, not shared,
across threads.split in interface SplittablePseudoRandompublic static SplittablePseudoRandom getDefault()
Copyright © 2022. All rights reserved.