A178987 a(n) = n*(n-3)*2^(n-2).
0, -1, -2, 0, 16, 80, 288, 896, 2560, 6912, 17920, 45056, 110592, 266240, 630784, 1474560, 3407872, 7798784, 17694720, 39845888, 89128960, 198180864, 438304768, 964689920, 2113929216, 4613734400, 10032775168, 21743271936, 46976204800, 101200166912
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- Sara Billey, Krzystof Burdzy and Bruce Sagan, Permutations With Given Peak Set, J. Integer Sequences, Vol. 16 (2013), online article 13.6.1.
- Index entries for linear recurrences with constant coefficients, signature (6,-12,8).
Crossrefs
Cf. A176027.
Programs
-
Magma
[n*(n-3)*2^(n-2): n in [0..30]]; // Vincenzo Librandi, Aug 04 2011
-
Mathematica
Table[n(n-3)2^(n-2),{n,0,30}] (* or *) LinearRecurrence[{6,-12,8},{0,-1,-2},30] (* Harvey P. Dale, Mar 24 2023 *)
Formula
a(n) = 16*A001793(n-3), n > 3.
a(n) = +6*a(n-1) -12*a(n-2) +8*a(n-3).
a(n+1)-a(n) = -A127276(n).
G.f.: -x*(-1+4*x)/(2*x-1)^3. - R. J. Mathar, Jan 04 2011
a(n) = Sum_{k=0..n-1} Sum_{i=0..n-1} (k-1) * C(n-1,i). - Wesley Ivan Hurt, Sep 20 2017
a(n) = Sum_{k=0..n} k^2 * (-1)^k * 3^(n-k) * binomial(n,k). - Seiichi Manyama, Apr 18 2025
Comments