A060281
Triangle T(n,k) read by rows giving number of labeled mappings (or functional digraphs) from n points to themselves (endofunctions) with exactly k cycles, k=1..n.
Original entry on oeis.org
1, 3, 1, 17, 9, 1, 142, 95, 18, 1, 1569, 1220, 305, 30, 1, 21576, 18694, 5595, 745, 45, 1, 355081, 334369, 113974, 18515, 1540, 63, 1, 6805296, 6852460, 2581964, 484729, 49840, 2842, 84, 1, 148869153, 158479488, 64727522, 13591116, 1632099, 116172, 4830, 108, 1
Offset: 1
Triangle T(n,k) begins:
1;
3, 1;
17, 9, 1;
142, 95, 18, 1;
1569, 1220, 305, 30, 1;
21576, 18694, 5595, 745, 45, 1;
355081, 334369, 113974, 18515, 1540, 63, 1;
6805296, 6852460, 2581964, 484729, 49840, 2842, 84, 1;
...
T(3,2)=9: (1,2,3)--> [(2,1,3),(3,2,1),(1,3,2),(1,1,3),(1,2,1), (1,2,2),(2,2,3),(3,2,3),(1,3,3)].
From _Peter Luschny_, Mar 03 2009: (Start)
Tree polynomials (with offset 0):
t_0(y) = 1;
t_1(y) = y;
t_2(y) = 3*y + y^2;
t_3(y) = 17*y + 9*y^2 + y^3; (End)
- I. P. Goulden and D. M. Jackson, Combinatorial Enumeration, Wiley, N.Y., 1983.
- W. Szpankowski. Average case analysis of algorithms on sequences. John Wiley & Sons, 2001. - Peter Luschny, Mar 03 2009
- Alois P. Heinz, Rows n = 1..141, flattened
- Julia Handl and Joshua Knowles, An Investigation of Representations and Operators for Evolutionary Data Clustering with a Variable Number of Clusters, in Parallel Problem Solving from Nature-PPSN IX, Lecture Notes in Computer Science, Volume 4193/2006, Springer-Verlag. [From _N. J. A. Sloane_, Jul 09 2009]
- D. E. Knuth, Convolution polynomials, The Mathematica J., 2 (1992), 67-78.
- D. E. Knuth and B. Pittel, A recurrence related to trees, Proceedings of the American Mathematical Society, 105(2):335-349, 1989. [From _Peter Luschny_, Mar 03 2009]
- J. Riordan, Enumeration of Linear Graphs for Mappings of Finite Sets, Ann. Math. Stat., 33, No. 1, Mar. 1962, pp. 178-185.
- David M. Smith and Geoffrey Smith, Tight Bounds on Information Leakage from Repeated Independent Runs, 2017 IEEE 30th Computer Security Foundations Symposium (CSF).
-
A060281:= func< n,k | (&+[Binomial(n-1,j)*n^(n-1-j)*(-1)^(k+j+1)*StirlingFirst(j+1,k): j in [0..n-1]]) >;
[A060281(n,k): k in [1..n], n in [1..12]]; // G. C. Greubel, Nov 06 2024
-
with(combinat):T:=array(1..8,1..8):for m from 1 to 8 do for p from 1 to m do T[m,p]:=sum(binomial(m-1,k)*m^(m-1-k)*(-1)^(p+k+1)*stirling1(k+1,p),k=0..m-1); print(T[m,p]) od od; # Len Smiley, Apr 03 2006
From Peter Luschny, Mar 03 2009: (Start)
T := z -> sum(n^(n-1)*z^n/n!,n=1..16):
p := convert(simplify(series((1-T(z))^(-y),z,12)),'polynom'):
seq(print(coeff(p,z,i)*i!),i=0..8); (End)
-
t=Sum[n^(n-1) x^n/n!,{n,1,10}];
Transpose[Table[Rest[Range[0, 10]! CoefficientList[Series[Log[1/(1 - t)]^n/n!, {x, 0, 10}], x]], {n,1,10}]]//Grid (* Geoffrey Critzer, Mar 13 2011*)
Table[k! SeriesCoefficient[1/(1 + ProductLog[-t])^x, {t, 0, k}, {x, 0, j}], {k, 10}, {j, k}] (* Jan Mangaldan, Mar 02 2013 *)
-
@CachedFunction
def A060281(n,k): return sum(binomial(n-1,j)*n^(n-1-j)*stirling_number1(j+1,k) for j in range(n))
flatten([[A060281(n,k) for k in range(1,n+1)] for n in range(1,13)]) # G. C. Greubel, Nov 06 2024
A209324
Triangular array read by rows: T(n,k) is the number of endofunctions f:{1,2,...,n}-> {1,2,...,n} whose largest component has exactly k nodes; n>=1, 1<=k<=n.
Original entry on oeis.org
1, 1, 3, 1, 9, 17, 1, 45, 68, 142, 1, 165, 680, 710, 1569, 1, 855, 6290, 8520, 9414, 21576, 1, 3843, 47600, 134190, 131796, 151032, 355081, 1, 21819, 481712, 1838900, 2372328, 2416512, 2840648, 6805296, 1, 114075, 5025608, 21488292, 50609664, 48934368, 51131664, 61247664, 148869153
Offset: 1
Triangle T(n,k) begins:
1;
1, 3;
1, 9, 17;
1, 45, 68, 142;
1, 165, 680, 710, 1569;
1, 855, 6290, 8520, 9414, 21576;
1, 3843, 47600, 134190, 131796, 151032, 355081;
1, 21819, 481712, 1838900, 2372328, 2416512, 2840648, 6805296;
...
- R. Sedgewick and P. Flajolet, Analysis of Algorithms, Addison Wesley, 1996, Chapter 8.
- Alois P. Heinz, Rows n = 1..141, flattened
- Steven Finch, Permute, Graph, Map, Derange, arXiv:2111.05720 [math.CO], 2021.
- D. Panario and B. Richmond, Exact largest and smallest size of components, Algorithmica, 31 (2001), 413-432.
-
g:= proc(n) option remember; add(n^(n-j)*(n-1)!/(n-j)!, j=1..n) end:
b:= proc(n, m) option remember; `if`(n=0, x^m, add(g(i)*
b(n-i, max(m, i))*binomial(n-1, i-1), i=1..n))
end:
T:= n-> (p-> seq(coeff(p, x, i), i=1..n))(b(n, 0)):
seq(T(n), n=1..12); # Alois P. Heinz, Dec 16 2021
-
nn=8;t=Sum[n^(n-1)x^n/n!,{n,1,nn}];c=Log[1/(1-t)];b=Drop[Range[0,nn]!CoefficientList[Series[c,{x,0,nn}],x],1];f[list_]:=Select[list,#>0&];Map[f,Drop[Transpose[Table[Range[0,nn]!CoefficientList[Series[ Exp[Sum[b[[i]]x^i/i!,{i,1,n+1}]]-Exp[Sum[b[[i]]x^i/i!,{i,1,n}]],{x,0,nn}],x],{n,0,nn-1}]],1]]//Grid
(* Second program: *)
g[n_] := g[n] = Sum[n^(n - j)*(n - 1)!/(n - j)!, {j, 1, n}];
b[n_, m_] := b[n, m] = If[n == 0, x^m, Sum[g[i]*b[n - i, Max[m, i]]* Binomial[n - 1, i - 1], {i, 1, n}]];
T[n_] := With[{p = b[n, 0]}, Table[Coefficient[p, x, i], {i, 1, n}]];
Table[T[n], {n, 1, 12}] // Flatten (* Jean-François Alcover, Dec 30 2021, after Alois P. Heinz *)
A350134
Number of endofunctions on [n] with at least one isolated fixed point.
Original entry on oeis.org
0, 1, 1, 10, 87, 1046, 15395, 269060, 5440463, 124902874, 3208994379, 91208536112, 2841279322871, 96258245162678, 3523457725743059, 138573785311560916, 5827414570508386335, 260928229315498155314, 12393729720071855683739, 622422708333615857463608
Offset: 0
a(3) = 10: 123, 122, 133, 132, 121, 323, 321, 113, 223, 213.
-
g:= proc(n) option remember; add(n^(n-j)*(n-1)!/(n-j)!, j=1..n) end:
b:= proc(n, t) option remember; `if`(n=0, t, add(g(i)*
b(n-i, `if`(i=1, 1, t))*binomial(n-1, i-1), i=1..n))
end:
a:= n-> b(n, 0):
seq(a(n), n=0..23);
-
g[n_] := g[n] = Sum[n^(n - j)*(n - 1)!/(n - j)!, {j, 1, n}];
b[n_, t_] := b[n, t] = If[n == 0, t, Sum[g[i]*
b[n - i, If[i == 1, 1, t]]*Binomial[n - 1, i - 1], {i, 1, n}]];
a[n_] := b[n, 0];
Table[a[n], {n, 0, 23}] (* Jean-François Alcover, Apr 27 2022, after Alois P. Heinz *)
A350157
Total number of nodes in the smallest connected component summed over all endofunctions on [n].
Original entry on oeis.org
0, 1, 7, 61, 709, 9911, 167111, 3237921, 71850913, 1780353439, 49100614399, 1482061739423, 48873720208853, 1740252983702871, 66793644836081827, 2740470162691675711, 120029057782404141841, 5575505641199441262767, 274412698693082818767335, 14236421024010426118259883
Offset: 0
a(2) = 7 = 2 + 2 + 1 + 2: 11, 22, 12, 21.
-
g:= proc(n) option remember; add(n^(n-j)*(n-1)!/(n-j)!, j=1..n) end:
b:= proc(n, m) option remember; `if`(n=0, x^m, add(
b(n-i, min(m, i))*g(i)*binomial(n-1, i-1), i=1..n))
end:
a:= n-> (p-> add(coeff(p, x, i)*i, i=0..n))(b(n,n)):
seq(a(n), n=0..23);
-
g[n_] := g[n] = Sum[n^(n - j)*(n - 1)!/(n - j)!, {j, 1, n}];
b[n_, m_] := b[n, m] = If[n == 0, x^m, Sum[
b[n - i, Min[m, i]]*g[i]*Binomial[n - 1, i - 1], {i, 1, n}]];
a[n_] := Function[p, Sum[Coefficient[p, x, i]*i, {i, 0, n}]][b[n, n]];
Table[a[n], {n, 0, 23}] (* Jean-François Alcover, Apr 27 2022, after Alois P. Heinz *)
A350135
Number of endofunctions on [2n] whose smallest connected component has size n.
Original entry on oeis.org
1, 1, 27, 2890, 705740, 310181886, 215071984512, 216357598418676, 298018065222408960, 538758820820128412790, 1237604585414359892787200, 3521561770316172974098259916, 12159265179096745219044911480832, 50086112147669900240287215353718700, 242646275221231775443338250567758643200
Offset: 0
-
a:= n-> `if`(n=0, 1, add(n^(n-j)*(n-1)!/(n-j)!, j=1..n)^2*binomial(2*n, n)/2):
seq(a(n), n=0..14);
Showing 1-5 of 5 results.
Comments