Set Theory: Subsets and Set Operations

Matt Gruber
4 min readOct 31, 2020

--

A few months ago I wrote an introduction to the basics of Set Theory. My goal in writing that article was to create interest in a topic that is usually reserved for high-level mathematics courses in universities. The framework can be useful for many people beyond higher education and I hope it generated some interest in the topic.

In this article, I will continue to break down the concepts using basic examples that focus on the intuition behind Set Theory. At the highest level, this article will be about Subsets and two operations you can perform on sets, namely, the union of two sets and the intersection of two sets.

Subsets

What is a Subset?

We call a set a subset of a parent set if every element in the set is a member of the parent set.

Lets, pretend we have a set of people with colored hats.

Set of 3 people in blue hats and 2 people in red hats.

For simplicities sake, each of these individuals is labeled with a number 1 through 5. Let's call this set “People in Hats” (1,2,3,4,5).

Let's call the following set of people in blue hats: “People in Blue Hats” (2,3,4)

The subset of People in Hats with individuals wearing a blue hat

and let’s call the following set of people in red hats: “People in Red Hats” (1,5)

The subset of People in Hats with individuals wearing a red hat

The “People in Blue Hats” (2,3,4) and “People in Red Hats” (1,5) are subsets of the set “People in Hats” (1,2,3,4,5) because every member of the subsets are members of the parent set.

Any random grouping of these individuals would be a subset of “People in Hats” (1,2,3,4,5).

What wouldn’t be a Subset?

For a set to not be a subset of another set it must contain members that aren’t in the parent set.

For example, the following set of people in red hats, which we’ll call “Red Hat Wearers” (1,5,6) for differentiation sake, would not be a subset of “People in Hats” (1,2,3,4,5).

A set of people in red hats.

This would not be a subset of “People in Hats” (1,2,3,4,5) because the individual labeled 6 is not contained in “People in Hats” (1,2,3,4,5).

Set Operations

What is the Union of two sets?

The union of two sets is the combination of every unique individual in both sets. For example, if we took the union of “People in Blue Hats” (2,3,4) and “People in Red Hats” (1,5) we would get the set “People in Hats” (1,2,3,4,5).

What is the Intersection of two sets?

The intersection of two sets is the overlapping members of both sets. For example, if we took the intersection of “Red Hat Wearers” (1,5,6) and “People in Hats” (1,2,3,4,5) then we would get “People in Red Hats” (1,5).

Simple Visualization

With a Venn diagram, it is simple to visualize the differences between a Union and an Intersection.

A Venn Diagram with a red circle on the left half, a blue circle on the right half, and a black fill-in where the circles overlap.

Let’s pretend the red circle on the left contains every individual in the set “People in Red Hats” (1,5) and the blue circle on the right contains every individual in the set “People in Blue Hats” (2,3,4).

The union of the red circle and the blue circle is the entire Venn Diagram, or “People in Hats” (1,2,3,4,5).

The intersection of the red circle and the blue circle is the black area, or the empty set in this case since there is nobody in the set “People in Hats” (1,2,3,4,5) wearing both a red hat and a blue hat.

In summary:

  • A set is a subset of another set if every member of the set is contained in the parent set.
  • The union of two sets is the combination of every unique individual in a set.
  • The intersection of two sets is the overlapping members of both sets.

In my next article, I will describe the Cartesian Product of sets to bring us one step closer to the answer that you’re looking for from the initial article. How does the statement 𝒫(ℝ²) contain every black and white image in existence?

I decided to remove the mathematical notation from this article because I thought it may make the intuition easier to understand! Let me know if you think I should add that here to tie the two together or if you found it better without!

Do you have any questions? Is there anything here that you feel I misrepresented or left out? Feel free to comment or send me a message!

Learn about the Cartesian Product in my next article… coming soon.

--

--