Is there a trick to evaluating a matrix multiplied by the sum of three vectors? I am looking at some old linear algebra test material along with some sample answers. I don't understand a bit of computation in the sample answer. Here's the exam question:

Examine the recurrence equation $x_n = Ax_{n-1} + u$, where
$$A = \begin{pmatrix} 1 & 0 & 0 \\\ 0 & 1 & a \\\ 0 & a & a^2 \end{pmatrix}$$
Now suppose $x_n = α_np + β_nq + γ_nr$ and $u = cp - acr + bq$ for some set of vectors $p, q, r, u$ ($α, β, γ, a, b, c$ are constants). Express $α_n, β_n, γ_n$ in terms of  $α_{n-1}, β_{n-1}, γ_{n-1}$.

The answer proceeds:

$$x_n = Ax_{n-1} + u = \begin{pmatrix} 1 & 0 & 0 \\\ 0 & 1 & a \\\ 0 & a & a^2 \end{pmatrix}\begin{pmatrix} \\\ α_{n-1}p + β_{n-1}q + γ_{n-1}r \\\ \end{pmatrix} + u$$
$$x_n = \begin{pmatrix} 1 & 0 & 0 \\\ 0 & 1 & a \\\ 0 & a & a^2 \end{pmatrix}\begin{pmatrix} \\\ (a^2 + 1)α_{n+1}p + β_{n-1}q \\\ \end{pmatrix} + u$$
$$x_n = ((a^2 + 1)α_{n+1} + c)p + (β_{n-1} + b)q + acr$$
  
  
*
  
*$α_n = (a^2 + 1)a_{n+1}c$
  
*$β_n = β_{n-1} + b$
  
*$γ_n = ac$
  

Unfortunately, I can't understand the second step in the solution. Where did $r$ go? Where did $a^2 + 1$ and $α_{n+1}$ come from? Is the answer using some sort of matrix-vector product shortcut I don't know about?

In case it's relevant, in an earlier part of the problem the values of $p, q, r$ are calculated as:
$$p = \frac{1}{a^2 + 1}\begin{pmatrix} 0 \\\ 1 \\\ a \end{pmatrix}\space,\space\space\space q = \begin{pmatrix} 1 \\\ 0 \\\ 0 \end{pmatrix}\space,\space\space\space r = \frac{1}{a^2 + 1}\begin{pmatrix} 0 \\\ -a \\\ 1 \end{pmatrix}$$

There appear to be some typos. 
Yes the previous computations are relevant. As in the comment by Avitus, 
$Ap = (a^2 + 1)p , Aq=q, Ar = 0$. Then
$$ \begin{align}x_n = \alpha_n p + \beta_n q + \gamma_n r 
&= A(\alpha_{n-1}p + \beta_{n-1}q + \gamma_{n-1}r ) + u\\
&= (\alpha_{n-1}(a^2 + 1) + c)p + (\beta_{n-1} + b)q - acr
\end{align}$$
Then by comparing the coefficients of $p,q$ and $r$ you see that
$\alpha_n = \alpha_{n-1}(a^2 + 1) + c$, $\beta_n = \beta_{n-1} + b$ and $\gamma_n = -ac$.
