Video 3, chapter 4

The Repeated Number Trick

Why the repeated number trick works, how digit concatenation multiplies a three-digit block by the number 1001, and how divisibility and the prime factorization of 1001 into 7, 11 and 13 return the block.

  • Video 3, chapter 4
  • Numbers with a hidden mechanism

Pick any three-digit number, say 326, and write it twice to get 326326. This new number divides exactly by 7, the answer divides exactly by 11, that answer divides exactly by 13, and what remains is 326 again. Nothing about 326 was chosen to suit these divisors, so why does every division come out exact? This page shows that writing a number twice is a hidden multiplication by 1001, and that 1001 is exactly 7 times 11 times 13.

Key terms

The repeated number trick

Definition The repeated number trick starts from a block of three digits, which stands for a whole number nn. Without a leading zero the block runs from 100 to 999. If leading zeros are allowed, as in 042, the block still fills all three places, and nn can be any whole number from 0 to 999. Write the block twice in a row, keeping its digits in the same order, so that 326 becomes 326326. The trick claims that the result is divisible by 7, by 11 and by 13, and that dividing it by these three numbers one after another, in any order, gives back nn, with every division exact. The claim holds for every block, because the written number always equals

1000n+n=1001n,1000n + n = 1001n,

and 1001=7⋅11⋅131001 = 7 \cdot 11 \cdot 13. The three divisors belong to this exact setup, a block of three digits written twice. Blocks of another length, or more than two copies, give other multipliers, which need not contain 7, 11 and 13.

In plain words Writing a number twice secretly multiplies it by 1001, and 1001 is 7 times 11 times 13. Dividing by 7, 11 and 13 only takes that 1001 back out, so the number you started with is all that remains.

Example Take the block 326. The three divisions give

326326÷7=46618,46618÷11=4238,4238÷13=326,\begin{aligned} 326326 \div 7 &= 46618, \\[0.4em] 46618 \div 11 &= 4238, \\[0.4em] 4238 \div 13 &= 326, \end{aligned}

and none of them leaves a remainder. The block itself is not divisible by 7, since 326=7⋅46+4326 = 7 \cdot 46 + 4. The factor 7 in 326326 comes from the 1001, not from the block.

Digit concatenation

Definition Digit concatenation means writing the digits of one number directly after the digits of another, so that 326 followed by 326 gives 326326. Place value turns this into arithmetic. Let k≥1k \ge 1, let AA be a whole number, and let BB be a whole number with 0≤B<10k0 \le B < 10^k, written with exactly kk digits by adding leading zeros when it has fewer. Then the digits of AA followed by the kk digits of BB form the number

A⋅10k+B.A \cdot 10^k + B.

Each digit of AA moves kk places to the left, which multiplies its value by 10k10^k. In particular, a block of kk digits that stands for nn, written twice, gives the number

n⋅10k+n=(10k+1) n.n \cdot 10^k + n = (10^k + 1)\,n.

The width kk of the right copy decides the multiplier, so the width has to be fixed before the block is written twice.

In plain words Writing digits side by side is not adding them. The copy on the left is pushed into higher places, so it counts many times its face value. A three-digit block pushed three places to the left counts a thousand times as much.

Example The left copy in 326326 stands for 326000 and the right copy for 326, so

326326=326000+326=1001⋅326.\begin{aligned} 326326 &= 326000 + 326 \\[0.4em] &= 1001 \cdot 326. \end{aligned}

The block 042 has width three, so writing it twice gives 042042, which stands for 42042=1001⋅4242042 = 1001 \cdot 42. Writing 42 twice without the leading zero gives 4242=101⋅424242 = 101 \cdot 42 instead, the two-digit version of the construction. The zero adds nothing to the value of the block, but it keeps the right copy three places wide, so the left copy moves three places and the multiplier is 1001.

Divisibility

Definition For whole numbers a≥0a \ge 0 and d≥1d \ge 1, the number aa is divisible by dd when a=dqa = dq for some whole number qq. Then dd is a divisor of aa, written d∣ad \mid a, and the division a÷da \div d is exact, with quotient qq and remainder 0. When a number is written as a product of whole numbers, each factor, and each product of some of the factors, divides it. Being divisible by two numbers does not by itself make a number divisible by their product. When the two numbers have no common divisor greater than 1 it does, and otherwise it can fail.

In plain words A division is exact when nothing is left over. Once a number is written as a product, you can read off divisors without dividing, because every factor in the product is one of them.

Example Take the block 582, so the written number is 582582=7⋅11⋅13⋅582582582 = 7 \cdot 11 \cdot 13 \cdot 582. Divide by 13 first.

582582÷13=44814,44814÷7=6402,6402÷11=582.\begin{aligned} 582582 \div 13 &= 44814, \\[0.4em] 44814 \div 7 &= 6402, \\[0.4em] 6402 \div 11 &= 582. \end{aligned}

After the first division the quotient is 44814=7⋅11⋅58244814 = 7 \cdot 11 \cdot 582, which still shows the factors 7 and 11, so the next divisions are exact as well. Changing the order changes the numbers in between but not the end result. Compare the number 12, which is divisible by 4 and by 6 but not by their product 24. The rule about products cannot be used there, because 4 and 6 share the divisor 2.

Prime factorization

Definition A prime number is a whole number greater than 1 whose only positive divisors are 1 and itself, such as 2, 3, 5, 7, 11 and 13. The fundamental theorem of arithmetic says that every whole number greater than 1 can be written as a product of primes, and that this product is unique apart from the order of the factors. That product is the prime factorization of the number. It shows every divisor at once, because the positive divisors of a whole number greater than 1 are exactly the products of some of its prime factors, each used at most as often as it appears in the factorization, with the product of none of them counted as 1. It follows that a prime that divides a product of whole numbers divides at least one of the factors.

