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.

Showing 1-3 of 3 results.

A006153 E.g.f.: 1/(1-x*exp(x)).

Original entry on oeis.org

1, 1, 4, 21, 148, 1305, 13806, 170401, 2403640, 38143377, 672552730, 13044463641, 276003553860, 6326524990825, 156171026562838, 4130464801497105, 116526877671782896, 3492868475952497313, 110856698175372359346, 3713836169709782989993, 130966414749485504586940
Offset: 0

Views

Author

Keywords

Comments

a(n) is the sum of the row entries of triangle A199673, that is, a(n) is the number of ways to assign n people into labeled groups and then to assign a leader for each group from its members; see example below. - Dennis P. Walsh, Nov 15 2011
a(n) is the number of functions f:{1,2,...,n}->{1,2,...,n} (endofunctions) such that for some j>1, f^j=f where f^j denotes iterated functional composition. Equivalently, the number of endofunctions such that every element is mapped to a recurrent element. Equivalently, every vertex of the functional digraph is at a distance at most 1 from a cycle. - Geoffrey Critzer, Jan 21 2012
Numerators in rational approximations of Lambert W(1). See Ramanujan, Notebooks, volume 2, page 22: "2. If e^{-x} = x, shew that the convergents to x are 1/2, 4/7, 21/37, 148/261, &c." - Michael Somos, Jan 21 2019

Examples

			a(3) = 21 since there are 21 ways to assign 3 people into labeled groups with designated leaders. If there is one group, there are 3 ways to select a leader from the 3 people in the group. If there are two groups (group 1 and group 2), there are 6 ways to assign leaders and then 2 ways to select a group for the remaining person, and thus there are 12 assignments. If there are three groups (group1, group 2, and group3), each person is a leader of their singleton group, and there are 6 ways to assign the 3 people to the 3 groups. Hence a(3) = 3 + 12 + 6 = 21.
a(4) = 148 = 4 + 48 + 72 + 24.
		

References

  • S. Ramanujan, Notebooks, Tata Institute of Fundamental Research, Bombay 1957 Vol. 2, see page 22.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • R. P. Stanley, Enumerative Combinatorics, Cambridge, Vol. 2, 1999; see Problem 5.32(d).

Crossrefs

Row sums of triangle A199673.

Programs

  • Maple
    a := proc(n) local k; add(k^(n-k)*n!/(n-k)!,k=1..n); end; # for n >= 1
  • Mathematica
    With[{nn=20},CoefficientList[Series[1/(1-x Exp[x]),{x,0,nn}],x] Range[0,nn]!] (* Harvey P. Dale, Aug 29 2012 *)
    a[ n_] := If[n < 0, 0, n! + n! Sum[(n - k)^k / k!, {k, n}]]; (* Michael Somos, Jan 21 2019 *)
  • PARI
    x='x+O('x^66);
    egf=1/(1-x*exp(x)); /* = 1 + x + 2*x^2 + 7/2*x^3 + 37/6*x^4 + 87/8*x^5 +... */
    Vec(serlaplace(egf)) /* Joerg Arndt, Apr 30 2011 */
    
  • PARI
    {a(n) = if(n<0, 0, n! * sum(k=0, n, (n-k)^k / k!))}; /* Michael Somos, Jan 21 2019 */
    
  • Sage
    def A006153_list(len):
        f, R, C = 1, [1], [1]+[0]*(len-1)
        for n in (1..len-1):
            f *= n
            for k in range(n, 0, -1):
                C[k] = -C[k-1]*(1/(k-1) if k>1 else 1)
            C[0] = sum((-1)^k*C[k] for k in (1..n))
            R.append(C[0]*f)
        return R
    print(A006153_list(20)) # Peter Luschny, Feb 21 2016

Formula

a(n) = n! * Sum_{k=0..n}(n-k)^k/k!.
a(n) = Sum_{k=0..n} k!*k^(n-k)*binomial(n,k).
For n>=1, a(n-1) = b(n) where b(1)=1 and b(n) = Sum_{i=1..n-1} i*binomial(n-1, i)*b(i). - Benoit Cloitre, Nov 13 2004
a(n) = Sum_{k=1..n}A199673(n,k) = Sum_{k=1..n}n! k^(n-k)/(n-k)!. - Dennis P. Walsh, Nov 15 2011
E.g.f. for a(n), n>=1: x*e^x/(1-x*e^x). - Dennis P. Walsh, Nov 15 2011
a(n) ~ n! / ((1+LambertW(1))*LambertW(1)^n). - Vaclav Kotesovec, Jun 21 2013
O.g.f.: Sum_{n>=0} n! * x^n / (1 - n*x)^(n+1). - Paul D. Hanna, May 22 2018
a(0) = 1; a(n) = n * Sum_{k=0..n-1} binomial(n-1,k) * a(k). - Ilya Gutkovskiy, Jul 12 2020

Extensions

Definition corrected by Joerg Arndt, Apr 30 2011

A228534 Triangular array read by rows: T(n,k) is the number of functional digraphs on {1,2,...,n} such that every element is mapped to a recurrent element and there are exactly k cycles, n>=1, 1<=k<=n.

Original entry on oeis.org

