10.1: Sets and Set Notation
-
- Last updated
- Save as PDF
A set is a collection of things called elements . For example \(\left\{ 1,2,3,8\right\}\) would be a set consisting of the elements 1,2,3, and 8. To indicate that \(3\) is an element of \(\left\{ 1,2,3,8\right\} ,\) it is customary to write \(3\in \left\{ 1,2,3,8\right\}.\) We can also indicate when an element is not in a set, by writing \(9\notin \left\{ 1,2,3,8\right\}\) which says that \(9\) is not an element of \(\left\{ 1,2,3,8\right\}.\) Sometimes a rule specifies a set. For example you could specify a set as all integers larger than \(2.\) This would be written as
\[S=\left\{ x\in \mathbb{Z}:x>2\right\} .\nonumber \]
This notation says: \(S\) is the set of all integers, \(x,\) such that \(x>2.\)
Suppose \(A\) and \(B\) are sets with the property that every element of \(A\) is an element of \(B\). Then we say that \(A\) is a subset of \(B.\) For example, \(\left\{ 1,2,3,8\right\}\) is a subset of \(\left\{ 1,2,3,4,5,8\right\}.\) In symbols, we write
\[\left\{ 1,2,3,8\right\} \subseteq \left\{ 1,2,3,4,5,8\right\} .\nonumber \]
It is sometimes said that “\(A\) is contained in \(B\)" or even “\(B\) contains \(A\)". The same statement about the two sets may also be written as
\[\left\{ 1,2,3,4,5,8\right\} \supseteq \left\{ 1,2,3,8\right\}. \nonumber\]
We can also talk about the union of two sets, which we write as \(A \cup B\). This is the set consisting of everything which is an element of at least one of the sets, \(A\) or \(B\). As an example of the union of two sets, consider
\[\left\{ 1,2,3,8\right\} \cup \left\{ 3,4,7,8\right\} =\left\{ 1,2,3,4,7,8\right\}.\nonumber \]
This set is made up of the numbers which are in at least one of the two sets.
In general
\[A\cup B = \left\{ x:x\in A \text{ or }x\in B\right\}\nonumber \]
Notice that an element which is in both \(A\) and \(B\) is also in the union, as well as elements which are in only one of \(A\) or \(B\).
Another important set is the intersection of two sets \(A\) and \(B\), written \(A \cap B\). This set consists of everything which is in both of the sets. Thus \(\left\{ 1,2,3,8\right\} \cap \left\{ 3,4,7,8\right\} =\left\{ 3,8\right\}\) because \(3\) and \(8\) are those elements the two sets have in common. In general, \[A\cap B = \left\{ x:x\in A\text{ and }x\in B\right\}\nonumber \]
If \(A\) and \(B\) are two sets, \(A\setminus B\) denotes the set of things which are in \(A\) but not in \(B.\) Thus \[A\setminus B = \left\{ x\in A:x\notin B\right\}\nonumber \] For example, if \(A = \left\{1,2,3,8 \right\}\) and \(B = \left\{ 3,4,7,8 \right\}\), then \(A \setminus B = \left\{ 1,2,3,8\right\} \setminus \left\{ 3,4,7,8 \right\} =\left\{1,2 \right\}\).
A special set which is very important in mathematics is the empty set denoted by \(\emptyset\), which is defined as the set which has no elements in it. It follows that the empty set is a subset of every set. This is true because if it were not so, there would have to exist a set \(A,\) such that \(\emptyset\) has something in it which is not in \(A.\) However, \(\emptyset\) has nothing in it and so it must be that \(\emptyset \subseteq A.\)
We can also use brackets to denote sets which are intervals of numbers. Let \(a\) and \(b\) be real numbers. Then
- \(\left[ a,b\right] = \{x \in \mathbb{R}: a\leq x\leq b \}\)
- \(\left[a,b \right) = \{x \in \mathbb{R}: a\leq x<b \}\)
- \(\left( a,b\right) = \{x \in \mathbb{R}: a<x<b \}\)
- \((a,b] = \{ x \in \mathbb{R}: a<x\leq b \}\)
- \([a,\infty ) = \{x \in \mathbb{R}: x\geq a \}\)
- \((-\infty ,a] = \{x \in \mathbb{R}: x \leq a \}\)
These sorts of sets of real numbers are called intervals. The two points \(a\) and \(b\) are called endpoints, or bounds, of the interval. In particular, \(a\) is the lower bound while \(b\) is the upper bound of the above intervals, where applicable. Other intervals such as \(\left( -\infty ,b\right)\) are defined by analogy to what was just explained. In general, the curved parenthesis, \((\), indicates the end point is not included in the interval, while the square parenthesis, \([\), indicates this end point is included. The reason that there will always be a curved parenthesis next to \(\infty\) or \(-\infty\) is that these are not real numbers and cannot be included in the interval in the way a real number can.
To illustrate the use of this notation relative to intervals consider three examples of inequalities. Their solutions will be written in the interval notation just described.
Example \(\PageIndex{1}\): Solving an Inequality
Solve the inequality \(2x+4\leq x-8\).
Solution
We need to find \(x\) such that \(2x+4\leq x-8\). Solving for \(x\), we see that \(x\leq -12\) is the answer. This is written in terms of an interval as \((-\infty ,-12].\)
Consider the following example.
Example \(\PageIndex{2}\): Solving an Inequality
Solve the inequality \(\left( x+1\right) \left( 2x-3\right) \geq0.\)
Solution
We need to find \(x\) such that \(\left( x+1\right) \left( 2x-3\right) \geq0.\) The solution is given by \(x\leq -1\) or \(x\geq \frac{3}{2}\). Therefore, \(x\) which fit into either of these intervals gives a solution. In terms of set notation this is denoted by \((-\infty ,-1]\cup [ \frac{3}{2},\infty ).\)
Consider one last example.
Example \(\PageIndex{3}\): Solving an Inequality
Solve the inequality \(x \left( x+2\right) \geq-4\).
Solution
This inequality is true for any value of \(x\) where \(x\) is a real number. We can write the solution as \(\mathbb{R}\) or \(\left( -\infty ,\infty \right) .\)
In the next section, we examine another important mathematical concept.