Fact-checked by Grok 2 weeks ago

Bell number

The Bell numbers form a sequence of positive integers in combinatorics, where the nth Bell number, denoted B_n, counts the total number of partitions of a set containing n distinct elements into nonempty unlabeled subsets. These numbers arise naturally in problems involving the division of objects into groups without regard to order or labeling of the groups themselves. Although named after the mathematician Eric Temple Bell, who analyzed them in a 1934 paper on partition polynomials, the sequence was first systematically studied by Srinivasa Ramanujan around 1904–1909 in his notebooks. The first few Bell numbers are B_0 = 1, B_1 = 1, B_2 = 2, B_3 = 5, B_4 = 15, B_5 = 52, B_6 = 203, and B_7 = 877, exhibiting rapid exponential growth thereafter. Combinatorially, B_n equals the sum of the Stirling numbers of the second kind S(n, k) over k = 0 to n, where S(n, k) counts the partitions into exactly k nonempty subsets. Bell numbers hold significant importance in enumerative combinatorics, as they also count the number of equivalence relations on an n-element set and appear in the generating function e^{e^x - 1} = \sum_{n=0}^\infty B_n \frac{x^n}{n!}. Additional representations include Dobiński's formula, B_n = \frac{1}{e} \sum_{k=0}^\infty \frac{k^n}{k!}, which connects them to expectations. Their study extends to applications in probability, for clustering algorithms, and , including rare prime instances like B_2 = 2, B_3 = 5, and the massive B_{2841} proven prime in 2004.

Definition and examples

Definition

In , the Bell number B_n denotes the total number of ways to a set with n elements into nonempty subsets. A S is a collection of nonempty subsets A_i \subseteq S such that \bigcup A_i = S and A_i \cap A_j = \emptyset for all i \neq j. For example, consider the set \{1, 2, 3\}. Its partitions are \{\{1,2,3\}\}, \{\{1\}, \{2,3\}\}, \{\{2\}, \{1,3\}\}, \{\{3\}, \{1,2\}\}, and \{\{1\}, \{2\}, \{3\}\}, yielding B_3 = 5. The Bell numbers satisfy the explicit formula B_n = \sum_{k=0}^n S(n,k), where S(n,k) is the of the second kind, which counts the number of partitions of an n-element set into exactly k nonempty subsets. By convention, B_0 = 1, corresponding to the single partition of the .

Initial values

The initial Bell numbers provide concrete illustrations of the sequence's values for small nonnegative integers n, starting from the . These numbers are obtained by systematically enumerating the distinct ways to sets with n elements. The first Bell numbers, B_n for n = 0 to n = 15, are tabulated below to demonstrate their progression:
nB_n
01
11
22
35
415
552
6203
7877
84140
921147
10115975
11678570
124213597
1327644437
14190899322
151382958545
For example, B_3 = 5 counts the partitions of a three-element set into nonempty subsets. The sequence exhibits rapid , as evident from the jump from B_5 = 52 to B_{15} \approx 1.38 \times 10^9, underscoring the increasing complexity of partitioning larger sets.

Combinatorial interpretations

Set partitions

A set partition of a S with n is a collection of nonempty subsets of S that are pairwise disjoint and whose union is exactly S. These subsets, called blocks, group the of S into distinct, non-overlapping groups without leaving any unassigned. The Bell number B_n counts the total number of such for any n-element set. There exists a natural bijection between the set partitions of S and the equivalence relations on S. Specifically, given an equivalence relation \sim on S, the equivalence classes—sets of elements deemed equivalent under \sim—form a partition of S, with each class as a block. Conversely, any partition of S defines an equivalence relation where two elements are equivalent if and only if they belong to the same block. This correspondence highlights the structural equivalence between partitioning and relational grouping in set theory. The number of set partitions of an n-element set into exactly k blocks is given by the Stirling number of the second kind S(n,k), so B_n = \sum_{k=1}^n S(n,k). This partition perspective connects directly to surjective functions: the number of surjective (onto) functions from an n-element set to a k-element set is k! \, S(n,k), as each such function assigns elements to k labeled targets exhaustively, with the preimages forming an unordered partition into k blocks that can then be labeled in k! ways. Thus, while surjections emphasize ordered codomains, the underlying structure reverts to the unordered blocks of set partitions, underscoring the primacy of the partition interpretation for Bell numbers. To illustrate, consider the set S = \{1, 2, 3, 4\}, for which B_4 = 15. The partitions can be grouped by the number of blocks k:
  • For k=1: 1 partition
    \{\{1,2,3,4\}\}
  • For k=2: 7 partitions
    • One triple and one singleton (4 partitions):
      \{\{1,2,3\},\{4\}\}, \{\{1,2,4\},\{3\}\}, \{\{1,3,4\},\{2\}\}, \{\{2,3,4\},\{1\}\}
    • Two doubletons (3 partitions):
      \{\{1,2\},\{3,4\}\}, \{\{1,3\},\{2,4\}\}, \{\{1,4\},\{2,3\}\}
  • For k=3: 6 partitions (each consisting of one doubleton and two singletons):
    \{\{1,2\},\{3\},\{4\}\}, \{\{1,3\},\{2\},\{4\}\}, \{\{1,4\},\{2\},\{3\}\},
    \{\{2,3\},\{1\},\{4\}\}, \{\{2,4\},\{1\},\{3\}\}, \{\{3,4\},\{1\},\{2\}\}
  • For k=4: 1 partition
    \{\{1\},\{2\},\{3\},\{4\}\}
