cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A134432 Sum of entries in all the arrangements of the set {1,2,...,n} (to n=0 there corresponds the empty set).

Original entry on oeis.org

0, 1, 9, 66, 490, 3915, 34251, 328804, 3452436, 39456405, 488273005, 6510306726, 93097386174, 1421850988831, 23105078568495, 398118276872520, 7251440043035176, 139227648826275369, 2810658160680434001, 59519819873232720010, 1319356007189991960210
Offset: 0

Views

Author

Emeric Deutsch, Nov 16 2007

Keywords

Comments

Appears to be the binomial transform of A001286 (filled with the appropriate two leading zeros), shifted one index left. - R. J. Mathar, Apr 04 2012

Examples

			a(2)=9 because the arrangements of {1,2} are (empty), 1, 2, 12 and 21.
		

Crossrefs

Programs

  • Magma
    [Binomial(n+1,2)*(&+[Factorial(j)*Binomial(n-1, j-1): j in [0..n]]): n in [0..30]]; // G. C. Greubel, Jan 09 2022
    
  • Maple
    Q[0]:=1: for n to 17 do Q[n]:=sort(simplify(Q[n-1]+t^n*x*(diff(x*Q[n-1], x))), t) end do: for n from 0 to 17 do P[n]:=sort(subs(x=1,Q[n])) end do: seq(subs(t =1,diff(P[n],t)),n=0..17);
    # second Maple program:
    b:= proc(n, t) option remember; `if`(n=0, [t!, 0],
          b(n-1, t)+(p-> p+[0, n*p[1]])(b(n-1, t+1)))
        end:
    a:= n-> b(n, 0)[2]:
    seq(a(n), n=0..23);  # Alois P. Heinz, Feb 19 2020
  • Mathematica
    (* First program *)
    b[n_, s_, t_]:= b[n, s, t] = If[n==0, t! x^s, b[n-1, s, t] + b[n-1, s+n, t+1]];
    T[n_]:= T[n]= Function[p, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]] @ b[n, 0, 0];
    a[n_] := Sum[k T[n][[k+1]], {k, 0, n(n+1)/2}];
    a /@ Range[0, 20] (* Jean-François Alcover, Feb 19 2020, after Alois P. Heinz *)
    (* Second program *)
    a[n_]:= ((n+1)/2)*Sum[j*j!*Binomial[n,j], {j,0,n}];
    Table[a[n], {n, 0, 30}] (* G. C. Greubel, Jan 09 2022 *)
  • Sage
    [((n+1)/2)*sum( j*factorial(j)*binomial(n, j) for j in (0..n) ) for n in (0..30)] # G. C. Greubel, Jan 09 2022

Formula

a(n) = Sum_{k=0..n*(n+1)/2} k*A134431(n,k).
a(n) = (d/dt)P[n](t) evaluated at t=1; here P[n](t)=Q[n](t,1) where the polynomials Q[n](t,x) are defined by Q[0]=1 and Q[n]=Q[n-1] + xt^n (d/dx)xQ[n-1]. (Q[n](t,x) is the bivariate generating polynomial of the arrangements of {1,2,...,n}, where t (x) marks the sum (number) of the entries; for example, Q[2](t,x) = 1 + tx + t^2*x + 2t^3*x^2, corresponding to: empty, 1, 2, 12 and 21, respectively.)
E.g.f.: exp(x)*x*(2 + x - x^2) / (2*(1 - x)^3). - Ilya Gutkovskiy, Jun 02 2020
From G. C. Greubel, Jan 09 2022: (Start)
a(n) = A271705(n+1, 2).
a(n) = ((n+1)/2) * Sum_{j=0..n} j * j! * binomial(n, j).
a(n) = (1/n!)*binomial(n+1, 2) * Sum_{j=0..n} (j!)^2 * A271703(n, j). (End)
D-finite with recurrence (-n+1)*a(n) +(n+1)^2*a(n-1) -n*(n+1)*a(n-2)=0. - R. J. Mathar, Jul 26 2022

Extensions

More terms from Alois P. Heinz, Dec 22 2017