%I #57 Jul 31 2022 20:54:14
%S 1,1,4,26,243,2992,45906,845287,18182926,447797646,12429760889,
%T 384055045002,13075708703910,486430792977001,19632714343389296,
%U 854503410602781782,39898063449977239323,1989371798838577172796,105503454201101084456182,5930110732782743218645271
%N Expansion of e.g.f.: LambertW(1-exp(x))/(1-exp(x)).
%C A simple grammar.
%C Also the number of transitive reflexive early confluent binary relations R on n labeled elements. Early confluency means that (xRy and xRz) implies (yRz or zRy) for all x, y, z.
%H Alois P. Heinz, <a href="/A052880/b052880.txt">Table of n, a(n) for n = 0..378</a>
%H INRIA Algorithms Project, <a href="http://ecs.inria.fr/services/structure?nbr=851">Encyclopedia of Combinatorial Structures 851</a>
%F a(n) = Sum_{k=0..n} Stirling2(n, k)*(k+1)^(k-1). - _Vladeta Jovovic_, Nov 12 2003
%F a(n) ~ sqrt(1+exp(1)) * n^(n-1) / (exp(n-1)*(log(1+exp(1))-1)^(n-1/2)). - _Vaclav Kotesovec_, Nov 27 2012
%F E.g.f. A(x) satisfies: A(x) = Sum_{n>=0} x^n/n! * Sum_{k=0..n} Stirling2(n,k) * A(x)^k. - _Paul D. Hanna_, Mar 09 2013
%F E.g.f. A(x) satisfies: A(x) = exp((exp(x) - 1)*A(x)). - _Ilya Gutkovskiy_, Apr 04 2019
%p spec := [S,{B=Set(Z,1 <= card),S=Set(C),C=Prod(B,S)},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
%p # second Maple program:
%p b:= proc(n, m) option remember; `if`(n=0,
%p (m+1)^(m-1), m*b(n-1, m)+b(n-1, m+1))
%p end:
%p a:= n-> b(n, 0):
%p seq(a(n), n=0..27); # _Alois P. Heinz_, Jul 15 2022
%t CoefficientList[Series[-LambertW[-E^x+1]/(E^x-1), {x, 0, 20}], x]* Range[0, 20]! (* _Vaclav Kotesovec_, Nov 27 2012 *)
%t f[0, _] = 1; f[k_, x_] := f[k, x] = Exp[Sum[x^m/m!*f[k-m, x], {m, 1, k}]];
%t (* b = A135302 *) b[0, 0] = 1; b[_, 0] = 0; b[n_, k_] := SeriesCoefficient[ f[k, x], {x, 0, n}]*n!;
%t a[n_] := b[n, n];
%t a /@ Range[0, 20] (* _Jean-François Alcover_, Oct 14 2019 *)
%o (PARI) {Stirling2(n, k)=n!*polcoeff(((exp(x+x*O(x^n))-1)^k)/k!, n)}
%o {a(n)=local(A=1+x); for(i=1, n, A=sum(m=0, n, sum(k=0, m, Stirling2(m, k)*(A+x*O(x^n))^k)*x^m/m!)); n!*polcoeff(A, n)} \\ _Paul D. Hanna_, Mar 09 2013
%o (PARI) x='x+O('x^30); Vec(serlaplace(-lambertw(-exp(x)+1)/(exp(x)-1))) \\ _G. C. Greubel_, Feb 19 2018
%Y Row sums of A135313.
%Y Main diagonal of A135302.
%Y Cf. A033917, A053763.
%K easy,nonn
%O 0,3
%A encyclopedia(AT)pommard.inria.fr, Jan 25 2000
%E Edited by _Alois P. Heinz_, Nov 21 2010