principle of inclusion-exclusion, proof of


The proof is by inductionMathworldPlanetmath. Consider a single set A1. Then the principle of inclusion-exclusion states that |A1|=|A1|, which is trivially true.

Now consider a collectionMathworldPlanetmath of exactly two sets A1 and A2. We know that

AB=(AB)(BA)(AB)

Furthermore, the three sets on the right-hand side of that equation must be disjoint. Therefore, by the addition principle, we have

|AB| = |AB|+|BA|+|AB|
= |AB|+|AB|+|BA|+|AB|-|AB|
= |A|+|B|-|AB|

So the principle of inclusion-exclusion holds for any two sets.

Now consider a collection of N>2 finite setsMathworldPlanetmath A1,A2,AN. We assume that the principle of inclusion-exclusion holds for any collection of M sets where 1M<N. Because the union of sets is associative, we may break up the union of all sets in the collection into a union of two sets:

i=1NAi=(i=1N-1Ai)AN

By the principle of inclusion-exclusion for two sets, we have

|i=1NAi|=|i=1N-1Ai|+|AN|-|(i=1N-1Ai)AN|

Now, let Ik be the collection of all k-fold intersectionsMathworldPlanetmathPlanetmath of A1,A2,AN-1, and let Ik be the collection of all k-fold intersections of A1,A2,AN that include AN. Note that AN is included in every member of Ik and in no member of Ik, so the two sets do not duplicate one another.

We then have

|i=1NAi|=j=1N((-1)(j+1)SIj|S|)+|AN|-|(i=1N-1Ai)AN|

by the principle of inclusion-exclusion for a collection of N-1 sets. Then, we may distribute set intersection over set union to find that

|i=1NAi|=j=1N((-1)(j+1)SIj|S|)+|AN|-|i=1N-1(AiAN)|

Note, however, that

(AxAN)(AyAN)=(AxAyAN)

Hence we may again apply the principle of inclusion-exclusion for N-1 sets, revealing that

|i=1NAi| = j=1N-1((-1)(j+1)SIj|S|)+|AN|-j=1N-1((-1)(j+1)SIj|SAN|)
= j=1N-1((-1)(j+1)SIj|S|)+|AN|-j=1N-1((-1)(j+1)SIj+1|S|)
= j=1N-1((-1)(j+1)SIj|S|)+|AN|-j=2N((-1)(j)SIj|S|)
= j=1N-1((-1)(j+1)SIj|S|)+|AN|+j=2N((-1)(j+1)SIj|S|)

The second sum does not include I1. Note, however, that I1={AN}, so we have

|i=1NAi| = j=1N-1((-1)(j+1)SIj|S|)+j=1N((-1)(j+1)SIj|S|)
= j=1N-1[(-1)(j+1)(SIj|S|+SIj|S|)]+(-1)N+1|i=1NAi|

Combining the two sums yields the principle of inclusion-exclusion for N sets.

Title principle of inclusion-exclusion, proof of
Canonical name PrincipleOfInclusionexclusionProofOf
Date of creation 2013-03-22 12:33:27
Last modified on 2013-03-22 12:33:27
Owner mps (409)
Last modified by mps (409)
Numerical id 6
Author mps (409)
Entry type Proof
Classification msc 05A99