# Is 20482048 the highest power of 22 with all even digits (base ten)?

I have a friend who turned $$3232$$ recently. She has an obsessive compulsive disdain for odd numbers, so I pointed out that being $$3232$$ was pretty good since not only is it even, it also has no odd factors. That made me realize that $$6464$$ would be an even better age for her, because it’s even, has no odd factors, and has no odd digits. I then wondered how many other powers of $$22$$ have this property. The only higher power of $$22$$ with all even digits that I could find was $$2048.2048.$$

So is there a larger power of $$22$$ with all even digits? If not, how would you go about proving it?

I tried examining the last $$NN$$ digits of powers of $$22$$ to look for a cycle in which there was always at least one odd digit in the last $$NN$$ digits of the consecutive powers. Unfortunately, there were always a very small percentage of powers of $$22$$ whose last $$NN$$ digits were even.

Edit: Here’s a little more info on some things I found while investigating the $$NN$$ digit cycles.

$$NN$$: $$2,3,4,5,6,7,8,92,3,4,5,6,7,8,9$$

Cycle length: $$20,100,500,2500,12500,62520,312500,1562500,…,4⋅5N−120,100,500,2500,12500,62520,312500,1562500,\dotsc, 4\cdot 5^{N-1}$$

Number of suffixes with all even digits in cycle: $$10,25,60,150,370,925,2310,5780,∼4⋅2.5N−110, 25, 60, 150, 370, 925, 2310,5780,\sim4\cdot2.5^{N-1}$$

It seems there are some interesting regularities there. Unfortunately, one of the regularities is those occurrences of all even numbers! In fact, I was able to find a power of $$22$$ in which the last $$3333$$ digits were even $$(23789535319=…468088628828226888000862880268288)(2^{3789535319} = \dots 468088628828226888000862880268288)$$.

Yes it’s true that it took a power of $$22$$ with over a billion digits to even get the last $$3333$$ to be even, so it would seem any further powers of $$22$$ with all even digits are extremely unlikely. But I’m still curious as to how you might prove it.

Edit 2: Here’s another interesting property I noticed. The next digit to the left of the last $$NN$$ digits will take on every value of its parity as the $$NN$$ digits cycle each time. Let me illustrate.

The last $$22$$ digits cycle every $$2020$$ powers. Now examine the following:

$$27=1282^7 = 128$$
$$227=…7282^{27} = \dots 728$$
$$247=…3282^{47} = \dots 328$$
$$267=…9282^{67} = \dots 928$$
$$287=…5282^{87} = \dots 528$$
$$2107=…1282^{107} = \dots 128$$

Notice that the hundreds place starts out odd and then proceeds to take on every odd digit as the final 2 digits cycle.

As another example, let’s look at the fourth digit (knowing that the last 3 digits cycle every 100 powers.)

$$218=2621442^{18} = 262144$$,
$$2118=…61442^{118} = \dots 6144$$,
$$2218=…01442^{218} = \dots 0144$$,
$$2318=…41442^{318} = \dots 4144$$,
$$2418=…81442^{418} = \dots 8144$$,
$$2518=…21442^{518} = \dots 2144$$

This explains the power of 5 in the cycle length as each digit must take on all five digits of its parity.

EDIT 3: It looks like the $$(N+1)(N+1)$$st digit takes on all the values $$0−90-9$$ as the last $$NN$$ digits complete half a cycle. For instance, the last $$22$$ digits cycle every $$2020$$ powers, so look at the third digit every $$1010$$ powers:

$$28=2562^{8} = 256$$,
$$218=…1442^{18} = \dots 144$$,
$$228=…4562^{28} = \dots 456$$,
$$238=…9442^{38} = \dots 944$$,
$$248=…6562^{48} = \dots 656$$,
$$258=…7442^{58} = \dots 744$$,
$$268=…8562^{68} = \dots 856$$,
$$278=…5442^{78} = \dots 544$$,
$$288=…0562^{88} = \dots 056$$,
$$298=…3442^{98} = \dots 344$$

