Is there a power of $2$ which begins, in base 10, with $999…$? [closed]

Is there a power of $$2$$ which begins, in base 10, with $$999...$$?

I don't know how to do it, maybe I must apply Dirichlet principle but in which way?

closed as off-topic by Henrik, Jyrki Lahtonen, Paul Frost, Cesareo, AndreiDec 28 '18 at 18:48

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question is missing context or other details: Please provide additional context, which ideally explains why the question is relevant to you and our community. Some forms of context include: background and motivation, relevant definitions, source, possible strategies, your current progress, why the question is interesting or important, etc." – Henrik, Jyrki Lahtonen, Paul Frost, Cesareo
If this question can be reworded to fit the rules in the help center, please edit the question.

• I don't see how the Diichlet principle can be of any value here. – Henrik Dec 28 '18 at 9:19
• @Henrik I'm fairly sure that the OP has Dirichlet's approximation theorem in mind. – Jyrki Lahtonen Dec 28 '18 at 10:17
• Assuming that the string of nines has a finite length (in spite of appearances to the contrary), then this is question is also a duplicate. If that string is not finite, then the question is non-sensical. – Jyrki Lahtonen Dec 28 '18 at 10:20
• @JyrkiLahtonen: That would make more sense. – Henrik Dec 28 '18 at 10:42
• Possible duplicate of Starting digits of $2^n$. – Andrei Dec 28 '18 at 18:48

To find many answers, you can start looking for $$n,m$$ such that $$2^n \approx 10^m$$, which is equivalent to $$n\log2\approx m\log10$$.

In other words, we look for rational approximations of $$\frac{\log10}{\log2}$$, in which case $$n$$ would be the numerator.

Using continued fractions, for

$$\frac{\log10}{\log2} \approx 3 + \frac1{3 + \frac1{9 + \frac1{2 + \frac1{2 + \frac1{4 + \frac16}}}}} = \frac{13301}{4004}$$

we find $$n = 13301$$, for which $$2^n$$ starts with 9999.

Note that since the sequence of continued fractions converges to the value, there is no limit on the number of leading 9's a power of 2 can have.

• If $2^{13301} \approx 10^{4004}$ cat it not start with 1000 instead of 9999? – Todor Markov Dec 28 '18 at 9:39
• With continued fraction approximations you will alternatingly overshoot and undershoot, so you can stop at the right moment to make sure you are below. This doesn't tell you how many 9's you'll have at the beginning. In reality what I did was simply compute the value to check it had at least 3 leading 9's – doetoe Dec 28 '18 at 9:42

The first power of $$2$$ that begins with $$999$$ is $$2^{2621}$$. The number itself is $$789$$ digits long. Done with the following python script:

x,y=1,0
while 1:
if str(x)[:3]=="999":
print(x,y)
break
x,y=x*2,y+1

• Just for completeness: $2^{2621}\approx9991223\times10^{782}$ – Martin Rosenau Dec 28 '18 at 9:28

Let $$a = 2 ^ n$$ and $$b = 10 ^ m$$ and $$a .

Note: $$1024> 1000$$ that comes from $$128> 125$$.

The sequence of powers of 2 is: $$1,2,4,8,16,32,64,128,256, ...$$

Whose first digits are: $$1,2,4,8,1,3,6,1,2,5,1,2,4,8,1,3,6,1,2,5,1, ...$$

At the moment you do not see nines ...

And, in addition, it seems that the sequence is repeated every 10 positions with: $$1,2,4,8,1,3,6,1,2,5$$

But the reality is that that first one and the following digits grow slowly towards the next digit ...

And the 8 becomes 9 with $$2 ^ {53} = 2 ^ 3 \cdot 2 ^ {50} = 9,007,199,254,740,992$$

Everything mentioned above is related to the logarithm in base 10 of 2, which is: $$0.3010299956639811952...$$

And as you can see it is a real number (transcendent number) that is very close to $$3/10$$. Hence comes the "almost" repetition of ten digits mentioned above.

With these ingredients we can now propose the equation to solve to find a power number of two that starts with 999 when writing it in decimal:

$$2 ^ n = 10 ^ a \cdot b$$

$$b \in [0.999, 1); a, n \in N$$

Taking base 10 logarithms:

$$n * 0.3010299956639811952... = a + c$$

$$c \in [-0.00043451..., 0)$$

Which is easy to solve taking n as 100,000:

$$2 ^ {100,000} = 0.999002093 ... \cdot 10 ^ {30103} = 999.002093 ... \cdot 10 ^ {30100}$$