OFFSET
0,3
LINKS
Index entries for linear recurrences with constant coefficients, signature (3,1,-1,-1,-1)
FORMULA
G.f.: x*(1 - x - x^3)/((1 - x)*(1 - 2*x - 3*x^2 - 2*x^3 - x^4)).
a(n) = 3*a(n-1) + a(n-2) - a(n-3) - a(n-4) - a(n-5).
a(n) = floor((1 + sqrt(2))*a(n-1) + (1 + sqrt(2))*a(n-2)), a(0)=0, a(1)=1 (empirically).
Lim_{n->infinity} a(n)/a(n+1) = sqrt(sqrt(2) - sqrt(sqrt(2) + sqrt(sqrt(2) - sqrt(sqrt(2) + ...)))) = (sqrt(4*sqrt(2) - 3) - 1)/2 = A190179 - 1.
MATHEMATICA
LinearRecurrence[{3, 1, -1, -1, -1}, {0, 1, 2, 7, 21}, 31]
RecurrenceTable[{a[0] == 0, a[1] == 1, a[n] == Floor[(Sqrt[2] + 1) a[n - 1] + (Sqrt[2] + 1) a[n - 2]]}, a, {n, 30}]
PROG
(PARI) concat(0, Vec(x*(1-x-x^3)/((1-x)*(1-2*x-3*x^2-2*x^3-x^4)) + O(x^99))) \\ Altug Alkan, Jun 26 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Ilya Gutkovskiy, Jun 13 2016
STATUS
approved