Basics of probability

Random, certain and impossible events, classical probability, relative frequency and the law of large numbers, complementary events, the addition and multiplication rules, tree diagrams, counting with combinations and geometric probability.

  • Grades 9…11
  • 25 min
  • 12 questions
  • Lesson 35 of 92

In this lesson you will learn

  • Describe an experiment by its equally likely outcomes and compute probabilities with P(A) = m/n
  • Explain how relative frequency is related to probability (the law of large numbers)
  • Apply the complement, addition and multiplication rules and tree diagrams
  • Use combinations in selection problems and find simple geometric probabilities

Aysel and Murad are playing a board game. Aysel wins if she rolls a 6 on one die; Murad wins if the two dice he rolls add up to 7. Who has the better chance? And what does a forecast mean by “a 70% chance of rain”? Probability theory measures chance with a number from 0 to 1. In this lesson we go from a single die to multi-stage experiments, random selections and even areas. Collecting and describing data (tables, charts, the mean and the median) is the topic of the lesson “Basic statistics: data, charts and averages”.

Experiments, outcomes and events

A random experiment (a trial) is an action whose result cannot be predicted, although all its possible results are known in advance: tossing a coin, rolling a die, drawing a card from a shuffled pack. Each possible result is an outcome; the set of all outcomes is the sample space, often written Ω. For one die Ω = {1, 2, 3, 4, 5, 6}.

EventDefinition

Any set of outcomes, that is, a statement about the result that is either true or false once the experiment is over. The outcomes in which it happens are favourable to it. On a die, the event “an even number” = {2, 4, 6}.

  • A certain event is sure to happen: rolling a number less than 7 on a die. Its probability is 1.
  • An impossible event never happens: rolling a 7 on an ordinary die. Its probability is 0.
  • A random event may or may not happen: rolling a 6. Its probability is between 0 and 1.

The closer a probability is to 1, the more often the event occurs in a long series of trials; 0.5 means “half of the time”. Probabilities are also written as percentages: 0.7 = 70%. “A 70% chance of rain” means that on days with such a forecast it rains on about 7 days out of 10.

Sign up free to keep reading

The rest of the lesson, the quiz and your notes open with an Educora account. Signing up takes a minute, and your progress is saved on all your devices.

Classical probability

When all n outcomes are equally likely — a symmetric die, a well-shuffled pack, a ball taken without looking — none of them is favoured, so each gets the same share, 1/n. An event made of m outcomes gets m such shares. This gives the classical formula.

Simple explanation

Imagine a bag with 10 identical balls: 3 red and 7 blue. Shake it and take one ball without looking. No ball has an advantage over another, so each one has the same chance, 1 out of 10. Three of the balls are red, so the chance of a red ball is 3 out of 10: P(red) = 3/10. That is the whole meaning of the classical formula: the number of favourable outcomes divided by the number of all outcomes — but only when all outcomes are equally likely.

P(A) = m / nP(A) = m / n

Where

P(A)
the probability of event A
m
the number of outcomes favourable to A
n
the total number of equally likely outcomes

The classical formula works only when all outcomes are equally likely. Since 0 ≤ m ≤ n, always 0 ≤ P(A) ≤ 1.

One die

Problem

A die is rolled once. Find the probability of: 1) a 6; 2) an even number; 3) a number greater than 4; 4) a prime number.

Show solutionHide solution

Solution

All outcomes: 1, 2, 3, 4, 5, 6, so n = 6.
1) Only 6 is favourable: P = 1/6.
2) Even numbers 2, 4, 6: m = 3, P = 3/6 = 1/2.
3) Greater than 4: 5 and 6, so P = 2/6 = 1/3.
4) Primes 2, 3, 5 (1 is not a prime!): P = 3/6 = 1/2.

Numbered cards

Problem

A box holds 30 cards numbered 1 to 30. One card is drawn at random. Find the probability that its number: 1) is divisible by 3; 2) has two digits; 3) ends in 7; 4) is a perfect square.

Show solutionHide solution

Solution

n = 30.
1) 3, 6, …, 30 — that is 30 ÷ 3 = 10 numbers: P = 10/30 = 1/3.
2) 10, 11, …, 30 — 30 − 9 = 21 numbers: P = 21/30 = 7/10.
3) 7, 17, 27: P = 3/30 = 1/10.
4) 1, 4, 9, 16, 25: P = 5/30 = 1/6.

