login
A176758
a(n) = Sum_{k=0..floor((n-1)/2)} (3^k-1)*binomial(n, 2*k+1).
1
2, 8, 28, 88, 264, 768, 2192, 6176, 17248, 47872, 132288, 364416, 1001600, 2748416, 7532800, 20627968, 56452608, 154423296, 422276096, 1154447360, 3155544064, 8624177152, 23567831040, 64400793600, 175970803712, 480810303488
OFFSET
3,1
FORMULA
From R. J. Mathar, Jan 29 2012: (Start)
a(n) = A002605(n) - 2^(n-1) = 2*A094309(n).
G.f.: 2*x^3/( (1-2*x)*(1-2*x-2*x^2) ). (End)
MATHEMATICA
(* First program *)
a[n_, q_]:= Sum[(q^((m-1)/2) - 1)*Binomial[n, m], {m, 1, n, 2}];
Table[a[n, 3], {n, 3, 30}]
(* Second program *)
A002605[n_]:= (-I*Sqrt[2])^(n-1)*ChebyshevU[n-1, I/Sqrt[2]];
Table[(Boole[n==0] - 2^n)/2 + A002605[n], {n, 3, 30}] (* G. C. Greubel, Sep 17 2021 *)
PROG
(Magma) I:=[2, 8, 28]; [n le 3 select I[n] else 4*Self(n-1) - 2*Self(n-2) +4*Self(n-3): n in [1..31]]; // G. C. Greubel, Sep 17 2021
(Sage) [(-i*sqrt(2))^(n-1)*chebyshev_U(n-1, i/sqrt(2)) - 2^(n-1) for n in (3..30)] # G. C. Greubel, Sep 17 2021
CROSSREFS
Sequence in context: A048497 A118047 A087431 * A178222 A090426 A279193
KEYWORD
nonn,easy
AUTHOR
Roger L. Bagula, Apr 25 2010
STATUS
approved