1.1.1: Set Theory

Learning Objectives

  • Define sets, subsets, universal set, empty set, and infinite sets
  • Determine subsets of a set
  • Determine subsets, and complement of a set
  • Apply the set operations union, intersection, and complements of sets
  • Use Venn diagrams to illustrate set operations

KEY words

  • Subset: A set containing elements of another set
  • Empty set: a set containing no elements
  • Universal set: a set containing all elements we are interested in
  • Infinite set: a set that contains an infinite number of elements
  • Complement: the complement of a set is all elements in the universal set that are not in the original set
  • Variable: a letter that is used as a stand-in to represent any element

In mathematics, it is helpful to consider where numbers come from and how they interact with each other. To look at collections of different numbers, we will first define sets.

Sets

An art collector owns a collection of paintings, while a music lover might keep a collection of CDs. Any collection of items can form a set.

Set

A set is a collection of distinct objects, called elements of the set.

A set can be defined by describing the contents, or by listing the elements of the set, enclosed in braces and separated by commas.

It is common to name a set, to make it easier to refer to that set later. Capital letters are often used for this purpose. Sets can have a finite number of elements or an infinite number of elements and are referred to as finite or infinite sets. A set simply specifies the contents; order is not important. The set represented by {1, 2, 3} is equivalent to the set {3, 1, 2}.

Example

Some examples of sets defined by describing the contents:

  1. [latex]\text{C}\;=\;\text{the set of all books written about travel to Chile}[/latex]. This is a finite set.
  2. [latex]\mathbb{Z}=\text{the set of all integers}[/latex]. This is an infinite set.

Some examples of sets defined by listing the elements of the set:

  1. [latex]A\;= \;\{1, 3, 9, 12\}[/latex].This is a finite set.
  2. [latex]\text{R}\;=\;\{\text{red, orange, yellow, green, blue, indigo, purple}\}[/latex]. This is a finite set.

Notation

The symbol [latex]\in[/latex] means “is an element of”.

A set that contains no elements, [latex]\{\;\}[/latex], is called the empty set and is notated [latex]\varnothing[/latex].

Example

Let [latex]A\;= \;\{1, 2, 3, 4\}[/latex]

To say that 2 is an element of the set, we write [latex]2\;\in\;A[/latex].

Sometimes a collection might not contain all the elements of a set. For example, Chris owns three Madonna albums. While Chris’s collection is a set, we can also say it is a subset of the larger set of all Madonna albums.

Subset

A subset of a set [latex]A[/latex] is another set that contains only elements from the set [latex]A[/latex]. A subset may contain some elements of set [latex]A[/latex], no elements of set [latex]A[/latex] (i.e. the empty set, [latex]\varnothing[/latex]) or all elements of set [latex]A[/latex] (i.e. [latex]A[/latex]).

If set [latex]B[/latex] is a subset of set [latex]A[/latex], we write [latex]B\;\subseteq\;A[/latex].

A proper subset is a subset that is not identical to the original set—it contains fewer elements.

If set [latex]B[/latex] is a proper subset of set [latex]A[/latex], we write [latex]B\;\subset\;A[/latex].

The bottom bar in the subset notation  [latex]\subseteq[/latex] represents the equality sign, meaning the whole set is a subset of itself. Notice that the proper subset notation [latex]\subset[/latex] does not have that equals bar so does not include the whole set as a subset of itself.

Example

Consider these three sets:

[latex]A=\text{the set of all even numbers}[/latex]
[latex]B=\{2,4,6\}[/latex]
[latex]C=\{2,3,4,6\}[/latex]

Here [latex]B\:\subset\:A[/latex] since every element of [latex]B[/latex] is an even number, so is an element of [latex]A[/latex].

More formally, we could say [latex]B\:\subset\:A[/latex] since if [latex]x\:\in\:B[/latex], then [latex]x\:\in\:A[/latex].

It is also true that [latex]B\:\subset\:C[/latex] because every element of [latex]B[/latex] is an element of [latex]C[/latex].

[latex]C[/latex] is NOT a subset of [latex]A[/latex], since [latex]C[/latex] contains an element, 3, that is not contained in [latex]A[/latex].

