Topics Register • News • History • How to • Sequences statistics • Template prototypes

# Cunningham project

The aim of this project is to find the complete factorization of numbers of the form $\displaystyle{ b^n\pm 1 }$ for $\displaystyle{ b }$ = 2, 3, 5, 6, 7, 10, 11, 12. The values of the exponent $\displaystyle{ n }$ are selected so there is never too many factorizations left. This means that when the supply of numbers to be factored is low, the project starts factoring numbers with higher exponents, tracking the advances in factorization algorithms and speed of computers.

The project started in 1925, when Allan Cunningham and Herbert Woodall published a book of tables about this subject. Many people contributed to it and it is considered the oldest continuously ongoing activity in computational number theory.

At this moment three editions of the book about the Cunningham project have been published.

Current limits of the exponents of the Cunningham tables are:

 Base Limit 2 3 5 6 7 10 11 12 1300 850 550 500 450 400 350 350

## Properties of Cunningham factors

In the Cunningham tables, we eliminate two types of factors before factoring the remaining cofactor. The first type is algebraic factor, which are derived from a lower exponent. The second type is aurifeuillian factor, in which the whole number can be split into two parts directly, for certain combination of values of $\displaystyle{ b }$ and $\displaystyle{ n }$.

## Algebraic factorizations

It is trivial from elementary algebra that

$\displaystyle{ (b^{kn}-1) = (b^n-1) \sum _{r=0}^{k-1} b^{rn} }$

for any value of $\displaystyle{ k }$ and

$\displaystyle{ (b^{kn}+1) = (b^n+1) \sum _{r=0}^{k-1} (-1)^k.b^{rn} }$

only when $\displaystyle{ k }$ is odd.

Also that,

$\displaystyle{ (b^{2n}-1) = (b^n-1)(b^n+1) }$.

Thus, it turns out that both $\displaystyle{ b^m-1 }$ and $\displaystyle{ b^m+1 }$ are factors of $\displaystyle{ b^n-1 }$, if $\displaystyle{ m }$ divides $\displaystyle{ n }$ and $\displaystyle{ n \over m }$ is even. Only $\displaystyle{ b^m-1 }$ is a factor of $\displaystyle{ b^n-1 }$, if $\displaystyle{ m }$ divides $\displaystyle{ n }$ and $\displaystyle{ n \over m }$ is odd. Also, $\displaystyle{ b^m+1 }$ is a factor of $\displaystyle{ b^n+1 }$, if $\displaystyle{ m }$ divides $\displaystyle{ n }$ and $\displaystyle{ n \over m }$ is odd.

## Aurifeuillian factorizations

Consider the identity ($\displaystyle{ h = 2k-1 }$)

$\displaystyle{ 2^{2h}+1 = L.M }$ where $\displaystyle{ L = 2^h-2^k+1,\ M = 2^h+2^k+1 }$

This factorization was discovered for one value by Aurifeuille and the general form was subsequently given by Lucas. Here are the Aurifeuillian factorizations for the other bases.

$\displaystyle{ 3^{3h} + 1 = (3^h + 1).L.M }$ where
$\displaystyle{ L = 3^h - 3^k + 1 }$
$\displaystyle{ M = 3^h + 3^k + 1 }$

$\displaystyle{ 5^{5h} - 1 = (5h - 1).L.M }$ where
$\displaystyle{ L = T^2 - T.5^k + 5^h }$
$\displaystyle{ M = T^2 + T.5^k + 5^h }$
$\displaystyle{ T = 5^h + 1 }$

$\displaystyle{ 6^{6h} + 1 = (6^{2h} + 1).L.M }$ where
$\displaystyle{ L = T^2 - T.6^k + 6^h }$
$\displaystyle{ M = T^2 + T.6^k + 6^h }$
$\displaystyle{ T = 6^h + 1 }$

$\displaystyle{ 7^{7h} + 1 = (7^h + 1).L.M }$ where
$\displaystyle{ L = T^3 - B }$
$\displaystyle{ M = T^3 + B }$
$\displaystyle{ T = 7^h + 1 }$
$\displaystyle{ B = 7^k(T^2 - 7^h) }$

