Quick answer: For two sets, . For three sets, . This is the inclusion-exclusion principle: add the single sets, subtract the overlaps counted twice, then add back the triple overlap. A Venn diagram filled from the centre outward makes these problems quick and reliable.
This uses the operations in set operations and laws of sets.
Two-set formulas
| Quantity | Formula |
|---|---|
| Only A, | |
| Exactly one of A, B | |
| Neither, |
If A and B are disjoint, .
Three-set formula
Let , = sum of the three pairwise intersections, and .
| Quantity | Formula |
|---|---|
| At least one | |
| Exactly one | |
| Exactly two | |
| Exactly three | |
| At least two |
How to fill a three-set Venn diagram
Step 1: Write in the centre.
Step 2: For each pair, write (pair intersection − centre) in the region of exactly those two sets.
Step 3: For each set, write (set total − its three inner regions) in the "only" region.
Step 4: Add all seven regions for the union, and subtract from for "none".
Worked examples
Example 1: two languages
In a class of 50, 30 study French, 25 study German and 10 study both. How many study neither?
Step 1: .
Step 2: Neither .
Example 2: three newspapers
In a survey of 100 people: 50 read A, 40 read B, 30 read C, 20 read A and B, 15 read B and C, 10 read A and C, and 5 read all three.
At least one:
None: .
Exactly one: .
Exactly two: .
Check: exactly one + exactly two + exactly three ✓.
Example 3: region-by-region
Using Example 2, the "only A" region is .
Example 4: the largest and smallest possible overlap
If , and , what are the possible values of ?
- Maximum: , when B ⊆ A.
- Minimum: , when .
So .
Summary table
| Problem asks for | Use |
|---|---|
| Union of two sets | |
| Union of three sets | |
| Exactly one of three | |
| Exactly two of three | |
| Bounds on overlap |
Exam tips
- Always fill a Venn diagram from the centre outward.
- Read wording carefully: "both A and B" may include those who also do C.
- Check that the seven regions plus "none" add up to the total.
- The same principle is used for counting with divisibility, for example numbers divisible by 2, 3 or 5.
The same counting idea appears in probability; see NIMCET probability and statistics and the NIMCET Set Theory chapter.
Common mistakes
- Subtracting the triple intersection instead of adding it back.
- Treating a pairwise intersection as "exactly two"; it includes the centre.
- Forgetting the "none" region outside all circles.
- Using for a union without checking whether the sets overlap.
Frequently Asked Questions
What is the inclusion-exclusion principle?
It is the counting rule n(A ∪ B) = n(A) + n(B) − n(A ∩ B), and its extension to more sets, which corrects for elements counted more than once.
What is the formula for n(A ∪ B ∪ C)?
n(A) + n(B) + n(C) − n(A ∩ B) − n(B ∩ C) − n(C ∩ A) + n(A ∩ B ∩ C).
How do you find the number in exactly one of three sets?
Use S₁ − 2S₂ + 3S₃, where S₁ is the sum of the set sizes, S₂ the sum of pairwise intersections and S₃ the triple intersection.
How do you find the number of elements in neither set?
Subtract the union from the total: n(U) − n(A ∪ B).
What is the minimum possible value of n(A ∩ B)?
It is n(A) + n(B) − n(U), or 0 if that value is negative.