This enumeration demonstrates how the partitions grow combinatorially, with the Stirling numbers S(4,1)=1, S(4,2)=7, S(4,3)=6, S(4,4)=1 summing to B_4=15.

Rhyme schemes

In poetry, a rhyme scheme specifies the pattern of end rhymes across the lines of a stanza, effectively partitioning the set of n lines into subsets where lines within each subset share the same rhyme sound. This combinatorial structure aligns directly with the enumeration provided by Bell numbers, as each possible partitioning corresponds to a distinct rhyme scheme. For a two-line stanza, the Bell number B_2 = 2 counts the schemes AA (both lines rhyme) and AB (lines rhyme differently). With three lines, B_3 = 5 yields the schemes AAA (all rhyme), AAB (first two rhyme, third differs), ABA (first and third rhyme), ABB (last two rhyme), and ABC (all distinct). This mapping mirrors the set partitions interpretation, where each block of the partition represents a group of lines assigned to the same rhyme sound, and distinct labels (such as A, B, C) differentiate the sounds across blocks. As explored in the preceding section on set partitions, the total count of such configurations for n lines is the nth Bell number. The application of Bell numbers has been utilized in and to systematically classify structures and explore patterns in verse composition.

Factorizations

The Bell number B_n provides a combinatorial interpretation in by counting the number of unordered factorizations of a square-free positive with exactly n distinct prime factors into integers greater than 1. A is one that is not divisible by any other than 1, meaning its prime consists of distinct primes raised to . For such an m = p_1 p_2 \cdots p_n, where p_i are distinct primes, an unordered is a way to write m as a product f_1 f_2 \cdots f_k with each f_j > 1 and the order of the factors disregarded. The total number of such factorizations equals B_n, as each factorization corresponds uniquely to a of the set \{p_1, p_2, \dots, p_n\} into non-empty subsets, where each subset's product forms one factor f_j. This arises because grouping the primes into subsets mirrors the structure of set : singleton subsets yield prime factors, while larger subsets yield composite factors from their products. For instance, the trivial partition into one block gives the single-factor representation m itself, while the partition into n singletons gives the full prime . Since the factors are unordered, different permutations of the same grouping do not count as distinct, aligning precisely with the unordered nature of set counted by B_n. To illustrate, consider n = 1: Let m = 2. There is only one : $2. This matches B_1 = 1. For n = 2: Let m = 6 = 2 \times 3. The factorizations are $6 (primes together) and $2 \times 3 (primes separate), giving 2 ways, matching B_2 = 2. For n = 3: Let m = 30 = 2 \times 3 \times 5. The factorizations are:
  • $30 (all primes together),
  • $6 \times 5, $10 \times 3, $15 \times 2 (one pair and one singleton),
  • $2 \times 3 \times 5 (all separate).
This yields 5 distinct unordered factorizations, matching B_3 = 5. For n = 4: With m = 210 = 2 \times 3 \times 5 \times 7, the 15 factorizations correspond to the 15 partitions of a 4-element set, such as $210, composites like $6 \times 35, $2 \times 105, triples like $2 \times 3 \times 35, and so on. This interpretation highlights the deep connection between additive partitioning of sets and multiplicative structures in integers, though it applies specifically to square-free cases; for non-square-free integers, the count involves more complex partitioning of exponent multisets, generalizing beyond plain Bell numbers.

Permutations

The Bell number B_n enumerates the permutations of the set = \{1, 2, \dots, n\} that avoid the generalized pattern $1\mathbin{-}23. In generalized pattern avoidance, the notation $1\mathbin{-}23 specifies an occurrence as indices i < j < j+1 \leq n in a permutation \pi where \pi(i) < \pi(j) < \pi(j+1), meaning an earlier entry smaller than an adjacent increasing pair later in the sequence. Thus, $1\mathbin{-}23-avoiding permutations are those with no such configuration, ensuring that every adjacent ascent is either at the start or lacks a smaller preceding value. This interpretation aligns with the known values of Bell numbers for small n. For n=1, the single permutation (1) avoids the pattern. For n=2, both $12 and $21 avoid it, as no valid triple exists. For n=3, the avoiding permutations are $132, $213, $231, $312, and $321; the permutation $123 contains an occurrence at positions $1,2,3 since $1 < 2 < 3. This yields 5 permutations, matching B_3 = 5. A bijection maps these avoiding permutations to set partitions of $$ by interpreting the permutation's structure—specifically, its descents and ascents—as defining partition blocks in a canonical decreasing order within blocks, with the avoidance condition preserving the partition's integrity. This connection highlights the combinatorial equivalence between the two objects.

