OFFSET
0,3
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (3,5).
FORMULA
G.f.: (1-2*x)/(1-3*x-5*x^2). - Jaume Oliver Lafont, Mar 06 2009
G.f.: G(0)*(1-2*x)/(2-3*x), where G(k)= 1 + 1/(1 - x*(29*k-9)/(x*(29*k+20) - 6/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 17 2013
a(n) = 5^((n-1)/2)*( sqrt(5)*Fibonacci(n+1, 3/sqrt(5)) - 2*Fibonacci(n, 3/sqrt(5)) ). - G. C. Greubel, Jan 14 2020
EXAMPLE
a(5)=3*a(4)+5*a(3): 127=3*29+5*8=87+40.
MAPLE
seq(coeff(series((1-2*x)/(1-3*x-5*x^2), x, n+1), x, n), n = 0..30); # G. C. Greubel, Jan 14 2020
MATHEMATICA
LinearRecurrence[{3, 5}, {1, 1}, 30] (* Harvey P. Dale, Feb 17 2018 *)
PROG
(Magma) [n le 2 select 1 else 3*Self(n-1)+5*Self(n-2): n in [1..26]]; // Bruno Berselli, Oct 11 2011
(PARI) my(x='x+O('x^30)); Vec((1-2*x)/(1-3*x-5*x^2)) \\ G. C. Greubel, Jan 14 2020
(Sage)
def A072264_list(prec):
P.<x> = PowerSeriesRing(ZZ, prec)
return P( (1-2*x)/(1-3*x-5*x^2) ).list()
A072264_list(30) # G. C. Greubel, Jan 14 2020
(GAP) a:=[1, 1];; for n in [3..30] do a[n]:=3*a[n-1]+5*a[n-2]; od; a; # G. C. Greubel, Jan 14 2020
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Miklos Kristof, Jul 08 2002
EXTENSIONS
Offset changed and more terms added by Bruno Berselli, Oct 11 2011
STATUS
approved