With two dice it helps to imagine them in different colours, say red and blue. Every outcome is an ordered pair (red, blue): each of the 6 results of the first die combines with each of the 6 results of the second, so there are n = 6 · 6 = 36 equally likely pairs. (1, 6) and (6, 1) are different outcomes.

Simple explanation

Imagine the two dice as one red and one blue. Write the red result in the row and the blue result in the column: you get a table of 6 · 6 = 36 cells, and every cell is equally likely. To find a probability, count cells. The table below shows the total score in every cell:

+123456
1234567
2345678
3456789
45678910
567891011
6789101112
Row — red die, column — blue die. The total 7 lies on the diagonal from the top right to the bottom left corner — 6 cells, so P(7) = 6/36 = 1/6. The cells (1, 6) and (6, 1) are different: red 1 with blue 6 is not the same as red 6 with blue 1.

Two dice

Problem

Two dice are rolled. Find the probability that: 1) the total is 7; 2) a double is rolled (both dice show the same number); 3) the total is 9; 4) both dice show more than 4.

Show solutionHide solution

Solution

n = 36.
1) (1, 6), (2, 5), (3, 4), (4, 3), (5, 2), (6, 1): m = 6, P = 6/36 = 1/6. So Murad’s chance is exactly the same as Aysel’s!
2) (1, 1), (2, 2), …, (6, 6): m = 6, P = 1/6.
3) (3, 6), (4, 5), (5, 4), (6, 3): P = 4/36 = 1/9.
4) Each die shows 5 or 6: m = 2 · 2 = 4, P = 4/36 = 1/9.

Interactive

Loading simulation…
These numbers are counted from the 36 pairs, not measured: each column is the number of pairs giving that total, and the probability is this number divided by 36. A total of 7 is the most likely (6/36 = 1/6), 2 and 12 the least likely (1/36 each).

Relative frequency and the law of large numbers

The classical formula needs symmetry. But what is the probability that a seed germinates or that a light bulb from a factory is faulty? There are no equally likely outcomes here, so the probability is estimated from experience: the trial is repeated many times and we count how often the event happens.

W(A) = k / NW(A) = k / N

Where

W(A)
the relative frequency of event A
k
the number of trials in which A happened
N
the total number of trials

The relative frequency is found after the trials and changes from one series to another; the probability is a fixed number. With many trials W(A) ≈ P(A): this is the statistical estimate of probability.

The law of large numbers: as the number of trials grows, the relative frequency of an event settles closer and closer to its probability. In 10 rolls a 6 may come up 3 times (0.3) — that is chance; in 6000 rolls it will come up roughly 1000 times, and the relative frequency will be near 1/6 ≈ 0.167.

Estimating probability from data

Problem

1) A factory checked 500 light bulbs and found 12 faulty ones. Estimate the probability that a bulb is faulty and the number of faulty bulbs in a batch of 10,000.
2) Elvin scored 45 free throws out of 60. About how many successful throws can be expected in his next 20?
3) A coin was tossed 50 times and showed heads 29 times. Does this prove that the coin is unfair?

Show solutionHide solution

Solution

1) W = 12/500 = 0.024 (2.4%). In 10,000 bulbs we expect about 0.024 · 10,000 = 240 faulty ones.
2) W = 45/60 = 0.75, so about 0.75 · 20 = 15 successful throws.
3) W = 29/50 = 0.58. In a short series such a deviation from 0.5 is quite normal; to judge the coin, far more tosses are needed. No, it does not.

Interactive

Loading simulation…
Roll 10 times, then 1000 times: with few rolls the bars jump around, with many they settle near the line 1/6 ≈ 0.167.
Going deeper
σ ≈ √(p(1 − p) / N)σ ≈ √(p(1 − p) / N)

Where

σ
the typical deviation of the relative frequency from p
p
the probability of the event
N
the number of trials

In about 95% of series the relative frequency differs from p by less than 2σ. At university this follows from the central limit theorem.

How close is “close”? For a coin (p = 0.5), N = 100 gives σ ≈ 0.05 and N = 10 000 gives σ ≈ 0.005: to make the error 10 times smaller you need 100 times more trials. In Pearson’s 24 000 tosses σ ≈ 0.003, and his result 0.5005 came out even closer. In problem 3 above, N = 50 gives σ ≈ 0.07, so 0.58 is only about one typical deviation away from 0.5 — nothing suspicious at all.

The complement, addition and multiplication rules

Complementary event ĀDefinition

