Lesson 3 of 42 · Numbers and sets
Sets, Venn diagrams and counting overlaps
Use set notation for union, intersection, complement and Cartesian product, and count overlapping groups in two and three sets without double counting.
About 22 minutes
In this lesson
- Read and apply inclusion, union, intersection, difference, complement and Cartesian product.
- Count the elements of a union of two or three sets with inclusion and exclusion.
- Fill a Venn diagram from the inside out to answer "only", "exactly" and "neither" questions.
The idea
The notation
A set is a collection of distinct objects, its elements. means belongs to ; (or ) is the number of elements of a finite set. The universe is the set of everything under discussion.
| Symbol | Meaning | With , , |
|---|---|---|
| every element of is in | false: but | |
| in or (or both) | ||
| in both and | ||
| in but not in | ||
| (also ) | in but not in | |
| all ordered pairs with , | 12 pairs, from to |
The empty set has no elements and is a subset of every set. Every set is a subset of itself. A set with elements has subsets, because each element is either in or out of a subset, independently; the count includes and the set itself.
The Cartesian product has elements, and order matters: , while belongs to .
The complement depends on the universe. "Not English" among 120 students is a different set from "not English" among all the students in a school. Name before taking any complement.
Two useful laws
De Morgan's laws say that the complement of a union is the intersection of the complements, and the other way round:
In words: "not (A or B)" is "neither A nor B"; "not (A and B)" is "not A, or not B". These let you count a "neither" group as .
Also, , and splits into two disjoint pieces: . That split is the idea behind every Venn diagram count.
Intervals are sets too
Sets of real numbers are often intervals, and the same operations apply. With and : , , . Draw both on one number line and read off the result, paying attention to which endpoints are included.
Counting a union: inclusion and exclusion
Adding and counts the elements of twice, so subtract them once:
For three sets, the pairwise overlaps are subtracted, but that removes the triple overlap once too often, so it is added back:
Filling a Venn diagram from the inside out
When a question asks for "only A", "exactly two" or "neither", draw the diagram and fill it from the innermost region outwards. With two sets there are four regions: only , only , both, and neither. With three sets there are eight: the centre (all three), three "exactly two" regions, three "only one" regions, and the outside.
- Write the triple overlap in the centre.
- For each pair, subtract the centre from the pair's total to get "these two only".
- For each set, subtract its three inner regions from its total to get "this one only".
- Subtract everything inside the circles from to get "neither".
Then add all eight regions; they must give . That final sum is a built-in check.
Reading the wording
"Studies French" includes those who also study German; "studies only French" does not. "At least one" is the union; "exactly one" excludes every overlap; "at most one" includes "neither". Most wrong answers in set questions come from reading one of these as another.
Worked examples
Example 1: Two overlapping groups
Of 120 students, 70 study English, 50 study Spanish and 25 study both. How many study neither language, and how many study only English?
At least one language: .
Neither: .
Only English: . Only Spanish: .
Check the four regions add up: .
Answer
25 study neither and 45 study only English. Forgetting the overlap gives for "neither", which is the classic double count.
Example 2: Three overlapping groups
A shop surveyed 100 customers. 45 bought product , 40 bought and 30 bought ; 15 bought and , 10 bought and , 8 bought and , and 5 bought all three. How many bought none, and how many bought exactly one product?
Union by inclusion and exclusion: . So bought none.
Fill from the centre: all three is 5. Exactly and : ; exactly and : ; exactly and : .
Only : . Only : . Only : . Exactly one: .
Check: .
Answer
13 bought none and 64 bought exactly one. Subtracting the pairwise totals without adding the centre back gives "only " as , which removes the 5 triple buyers twice.
Example 3: Operations on a small universe
Let , the even numbers in and the multiples of 3 in . Find , , and .
List the sets: and . So .
, so its complement in is .
Check with De Morgan: and ; their intersection is , the same.
, and .
Answer
, , , . Answering 8 for the product, , confuses pairs with a list of elements.
Common traps
Double counting the overlap
counts the members of both sets twice. Whenever groups can overlap, subtract the intersection, or fill a diagram region by region.
Forgetting to add back the triple overlap
With three sets, each pairwise total already contains the people in all three. Subtracting all three pairwise totals removes them three times after they were added three times, so add the triple overlap back once. In a diagram, always start from the centre.
Reading "A" as "only A"
"40 bought " includes everyone who also bought something else. If a question asks how many bought only , you must subtract the overlaps; if it asks how many bought , you must not.
Adding instead of multiplying for a Cartesian product
is a set of pairs, so it has elements, not . Its subsets number .
Check yourself
Answer each question before you open its answer.
Question 1: Players of both sports
Sets
In a class of 40 students, 22 play football, 17 play tennis and 6 play neither sport. How many play both?
- A.
- B.
- C.
- D.
Show the answer
Answer: B.
Working
Students who play at least one sport: . By inclusion and exclusion, , so both . Check: only football 17, only tennis 12, both 5, neither 6, total 40.
Why the other options are wrong
- A. This computes , which ignores the 6 students who play neither sport. The overlap is the sum of the two groups minus the union: .
- C. This confuses the students who play neither sport with those who play both.
- D. This assumes every tennis player also plays football. That is the largest the overlap could be, not what the numbers give.
What carries over
Find the union first from the total and the "neither" group, then the overlap is the sum of the sets minus the union.
Question 2: Exactly one of three
Sets
Of 60 people, 25 read paper , 20 read and 18 read . 7 read and , 6 read and , 5 read and , and 2 read all three. How many read exactly one paper?
- A.
- B.
- C.
- D.
Show the answer
Answer: C.
Working
Centre: 2. Exactly two: , , . Only : ; only : ; only : . Exactly one: . Check: the union is , and .
Why the other options are wrong
- A. This is the number who read no paper, .
- B. This finds each "only" region by subtracting the two pairwise totals without adding back the 2 who read all three, so they are removed twice from each paper.
- D. This is the number who read at least one paper, which also counts those who read two or three.
What carries over
For "exactly" questions with three sets, fill the diagram from the centre outwards and check that the regions add up to the union.
Question 3: Subsets of a Cartesian product
Sets
Let and . How many subsets does have?
- A.
- B.
- C.
- D.
Show the answer
Answer: D.
Working
has ordered pairs. A set with 6 elements has subsets, counting the empty set and the whole set.
Why the other options are wrong
- A. This adds and then stops: it is neither the size of the product nor a count of subsets.
- B. This is the number of elements of , not the number of its subsets.
- C. This is , built on the wrong size for the product.
What carries over
, and a set of elements has subsets.
Key points
; for three sets, subtract the pairs and add back the triple.
Fill Venn diagrams from the centre outwards, and check that the regions add up to the whole.
The complement depends on the universe; "neither" is .
, and a set of elements has subsets.
All questions here are original and written for UniExamer; none comes from the test maker.
Written by the UniExamer team with AI assistance. Every worked example and check question was re-solved by an independent checker before publication. No subject expert has reviewed this lesson yet. If you find a mistake, write to support@uniexamer.com.