Documentation

Mathlib.Combinatorics.Enumerative.Bell

Bell numbers for multisets #

For n : ℕ, the nth Bell number is the number of partitions of a set of cardinality n. Here, we define a refinement of these numbers, that count, for any m : Multiset, the number of partitions of a set of cardinality m.sum whose parts have cardinalities given by m.

The definition presents it as a natural number.

TODO #

Prove that it actually counts the number of partitions as indicated. (When m contains 0, the result requires to admit repetitions of the empty set as a part.)

Number of partitions of a set of cardinality m.sum whose parts have cardinalities given by m

Equations
Instances For
    theorem Multiset.bell_mul_eq (m : Multiset ) :
    m.bell * (Multiset.map (fun (j : ) => j.factorial) m).prod * jm.toFinset.erase 0, (Multiset.count j m).factorial = m.sum.factorial
    theorem Multiset.bell_eq (m : Multiset ) :
    m.bell = m.sum.factorial / ((Multiset.map (fun (j : ) => j.factorial) m).prod * jm.toFinset.erase 0, (Multiset.count j m).factorial)
    def Nat.uniformBell (m n : ) :

    Number of possibilities of dividing a set with m * n elements into m groups of n-element subsets.

    Equations
    Instances For
      theorem Nat.uniformBell_eq (m n : ) :
      m.uniformBell n = pFinset.range m, (p * n + n - 1).choose (n - 1)
      theorem Nat.uniformBell_zero_right (m : ) :
      m.uniformBell 0 = 1
      theorem Nat.uniformBell_succ_left (m n : ) :
      (m + 1).uniformBell n = (m * n + n - 1).choose (n - 1) * m.uniformBell n
      theorem Nat.uniformBell_one_right (m : ) :
      m.uniformBell 1 = 1
      theorem Nat.uniformBell_mul_eq (m : ) {n : } (hn : n 0) :
      m.uniformBell n * n.factorial ^ m * m.factorial = (m * n).factorial
      theorem Nat.uniformBell_eq_div (m : ) {n : } (hn : n 0) :
      m.uniformBell n = (m * n).factorial / (n.factorial ^ m * m.factorial)