Back to homeMathematics · Algebra 2 · Change subject
Start for free
Algebra 2 · Mathematics
Probability · Probability

Dependent and Independent Events

Before you start, make sure you know: Compound events (Geometry)
Before you start, make sure you know: Dependence (Geometry)

You flip a coin and get heads three times in a row. Is tails "due" on the next flip? Now deal two cards from a deck: if the first is an ace, is the second one just as likely to be an ace? In one case the past doesn't matter, and in the other it does. This page shows you how to tell the difference, and how that changes the way you calculate $P(A \cap B)$.

What does independent mean?

Two events are independent when knowing that one happened does not change the probability of the other. If knowing it does change the probability, the events are dependent.

Two boxes comparing independent events, where knowing B does not change P(A), with dependent events, where it does. independent P(A|B) = P(A) knowing B changesnothing dependent P(A|B) ≠ P(A) knowing B changesthe probability

A two-way table (some problems call it a contingency table) is a great place to test independence. Here are 100 students at a high school, sorted by grade and by whether they have a part-time job:

Juniors Seniors Total
Has a job 30 20 50
No job 30 20 50
Total 60 40 100
Practice★☆☆Not started
A survey has been carried out in a high school on the use of two social networks: Instagram ($I$) and TikTok ($T$). The results show that $70\%$ of the students use…

A survey has been carried out in a high school on the use of two social networks: Instagram ($I$) and TikTok ($T$). The results show that $70\%$ of the students use Instagram, $50\%$ use TikTok and $35\%$ use both platforms. Determine whether the use of Instagram is independent of the use of TikTok in this school.

Solve
Practice★☆☆Not started
Observe the following contingency table showing the preferred type of sport for a group of 100 teenagers: | | Soccer ($F$) | Basketball ($B$) | TOTAL |…

Observe the following contingency table showing the preferred type of sport for a group of 100 teenagers:

Soccer ($F$) Basketball ($B$) TOTAL
Boys ($H$) 45 15 60
Girls ($M$) 30 10 40
TOTAL 75 25 100

A teenager is chosen at random. Calculate:

  1. a) $P(F)$, the probability that they like soccer.
  2. b) $P(F|H)$, the probability that they like soccer knowing that they are a boy.
  3. c) In view of the results, are the events "being a boy" and "liking soccer" independent?
Solve
Practice★★☆Not started
In a high school in Chicago, a study was conducted on the use of social media platforms and the grade level of the students, obtaining the following data: | | 11th Grade…

In a high school in Chicago, a study was conducted on the use of social media platforms and the grade level of the students, obtaining the following data:

11th Grade 12th Grade Total
TikTok 72 48 120
Instagram 48 32 80
Total 120 80 200

A student is chosen at random. Determine whether the event "preferring TikTok" is independent of the event "being in 11th grade."

Solve

The product rule for independent events

For any two events, $P(A \cap B) = P(A)\cdot P(B \mid A)$. When $A$ and $B$ are independent, $P(B \mid A)$ is just $P(B)$, so the rule gets simpler.

The product rule is an area idea. Say Jayden makes a free throw with probability $0.75$ and Emma makes hers with probability $0.60$, independently. Cut a unit square by width for Jayden and by height for Emma. Each region's area is the probability of that combination.

A square split by width 0.75 and 0.25 for Jayden and by height 0.60 and 0.40 for Emma, showing that each region's area is a product of probabilities. 0.75 × 0.60 = 0.45 0.75 × 0.40 = 0.30 0.15 0.10 Jayden makes 0.75 miss 0.25 Emma makes 0.60 Emma misses 0.40

The picture also shows something useful: the other three regions are products too. If $A$ and $B$ are independent, then $A$ and $\overline{B}$ are independent, and so are $\overline{A}$ and $B$, and $\overline{A}$ and $\overline{B}$. (The complement of $A$ is also written $A'$ or $A^c$.)

Practice★☆☆Not started
Let $A$ and $B$ be two events associated with a random experiment. We know that the probability of event $A$ occurring is $P(A) = 0,6$ and the probability of event $B$…

Let $A$ and $B$ be two events associated with a random experiment. We know that the probability of event $A$ occurring is $P(A) = 0,6$ and the probability of event $B$ occurring is $P(B) = 0,3$. If it is known that the events are independent, calculate the probability that both occur at the same time, that is, $P(A \cap B)$.

Solve
Practice★☆☆Not started
An 11th-grade student has two exams on the same day: Math and English. The probability of passing Math is $P(M) = 0,7$ and of passing English is $P(I) = 0,8$. Assuming…

An 11th-grade student has two exams on the same day: Math and English. The probability of passing Math is $P(M) = 0,7$ and of passing English is $P(I) = 0,8$. Assuming that passing one exam does not influence the result of the other:

  1. a) Calculate the probability of passing both exams.
  2. b) Calculate the probability of passing neither of them.
