Lucas-Lehmer test
The Lucas-Lehmer test is a specific algorithm used to determine whether a given Mersenne number is prime. A Mersenne number is of the form 2^p - 1, where p is a prime number. The test starts with the number 4 and iteratively squares it and subtracts 2, repeating this process p-2 times.
If the final result is zero when taken modulo the Mersenne number, then it is prime; otherwise, it is composite. This test is particularly efficient for large primes and is widely used in computational number theory to verify the primality of Mersenne numbers.