Computer Science Stack Exchange is a question and answer site for students, researchers and practitioners of computer science. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

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?

share|cite|improve this question
up vote 4 down vote accepted

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 264 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.

share|cite|improve this answer
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. – Raphael Apr 25 '14 at 7:01

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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