Learn on your own. Parents beside you. Teachers guide.

Lemonmath
Tiếng Việt

Union, intersection and independent events

Lesson 9.1 · 25 min read · Updated

Suppose that in a class of 4040 students, 2525 like football, 1818 like basketball and 88 like both (assumed figures). A student is chosen at random. What is the probability that the student likes at least one of the two sports? Are the two preferences independent? To answer, we need the language of union, intersection and independent events.

Exploration: two events on the same die

Roll a fair die, which has 66 equally likely outcomes. Let AA be "the number is even" and BB be "the number is at least 44".

Number 11 22 33 44 55 66
In AA no yes no yes no yes
In BB no no no yes yes yes

The outcomes favourable to AA are {2,4,6}\{2,4,6\} and to BB are {4,5,6}\{4,5,6\}. The outcomes in at least one of the events are {2,4,5,6}\{2,4,5,6\}; those in both are \{4,6\}. These two sets give two new events.

Union and intersection

The set of outcomes favourable to A\cup B is the union of the sets favourable to A and to B; the set for A\cap B is their intersection. In the die example, A\cup B=\{2,4,5,6\} and A\cap B=\{4,6\}.

An event A and its complement \overline A are always mutually exclusive, and P(A)+P(\overline A)=1.

If A and B are independent, then the pairs A and \overline B, \overline A and B, \overline A and \overline B are also independent.

Examples

First, a union and an intersection on a die.

Next, a deck of cards.

Now mutually exclusive events.

Then testing independence.

Finally, we return to the survey from the start, in four steps.

Connections. This lesson uses the classical definition of probability and counting outcomes from earlier lessons. The lesson on the addition rule will turn the count n(A\cup B)=n(A)+n(B)-n(A\cap B) into the formula P(A\cup B)=P(A)+P(B)-P(AB). In practice, surveys, quality control and risk forecasts all need us to tell unions, intersections and independence apart.

Terms

Summary

  • A\cup B: at least one of the events occurs; A\cap B (or AB): both occur; \overline A: A does not occur.
  • A, B are mutually exclusive if A\cap B=\varnothing, and then P(AB)=0.
  • A, B are independent if and only if P(AB)=P(A)\,P(B).
  • If A, B are independent, so are A and \overline B; mutually exclusive and independent are different ideas.
  • Counting a union: n(A\cup B)=n(A)+n(B)-n(A\cap B).

Practice

Each exercise has the knowledge needed and hints on the steps. Try it yourself first, then open the solution.

Exercise 1

Roll a fair die. Let A be "the number is divisible by 3" and B be "the number is odd". Describe A\cup B and A\cap B and find their probabilities.

What you need and how to start

Knowledge: list the favourable outcomes; union and intersection.

Hints on the steps:

  1. List A and B.
  2. Find the union and the intersection, then divide by 6.
Show solution

The sample space is \Omega=\{1,2,3,4,5,6\}, which has 6 equally likely outcomes.

The event A, "the number is divisible by 3", gives A=\{3,6\}. The event B, "the number is odd", gives B=\{1,3,5\}.

The union A\cup B is the event "the number is divisible by 3 or is odd", consisting of the outcomes in at least one of the two sets: A\cup B=\{1,3,5,6\}.

The intersection A\cap B is the event "the number is both divisible by 3 and odd", consisting of the outcomes in both sets: A\cap B=\{3\}.

Hence n(A\cup B)=4 and n(A\cap B)=1, so P(A\cup B)=\frac46=\frac23,\qquad P(A\cap B)=\frac16.

So P(A\cup B)=\dfrac23 and P(A\cap B)=\dfrac16.

Answer. \dfrac23 and \dfrac16.

Exercise 2

A card is drawn at random from a standard deck of 52 cards. Let A be "a spade" and B be "a jack, queen or king". Find P(A\cup B) and P(A\cap B).

What you need and how to start

Knowledge: n(A\cup B)=n(A)+n(B)-n(A\cap B).

Hints on the steps:

  1. Count n(A)=13 and n(B)=12.
  2. Count the intersection: the jack, queen and king of spades.
Show solution

A standard deck has 52 cards, each equally likely to be drawn, so n(\Omega)=52.

The event A, "a spade", has n(A)=13. The event B, "a jack, queen or king", has n(B)=3\cdot4=12 cards (each rank comes in 4 suits).

The intersection A\cap B is "a spade that is a jack, queen or king", consisting of the jack, queen and king of spades, so n(A\cap B)=3.

By the addition rule, we have n(A\cup B)=n(A)+n(B)-n(A\cap B)=13+12-3=22.

Hence P(A\cup B)=\frac{22}{52}=\frac{11}{26},\qquad P(A\cap B)=\frac{3}{52}.

So P(A\cup B)=\dfrac{11}{26} and P(A\cap B)=\dfrac3{52}.

Answer. \dfrac{11}{26} and \dfrac3{52}.

Exercise 3

A fair coin is tossed three times. Let A be "at least two heads" and B be "the first toss is a tail". Find P(A\cup B) and P(A\cap B).

What you need and how to start

Knowledge: there are 8 equally likely outcomes.