1, 3, 1, 11, 9, 1, 58, 71, 18, 1, 409, 620, 245, 30, 1, 3606, 6274, 3255, 625, 45, 1, 38149, 73339, 45724, 11795, 1330, 63, 1, 470856, 977780, 697004, 221529, 33880, 2506, 84, 1, 6641793, 14678712, 11602394, 4309956, 823179, 82908, 4326, 108, 1
Offset: 1

Views

Author

Geoffrey Critzer, Aug 24 2013

Keywords

Comments

The Bell transform of (-1)^n*A009444(n+1). For the definition of the Bell transform see A264428. - Peter Luschny, Jan 18 2016

Examples

			       1;
       3,      1;
      11,      9,      1;
      58,     71,     18,      1;
     409,    620,    245,     30,     1;
    3606,   6274,   3255,    625,    45,    1;
   38149,  73339,  45724,  11795,  1330,   63,  1;
  470856, 977780, 697004, 221529, 33880, 2506, 84, 1;
		

Crossrefs

Row sums = A006153.
Column 1 = |A009444|.
Cf. A199673.

Programs

  • Maple
    # The function BellMatrix is defined in A264428.
    # Adds (1,0,0,0, ..) as column 0.
    g := n -> add(m^(n-m)*m!*binomial(n+1,m), m=1..n+1);
    BellMatrix(g, 9); # Peter Luschny, Jan 29 2016
  • Mathematica
    nn = 8; a = x Exp[x];
    Map[Select[#, # > 0 &] &,
      Drop[Range[0, nn]! CoefficientList[
         Series[1/(1 - a)^y, {x, 0, nn}], {x, y}], 1]] // Grid
    (* Second program: *)
    BellMatrix[f_, len_] := With[{t = Array[f, len, 0]}, Table[BellY[n, k, t], {n, 0, len - 1}, {k, 0, len - 1}]];
    B = BellMatrix[Function[n, (n+1)! Sum[m^(n-m)/(n-m+1)!, {m, 1, n+1}]], rows = 12];
    Table[B[[n, k]], {n, 2, rows}, {k, 2, n}] // Flatten (* Jean-François Alcover, Jun 28 2018, after Peter Luschny *)
  • Sage
    # uses[bell_matrix from A264428, A009444]
    # Adds a column 1,0,0,0, ... at the left side of the triangle.
    bell_matrix(lambda n: (-1)^n*A009444(n+1), 10) # Peter Luschny, Jan 18 2016

Formula

E.g.f.: 1/(1 - x*exp(x))^y.

A335311 Coefficients of polynomials arising in the series expansion of the multiplicative inverse of an analytic function. Irregular triangle read by rows.

Original entry on oeis.org

1, 1, 2, 2, 6, 12, 3, 24, 72, 24, 24, 4, 120, 480, 180, 360, 40, 120, 5, 720, 3600, 1440, 4320, 360, 2160, 720, 60, 240, 180, 6, 5040, 30240, 12600, 50400, 3360, 30240, 20160, 630, 5040, 3780, 7560, 84, 420, 840, 7
Offset: 0

Views

Author

Peter Luschny, May 31 2020

Keywords

Comments

The coefficients of Bell-type polynomials where the monomials correspond to integer partitions. The monomials are in graded lexicographic order with variables x[0] > x[1] > ... > x[n]. This means that monomials are compared first by their total degree, with ties broken by lexicographic order. (This is the monomial order of Maple after sorting.)

Examples

			The triangle starts (the refinement is indicated by square brackets):
[0]    1;
[1]    1;
[2]    2,     2;
[3]    6,    12,     3;
[4]   24,    72,    (24,    24),    4;
[5]  120,   480,   (180,   360),   (40,   120),     5;
[6]  720,  3600,  (1440,  4320),  (360,  2160,   720), (60,  240,  180),    6;
[7] 5040, 30240, (12600, 50400), (3360, 30240, 20160), (630, 5040, 3780, 7560), (84, 420, 840), 7;
[8] 40320, 282240, (120960, 604800), (33600, 403200, 403200), (6720, 80640, 60480,
241920, 40320), (1008, 10080, 20160, 20160, 30240), (112, 672, 1680, 1120), 8;
The multivariate polynomials start:
        1
        x[0]
      2*x[0]^2 +          2*x[1]
      6*x[0]^3 +    12*x[0]*x[1] +          3*x[2]
     24*x[0]^4 +  72*x[0]^2*x[1] +    24*x[0]*x[2] +       24*x[1]^2 +       4*x[3]
    120*x[0]^5 + 480*x[0]^3*x[1] + 180*x[0]^2*x[2] + 360*x[0]*x[1]^2 + 40*x[0]*x[3] + 120*x[1]*x[2] + 5*x[4]
		

Crossrefs

Cf. A199673 (row reversed refinement), A006153 (row sums), A000041 (length of rows), A182779 (different monomial order).

Programs

  • Maple
    A335311Triangle := proc(numrows) local ser, p, C, B, P;
    B(0) := 1; ser := series(1/B(s), s, numrows);
    C := [seq(expand(simplify(n!*coeff(ser,s,n))), n=0..numrows-1)]:
    P := subs(seq((D@@n)(B)(0)=n*x[n], n=1..numrows), C):
    for p in P do print(seq(abs(c), c=coeffs(sort(p)))) od end:
    A335311Triangle(8);
Showing 1-3 of 3 results.