Not only does the third digit take on every value 0-9, but it also alternates between odd and even every time (as the Edit 2 note would require.) Also, the N digits cycle between two values, and each of the N digits besides the last one alternates between odd and even. I’ll make this more clear with one more example which looks at the fifth digit:

$$220=…485762^{20} = \dots 48576$$,
$$2270=…114242^{270} = \dots 11424$$,
$$2520=…285762^{520} = \dots 28576$$,
$$2770=…314242^{770} = \dots 31424$$,
$$21020=…085762^{1020} = \dots 08576$$,
$$21270=…514242^{1270} = \dots 51424$$,
$$21520=…885762^{1520} = \dots 88576$$,
$$21770=…714242^{1770} = \dots 71424$$,
$$22020=…685762^{2020} = \dots 68576$$,
$$22270=…914242^{2270} = \dots 91424$$

EDIT 4: Here’s my next non-rigorous observation. It appears that as the final N digits cycle 5 times, the $$(N+2)(N+2)$$th digit is either odd twice and even three times, or it’s odd three times and even twice. This gives a method for extending an all even suffix.

If you have an all even N digit suffix of $$2a2^a$$, and the (N+1)th digit is odd, then one of the following will have the (N+1)th digit even:

$$2(a+1∗4∗5N−2)2^{(a+1*4*5^{N-2})}$$,
$$2(a+2∗4∗5N−2)2^{(a+2*4*5^{N-2})}$$,
$$2(a+3∗4∗5N−2)2^{(a+3*4*5^{N-2})}$$

Edit 5: It’s looking like there’s no way to prove this conjecture solely by examining the last N digits since we can always find an arbitrarily long, all even, N digit sequence. However, all of the digits are distributed so uniformly through each power of 2 that I would wager that not only does every power of 2 over 2048 have an odd digit, but also, every power of 2 larger than $$21682^{168}$$ has every digit represented in it somewhere.

But for now, let’s just focus on the parity of each digit. Consider the value of the $$kthk^{th}$$ digit of $$2n2^n$$ (with $$a0a_0$$ representing the 1’s place.)

$$ak=⌊2n10k⌋ mod 10⇒ak=⌊2n−k5k⌋ mod 10 a_k = \left\lfloor\frac{2^n}{10^k}\right\rfloor \text{ mod 10}\Rightarrow a_k = \left\lfloor\frac{2^{n-k}}{5^k}\right\rfloor \text{ mod 10}$$

We can write
$$2n−k=d⋅5k+r2^{n-k} = d\cdot5^k + r$$
where $$dd$$ is the divisor and $$rr$$ is the remainder of $$2n−k/5k2^{n-k}/5^k$$. So
$$a_k \equiv \frac{2^{n-k}-r}{5^k} \equiv d \pmod{10} a_k \equiv \frac{2^{n-k}-r}{5^k} \equiv d \pmod{10}$$
$$\Rightarrow a_k \equiv d \pmod{2}\Rightarrow a_k \equiv d \pmod{2}$$
And
$$d\cdot5^k = 2^{n-k} – r \Rightarrow d \equiv r \pmod{2}d\cdot5^k = 2^{n-k} - r \Rightarrow d \equiv r \pmod{2}$$
Remember that $$rr$$ is the remainder of $$2^{n-k} \text{ div } {5^k}2^{n-k} \text{ div } {5^k}$$ so

$$\text{The parity of a_k is the same as the parity of 2^{n-k} mod 5^k.}\text{The parity of a_k is the same as the parity of 2^{n-k} mod 5^k.}$$

Now we just want to show that for any $$2^n > 20482^n > 2048$$ we can always find a $$kk$$ such that $$2^{n-k} \text{ mod }5^k2^{n-k} \text{ mod }5^k$$ is odd.

I’m not sure if this actually helps or if I’ve just sort of paraphrased the problem.

EDIT 6: Thinking about $$2^{n-k}2^{n-k}$$ mod $$5^k5^k$$, I realized there’s a way to predict some odd digits.

$$2^a \pmod{5^k} \text{ is even for } 1\le a< log_2 5^k2^a \pmod{5^k} \text{ is even for } 1\le a< log_2 5^k$$