Computation methods

Recurrence relations

The Bell numbers satisfy the initial condition B_0 = 1 and the recurrence relation B_{n+1} = \sum_{k=0}^n \binom{n}{k} B_k for n \geq 0. This relation provides a direct method for iterative computation of successive Bell numbers from prior values. The recurrence follows from the combinatorial meaning of Bell numbers as the number of partitions of an (n+1)-element set S = \{1, 2, \dots, n+1\}. Consider the block containing the distinguished element n+1; this block includes n+1 together with some subset of k elements from \{1, 2, \dots, n\}, where $0 \leq k \leq n. There are \binom{n}{k} ways to choose this subset, and the remaining n - k elements can then be partitioned arbitrarily in B_{n-k} ways. Summing over all possible k and substituting j = n - k yields the given formula. To illustrate, the computation of B_4 (assuming prior values B_0 = 1, B_1 = 1, B_2 = 2, B_3 = 5) proceeds as B_4 = \sum_{k=0}^3 \binom{3}{k} B_k = \binom{3}{0} B_0 + \binom{3}{1} B_1 + \binom{3}{2} B_2 + \binom{3}{3} B_3 = 1 \cdot 1 + 3 \cdot 1 + 3 \cdot 2 + 1 \cdot 5 = 15. Similar steps yield higher terms, such as B_5 = 52. Although the recurrence enables computation via in O(n^2) time to obtain B_n (as each of the n steps requires O(n) additions), practical limits arise for large n due to the super-exponential growth of the numbers themselves, which exceed standard integer precision beyond n \approx 1000 without specialized .

Bell triangle

The Bell triangle, also known as Aitken's array or the Peirce triangle, is a triangular array of natural numbers that facilitates the computation of Bell numbers through successive additions, much like Pascal's triangle but with a shifted starting point for each row. The array is indexed by row number n \geq 0 and column index k = 0, 1, \dots, n, with entries denoted C(n,k). It begins with the single entry C(0,0) = 1. For n \geq 1, the first entry of each row is set to the last entry of the previous row: C(n,0) = C(n-1,n-1). Subsequent entries in the row are computed as C(n,k) = C(n,k-1) + C(n-1,k-1) for $1 \leq k \leq n. This construction directly yields the Bell numbers as the leftmost column C(n,0) = B_n for each n. The name "Bell triangle" refers to the Bell numbers appearing in the first column. The following table illustrates the first six rows (up to n=5) of the Bell triangle:
nk=0k=1k=2k=3k=4k=5
01
112
2235
3571015
41520273752
5526787114151203
Here, the Bell numbers B_0 = 1, B_1 = 1, B_2 = 2, B_3 = 5, B_4 = 15, and B_5 = 52 appear in the first column. The entries C(n,k) enumerate the number of partitions of a set of n+1 elements where the largest element belongs to a block of size k+1. The Bell triangle was independently discovered by several mathematicians, starting with in 1880, followed by in 1933. Its simple additive recurrence makes it advantageous for hand calculations of Bell numbers, as it requires only basic arithmetic operations without needing to compute or more intricate formulas, allowing quick extension to larger n compared to direct application of the underlying recurrence B_n = \sum_{k=0}^{n-1} \binom{n-1}{k} B_k. This tabular approach visually implements the combinatorial recurrence for set partitions in an iterative manner.

Mathematical properties

Generating functions

The exponential generating function for the Bell numbers B_n is given by G(x) = \sum_{n=0}^\infty B_n \frac{x^n}{n!} = e^{e^x - 1}. This closed-form expression arises from the combinatorial interpretation of Bell numbers as the number of partitions of an n-element set. To derive this, consider the exponential formula for labeled structures, which states that the exponential generating function for set partitions is the exponential of the generating function for the connected components (nonempty subsets). The exponential generating function for nonempty subsets of size n \geq 1 is \sum_{n=1}^\infty \frac{x^n}{n!} = e^x - 1, since each subset is a single block without further structure. Applying the exponential formula yields G(x) = e^{e^x - 1}, where the outer exponential accounts for the disjoint union of blocks forming the partition. Alternatively, the formula can be obtained from the recurrence B_n = \sum_{k=0}^{n-1} \binom{n-1}{k} B_k with B_0 = 1. Multiplying by x^n / n! and summing over n \geq 1 leads to the differential equation G'(x) = e^x G(x) with G(0) = 1, whose solution is G(x) = e^{e^x - 1}. The ordinary generating function \sum_{n=0}^\infty B_n x^n lacks a simple closed form but satisfies the functional equation B(x) = 1 + \frac{x}{1-x} B\left(\frac{x}{1-x}\right). This exponential generating function facilitates derivations of other identities, such as expressing the raw moments of a Poisson random variable with parameter \lambda = 1, where the nth moment equals B_n.

