Diehard tests

Diehard tests

The diehard tests are a battery of statistical tests for measuring the quality of a random number generator. They were developed by George Marsaglia over several years and first published in 1995 on a CD-ROM of random numbers.

These are the tests:

  • Overlapping permutations: Analyze sequences of five consecutive random numbers. The 120 possible orderings should occur with statistically equal probability.
  • Ranks of matrices: Select some number of bits from some number of random numbers to form a matrix over {0,1}, then determine the rank of the matrix. Count the ranks.
  • Monkey tests: Treat sequences of some number of bits as "words". Count the overlapping words in a stream. The number of "words" that don't appear should follow a known distribution. The name is based on the infinite monkey theorem.
  • Count the 1s: Count the 1 bits in each of either successive or chosen bytes. Convert the counts to "letters", and count the occurrences of five-letter "words".
  • Parking lot test: Randomly place unit circles in a 100 x 100 square. If the circle overlaps an existing one, try again. After 12,000 tries, the number of successfully "parked" circles should follow a certain normal distribution.
  • Minimum distance test: Randomly place 8,000 points in a 10,000 x 10,000 square, then find the minimum distance between the pairs. The square of this distance should be exponentially distributed with a certain mean.
  • Random spheres test: Randomly choose 4,000 points in a cube of edge 1,000. Center a sphere on each point, whose radius is the minimum distance to another point. The smallest sphere's volume should be exponentially distributed with a certain mean.
  • The squeeze test: Multiply 231 by random floats on [0,1) until you reach 1. Repeat this 100,000 times. The number of floats needed to reach 1 should follow a certain distribution.
  • Overlapping sums test: Generate a long sequence of random floats on [0,1). Add sequences of 100 consecutive floats. The sums should be normally distributed with characteristic mean and sigma.
  • Runs test: Generate a long sequence of random floats on [0,1). Count ascending and descending runs. The counts should follow a certain distribution.[further explanation needed]
  • The craps test: Play 200,000 games of craps, counting the wins and the number of throws per game. Each count should follow a certain distribution.[further explanation needed]

See also

  • Randomness test
  • TestU01

External links


Wikimedia Foundation. 2010.

Игры ⚽ Поможем решить контрольную работу

Look at other dictionaries:

  • Randomness tests — (or tests of randomness), in data evaluation, are used to analyze the distribution pattern of a set of data. In stochastic modeling, as in some computer simulations, the expected random input data can be verified to show that tests were performed …   Wikipedia

  • Тесты DIEHARD — это набор статистических тестов для измерения качества набора случайных чисел. Они были разработаны Джорджем Марсальей (англ. George Marsaglia) в течение нескольких лет и впервые опубликованы на CD ROM, посвящённом случайным числам. Вместе они… …   Википедия

  • Тесты diehard — Тесты diehard  это набор статистических тестов для измерения качества набора случайных чисел. Они были разработаны Джорджем Марсальей (англ.) в течение нескольких лет и впервые опубликованы на CD ROM, посвящённом случайным числам.… …   Википедия

  • George Marsaglia — is a mathematician and computer scientist. He is perhaps best known for establishing the lattice structure [ [http://www.pnas.org/content/61/1/25.full.pdf+html G. Marsaglia, Random numbers fall mainly in the planes , Proc. Natl. Acad. Sci. 61(1) …   Wikipedia

  • Die hard — may refer to: die hard (phrase), one not easily swayed from a belief DieHard (type of battery), a brand of batteries marketed by Sears Diehard tests, a battery of statistical tests Diehard is also a pattern in the Game of Life Die Hard, a song by …   Wikipedia

  • Statistical randomness — A numeric sequence is said to be statistically random when it contains no recognizable patterns or regularities; sequences such as the results of an ideal die roll, or the digits of π exhibit statistical randomness.Statistical randomness does not …   Wikipedia

  • Infinite monkey theorem — Not to be confused with Hundredth monkey effect. Given enough time, a hypothetical monkey typing at random would, as part of its output, almost surely produce all of Shakespeare s plays. In this image a chimpanzee is giving it a try. The infinite …   Wikipedia

  • Mersenne twister — The Mersenne twister is a pseudorandom number generator developed in 1997 by Makoto Matsumoto (松本 眞?) and Takuji Nishimura (西村 拓士?)[1] …   Wikipedia

  • List of random number generators — Computer random number generators are important in mathematics, cryptography and gambling. This list includes all common types, regardless of quality.Pseudorandom number generators (PRNGs)The following algorithms are pseudorandom number… …   Wikipedia

  • Deaths in February 2011 — Contents 1 February 2011 1.1 28 1.2 27 1.3 26 …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”