A152885
Number of descents beginning and ending with an odd number in all permutations of {1,2,...,n}.
Original entry on oeis.org
0, 0, 2, 6, 72, 360, 4320, 30240, 403200, 3628800, 54432000, 598752000, 10059033600, 130767436800, 2440992153600, 36614882304000, 753220435968000, 12804747411456000, 288106816757760000, 5474029518397440000, 133809610449715200000, 2810001819444019200000
Offset: 1
a(6) = 360 because (i) the descent pairs can be chosen in binomial(3,2) = 3 ways, namely (3,1), (5,1), (5,3); (ii) they can be placed in 5 positions, namely (1,2),(2,3),(3,4),(4,5),(5,6); (iii) the remaining 4 entries can be permuted in 4!=24 ways; 3*5*24 = 360.
-
a := proc (n) if `mod`(n, 2) = 0 then (1/4)*factorial(n)*((1/2)*n-1) else (1/8)*(n-1)*(n+1)*factorial(n-1) end if end proc: seq(a(n), n = 1 .. 20);
-
a[n_] := (n - 1)! * Binomial[If[OddQ[n], (n + 1)/2, n/2], 2]; Array[a, 25] (* Amiram Eldar, Jan 22 2023 *)
A152886
Number of descents beginning and ending with an even number in all permutations of {1,2,...,n}.
Original entry on oeis.org
0, 0, 0, 6, 24, 360, 2160, 30240, 241920, 3628800, 36288000, 598752000, 7185024000, 130767436800, 1830744115200, 36614882304000, 585838116864000, 12804747411456000, 230485453406208000, 5474029518397440000, 109480590367948800000, 2810001819444019200000
Offset: 1
a(7) = 2160 because (i) the descent pairs can be chosen in binomial(3,2) = 3 ways, namely (4,2), (6,2), (6,4); (ii) they can be placed in 6 positions, namely (1,2),(2,3),(3,4),(4,5),(5,6),(6,7); (iii) the remaining 5 entries can be permuted in 5! = 120 ways; 3*6*120 = 2160.
-
a := proc (n) if `mod`(n, 2) = 0 then factorial(n-1)*binomial((1/2)*n, 2) else factorial(n-1)*binomial((1/2)*n-1/2, 2) end if end proc: seq(a(n), n = 1 .. 22);
-
a[n_] := (n - 1)! * Binomial[If[OddQ[n], (n - 1)/2, n/2], 2]; Array[a, 25] (* Amiram Eldar, Jan 22 2023 *)
A052657
Expansion of e.g.f. x^2/((1-x)^2*(1+x)).
Original entry on oeis.org
0, 0, 2, 6, 48, 240, 2160, 15120, 161280, 1451520, 18144000, 199584000, 2874009600, 37362124800, 610248038400, 9153720576000, 167382319104000, 2845499424768000, 57621363351552000, 1094805903679488000, 24329020081766400000, 510909421717094400000, 12364008005553684480000
Offset: 0
encyclopedia(AT)pommard.inria.fr, Jan 25 2000
-
spec := [S,{S=Prod(Z,Z,Sequence(Z),Sequence(Prod(Z,Z)))},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
-
a[n_] := Floor[n/2] * n!; Array[a, 25, 0] (* Amiram Eldar, Jan 22 2023 *)
-
a(n)=if(n<0,0,n!*polcoeff(x^2/(1-x)/(1-x^2)+x*O(x^n),n))
-
a(n)=n!*(n\2); \\ Joerg Arndt, Jan 22 2023
A062779
a(n) = 2*n*(2*n)!.
Original entry on oeis.org
0, 4, 96, 4320, 322560, 36288000, 5748019200, 1220496076800, 334764638208000, 115242726703104000, 48658040163532800000, 24728016011107368960000, 14890761641597746544640000, 10485577989291746525184000000
Offset: 0
- Jerome Spanier and Keith B. Oldham, "Atlas of Functions", Hemisphere Publishing Corp., 1987, chapter 38, equation 38:6:2 at page 364.
-
a[n_] := 2*n*(2*n)!; Array[a, 14, 0] (* Amiram Eldar, Feb 14 2021 *)
-
for(n=0,22,print((2*n)*(2*n)!))
Comments