Infinitely many perfect squares Are there positive integers $A,B$ such that $A2^n+B$ is a perfect square for  infinitely many $n$ ?
This is not my homework.
 A: Suppose that there are such positive integers $A$, $B$. Write $c_m=A2^m+B$, where $m$ is a positive integer such that $c_m$ is a perfect square. By assumption, there are infinitely many such $m\ge 1$. I will make a further assumption: there is an $m_0$ such that $c_m$ is a perfect square for all $m\ge m_0$. Then construct a sequence
$$
(x_m,y_m)=(2\sqrt{c_m}, \sqrt{A2^{m+2}+B }).
$$
It satisfies $(x_m+y_m)(x_m-y_m)=3B$. Hence $x_m+y_m$ divides $3B$ for infinitely many $m\ge m_0$. But this is impossible because $|x_m+y_m|>3B$ for $m$ large enough,and $3B\neq 0$ by assumption. Hence there are no such positive integers $A$ and $B$.
Edit: Without the additional assumption, $y_m$ may not be an integer. Perhaps one can remove the additional assumtion, e.g., by taking such integer $k$ that with $c_m$ also $A2^{m+k}+B$ is a perfect square for infinitely many $m$, i.e., with  $x_m=2^k\sqrt{a2^m+b}$, $y_m=\sqrt{a2^{m+2k}+b}$.
A: If one writes $n=n_0+3k$ for $n_0 \in \{ 0, 1, 2 \}$, then the existence of infinitely many $n$ for which $A 2^n+B$ is square would imply the existence of infinitely many integral points on (at least) one of the (genus $1$, generically) curves $y^2 = A 2 ^{n_0} x^3 + B$, contradicting Siegel's theorem.
