A recent Mathematics study has argued that prime numbers might not be as random as once thought.
The study, titled Unexpected biases in the distribution of consecutive primes, analyses the first one billion prime numbers to find patterns in their distribution. This study is significant as it suggests there might be a pattern or bias to prime numbers, and prime numbers are famously known for appearing randomly and thus are good to use in encryption. As Computer Science applicants might be aware, every online purchase with a credit card uses the RSA algorithm, which encrypts your credit card number into a large prime number using the credit card numbers as factors. Prime numbers are famously hard to factorise – it took researchers two years to factor a 232-digit number.
The study suggests the bias must exist because of the frequency of the ending digit of numbers up to a billion. Aside from 2 and 5, all prime numbers end in one of four digits: 1, 3, 7 or 9. From this, we can say that is a prime numbers were truly random, a prime number ending with a 1 should be followed by another prime number ending with a 1 25% of the time, as there are four options available. Researches instead found that the occurrence was true only 18% of the time, and a prime number ending with 1 was likely to be followed by a number ending in 3 or 7 30% of the time, and 9 22% of the time.
While this ‘anti-sameness’ bias does not yet concretely change the way our encryption services work, it is a big step towards understanding the prime number phenomenon.