login
A107287
a(n) = a(n-1)+a(n-2)-a(n-3)+a(n-5), n>7.
0
1, 0, 1, 1, 1, 4, 4, 6, 7, 10, 15, 22, 33, 47, 68, 97, 140, 202, 292, 422, 609, 879, 1268, 1830, 2641, 3812, 5502, 7941, 11461, 16541, 23873, 34455, 49728, 71771, 103585, 149501, 215770, 311414, 449454, 648683, 936224, 1351223, 1950178, 2814631
OFFSET
0,6
FORMULA
G.f.: (-1+x)*(1+x)*(2*x^5+x^2-x+1)/(-1+x+x^2-x^3+x^5). [Sep 28 2009]
MATHEMATICA
M = {{0, 1, 0, 0, 0}, {0, 0, 1, 0, 0}, {0, 0, 0, 1, 0}, {0, 0, 0, 0, 1}, {1, 0, -1, 1, 1}} v[1] = {1, 0, -1, 1, 1} v[n_] := v[n] = M.v[n - 1] a = Table[Abs[v[n][[1]]], {n, 1, 50}]
LinearRecurrence[{1, 1, -1, 0, 1}, {1, 0, 1, 1, 1, 4, 4, 6}, 50] (* Harvey P. Dale, Sep 24 2015 *)
CROSSREFS
Sequence in context: A320828 A065677 A006672 * A240119 A292755 A294021
KEYWORD
nonn,easy
AUTHOR
Roger L. Bagula, Jun 08 2005
EXTENSIONS
Definition replaced by recurrence by the Associate Editors of the OEIS, Sep 28 2009
STATUS
approved