The event “A does not happen”. In every trial exactly one of A and Ā occurs, so their probabilities add up to 1.

P(Ā) = 1 − P(A)

Where

Ā
the complement of A (“not A”)

Switch to the complement when “not A” or “none” is easier to count than A itself — especially in “at least one” problems.

Using the complement

Problem

1) A die is rolled. Find P(not a 6).
2) A box holds cards numbered 1 to 20. Find the probability that a random card’s number is not divisible by 5.
3) Two dice are rolled. Find the probability that the product of the numbers is even.

Show solutionHide solution

Solution

1) P(6) = 1/6, so P(not 6) = 1 − 1/6 = 5/6.
2) Divisible by 5: 5, 10, 15, 20, so P = 4/20 = 1/5; the answer is 1 − 1/5 = 4/5.
3) Counting even products directly takes long. The complement: the product is odd only when both numbers are odd — 3 · 3 = 9 pairs, P = 9/36 = 1/4. So P(even product) = 1 − 1/4 = 3/4.

Mutually exclusive eventsDefinition

Events that cannot happen in the same trial: “a 1” and “a 6” on one die. “An even number” and “a number greater than 3” are not mutually exclusive: both happen when a 4 or a 6 comes up.

Independent eventsDefinition

Events such that one happening does not change the probability of the other: the results of a coin and a die, two separate tosses, two shooters firing independently of each other.

P(A or B) = P(A) + P(B)

Where

A or B
at least one of A and B happens (also written A ∪ B or A + B)

The addition rule holds only for mutually exclusive events. If A and B can happen together, the common outcomes are counted twice and must be subtracted once: P(A or B) = P(A) + P(B) − P(A and B).

Simple explanation

Count the overlap once

Problem

A die is rolled. A = “an even number”, B = “a number greater than 3”. Find P(A or B).

Show solutionHide solution

Solution

A = {2, 4, 6}, B = {4, 5, 6}. Together they cover {2, 4, 5, 6} — 4 outcomes, so P = 4/6 = 2/3.
The formula gives the same: 3/6 + 3/6 − 2/6 = 4/6, because 4 and 6 belong to both events and must not be counted twice.

The addition rule

Problem

1) A bag holds 5 red, 3 green and 2 blue balls. One ball is drawn. Find P(red or blue).
2) The probability that Leyla gets a mark of 5 for a test is 0.3, and a mark of 4 is 0.45. Find the probability that she gets a 4 or a 5.
3) One card is drawn from cards numbered 1 to 20. Find the probability that its number is divisible by 2 or by 3.

Show solutionHide solution

Solution

1) “Red” and “blue” are mutually exclusive: 5/10 + 2/10 = 7/10.
2) One test cannot get both marks: 0.3 + 0.45 = 0.75.
3) 10 numbers are divisible by 2 and 6 by 3, but 6, 12 and 18 are in both lists — the events are not mutually exclusive! P = 10/20 + 6/20 − 3/20 = 13/20. (Simply writing 16/20 would be wrong.)
P(A and B) = P(A) · P(B)

Where

A and B
both events happen (also written AB or A ∩ B)

The multiplication rule is only for independent events. The probability that several events all happen is never larger than the smallest factor.

The multiplication rule

Problem

1) A coin is tossed and a die is rolled. Find P(heads and a 6).
2) Two shooters fire once each, independently; they hit the target with probabilities 0.8 and 0.7. Find the probability that both hit, that neither hits, and that at least one hits.
3) A coin is tossed 3 times. Find P(three heads) and P(at least one tails).

Show solutionHide solution

Solution

1) The coin and the die are independent: 1/2 · 1/6 = 1/12.
2) Both: 0.8 · 0.7 = 0.56. Neither: the misses have probabilities 0.2 and 0.3, so 0.2 · 0.3 = 0.06. At least one is the complement of “neither”: 1 − 0.06 = 0.94.
3) P(HHH) = 1/2 · 1/2 · 1/2 = 1/8; “at least one tails” is its complement: 1 − 1/8 = 7/8.
Going deeper

The Chevalier de Méré’s puzzle

Problem

Which is more likely: at least one six in 4 rolls of a die, or at least one double six in 24 rolls of two dice?

Show solutionHide solution

Solution

Use the complement and the multiplication rule.
One die, 4 rolls: P(no six) = (5/6)⁴ = 625/1296, so P(at least one six) = 671/1296 ≈ 0.518.
Two dice, 24 rolls: P(no double six) = (35/36)²⁴ ≈ 0.509, so P(at least one) ≈ 0.491.
The first bet is better, although “4 : 6 = 24 : 36” makes them look equal. This question, put to Blaise Pascal in 1654, is part of the story of how probability theory began.
Going deeper