Hints on the steps:

  1. List the outcomes favourable to A and to B (H: head, T: tail).
  2. Find the union and the intersection.
Show solution

Let H denote heads and T denote tails. Tossing a fair coin three times gives 2^3=8 equally likely outcomes.

The event A, "at least two heads", gives A=\{HHH,HHT,HTH,THH\}, which has 4 outcomes.

The event B, "the first toss is a tail", gives B=\{THH,THT,TTH,TTT\}, which has 4 outcomes.

The only outcome in both A and B is THH, so A\cap B=\{THH\} and n(A\cap B)=1.

The union has n(A\cup B)=4+4-1=7 outcomes.

Hence P(A\cup B)=\frac78,\qquad P(A\cap B)=\frac18.

So P(A\cup B)=\dfrac78 and P(A\cap B)=\dfrac18.

Answer. \dfrac78 and \dfrac18.

Exercise 4

Decide whether each statement is true or false.

a) The event A\cup B occurs when at least one of A, B occurs.

b) If A\cap B=\varnothing then A and B are always independent.

c) If P(AB)=P(A)\,P(B) then A and B are independent.

d) The event A\cup B occurs only when both A and B occur.

What you need and how to start

Knowledge: the definitions.

Hints on the steps:

  1. Compare each statement with the definition.
  2. Distinguish mutually exclusive from independent.
Show solution

a) True. By definition, the union A\cup B occurs exactly when at least one of A, B occurs.

b) False. If A\cap B=\varnothing (the events are mutually exclusive) then P(AB)=0. Two events are independent when P(AB)=P(A)P(B); if P(A)>0 and P(B)>0 then P(A)P(B)>0, which differs from P(AB)=0. For example, roll a fair die with A=\{1\} and B=\{2\}: A\cap B=\varnothing but P(AB)=0\ne\dfrac1{36}=P(A)P(B).

c) True. By definition, the events A and B are independent when P(AB)=P(A)\,P(B).

d) False. The event A\cup B occurs when at least one of the two events occurs, not necessarily both. The event "both A and B occur" is the intersection A\cap B.

So statements a), c) are true; statements b), d) are false.

Answer. a) True; b) False; c) True; d) False.

Exercise 5

Suppose two marksmen shoot independently at the same target; the probability of a hit is 0.8 for the first and 0.7 for the second (assumed figures). Find the probability that both hit and the probability that both miss.

What you need and how to start

Knowledge: if A, B are independent then P(AB)=P(A)P(B); \overline A, \overline B are also independent.

Hints on the steps:

  1. Find P(AB).
  2. Find P(\overline A), P(\overline B) and multiply.
Show solution

Let A be the event "the first marksman hits" and B the event "the second marksman hits". We are given P(A)=0.8, P(B)=0.7, and A, B are independent.

Both hit is the event AB. Since A and B are independent, P(AB)=P(A)\,P(B)=0.8\cdot0.7=0.56.

Both miss is the event \overline A\,\overline B. We have P(\overline A)=1-0.8=0.2 and P(\overline B)=1-0.7=0.3. Since A and B are independent, so are \overline A and \overline B, hence P(\overline A\,\overline B)=P(\overline A)\,P(\overline B)=0.2\cdot0.3=0.06.

So the probability that both hit is 0.56 and the probability that both miss is 0.06.

Answer. 0.56 and 0.06.

Exercise 6

Roll a fair die twice. Let A be "the sum of the two rolls is 7" and B be "the second roll is 6". Are the two events independent?

What you need and how to start

Knowledge: compare P(AB) with P(A)P(B).

Hints on the steps:

  1. Find P(A) and P(B).
  2. Find the intersection: only (1,6).
Show solution

Rolling a fair die twice gives 6\cdot6=36 equally likely outcomes, each a pair (i, j) where i is the first roll and j is the second roll.

The event A, "the sum of the two rolls is 7", consists of the 6 outcomes (1, 6), (2, 5), (3, 4), (4, 3), (5, 2), (6, 1), so P(A)=\dfrac{6}{36}=\dfrac16.

The event B, "the second roll is 6", consists of the 6 outcomes (1, 6), (2, 6), \ldots, (6, 6), so P(B)=\dfrac{6}{36}=\dfrac16.

The only outcome in both A and B is (1, 6), so A\cap B=\{(1, 6)\} and P(AB)=\dfrac1{36}.

We have P(A)\,P(B)=\dfrac16\cdot\dfrac16=\dfrac1{36}=P(AB).

So the events A and B are independent.

Answer. Yes, the events are independent.

Exercise 7

Suppose that in a class of 30 students, 18 learn chess, 12 learn music and 5 learn both (assumed figures). A student is chosen at random. Find the probability that the student learns at least one of the two, and the probability that the student learns neither.

What you need and how to start

Knowledge: n(A\cup B)=n(A)+n(B)-n(A\cap B); complementary events.

Hints on the steps:

  1. Count the students who learn at least one.
  2. Use the complement.
Show solution

Let A be the event "the chosen student learns chess" and B the event "the chosen student learns music". We are given n(A)=18, n(B)=12, n(A\cap B)=5 and n(\Omega)=30.

