1..30, A = multiples of 2
|A| = 15
B multiples of 3: 10.
Sets obey algebraic laws such as and .
This page is easier if you are comfortable with:
Test with , , in the universe . Then , and has 2 elements. On the other side, and , whose union is : 2 elements, the same set. For the complement law: , so with 2 elements, and .
These identities are the set-theoretic twins of the laws of logic: union corresponds to "or", intersection to "and", complement to "not", so the second identity is De Morgan's law. The size of a union follows inclusion–exclusion: here , and for three sets see inclusion–exclusion for three events.
Venn diagrams illustrate the identities (overlapping sets) and probability uses the same algebra for events (the probability of the complement, the union of two events). The identities are proved by showing that each side is a subset of the other, using implication.
Set identities let us rewrite expressions with unions, intersections and complements.
Each pair of equal expressions gives the same set.
These examples are worked by hand, step by step, so you can compare your own working.
Find for the sets above.
Find in .
Find .
A few situations come up again and again. Knowing them saves time and helps you spot answers that cannot be right.
|A| = 15
B multiples of 3: 10.
multiples of 6
5.
15 + 10 − 5
20.
30 − 20
10.
Key identities: A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C); (A ∪ B)ᶜ = Aᶜ ∩ Bᶜ; A \ B = A ∩ Bᶜ; |A ∪ B| = |A| + |B| − |A ∩ B|.
In 1..30 count multiples of 2.
Count multiples of 6.
Count multiples of 2 or 3.
Count numbers divisible by neither.
A ∩ (B ∪ C) = (A ∩ B) ∪ C ✗
intersect both ✓
Distribute fully.
15 + 10 ✗
subtract overlap ✓
Union.
Aᶜ ∪ Bᶜ ✗
Aᶜ ∩ Bᶜ ✓
De Morgan.
B \ A ✗
A \ B = A ∩ Bᶜ ✓
Order matters.
Try each one on paper, then open the answer. Use the solver above to see the full working.
8
8
10
10
28
4
Unlimited fresh questions with instant marking. Choose a level, work it out on paper, then type your answer.
Solve: …
A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C) and A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C).
A ∩ Bᶜ.
Show both inclusions or use a Venn diagram.
Add and subtract the overlap.
De Morgan’s laws.
More in Discrete maths and number theory and the formula sheets.