Random Number Generator

The Cascading Style Sheet has not loaded, so this page will not display properly

Generate batches of pseudo-random numbers using GJ Mitchell & DP Moore algorithm from The Art of Computer Programming vol 2 Seminumerical Algoriths 2nd edition by Donald E Knuth. This uses modulo arithmetic to seed the generator then subtractive combination to generate a sequence. This implementation uses the number pair (24, 55). Other successful pairs include (32, 65) and (27, 98). It uses integer arithmetic in the range +-10e9 to generate random numbers in the range 0 <= x < 10e9 which are converted to other ranges required.

Requested by Spencer Hamill

0 <= number < 10e9

specified <= integer <= specified


                     

0 <= real < 1

Enter inclusive lower and upper bounds for integers if required then
click Generate to generate a single random number,
Every Second to generate one every second then any button to stop,
Re-initialise to re-seed the generator from the time.
For help, hover cursor over fields to show tooltips.