HOME

TheInfoList



OR:

TestU01 is a
software library In computer science, a library is a collection of non-volatile resources used by computer programs, often for software development. These may include configuration data, documentation, help data, message templates, pre-written code and sub ...
, implemented in the
ANSI C ANSI C, ISO C, and Standard C are successive standards for the C programming language published by the American National Standards Institute (ANSI) and ISO/IEC JTC 1/SC 22/WG 14 of the International Organization for Standardization (ISO) and the ...
language, that offers a collection of utilities for the
empirical Empirical evidence for a proposition is evidence, i.e. what supports or counters this proposition, that is constituted by or accessible to sense experience or experimental procedure. Empirical evidence is of central importance to the sciences ...
randomness testing of
random number generator Random number generation is a process by which, often by means of a random number generator (RNG), a sequence of numbers or symbols that cannot be reasonably predicted better than by random chance is generated. This means that the particular out ...
s (RNGs).The TestU01 web site
The library was first introduced in 2007 by Pierre L’Ecuyer and Richard Simard of the
Université de Montréal The Université de Montréal (UdeM; ; translates to University of Montreal) is a French-language public research university in Montreal, Quebec, Canada. The university's main campus is located in the Côte-des-Neiges neighborhood of Côte-d ...
.Pierre L’Ecuyer & Richard Simard (2007),
TestU01: A Software Library in ANSI C for Empirical Testing of Random Number Generators
, '' ACM Transactions on Mathematical Software'', 33: 22.
The library implements several types of random number generators, including some proposed in the literature and some found in widely used software. It provides general implementations of the classical statistical tests for random number generators, as well as several others proposed in the literature, and some original ones. These tests can be applied to the generators predefined in the library, user-defined generators, and streams of random numbers stored in files. Specific tests suites for either sequences of
uniform A uniform is a variety of clothing worn by members of an organization while participating in that organization's activity. Modern uniforms are most often worn by armed forces and paramilitary organizations such as police, emergency services, se ...
random numbers in ,1or bit sequences are also available. Basic tools for plotting vectors of points produced by generators are provided as well.


History

An initial battery of randomness tests for RNGs was suggested in the 1969 first edition of ''
The Art of Computer Programming ''The Art of Computer Programming'' (''TAOCP'') is a comprehensive monograph written by the computer scientist Donald Knuth presenting programming algorithms and their analysis. Volumes 1–5 are intended to represent the central core of comp ...
'' by
Donald Knuth Donald Ervin Knuth ( ; born January 10, 1938) is an American computer scientist, mathematician, and professor emeritus at Stanford University. He is the 1974 recipient of the ACM Turing Award, informally considered the Nobel Prize of computer ...
. Knuth's tests were then supplanted by
George Marsaglia George Marsaglia (March 12, 1924 – February 15, 2011) was an American mathematician and computer scientist. He is best known for creating the diehard tests, a suite of software for measuring statistical randomness. Research on random numbers ...
's Diehard tests (1996) consisting of fifteen different tests. The inability to modify the test parameters or add new tests led to the development of the TestU01 library.


Features

TestU01 offers four groups of modules for analyzing RNGs: # Implementing (pre-programmed) RNGs; # Implementing specific statistical tests; # Implementing batteries of statistical tests; # Applying tests to entire families of RNGs. When a specific test is applied to a sample of size ''n'' produced by an RNG, the ''p''-value of the test usually will remain reasonable as the sample size increases until the sample size hits ''n''0, say. After that, the ''p''-value diverges to 0 or 1 with exponential speed. Module 4 allows the researcher to study the interaction between a specific test and the structure of the point sets produced by a given family of RNGs. This technique can be used to determine how large the sample size should be, as a function of the generator's period length, before the generator starts to fail the test systematically. TESTU01 offers several batteries of tests including "Small Crush" (which consists of 10 tests), "Crush" (96 tests), and "Big Crush" (106 tests). The specific tests applied by each battery are detailed in the user's guide.TestU01 User's Guide
On a 1.7 GHz
Pentium 4 Pentium 4 is a series of single-core CPUs for desktops, laptops and entry-level servers manufactured by Intel. The processors were shipped from November 20, 2000 until August 8, 2008. The production of Netburst processors was active from 2000 ...
running
Red Hat Linux Red Hat Linux was a widely used commercial open-source Linux distribution created by Red Hat until its discontinuation in 2004. Early releases of Red Hat Linux were called Red Hat Commercial Linux. Red Hat published the first non-beta releas ...
9.0, for a simple RNG, Small Crush takes about 2 minutes. Crush takes about 1.7 hours. Big Crush takes about 4 hours. For a more complex RNG, all these times increase by a factor of two or more. For comparison, the Diehard tests take about 15 seconds to run.


Limitations

TestU01 only accepts 32-bit inputs, and interprets them as values in the range , 1 This causes it to be more sensitive to flaws in the most-significant bits than the least significant bits. It is important to test general-purpose generators in bit-reversed form, to verify their suitability for applications which use the low-order bits. Generators which produce 64 bits of output additionally require separate tests for their high and low halves.


See also

* Randomness tests * Diehard tests * PractRand


References

{{reflist Computer libraries Random number generation Statistical software