Finding solutions to $2^x+17=y^2$

1.2k Views Asked by At

Find all positive integer solutions $(x,y)$ of the following equation: $$2^x+17=y^2.$$

If $x = 2k$, then we can rewrite the equation as $(y - 2^k)(y + 2^k) = 17$, so the factors must be $1$ and $17$, and we must have $x = 6, y = 9$.

However, this approach doesn't work when $x$ is odd.

6

There are 6 best solutions below

1
On BEST ANSWER

The only solutions are $x = 3, 5, 6, 9$. This is proved on pp. 148-152 of

Tzanakis, N. (1983), On the diophantine equation $y^2-D = 2^k$, J. Number Theory 17, 144-64.

5
On

I think that there are not solutions for $x$ odd.

Indeed,

$y^2=2^x+17=2^{2k+1}+17=2 \cdot 4^k +17 \equiv 2+17 \equiv3 \mod4$, which cannot happen.

(If $x$ is of the form $x=2k$, then the equation can be easily written $(y-2^k)(y+2^k)=17$, and so we go on).

EDIT: Wrong solution!

0
On

$x=3,5,9$ work with $y=5,7,23$ but fail nor $x=1,7$. If $x $ works for any other value then $x>4$.

$2^x+17=y^2$

$2^4 (2^{x-4}+1)=y^2-1=(y+1)(y-1) $

$y\pm 1$ must be even and $\gcd(x+1,x-1)=2$ and one is a multiple of $4$ while the other isn't.

That means::

$y\pm 1=8m;y\mp 1=2n;mn=2^{x-4}+1$

Also means

$2^x+8=y^2-9$

$2^3 (2^{x-3}+1)=(y-3)(y+3) $

So $y\mp 3 =4k=2n\mp 2;y\pm 3=2j=8m\pm 2;jk=2^{x-3}+1$

We have strict limitation here it seems. In that $m,n $ are relatively close to $j,k $ but their product is about half.

I'm too lazy to work out the details but there must be an upper limit to that being possible.

Also $2^x-8=2^3 (2^{x-3}-1)=y^2-25=(y-5)(y+5) $ and so $y\pm 2 =4r;y\mp 2=2s;rs=jk-2$

So.... it's a mess but we have clear limits.

I strongly suspect $x=9$ is the highest possible $x $.

Oh, and we have $2^x+1=(y-4)(y+4)\approx 16mn $.

0
On

A largely complete answer:

Starting from $2^x+17=y^2$, we obtain $2^x+2^4=(y-1)(y+1)$. By observation, $x=4$ fails as $33\ne y^2$. Note that $(y-1),(y+1)$ are two consecutive even numbers, so their difference is $2$, and one of them contains a single factor of $2$ while the other contains more than one factor of $2$.

Case 1, $x<4 \Rightarrow x=1,2,3$: Hence, $2^x+2^4=18,20,24$. Of these, only $24=4\times 6$ is the product of two consecutive even numbers. This corresponds to $x=3$.

Case 2, $x>4$: $16(2^{x-4}+1)=(y-1)(y+1)$. We see $(2^{x-4}+1)$ is an odd number, which we can factor as $ab$, where both $a,b$ are odd integers $\ge 1$. It must be the case that $(y-1)(y+1)=8a\cdot 2b$ where $8a-2b=\pm 2$, or $4a-b=\pm 1 \Rightarrow b=4a\pm 1$ and $(2^{x-4}+1)=ab=4a^2\pm a$

For $a=1$ we get $4a^2\pm a=3,5$ corresponding to $2^1+1$ and $2^2+1$, whence $x-4=1,2 \Rightarrow x=5,6$

For $a=3$ we get $4a^2\pm a=33,39$. Of these, $33=2^5+1 \Rightarrow x-4=5 \Rightarrow x=9$

I note that for $x\ge 9 \Rightarrow x-4 \ge 5$ it is the case that $(2^{x-4}+1) \equiv 1 \bmod 32$ and $a$ being odd means $a^2 \equiv 1 \bmod 8 \Rightarrow 4a^2 \equiv 4 \bmod 32$. Thus $(2^{x-4}+1)=4a^2\pm a \Rightarrow 4 \pm a \equiv 1 \bmod 32$, or $a\equiv \pm 3 \bmod 32$. Looking at the first $200$ members of $\{3,29,35,61,67,\dots\}$ I find no further suitable values of $a$

For larger $a$, I have not found a proof that none exist. If I find such a proof, I will update this answer.

0
On

It looks like I need to spell out the details for insipidintegrator.

If $x$ is even, the prime $17$ is the product of $y+2^{x/2}$ and $y-2^{x/2}.$ Averaging, we find $y=9$ whence $x=6.$