Solve
Practice★☆☆Not started
In a quality control check at a light bulb factory, it is known that the probability of a light bulb being defective is $0,02$. If two light bulbs are chosen at random,…

In a quality control check at a light bulb factory, it is known that the probability of a light bulb being defective is $0,02$. If two light bulbs are chosen at random, calculate the probability that:

  1. a) Neither is defective.
  2. b) Both are defective.

(Note: The batch size is so large that the extraction of one light bulb can be considered not to affect the probability of the next).

Solve

"At least one" and "exactly one"

Problems about backups, alarms, or multiple chances often ask for "at least one." The shortcut is the complement: "at least one" is everything except "none."

Why does this work? The outcomes "none," "exactly one," and "both" cover all possibilities, so their probabilities add to 1. Computing "none" with a single product is much quicker than adding up everything else.

A bar split into three parts: both work 0.765, exactly one works 0.22, and neither works 0.015. both work 0.765 exactly one 0.22 neither 0.015 at least one works = 1 − 0.015 = 0.985
Practice★★☆Not started
Two electronic components of a drone, $A$ and $B$, work independently. The probability that component $A$ fails is $0,05$ and the probability that component $B$ fails is…

Two electronic components of a drone, $A$ and $B$, work independently. The probability that component $A$ fails is $0,05$ and the probability that component $B$ fails is $0,08$.

  1. a) Calculate the probability that the drone can continue flying if it is necessary for at least one of the two components to work correctly.
  1. b) Calculate the probability that exactly one of the two components fails.
Solve
Practice★★☆Not started
A high school student has two independent alarms on their cell phone. The first ($D_1$) works $95\%$ of mornings and the second ($D_2$) works $90\%$ of the time. a)…

A high school student has two independent alarms on their cell phone. The first ($D_1$) works $95\%$ of mornings and the second ($D_2$) works $90\%$ of the time.

  1. a) Calculate the probability that the student oversleeps because neither of the two alarms goes off.
  1. b) If we know that at least one of the alarms has gone off, what is the probability that alarm $D_1$ has failed?
Solve

With and without replacement

Drawing from a jar is the cleanest way to see independence and dependence. Everything depends on whether the item goes back.

  • With replacement: the jar is the same for every draw, so draws are independent.

  • Without replacement: the jar changes after each draw, so draws are dependent.

For dependent events we use the general rule:

A few problems use a different deck, so here is how to read it.

Sometimes the unknown is the number of items. Then the probability rule gives you an equation.

Practice★☆☆Not started
In a gumball machine there are balls of three colors: 10 red, 6 blue and 4 green. A child takes out a gumball, notes its color, puts it back into the machine and takes…

In a gumball machine there are balls of three colors: 10 red, 6 blue and 4 green. A child takes out a gumball, notes its color, puts it back into the machine and takes out a second gumball.

  1. a) Justify whether the events "drawing a red ball first" and "drawing a blue ball second" are dependent or independent.
  2. b) Calculate the probability that the first gumball is blue and the second is green.
Is replaced (Replacement) 10 Rojas 6 Azules 4 Verdes Total: 20 Draws 1ª 2ª
Solve
Practice★☆☆Not started
We draw two cards from a 40-card Spanish deck, one after the other and without replacing the first one in the deck. a) What is the probability that the first card is a…

We draw two cards from a 40-card Spanish deck, one after the other and without replacing the first one in the deck.

  1. a) What is the probability that the first card is a King?
  2. b) Knowing that the first card was a King, what is the probability that the second is also a King?
  3. c) Are these events dependent or independent?
Solve
Practice★★★Not started
An urn contains $n$ white balls and $6$ black balls. Two balls are drawn successively without replacement. Knowing that the probability of both balls being white is…

An urn contains $n$ white balls and $6$ black balls. Two balls are drawn successively without replacement. Knowing that the probability of both balls being white is exactly $\frac{1}{3}$, determine using an algebraic equation how many white balls were initially in the urn.

... n white 6 black Total: n + 6 balls B₁ n n+6 B₂ n-1 n+5 Probability equation P(B₁ ∩ B₂) = n n+6 n-1 n+5 = 1 3
Solve

Tree diagrams

