|
|
A295683
|
|
a(n) = a(n-1) + a(n-3) + a(n-4), where a(0) = 2, a(1) = 1, a(2) = 0, a(3) = 1.
|
|
2
|
|
|
2, 1, 0, 1, 4, 5, 6, 11, 20, 31, 48, 79, 130, 209, 336, 545, 884, 1429, 2310, 3739, 6052, 9791, 15840, 25631, 41474, 67105, 108576, 175681, 284260, 459941, 744198, 1204139, 1948340, 3152479, 5100816, 8253295, 13354114, 21607409, 34961520, 56568929, 91530452
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
a(n)/a(n-1) -> (1 + sqrt(5))/2 = golden ratio (A001622), so that a( ) has the growth rate of the Fibonacci numbers (A000045).
|
|
LINKS
|
|
|
FORMULA
|
G.f.: (2 - x - x^2 - x^3)/(1 - x - x^3 - x^4).
|
|
MAPLE
|
f:= gfun:-rectoproc(a(n) = a(n-1) + a(n-3) + a(n-4), a(0) = 2, a(1) = 1, a(2) = 0, a(3) = 1}, a(n), remember):
|
|
MATHEMATICA
|
LinearRecurrence[{1, 0, 1, 1}, {2, 1, 0, 1}, 45]
|
|
PROG
|
(PARI) my(x='x+O('x^45)); Vec((-2 + x + x^2 + x^3)/(-1 + x + x^3 + x^4)) \\ Georg Fischer, Apr 03 2019
(Magma) I:=[2, 1, 0, 1]; [n le 4 select I[n] else Self(n-1) +Self(n-3) +Self(n-4): n in [1..45]]; // G. C. Greubel, Apr 03 2019
(Sage) ((2-x-x^2-x^3)/(1-x-x^3-x^4)).series(x, 45).coefficients(x, sparse=False) # G. C. Greubel, Apr 03 2019
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|