$\displaystyle{ 10^{10h} + 1 = (10^{2h} + 1).L.M }$ where
$\displaystyle{ L = A - B }$
$\displaystyle{ M = A + B }$
$\displaystyle{ A = 10^{4h} + 5.10^{3h} + 7.10^{2h} + 5.10^h + 1 }$
$\displaystyle{ B = 10^k(10^{3h} + 2.10^{2h} + 2.10^h + 1) }$

$\displaystyle{ 11^{11h} + 1 = (11^h + 1).L.M }$ where
$\displaystyle{ L = A - B }$
$\displaystyle{ M = A + B }$
$\displaystyle{ A = 11^{5h} + 5.11^{4h} - 11^{3h} - 11^{2h} + 5.11^h + 1 }$
$\displaystyle{ B = 11^k(11^{4h} + 11^{3h} - 11^{2h} + 11^h + 1) }$

$\displaystyle{ 12^{3h} + 1 = (12^h + 1).L.M }$ where
$\displaystyle{ L = 12^h - 2^h.3^k + 1 }$
$\displaystyle{ M = 12^h + 2^h.3^k + 1 }$

So, there exist an Aurifeuillian factorization for base $\displaystyle{ b }$ for any exponent of the form $\displaystyle{ b(2k-1) }$ for integral values of $\displaystyle{ k }$. Note that the Aurifeuillian factorization of base 5 is on the negative side, while for the other bases 2, 3, 6, 7, 10, 11, 12 it is on the positive side.

## Other factors

Once the algebraic and Aurifeuillian factors are removed, the other factors of $\displaystyle{ b^n \pm 1 }$ will always be of the form $\displaystyle{ 2kn+1 }$. Note that when the exponent $\displaystyle{ n }$ is prime, algebraic and Aurifeuillian factors are not possible, except for the trivial factor of $\displaystyle{ b-1 }$ for $\displaystyle{ b^n-1 }$ and $\displaystyle{ b+1 }$ for $\displaystyle{ b^n+1 }$.

For Mersenne numbers of the form $\displaystyle{ 2^n-1 }$, even this trivial factor is not possible for prime values of $\displaystyle{ n }$, so any factor of it should be of the form $\displaystyle{ 2kn+1 }$. In general, any factor of $\displaystyle{ b^n-1 \over b-1 }$ is of the form $\displaystyle{ 2kn+1 }$, $\displaystyle{ b \ge 2 }$ and $\displaystyle{ n }$ is prime, except when $\displaystyle{ n }$ is a factor of $\displaystyle{ x-1 }$. In such cases, $\displaystyle{ b^n-1 \over b-1 }$ is divisible by $\displaystyle{ n }$ itself.

Cunningham numbers of the form $\displaystyle{ b^n-1 }$ can only be prime if $\displaystyle{ b=2 }$ and $\displaystyle{ n }$ is prime, assuming that $\displaystyle{ n \ge 2 }$, and numbers of the form $\displaystyle{ b^n+1 }$ can only be prime if $\displaystyle{ b }$ is even and $\displaystyle{ n }$ is a power of 2, considering the fact that $\displaystyle{ n \ge 2 }$ again. Numbers of the form $\displaystyle{ (2a)^{2^k}+1 }$ are known as Generalized Fermat Numbers, which when $\displaystyle{ a = 1 }$, are known as Fermat Numbers. In general, any factor of the Fermat Number $\displaystyle{ 2^{2^k}+1 }$ is of the form $\displaystyle{ k.2^{n+2}+1 }$.

Only the first five Fermat numbers, k = 0, 1, 2, 3, 4 corresponding to 3, 5, 17, 257 and 65537 are known to be prime. All Fermat numbers from k = 5 to k = 32 are known to be composite. Fermat numbers till k = 11 are fully factorized.

Does there exist any squares of primes that divide Mersenne numbers of the form $\displaystyle{ 2^n-1 }$, for prime values of $\displaystyle{ n }$? If such a prime exists, it must be a Wieferich prime, satisfying $\displaystyle{ 2^{n-1} = 1\ (mod\ n^2) }$. Only two such primes are known 1093 and 3511, out of a very deep search, and neither of these square divide a Mersenne number at all, for any prime value of $\displaystyle{ n }$.