"Any one who considers arithmetical methods of producing random digits is, of course, in a state of sin. For, as has been pointed out several times, there is no such thing as a random number — there are only methods to produce random numbers, and a strict arithmetic procedure of course is not such a method."Since random numbers are important in computer simulations, such as the Monte Carlo method, von Neumann went against his own advice and developed a simple pseudorandom number generator, called the middle-square method, which was useful in the early days of computing. Unknown to von Neumann, but known to the present readers of Wikipedia, this simple method of generating pseudorandom numbers was invented by Brother Edvin, a Franciscan friar, circa 1245. There are two problems with this method, but they're fortunately very apparent when they happen. The first is when the middle digits become all zeros. After that point, the generator output is always zero. The other problem is that the generator can enter a mode in which it outputs the same short sequence, over and over. linear congruential generator, a recurrence relation published by D.H. Lehmer in 1948, as follows:
Xn = (aXn-1 + c) mod mThis generator gives a long list of pseudorandom numbers when proper values are selected for a, c and m. Computer scientist, Donald Knuth, prefers to use
a=6364136223846793005, c=1442695040888963407, and m = 264.The choice of a power of two for m simplifies the modulus operation. These are just two examples of many simple pseudorandom number generators proven to be useful in the early days of computing when processors were slow and memory was small. Since we now have fast computers, we can be more creative with our pseudorandom number generators. One example of a more elaborate generator is the Mersenne twister; which, as its name implies, involves the Mersenne primes. Aside from that fact, it's somewhat hard to describe, but it's used as the random number generator in Python, PHP, and some other programming languages. Most random number generators are suitable for computer simulations if we're careful to select those with sufficiently large periods. Cryptographic randomness is another case entirely, since the common pseudorandom number algorithms we might use in our cipher will be known also to our adversaries. Certain regularities in the output of such algorithms offer a signature of what method we might be using. Physical random number generation is an alternative to algorithmic generation. The simplest of these is casting dice, but this method is slow and tedious.
Six dice will generate random numbers from 111,111 to 666,666, which could be scaled to the range, 0 to 555,555. Each die, of course, needs to be assigned to a decimal place. (Illustration by the author.) |
Figure three of the Lavarand patent.[2] (Via Google Patents.) |
Apparatus for one-time pad generation using light scattering. Fig. 2b of ref. 3, (Via arXiv.)[3] |