Summation formulas

One explicit summation formula for the Bell number B_n expresses it as the sum of the Stirling numbers of the second kind S(n,k) from k=0 to n: B_n = \sum_{k=0}^n S(n,k), where S(n,k) denotes the number of ways to partition an n-element set into exactly k nonempty unlabeled subsets. This relation follows directly from the combinatorial interpretation of Bell numbers as the total number of partitions of an n-element set, aggregating over all possible numbers of subsets. A well-known infinite summation formula, known as Dobiński's formula, provides another explicit expression: B_n = \frac{1}{e} \sum_{k=0}^\infty \frac{k^n}{k!}. This formula, first derived by Dobiński in 1877, arises from the exponential generating function for Bell numbers or through probabilistic arguments. One derivation interprets the sum as the nth factorial moment of a Poisson random variable with parameter 1, which equals B_n due to the connection between set partitions and the moments of this distribution. Numerical verification of Dobiński's formula holds for small values of n. For n=1, the sum is \frac{1}{e} (0^1/0! + 1^1/1! + 2^1/2! + 3^1/3! + \cdots) = \frac{1}{e} \cdot e = 1 = B_1. For n=2, it yields \frac{1}{e} (0 + 1 + 2/2 + 6/6 + 24/24 + \cdots) = 2 = B_2. For n=3, the partial sum up to k=10 approximates 5, matching B_3 = 5, with convergence improving for larger terms.

Asymptotic growth

The asymptotic growth of the Bell numbers B_n is characterized by a formula involving the , which provides a precise approximation for large n. Define r = W(n), the principal branch of the Lambert W function satisfying r e^r = n. Equivalently, let N = e^r, so that N \ln N = n. Then, B_n \sim \frac{N^n e^{N - n - 1}}{\sqrt{1 + \ln N}} as n \to \infty, with relative error O\left( \frac{(\ln n)^{1/2}}{n^{1/2}} \right). This expression captures the dominant behavior, where the term N^n reflects the rapid exponential growth modulated by the saddle point determined by the generating function. This asymptotic was originally derived by Moser and Wyman using a method based on the integral representation of the Bell numbers via the exponential generating function \sum_{n=0}^\infty B_n \frac{x^n}{n!} = e^{e^x - 1}, applying a saddle-point approximation around the point where the integrand achieves its maximum contribution. De Bruijn later refined the analysis, confirming the form through detailed expansion of the contour integral and error estimates. The Lambert W function emerges naturally as the solution to the transcendental equation defining the saddle point r, which asymptotically behaves as r \sim \ln n - \ln \ln n + o(1). Compared to the factorial n!, which grows as \sim \sqrt{2\pi n} (n/e)^n or roughly \exp(n \ln n - n + O(\ln n)), the Bell numbers exhibit faster growth: \ln B_n \sim n \ln n - n \ln \ln n - n + O(n / \ln n). This places B_n between single-exponential functions like a^n and fully double-exponential ones like \exp(c^n), highlighting their superexponential yet sub-double-exponential nature in combinatorial enumeration. For illustration, B_{10} = 115975 and the approximation yields a relative error below 1%, while for n=20, B_{20} \approx 5.17 \times 10^{13} with error under 0.1%.

Log-concavity

The sequence of normalized Bell numbers, a_n = \frac{B_n}{n!}, is log-concave, satisfying a_{n-1} a_{n+1} \leq a_n^2 for all n \geq 2, with equality holding only for small values of n. This property follows from the structure of the exponential generating function for the , \sum_{n=0}^\infty a_n x^n = e^{e^x - 1}, which preserves log-concavity through analytic continuation and coefficient extraction techniques. Alternatively, a proof can be sketched using the representation B_n = \sum_{k=0}^n S(n,k), where S(n,k) are the ; the log-concavity arises inductively from the recurrence relations and positivity of these coefficients. A stronger underlying property is the total positivity of the Stirling triangle, where all minors of the matrix with entries S(n,k) are positive. This total positivity, as established by Karlin, implies the log-concavity of each row \{S(n,k)\}_{k=0}^n via the theory of variation-diminishing transformations and Pólya frequency sequences. In turn, this row log-concavity contributes to the overall log-concavity of the normalized Bell sequence through summation and normalization. The log-concavity of \{a_n\} has implications for combinatorial inequalities, such as bounding partial sums of and establishing unimodality in related partition statistics, which are useful in asymptotic analysis and probabilistic models of set partitions. For instance, it facilitates for the coefficients of the generating function, providing tighter estimates on growth compared to crude asymptotic approximations.

