BASIC SET THEORY
James T. Smith
San Francisco State University
These notes outline some set theory on which many parts of mathematics are based.
Sets
The notions object, set, and membership are used in this theory without definition. The
expression x 0 X indicates that the object x is a member of the set X. Any object with
a member is a set, and sets are considered objects. Sometimes it’s assumed that sets are
the only objects, but not in this outline.
Notation
Using gaudier letters for sets than for their members, as in g 0 G 0 G , often enhances
clarity (but sometimes isn’t practical). These abbreviations are also useful:
0 ...
ó ...
= ....
=
/ ....
œ ...
› ...
is a member of
is not a member of
equals
does not equal
for all
for some
& ...
w
...
¬ ...
| ...
] ...
and
or
not
if ... then ...
if and only if
Equality
Two sets are equal if and only if they have the same members:
X = Y ] œt [ t 0 X ] t 0 Y ].
That is the extensionality principle.
Extension
Frequently, a set X is described by a statement of the form
t0X ] Φ
(*)
2008-01-29 16:02
Page 2
BASIC SET THEORY
where Φ is a condition involving t. For example, in calculus you often consider intervals
of real numbers:
t 0 [a, b] ] a # t & t # b.
If (*) holds, then X is called the extension of Φ. It’s appropriate to call X the extension, because, by the extensionality principle, you can deduce X = Y from (*) and the
similar statement t 0 Y ] Φ. Since X is uniquely determined when (*) holds, the
notation
X = { t : Φ}
is common. It’s read, “X is the set of all t such that Φ.” For the previous example,
[a, b] = { t : a # t & t # b }.
Each set X is the extension of some condition Φ —for example, the condition
t 0 X. That is,
t0X ] t0X
X = { t : t 0 X }.
However, there are conditions Φ that have no extension—that is, for which there’s no
set X such that (*) holds. In 1902, Bertrand Russell discovered the most celebrated
such condition: t ó t. If that had an extension X, then X 0 X ] X ó X, contradiction!
One of the most important problems in foundations of mathematics is to determine
which conditions have extensions. This outline, however, doesn’t attack that question.
Frequently, it introduces new sets X as extensions of certain conditions. The assumptions that these particular conditions have extensions have never led to contradiction.
Separation
One type of condition always has an extension: a condition applying only to members
of a previously given set. That is, to each set Y and each condition Φ corresponds a
set X whose elements are those members t of Y that satisfy Φ:
X = { t : t 0 Y & Φ}, abbreviated { t 0 Y : Φ}.
This is the separation principle. It implies, for example, that the condition t = t has no
extension: if there existed a set V such that t 0 V ] t = t, then Russell’s condition
would have an extension, namely { t 0 V : t ó t}. This result can also be phrased, there’s
no “universal” set that contains all objects.
2008-01-29 16:02
BASIC SET THEORY
Page 3
Inclusion
A set X is said to be included in a set Y —or called a subset of Y —if each member
of X belongs also to Y:
X f Y ] œt [ t 0 X | t 0 Y ].
This concept has the following properties:
XfX
XfY & YfX | X=Y
XfY & YfZ | XfZ
—reflexivity
—weak antisymmetry
—transitivity.
Power Set
To each set X corresponds a set
the subsets of X:
P X,
called the power set of X, whose members are
P X = { S : S f X }.
Empty Set
The condition t =
/ t has an extension, called the empty set φ:
œt [t ó φ].
φ = {t : t =
/ t}
By the extensionality principle, φ is the only set with no members. It’s a subset of every
set.
Singletons
To each object x corresponds a set {x}, called singleton x, whose sole member is x:
{x} = { t : t = x}.
Pairs
To any objects x and y corresponds a set {x, y}, called a pair, whose only members
are x and y:
{x, y} = { t : t = x
w
t = y}.
2008-01-29 16:02
Page 4
BASIC SET THEORY
Notice that
{ x, y} = { y, x}
{ x, x} = { x}.
Triples, quadruples, etc., could be introduced the same way, but more comprehensive
methods will be presented later.
Ordered Pairs
To any two objects x and y corresponds an object <x, y>, called an ordered pair. For
any objects x, y, xr, and yr,
<x, y> = <xr, yr> ] x = xr & y = yr.
Ordered triples and quadruples, etc., could be introduced the same way, but it’s easier
to define
<x, y, z> = <<x, y>, z>
and extend that idea to quadruples, etc.
Cartesian Product
To any sets X and Y corresponds a set X × Y, called their Cartesian product, whose
members are the ordered pairs whose first and second entries belong to X and Y:
<x, y> 0 X × Y ] x 0 X & y 0 Y.
Cartesian products of three or more sets are introduced as follows:
X × Y × Z = (X × Y ) × Z
<x, y, z> 0 X × Y × Z ] x 0 X & y 0 Y & z 0 Z.
Relations
A relation between two sets X and Y is a subset of X × Y. Thus φ and X × Y itself
are relations between X and Y. This abbreviation is commonly used for relations R:
x R y ] <x, y> 0 R .
A relation between X and itself is called a relation on X.
2008-01-29 16:02
BASIC SET THEORY
Page 5
Domain and Range
To each relation R correspond two sets, called its domain and range, whose members
are the first and second entries of the members of R:
x 0 Dom R ] › y [x R y]
y 0 Rng R ] › x [x R y].
Converse
To each relation R between sets X and Y corresponds a relation R̆ between Y and
X, called the converse of R, such that
y R̆ x ] x R y.
Relative Product
If R is a relation between sets X and Y and S is a relation between sets Y and Z,
then their relative product is the relation R*S defined as follows:
x (R*S) z ] › y [x R y & y S z].
For example, if R is the relation of person to parent and S that of sibling to brother,
then R*S is the relation of person to uncle.
The following associative law is fundamental: for any R and S as described and any
relation Q between sets W and X ,
(Q*R)*S = Q*(R*S).
Proof. Suppose w ((Q*R)*S) z. Then
›y [w (Q*R) y & y S z ]
b
›x [w Q x & x R y]
`
b
x (R*S) z
`
b
w (Q*(R*S)) z.
Thus the left hand side of the associative law equation is included in the right hand side.
You can demonstrate the reverse inclusion similarly.
The associative law permits the abbreviation Q*R*S for (Q*R)*S or Q*(R*S). The
following law is also important: for any relations R and S as described earlier,
T = R*S | T̆ = S̆*R̆.
2008-01-29 16:02
Page 6
BASIC SET THEORY
You can supply the proof.
Identity
To each set X corresponds the identity relation I X on X:
x I X xr ] x = xr & x 0 X.
For each relation R between X and a set Y,
I X *R = R = R*IY .
Image
To each relation R and each set A corresponds a subset R[A] of Rng R called the
image of A under R:
y 0 R[ A] ] ›x [x 0 A & x R y].
For each relation S,
(R*S)[ A] = S[R[ A]].
Functions
A relation F is called a function from a set X to a set Y if Dom F = X, Rng F f Y and
for all x, y,
x F y & x F yr | y = yr.
That is written F : X 6 Y. If F : X 6 Y and x 0 X then there is a unique y 0 Y such
that x F y. This is written F : x ² y. That y is called the value of F at x, and it is
denoted by F(x) or Fx . By the extensionality principle, two functions F and G are
equal if and only if they have the same domain X and F(x) = G(x) for all x 0 X.
The functions from a set X to a set Y constitute a set Y X. Here are some rules for
manipulating these function sets:
Y φ = { φ}
X=
/ φ | φX = φ
X f Y | IX 0 Y X.
A function f : X 6 X is often called a singulary operation on X; a function g : X × X 6
X is often called a binary operation on X. A function is called constant if its range is a
singleton.
2008-01-29 16:02
BASIC SET THEORY
Page 7
Composition
The composition of functions F : X 6 Y and G : Y 6 Z is the function G B F = F*G from
X to Z. The associativity law holds: if also E : W 6 X, then
(G B F ) B E = G B (F B E).
That permits the abbreviation G B F B E for either of these compositions. The following
manipulation rules hold:
x 0 X | (G B F )(x) = G(F(x))
A f X | (G B F )[A] = G[F [A]]
IY B F = F = F B I X .
Injections
If F : X 6 Y and F̆ is a function, then we say that F : X 6 Y injectively, and call F an
injection. The following rules are helpful:
φ : φ 6 Y injectively
X f Y | IX : X 6 Y injectively
F : X 6 Y injectively & G : Y 6 Z injectively
| G B F : X 6 Z injectively.
Surjections
If F : X 6 Y and Rng F = Y, then we say that F : X 6 Y surjectively, and call F a
surjection. The following rules hold:
φ : φ 6 φ surjectively
F : X 6 Y surjectively & G : Y 6 Z surjectively
| G B F : X 6 Z surjectively.
Bijections
If F : X 6 Y injectively and surjectively, then we say that F : X 6 Y bijectively and call
F a bijection. Here are useful rules:
IX : X 6 X bijectively
F : X 6 Y bijectively Y F̆ : Y 6 X bijectively
F : X 6 Y bijectively & G : Y 6 Z bijectively
Y G B F : X 6 Z bijectively.
2008-01-29 16:02
Page 8
BASIC SET THEORY
A bijection from X to itself is called a permutation of X. The set X ! of all permutations
of X is called the symmetric group on X.
Inverse
If F : X 6 Y bijectively, then F̆ is called the inverse of F and denoted by F –1. Here’s
its most important property:
F –1 B F = IX
F B F –1 = IY .
Proof. To show IX f F&1 B F, let x 0 X and define y = F(x). Then x F y, so that
y F –1 x and hence x F *F –1 x, i.e. <x, x> 0 F –1 B F. To show F –1 B F f I X , let <x, xr> 0
F –1 B F, i.e. x F *F –1 xr. Then there exists y such that x F y and y F –1 xr. But x F y
implies y F –1 x, and thus x = xr because F –1 is a function. The proof that F B F –1 =
IY is similar.
Here’s an important property of the inverse, complementary to the previous one:
G : Y 6 X & G B F = IX | G = F –1
G : Y 6 X & F B G = IY | G = F –1 .
Proof. Suppose G B F = I X ; then G = G B IY = G B (F B F –1 ) = (G B F ) B F –1 = I X B F –1 =
F –1. The second result is proved similarly.
Finally, if F : X 6 Y and G : Y 6 Z bijectively, then
(G B F ) –1 = F –1 B G –1.
Union
To any sets X and Y corresponds a set X c Y called their union, whose members are
the members of X and those of Y:
t0XcY ] t0X
w
t 0 Y.
The union is their “least upper bound” in the following sense:
X, Y f X c Y
X f Z & Y f Z | X c Y f Z.
These commutative and associative laws hold:
XcY=YcX
X c (Y c Z) = (X c Y ) c Z.
Associativity permits the abbreviation X c Y c Z for either side of this equation.
2008-01-29 16:02
BASIC SET THEORY
Page 9
Intersection
To any sets X and Y corresponds a set X 1 Y called their intersection, whose members
are the elements common to X and Y:
t 0 X 1 Y ] t 0 X & t 0 Y.
The intersection is their “greatest lower bound” in the following sense:
Z f X & Z f Y | Z f X 1 Y.
X 1 Y f X, Y
If X 1 Y = φ, then X and Y are called disjoint. These commutative, associative, and
distributive laws hold:
X1Y=Y1X
X 1 (Y 1 Z) = (X 1 Y ) 1 Z
X 1 (Y c Z) = (X 1 Y ) c (X 1 Z)
X c (Y 1 Z) = (X c Y ) 1 (X c Z) .
Associativity permits the abbreviation X 1 Y 1 Z for either side of the second equation.
Union, Continued
To any set X corresponds a set ^X called its union, whose members are the members
of the members of X :
t 0 ^X ] › X [ X 0 X & t 0 X ].
The union of
X
is its “least upper bound” in the following sense:
œX [ X 0 X | X f ^X ]
For any sets X and Y, ^{X, Y } = X c Y.
œX [ X 0 X | X f Y ] | ^ X f Y.
Intersection, Continued
To any nonempty set X corresponds a set _ X called its intersection, whose members
are the elements common to all members of X :
t 0 _X ] œX [ X 0 X | t 0 X ].
The intersection of
X
is its “greatest lower bound” in the following sense:
œX [ X 0 X | _X f X ]
For any sets X and Y, _{X, Y } = X 1 Y.
œX [ X 0 X | Y f X ] | Y f _X .
2008-01-29 16:02
Page 10
BASIC SET THEORY
Union and Intersection, Continued
Often you’ll be interested in the union or intersection of the range of a function X with
domain I. This notation is common:
∪X
i
∩X
= { t : (›i 0 I)[ t 0 X i ]}
i±I
i
= { t : (œi 0 I)[ t 0 X i ]}.
i±I
When the set I is clear from the context, these are usually abbreviated as ^ i X i and
_ i X i . This notation simplifies the statements of many rules—for example, the distributive laws
A 1 ^ i X i = ^ i (A 1 X i )
A c _ i X i = _ i (A c X i ).
Relative Complement
In this paragraph, all sets are assumed to be subsets of a single set U. To each such set
X corresponds a set –X, its complement (relative to U ), whose members are those
elements of U not in X:
–X = {t 0 U : t ó X }.
These rules hold:
–U = φ
– –X = X
X c –X = U
X f Y ] –Y f –X
–
∪X
i
i±I
=
∩
( X i)
i± I
–φ = U
—double negation
X 1 –X = φ
—contraposition
–
∩X
i±I
i
=
∪
( X i)
—de Morgan
i± I
Natural Numbers
There’s a set
whose members are called natural numbers. Among its members is
φ, which in this context is called zero and written 0. There’s a bijection
S:
6 {n 0
:n=
/ 0}
called the successor operation, which satisfies the first principle of recursive proof:
00Xf
& œn [ n 0 X | S(n) 0 X ] | X =
.
From these considerations follows— by a complicated argument—the first principle of
recursive definition:
2008-01-29 16:02
BASIC SET THEORY
Page 11
given any set Y, any y 0 Y, and any function G : Y 6 Y,
there’s a unique function F : 6 Y such that
| F (S(n)) = G(F (n)) ].
F (0) = y & œn [ n 0
Binary sum and product operations + and @ and an order relation # on
are
defined, and their usual properties proved, following standard recursive methods. In
particular, 1 is defined as S(0), so that S(n) = n + 1 for all n 0 ; and 2 is defined
as 1 + 1.
A second principle of recursive proof is sometimes handier than the first:
every nonempty X f
x 0 X.
contains a member w such that w # x for all
There’s a corresponding second principle of recursive definition:
given any set Y and any function G : × P ( × Y ) 6 Y,
there’s a unique F : 6 Y such that for each n 0 ,
œn [ n 0
| F (n) = G(<n, {<m, F (m)> : m 0
& m < n}>) ].
Integers
Following standard algebraic procedures, integers are defined as certain sets of ordered
pairs of natural numbers, and the familiar arithmetic operations are constructed for
them. They form an ordered integral domain in which each nonempty set of nonnegative elements has a minimum element. All such domains are isomorphic.
Rational Numbers
Again following standard algebraic procedures, rational numbers are defined as certain
sets of ordered pairs of integers, and the familiar arithmetic operations are constructed
for them. They form a prime ordered field . All such fields are isomorphic.
Real Numbers
Following standard analytic procedures, real numbers are defined as certain sets of
sequences of rational numbers—i.e. certain sets of functions from
to
—and the
familiar arithmetic operations are constructed for them. They form a complete ordered
field . All such fields are isomorphic. (Alternative definitions of real numbers as
certain sets of rational numbers or certain sequences of integers are common.)
2008-01-29 16:02
Page 12
BASIC SET THEORY
Complex Numbers
Following a standard algebraic procedure, complex numbers are defined as pairs of real
numbers, and the familiar arithmetic operations are constructed for them. They form
an algebraically closed field .
Trivial questions
1.
Pφ=?
P {φ} = ?
2.
{x, x} = ?
3.
φ×X=?
X×φ=?
4.
Dom φ = ?
Rng φ = ?
5.
Dom {<x, y>} = ?
Rng {<x, y>} = ?
6.
Dom ( X × Y ) = ?
Rng (X × Y ) = ?
7.
φ̆ = ?
R = {<x, y>} | R̆ = ?
8.
R = X × Y | R̆ = ?
R = S̆ | R̆ = ?
9.
φ*R = ?
R*φ = ?
10.
{<x, y>}*{<y, z>} = ?
11.
(X × Y )*(Y × Z) = ?
Careful!
12.
Dom(R*S) f Dom(?)
Rng(R*S) f Rng(?)
13.
Iφ = ?
I{x} = ?
14.
φ[A] = ?
R[φ] = ?
15.
R[Dom R] = ?
R̆[Rng R] = ?
16.
Xcφ=?
X1φ=?
17.
XcX=?
X1X=?
18.
{x} c { y} = ?
{x} 1 { y} = ?
19.
XcY=Y ] ?
X1Y=Y ] ?
20.
X c (X 1 Y ) = ?
X 1 (X c Y ) = ?
21.
IX [A] = ?
22.
^φ = ?
23.
^{X } = ?
24.
Ac
∪X
i±I
i
_{X } = ?
=
∪ (?)
i±I
A1
∩X
i±I
i
=
∩ (?)
i±I
2008-01-29 16:02
BASIC SET THEORY
Page 13
Routine exercises
1.
Prove œS [ x 0 S | y 0 S ] | x = y.
2.
Prove X f Y |
P X f P Y.
3.
Prove {{x}, {x, y}} = {{xr}, {xr, yr}} | x = xr & y = yr (Kuratowski, 1921). The
notion of ordered pair can be defined this way.
4.
Prove X × Y = Y × X ] φ = X
5.
Suppose X f Xr. What can you say about the relationship of
a.
b.
c.
d.
e.
f.
6.
X=Y
w
Y = φ.
X × Y and Xr × Y, Y × X and Y × Xr ?
R[X] and R[Xr] ?
X c Y and Xr c Y, Y c X and Y c Xr ?
X 1 Y and Xr 1 Y, Y 1 X and Y 1 Xr ?
^ X and ^ Xr ?
_ X and _ Xr ?
Suppose R and Rr are relations and R f Rr. What can you say about the relationship of
a.
b.
c.
d.
7.
w
Dom R and Dom Rr, Rng R and Rng Rr ?
R̆ and R̆r ?
R*S and Rr*S, S*R and S*Rr ?
R[A] and Rr[A] ?
Suppose œi [ X i f Yi ]. What can you say about the relationship of
a.
b.
^ i X i and ^ i Yi ?
_ i Xi and _ i Yi ?
8.
Prove that if R and S are relations, and Q = R*S, then Q̆ = S̆ *R̆. Prove that
if F : X 6 Y and G : Y 6 Z bijectively, then (G B F ) –1 = F –1 B G –1.
9.
Prove that the composition of two injections is an injection. Do the same for surjections and bijections.
10.
Prove that if R and S are relations, then (R*S)[A] = S[R[A]]. Prove that if
F : X 6 Y and G : Y 6 Z then (G B F )[A] = G[F [A]] .
11.
Prove that if R is a relation, then (X × Y )*R = X × R[Y ]. What’s R*(X × Y )?
12.
Prove all the distributive laws mentioned.
2008-01-29 16:02
Page 14
BASIC SET THEORY
13.
Prove the de Morgan laws.
14.
Prove the modular law X f Z ] X c (Y 1 Z) = (X c Y ) 1 Z.
Prove that X c Y = X c Z & X 1 Y = X 1 Z | Y = Z.
15.
a.
b.
c.
d.
16.
When does a relative complement of a set equal that set itself ?
17.
a.
b.
Why can’t we define _ φ?
Why can’t we define an absolute complement –X = {t : t ó X } ?
18.
a.
Prove that if R is a relation, then R[ ^ i A i ] = ^ i R[A i ].
Prove ^ P X = X.
Prove X f P ^ X .
Find X so that X = P ^ X .
/ P ^X .
Find X so that X =
Suppose S is a relation and for each i, Ri is a relation. Prove
b.
c.
d.
e.
19.
Dom ^ i Ri = ^ i Dom Ri and Rng ^ i Ri = ^ i Rng Ri
R = ^ i Ri | R̆ = ^ i R̆i
(^ i Ri)*S = ^ i (Ri*S) and S*^ i Ri = ^ i (S*Ri )
(^ i Ri )[A] = ^ i Ri [A] .
If F : X 6 Y, then define F̆“ : P Y 6 P X by setting F̆“(B) = F̆ [B] for every
B 0 P Y. Prove that if F is injective, then F̆“ is surjective. Prove that if F is
surjective, then F̆“ is injective.
Substantial problems
1.
Undertake routine exercise 18 with unions replaced by intersections. You’ll find
that you must replace many equations by inclusions. In those cases, find examples
where the equations hold, and examples where they don’t. Keep the examples
simple—use intersections of two sets only.
2.
Let R be a relation. Prove that
B f Rng R | B f R[R̆[B]] .
Prove that R is a function if and only if
œB [ B f Rng R | B = R[R̆[B]] ].
Find a function F and a set B f Dom F such that B =
/ F̆ [F [B]], and another
F and B such that the equation does hold.
2008-01-29 16:02
BASIC SET THEORY
3.
Page 15
A function F : X 6 Y is called right cancellative if
G : Y 6 Z & Gr : Y 6 Zr & G B F = Gr B F | G = Gr.
It’s left cancellative if
E : W 6 X & Er : Wr 6 X & F B E = F B Er | E = Er.
Prove that F is injective if and only if it’s left cancellative and surjective if and only
if it’s right cancellative.
4.
Suppose that for each i 0 I, Fi is a function from a subset of a set X to a set Y.
Further, assume (œi, j 0 I)(›k 0 I)[ Fi f Fk & Fj f Fk]. Prove that ^ i Fi is a
function from a subset of X to Y, and if each Fi is injective, then so is ^ i Fi .
5.
Consider some sets A n for n 0
Liminf n A n =
∪∩ A
n
. Define
Limsup n A n =
m nm
∩∪ A
n
.
m nm
Prove
a.
b.
c.
6.
Liminf n A n f Limsup n A n
œn [ A n f A n+1 ] | Liminf n A n = ^ n A n = Limsup n A n
œn [ A n+1 f A n ] | Liminf n A n = _ n A n = Limsup n A n .
Let m, n 0 and X and Y be sets with m and n elements. How many elements
have the sets
(X × {0}) c (Y × {1})
X×Y
PX
Y X?
How many injections are there from X to Y? How many bijections are there from
X to X?
7.
Show that this condition on t has no extension:
¬›s [ s
0 t & t 0 s ].
References
Bourbaki, Nicholas. 1968. Theory of Sets. Elements of Mathematics, Part 1, Book 1.
Reading, Massachusetts: Addison–Wesley. LC: QA248.B73413. Pages 65–277. Skip
over all references to his (rather unusual) axiom system.
Cohen, Leon W., and Gertrude Ehrlich. 1963. The Structure of the Real Number System.
Princeton: D. Van Nostrand. LC: QA241.C67.
Lipschutz, Seymour. 1964. Schaum’s Outline of Theory and Problems of Set Theory and
Related Topics. New York: McGraw–Hill. LC: QA248.L57. ISBN: 0-070-38159-3.
Pages 1–184. Upper-division text.
2008-01-29 16:02
Page 16
BASIC SET THEORY
Monk, J. Donald. 1969. Introduction to Set Theory. New York: McGraw–Hill. LC:
QA248.M53. Axiomatic treatment, von Neumann–Bernays–Gödel–Morse version.
Beginning graduate level.
Stoll, Robert R. [1963] 1979. Set Theory and Logic. New York: Dover Publications.
Originally published by W. H. Freeman. LC: QA248.S7985. ISBN: 0-486-63829-4.
Pages 1–154, 289–306. Between the levels of Lipschutz and Monk.
Suppes, Patrick. 1960. Axiomatic Set Theory. Princeton: D. Van Nostrand. LC:
QA248.S92. Axiomatic treatment, Zermelo–Fraenkel version. Same level as Monk
1969. Rather close to this outline.
2008-01-29 16:02