login
a(n) = (n-1)*(n+1)!/6.
(Formerly M4551)
21

%I M4551 #81 Aug 09 2022 02:29:44

%S 0,1,8,60,480,4200,40320,423360,4838400,59875200,798336000,

%T 11416204800,174356582400,2833294464000,48819843072000,

%U 889218570240000,17072996548608000,344661117825024000,7298706024529920000,161787983543746560000

%N a(n) = (n-1)*(n+1)!/6.

%C Coefficients of Gandhi polynomials.

%C a(n) = Sum_{pi in Symm(n)} Sum_{i=1..n} max(pi(i)-i,0), i.e., the total positive displacement of all letters in all permutations on n letters. - _Franklin T. Adams-Watters_, Oct 25 2006

%C a(n) is also the sum of the excedances of all permutations of [n]. An excedance of a permutation p of [n] is an i (1 <= i <= n-1) such that p(i) > i. Proof: i is an excedance if p(i) = i+1, i+2, ..., n (n-i possibilities), with the remaining values of p forming any permutation of [n]\{p(i)} in the positions [n]\{i} ((n-1)! possibilities). Summation of i(n-i)(n-1)! over i from 1 to n-1 completes the proof. Example: a(3)=8 because the permutations 123, 132, 213, 231, 312, 321 have excedances NONE, {2}, {1}, {1,2}, {1}, {1}, respectively. - _Emeric Deutsch_, Oct 26 2008

%C a(n) is also the number of doubledescents in all permutations of {1,2,...,n-1}. We say that i is a doubledescent of a permutation p if p(i) > p(i+1) > p(i+2). Example: a(3)=8 because each of the permutations 1432, 4312, 4213, 2431, 3214, 3421 has one doubledescent, the permutation 4321 has two doubledescents and the remaining 17 permutations of {1,2,3,4} have no doubledescents. - _Emeric Deutsch_, Jul 26 2009

%C Equals the second right hand column of A167568 divided by 2. - _Johannes W. Meijer_, Nov 12 2009

%C Half of sum of abs(p(i+1) - p(i)) over all permutations on n, e.g., 42531 = 2 + 3 + 2 + 2 = 9, and the total over all permutations on {1,2,3,4,5} is 960. - _Jon Perry_, May 24 2013

%C a(n) gives the number of non-occupied corners in tree-like tableaux of size n+1 (see Gao et al. link). - _Michel Marcus_, Nov 18 2015

%C a(n) is the number of sequences of n+2 balls colored with at most n colors such that exactly three balls are the same color as some other ball in the sequence. - _Jeremy Dover_, Sep 26 2017

%C a(n) is the number of triangles (3-cycles) in the (n+1)-alternating group graph. - _Eric W. Weisstein_, Jun 09 2019

%D N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

%H Vincenzo Librandi, <a href="/A005990/b005990.txt">Table of n, a(n) for n = 1..300</a>

%H D. Dumont, <a href="http://dx.doi.org/10.1215/S0012-7094-74-04134-9">Interpretations combinatoires des nombres de Genocchi</a>, Duke Math. J., 41 (1974), 305-318.

%H D. Dumont, <a href="/A001469/a001469_3.pdf">Interprétations combinatoires des nombres de Genocchi</a>, Duke Math. J., 41 (1974), 305-318. (Annotated scanned copy)

%H Alice L. L. Gao, Emily X. L. Gao, and Brian Y. Sun, <a href="http://arxiv.org/abs/1511.05434">Zubieta's Conjecture on the Enumeration of Corners in Tree-like Tableaux</a>, arXiv:1511.05434 [math.CO], 2015. The second version of this paper has a different title and different authors: A. L. L. Gao, E. X. L. Gao, P. Laborde-Zubieta, and B. Y. Sun, Enumeration of Corners in Tree-like Tableaux and a Conjectural (a,b)-analogue, arXiv preprint arXiv:1511.05434v2, 2015.

