A261280 Number of ways to start with set {1,2,...,n} and then repeat n times: partition each set into subsets.
1, 1, 3, 22, 315, 7556, 274778, 14140722, 979687005, 87998832685, 9951699489061, 1384060090903535, 232230523534594676, 46265730933522733556, 10797461309089628151462, 2918087323005280354349508, 904185772556792011572372117, 318432010852077710049833537040
Offset: 0
Keywords
Examples
a(2) = 3: 12->12->12, 12->12->1|2, 12->1|2->1|2. a(3) = 22: 123->123->123->123, 123->123->123->12|3, 123->123->123->1|23, 123->123->123->13|2, 123->123->123->1|2|3, 123->123->12|3->12|3, 123->123->12|3->1|2|3, 123->123->1|23->1|23, 123->123->1|23->1|2|3, 123->123->13|2->13|2, 123->123->13|2->1|2|3, 123->123->1|2|3->1|2|3, 123->12|3->12|3->12|3, 123->12|3->12|3->1|2|3, 123->12|3->1|2|3->1|2|3, 123->1|23->1|23->1|23, 123->1|23->1|23->1|2|3, 123->1|23->1|2|3->1|2|3, 123->13|2->13|2->13|2, 123->13|2->13|2->1|2|3, 123->13|2->1|2|3->1|2|3, 123->1|2|3->1|2|3->1|2|3.
Links
- Alois P. Heinz, Table of n, a(n) for n = 0..247
Programs
-
Maple
g:= x-> exp(x)-1: egf:= k-> 1+(g@@(k+1))(x): a:= n-> n! * coeff(series(egf(n), x, n+1), x, n): seq(a(n), n=0..20); # second Maple program: A:= proc(n, k) option remember; `if`(n=0 or k=0, 1, add(binomial(n-1, j-1)*A(j, k-1)*A(n-j, k), j=1..n)) end: a:= n-> A(n$2): seq(a(n), n=0..20); # third Maple program: b:= proc(n, t, m) option remember; `if`(t=0, 1, `if`(n=0, b(m, t-1, 0), m*b(n-1, t, m)+b(n-1, t, m+1))) end: a:= n-> b(n$2, 0): seq(a(n), n=0..20); # Alois P. Heinz, Aug 04 2021
-
Mathematica
Clear[t]; t[n_, k_]:=t[n, k] = If[n==0 || k==0, 1, Sum[Binomial[n-1, j-1]*t[j, k-1]*t[n-j, k], {j, 1, n}]]; Table[t[n, n], {n, 0, 20}] (* Vaclav Kotesovec, Aug 14 2015 after Alois P. Heinz *)
-
Python
from sympy.core.cache import cacheit from sympy import binomial @cacheit def A(n, k): return 1 if n==0 or k==0 else sum(binomial(n - 1, j - 1)*A(j, k - 1)*A(n - j, k) for j in range(1, n + 1)) def a(n): return A(n, n) print([a(n) for n in range(21)]) # Indranil Ghosh, Aug 07 2017
Formula
a(n) = n! * [x^n] 1 + g^(k+1)(x), where g(x) = exp(x)-1.
From Vaclav Kotesovec, Aug 14 2015: (Start)
Conjecture: a(n) ~ c * n^(2*n-5/6) / (2^(n-1) * exp(n)), where c = 7.7889...
a(n) ~ exp(1) * A139383(n).
(End)