You are on page 1of 8

Overview

Unions and Intersections Math 425 Introduction to Probability Lecture 7


Kenneth Harris kaharri@umich.edu
Department of Mathematics University of Michigan

! This lecture will focus on computing the probability of arbitrary nite


unions of events P (E1 E2 . . . En ) even when the events are not mutually inclusive. The method is called the Inclusion-Exclusion Principle (Proposition 2.4.4).

! Chapter 3 (the next ve lectures) will introduce methods for


P (E1 E2 . . . En ). The method is called the Conditionalization.

computing the probability of arbitrary nite intersections of events

January 23, 2009

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

1/1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

3/1

Inclusion-Exclusion Principle case n = 2

Inclusion-Exclusion Principle case n = 2

Proposition 4.3

Picture Proof of Proposition 4.3


Picture Proof.
P (E F ) = P (E ) + P (F ) P (E F )
S

The Inclusion-Exclusion Principle (for n = 2) is used to compute P (E F ) when E and F may not be mutually exclusive.

Fc

Ec

Proposition (Ross 4.3) Let E and F be any events. Then P (E F ) = P (E ) + P (F ) P (E F )

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

5/1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

6/1

Inclusion-Exclusion Principle case n = 2

Inclusion-Exclusion Principle case n = 3

Example 0
Example 0. What is the probability of getting a heads on the rst toss or a tails on the second toss of a fair coin? Sample Space. S = {HH , HT , TH , TT } Assumption. Each outcome is equiprobable. Events. Hi : heads on i th toss (i = 1, 2), Ti : tails on i th toss (i = 1, 2) Probabilities. We want to compute P (H1 T2 ).

Proposition 4.4, Case n = 3


The Inclusion-Exclusion Principle (for n = 3) is used to compute P (E F G) when E , F and G may not be mutually exclusive. Proposition (Ross 4.4, case n = 3) Let E, F and G be any events. Then P (E F G) = P (E ) + P (F ) + P (G) 1 P (Hi ) = 2 1 P (Ti ) = 2 1 P (H1 T2 ) = 4 3 P (H1 T2 ) = . 4
January 23, 2009 7/1 Kenneth Harris (Math 425)

P (E F ) + P (E G) + P (F G) + P (E F G )

P (H1 ) + P (T2 ) = 1
Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

Math 425 Introduction to Probability Lecture 7

January 23, 2009

9/1

Inclusion-Exclusion Principle case n = 3

Inclusion-Exclusion Principle case n = 3

Picture Proof of case n = 3


Picture Proof
P (E F G) = P (E ) + P (F ) + P (G) P (E F ) + P (E G) + P (F G) + P (E F G)
S

Example 0
Example 0. What is the probability of getting a heads on the rst toss or a tails on the second toss or heads on the third toss of a fair coin? Sample Space.
S = {HHH , HHT , HTH , HTT , THH , THT , TTH , TTT } Assumption. Each outcome is equiprobable.

Events.
Hi : heads on i th toss (i = 1, 2, 3),
E E F F

Ti : tails on i th toss (i = 1, 2, 3)

Probabilities. We want to compute P (H1 T2 H3 ).


F G

1 2 1 P (H1 T2 H3 ) = 8 3 P (H1 ) + P (T2 ) + P (H3 ) = 2 P ( Hi ) =


January 23, 2009 10 / 1 Kenneth Harris (Math 425)

P (Ti ) =

1 2

1 where i = j 4 7 P (H1 T2 H3 ) = . 8 P (Hi Tj ) =


January 23, 2009 11 / 1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

Math 425 Introduction to Probability Lecture 7

Inclusion-Exclusion Principle case n = 3

Inclusion-Exclusion Principle case n = 3

Example 1
Example 1. What is the probability that a randomly chosen integer between 1 and 10,000 is divisible by at least one of 4, 10 or 25? The sample space is integers between 1 and 10,000. We interested in the events Ek : the chosen number is divisible by k (where k = 4, 10, 25.)

Example 1 continued
We want to compute P (E4 E10 E25 ), and since these events are NOT mutually exclusive (why?), we need to use the Inclusion-Exclusion Principle. The following are easy to compute: P (E4 ) = 1 4 P (E10 ) = 1 10 P (E25 ) = 1 . 25

In general, if k evenly divides 10,000: Assumption. Every outcome is equiprobable: the probability of a number being chosen is
1 10000 .

|Ek | =

10000 , k

so P (Ek ) =

1 . k

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

12 / 1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

13 / 1

Inclusion-Exclusion Principle case n = 3

Inclusion-Exclusion Principle case n = 3

