9

Today my friend asked a question for help:

Find all solutions of $2^x=5^y+3$ for non-negative integers $x,y$.

It is obvious that the solutions are $(x,y)=(2,0),(3,1),(7,3)$, and I think there is no more solution. However, we can't prove that these are the only solutions. We have already tried to mod many numbers and still get "may" possible solutions other than the $3$ solutions I have written. I have surfed the Net and still can't find solutions. I hope you guys can help my friend solve. Thank you very much!

MafPrivate
  • 4,241
  • 15
  • 41
  • How are you sure these are the only solutions? Reduce the equation modulo $2$ and see what happens. – Allawonder Jan 01 '20 at 07:12
  • @Allawonder this problem is a contest math problem. It would not consist of big number solution. Also modulo 2 is no used dude XD – MafPrivate Jan 01 '20 at 07:36
  • Looking at it modulo powers of two is not going to help for five generates the subgroup of residue classes of the form $1+4k$ modulo $2^m$, for all $m$. On the other hand, for the same reason the congruence modulo $2^m$ determines $y$ uniquely modulo $2^{m-2}$ (given $x$), but this doesn't really rule out anything. Basically: given $x$ there is a 2-adic $y$ that solves the equation. I would guess looking at it modulo powers of five shows something similar: given $y$ there exists a 5-adic $x$. – Jyrki Lahtonen Jan 01 '20 at 07:36
  • 1
    The next likely candidate $$2^{20087}\approx5^{8651}+2^{20087}(\ln2)(5.11\times10^{-5})$$ isn't really very close... the numbers are growing exponentially as $2^x$ but the relative errors tend to only decrease as $1/x$. – user5713492 Jan 01 '20 at 08:20
  • 3
    Found in various AoPS forum topics according to Approach0 – Sil Jan 01 '20 at 08:45
  • 1
    @IsaacYIUMathStudio Well, that sounds reasonable enough. True, modding out by $2$ helps nothing. For what it may be worth, note that RHS is always of the form $1000k+628$ when $y>4.$ Also, we must have $x>y$ necessarily. – Allawonder Jan 01 '20 at 09:21
  • @Allowander: The RHS alternates between 1000k+628 and 1000k+128 – Moko19 Jan 01 '20 at 11:04
  • Using mod 1000, it can be seen that any additional solutions must be of the form $x=100k+7$. I'm not sure how to prove that no such solutions exist, but I can't find any others either – Moko19 Jan 01 '20 at 11:06
  • @JyrkiLahtonen got it. Big primes involved. – Will Jagy Jan 01 '20 at 18:13
  • Not too much modular arithmetic required; show that $x=8u+7$ and $y=4v+3$ for any solution other than the two smallest ones. Then rearranging as in Will Jagy's answer yields $$128(256^u-1)=125(625^v-1).$$ Reducing mod $257$ and distinguishing cases for $u$ odd and even yields $u=0$ as the only option. (When $u$ is even you will find $v\equiv0\pmod{64}$, then reducing mod $256$ shows that $u=0$.) – Servaes Jan 13 '20 at 21:30

5 Answers5

8

We start by changing the letters, plugging in your maximal exponents, and arriving at $$ 128 (2^x - 1) = 125 (5^y-1) \; . \; $$ We ASSUME that both $x,y \geq 1$ and get a contradiction. The main tasks are factoring $p^n - 1$ and finding the order of a prime for some target $n,$ the minimal $k$ such that $p^k \equiv 1 \pmod k$

So, order 2 modulo 125 is 100 (a brief explanation of this calculation: we have simply $\varphi(125) = 100$, so the order 2 modulo 125 must be a divisor of 100, i.e., 1, 2, 4, 5, 10, 20, 25, 50, 100. Checking through all of these divisors we find only $2^{100} \equiv 1 \pmod {125}$). Thus $100 \mid x$.

Next $$ 2^{100} - 1 = 3 \cdot 5^3 \cdot 11 \cdot 31 \cdot 41 \cdot 101 \cdot 251 \cdot 601 \cdot 1801 \cdot 4051 \cdot 8101 \cdot 268501 $$ We need $5^y \equiv 1 \pmod {268501}$. Calculating the order of 5 modulo 268501, we can see it is 134250. So $134250|y$. Therefore $125 | y$. $$ 5^{125} - 1 = 2^2 \cdot 11 \cdot 71 \cdot 101 \cdot 251 \cdot 401 \cdot 3597751 \cdot 9384251 \cdot \mbox{BIG} $$ We need $2^x \equiv 1 \pmod { 9384251}$. We can calculate the order 2 modulo 9384251, which is 9384250. So $9384250|x$. Therefore $125 | x$. From the beginning, we have had $100 \mid x$. Put them together, Chinese Remainder Theorem, and we arrive at $$ 500 \mid x $$