Modular properties

The modular properties of have been studied extensively in number theory and combinatorics, particularly in relation to primes and the behavior of the sequence modulo p. A fundamental result is , which states that for any prime p and nonnegative integer n, B_{n+p} \equiv B_n + B_{n+1} \pmod{p}. This congruence, originally due to Jacques Touchard, allows recursive computation of Bell numbers modulo p and implies that the sequence {B_n \mod p} satisfies a linear recurrence of order 2 with periodic coefficients. As a consequence, B_p \equiv B_0 + B_1 = 2 \pmod{p}. The result follows from the explicit formula for Bell numbers in terms of Stirling numbers of the second kind and properties of falling factorials modulo p. Another important congruence relates Bell numbers to derangement numbers D_m modulo p. For a prime p, B_{p-1} \equiv D_{p-1} + 1 \pmod{p}. Derangement numbers count permutations without fixed points, and for primes p > 2, D_{p-1} \equiv -1 \pmod{p} in many cases, though exceptions occur for small p (e.g., p=3 where D_2 = 1 \not\equiv -1 \pmod{3}). This yields B_{p-1} \equiv 0 \pmod{p} for p=5 (B_4=15 \equiv 0) and p=7 (B_6=203 \equiv 0), but B_2=2 \equiv -1 \pmod{3} for p=3. The congruence arises from identities and evaluations at roots of unity modulo p. The sequence of Bell numbers modulo a prime p is purely periodic, with the minimal period dividing N_p = p^{p-1}/(p-1). Computations show that the minimal period equals N_p for all primes p < 126 and several larger ones (e.g., p=137,149). For small p, this yields short observable patterns, but the full period grows rapidly. Touchard's congruence facilitates verifying periodicity by checking alignment after shifts of length N_p. Known bounds indicate that the minimal period does not divide any proper divisor of N_p involving small prime factors q of N_p, confirmed computationally up to p < 1100. Examples for small primes illustrate these properties. The following table lists the first 12 Bell numbers modulo 2, 3, 5, and 7:
nB_n mod 2B_n mod 3B_n mod 5B_n mod 7
01111
11111
20222
31205
41001
50123
61230
71122
80003
91020
101106
110004
Modulo 2, the sequence has minimal period 3 (1,1,0 repeating). Modulo 3, no short period is evident in the initial terms, consistent with N_3=4 but actual period larger. For p=5, B_4 \equiv 0 as predicted; for p=7, B_6 \equiv 0. Bell numbers connect to modular properties of S(n,k), since B_n = \sum_{k=0}^n S(n,k). For prime p and 1 < k < p, S(p,k) \equiv 0 \pmod{p}, implying B_p \equiv 2 \pmod{p} as noted earlier. More generally, explicit congruences for S(n,k) mod p^m (p odd prime) express them in terms of , e.g., S(n, a p^m) \equiv 0 \pmod{p^m} unless n \equiv a \pmod{p-1}, in which case it equals p^m \left( \binom{n - a p^m -1}{p-1} - 1 \right) \pmod{p^{m+1}}. These yield refined modular behaviors for sums forming B_n, particularly for composite moduli via .

Integral representations

The exponential generating function for the Bell numbers is G(z) = e^{e^z - 1} = \sum_{n=0}^\infty B_n \frac{z^n}{n!}. Applying to extract the coefficient of z^n / n! yields the contour integral representation B_n = \frac{n!}{2\pi i} \oint_C \frac{e^{e^z - 1}}{z^{n+1}} \, dz, where C is any simple closed contour in the complex plane that encircles the origin positively and lies within the disk of analyticity of the integrand. This representation plays a central role in analytic combinatorics, where it facilitates asymptotic analysis of B_n via techniques such as saddle-point integration, revealing the dominant growth behavior given by the asymptotic expansion in the previous subsection. A remarkable real integral representation, discovered by Ernesto Cesàro in 1885 and later corrected for a missing factorial factor, is B_n = \frac{2 n!}{\pi e} \Im \left( \int_0^\pi e^{e^{i\theta}} \sin(n \theta) \, d\theta \right) for n \geq 1. This formula stems from expressing Bell numbers in terms of and exploiting the orthogonality of the sine functions over [0, \pi]. An equivalent fully real form expands the complex exponential: B_n = \frac{2 n!}{\pi e} \int_0^\pi e^{\cos \theta} \sin \left( e^{\cos \theta} \sin(\sin \theta) + n \theta \right) \, d\theta. Both variants enable numerical evaluation of B_n and have been verified computationally for small n, such as B_1 = 1, B_2 = 2, and B_3 = 5.

