Is it true: $3k^2+1$ is a perfect square if and only if $k=1$ or $4$ I'm checking the following conjecture:  $3k^2+1$ is a perfect square if and only if $k=1$ or $4$. If it is not true counter example would be appreciated. Thanks in advance.
 A: There are in fact infinitely many solutions:
$k_1=1, k_2=4, k_3=15, k_n=4k_{n-1}-k_{n-2}$
$3\cdot15^2+1=676=26^2$, etc.
A: This is not true. $3\times15^2+1=676=26^2$.
A: You can do this by solving the pells equation.
Let $3{k^2}+1={n^2}$ for some natural number n.Then the equation becomes a
pells equation$\implies$ ${n^2}-3{m^2}=1$.Then factorize L.H.S.
We get $(n+{\sqrt3}m)(n-{\sqrt3}m)=1$.Here m and n are solutions of the equation.
Now square both sides of the equation,you will get$\implies$
$({n^2}+3{m^2}+2{\sqrt3}mn)({n^2}+3{m^2}-2{\sqrt3}mn)=1$
Now see that the above equation is of the form ${\implies}$
$(I_1+{\sqrt3}I_2)(I_1-{\sqrt3}I_2)=1$
So $I_1\;\;and\;\;I_2$ are also solutions of that above equation.So if
you proceed like this, you will get the solutions for K.
By observing some solutions for K,we get the recurrence
$K_n=4K_{n-1}-K_{n-2}$.
Hence by solving the recurrence by characteristic equation for solving
recurrence we get ${\implies}$
$$K_n=\frac{1}{2{\sqrt3}}(({2+{\sqrt3}})^n-({2-{\sqrt3}})^n)$$
