x
Loading
 Loading
Hello, Guest | Login | Register

Live Random or DieHarder

Simulations, games, encryption, and statistical analyses all need random numbers. But just how random is your random number generator? DieHarder can help.

The Universe seems to be a pretty random place. It should therefore come as no surprise that random numbers are very useful to people performing computations to describe, study, simulate, or otherwise muck about with Universes, real or imagined.

Unfortunately, real random numbers aren’t terribly easy to come by. Computers, after all, compute. No matter the problem, a computer executes an algorithm that takes some sort of input — numbers of some form — and performs completely deterministic things to make new numbers. There is nothing random about any output generated by a computer program. (Even hardware RNGs often are measurably non-random.)

The notion of a software random number generator (RNG) is therefore a logical oxymoron. In fact, software RNGs are often called “pseudo-random number generators” to remind us of that fact.

Sometimes the “pseudo” part doesn’t matter much. For example, random numbers are used in computer games to ensure that each playing experience is unique. Yet the random numbers need not be perfect. As long as the numbers are random “enough” that players cannot observe any systematic pattern and exploit it in game play, everybody’s happy. There are other applications that are relatively tolerant of poor quality RNGs. In many cases, fast and relatively unpredictable are sufficient.

There are many other places, however, where “unpredictable” per se is not enough. Physicists, statisticians, and mathematicians studying processes using Monte Carlo simulation or generating Markov Chains of one sort or another need a supply of numbers that are theoretically random,…

Please log in to view this content.

Not Yet a Member?

Register with LinuxMagazine.com and get free access to the entire archive, including:

  • Hands-on Content
  • White Papers
  • Community Features
  • And more.
Already a Member?
Log in!
Username

Password

Remember me

Forgotten your password?
Forgotten your username?
Read More
  1. Helpful Tools for Software Developers
  2. The Github Hall of Fame
  3. Book'em, Github.
  4. This Week on Github: Stupid Ruby Tricks
  5. A Veritable Scatter Shot!
Follow Linux Magazine
Rackspace