Applications and variants

Probability distributions

The Bell numbers arise naturally in the study of moments for the Poisson distribution. Specifically, if K is a Poisson random variable with mean parameter 1, then the nth raw \mathbb{E}[K^n] equals the nth Bell number B_n. This equivalence follows from Dobiński's formula, which expresses B_n = e^{-1} \sum_{k=0}^\infty \frac{k^n}{k!}, precisely the form of the expectation \mathbb{E}[K^n] = \sum_{k=0}^\infty k^n \Pr(K = k) under the Poisson(1) probability mass function \Pr(K = k) = e^{-1} k!^{-1}. This connection generalizes through the Touchard polynomials, defined as T_n(\lambda) = \sum_{k=0}^n S(n,k) \lambda^k, where S(n,k) are the Stirling numbers of the second kind. For a random variable X with mean parameter \lambda > 0, the nth raw moment is \mathbb{E}[X^n] = T_n(\lambda), so B_n = T_n(1). The provides a direct way to derive these moments. For K \sim \mathrm{[Poisson](/page/Poisson)}(1), the mgf is M(t) = \mathbb{E}[e^{tK}] = \exp(e^t - 1). The nth raw moment is then the nth of M(t) evaluated at t = 0, which yields B_n. Equivalently, the generating function for the Touchard polynomials is \sum_{n=0}^\infty T_n(\lambda) \frac{t^n}{n!} = e^{\lambda (e^t - 1)}, aligning with the mgf scaled by the factorial moments. For illustration, consider small values of n: when n=1, B_1 = 1 = \mathbb{E}[K]; for n=2, B_2 = 2 = \mathbb{E}[K^2] = \mathrm{Var}(K) + (\mathbb{E}[K])^2 = 1 + 1; and for n=3, B_3 = 5 = \mathbb{E}[K^3], computed via the mgf or Touchard expansion T_3(1) = 1 + 3 \cdot 1 + 1 = 5. These examples highlight how the combinatorial structure of Bell numbers captures the higher-order moments of the Poisson(1) distribution.

Bell primes

A Bell prime is defined as a Bell number B_n that is also a . The smallest such primes occur for small indices: B_2 = 2, B_3 = 5, and B_7 = 877. Further examples include B_{13} = 27{,}644{,}437, which was verified as prime using advanced primality testing algorithms. Larger Bell primes are exceedingly rare due to the rapid, double-exponential growth of Bell numbers, which makes them susceptible to despite their size. The known indices n where B_n is prime are 2, 3, 7, , 42, , and 2841, with B_{42} (38 digits) and B_{55} (54 digits) having values exceeding $10^{30}, and B_{2841} having 6,539 digits. The primality of B_{2841} was certified using the software, a deterministic primality prover capable of handling massive integers. Checking primality for large Bell numbers typically involves probabilistic tests such as the for initial screening, followed by deterministic methods like the or specialized provers for confirmation. Modular properties of Bell numbers can occasionally aid in identifying factors for smaller composite cases, though this is less effective for enormous primes like B_{2841}. No additional Bell primes have been identified beyond n=2841 as of November 2025, underscoring their scarcity.

Historical development

Early computations

Even earlier, in 1321, the Kamāl al-Dīn al-Fārisī listed Bell numbers up to B_8 in a work on astronomy, predating both and European efforts. In the , Yoshisuke Matsunaga (1694?–1744) made significant early contributions to the computation of Bell numbers during the , motivated by problems in Genjikō , a traditional game involving arrangements of stones. In his 1726 manuscript Danren Sōjutsu, Matsunaga developed a method using what are now known as Matsunaga numbers (related to signed Stirling numbers of the first kind) to calculate Bell numbers via the relation B_n = 1 + \frac{1}{n!} \sum_{k=1}^n M_{n,k} n^k, where M_{n,k} are the Matsunaga numbers. He computed values up to B_8 = 4140, including B_2 = 2, B_3 = 5, B_4 = 15, B_5 = 52, B_6 = 203, B_7 = 877, employing tabular methods and Horner's rule for efficiency. Matsunaga's work remained unpublished during his lifetime, but it was extended and popularized by Yoriyuki (1714–1783) in his 1763 book Danren Henkyokuhō. Arima refined the recurrence to B_n = \sum_k \binom{n-1}{k} B_{n-1-k} and computed Bell numbers up to B_{13} = 27644437, solving for B_{11} = 678570 in a 1769 problem from Shūki Sanpō. These calculations predated known European efforts and were part of the Wasan tradition, linking set partitions to combinatorial games without explicit recognition of the numbers' broader significance. In , sequences of Bell numbers appeared as early as by Christian Kramp, with further listings in works like Whitworth's 1870 Choice and Chance in the context of partitions, though without a general formula. In 1877, Gustaw Dobiński provided the first explicit formula, B_n = \frac{1}{e} \sum_{k=0}^\infty \frac{k^n}{k!}, enabling computations beyond small n. A key advancement came in 1880 when American philosopher and mathematician independently discovered the Bell triangle (also known as the Peirce triangle), a recursive array for computing Bell numbers displaying the of the second kind S(n,k), where each entry satisfies S(n,k) = S(n-1,k-1) + k \, S(n-1,k), with S(n,0) = 0, S(0,k) = 0 for k > 0, S(0,0) = 1, and the row sums giving the Bell numbers. Peirce used this in his algebraic logic framework to enumerate logical associations, computing values up to at least B_{10} = 115975. The triangle provided an efficient tabular method, akin to , for generating the sequence:
RowEntries (partial)Bell Number (sum)
011
111
21 12
31 3 15
41 7 6 115
51 15 25 10 152
This structure facilitated manual computations up to moderate n without advanced tools.