Example 1 continued
We also need to compute the probabilties of the intersections. E4 E10 = E20 E4 E25 = E100 E10 E25 = E50 E4 E10 E25 = E100 since 20 = lcm(4, 10) since 100 = lcm(4, 25) since 50 = lcm(4, 10) since 100 = lcm(4, 10, 25)

Example 2
Example 2. From a faculty of 5 full professors, 7 associate professors and 11 assistant professors, a committee of size 4 is to be formed randomly. What is the probability that a person from each rank is represented on the committee?

A Warning. The following is not correct (it overcounts groups):


5 1

7 1

23 4

11 1

20 1

By the Inclusion-Exclusion Principle: P (E4 E10 E25 ) = = 1 1 1 1 1 1 1 + + + 4 10 25 20 50 100 100 32 . 100


January 23, 2009 14 / 1

20 0.870!! 23

More than half the committees are formed from only two of the three groups:
12 4

16 4 23 4

18 4

1075 0.6070 1771

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

15 / 1

Inclusion-Exclusion Principle case n = 3

Inclusion-Exclusion Principle case n = 3

Example 2 continued
Apply the Inclusion-Exclusion Principle to avoid overcounting. Let the sample space S consist of sets
{p1 , p2 , p2 , p4 } where 1 p1 , p2 , p3 , p4 23,

Example 2 continued
We want to compute P (F). We can do this by as follows. The event E1 E2 E3 is that of all committees that are missing some group. So, F = E1 E2 E3 , and P (F ) = 1 P (E1 E2 E3 ). The events E1 , E2 , E3 are NOT mutually exclusive, so we need to use the Inclusion-Exclusion Principle to compute P (E1 E2 E3 ).
c

and these numbers mean:


1 p 5 : [full] 6 p 12 : [associate] 13 p 23 : [assistant].

We are interested in the following events: E1 : NO full professor is on the committee, E2 : NO associate professor is on the committee, E3 : NO assistant professor is on the committee, F : All three positions are represented on the committee.
Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 16 / 1 Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

17 / 1

Inclusion-Exclusion Principle case n = 3

Inclusion-Exclusion Principle general case

Example 2 continued
Apply the Inclusion-Exclusion Principle.
|S | = |E1 | = |E2 | = |E3 | = 23 4 18 4 16 4 12 4 |E1 E2 | = |E1 E3 | = |E2 E3 | = 11 4 7 4 5 4

Generalized Inclusion-Exclusion Principle

The Inclusion-Exclusion Principle for 3 events E1 , E2 , E3 : P (E1 E2 E3 ) = 1 2 + 3 , where 1 = P (E1 ) + P (E2 ) + P (E3 ) 2 = P (E1 E2 ) + P (E1 E3 ) + P (E2 E3 ) 3 = P (E1 E2 E3 ).

|E1 E2 E3 | = 0

So,
P (F ) = =
Kenneth Harris (Math 425)

18 4

16 4

12 4

23 4

11 4

7 4

5 4

i (i = 1, 2, 3) is the sum of all intersections taken i at a time.

10 0.435. 23
Math 425 Introduction to Probability Lecture 7 January 23, 2009 18 / 1 Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 20 / 1

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Generalized Inclusion-Exclusion Principle


The general Inclusion-Exclusion Principle is used for computing P (E1 E2 . . . En ) for any events E1 , E2 , . . . , En (even if they are not mutually exclusive). Theorem (Ross Proposition 4.4 Inclusion-Exclusion Principle) Let E1 , E2 , . . . , En be any events. Then P (E1 E2 . . . En ) = 1 2 + 3 . . . + (1)n+1 n where r is the sum of the
n r

Example 1

(See Ross, Exercise 2.5n.)

Example 1. Eight people (forming 4 couples) are sat at random at a round table. What is the probability that no couple sits together?

There are 7! ways of seating 8 people at a round table (where there is no privileged position, such as head of the table).

terms Assumption. All possible arrangements are equiprobable.

P (Ei1 Ei2 . . . Eir ) over all subsets {i1 , i2 , . . . , ir } of size r from {1, 2, . . . , n}.
Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 21 / 1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

22 / 1

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Example 1 continued
We are interested in the events Ei : the i th couple sits together (where i = 1, 2, 3, 4). F : NO couple sits together. Thus, and we want to compute the probability P (F ) = 1 P E1 E2 E3 E4 . F = E1 E2 E3 E4 .
c

Example 1 continued

Compute the probability of each Ei (i = 1, 2, 3, 4): P (Ei ) = Reason: Treat couple i as one person, so that we need to seat 7 people at a round table: 6! choices. For each arrangement, we have two ways to seat the couple (expanding their one spot to two). |Ei | 2 6! = . |S | 7!

The events E1 , E2 , E3 , E4 are NOT mutually exclusive.

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