A tree diagram organizes a multi-stage experiment. Each stage is a set of branches. The labels on the second set of branches are conditional probabilities, because they depend on where you came from.

Here is the tree for a bag of $4$ green (G) and $6$ orange (O) jelly beans, drawing two without replacement.

Tree diagram for drawing two jelly beans without replacement from 4 green and 6 orange, with the probability of each branch and each outcome. 4/10 6/10 3/9 6/9 4/9 5/9 G O G O G O G then G: 4/10 · 3/9 = 12/90 G then O: 4/10 · 6/9 = 24/90 O then G: 6/10 · 4/9 = 24/90 O then O: 6/10 · 5/9 = 30/90
Practice★☆☆Not started
In a drawer in a clothing store fitting room, 4 black socks and 2 white socks were left behind, all of the same size and texture. If a store associate reaches in and…

In a drawer in a clothing store fitting room, 4 black socks and 2 white socks were left behind, all of the same size and texture. If a store associate reaches in and draws two socks at random, one after the other and without looking:

  1. a) Complete the following tree diagram with the corresponding probabilities.
  2. b) Calculate the probability that the two socks drawn are black.
Drawer 4N, 2B 4/6 ? ? ? ? ? Black (N₁) White (B₁) N₂ B₂ N₂ B₂ (N₁, N₂) (N₁, B₂) (B₁, N₂) (B₁, B₂)
Solve
Practice★★☆Not started
An urn contains 5 yellow balls and 3 purple balls. We draw two balls from the urn consecutively and without replacement. a) Draw the tree diagram corresponding to this…

An urn contains 5 yellow balls and 3 purple balls. We draw two balls from the urn consecutively and without replacement.

  1. a) Draw the tree diagram corresponding to this experiment, indicating the probability of each branch.
  1. b) Calculate the probability that the two balls drawn are the same color.
URN 5 3 Total: 8 DRAW Without replacement 1ª 2ª
Solve
Practice★★☆Not started
We draw two cards from a 40-card Spanish deck, one after the other and without replacing the first. a) What is the probability that the second card is a King, knowing…

We draw two cards from a 40-card Spanish deck, one after the other and without replacing the first.

  1. a) What is the probability that the second card is a King, knowing that the first card was the Ace of Coins?
  1. b) What is the probability of obtaining two face cards (Jack, Knight or King) of different suits?
40 cards 39 cards Without replacement 40 - 1 = 39 P(C₁) C₁ 1st Card P(C₂|C₁) C₂ 2nd Card
Solve

When the second probability depends on the first

Dependence isn't only about jars. Anything where "what happened first" changes the odds works the same way: a player who gets nervous, a game with a streak bonus, a network that gets congested. You just draw the tree with the stated conditional probabilities.

If you want the probability of the second event no matter what happened first, add up both paths that end in it.

Tree diagram for Liam's bus over two days, where Tuesday's probabilities depend on Monday's result. 0.8 0.2 0.9 0.1 0.6 0.4 T L T L T L T,T: 0.8 · 0.9 = 0.72 T,L: 0.8 · 0.1 = 0.08 L,T: 0.2 · 0.6 = 0.12 L,L: 0.2 · 0.4 = 0.08

A chain of three or more steps works the same way: multiply along the whole path, using the probability that applies at that step.

Sometimes the first stage has more than two possibilities, such as an item that comes from one of three factories. Total probability extends in the obvious way: if $F_1, F_2, F_3$ cover every possibility and don't overlap, add one path for each.

Practice★★☆Not started
A video game programmer is testing a character's "critical hit" system. The character has a probability of $0,2$ of landing a critical hit ($C$). However, the system is…

A video game programmer is testing a character's "critical hit" system. The character has a probability of $0,2$ of landing a critical hit ($C$). However, the system is designed so that, if the last hit was critical, the probability of the next one also being critical drops to $0,1$ due to the skill's cooldown. If the last hit was not critical, the probability of the next one remains at $0,2$.

  1. a) Are the events "first critical hit" and "second critical hit" independent? Reason your answer.
  1. b) Calculate the probability that, in a sequence of two hits, the character does not land any critical hits.
Solve
Practice★★★Not started
A two-factor authentication security system sends a code to the user's cell phone. If the first message does not arrive (which happens with a probability of $0,12$), the…

A two-factor authentication security system sends a code to the user's cell phone. If the first message does not arrive (which happens with a probability of $0,12$), the system attempts a second delivery. However, due to network congestion, if the first delivery failed, the probability of the second also failing increases to $0,45$. On the other hand, if the first delivery was successful, the probability of the user receiving a second confirmation message is $0,98$.

