Whilst reading up on Xorshift I came across the following (emphases added):

The following xorshift+ generator, instead, has 128 bits of state, a maximal period of 2^128 − 1 and passes BigCrush:

[snip code]

This generator is one of the fastest generator passing BigCrush; however, it is only 1-dimensionally equidistributed.

Earlier in the article there's the following:

[snip code]

Both generators, as all xorshift* generators of maximal period, emit a sequence of 64-bit values that is equidistributed in the maximum possible dimension.

What does it mean for a sequence to be equidistributed in one dimension vs. multiple dimensions vs. not at all?


1 Answer 1


This website provides the answer:

A xorshift* generator with an n-bit state space is $n/64$-dimensionally equidistributed: every $n/64$-tuple of consecutive 64-bit values appears exactly once in the output, except for the zero tuple (and this is the best possible for 64-bit values). A xorshift+ generator is however only $(n/64 − 1)$-dimensionally equidistributed: every $(n/64 − 1)$-tuple of consecutive 64-bit values appears exactly $2^{64}$ times in the output, except for a missing zero tuple.

In the case of a xorshift+ which uses 128 bits of state, n/64 - 1 = 128/64 - 1 = 2 - 1 = 1, so the Wikipedia article was correct in stating that that particular generator is only 1-dimensionally equidistributed.

  • $\begingroup$ Wasn't there a famous example with a PRNG by Intel that was used in the wild which had structure already in triples? There are nice pictures of that phenomenon that could help illustrate the problem. $\endgroup$
    – Raphael
    Apr 25, 2014 at 7:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.