This is a recursive relationship very similar to the Fibonacci numbers, except that A1=2 and A2=5, whereas F1=1 and F2=1 for Fibonacci numbers.
We start with
Substitute An-1=An-2+An-3, we get
Similarly, and continuing,
Replacing the coefficients by Fibonacci numbers, where
F0=0, F1=1, F2=1, F3=2, F4=3...
and continuing the substitution until A2 and A1, we would get:
Work out A8 manually as a check.