Prime reciprocal magic square
A prime reciprocal magic square is a magic square using the decimal digits of the reciprocal of a prime number.
Consider unit fractions such as 1/2, 1/3 or 1/7. In base ten, one-half has no repeating decimal while one-third repeats 0.3333... indefinitely. The remainder of one-seventh, on the other hand, repeats over six digits as 1/7 = 0.1428571428571...
Multiples of 1/7 exhibit cyclic permutations of these six digits:[1]
1/7 = 0·1 4 2 8 5 7... 2/7 = 0·2 8 5 7 1 4... 3/7 = 0·4 2 8 5 7 1... 4/7 = 0·5 7 1 4 2 8... 5/7 = 0·7 1 4 2 8 5... 6/7 = 0·8 5 7 1 4 2...
If the digits are laid out as a square, each row will sum to 1 + 4 + 2 + 8 + 5 + 7 = 27. Each column will equivalently add to 27 and consequently we have a magic square:
1 4 2 8 5 7 2 8 5 7 1 4 4 2 8 5 7 1 5 7 1 4 2 8 7 1 4 2 8 5 8 5 7 1 4 2
However, neither diagonals add to 27. All other prime reciprocals in base ten with maximum period of p−1 produce squares in which all rows and columns sum to the same total.
When an even repeating cycle produced from an odd prime reciprocal (such as 1/7 = 0.142857142857...) is mirrored halfway accordingly (i.e. 142857 and 857142), the pair of complementary sequences of digits generated will yield a sequence of 9s when added:
1/7 = 0.142,857,142,857 ... +0.857,142 --------- 0.999,999
1/11 = 0.09090,90909 ... +0.90909,09090 ----- 0.99999,99999
1/13 = 0.076,923 076,923 ... +0.923,076 --------- 0.999,999
1/17 = 0.05882352,94117647 +0.94117647,05882352 ------------------- 0.99999999,99999999
1/19 = 0.052631578,947368421 ... +0.947368421,052631578 ---------------------- 0.999999999,999999999
This is a result of Midy's theorem.[2][3]
Concerning the number of decimal places shifted in the quotient per multiple of 1/19, a factor of 2 in the numerator produces a shift of one decimal place to the right in the quotient:
01/19 = 0.052631578,947368421 02/19 = 0.1052631578,94736842 04/19 = 0.21052631578,9473684 08/19 = 0.421052631578,947368 16/19 = 0.8421052631578,94736
In the 1/19 magic square with maximum period 18, there is a row-and-column total of 81 that is also that obtained by both diagonals. This makes it the first full (non-normal) prime reciprocal magic square in base-10:[4]
01/19 = 0·0 5 2 6 3 1 5 7 8 9 4 7 3 6 8 4 2 1... 02/19 = 0·1 0 5 2 6 3 1 5 7 8 9 4 7 3 6 8 4 2... 03/19 = 0·1 5 7 8 9 4 7 3 6 8 4 2 1 0 5 2 6 3... 04/19 = 0·2 1 0 5 2 6 3 1 5 7 8 9 4 7 3 6 8 4... 05/19 = 0·2 6 3 1 5 7 8 9 4 7 3 6 8 4 2 1 0 5... 06/19 = 0·3 1 5 7 8 9 4 7 3 6 8 4 2 1 0 5 2 6... 07/19 = 0·3 6 8 4 2 1 0 5 2 6 3 1 5 7 8 9 4 7... 08/19 = 0·4 2 1 0 5 2 6 3 1 5 7 8 9 4 7 3 6 8... 09/19 = 0·4 7 3 6 8 4 2 1 0 5 2 6 3 1 5 7 8 9... 10/19 = 0·5 2 6 3 1 5 7 8 9 4 7 3 6 8 4 2 1 0... 11/19 = 0·5 7 8 9 4 7 3 6 8 4 2 1 0 5 2 6 3 1... 12/19 = 0·6 3 1 5 7 8 9 4 7 3 6 8 4 2 1 0 5 2... 13/19 = 0·6 8 4 2 1 0 5 2 6 3 1 5 7 8 9 4 7 3... 14/19 = 0·7 3 6 8 4 2 1 0 5 2 6 3 1 5 7 8 9 4... 15/19 = 0·7 8 9 4 7 3 6 8 4 2 1 0 5 2 6 3 1 5... 16/19 = 0·8 4 2 1 0 5 2 6 3 1 5 7 8 9 4 7 3 6... 17/19 = 0·8 9 4 7 3 6 8 4 2 1 0 5 2 6 3 1 5 7... 18/19 = 0·9 4 7 3 6 8 4 2 1 0 5 2 6 3 1 5 7 8...
The next prime number in decimal whose reciprocal can be used to produce a non-normal full prime reciprocal magic square is 383.[5]
The same phenomenon occurs with other primes in other bases, and the following table lists some of them, giving the prime, base, and magic total (derived from the formula base−1 × prime−1 / 2):
Prime | Base | Total |
---|---|---|
19 | 10 | 81 |
53 | 12 | 286 |
53 | 34 | 858 |
59 | 2 | 29 |
67 | 2 | 33 |
83 | 2 | 41 |
89 | 19 | 792 |
167 | 68 | 5,561 |
199 | 41 | 3,960 |
199 | 150 | 14,751 |
211 | 2 | 105 |
223 | 3 | 222 |
293 | 147 | 21,316 |
307 | 5 | 612 |
383 | 10 | 1,719 |
389 | 360 | 69,646 |
397 | 5 | 792 |
421 | 338 | 70,770 |
487 | 6 | 1,215 |
503 | 420 | 105,169 |
587 | 368 | 107,531 |
593 | 3 | 592 |
631 | 87 | 27,090 |
677 | 407 | 137,228 |
757 | 759 | 286,524 |
787 | 13 | 4,716 |
811 | 3 | 810 |
977 | 1,222 | 595,848 |
1,033 | 11 | 5,160 |
1,187 | 135 | 79,462 |
1,307 | 5 | 2,612 |
1,499 | 11 | 7,490 |
1,877 | 19 | 16,884 |
1,933 | 146 | 140,070 |
2,011 | 26 | 25,125 |
2,027 | 2 | 1,013 |
2,141 | 63 | 66,340 |
2,539 | 2 | 1,269 |
3,187 | 97 | 152,928 |
3,373 | 11 | 16,860 |
3,659 | 126 | 228,625 |
3,947 | 35 | 67,082 |
4,261 | 2 | 2,130 |
4,813 | 2 | 2,406 |
5,647 | 75 | 208,902 |
6,113 | 3 | 6,112 |
6,277 | 2 | 3,138 |
7,283 | 2 | 3,641 |
8,387 | 2 | 4,193 |
See also
References
- Wells, D. (1987). The Penguin Dictionary of Curious and Interesting Numbers. London: Penguin Books. pp. 171–174. ISBN 0-14-008029-5. OCLC 39262447. S2CID 118329153.
- Rademacher, Hans; Toeplitz, Otto (1957). The Enjoyment of Mathematics: Selections from Mathematics for the Amateur (2nd ed.). Princeton, NJ: Princeton University Press. pp. 158–160. ISBN 9780486262420. OCLC 20827693. Zbl 0078.00114.
- Leavitt, William G. (June 1967). "A Theorem on Repeating Decimals". The American Mathematical Monthly. Mathematical Association of America. 74 (6): 669–673. doi:10.2307/2314251. JSTOR 2314251.
- Andrews, William Symes (1917). Magic Squares and Cubes (PDF). Chicago, IL: Open Court Publishing Company. pp. 176, 177. ISBN 9780486206585. MR 0114763. OCLC 1136401. Zbl 1003.05500.
- Sloane, N. J. A. (ed.). "Sequence A072359 (Primes p such that the p-1 digits of the decimal expansion of k/p (for k equal to 1,2,3,...,p-1) fit into the k-th row of a magic square grid of order p-1.)". The On-Line Encyclopedia of Integer Sequences. OEIS Foundation. Retrieved 2023-09-04.
External links
Eric W. Weisstein, "Midy's Theorem." From MathWorld — A Wolfram Web Resource