- Foundation
- About 17 min
- 5 practice questions
Complement of a set and De Morgan's laws
Find the complement of a set in a given universal set, use the complement laws, verify De Morgan's laws, and prove simple set results element by element.
If something looks wrong, please tell us.
By the end of this lesson you can
- Find A′, the complement of A with respect to U, and see that A′ = U − A.
- Use the complement laws: A ∪ A′ = U, A ∩ A′ = φ, (A′)′ = A, φ′ = U and U′ = φ.
- State and verify De Morgan's laws (A ∪ B)′ = A′ ∩ B′ and (A ∩ B)′ = A′ ∪ B′.
- Prove a simple set identity by following an element.
Often it is easier to describe what a set leaves out than what it contains. The complement does exactly that, and De Morgan's laws tell us how complements behave with union and intersection. These two laws reappear in probability, where not (A or B) is the same event as not A and not B.
The complement
Let U be the universal set and A a subset of U. The complement of A, written A′, is the set of all elements of U that are not in A: A′ = {x : x ∈ U and x ∉ A}. So the complement is a difference: A′ = U − A. In a Venn diagram, A′ is everything inside the rectangle but outside the circle A. The complement always depends on U: change U and the complement changes.
Worked example 1: complements in a finite U
Let U = {1, 2, 3, ..., 10} and A = {2, 3, 5, 7}, the primes in U. Working: remove 2, 3, 5 and 7 from U. Then A′ = {1, 4, 6, 8, 9, 10}. Now take the complement again: the elements of U not in A′ are 2, 3, 5 and 7, so (A′)′ = A.
Worked example 2: complements in N
Take U = N. (i) If A is the set of even natural numbers, A′ is the set of odd natural numbers. (ii) If B = {x : x ∈ N and x ≥ 5}, then B′ = {1, 2, 3, 4}. (iii) If C = {x : x ∈ N and 2x + 3 = 11}, then C = {4}, so C′ = N − {4} = {1, 2, 3, 5, 6, 7, ...}.
Laws of complements
| Law | Statement |
|---|---|
| Complement laws | A ∪ A′ = U and A ∩ A′ = φ |
| Double complement | (A′)′ = A |
| Empty set and universal set | φ′ = U and U′ = φ |
| De Morgan's laws | (A ∪ B)′ = A′ ∩ B′ and (A ∩ B)′ = A′ ∪ B′ |
De Morgan's laws
In words: the complement of a union is the intersection of the complements, and the complement of an intersection is the union of the complements. The laws are named after the mathematician Augustus De Morgan. Taking a complement swaps ∪ and ∩, rather like the way a minus sign outside a bracket changes every sign inside.
(A ∪ B)′ = A′ ∩ B′ and (A ∩ B)′ = A′ ∪ B′: complement each set and swap ∪ with ∩.
Verifying (A ∪ B)′ = A′ ∩ B′ on an example
- Write U, A, B in roster form Make sure A and B are subsets of U.
- Left side Find A ∪ B, then its complement.
- Right side Find A′ and B′, then their intersection.
- Compare The two sets should match element for element.
Worked example 3: verifying both laws
Let U = {1, 2, 3, 4, 5, 6, 7, 8}, A = {1, 2, 3, 4} and B = {3, 4, 5, 6}. First law: A ∪ B = {1, 2, 3, 4, 5, 6}, so (A ∪ B)′ = {7, 8}. Also A′ = {5, 6, 7, 8} and B′ = {1, 2, 7, 8}, so A′ ∩ B′ = {7, 8}. The two sides agree. Second law: A ∩ B = {3, 4}, so (A ∩ B)′ = {1, 2, 5, 6, 7, 8}. And A′ ∪ B′ = {1, 2, 5, 6, 7, 8}. Again the two sides agree: (A ∪ B)′ = A′ ∩ B′ = {7, 8} and (A ∩ B)′ = A′ ∪ B′ = {1, 2, 5, 6, 7, 8}.
Proving results by following an element
To prove that two sets are equal in general, we show each is a subset of the other: take any element of one and show it belongs to the other. To prove one set is a subset of another, take any element of the first and show it lies in the second.
Worked example 4: A − B = A ∩ B′
Proof. Let x ∈ A − B. Then x ∈ A and x ∉ B. Since x ∉ B and x ∈ U, x ∈ B′. So x ∈ A and x ∈ B′, that is x ∈ A ∩ B′. Hence A − B ⊂ A ∩ B′. Conversely, let x ∈ A ∩ B′. Then x ∈ A and x ∈ B′, so x ∉ B. Hence x ∈ A − B, and A ∩ B′ ⊂ A − B. Since each set is a subset of the other, A − B = A ∩ B′.
Worked example 5: if A ⊂ B then B′ ⊂ A′
Proof. Let x ∈ B′. Then x ∈ U and x ∉ B. If x were in A, then, since A ⊂ B, x would be in B, which is false. So x ∉ A, which means x ∈ A′. Every element of B′ lies in A′, so B′ ⊂ A′. Example: in U = {1, 2, 3, 4, 5}, A = {1} ⊂ B = {1, 2}, and B′ = {3, 4, 5} ⊂ A′ = {2, 3, 4, 5}.
Key takeaways: A′ = U − A depends on U. A ∪ A′ = U, A ∩ A′ = φ, (A′)′ = A, φ′ = U, U′ = φ. De Morgan: the complement of a union is the intersection of the complements, and vice versa. To prove two sets equal, show each is a subset of the other by following a single element.
Check your understanding
-
1. Let U = {1, 2, 3, ..., 10} and A = {2, 3, 5, 7}. What is A′?
- {1, 4, 6, 8, 9, 10}
- {4, 6, 8, 9, 10}
- {1, 4, 6, 8, 10}
- {2, 3, 5, 7}
Show answer
Answer: A. A′ contains the elements of U that are not in A. Removing 2, 3, 5 and 7 from 1 to 10 leaves 1, 4, 6, 8, 9 and 10. Do not forget 1, which is not prime.
-
2. Which set is always equal to (A ∪ B)′?
- A′ ∪ B′
- A ∩ B
- A′ ∩ B′
- (A ∩ B)′
Show answer
Answer: C. By De Morgan's law, the complement of a union is the intersection of the complements: (A ∪ B)′ = A′ ∩ B′. The set A′ ∪ B′ is (A ∩ B)′, which is the other law.
-
3. With U = N, what is the complement of A = {x : x ∈ N and x > 4}?
- {0, 1, 2, 3, 4}
- {1, 2, 3}
- {5, 6, 7, ...}
- {1, 2, 3, 4}
Show answer
Answer: D. A = {5, 6, 7, ...}. The natural numbers not in A are 1, 2, 3 and 4. 0 is not a natural number, so it cannot be in a complement taken inside N.
-
4. For any subset A of U, what is A ∩ A′?
- U
- φ
- A
- A′
Show answer
Answer: B. No element can be both in A and outside A, so A ∩ A′ = φ. (It is A ∪ A′ that equals U.)
-
5. Let U = {1, 2, 3, 4, 5, 6}, A = {1, 2, 3} and B = {2, 4}. What is (A ∩ B)′?
- {2}
- {1, 3, 4, 5, 6}
- {5, 6}
- {4, 5, 6}
Show answer
Answer: B. A ∩ B = {2}, so (A ∩ B)′ = U − {2} = {1, 3, 4, 5, 6}. Check with De Morgan: A′ = {4, 5, 6}, B′ = {1, 3, 5, 6}, and A′ ∪ B′ = {1, 3, 4, 5, 6}.
Sign in to keep track of the lessons you finish.