0

This was a problem from the AOPS Intermediate Probability and Counting book, from a chapter on Principle of Inclusion Exclusion (PIE). I was able to follow the solution, but don't understand why PIE applies to the problem.

Essentially, they find the number of ways to seat exactly 1-5 pairs of twins together, and use PIE to calculate the number of ways that at least 1 pair of twins is together, and subtracts it from the total number of ways with no restriction.

So they do #ways-pair1 - #ways-pair2 + #ways-pair3 - #ways-pair4 + #ways-pair5

However, why does PIE work for this? When I think of PIE I think of venn diagrams and sets. The formula for PIE with n sets is basically sum (alternating sign) of the nth elementary symmetric sums, but intersecting instead of multiplying.

What would the sets in this problem be?

  • Let $~S~$ denote the set of all possible seatings, without any regard for whether twins are together. Label the pairs of twins T-1, T-2, T-3, T-4, T-5. For $~k \in {1,2,3,4,5},~$ let $~S_k~$ denote the subset of $~S~$ such that the pair of twins T-k are together. Then, you want $$|S| - |S_1 \cup S_2 \cup S_3 \cup S_4 \cup S_5|.$$ For illustration purposes: clearly $~|S| = 10!,~$ and $~|S_1| = 2 \times 9!.$ ...see next comment – user2661923 Sep 10 '23 at 05:27
  • See this article for an introduction to Inclusion-Exclusion. Then, see this answer for an explanation of and justification for the Inclusion-Exclusion formula. Using the syntax in the second link, you would have $$T_0 = |S| = 10!, ~T_1 = |S_1| + \cdots + |S_5| = 5 \times 2 \times 9!.$$ – user2661923 Sep 10 '23 at 05:29

2 Answers2

1

The sets, which you have called pair$n$, are the number of ways to seat the people so there are at least $n$ pairs next to each other. The point is that if you have exactly $2$ pairs seated next to each other you have counted the arrangement twice in pair$1$ so need to subtract one. If you have $3$ pairs seated next to each other you have counted the arrangement three times in pair$1$ and added them, then counted it three times in pair$2$ and subtracted them, so you need to add it in once and so on.

Ross Millikan
  • 374,822
0

Well, from what I can gather, the set that you're interested in is a subset of $^{10}P_{10} = 10!$. Venn diagramatically, the set that you're interested is a circle inside the circle for $10!$

The PIE technique seems to overcount by first calculating $10!$ and then subtracting what was overcounted to leave you with the correct answer.

By the way do the calculations involve the numbers 9, 2, 90, and $8!$? Just curious.
Have a good day.