Mathematical theories are constantly changing as new discoveries are made and understood. One area that has been studied with great interest since the ancient world is prime numbers. The Sieve of Eratosthenes, which was developed approximately 2,300 years ago, is the earliest known algorithm to find prime numbers.

There are many uses for prime numbers, most noticeably for digital purposes. There are an infinite amount of prime numbers, which means that there is still a lot to be learned from this certain type of number and how they can be used.

Whether you're hoping to understand prime numbers better or want to further your knowledge about how they are calculated or used, there are a number of tricks and methods that can help you develop your understanding of prime numbers.

In this guide, we'll look at what prime numbers are, why they are important, and how you can identify them.

A prime number is a number that is greater than one and whose only factors are one and itself. A prime number cannot be fully divided by positive integers without leaving a remainder. Between 2 and 30, the prime numbers are 2, 3, 5, 7, 11, 13, 17, 19, 23 and 29.

Except for the number two, all prime numbers are odd. This is because even numbers are all divisible by two and will therefore always have more than two factors. For example, four can be divided by one, two and four. However, five can only be divided by itself and one. Dividing five by two, for example, would equal 2.5, which is not an integer.

Prime numbers are often seen as the foundation for number theory. Composite numbers, according to the fundamental theorem of arithmetic, can all be expressed as the product of prime numbers.

Continue reading to find out the various uses of prime numbers, as well as ways that you can identify them.

What is a Mersenne prime number?

A Mersenne prime number is a prime number that is one less than a power of two and so can be written in the form 2n−1. There are currently 51 known Mersenne prime numbers, one of which is the largest known prime number. You can find Mersenne prime numbers by taking a natural number and using it to calculate 2n, subtracting one and then checking to see if the answer is a prime number.

For example:

22 = 2(2) = 4

4 - 1 = 3

3 is a Mersenne prime number.

A key criterion of prime numbers is that they have exactly two factors, usually one and the number itself. As one is only divisible by itself, it has exactly one factor and so is not considered to be a prime number. Historically, many mathematicians considered one to be a prime number because it can be divided by one and itself, but as both of these numbers are the same, it does not count as two separate factors.

It's important to remember that mathematical theories and definitions evolve over time, so while one was previously considered a prime number, that is not the most common belief in the modern era and so is discounted.

Two is the smallest prime number, as well as the only even prime number. This is because all other even numbers can be divided by one, two and themselves as a minimum, which means that they have more than two factors.

Euclid, a mathematician who lived in Ancient Greece, calculated that there is no largest prime number based on the theory that there are infinitely many prime numbers. However, there have been numerous studies by scientists and mathematicians over the years to try and find the largest prime number.

The current largest known prime number was determined to be 282,589,933 − 1 in May 2022. This number has 24,862,048 digits. Before this discovery was made, the largest known prime number was 277,232,917 − 1, which had 23,249,425 digits.

A collaborative project called the Great Internet Mersenne Prime Search (GIMPS) consists of volunteers who use software to try and find Mersenne prime numbers. It was a GIMPS volunteer called Patrick Laroche who used computer software to discover the largest known prime number in 2018, although efforts are still being made to find larger prime numbers. Formed in 1996, GIMPS has discovered the last 17 Mersenne primes.

Prime numbers are most commonly used in cyber security, where they can be used to help make the internet safe from cyber attacks. Software engineers use prime numbers in algorithms to encrypt data such as credit card details, medical records and private messages on apps like Whatsapp.

Two large prime numbers, sometimes hundreds of digits long, are multiplied together. The resulting number is used to encrypt information as the two large factors are only known to the software engineers. Therefore, hackers have to try and work out the original factors that were used to try and reveal the hidden information.

RSA (Rivest-Shamir-Adleman), a well-known type of cryptography, always uses prime numbers that are unique. However, in other typography schemes, such as Digital Signature Standard (DSS), the prime numbers are often standardized and used in multiple applications.

In all forms of cyber security, prime numbers are incredibly long, which is why it can take cyber criminals years or decades to try and calculate the factors through trial and error.

Prime numbers are also important in other areas of the digital world. For example, they determine the color intensity of pixels on computer screens.

Prime numbers cannot be divided by more than two factors (itself and one) to make a whole number. For this reason, the majority of prime numbers are odd — in fact, two is the only even prime number. All the other prime numbers are odd numbers because they cannot be divided by two.

It is also easy to calculate if smaller numbers are prime because they have fewer factors. Mathematicians can quickly determine whether a number is prime or not using factorization. For example, 10 has two prime factors: two and five because they can be multiplied by each other to equal 10.

Mathematicians can use computer software to determine whether larger numbers are prime or not. However, there is no limit to how large a natural number can be, which means that even supercomputers can struggle when calculating the factors of extremely large numbers.

There are two types of natural number: prime and composite (and 1, which is neither of these). They differ based on how many factors they have. Prime numbers cannot be divided into a full number by anything other than itself and one. A composite number, on the other hand, has more factors than just itself and one. Composite numbers can be divided by at least one other positive integer. One is considered to be neither a prime number nor a composite number, however.

There are both positive and negative composite numbers. Positive numbers that are not prime are called odd composite numbers. For example, the odd numbers 9, 21, 33, and 45 have more than two factors, so they are considered to be odd composite numbers. Two is the only prime number that is even, which means that all other even numbers are composite numbers.

Prime numbers are integer numbers that have only two factors: themselves and one. The prime number examples between one and ten are 2, 3, 5, and 7. A prime number cannot be divided into a whole number by anything else without leaving a decimal, fraction, or remainder.

There are many uses for prime numbers, but their most predominant use is for encryption. It's fairly quick to find two long factors and multiply them to create a new number that can be used to encrypt information. However, it is hard to try and calculate the two prime factors that were used to create the encryption number, which helps to prevent cyber attacks.

The smallest prime number is two, but mathematicians are constantly working on calculating the largest prime number possible. At present, the largest prime number is 282,589,933 − 1, which is a Mersenne prime number as it was calculated using 2n−1. There are 51 known Mersenne prime numbers in total.