<s>[INST] Finding the general formula of the sequence $ a_n = 7a_{n-2} + 6a_{n-3} $ Given the equation $ a_n = 7a_{n-2} + 6a_{n-3} $, and $ a_0 = a_1 = a_2 = 1 $, how do I find the general equation? 
I have tried to express this sequence in matrix form, $ Q = Xb $ as follows
$$ Q = \begin{bmatrix} a_{n+1} \\ a_{n-2} \\ a_{n-3} \\ \end{bmatrix} 
\hspace{1cm}
X =\begin{bmatrix}0 & 7 & 6 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \\ \end{bmatrix} 
\hspace{1cm}
b = \begin{bmatrix} a_{n} \\ a_{n-1} \\ a_{n-2} \\ \end{bmatrix} $$
I attempt diagonalize $X$ in order to  find $X^n$, but the eigenvalues of $X$ seem to be not real
Can anyone see if my method is correct? 
 [/INST] Try instead $$Q = A_n=\begin{bmatrix} a_{n} \\ a_{n-1} \\ a_{n-2} \\ \end{bmatrix} 
\hspace{1cm}
X =\begin{bmatrix} 0&7 & 6 \\ 1 & 0 & 0 \\ 0 &  1 & 0 \\ \end{bmatrix} 
\hspace{1cm}
b = A_{n-1}=\begin{bmatrix} a_{n-1} \\ a_{n-2} \\ a_{n-3} \end{bmatrix}$$
Hence $A_n=X^n A_0=X^{n-3}A_3$
The matrix $X$ can be diagonalized as
$$ X = \begin{bmatrix} 9&4 & 1 \\ 3 & -2 & -1 \\1 &  1 & 1 \\ \end{bmatrix}
\begin{bmatrix} 3&0 & 0 \\ 0 & -2 &0 \\0 &  0 & -1 \\ \end{bmatrix}
\frac{1}{20}\begin{bmatrix} 1&3 & 2 \\ 4 & -8 &-12 \\-5 &  5 & -30 \\ \end{bmatrix}
$$
</s>