Math

Why Computers Can Never Generate Truly Random Numbers

NEWS: The Curiosity Podcast is out! Subscribe on iTunesStitcher, Google Play MusicSoundCloud and add the RSS feed to any podcast player. If you love it please consider leaving us a review.

If you needed to make a choice at random, you might flip a coin or roll a die. If you did, you'd have a leg up on your computer. That's because computer software can never generate a truly random number. That's not so important when you want to play a favorite album on shuffle, but when it comes to high-stakes areas like security and gambling, it can mean everything.

Related: A Turing Machine Is The Hypothetical Device That Underpins All Of Computation

Pick A Number, Any Number

Modern computers can do some pretty amazing things. So why can't they do something as simple as simulating a dice roll? It all comes down to the way computers are programmed. Computers follow algorithms, which are essentially just lists of instructions on how to carry out tasks. They're slaves to their instructions, so they're completely predictable. Still, engineers are pretty savvy, and they've come up with a few different ways to make computers generate something very close to random numbers, even if they can't generate true randomness.

Related: Road Trip! Why Mathematicians Are Vexed By The Traveling Salesman Problem

As Close As Random Gets

One way to come up with seemingly random numbers is with a pseudo-random number generator. Those algorithms use things like mathematical formulas or predetermined number tables to create number sequences that appear random. These days, the algorithms that generate pseudo-random numbers are so good that it would take some real detective work to determine that the numbers aren't actually random. Still, it's possible. With the right programming chops, you could reverse-engineer the pseudo-random numbers used to run an online poker game or encrypt sensitive data and come out with a lot of other people's money.

Related: Could A Monkey Randomly Pounding Keys Type Out Shakespeare?

You could argue that true random number generators, the second method, actually do produce randomness. But we'd have you on a technicality there. Here's why: true random number generators use physical phenomena to extract actual randomness, which they then use to generate a random number. Those physical phenomena could be as simple as a roll of real dice, but they're more often easier-to-measure things like radioactive decay, background noise in the atmosphere, or even the amount of time between a person's keystrokes. But that just provides the seed. There are still algorithms involved in true random number generators, and algorithms are never truly random.

Is there something you're curious about? Send us a note or email us at editors (at) curiosity.com. And follow Curiosity on Facebook, Instagram and Twitter.

Watch And Learn: Our Favorite Content On Randomness

What is Random?

Share the knowledge!

If you liked this you'll love our podcast! Check it out on iTunes, StitcherGoogle Play Music, SoundCloud, search 'curiosity' on your favorite podcast app or add the RSS Feed URL.

Advertisement