2

Is there any solution to the equation

$$ p^k = 2^n \pm 1 $$

with prime $p > 3$ and natural number $k > 1$?

For $p=3$, is there any solution except the trivial case $3^2 = 2^3 + 1$?

What I did: Look into wikipedia and google on Mersenne primes (half of the $k=1$ case), and Prime powers, and went into the rabbit hole for both terms, but found nothing helping me out.

Links to dupes: (a) $2^n+1$ case, (b) $2^n-1$ case

Note: I'm asking the question on behalf of a retired family friend without internet, who came up with this question. I myself with 1yr of uni-level math ages ago were not able to find any prior work here nor was able to solve this question myself -- there must be thousands of such questions, and this may be trivial or very hard, I cannot judge properly.

Jeroen
  • 21
  • 7
    The Catalan conjecture, now the theorem of Preda V. Mihăilescu, tells us that $8,9$ are the only consecutive perfect powers. – lulu Jul 07 '23 at 18:28
  • Thanks, if I understand correctly, this is the actual answer? <sorry didn't realize saved>

    So if you supply this as an answer, I"ll mark it as such. I'll do the 'exercise for the reader' myself (that is, I'll add it as a comment for any future readers).

    – Jeroen Jul 07 '23 at 18:32
  • For $k=1$, the plus sign gives Fermat primes (where $n$ must be a power of $2$), while the minus sign gives Mersenne primes (where $n$ must also be prime). – Geoffrey Trang Jul 07 '23 at 18:40
  • @GeoffreyTrang No...because the question asks about $p^k$ as values, for $k>1$. – lulu Jul 07 '23 at 18:40
  • @Jeroen Yes, this is the entire answer. Any example of what you want would be a pair of consecutive powers. Of course, the Catalan conjecture is far more sweeping, and perhaps there is an easier proof in this particular case. Perfectly possible this is an example of "killing a mosquito with an atom bomb" If so, hopefully, someone will supply a more direct proof for the special case (or point to it). – lulu Jul 07 '23 at 18:42
  • I am fully satisfied with the pointer to Mihăilescu's theorem, so I'm grateful for the pointer. Of course, if someone feels like answering this question via different means, you are very welcome, but my (and my family-friend's) curiosity to the answer is satisfied. I'm now typing a self-answer for the benefit of others. – Jeroen Jul 07 '23 at 18:46
  • And here is one on this site where asker seems to prove $2^n=p^q+1$ is impossible by elementary means + xarles's answer proves $2^n=p^q-1$ also by elementary means. – Sil Jul 07 '23 at 18:52
  • [meta] There this second suggested duplicate answer, and I have erroneously marked that as 'nope, not answering my question'. I don't see how to undo that, if you can re-suggest that reference I'll now click yes. – Jeroen Jul 07 '23 at 19:43
  • It still is linked through mentioning it so it's fine. I guess my previous comment might have been confusing, what I meant is that the linked post actually proves both cases $2^n=p^q \pm 1$, it's just they are in different parts of that link – Sil Jul 07 '23 at 20:22

2 Answers2

0

Self-answer, but entirely thanks to @lulu:

The Catalan conjecture, now the theorem of Preda V. Mihăilescu, tells us that 8,9 are the only consecutive perfect powers.

The question looks for a $p^k$ and $2^n$ that differ by one, and the theorem linked above proves that for $k,n>1$ only the already mentioned case for $k=3$ is possible. Beyond that, only the trivial case $n=1$ remains, for which there is no solution $k>1$.

Jeroen
  • 21
0

My answer from deleted question. I found the method at

Exponential Diophantine equation $7^y + 2 = 3^x$ by Gyumin Roh in 2015

$$ \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc $$

Let us start with the easy case. We believe the biggest integer solution to $ 3^u +1 = 2^v $ is $3+1 = 4,$ or $u=1,v=2.$ Begin with the $ 3^u +1 = 2^v $ and subtract $4$ from both sides, reaching $$3^u - 3 = 2^v - 4$$ with $u,v >0$ so $v \geq 2.$ Thus $$ 3(3^x -1) = 4 (2^y - 1) $$ where $x=u-1, y= v-2.$ We get equality if both $x,y$ are zero, and we think those are the biggest $x,y$ values that work.

Next, assume we have a solution with both $x,y > 0.$ This one is quick: since $4|(3^x - 1)$ we see that $x$ must be even. However, as soon as $x$ is even we find $3^x \equiv 1 \pmod 8$ and $8|(3^x - 1).$ This gives a contradiciton since $8 | 4(2^y - 1),$ then $2| 2^y - 1,$ contradicting the assumption that $y \neq 0$

$$ \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc $$

This case is more work:

We have $$ 3^u = 2^v + 1. $$ Subtract $9$ from both sides, we have $$ 3^u - 9 = 2^v - 8. $$ Taking $u = x + 2$ and $v = 3 + y$ gives $9 \cdot 3^x - 9 = 8 \cdot 2^y - 8,$ or $$ 9 (3^x - 1 ) = 8 (2^y - 1). $$ We think this is only possible with $x=y=0,$ so we assume there is a solution with $x,y > 0$ and get a contradiction.

First we have $9 |(2^y - 1),$ or $$ 2^y \equiv 1 \pmod 9.$$ This tells us that $ 6 | y. $ Meanwhile $$ 2^6 - 1 = 63 = 3^2 \cdot 7. $$ Therefore $7 | (3^x - 1).$ In turn, we find $6 | x.$

Next $$ 3^6 - 1 = 728 = 2^3 \cdot 7 \cdot 13. $$ Therefore $13 | (2^y - 1).$ In turn, we find $12 | y.$

Next $$ 2^{12} - 1 = 4095 = 3^2 \cdot 5 \cdot 7 \cdot 13. $$ Therefore $5 | (3^x - 1).$ In turn, we find $4 | x.$

Finally, $3^x - 1$ is divisible by $3^4 - 1 = 80.$ In particular, $3^x - 1$ is divisible by $2^4 = 16.$ However, this contradicts $2^y - 1 \neq 0$ and $y > 0.$ $$ \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc \bigcirc $$

Will Jagy
  • 146,052