Lec13 MTH207
Lec13 MTH207
1 Cardinality of sets
Introduction
Previously we defined the cardinality of a finite set as the number of elements in the set. We
use the cardinalities of finite sets to tell us when they have the same size, or when one is
bigger than the other.
In this section we extend this notion to infinite sets. That is, we will define what it means for
two infinite sets to have the same cardinality, providing us with a way to measure the relative
sizes of infinite sets.
We will be particularly interested in countably infinite sets, which are sets with the same
cardinality as the set of positive integers. We will establish the surprising result that the set of
rational numbers is countably infinite.
We will also provide an example of an uncountable set when we show that the set of real
numbers is not countable.
We now define what it means for two sets to have the same size, or cardinality.
Definition
The sets A and B have the same cardinality if and only if there is a one-to-one
correspondence from A to B. When A and B have the same cardinality, we write |A| = |B|.
For infinite sets the definition of cardinality provides a relative measure of the sizes of two
sets, rather than a measure of the size of one particular set. We can also define what it
means for one set to have a smaller cardinality than another set.
Definition
If there is a one-to-one function from A to B, the cardinality of A is less than or the same as
the cardinality of B and we write |A| ≤ |B|. Moreover, when |A| ≤ |B| and A and B have
different cardinality, we say that the cardinality of A is less than the cardinality of B and we
write |A| < |B|.
We now define what it means for two sets to have the same size, or cardinality.
Definition
The sets A and B have the same cardinality if and only if there is a one-to-one
correspondence from A to B. When A and B have the same cardinality, we write |A| = |B|.
For infinite sets the definition of cardinality provides a relative measure of the sizes of two
sets, rather than a measure of the size of one particular set. We can also define what it
means for one set to have a smaller cardinality than another set.
Definition
If there is a one-to-one function from A to B, the cardinality of A is less than or the same as
the cardinality of B and we write |A| ≤ |B|. Moreover, when |A| ≤ |B| and A and B have
different cardinality, we say that the cardinality of A is less than the cardinality of B and we
write |A| < |B|.
Definition
A set that is either finite or has the same cardinality as the set of positive integers is called
countable. A set that is not countable is called uncountable. When an infinite set S is
countable, we denote the cardinality of S by ℵ0 (where ℵ is aleph, the first letter of the
Hebrew alphabet). We write |S| = ℵ0 and say that S has cardinality ”aleph null.”
Definition
A set that is either finite or has the same cardinality as the set of positive integers is called
countable. A set that is not countable is called uncountable. When an infinite set S is
countable, we denote the cardinality of S by ℵ0 (where ℵ is aleph, the first letter of the
Hebrew alphabet). We write |S| = ℵ0 and say that S has cardinality ”aleph null.”
Example
Show that the set of odd positive integers O is a countable set.
Definition
A set that is either finite or has the same cardinality as the set of positive integers is called
countable. A set that is not countable is called uncountable. When an infinite set S is
countable, we denote the cardinality of S by ℵ0 (where ℵ is aleph, the first letter of the
Hebrew alphabet). We write |S| = ℵ0 and say that S has cardinality ”aleph null.”
Example
Show that the set of odd positive integers O is a countable set.
Solution
f : Z+ → O
n → 2n − 1
Remark
An infinite set is countable if and only if it is possible to list the elements of the set in a
sequence (indexed by the positive integers). The reason for this is that a one-to-one
correspondence f from the set of positive integers to a set S can be expressed in terms of a
sequence a1 , a2 , ..., an , ..., where a1 = f (1), a2 = f (2), ..., an = f (n), ....
Remark
An infinite set is countable if and only if it is possible to list the elements of the set in a
sequence (indexed by the positive integers). The reason for this is that a one-to-one
correspondence f from the set of positive integers to a set S can be expressed in terms of a
sequence a1 , a2 , ..., an , ..., where a1 = f (1), a2 = f (2), ..., an = f (n), ....
Example
Show that the set of all integers is countable.
Remark
An infinite set is countable if and only if it is possible to list the elements of the set in a
sequence (indexed by the positive integers). The reason for this is that a one-to-one
correspondence f from the set of positive integers to a set S can be expressed in terms of a
sequence a1 , a2 , ..., an , ..., where a1 = f (1), a2 = f (2), ..., an = f (n), ....
Example
Show that the set of all integers is countable.
Solution
f : Z+ → Z
n
, if n is even
f (n) = 2
n−1
−
, if n is odd
2
f is one to one correspondence function.
Example
Show that the set of positive rational numbers is countable.
Example
Show that the set of positive rational numbers is countable.
Solution
We will show that we can list the positive rational numbers as a sequence r1 , r2 , ..., rn , ...
p
First, note that every positive rational number is the quotient of two positive integers.
q
We can arrange the positive rational numbers by listing those with denominator q = 1 in the
first row, those with denominator q = 2 in the second row, and so on, as displayed in the
figure below.
Solution
The key to listing the rational numbers in a sequence is to first list the positive rational
p
numbers with p + q = 2, followed by those with p + q = 3, followed by those with
q
p + q = 4, and so on, following the path shown in the figure. Whenever we encounter a
p
number that is already listed, we do not list it again. The initial terms in the list of positive
q
rational numbers we have constructed are 1, 1/2, 2, 3, 1/3, 1/4, 2/3, 3/2, 4, 5, and so on.
An Uncountable Set
Example
Show that the set of real numbers is an uncountable set.
An Uncountable Set
Example
Show that the set of real numbers is an uncountable set.
Solution
To show that the set of real numbers is uncountable, we suppose that the set of real numbers
is countable and arrive at a contradiction.
Then, the subset of all real numbers that fall between 0 and 1 would also be countable
(because any subset of a countable set is also countable.
Under this assumption, the real numbers between 0 and 1 can be listed in some order, say,
r1 , r2 , r3 , . . . . Let the decimal representation of these real numbers be
Solution
Then, form a new real number with decimal expansion r = 0.d1 d2 d3 d4 ..., where the decimal
digits are determined by the following rule:
4, if dii ̸= 4
di =
5, if dii = 4
Theorem
If A and B are countable sets, then A ∪ B is also countable.
Theorem
If A and B are countable sets, then A ∪ B is also countable.
Proof
Without loss of generality, we can assume that A and B are disjoint. (If they are not, we can
replace B by B - A, because A ∩ (B − A) = ∅ and A ∪ (B − A) = A ∪ B.)
quad
Case (i): Note that when A and B are finite, A ∪ B is also finite, and therefore, countable.
quad
Case (ii): Because A is countably infinite, its elements can be listed in an infinite sequence a1 ,
a2 , a3 , . . ., an , ... and because B is finite, its terms can be listed as b1 , b2 , . . ., bm for some
positive integer m. We can list the elements of A ∪ B as b1 , b2 , . . ., bm , a1 , a2 , a3 , . . ., an , ....
This means that A ∪ B is countably infinite.
Case (iii): Because both A and B are countably infinite, we can list their elements as a1 , a2 ,
a3 , . . ., an , ... and b1 , b2 , . . ., bn , . . ., respectively. By alternating terms of these two
sequences we can list the elements of A ∪ B in the infinite sequence a1 , b1 , a2 , b2 , a3 , b3 , . .
., an , bn , . . .. This means A ∪ B must be countably infinite.
Exercise 1
Determine whether each of these sets is finite, countably infinite or uncountable. For those
who are countably infinite, find a bijection between them and the set N.
a) The integers greater than 10.
b) The odd negative integers.
c) The integers with absolute value less than 1000000 .
d) The real numbers between 0 and 2 .
e) The integers that are multiple of 10.
Exercise 2
Give an example of two uncountable sets A and B such that A-B is
a) Finite.
b) Countably Infinite.
c) Uncountable.