# Some Interesting Properties of the number 142857

The number 142857 have such interesting properties.

It is the smallest number for which x, 2x, 3x, 4x, 5x, 6x all have the same digits(in different orders, of course).

Went through Wikipedia and found out amazing things about this number. Wanted to Share with you all.

-
Also, it has 42 embedded in it... –  copper.hat Mar 26 '13 at 9:30
As well as including leading zeros, you also open up lots of possibilities, and interesting analysis, if look for numbers in different bases with this cyclic behaviour. –  Mark Hurd Mar 26 '13 at 13:25

Well, $\frac{1}{7}$ = 0.142857142857142857...
Multiplying by ten, we see that

10 * $\frac{1}{7}$ = 1.42857 142857 142857...

On the other hand, 10 * $\frac{1}{7}$ = $\frac{10}{7}$ = 1 + $\frac{3}{7}$, so

1 + $\frac{3}{7}$ = 1.42857142857142857...

Subtracting 1 from each side, we have

$\frac{3}{7}$ = 0.42857142857142857...

If we multiply by 100 instead of ten, 14 + $\frac{2}{7}$ = 100 * $\frac{1}{7}$ = 14.2857142857142857...

So, $\frac{2}{7}$ = .2857142857142857...

Continuing with this game, we have

142 + $\frac{6}{7}$ = $\frac{1000}{7}$ = 142.857142857142857... so 6/7 = 0.857142857142857...

1428 + $\frac{4}{7}$ = $\frac{10000}{7}$ = 1428.57142857142857... so 4/7 = 0.57142857142857...

14285 + $\frac{5}{7}$ = $\frac{100000}{7}$ = 14285.7142857142857... so $\frac{5}{7}$ = 0.57142857142857...

so we see that the decimal expansions of each of $\frac{1}{7}$, $\frac{2}{7}$, $\frac{3}{7}$, $\frac{4}{7}$, $\frac{5}{7}$, and $\frac{6}{7}$ are cycles of the same digits.

So what were the ingredients here?

$\frac{1}{7}$ is a rational number with lowest-common-terms denominator relatively prime to ten, so we get a repeating decimal that repeats right off the bat. By successively multiplying $\frac{1}{7}$ by powers of ten, we get all numbers whose fractional parts cover every multiple of $\frac{1}{7}$ between 0 and 1.

Where do these fail for other numbers?

Well, if we tried a rational number with a denominator that divided some power of ten, we'd have a terminating decimal expansion:

$\frac{1}{25}$ = 0.04

No fun there. Even if the number only shared a common divisor with 10, we'd run into trouble:

$\frac{1}{6}$ = 0.1666666666...

That 1 at the beginning prevents the expansion from being completely cyclic, which again spoils our fun. Since 6 and 10 share a common divisor of 2, we can fix this by doubling the previous equation:

$\frac{1}{3}$ = 0.3333333333...

This number fails condition 2, unfortunately: $\frac{10}{3}$ = 3 + $\frac{1}{3}$, so multiplying by 10 will always leave a fractional part of $\frac{1}{3}$, and we won't obtain an expression for 2/3 as a permutation of the digits in the expansion of $\frac{1}{3 }$. (We couldn't get such an expression, of course -- $\frac{2}{3}$ = 0.66666666666...) We get the same problem with 11, albeit not as directly.

$\frac{1}{11}$ = 0.0909090909...$\frac{10 }{11}$ = 0.909090909... $\frac{100}{11}$ = 9 + $\frac{1}{11}$ = 9.09090909...

So our expressions bounce back and forth between having fractional parts $\frac{1}{11}$ and $\frac{10}{11}$.

So what's the difference between 7 and 3 and 11? Well, in mathematical terms, 10 is a generator of the multiplicative group (mod 7), but it's not a generator of the multiplicative group (mod 11), and, even worse, it's the multiplicative identity (mod 3). By the process described above, we see that, whenever n is relatively prime to 10 and 10 is a generator of the multiplicative group (mod n), we have the same sorts of properties described above.

There's one more subtlety here as well it could be that 10 and n are relatively prime, and that 10 generates the multiplicative group (mod n), but some numbers less than n are not in the multiplicative group (mod n). This happens precisely when n is composite. So we need n to be prime.

(The condition n > 5 rules out the primes 2 and 5, which are not relatively prime to 10, and the prime 3, which we ruled out above. We could also say "n is prime, but not 2 or 5" and let condition 2 rule out the number 3, but the above is more compact.)

Okay, so what's the next number after 7 that satisfies our conditions? Well, 10 has order 6 in the multiplicative group (mod 13), so that's out, and 15 isn't prime. The next choice is 17, and we can check that 10 does indeed generate the multiplicative group (mod 17) -- the easiest way is to note that

$\frac{1}{17}$ = 0.05882352941176470588235294117647 05882352941176470588235294117647 05882352941176470...

has a sixteen-digit repeating part (16 = 17-1). So if we take the number

588235294117647

and consider its multiples

• 1 = 0588235294117647

• 2 = 1176470588235294

• 3 = 1764705882352941

• 4 = 2352941176470588

• 5 = 2941176470588235

• 6 = 3529411764705882

• 7 = 4117647058823529

• 8 = 4705882352941176

• 9 = 5294117647058823

we see this same "cyclic" behavior, although it's not as visually obvious because there are so many more digits.

Can we get a better characterization of the values of n which make this work? Unfortunately, no -- there's no formula for the primitive roots (mod n).

To summarize, 142857 has these properties because $\frac{1}{7}$ = 0.142857142857142857..., 7 is a prime number, and 10 is a primitive root modulo 7.

it's the period of a reptend number (see http://oeis.org/A001913 for more information), and moreover it's the only one which does not contain any 0 in it. If you allow leading zeroes, 0588235294117647, 052631578947368421, 0434782608695652173913 have the same properties.