You might very well have heard of a random number generator before. They’re used all over to create randomicity (or at least something closely resembling it). In this brief introduction to random number generators, we’ll be looking at what exactly a random number generator is, and the two main types. We’ll then look at the most common applications for random number generators.
Early RND Generator
What is a Random Number Generator?
As you might very well have guessed, a random number generator is some device that is used to arrive at a random number. A random number here is defined as any sequence of digits, characters, or symbols the next of which cannot be reasonably predicted by random chance.
Random number generators have all kinds of applications in a variety of industries and we’ll get onto those shortly. However, for now, we need to introduce the two main types of random number generators, as well as to understand a little about their strengths and limitations.
True Random Number Generators
Any way at arriving at an unpredictable number is referred to as a random number generator. It might come as a surprise to you that the very best random number generators are in fact the very oldest.
Think about some ways you yourself can create a random result. You can toss a coin or roll a dice. That will a more random outcome than any single computer program in the world.
Providing the source of randomicity is fair (the dice isn’t weighted, the deck of cards isn’t loaded), then such methods of obtaining random numbers are the ultimate. Although computer scientists would love to create a way to generate true randomness digitally, for now it has not been achieved.
There do exist some advanced random number generators that use computers to produce random sequences. However, they take their starting point from a true random source – such as the sound wave of a geothermal movement. These are prohibitively expensive and are not really suitable for use in anything outside of advanced cryptography and other sciences.
One of the major limitations of this form of hardware-based number generation is that it is laborious and time-consuming. It can also be mind numbing trying to generate a particularly massive random number. Hence the second type of random number generator to discuss is the pseudo-random number generator.
Pseudo-Random Number Generator
Since the old school way is so painfully slow and ill-suited for generating huge numbers, computer scientists have come up with various computerised random number generators – well, they’re sort of random.
Different systems of digital random number generators work in different ways and this article is much too short to detail them all. However, since they function differently, they also have different degrees of predictability. This is because more advanced random number generators are computationally expensive and, frankly, such a high level of randomicity isn’t needed to shuffle up your Spotify playlist.
Meanwhile, more advanced systems are favoured where something more akin to true randomicity is required.
Again, pseudo-random number generators rely on complex algorithms to achieve their results. Unfortunately, this article cannot go deep into how they work. Especially how they are used to randomise all the video games and online casino games that are played by millions the world over.
Different Applications of Random Number Generators
Random number generators are used all over the world and in just about every walk of life. Simple examples might be the machine in a bingo hall or children choosing teams by way of allocation of numbers and a blind draw.
Another basic application might be to make an episode of a TV show play at random on an application like Netflix or for a simple “random” message being displayed on a website. In these two examples a very low level of randomicity is required and there are even safeguards to protect truly random results occurring. For example, iTunes would never play the same time 15 times consecutively. However, if using a genuine, hardware random number generator, it very well might do.
Random number generation is absolutely crucial to the operation of online casinos. Although there are some devices that allow for truly random events to be used to produce truly random strings of digital characters, such processes are too expensive and time consuming to use at an online casino. Unfortunately, they must instead make do with a pseudo random number generator. There are more detailed explanations of more advanced random number generators all over the web.
That last sentence might be enough to make you vow never to play another online casino game ever again. But it needn’t! Although theoretically possible to predict the next number in a sequence using a random number generator, in practice, it remains a feat that none have achieved. Again, the time taken to pick apart the algorithm makes it impractical and safeguards, such as a sporadic resetting of the entire system make the random number generators used at online casinos amongst the best out there.
More advanced applications of random number generation technology can be seen in the world of cryptography and digital security. Here, a pair of cryptographic keys can offer impregnable security, provided one of them is kept a secret. It is random number generation that helps digital currencies, such as Bitcoin, be almost immune to cyber-attack. The algorithms involved in random number generation for such use cases are much more advanced than those used in playlist selection and other simple “random” applications.