Calculate the probability that a user receives the second message, regardless of what happened with the first one.

Solve
Practice★★★Not started
In a popular strategy video game, players open "legendary chests" to obtain rewards. The probability of obtaining an S-tier hero in the first chest is only $0,05$.…

In a popular strategy video game, players open "legendary chests" to obtain rewards. The probability of obtaining an S-tier hero in the first chest is only $0,05$. However, the game has an "accumulated luck" system: if you do not obtain the hero in a chest, the probability of obtaining it in the next one increases by $0,02$ with respect to the probability of the previous chest. If you obtain the hero, the probability returns to $0,05$ for the next attempt.

Calculate the probability that a player needs to open exactly three chests to obtain their first S-tier hero.

ACCUMULATED LUCK SYSTEM +0,02 +0,02 P(S) = 0.05 P(S) = 0.07 P(S) = 0.09 Chest 1 ❌ Chest 2 ❌ Chest 3 ⭐ S 1 - 0,05 P(Miss₁) = 0.95 1 - 0,07 P(Miss₂) = 0.93 Hero obtained! P(Success₃) = 0.09 × × P(Total) = 0.95 × 0.93 × 0.09
Solve

Working backward: reverse conditional probability

The tree gives probabilities in order: first stage, then second. But many questions go backward: "Given that the email was flagged, what is the probability it was really spam?" To reverse the condition, use

$$P(A \mid B) = \frac{P(A \cap B)}{P(B)}$$

with $P(B)$ found from all the paths that end in $B$. This reverse step is often called Bayes' theorem.

A bar of all flagged emails, 0.313, split into spam 0.285 and not spam 0.028, showing the conditional probability as the spam share of the bar. all flagged emails: 0.313 spam spam and flagged 0.285 not spam 0.028 P(spam | flagged) = 0.285 / 0.313 ≈ 0.911

Sometimes the condition covers more than one path. Then the denominator adds all of them.

The same idea works with three sources. In the headphones example, given that a pair is defective, the chance it came from $F_3$ is $\dfrac{0.010}{0.021} \approx 0.476$.

Practice★★★Not started
In a basketball training session, a player shoots two consecutive free throws. The probability of scoring the first is $0,7$. If they score the first, their confidence…

In a basketball training session, a player shoots two consecutive free throws. The probability of scoring the first is $0,7$. If they score the first, their confidence increases and the probability of scoring the second is $0,8$. If they miss the first, they get nervous and the probability of scoring the second drops to $0,4$.

If we know that the player has scored only one of the two shots, what is the probability that it was the second one?

PROBABILITY TREE: FREE THROWS 1st Shot 2nd Shot Start Scores 1st Misses 1st Scores 2nd Misses 2nd Scores 2nd Misses 2nd p = 0.7 p = ? Confidence increases p = 0.8 p = ? Gets nervous p = 0.4 p = ? KNOWN FACT: Has scored ONLY ONE (Either of these 2) Probability that it was el 2º tiro? = ?
Solve
Practice★★★Not started
In an intelligence center, facial recognition software analyzes images. The probability that it correctly identifies an individual if they are in the database is $0,95$.…

In an intelligence center, facial recognition software analyzes images. The probability that it correctly identifies an individual if they are in the database is $0,95$. However, the software has a margin of error and sometimes incorrectly identifies people who are not in the database with a probability of $0,02$.

Knowing that only $1\%$ of the people passing through customs are in the database, calculate:

  1. a) The probability that the software gives an alert (identifies someone).
  2. b) If the software has identified a person, what is the probability that they are actually in the database?
Solve
Practice★★★Not started
Three pharmaceutical laboratories ($L_1$, $L_2$ and $L_3$) manufacture the same type of antigen test. $L_1$ produces $45\%$ of the total, $L_2$ produces $30\%$ and $L_3$…

Three pharmaceutical laboratories ($L_1$, $L_2$ and $L_3$) manufacture the same type of antigen test. $L_1$ produces $45\%$ of the total, $L_2$ produces $30\%$ and $L_3$ produces the rest. It is known that the percentage of defective tests is $1\%$ for $L_1$, $2\%$ for $L_2$ and $3\%$ for $L_3$.

If we choose two tests at random from a large batch where all manufacturers are mixed (you can consider the extraction to be with replacement due to the large volume):

  1. a) What is the probability that both are defective?
  2. b) Knowing that the first one was defective, what is the probability that the second one is also defective? Justify whether these events are dependent or independent.
