ArticleslgStudy

mathematics

Cunningham chain

Cunningham chain is a mathematics topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Cunningham chain rather than just read about it. In short: In mathematics, a Cunningham chain is a certain sequence of prime numbers. Cunningham chains are named after mathematician A.

Key takeaways

  • Cunningham chain belongs to mathematics; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Cunningham chain to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Cunningham chain from memory before moving on to harder problems.

Reference excerpt

In mathematics, a Cunningham chain is a certain sequence of prime numbers. Cunningham chains are named after mathematician A. J. C. Cunningham. They are also called chains of nearly doubled primes.

Definition A Cunningham chain of the first kind of length n is a sequence of prime numbers (p1, ..., pn) such that pi+1 = 2pi + 1 for all 1 ≤ i < n. (Hence each term of such a chain except the last is a Sophie Germain prime, and each term except the first is a safe prime). It follows that

p2=2p1+1,p3=4p1+3,p4=8p1+7, ⋮pi=2i−1p1+(2i−1−1), or, by setting a=p1+12 (the number a is not part of the sequence and need not be a prime number), we have pi=2ia−1. Similarly, a Cunningham chain of the second kind of length n is a sequence of prime numbers (p1, ..., pn) such that pi+1 = 2pi − 1 for all 1 ≤ i < n. It follows that the general term is

pi=2i−1p1−(2i−1−1). Now, by setting a=p1−12, we have pi=2ia+1. Cunningham chains are also sometimes generalized to sequences of prime numbers (p1, ..., pn) such that pi+1 = api + b for all 1 ≤ i ≤ n for fixed coprime integers a and b; the resulting chains are called generalized Cunningham chains. A Cunningham chain is called complete if it cannot be further extended, i.e., if the previous and the next terms in the chain are not prime numbers.

Examples Examples of complete Cunningham chains of the first kind include these:

2, 5, 11, 23, 47 (The next number would be 95, but that is not prime.) 3, 7 (The next number would be 15, but that is not prime.) 29, 59 (The next number would be 119, but that is not prime.) 41, 83, 167 (The next number would be 335, but that is not prime.) 89, 179, 359, 719, 1439, 2879 (The next number would be 5759, but that is not prime.) Examples of complete Cunningham chains of the second kind include these:

2, 3, 5 (The next number would be 9, but that is not prime.) 7, 13 (The next number would be 25, but that is not prime.) 19, 37, 73 (The next number would be 145, but that is not prime.) 31, 61 (The next number would be 121 = 112, but that is not prime.) Cunningham chains are now considered useful in cryptographic systems since "they provide two concurrent suitable settings for the ElGamal cryptosystem ... [which] can be implemented in any field where the discrete logarithm problem is difficult."

Largest known Cunningham chains It follows from Dickson's conjecture and the broader Schinzel's hypothesis H, both widely believed to be true, that for every k there are infinitely many Cunningham chains of length k. There are, however, no known direct methods of generating such chains. There are computing competitions for the longest Cunningham chain or for the one built up of the largest primes, but unlike the breakthrough of Ben J. Green and Terence Tao – the Green–Tao theorem, that there are arithmetic progressions of primes of arbitrary length – there is no general result known on large Cunningham chains to date.

q# denotes the primorial 2 × 3 × 5 × 7 × ... × q. As of October 2026, the longest known Cunningham chain of either kind is of length 20, discovered by John Armitage in 2026.

Congruences of Cunningham chains Let the odd prime p1 be the first prime of a Cunningham chain of the first kind. The first prime is odd, thus p1≡1(mod2). Since each successive prime in the chain is pi+1=2pi+1 it follows that pi≡2i−1(mod2i). Thus, p2≡3(mod4), p3≡7(mod8), and so forth. The above property can be informally observed by considering the primes of a chain in base 2. (Note that, as with all bases, multiplying by the base "shifts" the digits to the left; e.g. in decimal we have 314 × 10 = 3140.) When we consider pi+1=2pi+1 in base 2, we see that, by multiplying pi by 2, the least significant digit of pi becomes the secondmost least significant digit of pi+1. Because pi is odd—that is, the least significant digit is 1 in base 2–we know that the secondmost least significant digit of pi+1 is also 1. And, finally, we can see that pi+1 will be odd due to the addition of 1 to 2pi. In this way, successive primes in a Cunningham chain are essentially shifted left in binary with ones filling in the least significant digits. For example, here is a complete length 6 chain which starts at 141361469:

A similar result holds for Cunningham chains of the second kind. From the observation that p1≡1(mod2) and the relation pi+1=2pi−1 it follows that pi≡1(mod2i). In binary notation, the primes in a Cunningham chain of the second kind end with a pattern "0...01", where, for each i, the number of zeros in the pattern for pi+1 is one more than the number of zeros for pi. As with Cunningham chains of the first kind, the bits left of the pattern shift left by one position with each successive prime. Similarly, because pi=2i−1p1+(2i−1−1) it follows that pi≡2i−1−1(modp1). But, by Fermat's little theorem, 2p1−1≡1(modp1), so p1 divides pp1 (i.e. with i=p1). Thus, no Cunningham chain can be of infinite length.

See also Primecoin, which uses Cunningham chains as a proof-of-work system Bi-twin chain Primes in arithmetic progression

References

External links The Prime Glossary: Cunningham chain Primecoin discoveries (primes.zone): online database of primecoin findings with list of records and visualization PrimeLinks++: Cunningham chain OEIS sequence A005602 (Smallest prime beginning a complete Cunningham chain of length n (of the first kind)) -- the first term of the lowest complete Cunningham chains of the first kind of length n, for 1 ≤ n ≤ 14 OEIS sequence A005603 (Chains of length n of nearly doubled primes) -- the first term of the lowest complete Cunningham chains of the second kind with length n, for 1 ≤ n ≤ 15

Worked examples

Example 1 — a first encounter with Cunningham chain

Start with the simplest possible case. Write down what Cunningham chain claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In mathematics, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Cunningham chain before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Cunningham chain ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Cunningham chain

In research
Cunningham chain appears in mathematics research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Cunningham chain in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Cunningham chain is common in secondary-school and first-year university syllabi. It links to neighbouring topics Prime numbers, so understanding it makes those chapters shorter.
In everyday life
Look for Cunningham chain outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Cunningham chain” →

How to study Cunningham chain in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Cunningham chain means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Cunningham chain out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Cunningham chain in simple terms?

In mathematics, a Cunningham chain is a certain sequence of prime numbers. Cunningham chains are named after mathematician A.

Why does Cunningham chain matter?

Because it connects several mathematics ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Cunningham chain?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Cunningham chain.

Tags

  • Prime numbers

Keep exploring