A set is a collection of (mathematical) objects. There is an entire field of mathematics called set theory dedicated to the study of sets and to their use as a foundation for mathematics, but in MATH0005 we are going to give only an informal introduction to sets and their properties. If you want to know more, see the further reading section at the end of this chapter.
We use curly brackets to denote sets and commas to separate the things in the set. is the set containing 1, 2, and 3.
Sets are what we use for reasoning about unordered collections of objects, ignoring repetition. Unordered means that we consider and the same set, ignoring repetition means that . You will see why this is true when we make a definition of set equality shortly.
The things in a set are called its elements or members. We write to mean that is an element or member of the set , and to mean that is not an element or member of .
There is a unique set with no elements, called the empty set and written or . No matter what is, .
We allow any kind of mathematical object, including sets themselves, as elements of sets. Sets can contain functions, matrices, vectors, numbers, and sets themselves.
is a set whose four elements are the empty set, the number 1, the set containing the number 2, and the set containing the set containing 3.
Let . Then , , , .
We need vocabulary for talking about one set being contained in another.
is a subset of , written , if and only if every element of is also an element of .
If is not a subset of we write .
is equal to , written , if and only if for any we have if and only if .
is a proper subset of , written , if and only if but .
Thus being a proper subset of means that is a subset of and contains something that does not contain.
There is an important way to rephrase the definition of two sets being equal: if and only if and . This is sometimes useful as a proof technique, as you can split a proof of into first checking and then checking .
Why is the last equality true? The only things which are elements of are 1 and 2. The only things which are elements of element of are 1 and 2. So the two sets are equal according to our definition. There’s no concept of something being an element of a set “more than once.”
This is the way in which our definition of set equality captures the idea of sets being unordered collections of objects which disregard repetition.
The definition of subset means that the empty set is a subset of any set. for any set , because is vacuously true: there’s nothing in which could fail to be in the set in order to make false.
Suppose we have a set and a property that is true or false for each element of . For example, might be the set of all integers and might be the property “ is even”. We write
(2.1) |
for the set of all elements of for which the property is true. This is called set-builder notation. In our example,
is the set . In other texts you may see a in place of a in set builder notation; they mean exactly the same thing.
We sometimes use the notation to mean the set of all things for which the property is true.11 1 You have to be slightly careful with this kind of unrestricted comprehension because it can lead to contradictions. You can ignore this for the purposes of MATH0005, but if you want to know more then check out the Further Reading section at the end.