# A 10-adic number that is a zero divisor

A few weeks ago I wrote about p-adic numbers. I mentioned that if p is not prime, then the p-adic numbers can have zero divisors; that is, there are nonzero numbers $x$ and $y$ such that $xy=0$.

Today Foxmaths! wrote about a 10-adic number (although not using that terminology)

$F=\ldots4106619977392256259918212890625$

such that $F^2=F$ (in other words $F$ is an idempotent element of the 10-adic numbers). Of course, with a little algebra we can turn this into $0=F^2-F=F(F-1)$. In other words, both $F$ and $F-1$ are zero divisors in the set of 10-adic numbers.

In the post Foxmaths discusses how to generate other numbers of this form. In particular, assume $F$ is such a number and $a_n$ is the integer which corresponds to the first $n+1$ digits of $F$. Foxmaths goes on to write:

The n-th digit of $a_n$ is given by the n-th digit of $a_{n-1}^2$ . Which I think is a strikingly simple result.

Observe. Starting at $a_0=5$, we have $5*5=25$. So the 1-th digit of $a_1$ is given by the 1-th digit of 25, the 2. Thus $a_1=25$.

Carrying on, we see that $25*25=625$, so the 2-th digit of $a_2$ is given by the 2-th digit of 625, the 6. $a_2=625$.

Next, $625*625=390625$. So the 3-th digit of $a_3$ is a 0. This means that $a_3=625$ in value.

But then we have again, $625*625=390625$, and the 4-th digit of $a_4$ is given by the 4-th digit of 390625, the 9. Thus, $a_4=90625$.

And so it goes. We can use this to deterministically calculate as many digits of F as we like.

If I am reading his derivation correctly, then it appears the right-most digit of $a$ determines the rest of the digits of $a$. In particular, there must only be ten idempotent 10-adic integers (two of which are 0 and 1). [Update: Moreover, this digit can only be 0, 1, 5, or 6 because we need $a_0^2=a_0$ (mod 10). In particular, there must be only four idempotent 10-adic integers (two of which are 0 and 1).] Very cool.

Disclaimer: I do not know much more about p-adic numbers than what I’ve written on my blog. Presumably this fact is well-known among experts, or maybe I’m misinterpreting this and I’m completely wrong.

1. Fox says:

But but but!

The rightmost digit determines everything, but what determines the rightmost digit?

It must be that a*a = a (mod 10).

0, 1, 2, 3, 4, 5, 6, 7, 8, 9 square to give

0, 1, 4, 9, 6, 5, 6, 9, 4, 1 (mod 10)

Thus the rightmost digit can only be 0, 1, 5, 6.

So, this means there are only four?

Which is interesting, since 4 has no obvious connection to 10. Hmm!

2. Of course! Thank you for pointing that out. I fixed the post accordingly.

3. Michael Lugo says:

The connection between 4 and 10 is that 4 is the number of roots of x^2 – x (mod 10). This is the product of the number of roots of x^2 – x (mod 2) and x^2 – x (mod 5), each of which are 2.

In general, the number of solutions of x^2 – x (mod n) is 2^q(n), where q(n) is the number of distinct primes dividing n. This is because x^2 – x (mod p^j) for prime powers p^j has exactly two solutions; then apply the Chinese Remainder Theorem.

So it seems that the number of idempotent n-adic integers is 2^q(n), and there are “nontrivial” idempotent n-adics (i. e. idempotent n-adics other than 0 and 1) if and only if n is composite.

4. Brian Dean says:

I have a question about 10-adic numbers.

I know that 1/2 doesn’t exist in 10-adic because when you try to divide it, you can’t get 2 times anything to get 1. However, if you look at 2/4, and try to divide that, you get

0000000000002
0000000000012 (4*3)
_____________
9999999999990

So the first digit is 3, but the algorithm breaks down after that because you can’t get 4 times anything to be 9.

If you go with higher powers of 2 (for example 512/1024) you will find that you can go even further before the algorithm breaks down.

This leads me to believe that although 1/2 doesn’t exist in 10-adic, there does exist a limit as n approaches infinity of (2^n)/(2^(n+1))

Actually, there are two answers. They are:

…43441122120343012014132000331301242113113403320313
and
…56558877879656987985867999668698757886886596679688

If you add those two numbers, you get 1.

My question is, is this a natural result of the 10-adics having zero divisors or did I stumble on something more interesting?

5. Fibonacci says:

But isn’t 1/2 = 0,5 in 10-adics too?

As for zero divisors, as I pointed out in Foxmaths’ blog, is G = 1 – F = …607743740081787109376. This, also, is completely determined by the rightmost digit by a similar procedure – except that you subtract each new nonzero digit from 10 before attaching it to the left.