Example

Suppose a set contains the plays “Much Ado About Nothing,” “MacBeth,” and “A Midsummer’s Night Dream.” What is a larger set this might be a subset of?

There are many possible answers here. One would be the set of plays by Shakespeare. This is also a subset of the set of all plays ever written. It is also a subset of all British literature.

Universal Set

Universal Set

A universal set is a set that contains all the elements we are interested in. This is defined by context.

Example

  1. If we are discussing searching for books, the universal set might be all the books in the library.
  2. If we are grouping our Facebook friends, the universal set would be all of our Facebook friends.
  3. If we are working with sets of numbers, the universal set might be all whole numbers, all integers, or all real numbers.

Union, Intersection, and Complement

It is common for sets to interact. For example, you and a new roommate decide to have a house party, and you both invite your circle of friends. At this party, two sets are being combined, though it might turn out that there are some friends that are in both sets.

Union, Intersection, and Complement

The union of two sets contains all the elements contained in either set. The union is notated [latex]A\:\cup\:B[/latex]. More formally, [latex]x\in \:A\cup\:B[/latex] if [latex]x\in\:A[/latex] or [latex]x\in\:B[/latex].

The intersection of two sets contains only the elements that are in both sets. The intersection is notated [latex]A\cap\,B[/latex]More formally, [latex]x\:\in\,A\cap\,B\:\text{if}\:x\in\,A\:\text{and}\:x\in\,B[/latex].

The complement of a set [latex]A[/latex] contains everything that is not in the set [latex]A[/latex]. The complement is notated [latex]A^{\prime}[/latex], or [latex]A^c[/latex]. A complement is relative to the universal set, so [latex]A^{\prime}[/latex] contains all the elements in the universal set that are not in [latex]A[/latex].

Notice that we used a letter, [latex]x[/latex], to represent any element in a set. This letter is called a variable and is just a stand-in for any element in a given set.

Example

Suppose the universal set is [latex]U[/latex] = all whole numbers from 1 to 9. i.e. [latex]U=\{1,2,3,4,5,6,7,8,9\}[/latex]

If [latex]A=\{1, 2, 4\}[/latex], then [latex]A^{\prime}=\{3,5,6,7,8,9\}[/latex].

Example

Consider the sets:

[latex]A=\{\text{red, green, blue}\}[/latex]
[latex]B=\{\text{red, yellow, orange}\}[/latex]
[latex]C=\{\text{red, orange, yellow, green, blue, purple}\}[/latex]

Find the following:

  1. Find [latex]A\cup\,B[/latex]
  2. Find [latex]A\cap\,B[/latex]
  3. Find [latex]A^{\prime}\cap\,C[/latex]

Answers

  1. The union contains all the elements in either set: [latex]A\cup\,B=\{\text{red, green, blue, yellow, orange}\}[/latex]. Notice we only list red once.
  2. The intersection contains all the elements in both sets: [latex]A\cap\,B=\{\text{red}\}[/latex]. Red is the only color in both sets.
  3. Here we’re looking for all the elements that are not in set [latex]A[/latex] but are in set [latex]C[/latex]:  [latex]A^{\prime}\cap\,C=\{\text{orange, yellow, purple}\}[/latex]

Try It

Using the sets from the previous example, find [latex]A\cup\,C[/latex] and [latex]B^{\prime}\cap\,A[/latex]

Set operations can be grouped together using grouping symbols to force an order of operations, just like in arithmetic. Parentheses are used to tell us which operation to perform first.

Example

Suppose [latex]H=\{\text{cat, dog, rabbit, mouse}\}[/latex], [latex]F=\{\text{dog, cow, duck, pig, rabbit}\}[/latex], and [latex]W=\{\text{duck, rabbit, deer, frog, mouse}\}[/latex].

  1. Find [latex](H\cap\,F)\cup\,W[/latex]
  2. Find [latex]H\cap\,(F\cup\,W)[/latex]
  3. Find [latex](H\cap\,F)^{\prime}\cap\,W[/latex]

