|
|
A141038
|
|
Padovan-like sequence; a(0)=2, a(1)=1, a(2)=1, a(n) = a(n-2) + a(n-3).
|
|
1
|
|
|
2, 1, 1, 3, 2, 4, 5, 6, 9, 11, 15, 20, 26, 35, 46, 61, 81, 107, 142, 188, 249, 330, 437, 579, 767, 1016, 1346, 1783, 2362, 3129, 4145, 5491, 7274, 9636, 12765, 16910, 22401, 29675, 39311, 52076, 68986, 91387, 121062, 160373, 212449, 281435, 372822, 493884, 654257
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
REFERENCES
|
Martin Gardner, Mathematical Circus, Random House, New York, 1981, p. 165.
|
|
LINKS
|
|
|
FORMULA
|
G.f.: (1+x)(2-x)/(1-x^2-x^3).
|
|
MATHEMATICA
|
Nest[Append[#, #[[-2]] + #[[-3]]] &, {2, 1, 1}, 46] (* or *)
CoefficientList[Series[(1 + x) (2 - x)/(1 - x^2 - x^3), {x, 0, 48}], x] (* Michael De Vlieger, Dec 17 2017 *)
LinearRecurrence[{0, 1, 1}, {2, 1, 1}, 60] (* Harvey P. Dale, Jul 21 2020 *)
|
|
PROG
|
(MATLAB) function y=fib(n)
fz(1)=2; fz(2)=1; fz(3)=1;
for k=4:n
fz(k)=fz(k-2)+fz(k-3);
end
y=fz(n);
(PARI) x='x+O('x^99); Vec((1+x)*(2-x)/(1-x^2-x^3)) \\ Altug Alkan, Dec 17 2017
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
Matt Wynne (mattwyn(AT)verizon.net), Jul 30 2008
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|