The event "learns at least one of the two" is A\cup B. By the addition rule, the number of students who learn at least one is n(A\cup B)=n(A)+n(B)-n(A\cap B)=18+12-5=25.

Hence P(A\cup B)=\frac{25}{30}=\frac56.

The event "learns neither" is the complement of A\cup B, so P\left(\overline{A\cup B}\right)=1-P(A\cup B)=1-\frac56=\frac16.

So the probability that the student learns at least one of the two is \dfrac56, and the probability that the student learns neither is \dfrac16.

Answer. \dfrac56 and \dfrac16.

Exercise 8

Revisit fractions. Two cards are drawn one after the other from a standard deck of 52 cards, each card being returned to the deck after it is drawn. Find the probability that both cards are hearts.

What you need and how to start

Knowledge: with replacement, the two draws are independent.

Hints on the steps:

  1. Find the probability of a heart on one draw.
  2. Multiply the two probabilities.
Show solution

Let A_1 be the event "the first card is a heart" and A_2 the event "the second card is a heart".

The deck has 52 cards, of which 13 are hearts. Each card is returned to the deck after it is drawn, so the deck always has all 52 cards and the second draw does not depend on the first. Hence A_1 and A_2 are independent and P(A_1)=P(A_2)=\frac{13}{52}=\frac14.

Both cards being hearts is the event A_1A_2, so P(A_1A_2)=P(A_1)\,P(A_2)=\frac14\cdot\frac14=\frac1{16}.

So the probability that both cards are hearts is \dfrac1{16}.

Answer. \dfrac1{16}.

Exercise 9 Challenge

Prove that if A and B are independent, then A and \overline B are also independent.

What you need and how to start

Knowledge: A=AB\cup A\overline B and these two events are mutually exclusive, so P(A)=P(AB)+P(A\overline B).

Hints on the steps:

  1. Express P(A\overline B) using P(A) and P(AB).
  2. Substitute P(AB)=P(A)P(B).
Show solution

Suppose A and B are independent, that is P(AB)=P(A)\,P(B). We need to prove that P(A\overline B)=P(A)\,P(\overline B).

The event A is the union of the two mutually exclusive events AB and A\overline B (according to whether B occurs or not), so P(A)=P(AB)+P(A\overline B),\ \text{hence}\ P(A\overline B)=P(A)-P(AB).

Substituting P(AB)=P(A)\,P(B), we obtain \begin{aligned}P(A\overline B)&=P(A)-P(A)\,P(B)\\&=P(A)\,\bigl(1-P(B)\bigr)\\&=P(A)\,P(\overline B).\end{aligned}

So if A and B are independent, then A and \overline B are also independent.

Answer. Proved.

Mini test

Mini test

Marked like the Vietnamese graduation exam: Part I 0.25 points per question; Part II up to 1 point per question (1, 2, 3, 4 correct statements give 0.1, 0.25, 0.5, 1 point); Part III 0.5 points per question.

Part I. Multiple choice

Question 1. The event A\cup B occurs when
Question 2. Roll a fair die. Let A be "the number is even" and B be "the number is at least 4". The probability P(A\cap B) is
Question 3. A card is drawn from a standard deck of 52 cards. Let A be "a heart" and B be "a king". The probability P(A\cup B) is
Question 4. Two events A, B are independent if and only if

Part II. True or false

Question 1. Decide whether each statement is true or false:
a) The intersection A\cap B occurs when both A and B occur.
b) A and its complement \overline A are always mutually exclusive.
c) Two mutually exclusive events with positive probabilities are always independent.
d) If A and B are independent then A and \overline B are also independent.

Part III. Short answer

Question 1. Independent events A, B have P(A)=0.6 and P(B)=0.5. Find P(AB).

Question 2. Suppose that in a survey of 50 people, 30 use app X, 24 use app Y and 14 use both. One person is chosen at random. Find the probability that the person uses at least one app.

Show answers and explanations
  1. Part I, question 1: A. This is the definition of the union. Option C is the intersection, and B and D are other events.
  2. Part I, question 2: B. A\cap B=\{4,6\}, so P=\dfrac26=\dfrac13. Option D is P(A\cup B), A is P(A), and C counts only one outcome.
  3. Part I, question 3: C. n(A\cup B)=13+4-1=16, so P=\dfrac{16}{52}=\dfrac4{13}. Option B forgets to subtract the common card, A is P(AB), and D is P(B).
  4. Part I, question 4: D. This is the condition for independence. Options A and B describe mutually exclusive events, and C holds only for mutually exclusive events.
  5. Part II, question 1: a) True; b) True; c) False; d) True. a) True by definition. b) True, since A and \overline A cannot occur together. c) False: then P(AB)=0\neq P(A)P(B). d) True by the property.
  6. Part III, question 1: 0.3. P(AB)=0.6\cdot0.5=0.3.
  7. Part III, question 2: 0.8. 30+24-14=40 people, so the probability is \dfrac{40}{50}=0.8.
📈 My progress

Finding Lemonmath useful?

Send this page to a friend, a parent or a teacher who could use it. Studying on your own is easier with company, and Lemonmath is free for everyone.

Facebook ✉ Email