1

Assume six people at a party. Is there a formula to calculate the total possible combinations? Ie: Six alone. Four together, two alone. Four together, two together. 3 together, 3 others together. 3 together, 2 together, 1 alone and so on? I came up with 10 distributions and 142 combinations for that (which might be wrong).

I'm more interested in expanding that to other quantities.

hardmath
  • 37,715
  • It seems what you are interested in are the partitions of a set, treating the six people as distinct individuals. Possibly though you mean to treat the people only as indistinguishable figures, and thus only as "counts" in terms of your outcomes. Please clarify as this affects the answers. – hardmath Sep 14 '14 at 00:09
  • Yes, as individuals. Order of no import. (abc. def) counts the same as (fde. cab.) but (fde cb a) would be a different partition. – Walt torvin Sep 14 '14 at 03:56
  • This turned out to be more interesting and exciting than I anticipated. Thank you for your responses.k – Walt torvin Sep 24 '14 at 07:45

2 Answers2

1

Your "distributions" are commonly called "partitions". These are an extremely well-studied object in research-level mathematics.

The short answer is no, there is no such formula.

The longer answer is that there actually are such formulae, but they are all somewhat unsatisfying.

  • There are recursive rules which give you partition numbers if you know all of the previous partition numbers.
  • There are also approximate formulae which can be off by very large amounts but the error is guaranteed to be small compared to the size of the numbers involved (think Earth vs. the Milky Way. Yes, Earth is big, but it's pretty small on a galactic scale).
  • There are formulae which involve adding infinitely many numbers together, with the partial sums eventually converging on a single number.
  • In 2011, Jan Bruinier and Ken Ono found an exact, closed form, finite formula, but if you want to actually use it to compute partition numbers then you will need to be willing to learn some very, very deep mathematics.

I think your "combinations" are ways of first partitioning ("distributing") the people, and then determining which people go in which groups?

If you are allowed to distinguish the groups themselves (e.g. ABC/DEF is different than DEF/ABC), then this is simply the number of surjections from $\{1,\dots, n\}$ to $\{1,\dots, k\}$, summed over all $k$; I think these are easily countable by standard methods.

However, my guess is that you would want to make the groups indistinguishable. This may also have a simple answer, but I am not aware of it.

Eric Stucky
  • 13,018
1

The number of "distributions" of $n$ people described in the Question seems to be the (unordered) partitions of an integer, while the number of "combinations" of $n$ people appears to be the partitions of a set.

Let's illustrate with $n=6$. There are $11$ integer partitions of $6$, as follows:

$$ 6 $$

$$ 5+1 \; ;\; 4+2 \; ;\; 3+3 $$

$$ 4+1+1 \; ;\; 3+2+1 \; ;\; 2+2+2 $$

$$ 3+1+1+1 \; ;\; 2+2+1+1 $$

$$ 2+1+1+1+1 $$

$$ 1+1+1+1+1+1 $$

Counting how many integer partitions of $n$ there are defines the partition function $p(n)$, for which the OEIS sequence A000041 tabulates some of the initial values and gives references to the literature:

$$ p(0..9) = 1, 1, 2, 3, 5, 7, 11, 15, 22, 30 $$

There are $203$ ways to partition a set of six elements, e.g. $\{a,b,c,d,e,f\}$. Instead of listing them all out, let's jump right to the topic of counting them.

The Bell number $B_n$ counts how many partitions there are of a set of $n$ elements (the number of equivalence relations on such a set). The first few Bell numbers are tabulated by the OEIS sequence A000110:

$$ B_n = 1, 1, 2, 5, 15, 52, 203, 877, 4140, 21147 \;\text{ for } n=0..9 $$


Computing the partition function $p(n)$

For modest sizes of $n$ there is an attractive recurrence relation implied by the pentagonal number theorem of Leonhard Euler:

$$ p(n) = \sum_{k\gt 0} (-1)^{k-1} \left[p\left(n - \frac{k(3k-1)}{2}\right) + p\left(n - \frac{k(3k+1)}{2}\right)\right] $$

with the convention that $p(m) = 0$ for $m \lt 0$. For example:

$$ p(6) = p(5) + p(4) - p(0) - p(-1) = 7 + 5 - 1 - 0 = 11 $$

The connection between Euler's pentagonal number theorem and counting partitions was featured in this recent Math.SE blog post.

The history of improved calculation methods is quite interesting. Hardy and Ramanujan proved an approximation to $p(n)$ by an asymptotic series, work during 1916-1917 that gave rise to the circle method useful in other number theory problems. In 1937 Rademacher refined this into an exact convergent series, seemingly getting the best possible formula, one that Johansson shows yields an $O(n^{1/2 + \epsilon})$ method for computing $p(n)$.

Then in 2011 Brunier and Ono announced an exact finite formula expressing $p(n)$ as a sum of algebraic numbers. So far this has not led to faster methods of computing the partition function, but it may do so in the future.

The current record seems to be computation of $p(10^{20})$ by Johansson, a result with 11,140,086,260 digits.


Computing the Bell numbers $B_n$

The Bell numbers grow more rapidly than partition numbers due to their extra degrees of freedom in assigning individual elements to "parts" of a partition. An attractive recurrence relation can be expressed in terms of a triangle of positive integers, with the Bell numbers appearing both on the left and right diagonals:

$$ 1 $$ $$ 1 \;\; 2 $$ $$ 2 \;\; 3 \;\; 5 $$ $$ 5 \;\; 7 \;\; 10 \;\; 15 $$ $$ 15 \;\; 20 \;\; 27 \;\; 37 \;\; 52 $$ $$ 52 \;\; 67 \;\; 87 \;\; 114 \;\; 151 \;\; 203 $$

The rule of construction is to begin with $1$ at the top of the triangle, to copy the rightmost entry of each row to the leftmost entry of the row immediately below, and to otherwise form entries by summing the two entries to the left and to the upper left. Thus the final entry in the bottom row would become the first entry of the next, confirming that $B_6 = 203$.

A more concise recurrence formula for $B_n$ involves binomial coefficients:

$$ B_{n+1} = \sum_{k=0}^n \binom{n}{k} B_k $$

This would be fairly efficient if we were interested in the entire range $B_k, \; k=0..n$. For a specific Bell number we might prefer Dobinski's formula published in 1877, which for $x=0$ amounts to:

$$ B_n = \frac{1}{e} \sum_{k=0}^\infty \frac{k^n}{k!} $$

Dobinski's formula may be seen as connecting the Bell numbers with probability theory, that $B_n$ is the n'th moment of the Poisson distribution with mean $1$.

A 2011 talk by Johansson on Fast Special Functions discusses (starting on page 5) and times (see pages 9-11) some approaches for computing for ranges and for a single value $B_n$, with multimodular (Chinese remainder) methods winning for sufficiently large $n$.

hardmath
  • 37,715