You are on page 1of 2

Combinatorics

Principle of Inclusion and Exclusion

Exercise 1

Because of the continued Corona pandemic it is decided to organize an event that can be carried
out at a distance of 1.5 meters, line dancing. Ultimately, 3 couples turn up for the event. It’s
decided to make two rows of three people behind each other as in the diagram shown.

In how many ways can the 6 persons be distributed such that no couple dances close together,
i.e., no couple is either standing next to each other or opposite each other (thus not horizontally
or vertically). Use the principle of inclusion and exclusion for properties using the
following properties

P1 := couple 1 dances close together


P2 := couple 2 dances close together
P3 := couple 3 dances close together

1
Solution

The desired solutions are exactly those solutions that do not comply to any of the three
properties P1 , P2 , and P3 . Hence we can apply the principle of inclusion and exclusion.
Therefore we compute the default list of N (Pi1 . . . Pik )’s.

ˆ N = 6! = 720 as this is just all permutations of 6 persons at 6 positions.

ˆ N (P1 ) = 2 · 7 · 4! = 336. Since there are 7 ways to select a pair of positions for pair 1 such
that they dance close together. Given such a position, pair 1 can be distributed in two
ways. The remaining 4 persons can be distributed arbitrarily, i.e., 4!.

1 2 3 4 5 6 7

ˆ N (P2 ) = 336. Likewise.

ˆ N (P3 ) = 336. Likewise.

ˆ N (P1 P2 ) = (4 · 2) · (3 · 2) · 2! + (2 · 2) · (4 · 2) · 2! + (1 · 2) · (2 · 2) · 2! = 176. Since there are 4


cases for pair 1 in which we have 3 ways for pair 2 (cases 1,2,3,4) to dance together. Both
pair 1 and 2 can be distributed in 2 ways, and the remaining 2 persons can be distributed
in 2! ways. Analogously there are 2 cases for pair 1 in which we have 4 ways for pair 2
(case 5,7) to dance together, and there is 1 case for pair 1 in which we have 2 ways for
pair 2 (case 6) to dance together.

ˆ N (P1 P3 ) = 176. Likewise.

ˆ N (P2 P3 ) = 176. Likewise.

ˆ N (P1 P2 P3 ) = (5 · 2) · (2 · 2) · (1 · 2) + (2 · 2) · (4 · 2) · (1 · 2) = 144. Since there are now 5


cases for pair 1 such that there are 2 ways to distribute pair 2 (cases 1,2,3,4,6) such that
there is 1 way to distribute pair 3 such that these pairs dance close together. Each pair
can be distributed in 2 ways. Analogously, there are 2 cases for pair 1 such that there are
4 ways to distributed pair 2 (cases 5,7) such that there is 1 way to distribute pair 3 such
that these pairs dance close together.

So

N (P10 P20 P30 ) = N


− N (P1 ) − N (P2 ) − N (P3 )
+ N (P1 P2 ) + N (P1 P3 ) + N (P2 P3 )
− N (P1 P2 P3 )
= 720 − 3 · 336 + 3 · 176 − 144 = 96

You might also like