%H Milan Janjic, <a href="https://pmf.unibl.org/wp-content/uploads/2017/10/enumfun.pdf">Enumerative Formulas for Some Functions on Finite Sets</a>.

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/AlternatingGroupGraph.html">Alternating Group Graph</a>.

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/GraphCycle.html">Graph Cycle</a>.

%F a(n) = A090672(n)/2.

%F a(n) = A052571(n+2)/6. - _Zerinvary Lajos_, May 11 2007

%F a(n) = Sum_{m=0..n} Sum_{k=-1..n} Sum_{j=1..n} n!/6, n >= 0. - _Zerinvary Lajos_, May 11 2007

%F If we define f(n,i,x) = Sum_{k=i..n} (Sum_{j=i..k} binomial(k,j)*Stirling1(n,k)*Stirling2(j,i)*x^(k-j)) then a(n+1) = (-1)^(n-1)*f(n,1,-4), (n >= 1). - _Milan Janjic_, Mar 01 2009

%F E.g.f.: (-1+3*x)/(3!*(1-x)^3), a(0) = -1/3!. Such e.g.f. computations resulted from e-mail exchange with _Gary Detlefs_. - _Wolfdieter Lang_, May 27 2010

%F a(n) = ((n+3)!/2) * Sum_{j=i..k} (k+1)!/(k+3)!, with offset 0. - _Gary Detlefs_, Aug 05 2010

%F a(n) = (n+2)!*Sum_{k=1..n-1} 1/((2*k+4)*(k+3)). - _Gary Detlefs_, Oct 09 2011

%F a(n) = (n+2)!*(1 + 3*(H(n+1) - H(n+2)))/6, where H(n) is the n-th harmonic number. - _Gary Detlefs_, Oct 09 2011

%F With offset = 0, e.g.f.: x/(1-x)^4. - _Geoffrey Critzer_, Aug 30 2013

%F From _Amiram Eldar_, May 06 2022: (Start)

%F Sum_{n>=2} 1/a(n) = 3*(Ei(1) - gamma) - 6*e + 27/2, where Ei(1) = A091725, gamma = A001620, and e = A001113.

%F Sum_{n>=2} (-1)^n/a(n) = 3*(gamma - Ei(-1)) - 3/2, where Ei(-1) = -A099285. (End)

%p [ seq((n-1)*(n+1)!/6,n=1..40) ];

%p a:=n->sum(sum(sum(n!/6, j=1..n),k=-1..n),m=0..n): seq(a(n), n=0..19); # _Zerinvary Lajos_, May 11 2007

%p seq(sum(mul(j,j=3..n), k=3..n)/3, n=2..21); # _Zerinvary Lajos_, Jun 01 2007

%p restart: G(x):=x^3/(1-x)^2: f[0]:=G(x): for n from 1 to 21 do f[n]:=diff(f[n-1],x) od: x:=0: seq(f[n]/3!,n=2..21); # _Zerinvary Lajos_, Apr 01 2009

%t Table[Sum[n!/6, {i, 3, n}], {n, 2, 21}] (* _Zerinvary Lajos_, Jul 12 2009 *)

%t Table[(n - 1) (n + 1)!/6, {n, 20}] (* _Harvey P. Dale_, Apr 07 2019 *)

%t Table[(n - 1) Pochhammer[4, n - 2], {n, 20}] (* _Eric W. Weisstein_, Jun 09 2019 *)

%t Table[(n - 1) Gamma[n + 2]/6, {n, 20}] (* _Eric W. Weisstein_, Jun 09 2019 *)

%t Range[0, 20]! CoefficientList[Series[x/(1 - x)^4, {x, 0, 20}], x] (* _Eric W. Weisstein_, Jun 09 2019 *)

%o (Magma) [(n-1)*Factorial(n+1)/6: n in [1..25]]; // _Vincenzo Librandi_, Oct 11 2011

%o (PARI) a(n)=(n-1)*(n+1)!/6 \\ _Charles R Greathouse IV_, May 24 2013

%Y Cf. A001715, A090672, A167568.

%Y Cf. A001113, A001620, A091725, A099285.

%K nonn,easy

%O 1,3

%A _N. J. A. Sloane_

%E Better definition from Robert Newstedt