Modern recognition

In the early 20th century, systematically studied what are now recognized as Bell numbers in Chapter 3 of his second notebook, recorded around 1910–1914, focusing on their connections to integer partitions. These entries were analyzed and published posthumously in the mid-20th century, providing some of the earliest extensive explorations of their combinatorial properties. Eric Temple Bell significantly advanced the understanding of these numbers through his 1934 paper on exponential polynomials, where he introduced generalizations now known as and highlighted their role in . Building on this, Bell's 1938 work further popularized the sequence, leading to its naming in his honor despite prior contributions from mathematicians like Ramanujan. The eponymous "Bell numbers" thus reflect Bell's influence in formalizing and disseminating the topic within Western mathematical literature. Following , key developments included greater recognition of Dobiński's 1877 formula for Bell numbers, which expressed them via an infinite series involving Poisson-distributed terms and became a standard tool in asymptotic and probabilistic analyses. Concurrently, N. G. de Bruijn provided influential asymptotic approximations for the growth of Bell numbers in his 1958 book Asymptotic Methods in Analysis, enabling precise estimates of their rapid exponential increase. In more recent work, Martin Klazar proved in 2003 that the ordinary generating function for Bell numbers satisfies no algebraic over the field of rational functions, underscoring their transcendental nature and limiting certain analytic approaches. This result has been confirmed and extended in subsequent studies up to 2025. Additionally, a 2021 paper has brought attention to underappreciated 18th-century Japanese computations of Bell numbers by Yoshisuke Matsunaga and others.

