Prove that the elements of the sequence are integers

Sequence is Integral

Suppose $$ a_{n+2}=3a_n+b_n\tag{1} $$ where $$ b_n^2=8\!\left(a_n^2+a_{n+1}^2\right)\tag{2} $$ Then $$ \begin{align} b_{n+1}^2 &=8\!\left(\color{#C00}{a_{n+2}^2}+\color{#090}{a_{n+1}^2}\right)\\ &=8\!\left(\color{#C00}{9a_n^2+6a_nb_n+b_n^2}+\color{#090}{\frac{b_n^2}8-a_n^2}\right)\\ &=64a_n^2+48a_nb_n+9b_n^2\\[6pt] &=(8a_n+3b_n)^2\tag{3} \end{align} $$ Therefore, $$ b_{n+1}=8a_n+3b_n\tag{4} $$ We can continue the integer sequences using $(1)$ and $(4)$: $$ \begin{bmatrix}a_{n+1}\\a_{n+2}\\b_{n+1}\end{bmatrix} = \begin{bmatrix}0&1&0\\3&0&1\\8&0&3\end{bmatrix} \begin{bmatrix}a_n\\a_{n+1}\\b_n\end{bmatrix}\tag{5} $$ That is, $$ \begin{bmatrix}a_n\\a_{n+1}\\b_n\end{bmatrix} = \begin{bmatrix}0&1&0\\3&0&1\\8&0&3\end{bmatrix}^{\,\large n} \begin{bmatrix}1\\41\\116\end{bmatrix}\tag{6} $$


Closed Form for the Sequence

Using the Jordan Normal Form of the matrix in $(6)$, we get $$ \begin{bmatrix}a_n\\a_{n+1}\\b_n\end{bmatrix} = \begin{bmatrix} -1&\frac{-1-\sqrt3}8&\frac{-1+\sqrt3}8\\ 1&\frac{1-\sqrt3}8&\frac{1+\sqrt3}8\\ 2&1&1 \end{bmatrix} \begin{bmatrix} -1&0&0\vphantom{\frac{\sqrt3}8}\\ 0&2-\sqrt3&0\vphantom{\frac{\sqrt3}8}\\ 0&0&2+\sqrt3 \end{bmatrix}^{\,\large n} \begin{bmatrix} \frac{22}3\\ \frac{152-84\sqrt3}3\\ \frac{152+84\sqrt3}3 \end{bmatrix}\tag{7} $$ from which, we can extract $$ a_n=\frac{25+17\sqrt3}6\left(2+\sqrt3\right)^n-\frac{22}3(-1)^n+\frac{25-17\sqrt3}6\left(2-\sqrt3\right)^n\tag{8} $$ It is not immediately evident that $(8)$ is always an integer; however, since we have $\left(x-2-\sqrt3\right)\left(x-2+\sqrt3\right)(x+1)=x^3-3x^2-3x+1$, equation $(8)$ implies that $$ a_n=3a_{n-1}+3a_{n-2}-a_{n-3}\tag{9} $$ which does imply that $a_n$ is always an integer since $a_0=1$, $a_1=41$, and $a_2=119$.


Hint:

Clearly, induction is likely the way to go here. But, what should your hypothesis be?

It isn't enough to assume that the previous two terms are integers. So, let's look at what it means for $a_{n+2}$ to be an integer.

Clearly, if $a_n$ is an integer, then $3a_n$ is as well. So, you need to consider the square root. In order for that to be an integer, it must be the case that $8(a_n^2+a_{n+1}^2)$ is a perfect square. Since $8=2^3$, the combination of this condition with the assumption that $a_n$ and $a_{n+1}$ must be integers is equivalent to saying that $a_n^2+a_{n+1}^2=2m^2$ for some $m$. (Can you see why?)

So, I'd suggest trying to prove by induction the slightly stronger statement that for all $n$, $a_n$ is an integer AND that for each $n$, you can find an integer $m$ so that $a_n^2+a_{n+1}^2=2m^2$.