4 is an element of A.
⭕ Sets and Venn Diagrams
Learn how collections are represented, compared and combined, and use Venn diagrams to visualize relationships clearly.
🎯 What You Will Learn
📦 1. What Is a Set?
A set is a well-defined collection of distinct objects. The objects are called elements or members.
5 is not an element of A.
A contains four distinct elements.
✍️ 2. Ways to Represent a Set
List every element
E = {2, 4, 6, 8, 10}
Describe a common rule
E = {x | x is an even natural number and x ≤ 10}
Describe in words
E is the set of even natural numbers not exceeding 10.
🗂️ 3. Common Types of Sets
Contains no elements.
Contains exactly one element.
Has a countable fixed number of elements.
Continues without an end.
Contain exactly the same elements.
Have no common elements.
Contains every element under discussion.
🧩 4. Subsets and Power Sets
A is a subset of B, written A ⊆ B, when every element of A is also an element of B.
The power set P(A) is the set of all subsets of A. If A has n elements, then P(A) has 2n elements.
🔄 5. Set Operations
In A or B or both
Combine all distinct elements.
Common to both
Keep only shared elements.
In A but not B
Remove B’s elements from A.
In exactly one set
Keep elements that are not shared.
In U but not A
Use the stated universal set.
Operation Example
A = {1, 2, 3, 4} and B = {3, 4, 5, 6}.
A ∪ B = {1, 2, 3, 4, 5, 6}
A ∩ B = {3, 4}
A − B = {1, 2}
A △ B = {1, 2, 5, 6}
⚖️ 6. Important Set Laws
⭕ 7. Reading a Venn Diagram
A Venn diagram places sets inside a rectangle representing U. Overlapping circles show common elements; non-overlapping regions show elements unique to each set.
Inside A and outside B.
Inside both A and B.
Inside B and outside A.
Inside U but outside both circles.
🧪 Set Operation Explorer
Enter comma-separated elements, choose an operation and observe the highlighted Venn region together with the calculated result.
🧮 8. Counting with Two Sets
The intersection is subtracted once because it was counted in both n(A) and n(B).
CodeBhavya Example
In a class, 28 students know C, 20 know Python and 9 know both. How many know at least one language?
n(C ∪ P) = 28 + 20 − 9 = 39.
39 students know at least one language.
💻 9. Sets in Programming
Unique values
Convert repeated input into a collection of distinct elements.
Fast lookup
Check whether an identifier, permission or item is present.
Intersection
Find users, skills or records shared by two groups.
Union
Combine two groups without repeating elements.
📘 10. Solved Problems
Problem 1
A = {2, 4, 6, 8}, B = {4, 8, 12}. Find A ∩ B.
The elements appearing in both sets are 4 and 8.
A ∩ B = {4, 8}
Problem 2
U = {1, 2, 3, 4, 5, 6}, A = {2, 4, 6}. Find A′.
Keep the elements of U that do not belong to A.
A′ = {1, 3, 5}
Problem 3
If n(A) = 24, n(B) = 19 and n(A ∩ B) = 7, find n(A ∪ B).
n(A ∪ B) = 24 + 19 − 7 = 36.
n(A ∪ B) = 36
✍️ 11. Practice Problems
Solve each question first, then open the solution to verify your set operation.
1. Write the set of vowels in English using roster form.
2. If A = {1, 2, 3} and B = {3, 4, 5}, find A ∪ B.
3. Find the number of subsets of {p, q, r}.
4. U = {1, 2, 3, 4, 5}, A = {1, 3, 5}. Find A′.
5. In a group, 32 like tea, 25 like coffee and 12 like both. How many like at least one?
📝 Quick Revision
- A set is a well-defined collection of distinct elements.
- Roster form lists elements; set-builder form describes a rule.
- A ⊆ B means every element of A belongs to B.
- An n-element set has 2n subsets.
- Union combines, while intersection keeps common elements.
- A − B keeps elements in A but not B.
- A′ contains elements of U that are outside A.
- Use n(A ∪ B) = n(A) + n(B) − n(A ∩ B).
- Venn diagrams make regions and overlaps visible.
⭕ Sets and Venn Diagrams Practice
Answer all 20 questions, submit once, and then review your score, correct answers and complete explanations.