Enumerative Combinatorics: Class Notes

Total Page:16

File Type:pdf, Size:1020Kb

Enumerative Combinatorics: Class Notes Enumerative Combinatorics: class notes Darij Grinberg May 4, 2021 (unfinished!) Status: Chapters 1 and 2 finished; Chapter 3 outlined. Contents 1. Introduction7 1.1. Domino tilings . .8 1.1.1. The problem . .8 1.1.2. The odd-by-odd case and the sum rule . 12 1.1.3. The symmetry and the bijection rule . 14 1.1.4. The m = 1 case . 18 1.1.5. The m = 2 case and Fibonacci numbers . 19 1.1.6. Kasteleyn’s formula (teaser) . 26 1.1.7. Axisymmetric domino tilings . 28 1.1.8. Tiling rectangles with k-bricks . 31 1.2. Sums of powers . 38 1.2.1. The sum 1 + 2 + ... + n ....................... 38 1.2.2. What is a sum, actually? . 42 1.2.3. Rules for sums . 48 1.2.4. While at that, what is a finite product? . 53 1.2.5. The sums 1k + 2k + ... + nk .................... 54 1.3. Factorials and binomial coefficients . 58 1.3.1. Factorials . 58 1.3.2. Definition of binomial coefficients . 59 1.3.3. Fundamental properties of the binomial coefficients . 61 1.3.4. Binomial coefficients count subsets . 69 1.3.5. Integrality and some arithmetic properties . 74 1.3.6. The binomial formula . 78 1.3.7. Other properties of binomial coefficients . 86 1.4. Counting subsets . 93 1.4.1. All subsets . 93 1 Enumerative Combinatorics: class notes page 2 1.4.2. Lacunar subsets: the basics . 94 1.4.3. Intermezzo: SageMath . 97 1.4.4. Counting lacunar subsets . 102 1.4.5. Counting k-element lacunar subsets . 107 1.4.6. Counting subsets with a odd and b even elements . 111 1.4.7. The addition formula for Fibonacci numbers . 114 1.4.8. More subset counting . 119 1.4.9. Counting subsets containing a given subset . 126 1.5. Counting tuples and maps . 128 1.5.1. Tuples . 128 1.5.2. Counting maps . 132 1.5.3. Applications . 133 1.6. Interchange of summations . 136 1.6.1. The finite Fubini principle . 136 1.6.2. The Fubini principle with a predicate . 146 1.6.3. A cautionary tale about infinite sums . 156 1.7. Counting permutations: an introduction . 159 1.7.1. Permutations and derangements . 159 1.7.2. Only the size counts . 161 1.7.3. Intermezzo: OEIS . 166 1.7.4. The one-line notation . 168 1.7.5. Short-legged permutations . 172 1.7.6. Long-legged permutations . 176 2. Binomial coefficients 178 2.1. The alternating sum of a row of Pascal’s triangle . 178 2.1.1. Telescoping sums . 178 2.1.2. A war between the odd and the even . 184 2.2. The trinomial revision formula . 187 2.2.1. An algebraic proof . 187 2.2.2. A double counting proof . 191 2.3. The hockey-stick identity revisited . 198 2.4. Counting maps . 202 2.4.1. All maps . 202 2.4.2. Injective maps . 203 2.4.3. The pigeonhole principles . 210 2.4.4. Permutations . 212 2.4.5. Surjective maps . 213 2.5. 1m + 2m + ... + nm .............................. 224 2.6. The Vandermonde convolution . 226 2.6.1. The Vandermonde convolution theorem . 226 2.6.2. The polynomial identity trick . 232 2.6.3. Salvaging the proofs of Theorem 2.6.1 . 236 2.6.4. More consequences of the polynomial identity trick . 238 Enumerative Combinatorics: class notes page 3 2.6.5. Mutating the Chu–Vandermonde identity . 241 2.7. Counting subsets again . 248 2.8. Another use of polynomials . 253 2.9. The Principle of Inclusion and Exclusion . 257 2.9.1. The principles . 257 2.9.2. The cancellation lemma . 264 2.9.3. The proofs . 267 2.9.4. Application: Surjections . 273 2.9.5. Application: Derangements . 276 2.9.6. Application: Euler’s totient function . 282 2.9.7. Other cancellation-type lemmas . 290 2.10. Compositions and weak compositions . 290 2.10.1. Compositions . 291 2.10.2. Binary compositions . 295 2.10.3. Weak compositions . 296 2.10.4. Other composition-like counting problems . 298 2.11. Multisubsets . 299 2.11.1. Definitions . 299 2.11.2. Counting multisubsets of given size . 301 2.11.3. An application to lacunar subsets . 302 2.12. Multinomial coefficients . 307 2.12.1. Definition and formulas . 307 2.12.2. Counting maps that take values a given number of times . 309 2.12.3. Counting anagrams . 312 2.12.4. More formulas . 315 3. The twelvefold way 317 3.1. What is the twelvefold way? . 318 3.2. L ! L ..................................... 323 3.3. Equivalence relations . 324 3.3.1. Relations . 324 3.3.2. Equivalence relations . 326 3.3.3. Equivalence classes . 328 3.3.4. Defining unlabelled boxes and balls . 330 3.4. U ! L .................................... 333 3.5. L ! U .................................... 337 3.6. U ! U and integer partitions . 341 3.7. Integer partitions (an introduction) . 345 3.8. Odds and ends . 348 4. Permutations 349 4.1. Introduction . 349 4.2. Definitions . 350 4.3. Transpositions and cycles . 350 Enumerative Combinatorics: class notes page 4 4.4. Inversions and lengths . 353 4.5. Descents . 359 4.6. Signs . 360 5. Lattice paths (brief introduction) 363 6. Generating functions (introduction) 367 7. Solutions and references to the exercises 369 7.1. Reference to solution to Exercise 1.3.1 . 369 7.2. Solution to Exercise 1.3.2 . 369 7.3. Reference to solution to Exercise 1.3.3 . 369 7.4. Solution to Exercise 1.3.4 . 370 7.5. Reference to solution to Exercise 1.3.5 . 371 7.6. Solution to Exercise 1.3.6 . 371 7.7. Solution to Exercise 1.4.1 . 372 7.8. Solution to Exercise 1.4.2 . 374 7.9. Reference to solution to Exercise 1.4.6 . 375 7.10. Reference to solution to Exercise 1.4.7 . 375 7.11. Reference to solution to Exercise 1.4.8 . 375 7.12. Reference to solution to Exercise 1.5.1 . 375 7.13. Reference to solution to Exercise 1.5.2 . 375 7.14. Reference to solution to Exercise 2.1.1 . 375 7.15. Reference to solution to Exercise 2.2.1 . 376 7.16. Solution to Exercise 2.2.2 . 376 7.17. Reference to solution to Exercise 2.2.3 . 378 7.18. Solution to Exercise 2.4.1 . 378 7.19. Solution to Exercise 2.4.2 . 380 7.20. Solution to Exercise 2.4.3 . 382 7.21. Solution to Exercise 2.4.4 . 383 7.22. Solution to Exercise 2.4.5 . 389 7.23. Solution to Exercise 2.5.1 . ..
Recommended publications
  • The Twelvefold Way, the Nonintersecting Circles Problem, and Partitions of Multisets
    Turkish Journal of Mathematics Turk J Math (2019) 43: 765 – 782 http://journals.tubitak.gov.tr/math/ © TÜBİTAK Research Article doi:10.3906/mat-1805-72 The twelvefold way, the nonintersecting circles problem, and partitions of multisets Toufik MANSOUR1,, Madjid MIRZVAZIRI2, Daniel YAQUBI2;∗ 1Department of Mathematics, University of Haifa, Haifa, Israel 2Department of Mathematics, Ferdowsi University of Mashhad, Mashhad, Iran Received: 14.05.2018 • Accepted/Published Online: 30.01.2019 • Final Version: 27.03.2019 Abstract: Let n be a nonnegative integer and A = fa1; : : : ; akg be a multiset with k positive integers such that a1 6 ··· 6 ak . In this paper, we give a recursive formula for partitions and distinct partitions of positive integer n with respect to a multiset A. We also consider the extension of the twelvefold way. By using this notion, we solve the nonintersecting circles problem, which asks to evaluate the number of ways to draw n nonintersecting circles in the plane regardless of their sizes. The latter also enumerates the number of unlabeled rooted trees with n + 1 vertices. Key words: Multiset, partitions and distinct partitions, twelvefold way, nonintersecting circles problem, rooted trees, Wilf partitions 1. Introduction A partition of n is a sequence λ1 > λ2 > ··· > λk of positive integers such that λ1 + λ2 + ··· + λk = n (see [2]). We write λ ` n to denote that λ is a partition of n. The nonzero integers λ in λ are called parts of λ. P k j j The number of parts of λ is the length of λ, denoted by `(λ), and λ = k>1 λk is the weight of λ.
    [Show full text]
  • BASIC DISCRETE MATHEMATICS Contents 1. Introduction 2 2. Graphs
    BASIC DISCRETE MATHEMATICS DAVID GALVIN, DEPARTMENT OF MATHEMATICS, UNIVERSITY OF NOTRE DAME Abstract. This document includes lecture notes, homework and exams from the Spring 2017 incarnation of Math 60610 | Basic Discrete Mathematics, a graduate course offered by the Department of Mathematics at the University of Notre Dame. The notes have been written in a single pass, and as such may well contain typographical (and sometimes more substantial) errors. Comments and corrections will be happily received at [email protected]. Contents 1. Introduction 2 2. Graphs and trees | basic definitions and questions 3 3. The extremal question for trees, and some basic properties 5 4. The enumerative question for trees | Cayley's formula 6 5. Proof of Cayley's formula 7 6. Pr¨ufer's proof of Cayley 12 7. Otter's formula 15 8. Some problems 15 9. Some basic counting problems 18 10. Subsets of a set 19 11. Binomial coefficient identities 20 12. Some problems 25 13. Multisets, weak compositions, compositions 30 14. Set partitions 32 15. Some problems 37 16. Inclusion-exclusion 39 17. Some problems 45 18. Partitions of an integer 47 19. Some problems 49 20. The Twelvefold way 49 21. Generating functions 51 22. Some problems 59 23. Operations on power series 61 24. The Catalan numbers 62 25. Some problems 69 26. Some examples of two-variable generating functions 70 27. Binomial coefficients 71 28. Delannoy numbers 71 29. Some problems 74 30. Stirling numbers of the second kind 76 Date: Spring 2017; version of December 13, 2017. 1 2 DAVID GALVIN, DEPARTMENT OF MATHEMATICS, UNIVERSITY OF NOTRE DAME 31.
    [Show full text]
  • Combinatorics—
    The Ohio State University October 10, 2016 Combinatorics | 1 Functions and sets Enumerative combinatorics (or counting), at its heart, is all about finding functions between different sets in such a way that reveals their size. A little combinatorics goes a long way: you'll probably run into it in every discipline that involves numbers. Beyond numbers and sets, there is not much additional formal theory needed to get started. For sets A and B; a function f : A ! B is any assignment of elements of B defined for every element of A: All f needs to do to be a function from A to B is that there is a rule defined for obtaining f(a) 2 B for every element of a 2 A: In some situations, it can be non-obvious that a rule in unambiguous (we will see examples), in which case it may be necessary to prove that f is well-defined. We will be interested in counting, which motivates the following three definitions. Definition 1: A function f : A ! B is injective if and only if for all x; y 2 A; f(x) = f(y) ) x = y: These are sometimes called one-to-one functions. Think of injective functions as rules for placing A inside of B in such a way that we can undo our steps. Lemma 1: A function f : A ! B is injective if and only if there is a function g : B ! A so that 8x 2 A g(f(x)) = x: This function g is called a left-inverse for f Proof.
    [Show full text]
  • Complexity Theory and Its Applications in Linear Quantum
    Louisiana State University LSU Digital Commons LSU Doctoral Dissertations Graduate School 2016 Complexity Theory and its Applications in Linear Quantum Optics Jonathan Olson Louisiana State University and Agricultural and Mechanical College, [email protected] Follow this and additional works at: https://digitalcommons.lsu.edu/gradschool_dissertations Part of the Physical Sciences and Mathematics Commons Recommended Citation Olson, Jonathan, "Complexity Theory and its Applications in Linear Quantum Optics" (2016). LSU Doctoral Dissertations. 2302. https://digitalcommons.lsu.edu/gradschool_dissertations/2302 This Dissertation is brought to you for free and open access by the Graduate School at LSU Digital Commons. It has been accepted for inclusion in LSU Doctoral Dissertations by an authorized graduate school editor of LSU Digital Commons. For more information, please [email protected]. COMPLEXITY THEORY AND ITS APPLICATIONS IN LINEAR QUANTUM OPTICS A Dissertation Submitted to the Graduate Faculty of the Louisiana State University and Agricultural and Mechanical College in partial fulfillment of the requirements for the degree of Doctor of Philosophy in The Department of Physics and Astronomy by Jonathan P. Olson M.S., University of Idaho, 2012 August 2016 Acknowledgments My advisor, Jonathan Dowling, is apt to say, \those who take my take my advice do well, and those who don't do less well." I always took his advice (sometimes even against my own judgement) and I find myself doing well. He talked me out of a high-paying, boring career, and for that I owe him a debt I will never be able to adequately repay. My mentor, Mark Wilde, inspired me to work hard without saying a word about what I \should" be doing, and instead leading by example.
    [Show full text]
  • Homomesies Lurking in the Twelvefold Way
    Homomesies Lurking in the Twelvefold Way Tom Roby (UConn) Describing joint research with Michael Joseph & Michael LaCroix Special Session on Enumerative Combinatorics AMS Central Sectional Meeting University of St. Thomas Minneapolis, MN USA 28 October 2016 (Friday) Slides for this talk are available online (or will be soon) at http://www.math.uconn.edu/~troby/research.html Homomesies Lurking in the Twelvefold Way Tom Roby (UConn) Describing joint research with Michael Joseph & Michael LaCroix Special Session on Enumerative Combinatorics AMS Central Sectional Meeting University of St. Thomas Minneapolis, MN USA 28 October 2016 (Friday) Slides for this talk are available online (or will be soon) at http://www.math.uconn.edu/~troby/research.html Abstract Abstract: Given a group acting on a finite set of combinatorial objects, one can often find natural statistics on these objects which are homomesic, i.e., over each orbit of the action, the average value of the statistic is the same. Since the notion was codified a few years ago, homomesic statistics have been uncovered in a wide variety of situations within dynamical algebraic combinatorics. We discuss several examples lurking in Rota's Twelvefold Way related to actions on injections, surjections (joint work with Michael Joseph), and bijections/permutations (joint work with Michael LaCroix) of finite sets. Acknowledgments This seminar talk discusses joint work with Michael Joseph and Michael La Croix. Thanks to James Propp for suggesting the study of whirling and of Foatic actions, as well as earlier collaborations on the homomesy phenomenon. Please feel free to interrupt with questions or comments. Outline Actions, orbits, and homomesy; The Twelvefold Way; Foatic actions on Sn.
    [Show full text]
  • A Species Approach to the Twelvefold
    A species approach to Rota’s twelvefold way Anders Claesson 7 September 2019 Abstract An introduction to Joyal’s theory of combinatorial species is given and through it an alternative view of Rota’s twelvefold way emerges. 1. Introduction In how many ways can n balls be distributed into k urns? If there are no restrictions given, then each of the n balls can be freely placed into any of the k urns and so the answer is clearly kn. But what if we think of the balls, or the urns, as being identical rather than distinct? What if we have to place at least one ball, or can place at most one ball, into each urn? The twelve cases resulting from exhaustively considering these options are collectively referred to as the twelvefold way, an account of which can be found in Section 1.4 of Richard Stanley’s [8] excellent Enumerative Combinatorics, Volume 1. He attributes the idea of the twelvefold way to Gian-Carlo Rota and its name to Joel Spencer. Stanley presents the twelvefold way in terms of counting functions, f : U V, between two finite sets. If we think of U as a set of balls and V as a set of urns, then requiring that each urn contains at least one ball is the same as requiring that f!is surjective, and requiring that each urn contain at most one ball is the same as requiring that f is injective. To say that the balls are identical, or that the urns are identical, is to consider the equality of such functions up to a permutation of the elements of U, or up to a permutation of the elements of V.
    [Show full text]
  • Richard Stanley's Twelvefold Way
    Richard Stanley's Twelvefold Way August 31, 2009 Many combinatorial problems can be framed as counting the number of ways to allocate balls to urns, subject to various conditions. Richard Stanley invented the \twelvefold way" to organize these results into a table with twelve entries. See his book Enumerative Combinatorics, Volume 1. Let b represent the number of balls available and u the number of urns. The following table gives the number of ways to partition the balls among the urns according to the various states of labeled or unlabeled and subject to certain restrictions. The column headed \≤ 1" corresponds to requiring that there be no more than one ball in each urn. Similarly, the column headed \≥ 1" corresponds to requiring at least one ball in each urn. Balls Urns unrestricted ≤ 1 ≥ 1 b labeled labeled u (u)b u!S(b; u) unlabeled labeled u u u b b b-u labeled unlabeled u i=1 S(b; i) [b ≤ u] S(b; u) unlabeled unlabeled u P i=1 pi(b) [b ≤ u] pu(b) P For convenient cross referencing, we will refer to each of the cases by three symbols. The rst character is an l or a u depending on whether the balls 1 are labeled or unlabeled. The second character similarly indicates whether the urns are labeled or unlabeled. The nal character is one the regular expression symbols *, ?, or + indicating no restrictions, at most one ball per urn, and at least one ball per urn respectively. 1 Labeled balls, labeled urns, unrestricted (ll*) This is the number of b-tuples of u things.
    [Show full text]
  • The Twelvefold Way
    The Twelvefold Way Lukas Bulwahn February 23, 2021 Abstract This entry provides all cardinality theorems of the Twelvefold Way. The Twelvefold Way [1, 5, 6] systematically classifies twelve related combinatorial problems concerning two finite sets, which include count- ing permutations, combinations, multisets, set partitions and number partitions. This development builds upon the existing formal develop- ments [2, 3, 4] with cardinality theorems for those structures. It pro- vides twelve bijections from the various structures to different equiva- lence classes on finite functions, and hence, proves cardinality formulae for these equivalence classes on finite functions. Contents 1 Preliminaries 4 1.1 Additions to Finite Set Theory ................. 4 1.2 Additions to Equiv Relation Theory .............. 4 1.2.1 Counting Sets by Splitting into Equivalence Classes . 5 1.3 Additions to FuncSet Theory .................. 5 1.4 Additions to Permutations Theory ............... 6 1.5 Additions to List Theory ..................... 6 1.6 Additions to Disjoint Set Theory ................ 7 1.7 Additions to Multiset Theory .................. 7 1.8 Additions to Number Partitions Theory ............ 8 1.9 Cardinality Theorems with Iverson Function .......... 8 2 Main Observations on Operations and Permutations 9 2.1 Range Multiset .......................... 9 2.1.1 Existence of a Suitable Finite Function ........ 9 2.1.2 Existence of Permutation ................ 9 2.2 Domain Partition ......................... 9 2.2.1 Existence of a Suitable Finite Function ........ 9 2.2.2 Equality under Permutation Application ........ 10 2.2.3 Existence of Permutation ................ 10 2.3 Number Partition of Range ................... 11 1 2.3.1 Existence of a Suitable Finite Function ........ 11 2.3.2 Equality under Permutation Application .......
    [Show full text]
  • Discrete Structures I – Combinatorics
    Discrete Structures I – Combinatorics Lectures by Prof. Dr. Stefan Felsner Notes taken by Elisa Haubenreißer Summer term 2011 2 Contents 1 Introductory Examples 5 1.1 Derangements..................................... .. 5 1.2 TheOfficersProblem.................................. 9 2 Basic Counting 13 n 2.1 Models for k ...................................... 14 2.2 Extending binomial coefficients . ... 15 3 Fibonacci Numbers 17 3.1 Models for F -numbers .................................. 18 3.2 FormulasforFibonacciNumbers . .... 19 3.3 The -numberSystem.................................. 21 F 3.4 ContinuedFractionsandContinuants . ..... 22 4 The Twelvefold Way 25 5 Formal Power Series 33 5.1 Bernoullinumbersandsummation . ... 34 5.2 Compositionofseries................................. .. 35 5.3 RootsofFPS ....................................... 36 5.4 CatalanNumbers.................................... 37 6 Solvinglinearrecurrencesviageneratingfunctions 39 6.1 How to compute spanning trees of Gn ......................... 40 6.2 An example with exponential generating function . ....... 42 7 q-Enumeration 43 7.1 Another model for the q-binomial............................ 47 8 Finite Sets And Posets 49 8.1 Posets–Partiallyorderedsets. ..... 50 8.2 Thediagramofaposet ................................ 51 8.3 k-intersecting families . 52 8.4 Shadows – Another prooffor Sperner’s theorem . ......... 53 8.5 Erd¨os-Ko-RadofromKruskal-Katona. ........ 55 8.6 Symmetric chain decompositions . ... 57 8.7 An application: Dedekinds problem . ... 60 9 Duality
    [Show full text]
  • Haystack Hunting Hints and Locker Room Communication∗
    Haystack Hunting Hints and Locker Room Communication∗ Artur Czumaj † George Kontogeorgiou ‡ Mike Paterson § Abstract We want to efficiently find a specific object in a large unstructured set, which we model by a random n-permutation, and we have to do it by revealing just a single element. Clearly, without any help this task is hopeless and the best one can do is to select the element at random, and 1 achieve the success probability n . Can we do better with some small amount of advice about the permutation, even without knowing the object sought? We show that by providing advice of just one integer in 0; 1; : : : ; n 1 , one can improve the success probability considerably, by log n f − g a Θ( log log n ) factor. We study this and related problems, and show asymptotically matching upper and lower bounds for their optimal probability of success. Our analysis relies on a close relationship of such problems to some intrinsic properties of random permutations related to the rencontres number. 1 Introduction Understanding basic properties of random permutations is an important concern in modern data science. For example, a preliminary step in the analysis of a very large data set presented in an unstructured way is often to model it assuming the data is presented in a random order. Un- derstanding properties of random permutations would guide the processing of this data and its analysis. In this paper, we consider a very natural problem in this setting. You are given a set of 1 n objects ([n 1], say ) stored in locations x ; : : : ; x − according to a random permutation σ of − 0 n 1 [n 1].
    [Show full text]
  • Lecture Notes Combinatorics
    Lecture Notes Combinatorics Lecture by Torsten Ueckerdt (KIT) Problem Classes by Jonathan Rollin (KIT) Lecture Notes by Stefan Walzer (TU Ilmenau) Last updated: July 19, 2016 1 Contents 0 What is Combinatorics?4 1 Permutations and Combinations 10 1.1 Basic Counting Principles...................... 10 1.1.1 Addition Principle...................... 10 1.1.2 Multiplication Principle................... 10 1.1.3 Subtraction Principle.................... 11 1.1.4 Bijection Principle...................... 11 1.1.5 Pigeonhole Principle..................... 11 1.1.6 Double counting....................... 12 1.2 Ordered Arrangements { Strings, Maps and Products...... 12 1.2.1 Permutations......................... 13 1.3 Unordered Arrangements { Combinations, Subsets and Multisets................ 14 1.4 Multinomial Coefficients....................... 16 1.5 The Twelvefold Way { Balls in Boxes............... 22 1.5.1 U L: n Unlabeled Balls in k Labeled Boxes...... 22 1.5.2 L ! U: n Labeled Balls in k Unlabeled Boxes...... 24 1.5.3 L ! L: n Labeled Balls in k Labeled Boxes....... 26 1.5.4 U ! U: n Unlabeled Balls in k Unlabeled Boxes.... 28 1.5.5 Summary:! The Twelvefold Way............... 29 1.6 Binomial Coefficients { Examples and Identities.......... 30 1.7 Permutations of Sets......................... 34 1.7.1 Cycle Decompositions.................... 35 1.7.2 Transpositions........................ 38 1.7.3 Derangements......................... 40 2 Inclusion-Exclusion-Principle and M¨obiusInversion 44 2.1 The Inclusion-Exclusion Principle.................. 44 2.1.1 Applications......................... 46 2.1.2 Stronger Version of PIE................... 51 2.2 M¨obiusInversion Formula...................... 52 3 Generating Functions 57 3.1 Newton's Binomial Theorem..................... 61 3.2 Exponential Generating Functions................. 62 3.3 Recurrence Relations........................
    [Show full text]
  • Let's Expand Rota's Twelvefold Way for Counting Partitions!
    (Submitted to the American Mathematical Monthly.) Let's Expand Rota's Twelvefold Way For Counting Partitions! Robert A. Proctor Department of Mathematics University of North Carolina Chapel Hill, North Carolina 27599 rap -at- email.unc.edu January 5, 2007 Dedicated to the memory of Gian-Carlo Rota. 1. Introduction Let's suppose we have a diamond, an emerald, and a ruby. How many ways are there to store these gems in small velvet bags? The bags are identical, and we can use any number of them. Unused bags are ignored. Since the gems can move around within the bags, we may as well list the gems within each bag in alphabetical order. Since the bags are identical, we may as well record the bags in alphabetical order, according to their first elements. Using inner {}'s for the bags and outer {}'s to collect the bags, here are the possibilities: { {D}, {E}, {R} }, { {D,E}, {R} }, { {D,R}, {E} }, { {D}, {E,R} }, { {D,E,R} }. So there are 5 storage configurations. These are the "partitions" of the set {D, E, R}. For m ≥ 0, let B(m) denote the number of partitions of a set of m distinguishable items. So B(3) = 5. The counts B(0), B(1), B(2), B(3), … are called the "Bell numbers". Surprisingly, these numbers also arise in a Maclaurin series expansion: ex–1 xm e = ∑m≥0B(m)——— . m! There are dozens of variations of this notion of partition. If autographed baseballs were stored in socks, the order in which the baseballs were shoved into each sock would matter.
    [Show full text]