In plain words Primes are the building blocks of multiplication. Break a number into primes once, and you know every exact division it allows.

Example To factor 1001, try the primes in order. It is odd, its digit sum 2 is not a multiple of 3, and it does not end in 0 or 5, so 2, 3 and 5 fail. The next prime works, since 1001=7⋅1431001 = 7 \cdot 143, and then 143=11⋅13143 = 11 \cdot 13. So the prime factorization is

1001=7⋅11⋅13,1001 = 7 \cdot 11 \cdot 13,

and the positive divisors of 1001 are the eight numbers 1, 7, 11, 13, 77, 91, 143 and 1001. Because 7, 11 and 13 are different primes, a whole number is divisible by all three exactly when it is divisible by 1001.

The number 1001

Definition The number 1001 equals 103+110^3 + 1, and its prime factorization is 7⋅11⋅137 \cdot 11 \cdot 13. It is the multiplier hidden in the repeated number trick, since a block of three digits that stands for nn, written twice, makes 1001n1001n. The written number is the product 7⋅11⋅13⋅n7 \cdot 11 \cdot 13 \cdot n, so dividing it by any one of the three primes leaves a product that still contains the other two. The three divisions are therefore exact in each of the six possible orders, and they always end at 1001n÷1001=n1001n \div 1001 = n. For a block of kk digits written twice, with the width kk kept fixed, the multiplier is 10k+110^k + 1 instead, and its factors depend on kk. Repeating a block more than twice changes the multiplier again.

In plain words The trick is really a fact about 1001, not about the digits you choose. Change the length of the block or the number of copies, and you get a different hidden multiplier with its own divisors.

Example The multipliers for blocks of one to six digits written twice are these.

Block lengthMultiplierPrime factorization
11111, a prime
2101101, a prime
310017⋅11⋅137 \cdot 11 \cdot 13
41000173⋅13773 \cdot 137
510000111⋅909111 \cdot 9091
61000001101⋅9901101 \cdot 9901

Only the length 3 in the table brings all of 7, 11 and 13. Over all lengths, 7, 11 and 13 all divide 10k+110^k + 1 exactly when kk is 3, 9, 15 and so on, the lengths that leave remainder 3 on division by 6. Three copies of the block 326 give

326326326=1001001⋅326,1001001=3⋅333667,\begin{aligned} &326326326 \\[0.4em] &\quad = 1001001 \cdot 326, \\[0.4em] &1001001 = 3 \cdot 333667, \end{aligned}

where 333667 is prime. The prime 7 divides neither 1001001 nor 326, so it does not divide 326326326, which leaves remainder 4 on division by 7.

Check yourself

  1. Write the block 731 twice and divide the result by 11, then by 13, then by 7. What are the numbers along the way, and is 731 itself divisible by any of the three divisors?
Show the answer

The written number is 731731=1001⋅731731731 = 1001 \cdot 731, and the divisions give

731731÷11=66521,66521÷13=5117,5117÷7=731,\begin{aligned} 731731 \div 11 &= 66521, \\[0.4em] 66521 \div 13 &= 5117, \\[0.4em] 5117 \div 7 &= 731, \end{aligned}

with no remainders. The block itself factors as 731=17⋅43731 = 17 \cdot 43, so none of 7, 11 and 13 divides it. All three divisors come from the multiplier 1001.

  1. A friend wants to run the trick with the block 085 and writes 8585. Which number should the friend have written, and is 8585 divisible by 7, 11 or 13?
Show the answer

Keeping the width at three places gives 085085, which stands for 85085=1001⋅8585085 = 1001 \cdot 85. It works as the trick promises, since 85085÷7=1215585085 \div 7 = 12155, then 12155÷11=110512155 \div 11 = 1105, then 1105÷13=851105 \div 13 = 85. The number 8585 is the two-digit construction applied to 85, so

8585=101⋅85=5⋅17⋅101.\begin{aligned} 8585 &= 101 \cdot 85 \\[0.4em] &= 5 \cdot 17 \cdot 101. \end{aligned}

None of 7, 11 and 13 appears in this prime factorization, so none of them divides 8585. Direct division agrees, with remainders 3, 5 and 5 on division by 7, 11 and 13. The leading zero has no value of its own, but dropping it changes the multiplier from 1001 to 101.

  1. Extend the trick to four-digit blocks. Write 2026 twice, and find two divisions that bring back 2026. Is the result divisible by 7?
Show the answer

The right copy is four places wide, so the left copy moves four places and

20262026=2026⋅104+2026=10001⋅2026.\begin{aligned} 20262026 &= 2026 \cdot 10^4 \\[0.4em] &\quad + 2026 \\[0.4em] &= 10001 \cdot 2026. \end{aligned}

Since 10001=73⋅13710001 = 73 \cdot 137, the divisions 20262026÷73=27756220262026 \div 73 = 277562 and 277562÷137=2026277562 \div 137 = 2026 bring the block back, in either order. The prime 7 does not divide 10001, which leaves remainder 5, and it does not divide 2026=2⋅10132026 = 2 \cdot 1013, which leaves remainder 3. A prime that divides a product divides one of its factors, so 7 does not divide 20262026. Its remainder is 1. For four-digit blocks the divisors that always work are 73 and 137, not 7, 11 and 13.