A127976 a(n) = ((6*n + 10)/27)*2^(n-1) + ((-1)^(n-1))*(6*n + 5)/27.
1, 1, 5, 9, 25, 53, 125, 273, 609, 1325, 2885, 6217, 13353, 28517, 60685, 128641, 271857, 572829, 1203925, 2524345, 5281721, 11029461, 22991005, 47846129, 99420545, 206297613, 427508325, 884842793, 1829337929, 3777980485
Offset: 1
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- W. Bosma, Signed bits and fast exponentiation, J. Th. des Nombres de Bordeaux Vol.13, Fasc. 1, 2001.
- Index entries for linear recurrences with constant coefficients, signature (2,3,-4,-4).
Programs
-
Magma
[((6*n + 10)/27)*2^(n - 1) + ((-1)^(n - 1))*(6*n + 5)/27: n in [1..40]]; // Vincenzo Librandi, May 26 2011
-
Mathematica
Table[((6n + 10)/27)2^(n - 1) + ((-1)^(n - 1) )(6n + 5)/27, {n, 1, 100}]
-
PARI
x='x+O('x^30); Vec(x*(1-x)/((1+x)^2*(1-2*x)^2)) \\ G. C. Greubel, May 07 2018
-
PARI
a(n) = ((6*n + 10)/27)*2^(n - 1) + (-1)^(n - 1)*(6*n + 5)/27; \\ Michel Marcus, May 09 2018
Formula
From Joerg Arndt, May 27 2011: (Start)
a(n) = +2*a(n-1) +3*a(n-2) -4*a(n-3) -4*a(n-4).
G.f.: x*(1-x)/((1+x)^2*(1-2*x)^2). (End)
E.g.f.: 2*exp(x/2)*(6*x*cosh(3*x/2) + 5*sinh(3*x/2))/27. - Stefano Spezia, May 25 2023
Extensions
Name edited by Altug Alkan, May 09 2018
Comments