23 / 1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

24 / 1

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Example 1 continued
Compute each of the intersections using the same argument (condensing a couple to one person): P (Ei ) = P (Ei Ej ) = P (Ei Ej Ek ) = P (E1 E2 E3 E4 ) = 2 6! i = 1, 2, 3, 4 7! 22 5! 1i <j 4 7! 23 4! 1i <j <k 4 7! 24 3! . 7!

Example 1 completed

Use the Inclusion-Exclusion Principle to complete the computation: P (F ) = 1 1 + 2 3 + 4 4 2 6! 4 22 5! 4 23 4! 4 24 3! = 1 + + 1 7! 2 7! 3 7! 4 7! 31 = 0.2952. 105

These values do not depend on i , j , k .

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

25 / 1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

26 / 1

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Example 2

Example 2 Sample space

(See Ross, Exercise 2.5m.)

Example 2. A group of n musicians from an orchestra are exchanging names for gift-giving at the end of the season bash. Each places their name in an urn, which is completely mixed, then draw names one-by-one.

The sample space S is the set of all permutations on {1, 2, . . . , n}, where we replaced the name of each musician with a number. So, a permutation (i1 , i2 , . . . , in ) represents musician k draws ik . There are n! possible outcomes of the drawing.

Question. What is the probability that no one draws their own name?

Assumption. All permutations are equiprobable, since the names were well mixed.

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

27 / 1

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

28 / 1

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Example 2 Events
We are interested in the following events. Ek : the k th musician draws their own name. These outcomes are (i1 , i2 , . . . , in ) F : NO musician draws their name. The event F is so, the probability we want is P (F ) = 1 P E1 E2 . . . En . The events E1 , E2 , . . . , En are NOT mutually exclusive.
Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 29 / 1

Example 2 Events
Compute P (E1 E2 . . . En ) using the Inclusion-Exclusion Principle. For any k , P (Ek ) = Suppose k = , then P (Ek E ) = (n 2)! , n! (n 1)! , n!

where ik = k .

F = E1 E2 . . . En ;

More generally, for any subset {i1 , i2 , . . . , ir } (where r n): P (Ei1 Ei2 . . . Eir ) = This is same value for any subset of size r .
Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 30 / 1

(n r )! . n!

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Example 2 Events
For each r n, there are same probability. So, r =
n r

Example 2 concluded
subsets of size r , and each has the For n musicians, the probability that NO two pick their own name is 11+ 1 1 1 + . . . + (1)n . 2! 3! n!

n! (n r )! 1 = . (n r )! r ! n! r!

Compare this to the power series expansion ex = 1 + x + and you get as n , 11+ 1 1 1 + . . . + (1)n e1 0.36788!! 2! 3! n! xn x2 x3 + + ... + + ..., 2! 3! n!

By the Inclusion-Exclusion Principle P (F ) = 1 P E1 E2 . . . En = 1 1 + 2 . . . + (1)n n 1 1 1 = 11+ + . . . + (1)n 2! 3! n!

So, the probability that no musicians draw their name converges to e1 as n .


Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 31 / 1 Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 32 / 1

Inclusion-Exclusion Principle general case

Inclusion-Exclusion Principle general case

Example 3

Example 3 continued
Pr be the probability that none of r musicians draw their own name:

Example 3. What is the probability that exactly k musicians from Example 2 draw their own name?

Pr = 1 1 +

1 1 1 + . . . + (1)r . 2! 3! r!

So, the number of ways these musicians can draw is r ! Pr . The probability that musicians i1 , i2 , . . . , ik draw their own name is P (Ei1 Ei2 . . . Eik ) = (n k )! . n! The number of ways that exactly k musicians i1 , i2 , . . . , ik selected from n draw their own name is (none of the n k others draw theirs)
(n k )! Pnk

independently of the choice of musicians i1 , i2 , . . . , ik . However, this leaves open the possibility that other musicians draw their own name.

The probability that only these k musicians draw their own name is
(n k )! Pnk . n!

This is the same probability for any k musicians selected.


Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 33 / 1 Kenneth Harris (Math 425) Math 425 Introduction to Probability Lecture 7 January 23, 2009 34 / 1

Inclusion-Exclusion Principle general case

Example 3 continued
The probability that exactly k musicians are selected is n (n k )! Pnk k n! = = n! (n k )! Pnk (n k )!k ! n! Pn k k! 11+ =
1 2!

1 3!

1 + . . . + (1)(nk ) (n k )!

k!

So, the probability that exactly k musicians draw their name 1 converges to ek ! as n .

Kenneth Harris (Math 425)

Math 425 Introduction to Probability Lecture 7

January 23, 2009

35 / 1

You might also like