References

  1. [1]
    Bell Number -- from Wolfram MathWorld
    The number of ways a set of n elements can be partitioned into nonempty subsets is called a Bell number and is denoted B_n.Missing: significance | Show results with:significance
  2. [2]
    A000110 - OEIS
    ### Extracted Bell Numbers (B_n for n=0 to 19)
  3. [3]
    1.4 Bell numbers
    Bell numbers (Bn) denote the number of partitions of an n-element set. They grow exponentially fast, with the first few being 1, 1, 2, 5, 15, 52, 203, 877, ...Missing: history properties
  4. [4]
    Bell Numbers - Discrete Mathematics - An Open Introduction
    Bell numbers (Bk) count ways to partition k objects into nonempty subsets. They are also related to Stirling numbers and used in prime-number theory.Missing: history significance
  5. [5]
    C. S. Peirce and the Bell Numbers - jstor
    Since we can always represent a partition as a rhyme scheme and vice versa, we see that the Bell number Bn is both the number of partitions of an n-membered set ...Missing: poetry analysis linguistics
  6. [6]
    [PDF] arXiv:0807.0986v1 [math.NT] 7 Jul 2008
    Jul 7, 2008 · Introduction. Let f(n) denote the number of distinct unordered factorisations of the natural number n into factors larger than 1.<|control11|><|separator|>
  7. [7]
    [PDF] Multiplicative partitions of numbers with a large squarefree divisor
    For instance, one can note that when n is squarefree with k prime factors, f(n) is the number of set partitions of a k-element set, i.e., the kth Bell number. A ...
  8. [8]
    Bell Triangle -- from Wolfram MathWorld
    The Bell triangle starts with 1, subsequent rows begin with the last number of the previous row, and rows are filled by adding the preceding column to the ...Missing: definition construction example
  9. [9]
    A011971 - OEIS
    ### Summary of A011971 (OEIS)
  10. [10]
    [PDF] MAT344 Week 10
    Nov 25, 2019 · k l . We can use Theorem 4.2 to find an exponential generating function for the Bell numbers. The objects are the partitions, and the ...<|control11|><|separator|>
  11. [11]
  12. [12]
    Bell numbers and exponential generating functions
    We will go through one example of a sequence for which exponential generating functions are useful: the Bell numbers.
  13. [13]
    Ordinary Generating Function for Bell Numbers - MathOverflow
    Jun 30, 2014 · This is identity 1.94c in the second edition of Stanley's Enumerative Combinatorics, Volume I. at least for suitably convergent f(x), and for ...
  14. [14]
    Given Bell numbers as moments, derive the Poisson distribution
    Dec 20, 2023 · The exponential Generating function for the bell numbers is: B(x)=eex−1. You may recognize this as the moment generating function for the ...Computing the exponential generating function of the Bell numbers.Bell numbers and moments of the Poisson distributionMore results from math.stackexchange.com
  15. [15]
    Dobiński's Formula -- from Wolfram MathWorld
    Dobiński's Formula ; B_n(x)=e^(-x)sum_(k=0. (1) ; B_n=1/esum_(k=0)^infty(k^n. (2) ; (m^n)/(m!)=sum_(k=1. (3) ; sum_(m=1)^infty(m^n)/(m. (4) ; sum_(k=1)^nS(n,k)lambda ...Missing: derivation source
  16. [16]
    [PDF] Some Probabilistic Aspects of Set Partitions - Jim Pitman
    Apr 23, 2003 · Formulae with binomial coefficients typically involve independent trials, while those with Stirling numbers of the first kind typically involve ...<|control11|><|separator|>
  17. [17]
    DLMF: §26.7 Set Partitions: Bell Numbers ‣ Properties ‣ Chapter ...
    §26.7(iv) Asymptotic Approximation​​ Notes: See de Bruijn (1961, pp. 104–108) and Olver (1997b, pp. 329–331) .
  18. [18]
    [PDF] An asymptotic formula for the Bell numbers - OEIS
    An Asymptotic Formula for the Bell Numbers. LEO MOSER and MAX WYMAN, F.R.S.C.. 1. Introduction. Properties of the Bell numbers G,, defined by. (1.1). G₁z. R-On ...
  19. [19]
    [PDF] Explicit bounds for Bell numbers and their ratios - arXiv
    Aug 27, 2024 · In this article, we provide a comprehensive analysis of the asymptotic behavior of Bell numbers, enhancing and unifying various results ...Missing: poetry linguistics
  20. [20]
    [PDF] Log-concavity of stirling numbers and unimodality of stirling ...
    Each of the first and second kinds of Stirling numbers forms a triangular array, which is totally positive 2 (Karlin (1968)) as a function of two indices.
  21. [21]
    [PDF] ON A CURIOUS PROPERTY OF BELL NUMBERS
    In this paper we derive congruences expressing Bell numbers and derangement numbers in terms of each other modulo any prime. 2010 Mathematics subject ...
  22. [22]
    the period of the bell numbers modulo a prime
    Mar 1, 2010 · We discuss the numbers in the title, and in particular whether the minimum period of the Bell numbers modulo a prime p can be a proper divisor.
  23. [23]
    [PDF] Congruences for Stirling Numbers of the Second Kind - O-Yeat Chan
    Nov 9, 2009 · We easily obtain the congruences for Stirling numbers modulo odd prime powers. Theorem 5.2. Let p be an odd prime and let n, a, m be positive ...
  24. [24]
    Cesaro's integral formula for the Bell numbers (corrected) - arXiv
    Aug 24, 2007 · Cesaro (1885) gave a quite remarkable expression for the Bell number --the number of partitions of an n-element set -- as a definite integral.Missing: representation | Show results with:representation
  25. [25]
    [PDF] Combinatorics of Poisson stochastic integrals with random integrands
    i.e. the n-th Poisson moment with intensity parameter λ > 0 is given by Tn(λ) where. Tn is the Touchard polynomial of degree n. In the case of centered Poisson ...
  26. [26]
    [2312.00704] Moments of the Poisson distribution of order $k$ - arXiv
    Dec 1, 2023 · The present note presents a recurrence relation and an explicit combinatorial sum for the raw moments of the Poisson distribution of order k.
  27. [27]
    A051130 - OEIS
    The OEIS is supported by the many generous donors to the OEIS Foundation. A051130 - OEIS · Hints. (Greetings from The On-Line Encyclopedia of Integer Sequences ...
  28. [28]
    Chapter 3 of Ramanujan's second notebook - ScienceDirect.com
    G.E Andrews. The Theory of Partitions. Addison-Wesley, Reading, Mass (1976) ... 16. L Carlitz. Some remarks on the Bell numbers. Fibonacci Quart., 18 (1980) ...
  29. [29]
    Bell numbers in Matsunaga's and Arima's Genjikō combinatorics
    Oct 4, 2021 · We examine and clarify in detail the contributions of Yoshisuke Matsunaga (1694?--1744) to the computation of Bell numbers in the eighteenth century.