And $$ 2^{500}-1 = (2^{100}-1)(2^{400}+2^{300}+2^{200}+2^{100}+1)$$ where $2^{100}-1$ is a multiple of $5^3$ (above) and the second factor is a multiple of $5$ because $2^{100}=16^{25}\equiv 1\bmod 5$. Thus $2^{500} - 1$ is a multiple of $5^4.$ We have gotten what we wanted, as
$ 128 (2^x - 1) = 125 (5^y-1) \; \; $ tells us that $ 125 (5^y-1)$ is divisible by $625$. In turn, this says that $ (5^y-1)$ is divisible by $5$. This is impossible with $y \geq 1$, so that $y = 0$, contradicting our hypothesis.


factor with gp-pari 

parisize = 4000000, primelimit = 500000 ? factor( 2^100 -1) %1 = [ 3 1]

[ 5 3]

[ 11 1]

[ 31 1]

[ 41 1]

[ 101 1]

[ 251 1]

[ 601 1]

[ 1801 1]

[ 4051 1]

[ 8101 1]

[268501 1]

? factor( 5^125 -1) %2 = [ 2 2]

[ 11 1]

[ 71 1]

[ 101 1]

[ 251 1]

[ 401 1]

[ 3597751 1]

[ 9384251 1]

[ 28707251 1]

[ 4032808198751 1]

[ 767186663625251 1]

[24687045214139234043375683501 1]

? factor( 2^500 -1) %3 = [ 3 1]

[ 5 4]

[ 11 1]

[ 31 1]

[ 41 1]

[ 101 1]

[ 251 1]

[ 601 1]

[ 1801 1]

[ 4051 1]

[ 7001 1]

[ 8101 1]

[ 28001 1]

[ 96001 1]

[ 268501 1]

[ 3775501 1]

[ 229668251 1]

[ 269089806001 1]

[ 4710883168879506001 1]

[ 47970133603445383501 1][+++] ?


Will Jagy
  • 147,694
  • We do not need to factor $2^{500}-1$ completely. Simply render $a^5-1=(a-1)(a^4+a^3+a^2+a+1)$ where $a=2^{100}$. We already have $a\equiv 1\bmod 5$ for this $a$, forcing the quartic factor to impart the additional factor of $5$ that tumbles the edifice. – Oscar Lanzi Jan 01 '20 at 19:58
  • 1
    @OscarLanzi that sounds good; consider posting that as an answer, I cant say I have ever looked carefully about what simplifications might be available, better explanations,... – Will Jagy Jan 01 '20 at 20:14
  • 1
    Instead I edit your answer. – Oscar Lanzi Jan 01 '20 at 20:14
  • I like your answer with computation, but is there any way to solve this problem without computation? As it used to calculate factorization of big numbers – MafPrivate Jan 02 '20 at 09:20
  • @IsaacYIUMathStudio You are welcome to find other approaches. As to your complaint, suggest you carefully read the answer by Gyumin Roh at http://math.stackexchange.com/questions/1551324/exponential-diophantine-equation-7y-2-3x After that, some of the early ones (links in the second answer) use small numbers. – Will Jagy Jan 02 '20 at 15:39
4

In case anyone wants to learn what is going on in the solution, here are my earlier examples and the person who discovered the method (answer at the first link):

http://math.stackexchange.com/questions/1551324/exponential-diophantine-equation-7y-2-3x

http://math.stackexchange.com/questions/1941354/elementary-solution-of-exponential-diophantine-equation-2x-3y-7

http://math.stackexchange.com/questions/1941354/elementary-solution-of-exponential-diophantine-equation-2x-3y-7/1942409#1942409

http://math.stackexchange.com/questions/1946621/finding-solutions-to-the-diophantine-equation-7a-3b100/1946810#1946810

http://math.stackexchange.com/questions/2100780/is-2m-1-ever-a-power-of-3-for-m-3/2100847#2100847

The diophantine equation $5\times 2^{x-4}=3^y-1$

Equation in integers $7^x-3^y=4$

Solve in $\mathbb N^{2}$ the following equation : $5^{2x}-3\cdot2^{2y}+5^{x}2^{y-1}-2^{y-1}-2\cdot5^{x}+1=0$

Solve Diophantine equation: $2^x=5^y+3$ for non-negative integers $x,y$.

