login
A026965
a(n) = Sum_{k=0..n} (k+1) * A026626(n,k).
16
1, 3, 10, 25, 66, 154, 360, 810, 1810, 3982, 8700, 18850, 40614, 87030, 185680, 394570, 835578, 1763998, 3713700, 7798770, 16340302, 34166086, 71303160, 148548250, 308980386, 641728494, 1330992460, 2757055810, 5704253430
OFFSET
0,2
FORMULA
G.f.: (1-x-x^3+3*x^4-5*x^5-2*x^6+3*x^7)/((1-x)^2*(1+x)^2*(1-2*x)^2). - Colin Barker, Apr 26 2015
From G. C. Greubel, Jun 23 2024: (Start)
a(n) = (1/6)*(n+2)*(17*2^(n-2) - 3 + (-1)^n) + (1/4)*([n=0] + 3*[n=1]).
a(n) = ( n*(n+2)*a(n-1) + 2*(n+1)*(n+2)*a(n-2) + n*(n+1)*(n+2) )/(n*(n + 1)), with a(0) = 1, a(1) = 3, a(2) = 10, a(3) = 25.
E.g.f.: (1/12)*( 17*(1+x)*exp(2*x) - 6*(2+x)*exp(x) + 2*(2-x)*exp(-x) + 3*(1+3*x) ). (End)
MATHEMATICA
Table[(n+2)*(17*2^(n-2) -3 +(-1)^n)/6 +(1/4)*(Boole[n==0] +3*Boole[n== 1]), {n, 0, 50}] (* G. C. Greubel, Jun 23 2024 *)
PROG
(Magma) [n le 1 select 2*n+1 else (n+2)*(17*2^(n-2) -3 +(-1)^n)/6: n in [0..40]]; // G. C. Greubel, Jun 23 2024
(SageMath) [(n+2)*(17*2^(n-2) -3 +(-1)^n)/6 + (1/4)*(int(n==0) + 3*int(n==1)) for n in range(41)] # G. C. Greubel, Jun 23 2024
KEYWORD
nonn
STATUS
approved