OFFSET
0,2
LINKS
Robert Israel, Table of n, a(n) for n = 0..1090
Index entries for linear recurrences with constant coefficients, signature (12, -31).
FORMULA
From Philippe Deléham, Nov 26 2008: (Start)
a(n) = 12*a(n-1)-31*a(n-2), n>1 ; a(0)=1, a(1)=6 .
G.f.: (1-6*x)/(1-12*x+31*x^2).
a(n) = (Sum_{k=0..n} A098158(n,k)*6^(2*k)*5^(n-k))/6^n. (End)
E.g.f.: cosh(sqrt(5)*x)*exp(6*x). - Ilya Gutkovskiy, Aug 24 2016
EXAMPLE
For n=3, (6+sqrt(5))^3 = 216 + 108*sqrt(5) + 18*5 + 5*sqrt(5) = 306 + 113*sqrt(5) and (6-sqrt(5))^3 = 306 - 113*sqrt(5), so a(3) = (306 + 113*sqrt(5) + 306 - 113*sqrt(5))/2 = 306. - Michael B. Porter, Aug 25 2016
MAPLE
f:= gfun:-rectoproc({a(n)=12*a(n-1)-31*a(n-2), a(0)=1, a(1)=6}, a(n), remember):
map(f, [$0..50]); # Robert Israel, Aug 25 2016
MATHEMATICA
CoefficientList[Series[(1 - 6 x)/(1 - 12 x + 31 x^2), {x, 0, 19}], x] (* Michael De Vlieger, Aug 25 2016 *)
LinearRecurrence[{12, -31}, {1, 6}, 30] (* Harvey P. Dale, Aug 28 2024 *)
PROG
(Magma) Z<x>:= PolynomialRing(Integers()); N<r5>:=NumberField(x^2-5); S:=[ ((6+r5)^n+(6-r5)^n)/2: n in [0..19] ]; [ Integers()!S[j]: j in [1..#S] ]; // Klaus Brockhaus, Nov 26 2008
CROSSREFS
KEYWORD
nonn
AUTHOR
Al Hakanson (hawkuu(AT)gmail.com), Nov 24 2008
EXTENSIONS
Extended beyond a(6) by Klaus Brockhaus, Nov 26 2008
Typo in name corrected by J. Conrad, Aug 24 2016
STATUS
approved