Find all positive integer solutions $(x,y,z)$ that satisfy $5^x \cdot 7^y +4= 3^z$? This is another contest math-problem.
The only problem that I cannot find the way to tackle this problem. 
Can anybody try to provide the solution to solve this problem?
Thanks
 A: Since $x,y,z \in \mathbb{N}$ we get that $5|5^x7^y$, so we have: $3^z \equiv 4 \mod 5$. Since $ord_5(3) = 4$ and $3^2 \equiv 4 \pmod 5$ we get $\fbox{$z = 4n + 2$}$. Obviously $z$ is even so we have $\fbox{$z=2k$}$. Then we have:
$$5^x7^y = 3^{2k} - 4 = (3^k - 4)(3^k + 4)$$
Now let $d = (3^k - 4,3^k + 4)$, then $d$ divides their diference, so $d\mid 8$. But both numbers are obviously odd, hence $(3^k - 4,3^k + 4) = 1$. Since we have 2 different prime factors on the left side we have $4$ cases:
Case 1:
\begin{cases} 3^k - 4 = 5^x \\ 3^k + 4 = 7^y \end{cases} 
Working wrt modulo 5 and 7 respectively we get $k=4n + 2$ and $k=6n + 1$, an obvious contradiction.
Case 2:
\begin{cases} 3^k + 4 = 5^x \\ 3^k - 4 = 7^y \end{cases}
Working modulo $3$ we get: $5^x \equiv 2^x \equiv 1 \pmod 3 \implies \fbox{$x=2m$}$
So we get: $3^k = (5^m - 2)(5^m + 2)$. As previously we get that the two factors on the right side are comprime. Since $5^m + 2 > 1$ we get that the only possibilty is:
\begin{cases} 5^m - 2 = 1 \\ 5^m + 2 = 3^k \end{cases}
For the first equation we have: $5^m = 3$ a contradiction.
Case 3:
\begin{cases} 3^k + 4 = 1 \\ 3^k - 4 = 5^x7^y \end{cases} 
An obvious contradiction for the first equation.
Case 4:
\begin{cases} 3^k + 4 = 5^x7^y \\ 3^k - 4 = 1 \end{cases}
From the second equation we get $3^k = 5$ a contradiction, because $k \in \mathbb{N}$ 
Hence this equation doesn't have a solution in $\mathbb{N}$
A: Considering the equation modulo $5$ shows that $z = 2+4m$ for some integer $m$. Considering the equation modulo $7$ shows that $z = 4 + 6n$ for some integer $n$. Thus we have $2 + 4m = 4 + 6n$. This is a linear Diophantine equation, and the solutions to the original equation may be found by first solving this.
Edit: I seem to have overlooked the fact that the linear diophantine equation reads $2m - 3n = 1$. Because of the negative sign, there are infinitely many positive solutions and thus this attack method does not seem to help.
A: Given; $5^x \cdot 7^y +4= 3^z$ 
we get, $(-1)^x +1 \equiv 0 \pmod3$ hence $x$ must be odd, again, $(-1)^y \equiv (-1)^z \pmod 4$ hence $y$ and $z$ have the same parity.  Again $-1 \equiv 3^z \pmod 5$ or $1 \equiv 3^{2z} \pmod 5$ hence by Euler-Fermat theorem $2|z$. Again since $y$ and $z$ are even we have, $5^x \equiv 4 \pmod 8$, since $x$ is odd, we have two cases; either $x=4k+1$ or $x=4k+3$, note that $5^{4k} \equiv 1 \pmod 8$, the two cases each yield $5^x \equiv 5 \pmod 8$ a contradiction, hence $x$ cannot be greater than $0$, i.e $x=0$. The given equation then becomes $7^{2m} +4= 3^{2n}$ or $(7^m)^2 +2^2= (3^n)^2$, a pythagora's equation with solution, $2=2uv$, $7^m=u^2-v^2$ and $3^n=u^2+v^2$ from which it is obvious that $m$ and $n$ do not exist, and hence, $y(=2m)$ and $z(=2n)$ do not exist
