OFFSET
0,2
FORMULA
For n >= 1, a(n+3) = (8 - 3*n)*a(n-1) + (-24 + 4*n)*a(n) + (22 - n)*a(n+1) - 8*a(n+2). -- Jianing Song, Nov 10 2018
MATHEMATICA
M[n_] := {{0, 1, 0, 0}, {0, 0, 1, 0}, {0, 0, 0, 1}, {8 - 3 n, -24 + 4 n, 22 - n, -8}};
v[0] ={1, -8, 84, -836};
v[n_] := v[n] = M[n].v[n - 1];
a = Table[v[n][[1]], {n, 0, 30}]
RecurrenceTable[{a[0]==1, a[1]==-8, a[2]==84, a[3]==-836, a[n+3]==(8-3n)a[n-1]+ (-24+4n)a[n]+(22-n)a[n+1]-8a[n+2]}, a, {n, 20}] (* Harvey P. Dale, Jun 19 2021 *)
PROG
(PARI) M(n) = [0, 1, 0, 0; 0, 0, 1, 0; 0, 0, 0, 1; 8 - 3*n, -24 + 4*n, 22 - n, -8];
T(n) = if(n==0, [1; -8; 84; -836], M(n)*T(n-1))
a(n) = T(n)[1, 1] \\ Jianing Song, Nov 10 2018
CROSSREFS
KEYWORD
sign,easy,less
AUTHOR
Roger L. Bagula, Jun 16 2007
EXTENSIONS
Edited, new name, and offset corrected by Jianing Song, Nov 10 2018
STATUS
approved