TITLE: Find $x$ such that $12+13^x$ be a perfect square
QUESTION [9 upvotes]: Find $x \in N$ such that $12+13^x$ be a perfect square
I am going to limit  $k < 12 + 13^x < k+i$ so that I can have $t<x<t+u$, I don't know how to do it, if $x=2k$, it pretty easy but x can also equal $2k +1$ too. So... Stuck here
Update 2:
I can prove that $x$ can't be $2k$, if so, x = 2k $(k \in \mathbb{N})$ then
$13^{2k}<12+13^x = 12 + 13^{2k}<(13^k+1)^2$ => $12+13^x$ can't be a perfect square.
~# if $x=2k+1$ 
=> $12+13^x = 12+13^{2k+1}$.
Now we need prove that $k$ can not greater than $1$ (how to do that ?, stuck again)

REPLY [6 votes]: There are many ways to solve such problems -- I'm not sure that any of them are particularly easy. One way, since you've observed that your exponent $x$ is necessarily odd, would be to find all the integral points on the elliptic curves given by the equations
$$
y^2 = 13^\delta u^4+12 \; \mbox{ for } \; \delta \in \{ 1, 3 \}.
$$
One can do this in, for example, magma by typing :
IntegralQuarticPoints([13,0,0,0,12]); and IntegralQuarticPoints([13^3,0,0,0,12]);
which lead to the two known solutions (with $|u|=1$ and $|y| =5$ and $47$). These routines are using lower bounds for linear forms in logarithms (elliptic, I believe). 
Another approach (which has some similarities) would be to use an argument of de Weger (from his thesis, again based on linear forms in logarithms). This would enable you, for example, to tackle the more general equation
$$
13^x + 2^y 3^z = w^2.
$$
I haven't worked out the details, but one should be able to show that the only solutions are with
$$
\begin{array}{r}
(x,y,z) = (0,0,1), (0,3,0), (0,3,1), (0,4,1), (0,5,2), (1,0,1), (1,0,5), \\
(1,2,1), (1,2,2), (1,2,3), (2,0,3), (2,6,1), (2,10,5), (3,2,1). \\
\end{array}
$$
Yet another way to solve such problems is to use the hypergeometric method of Thue and Siegel. In this context, it enables one to prove an inequality of the shape
$$
\left| y^2 - 13^x \right| > |y|^{0.4},
$$
valid for all integers $y$ and odd $x$. Such an approach is also useful for bounding the number of solutions to equations like the one under consideration here. One can, for example, show that given any odd prime $p$ and integer $D$, there are at most $3$ positive integers $x$ such that 
$$
p^x+D = y^2
$$
for integer $y$. This is, of course, not quite sharp when $p=13$ and $D=12$, but it's close.