A268409 a(n) = 4*a(n - 1) + 2*a(n - 2) for n>1, a(0)=3, a(1)=5.
3, 5, 26, 114, 508, 2260, 10056, 44744, 199088, 885840, 3941536, 17537824, 78034368, 347213120, 1544921216, 6874111104, 30586286848, 136093369600, 605546052096, 2694370947584, 11988575894528, 53343045473280, 237349333682176, 1056083425675264
Offset: 0
Links
- Index entries for linear recurrences with constant coefficients, signature (4,2).
Programs
-
Magma
[n le 2 select 2*n+1 else 4*Self(n-1)+2*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Feb 04 2016
-
Mathematica
RecurrenceTable[{a[0] == 3, a[1] == 5, a[n] == 4 a[n - 1] + 2 a[n - 2]}, a, {n, 23}] LinearRecurrence[{4, 2}, {3, 5}, 24] Table[((18 + Sqrt[6]) (2 - Sqrt[6])^n - (Sqrt[6] - 18) (2 + Sqrt[6])^n)/12, {n, 0, 23}]
-
PARI
Vec((3 - 7*x)/(1 - 4*x - 2*x^2) + O(x^30)) \\ Michel Marcus, Feb 04 2016
Formula
G.f.: (3 - 7*x)/(1 - 4*x - 2*x^2).
a(n) = ((18 + sqrt(6))*(2 - sqrt(6))^n - (sqrt(6) - 18)*(2 + sqrt(6))^n)/12.
Lim_{n -> infinity} a(n + 1)/a(n) = 2 + sqrt(6) = A176213.
Comments