Will Jagy
  • 147,694
  • Hi Will, have a nice new year! This would be a good (initializing) list for a tag exponential-diophantine-equations which I'd liked to exist since long. But the community doesn't like to have bounces to frontpage by editing tags, doesn't it? – Gottfried Helms Jan 02 '20 at 06:31
  • @GottfriedHelms I suppose they would not like putting a tag on 25 questions in ten minutes. Should be alright if spread out a bit. Also, a tag needs some explanatory text, indicating some things it is about and some things it is not about. Either one of us can do that. – Will Jagy Jan 02 '20 at 15:33
  • Will - just introduced the tag. Tagged 3 questions (the OP and first two of your list)- enough for one day... – Gottfried Helms Jan 03 '20 at 07:52
0

From WolframAlpha here we get

$$x = \frac{\log{5^y + 3}}{\log{2}}\quad\text{for}\quad 5^y\in\mathbb{Z}\quad\land\quad5^y >=-2$$ The restrictions are overkill but simply indicate $y\in\mathbb{Z}$

Applying this in a spreadsheet for $-15000\le y \le 15000$ we get only $3$ pairs.

$$(2,0)\quad (3,1)\quad (7,3)\quad$$

poetasis
  • 7,045
0

My credit is not sufficient so as to comment the earlier answer provided by Will Jagy and further edited by Oscar Lanzi. Rather, I've found a minor simplification of their computation. That is, instead of concluding $125|y$, we only need to reach $25|y$. We factor $2^{100}-1$ into primes and know it has a prime factor $101$. Then we need $5^y \equiv 1 \pmod {101}$. We calculate the order of 5 modulo 101, and it is $25$.

We factor $5^{25}-1$, $$ 5^{25}-1 = 2^2 \cdot 11 \cdot 71 \cdot 101 \cdot 251 \cdot 401 \cdot 9384251 .$$

Here we have already got the prime factor $9384251$ that we need! The rest is the same as the answer of Will Jagy and Oscar Lanzi above. That is, we find the order of 2 modulo $9384251$ to be $9384250$ thus conclude $125|x$, putting already obtained conclusion $100|x$ together, we know $500|x$. Now LHS is divisible by 625 but RHS divisible by 125 only. Contradiction.

  • Following the same idea, we can prove with contradiction, with much less computation.

    We start with $$128(2^x−1)=125(5^y−1),$$ where $x,y≥1 $.

    We know Eular totient function $\phi(128)=64$, so the order of 5 modulo 128 is the factor of 64. It is indeed 32, i.e., $5^{32} \equiv 1 \pmod {128}$.

    – JXCantab Sep 13 '25 at 21:16
-1

Following the same idea, we can prove with contradiction, with much less computation.

We start with $$128(2^x−1)=125(5^y−1),$$ where $x,y≥1 $.

We know Euler totient function $\phi(128)=64$, so the order of 5 modulo 128 is some factor of 64. It is indeed 32, i.e., $5^{32} \equiv 1 \pmod {128}$. Therefore $32|y$, so $16|y$. We must have factor $(5^{16}-1)$ on the right hand side. Now we factor $(5^{16}-1)$ into primes we shall get a prime factor $11489$. Here we can do the factorisation without Python coding: we know $5^{16} \equiv 1 \pmod {17}$ by Fermat's Little Theorem. That means $17|(5^{16}-1)$. However, we know $17 \nmid (5^8-1)$, so $17 | (5^8+1)$. With this knowledge we reach $5^8+1=2 \cdot 17 \cdot 11489$ with ease. It is not hard to check that $11489$ is a prime. So the left hand site must contains this prime factor, i.e., $11489|(2^x-1)$. The order of 2 modulo 11489 is a factor of 11488. And another small computation tells us this order is $5744$ ($5744$ is half of $11488$ actually), i.e., $2^{5744} \equiv 1 \pmod {11489}$. Therefor $5744|x$. $5744=2^4 \cdot 359$, so $16|x$. LHS contains factor $(2^{16}-1)$. Factor $(2^{16}-1)$ into primes, we shall see a prime factor $257$ (in fact $2^8+1=257$). The order of 5 modulo 257 is 256 (this means $5$ is a primitive root of $257$), i.e., $5^{256} \equiv 1 \pmod {257}$. Hence the RHS must contain factor $5^{256}-1=(5^{128}+1)(5^{64}+1)(5^{32}+1)(5^{16}+1)(5^8+1)(5^4+1)(5^2+1)(5+1)(5-1)$. It is easy to spot from this factorisation that $2^{10}|(5^{256}-1)$. The RHS now can be divided by $2^{10}$ at least, whilst the LHS is only divisible by $2^7$. We have got a contradiction.

This method is different from the one provided above by Will Jagy, by focusing another side of the equation to investigate it, and thus need much less computation.