Solve

Finding probabilities from partial information

Often you are given $P(A)$, $P(B)$, and maybe $P(A \cup B)$, and have to build the rest. The key tool is the union formula:

$$P(A \cup B) = P(A) + P(B) - P(A \cap B)$$ Venn diagram of events A and B inside the sample space, showing A only, the overlap A and B, B only, and the outside region. S A only A ∩ B B only outside both: 1 − P(A ∪ B)

From the picture: the part of $A$ outside $B$ is $P(A \cap \overline{B}) = P(A) - P(A \cap B)$. That gives you conditional probabilities with a complement, such as $P(A \mid \overline{B}) = \dfrac{P(A \cap \overline{B})}{P(\overline{B})}$.

The overlap can't be just anything. It can't be bigger than the smaller event, and the union can't exceed $1$:

$$\max\{0,\ P(A) + P(B) - 1\} \le P(A \cap B) \le \min\{P(A),\ P(B)\}$$

If $P(A) + P(B) > 1$, then $P(A \cap B)$ must be positive, so $A$ and $B$ can never be mutually exclusive.

Practice★★☆Not started
On a music streaming platform, $60\%$ of users listen to the "Urban" genre ($U$) and $45\%$ listen to "Pop" ($P$). It is also known that $27\%$ of users listen to both…

On a music streaming platform, $60\%$ of users listen to the "Urban" genre ($U$) and $45\%$ listen to "Pop" ($P$). It is also known that $27\%$ of users listen to both musical genres.

  1. a) Determine whether the events "listening to Urban" and "listening to Pop" are independent. Justify your answer mathematically.
  1. b) If we select a user who we know listens to "Pop" music, what is the probability that they also listen to "Urban"?
Solve
Practice★★☆Not started
Let $A$ and $B$ be two events in a sample space such that $P(A) = 0,4$, $P(B) = 0,3$ and $P(A \cup B) = 0,58$. a) Calculate $P(A \cap B)$. b) Determine whether events…

Let $A$ and $B$ be two events in a sample space such that $P(A) = 0,4$, $P(B) = 0,3$ and $P(A \cup B) = 0,58$.

  1. a) Calculate $P(A \cap B)$.
  1. b) Determine whether events $A$ and $B$ are independent.
  1. c) Calculate the conditional probability $P(A | \bar{B})$, where $\bar{B}$ is the complementary event of $B$.
Solve
Practice★★★Not started
Two events $A$ and $B$ satisfy $P(A) = 0,6$ and $P(B) = 0,7$. Determine the interval of possible values for the probability of the intersection $P(A \cap B)$ and, based…

Two events $A$ and $B$ satisfy $P(A) = 0,6$ and $P(B) = 0,7$. Determine the interval of possible values for the probability of the intersection $P(A \cap B)$ and, based on this, reason why the events $A$ and $B$ can never be incompatible. What value should $P(A \cap B)$ have for $A$ and $B$ to be independent?

Ω A 0.6 B 0.7 A∩B P(A∩B) ∈ [0.3, 0.6] P(A) = 0.6 0.3 P(B) = 0.7 0 1
Solve

Several events at once

With three or more events, checking pairs isn't enough.

When outcomes are equally likely, you can test independence by counting the sample space. Roll two fair six-sided dice, so there are $36$ equally likely outcomes.

Also notice that the two dice themselves are independent: all outcome pairs are equally likely, so for any faces $i$ and $j$, $P(\text{first} = i \cap \text{second} = j) = P(\text{first} = i)\cdot P(\text{second} = j)$. This holds for a die with any number of faces.

Practice★★★Not started
Two tetrahedral dice (faces numbered 1 to 4) are rolled. Let the events be: $A$: "The sum of the faces is a prime number". $B$: "The product of the faces is a multiple…

Two tetrahedral dice (faces numbered 1 to 4) are rolled. Let the events be:

  • $A$: "The sum of the faces is a prime number".

  • $B$: "The product of the faces is a multiple of 4".

  • $C$: "At least one of the dice shows a 1".

Study the independence of events $A$ and $B$, and of events $B$ and $C$. Is there any relationship of dependence between the result of the first die and the result of the second? Explain it mathematically.

1 2 D₁ 3 4 D₂ 1 2 3 4 Result D₁ 1 2 3 4 Result D₂
Solve

Back to the start: tails is not due after three heads, because flips are independent. But the second card is less likely to be an ace after the first ace, because the deck changed. That change in the second probability is exactly what separates dependent events from independent ones.

Summary

See all the exercises in this section