Find all nonnegative integers $x, y, z$ satisfying the equation $$2^x+31^y=z^2.$$
Problem
Source: 2018 Thailand October Camp 3.2
Tags: number theory, Diophantine equation
19.02.2022 15:30
If $x=0$, then $z^2=31^y+1$. Mod $3$ annihilates. If $x=1$, then $z^2=31^y+2$. Mod $5$ obliterates. Now consider $x\geq 2$. Then, mod $4$ yields $y$ is even, i.e. set $y=2a$. Hence, $$(z-31^a)(z+31^a)=2^x.$$Thus, $z-31^a=2^p$ and $z+31^a=2^q$, hence both together give equation $2^p+2\cdot 31^a=2^q$, notice that $p=1$, thus $2^{q-1}=31^a+1$. Now by Zsigmondy's theorem, only possibilities are $a=0,1$. Indeed, $a=0\implies q=2$, thus $\boxed{(x,y,z)=(3,0,3)}$, and $a=1\implies q=6$, thus $\boxed{(x,y,z)=(7,2,33)}$.
19.02.2022 15:38
To avoid using Zsigmondy's Theorem, Case 1: $x=0\implies (z-1)(z+1)=31^y$. Obviously, $z$ is even so $\gcd(z-1,z+1)=1$. If $y=0$ then $z=\sqrt{2}$ which is absurd. Thus, $y\geq 1$. We have $z-1=1,z+1=31^y$ since $z+1>z-1$. Absurd. Case 2: $x\geq 1$ Note that $x\neq 1$ since otherwise $z^2=2^1+31^y\equiv 3\pmod{5}$. Thus, $x\geq 2$. $z^2\equiv 2^x+31^y\equiv 0+(-1)^y\pmod{4}$ which mean $y$ must be even, otherwise $z^2\equiv 3\pmod{4}$. Let $y=2m$. If $m=0$ then $2^x=(z-1)(z+1)\implies z-1=2,z+1=2^{x-1}$ by consider $\gcd(z-1,z+1)$. $z=3\implies 2^{z-1}=3+1=2^2\implies x=3\implies(x,y,z)=(3,0,3)$. If $m\geq 1$ then $(z-31^m)(z+31^m)=2^x\implies z-31^m=2, z+31^m=2^{x-1}$ by consider $\gcd(z-31^m,z+31^m)$. $z-31^m=2\implies z+31^m=2+2\cdot 31^m\implies 1+31^m=2^{x-2}$. Obviously, $x\geq 4$. $4\mid 1+31^m\implies (-1)^m\equiv -1\pmod{4}\implies 2\nmid m\implies v_2(2^{x-2})=v_2(1+31^m)=v_2(1+31)=5$. $x-2=5\implies x=7\implies 31^m=2^{7-2}-1=31\implies m=1\implies y=2m=2, z= 31^m+2=33$. Thus, $(x,y,z)=(0,3,0),(7,2,33)$.
19.02.2022 19:43
The only solutions are $(x,y,z)=(3,0,3)$ and $(x,y,z)=(7,2,33)$. By taking $\pmod{3}$ we have that $x \equiv 1 \pmod{2}$, thus $x=2k+1$. First case: $x \geq 3$ By taking the equation $\pmod{4}$ we have that $2 | y$, thus $y=2t$, then we must have that: $$2^{2k+1}=(z-31^t)(z+31^t)$$thus we have that $z-31^t=2^a$ and $z+31^t=2^b$, where $a+b=2k+1$. Subtracting we have that: $$31^t=2^{b-1}-2^{a-1}$$from here we have that $a=1$, then by Zsgimondy we have that $t=0$ or $t=1$, which both generate a valid solution. Second case: $x=1$ By taking $\pmod{5}$ we have that $z^2 \equiv 3 \pmod{5}$, which isn't possible