If $x$ is odd, write $y-2^{x/2}=\frac{17}{y+2^{x/2}}$. Letting $x=2n+1$, we have $\Big|\frac{y}{2^n}-\sqrt{2}\Big|=\frac{17}{2^n(y+2^{n+.5})}.$
From Beuker's thesis, If $q=2^k, \ \Big|\frac{p}{q}-\sqrt{2}\Big|>2^{-43.9}q^{-1.8}$ Thus $\Big|p-q\sqrt{2}\Big|>2^{-43.9}q^{.2}$ In our case, $p=y,q=2^n$ so $p+q\sqrt{2}>2q\sqrt{2}.$ Multiplying, $$17=y^2-2^x>2^{-43.9}q^{.2}\cdot 2q\sqrt{2}$$ or $$q^{1.2}<17\cdot2^{42.4}$$ and $$n<38.73955$$ A computer check shows the only solutions are $n=1,2,4.$ These values correspond to $x=3,5,9.$

0
On

If you have a computer and some luck, you can solve the problem "When will $a^n+b$ become a square number?". $a$ need not be prime.

Srinivasa Ramanujan said,

"The natural number solution of $2^n-7=m^2$ is only $(m, n) = (1, 3), (3, 4), (5, 5), (11, 7), (181, 15)$’’.

This was proved by Thoralf Skolem in 1959 and is known as the Ramanujan-Skolem theorem. We can also prove Ramanujan-Skolem theorem in the following way.

Let’s prove $2^z+17=x^2$ has only natural number solutions $(x,z)=(5,3), (7,5), (9,6), (23,9)$.

It's easy when $z$ is even. When $z$ is an odd number, just solve $x^2-2y^2=17$. Algorithms based on quadratic field theory are known, and all possible integer $y$ are represented by the sequence of integers $k$ $$y_k=\pm\{(4+5\sqrt{2})(3+2\sqrt{2})^k+(4-5\sqrt{2})(3-2\sqrt{2})^k\}/4.$$

Focusing on the maximum number of times $y_k$ is divisible by $2$, I calculated it with a software called "Maxima": $$k≡1 \bmod 2 \Leftrightarrow y_k\equiv0\bmod 4$$ $$k≡1 \bmod 4 \Leftrightarrow y_k\equiv0\bmod 8$$ $$k≡1 \bmod 8 \Leftrightarrow y_k\equiv0\bmod 16$$ $$k≡9 \bmod 16 \Leftrightarrow y_k\equiv0\bmod 32$$ $$k≡25 \bmod 32 \Leftrightarrow y_k\equiv0\bmod 64$$ $$k≡25 \bmod 64 \Leftrightarrow y_k\equiv0\bmod 128$$ $$\cdots$$ $$k≡25 \bmod 1024\Leftrightarrow y_k\equiv0\bmod 2048$$ $$k≡1049\bmod2048\Leftrightarrow y_k\equiv0\bmod4096...(*)$$ $$k≡3097 \bmod 4096 \Leftrightarrow y_k\equiv0\bmod 8192$$ $$\cdots$$ As you can see, there is a structure in which a term that is divisible by a power of 2 always appears at intervals of powers of 2. Introduced in $p$-adic structure of Pell-type equations about this mechanism

(*) is used. Since $y_k$ satisfies the recurrence formula between adjacent triplets $y_{k+1}=6y_k-y_{k-1}$, $$y_{-999}\equiv y_{1049}\equiv0\bmod4096,\ y_{-1000}\equiv y_{1048}\equiv\pm3538\bmod4096$$ From this, we can see that the remainder modulo 4096 has a period of 2048, and we can confirm with a computer that all the remaining 2046 terms from $y_{-998}$ to $y_{1047}$ are not divisible by 4096. If you want to prove this result without using a calculator, you can use "$p$-adic log", which is discussed in the above URL, to actually show it by hand calculation, and you can also make a more sophisticated proof.

Now, although it is abrupt, for the Fermat prime $p = 2^{16} + 1 = 65537$, in the same order of symbols, $$y_{1049}\equiv\pm17588\bmod p,\ y_{-999}\equiv y_{3097}\equiv\pm(-17588)\bmod p,$$ $$y_{1048}\equiv\pm21502\bmod p,\ y_{-1000}\equiv y_{3096}\equiv\pm(-21502)\bmod p$$

This looks like a "coincidence". Since $y_k\bmod p$ has a period of 4096, $y_k\bmod p$ must be either $17588$ or $-17588$ for $k$ that satisfies $k\equiv1049\bmod2048$.

$2^{16}\equiv-1\bmod p$, so if $y_k$ is a power of 2, it should be $y_k^{16}\equiv\pm1\bmod p$. But since $y_k^{16}\equiv(\pm17588)^{16}\equiv 42987\bmod p$, $y_k$ is never a power of 2 and a multiple of 4096 .

Finally, how to discover the above "coincidence"?

In general, the solution of the trinomial recurrence is $$y_k=\alpha(A+B\sqrt{s})^k+\beta(A-B\sqrt{s})^k$$

If you want a prime $p$ such that $y_k\bmod p$ has period $N$, calculate $$(A+B\sqrt{s})^N-1=C+D\sqrt{s}$$ and find the prime factors of $\gcd(C,D)$ that look good.