The birthday paradox

Problem

There are 23 pupils in a class. What is the probability that at least two of them share a birthday? (Assume 365 equally likely days and ignore 29 February.)

Show solutionHide solution

Solution

The complement: all 23 birthdays are different. The first pupil’s birthday can be any day, the second must avoid 1 day, the third 2 days, and so on:
P(all different) = 365/365 · 364/365 · … · 343/365 ≈ 0.493.
So P(at least one shared birthday) ≈ 1 − 0.493 = 0.507 — more than a half with just 23 people! For 30 pupils it is already about 0.706, for 50 about 0.970. The reason: there are C(23, 2) = 253 pairs of pupils, and every pair is a chance for a match.

When an experiment has several stages (two draws, three tosses), draw a tree diagram. Each branch carries its probability; the branches leaving one point add up to 1. If balls are drawn without replacement, the second stage depends on the first: its probabilities change after the first draw.

Simple explanation

A tree is like a road map with forks: at every fork the chances of the roads leaving it add up to 1. To get the chance of a whole route, multiply the chances along it; if several routes lead to the result you want, add their chances. One more thing: if a ball is not put back, the bag changes — after a red ball is taken from 3 red and 2 blue, only 2 of the 4 remaining balls are red.

  1. Draw the stages

    One level of branches for each stage, one branch for each possible result.

  2. Write the probabilities

    On each branch write its probability, taking the earlier steps into account (without replacement, count what is left).

  3. Multiply along a path

    The probability of a whole path is the product of the probabilities on its branches.

  4. Add the paths

    If an event consists of several paths, add their probabilities. Check: all paths together give 1.

1st ball2nd ballOutcomeRBRRR3/10BRB3/10RBR3/10BBB1/103/52/52/42/43/41/43/10 + 3/10 + 3/10 + 1/10 = 1
R = red, B = blue ball. Multiply along a path: for example, RR = 3/5 · 2/4 = 3/10.

Working with the tree

Problem

Two balls are drawn without replacement from the bag in the diagram (3 red, 2 blue). Find the probability that: 1) both are red; 2) they are the same colour; 3) at least one is blue; 4) both are red if the first ball is put back before the second draw.

Show solutionHide solution

Solution

1) Path RR: 3/5 · 2/4 = 6/20 = 3/10.
2) RR or BB: 3/10 + 2/5 · 1/4 = 3/10 + 1/10 = 2/5.
3) The complement of “both red”: 1 − 3/10 = 7/10 (check: RB + BR + BB = 3/10 + 3/10 + 1/10 = 7/10).
4) With replacement the second draw is again 3/5: 3/5 · 3/5 = 9/25. The answer changed because the stages became independent.
Going deeper

A tree can also be read backwards: if we know how the experiment ended, which branch did it most probably take? This is the idea of Bayes’ formula from the university course, and the easiest way to apply it is to count people instead of probabilities.

A medical test

Problem

1% of people have a certain illness. A test detects it in 99% of ill people, but it also shows a false “positive” in 5% of healthy people. Murad’s test is positive. What is the probability that he is ill?

Show solutionHide solution

Solution

Imagine 10 000 people. Ill: 100, and 99 of them test positive. Healthy: 9900, and 5% of them, that is 495, test positive.
All positives: 99 + 495 = 594, and only 99 of them are ill: P = 99/594 = 1/6 ≈ 0.17.
So even after a positive test, Murad is ill with a chance of only about 17% — because healthy people are so much more numerous. That is why doctors repeat such tests.

Too many outcomes: combinations and geometric probability

There are 220 ways to choose 3 pupils out of 12 — no tree can show them all. Here n and m are counted with the formulas of the lesson “Combinatorics”: in a selection the order does not matter, so we use combinations C(n, k).

P = C(m, k) · C(n − m, r − k) / C(n, r)P = C(m, k) · C(n − m, r − k) / C(n, r)

Where

n
the total number of objects
m
how many of them are “special” (winning tickets, girls…)
r
how many objects are chosen at random
k
how many “special” ones are among the chosen

Denominator: all ways to choose r objects out of n. Numerator (product rule): choose k of the m special objects AND r − k of the other n − m.

Simple explanation

Write down the pairs

Problem

