Prove that the equation $3^k = m^2 + n^2 + 1$ has infinitely many solutions in positive integers.
I have found that this is true for the first $k$'s from 1 to 7 except 3 and 6.
I have tried algebraic manipulation and induction too and it doesn't seem to work. I believe induction won't work since there are exceptions.
If I am correct, the numbers $m^2$ and $n^2$ can only be of the form $3a+1$.
Do you have any ideas about how I should proceed with this? I would love a few hints. Thanks.