Solutions

  1. We start with the intersection since it is in parentheses: [latex](H\cap\,F)=\{\text{dog, rabbit}\}[/latex]. Now we union that result with [latex]W[/latex]:  [latex](H\cap\,F)\cup\,W=\{\text{dog, duck, rabbit, deer, frog, mouse}\}[/latex].
  2. We start with the union inside parentheses: [latex](F\cup\,W)=\{\text{dog, cow, duck, pig, rabbit, deer, frog, mouse}\}[/latex] . Now we intersect that result with [latex]H[/latex]: [latex]H\cap\,(F\cup\,W)=\{\text{dog, rabbit, mouse}\}[/latex].
  3. We start with the intersection inside parentheses: [latex](H\cap\,F)=\{\text{dog, rabbit}\}[/latex]. Now we want to find the elements of [latex]W[/latex] that are not in [latex](H\cap\,F)[/latex].  [latex](H\cap\,F)^{\prime}\cap\,W= \{\text{duck, deer, frog, mouse}\}[/latex].

Venn Diagrams

To visualize the interaction of sets, John Venn in 1880 thought to use overlapping circles, building on a similar idea used by Leonhard Euler in the eighteenth century. These illustrations are now called Venn Diagrams.

Venn Diagram

A Venn diagram represents each set by a circle, usually drawn inside of a containing box representing the universal set. Overlapping areas indicate elements common to both sets.

Example

Suppose the universal set is students in a class. [latex]A[/latex] = all students with blonde hair; [latex]B[/latex] = all students with blue eyes; [latex]C[/latex] = all students at least 6 feet tall.

 

1. What does [latex]B^{\prime}[/latex] represent?

2. What does  [latex]A\cap\,B^{\prime}[/latex] represent?

3. What does  [latex](A\cup C)^{\prime}\cap B[/latex] represent?

Use the Venn to write set interactions to represent each category.

2. Students with blonde hair and blue eyes.

3. Students with blue eyes that are at least 6 feet tall.

4.Students who have blonde hair, blue eyes, and are at least 6 feet tall.

5. Students who are under 6 feet tall and have neither blonde hair nor blue eyes.

6. Students who have neither blonde hair nor blue eyes but are at least 6′ tall.

Venn diagram

 

TRY IT

The Venn diagram shows the interaction of sports watched on TV by people who answered a survey. [latex]S[/latex] = {watched soccer}, [latex]F[/latex] = {watched football}, [latex]B[/latex] = {watched baseball}, [latex]G[/latex] = {watched golf}

Sport Venn

 

Use set interactions to represent each category.

1. People who watch only baseball?

2. People who watch golf and football?

3. People who watch football and baseball?

4. People who watch football, baseball, and soccer?

5. People who watch football but neither baseball nor soccer?

6. People who do not watch golf?

Even when the elements of the sets are unknown, Venn diagrams can illustrate unions, intersections, and complements.

Example

Create Venn diagrams to illustrate [latex]A\cup\,B[/latex], [latex]A\cap\,B[/latex], and [latex]A^{\prime}\cap\,B[/latex].

[latex]A\cup\,B[/latex] contains all elements in either set.

Fig3_1_1

[latex]A\cap\,B[/latex] contains only those elements in both sets—in the overlap of the circles.

Fig3_1_2

[latex]A^{\prime}[/latex] will contain all elements not in the set [latex]A[/latex]. [latex]A^{\prime}\cap\,B[/latex] will contain the elements in set [latex]B[/latex] that are not in set [latex]A[/latex].

Fig3_1_3

Example

Use a Venn diagram to illustrate [latex](H\cap\,F)^{\prime}\cap\,W[/latex]

We’ll start by identifying everything in the set [latex]H\cap\,F[/latex]

Fig3_1_4

 

Now, [latex](H\cap\,F)^{\prime}\cap\,W[/latex] will contain everything not in the set identified above that is also in set W.

Fig3_1_5

Example

Create an expression to represent the outlined part of the Venn diagram shown.

Fig3_1_6

The elements in the outlined set are in sets [latex]H[/latex] and [latex]F[/latex], but are not in set [latex]W[/latex]. So we represent this set as [latex]H\cap\,F\cap\,W^{\prime}[/latex].

Try It

Create an expression to represent the outlined portion of the Venn diagram shown

Fig3_1_7