# Probability, Sets, Venn Diagrams and Two-Way Tables

> Sample spaces, complements, Venn diagrams and two-way tables, set notation, the addition rule and conditional probability.

From HSC Maths Advanced on WhizzNotes, free study notes for NSW students: https://whizznotes.com/mathematics-advanced/probability-and-sets/. Updated 3 November 2026.
Year 11 and Year 12 boxes go deeper than the Year 10 text around them.

### Story time: The school survey
Mr Nguyen surveys his Year 10 class of 30 students. 18 play a sport, 12 play a musical instrument, and 5 do both. He picks one student's name out of a hat for a prize. What is the chance the winner plays sport but not music?

Questions like this get confusing fast, because some students are counted twice. A **Venn diagram** sorts everyone into exactly one region, so nobody is counted twice. Then each probability is just a fraction.

**In short:** Probability is how likely an event is: favourable outcomes divided by total outcomes, from 0 (impossible) to 1 (certain). Venn diagrams and two-way tables organise events, and $P(A \cup B) = P(A) + P(B) - P(A \cap B)$.

## Starting point: Years 9 and 10

### Basic probability

For equally likely outcomes:

$$P(\text{event}) = \frac{\text{number of favourable outcomes}}{\text{total number of outcomes}}$$

Probabilities go from 0 (impossible) to 1 (certain). The list of all possible outcomes is the **sample space**.

The **complement** of an event is "it does not happen":

$$P(\text{not } A) = 1 - P(A)$$

### Venn diagrams

*Diagram: Venn diagram: sport only 13, both 5, music only 7, neither 5, total 30*
*Fill the middle first: 5 do both. Then 18 − 5 = 13 sport only, 12 − 5 = 7 music only, and 30 − 25 = 5 neither.*

So $P(\text{sport but not music}) = \dfrac{13}{30}$ and $P(\text{neither}) = \dfrac{5}{30} = \dfrac{1}{6}$.

### Key idea: "And" and "or"
- **A and B:** the overlap. Only students in both.
- **A or B:** anything inside either circle, including the overlap. Here $13 + 5 + 7 = 25$.

### Two-way tables

The same data can go in a table with totals.

| | Music | No music | Total |
|---|---|---|---|
| Sport | 5 | 13 | 18 |
| No sport | 7 | 5 | 12 |
| Total | 12 | 18 | 30 |

Every row and column must add up to its total, which is a good way to check your work.

### Exam tip: Fill the overlap first
In Venn diagram questions, always fill in the "both" region first, then subtract to fill the rest.

### Watch out: Do not double count
$P(\text{sport or music})$ is not $\dfrac{18 + 12}{30}$. That counts the 5 students who do both twice.

**Mind map**

```text
Probability and sets
  Basics
    Favourable over total
    0 to 1
    Complement: 1 - P(A)
  Venn diagrams
    Overlap is "and"
    Inside either is "or"
  Two-way tables
    Rows and columns add up
  Set notation
    ∪ union, ∩ intersection
    A' complement
  Rules
    Addition rule
    Mutually exclusive
    Conditional P(A | B)
    Independent events
```

### Year 11: Set notation and the addition rule
- $\xi$ or $S$: the **universal set** (everything).
- $A \cup B$: **union**, "A or B".
- $A \cap B$: **intersection**, "A and B".
- $\overline{A}$ or $A'$: the **complement**, "not A".
- $\varnothing$: the empty set.

**Addition rule.**

$$P(A \cup B) = P(A) + P(B) - P(A \cap B)$$

Subtract the overlap so it is only counted once. Survey: $\dfrac{18}{30} + \dfrac{12}{30} - \dfrac{5}{30} = \dfrac{25}{30}$.

**Mutually exclusive** events cannot happen together, so $P(A \cap B) = 0$ and $P(A \cup B) = P(A) + P(B)$. Rolling a 2 and rolling a 5 on one die are mutually exclusive.

### Year 11: Conditional probability and independence
$P(A \mid B)$ means "the probability of $A$, **given** that $B$ has happened." You restrict attention to $B$ only.

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