Of 5 tickets, 2 are winning (numbers 1 and 2) and 3 are empty (3, 4, 5). You take 2 tickets. What is the probability that both win? That exactly one wins?

Show solutionHide solution

Solution

All pairs: 1–2, 1–3, 1–4, 1–5, 2–3, 2–4, 2–5, 3–4, 3–5, 4–5 — 10 pairs = C(5, 2).
Both win: only 1–2, so P = 1/10 = C(2, 2) / C(5, 2).
Exactly one wins: 1–3, 1–4, 1–5, 2–3, 2–4, 2–5 — 6 pairs, so P = 6/10 = C(2, 1) · C(3, 1) / C(5, 2).
The formula simply counts this list without writing it down.

Random selections

Problem

1) Of 10 lottery tickets, 3 are winning. Nigar buys 2 tickets. Find P(both win) and P(exactly one wins).
2) A class has 5 girls and 7 boys; 3 pupils are chosen at random for classroom duty. Find P(all three are girls) and P(exactly two girls).
3) A 4-digit PIN (0000–9999) is chosen at random. Find the probability that all its digits are different.

Show solutionHide solution

Solution

1) n = C(10, 2) = 45. Both: C(3, 2) = 3, P = 3/45 = 1/15 (check with a tree: 3/10 · 2/9 = 1/15). Exactly one: C(3, 1) · C(7, 1) = 21, P = 21/45 = 7/15.
2) n = C(12, 3) = 220. Three girls: C(5, 3) = 10, P = 10/220 = 1/22. Two girls and a boy: C(5, 2) · C(7, 1) = 10 · 7 = 70, P = 70/220 = 7/22.
3) All PINs: 10⁴ = 10,000. With different digits (here the order matters): 10 · 9 · 8 · 7 = 5040. P = 5040/10,000 = 0.504.

Sometimes the outcomes cannot be counted at all: a point chosen at random on a segment, the moment you arrive at a bus stop. If every part of the region is equally likely, the probability is the share of the region taken by the favourable part — a ratio of lengths, areas or times.

P(A) = s / SP(A) = s / S

Where

s
the measure of the favourable part (length, area or time)
S
the measure of the whole region

Geometric probability is the “continuous” version of m/n; here too 0 ≤ P(A) ≤ 1.

Geometric probability

Problem

1) A point x is chosen at random on the segment [0, 10]. Find P(x < 3).
2) A bus comes every 15 minutes, and you arrive at the stop at a random moment. Find the probability of waiting less than 5 minutes.
3) A circle of radius 10 cm is drawn inside a square board with side 20 cm. Assuming a dart hits a random point of the board, find the probability that it lands in the circle.

Show solutionHide solution

Solution

1) Favourable length 3, whole length 10: P = 3/10 = 0.3.
2) Your arrival time is spread evenly over the 15-minute gap; you wait less than 5 minutes if you arrive in its last 5 minutes: P = 5/15 = 1/3.
3) Area of the circle π · 10² = 100π cm², area of the square 20² = 400 cm²: P = 100π/400 = π/4 ≈ 0.785.
Going deeper

The meeting problem

Problem

Aysel and Leyla agree to meet in a park between 12:00 and 13:00. Each arrives at a random moment within this hour, waits 15 minutes and leaves. What is the probability that they meet?

Show solutionHide solution

Solution

Let x and y be their arrival times in minutes after 12:00. All points (x, y) of the 60 × 60 square are equally likely. They meet when |x − y| ≤ 15 — a band along the diagonal.
Outside the band there are two corner triangles with legs 45, together 45² = 2025 square units; the whole square is 60² = 3600.
P = 1 − 2025/3600 = 1 − 9/16 = 7/16 ≈ 0.44.

Remember

  • A probability is a number from 0 (impossible event) to 1 (certain event).
  • P(A) = m/n works only for equally likely outcomes; with two dice count the 36 ordered pairs.
  • As trials pile up, the relative frequency W = k/N approaches the probability; a coin has no memory.
  • P(Ā) = 1 − P(A); “or” → add (mutually exclusive), “and” → multiply (independent), “at least one” → 1 − P(none).
  • In a tree, multiply along a path and add the paths; in random selections count n and m with combinations.
  • Geometric probability is a ratio of lengths, areas or times: P = s/S.
Spotted a mistake or something inaccurate in this lesson?

Check yourself

12 questions. Every correct answer earns XP.

Question 1 / 12

Question 1 / 12. Which number cannot be the probability of any event?