The period of $$2^a \pmod{5^k}2^a \pmod{5^k}$$ is $$4\cdot5^{k-1}4\cdot5^{k-1}$$ since 2 is a primitive root mod $$5^k5^k$$. Also

$$2^{2\cdot5^{k-1}} \equiv -1 \pmod{5^k}2^{2\cdot5^{k-1}} \equiv -1 \pmod{5^k}$$

So multiplying any $$2^a2^a$$ by $$2^{2\cdot5^{k-1}}2^{2\cdot5^{k-1}}$$ flips its parity mod $$5^k5^k$$. Therefore $$2^a \pmod{5^k}\text{ }2^a \pmod{5^k}\text{ }$$ is odd for

$$1 + 2\cdot5^{k-1} \le a< 2\cdot5^{k-1} + log_2 5^k1 + 2\cdot5^{k-1} \le a< 2\cdot5^{k-1} + log_2 5^k$$

Or taking the period into account, $$2^a \pmod{5^k} \text{ }2^a \pmod{5^k} \text{ }$$ is odd for any integer $$b\ge0b\ge0$$ such that

$$1 + 2\cdot5^{k-1} (1 + 2b) \le a< 2\cdot5^{k-1} (1 + 2b) + log_2 5^k1 + 2\cdot5^{k-1} (1 + 2b) \le a< 2\cdot5^{k-1} (1 + 2b) + log_2 5^k$$

Now for the $$k^{th}k^{th}$$ digit of $$2^n2^n$$ ($$k=0 \text{ } k=0 \text{ }$$ being the 1's digit), we're interested in the parity of $$2^{n-k}2^{n-k}$$ mod $$5^k5^k$$. Setting $$a =n-k \text{ } a =n-k \text{ }$$ we see that the $$k^{th}k^{th}$$ digit of $$2^n2^n$$ is odd for integer $$b\ge0b\ge0$$ such that

$$1 + 2\cdot5^{k-1} (1 + 2b) \le n - k < 2\cdot5^{k-1} (1 + 2b) + log_2 5^k1 + 2\cdot5^{k-1} (1 + 2b) \le n - k < 2\cdot5^{k-1} (1 + 2b) + log_2 5^k$$

To illustrate, here are some guaranteed odd digits for different $$2^n2^n$$:

(k=1 digit): $$2\cdot5^0 + 2 = 4 \le n \le 5 2\cdot5^0 + 2 = 4 \le n \le 5$$
(k=2 digit): $$2\cdot5^1 + 3 = 13 \le n \le 16 2\cdot5^1 + 3 = 13 \le n \le 16$$
(k=3 digit): $$2\cdot5^2 + 4 = 54 \le n \le 59 2\cdot5^2 + 4 = 54 \le n \le 59$$
(k=4 digit): $$2\cdot5^3 + 5 = 255 \le n \le 263 2\cdot5^3 + 5 = 255 \le n \le 263$$

Also note that these would repeat every $$4\cdot5^{k-1}4\cdot5^{k-1}$$ powers.

These guaranteed odd digits are not dense enough to cover all of the powers, but might this approach be extended somehow to find more odd digits?

Edit 7: The two papers that Zander mentions below make me think that this is probably a pretty hard problem.

This seems to be similar to (I'd venture to say as hard as) a problem of Erdős open since 1979, that the base-3 representation of $2^n$ contains a 2 for all $n>8$.
Here is a paper by Lagarias that addresses the ternary problem, and for the most part I think would generalize to the question at hand (we're also looking for the intersection of iterates of $x\rightarrow 2x$ with a Cantor set). Unfortunately it does not resolve the problem.
But Conjecture 2' (from Furstenberg 1970) in the linked paper suggests a stronger result, that every $2^n$ for $n$ large enough will have a 1 in the decimal representation. Though it doesn't quantify "large enough" (so even if proved wouldn't promise that 2048 is the largest all-even decimal), it looks like it might be true for all $n>91$ (I checked up to $n=10^6$).