**Example.** Given a student plays music, what is the chance they play sport? Only look at the 12 music students. 5 of them play sport, so $P(\text{sport} \mid \text{music}) = \dfrac{5}{12}$.

Events are **independent** if one does not change the chance of the other:

$$P(A \cap B) = P(A) \times P(B)$$

In the survey, $P(\text{sport}) \times P(\text{music}) = 0.6 \times 0.4 = 0.24$, but $P(\text{both}) = \dfrac{5}{30} \approx 0.17$. They are not independent.

**Testing independence from a union.** If $P(A) = 0.5$, $P(B) = 0.4$ and $P(A \cup B) = 0.7$, the addition rule gives $P(A \cap B) = 0.5 + 0.4 - 0.7 = 0.2$. Since $0.5 \times 0.4 = 0.2$ too, $A$ and $B$ are independent.

**Flipping a condition.** To get $P(A \mid B)$ from $P(B \mid A)$, go through the overlap: $P(A \cap B) = P(B \mid A)P(A)$, then divide by $P(B)$. With $P(B \mid A) = 0.5$, $P(A) = 0.3$ and $P(B) = 0.25$: $P(A \cap B) = 0.15$, so $P(A \mid B) = 0.6$.

**Complements of independent events** are independent too: $P(A' \cap B) = P(A')P(B)$. And from a Venn diagram, $P(A' \cap B) = P(A \cup B) - P(A)$, the part of the union outside $A$.

**Finding an unknown.** A bag has $n$ discs, 5 of them red. If two are drawn without replacement and $P(\text{both red}) = \frac{2}{9}$, then $\dfrac{5}{n} \times \dfrac{4}{n - 1} = \dfrac{2}{9}$, so $n^2 - n - 90 = 0$ and $n = 10$.

**How many tries?** If each test finds a carrier with probability 0.2, the chance of at least one in $n$ tests is $1 - 0.8^n$. For more than 90%: $0.8^n < 0.1$, so $n > \dfrac{\ln 0.1}{\ln 0.8} \approx 10.3$, which means 11 tests.

### Year 12: Medical test surprise
A disease affects 1% of people. A test catches 95% of people who have it, but also wrongly says "positive" for 5% of healthy people. Out of 10 000 people: 100 are sick and 95 test positive, while 9900 are healthy and 495 test positive.

$$P(\text{sick} \mid \text{positive}) = \frac{95}{95 + 495} \approx 0.16$$

Only 16% of positive results are real. A two-way table makes this clear, and the idea leads into the study of random variables.

## Quick summary

- $P(\text{event}) = \dfrac{\text{favourable}}{\text{total}}$ and $P(\text{not } A) = 1 - P(A)$.
- In a Venn diagram, fill the overlap first. "And" is the overlap. "Or" is anything in either circle.
- Two-way tables show the same counts with row and column totals.
- $P(A \cup B) = P(A) + P(B) - P(A \cap B)$.
- $P(A \mid B) = \dfrac{P(A \cap B)}{P(B)}$. Independent if $P(A \cap B) = P(A)P(B)$.

## Quiz

Try these questions from the chapter quiz.

1. A fair die is rolled. What is the probability of rolling a number greater than 4?
   - A. $\dfrac{1}{6}$
   - B. $\dfrac{1}{3}$
   - C. $\dfrac{1}{2}$
   - D. $\dfrac{2}{3}$
   - Answer: B. $\dfrac{1}{3}$. 5 and 6: two out of six.

2. The probability of rain tomorrow is 0.35. The probability of no rain is:
   - A. 0.35
   - B. 0.65
   - C. 0.5
   - D. 1.35
   - Answer: B. 0.65. $1 - 0.35$.

3. In a class of 25, 15 like pizza, 12 like pasta, and 6 like both. How many like pizza only?
   - A. 15
   - B. 9
   - C. 6
   - D. 3
   - Answer: B. 9. $15 - 6 = 9$.

The whole chapter quiz is on the page, for signed-in students: https://whizznotes.com/mathematics-advanced/probability-and-sets/#quiz
