Let l ≥ 3 be a prime, and let p = 2 − 1 be the corresponding Mersenne number. The Lucas-Lehmer test for the primality of p goes as follows. Define the sequence of integers xk by the recursion x0 = 4, xk = x 2 k−1 − 2. Then p is a prime if and only if each xk is relatively prime to p, for 0 ≤ k ≤ l − 3, and gcd(xl−2, p) > 1. We show, in the first section, that this test is based on the successiv...