What is the general solution of this equation :$2^x 3^y+1=7^z$ with $x, y , z$ are integers? I have got these triplet solution  $(x,y,z)=(1,1,1),(4,1,2)$ for this equation:

$$2^x 3^y+1=7^z$$ 

with  $x, y , z$ are integers, But i can't get general solution of it, I have attempted to use Gausse theorem for the solution of $ ax+by= c $, with $a, b, c$ are integers but my problem i can't transfer the titled equation to that of Gausse as a linear form, any way ?
 A: Clearly $z>0$, since $2^x3^y+1>1$, so $7^z-1\in \mathbb{Z}$ so $x,y\in  \mathbb{N}$.
If $y\geq 2$ then $1\equiv _9 7^z$. Since ord$_9(7) = 3$ we have $3\mid z$ so $z=3t$.
Now we can write: $$2^x3^y = (7^3-1)\Big((7^3)^{t-1}+\ldots+7^3+1\Big)$$
Since $7^3-1 = 19\cdot 9\cdot 2$ we see this is impossible, so $y\leq 1$ or $y=1$. 
Can you finish?

Added:
Now we have: $$2^{x-1} = 7^{z-1}+\ldots+7^2+7+1$$
Say $x>1$, then $z$ is even so $z=2s$ and $$2^x3 = (7^s-1)(7^s+1)$$ 
Since factors on right differ for $2$ at most one is divisible by $4$.  


*

*$7^s-1 = 1$ and $7^s+1 = 2^{x}3$...

*$7^s-1 = 2$ and $7^s+1 = 2^{x-1}3$...

*$7^s-1 = 3$ and $7^s+1 = 2^{x}$...

*$7^s-1 = 6$ and $7^s+1 = 2^{x-1}$...

*$7^s+1 = 1$ and $7^s-1 = 2^{x}3$...

*$7^s+1 = 2$ and $7^s-1 = 2^{x-1}3$...

*$7^s+1 = 3$ and $7^s-1 = 2^{x}$...

*$7^s+1 = 6$ and $7^s-1 = 2^{x-1}$...

A: This adds to Aqua's solution. There is actually a direct way to show the following:

Thm 1: For all $x\ \ge 6$ and all $k$ satisfying $7^k \equiv_{2^x} 1$, the inequality $7^k > 3 \times 2^x$ holds.

Prof of Thm 1: Let $(k,x)$ be a minimum-maximum pair satisfying
$$7^{k} \equiv_{2^x} 1$$
e.g., given $x$, the integer $k$ is the smallest positive integer that satisfies the above, and given $k$, the integer $x$ is the largest that satisfies the above. Then if we can show that $7^k > 3 \times 2^x$ for all minimum-maximum pairs $(k,x); x \ge 6$ then we are done. In particular, if we can show, for all integers $x \ge 6$, that there is an integer $k$ s.t. $(k,x)$ is a minimum-maximum pair, and that the inequality  $7^k > 3 \times 2^x$ holds for such $k$, then we are done.
Now, for $x=6$ note that $(8,6)$ is a minimum-maximum pair
and $7^8 > 3 \times 2^6$. We use induction on $x$.  Letting $k$ be such that $(k,x)$ is a minimum-maximum pair,we assume that $7^k > 3 \times 2^x$. Then letting  $k''$ be such that $k''$ such that $(k'',x+1)$ is a maximum-minimum pair, we show that $7^{k''} > 3 \times 2^{x+1}$ i.e., we show that the strict inequality $k''>k$ holds, and then Thm 1 will follow.
As $(\mathbb{Z}/2^{x'}\mathbb{Z})^{\times}$ is a group of order $2^{x'-1}$ for each positive integer $x'$ and $7 \not \equiv_{2^{x'}} \pm 1$ for each integer $x' \ge 6$, it follows that $k$ is a power of 2 at least 4. It also follows that $7^{k'} \not \equiv_{2^{x}} 1$, and in particular $7^{k'} \not \equiv_{2^{x+1}} 1$, for all integers $k' \in \{k,k+1, \ldots, 2k-1\}$. Indeed, if this were so then the equation $7^{k'-k} \equiv_{2^x} 1$ would hold with $k'-k< k$ which is a contradiction. Meanwhile we also claim that $7^{2k} \not  \equiv_{2^{x+2}} 1$. Indeed $7^k=1+a2^x$ for some $a$ odd.
Thus, if $(k,x)$ is a minimum-maximum pair then $(k'',x+1)$, where $k''=2k$ is also a minimum-maximum pair and clearly $7^{k''}=7^{2k} > 3 \times 2^{x+1}$ if $7^k > 3 \times 2^x$ and $k \ge 4$.
So Thm 1 follows. $\surd$
Thm 1 plus Aqua's solution for $y \ge 2$ plus checking a few small cases gives the desired result.
A: As Aqua notes, we must have $z\gt0$, so let's write $z=c+1$. Then
$$2^x3^y=7^{c+1}-1=(7-1)(1+7+7^2+\cdots+7^c)$$
It follows that $x,y\gt0$ as well, so let's write $x=a+1$ and $y=b+1$. We now have
$$2^a3^b=1+7+7^2+\cdots+7^c$$
If $b\gt0$, then, since $7\equiv1$ mod $3$, the number of terms on the right hand side must be a multiple of $3$, in which case we have
$$1+7+7^2+\cdots+7^c=(1+7+7^2)(1+7^3+7^6+\cdots+7^{3k})$$
for some $k\ge0$. But $1+7+7^2=57=3\cdot19$, and $19$ is not divisible by $2$ or $3$.  So we must have $b=0$.
If $a=0$, we have the solution $(x,y,z)=(1,1,1)$. If $a\gt0$, we must have an even number of terms in $1+7+7^2+\cdots+7^c$, so that
$$1+7+7^2+\cdots+7^c=(1+7)(1+7^2+7^4+\cdots+7^{2k})$$
for some $k\ge0$. Thus $a\gt0$ implies $a=3+a'$ for some $a'\ge0$, with $2^{a'}=1+7^2+7^4+\cdot+7^{2k}$. Now if $a'\gt0$, we must have an even number of terms in $1+7^2+7^4+\cdots+7^{2k}$, in which case we have
$$1+7^2+7^4+\cdots+7^{2k}=(1+7^2)(1+7^4+7^8+\cdots+7^{4k'})$$
for some $k'\ge0$. But $1+7^2=50=2\cdot5^2$ is not a power of $2$. So we must have $a'=0$, and this leaves $(x,y,z)=(4,1,2)$ as the only other solution.
Remark: The prime $19$ plays the same role here as it does in Aqua's answer, but it is obtained in a somewhat different manner (with a mod $3$ argument rather than a mod $9$ observation). The approach here can be modified to solve the equation $2^x3^y5^z+1=31^w$.
