login
(n-1)-st elementary symmetric function of {1, 2, 2, 3, 3, 4, 4, 5, 5, ..., floor(1+n/2)}.
5

%I #19 Nov 28 2017 03:27:13

%S 1,3,8,28,96,420,1824,9696,51360,322560,2021760,14670720,106323840,

%T 875992320,7211151360,66526064640,613365903360,6265340928000,

%U 63970228224000,716840699904000,8030097782784000,97954524315648000

%N (n-1)-st elementary symmetric function of {1, 2, 2, 3, 3, 4, 4, 5, 5, ..., floor(1+n/2)}.

%H Clark Kimberling, <a href="/A203152/b203152.txt">Table of n, a(n) for n = 1..1000</a>

%e Let esf abbreviate "elementary symmetric function". Then

%e 0th esf of {1}: 1;

%e 1st esf of {1,2}: 1+2 = 3;

%e 2nd esf of {1,2,2} is 1*2 + 1*2 + 2*2 = 8.

%p SymmPolyn := proc(L::list,n::integer)

%p local c,a,sel;

%p a :=0 ;

%p sel := combinat[choose](nops(L),n) ;

%p for c in sel do

%p a := a+mul(L[e],e=c) ;

%p end do:

%p a;

%p end proc:

%p A203152 := proc(n)

%p local k ;

%p L := [seq(floor(1+k/2),k=1..n)] ;

%p SymmPolyn(L,n-1) ;

%p end proc: # _R. J. Mathar_, Sep 23 2016

%t f[k_] := Floor[(k + 2)/2]; t[n_] := Table[f[k], {k, 1, n}]

%t a[n_] := SymmetricPolynomial[n - 1, t[n]]

%t Table[a[n], {n, 1, 22}] (* A203152 *)

%Y Cf. A203153.

%K nonn

%O 1,2

%A _Clark Kimberling_, Dec 29 2011