1. Home
  2. Explore
  3. Mathematics
  4. Prime Reciprocals Analysis

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Prime Reciprocals Analysis

🔢 William Shanks & The Reciprocals of Prime Numbers

This document explores the work of William Shanks, a recreational mathematician from the mid-to-late 1800s, who dedicated his spare time to extensive calculations. Shanks is best known for his work on prime numbers and their reciprocals, meticulously calculating the repeating periods of these reciprocals by hand.

📜 William Shanks' Legacy & Reciprocals of Primes

William Shanks submitted his extraordinary findings to the Royal Society, detailing the periods of reciprocals of prime numbers. His work involved calculating 1/p for a prime number p and determining the number of digits before the decimal representation repeats.

  • Methodology: Shanks performed these calculations in batches, sometimes up to 5,000 primes at a time, over many years. This was an incredibly time-consuming process given the manual nature of his work.

  • Table Structure:

    • Left-hand columns: Listed the prime numbers (p).

    • Right-hand columns: Indicated the number of figures (digits) in the repeating period of the reciprocal 1/p.

  • Example: For the prime 60,013, Shanks claimed its reciprocal repeats after 5,001 digits. This means 1/60,013 would produce a sequence of 5,001 seemingly random digits before the pattern begins again.

  • Verification: Modern computational tools, like a "ShanksBot" (Python software), can quickly verify these results. For instance, 1/61,561 has a repeating period of 405 digits, which aligns with Shanks' handwritten results.

➗ Understanding Repeating Decimals via Long Division

To understand how the repeating period is determined, the process of long division is fundamental.

💡 Example: Reciprocal of 7 (1/7)

Let's break down the calculation of 1/7 using long division:

  1. Start: Divide 1 by 7. Since 7 doesn't go into 1, we write 0. and consider 10.

  2. First Step: 7 goes into 10 once (1 x 7 = 7), leaving a remainder of 3. The first digit is 1.

  3. Next Step: Bring down a zero to make it 30. 7 goes into 30 four times (4 x 7 = 28), leaving a remainder of 2. The next digit is 4.

  4. Continue:

    • Bring down a zero to make it 20. 7 goes into 20 twice (2 x 7 = 14), remainder 6. Digit: 2.

      • Bring down a zero to make it 60. 7 goes into 60 eight times (8 x 7 = 56), remainder 4. Digit: 8.

      • Bring down a zero to make it 40. 7 goes into 40 five times (5 x 7 = 35), remainder 5. Digit: 5.

      • Bring down a zero to make it 50. 7 goes into 50 seven times (7 x 7 = 49), remainder 1. Digit: 7.

  5. Repeat: At this point, the remainder is 1, which is what we started with (implicitly 1.0). This means the division process will now repeat the same sequence of remainders and, consequently, the same sequence of digits.

Therefore, 1/7 = 0.142857142857..., and the repeating period is 6 digits (142857).

➕ Example: Reciprocal of 23 (1/23)

Calculating 1/23 is similar but involves larger numbers.

  1. Pre-computation: It's helpful to list multiples of the divisor (23 in this case) to speed up the process.

    • 1×23=231 \times 23 = 231×23=23

      • 2×23=462 \times 23 = 462×23=46

      • 3×23=693 \times 23 = 693×23=69

      • 4×23=924 \times 23 = 924×23=92

      • 5×23=1155 \times 23 = 1155×23=115

      • 6×23=1386 \times 23 = 1386×23=138

      • 7×23=1617 \times 23 = 1617×23=161

      • 8×23=1848 \times 23 = 1848×23=184

      • 9×23=2079 \times 23 = 2079×23=207

  2. Long Division for 1/23:

    • 23 into 100 goes 4 times (92), remainder 8. Result: 0.04...

      • 23 into 80 goes 3 times (69), remainder 11. Result: 0.043...

      • 23 into 110 goes 4 times (92), remainder 18. Result: 0.0434...

      • 23 into 180 goes 7 times (161), remainder 19. Result: 0.04347...

      • 23 into 190 goes 8 times (184), remainder 6. Result: 0.043478...

      • 23 into 60 goes 2 times (46), remainder 14. Result: 0.0434782...

      • 23 into 140 goes 6 times (138), remainder 2. Result: 0.04347826...

      • 23 into 20 (as 200) goes 8 times (184), remainder 16. Result: 0.043478268...

      • ...and so on.

The process continues until a remainder is encountered that has been seen before.

🔄 The Cyclical Nature of Remainders

For any prime number n, when calculating 1/n using long division, the remainders generated at each step will always be less than n (specifically, between 1 and n-1).

  • Finite Possibilities: There are only n-1 possible non-zero remainders (1, 2, ..., n-1).

  • Guaranteed Repeat: Because the number of possible remainders is finite, the process must eventually produce a remainder that has already appeared. Once a remainder repeats, the entire sequence of subsequent digits will also repeat, forming the repeating period.

  • Worst-Case Scenario: The maximum possible length of the repeating period for a prime n is n-1 digits. This occurs when every single possible remainder (from 1 to n-1) appears before the first remainder (1) is encountered again.

    • Example: The prime 60,017 has a repeating period of 60,016 digits, which is n-1. This means it utilized every possible remainder before repeating.

    • In contrast, 60,013 only had a period of 5,001 digits, indicating it did not use all n-1 possible remainders.

🕵️ Shanks' Method & Potential Errors

Given the immense scale of his calculations, it's unlikely Shanks performed all these divisions using the basic long division method.

  • Clues from Errors: Shanks' corrections often involved doubling or halving his initial period lengths (e.g., correcting 30,525 to 61,050). This suggests he might have used a technique involving powers of two or some form of iterative halving, which could lead to systematic errors.

  • Efficiency: The long division method is highly paper-intensive and time-consuming, even for small numbers. A more advanced method would have been necessary to achieve his results for primes up to 110,000.

🚀 Applications & Further Concepts

Shanks noted that his table of prime reciprocals could be used to find the repeating periods of composite numbers that do not have prime factors higher than those in his table.

  • Composite Reciprocals: This involves finding the least common multiple (LCM) of the periods of the prime factors of the composite number.

  • Practicality: Shanks' only stated "practical application" was to enable the calculation of other reciprocals, not a real-world application itself, highlighting his passion for pure mathematical exploration.

🔑 Primitive Roots & Reptend Primes

The length of the repeating period is deeply connected to concepts in number theory:

  • Primitive Root: A prime number p has a primitive root g if the powers of g modulo p generate all integers from 1 to p-1.

  • Decimal System & Primitive Root 10: If 10 is a primitive root modulo a prime p, then the repeating period of 1/p will be exactly p-1 digits. This means it uses every possible remainder before repeating.

    • Example: 60,017 has 10 as a primitive root, hence its period is 60,016 (p-1).

    • Example: 60,013 does not have 10 as a primitive root, so its period is shorter (5,001).

  • Reptend Primes: Primes for which the repeating decimal expansion of their reciprocal has the maximum possible length (p-1) are called Reptend primes (or full repetend primes). These are precisely the primes for which 10 is a primitive root.

    • Definition: A prime p is a Reptend prime if the decimal expansion of 1/p has a period length of p-1.


Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent