1.2: Sets
Understanding Sets
The most basic data structure is a set. Sets are defined by what is included or what is excluded. To understand what else this implies answer the following questions.
Checkpoint \(\PageIndex{1}\) For each of the following determine whether order matters or not.
- Members of congress (U.S. federal)
- Finishers of the Tour de France
- Students enrolled at UAA
- People in line at a coffee kiosk
Checkpoint \(\PageIndex{2}\) Given that sets indicate what is included and excluded what, if anything, is extraneous in the following sets?
- { green, gold, gold, green } (context: set of colors)
- {1,2,3,4,5,…}{1,2,3,4,5,…} (context: set of integers)
- {0,1,1×1,1×0}{0,1,1×1,1×0} (context: set of integers)
- Students enrolled in MATH A261 (context: set of students)
Checkpoint \(\PageIndex{3}\) Determine whether or not you are in the following sets.
- UAA students
- Computer Science majors
- Millionaires
- Musicians
In mathematics concepts must be "well defined." This means there are no ambiguities. For sets this means that it must be possible to determine whether every object is in a set or not. Note this does not mean that any person necessarily knows the answer, rather that some means exists. For example every number is prime or it is not. However, no person knows or can list all the primes.
Checkpoint \(\PageIndex{4}\) Are all of the sets above (Checkpoint \(\PageIndex{3}\)) well defined?
Terminology
The terms collection , set , member , and element are undefined. Collection and set are synonyms. An element is an object that is included in a set. Element and member are synonyms. Because specific sets are defined by membership, sets do not have a concept of order of their elements.
The following are mathematical notations for defining sets.
| Set | Element |
| \(T=\{true, false\}\) | \(true \in T\) |
| \(E=\{n | n=2k, k \not\in \mathbb{Z} \}\) | \(3 \not\in E\) |
|
S is the set of students enrolled in MATH A261 in the fall 2019 semester |
Guido is not in S |
Table 1.2.5. Set Notations
A set \(A\) is a subset of a set \(B\), denoted \(A \subset B\), if and only if \(a \in A\) implies \(a∈B\).
For example \(E \subset \mathbb{Z}\). Note when needed \(X \subseteq Y\) means \(X\) is a subset but might be equal to \(Y\) whereas \(X \subset Y\) means \(X\) is a subset and \(Y\) contains at least one element not in \(X\). However, we rarely need to make this distinction in this class, so we will use \(\subset\) to mean \(\subseteq\).
Often we need to talk about a set that has no elements. This is called the empty set and is written as \(\emptyset\text{.}\)
Practice
Checkpoint \(\PageIndex{7}\) Determine if the first set is a subset of the second set.
- even numbers, all integers
- vowels, letters
- colors, pastels
- chairs, people
Checkpoint \(\PageIndex{8}\) Determine if the object is an element of the given set.
- apple, fruit
- spider, insects
- bird shot (shotguns), things that float
- bumble bees (living, healthy), things that can fly