Applications of Methods of Proof
Applications of Methods of Proof
1. Set Operations
Recall that in any discussion about sets and set operations there must be a set,
called a universal set, that contains all others sets to be considered. This term is a
bit of a misnomer: logic prohibits the existence of a “set of all sets,” so that there
is no one set that is “universal” in this sense. Thus the choice of a universal set will
depend on the problem at hand, but even then it will in no way be unique. As a rule
we usually choose one that is minimal to suit our needs. For example, if a discussion
involves the sets {1, 2, 3, 4} and {2, 4, 6, 8, 10}, we could consider our universe to be
the set of natural numbers or the set of integers. On the other hand, we might be
able to restrict it to the set of numbers {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}.
We now restate the operations of set theory using the formal language of logic.
∀x[x ∈ A ↔ x ∈ B]
∀x[x ∈ A → x ∈ B].
96
1. SET OPERATIONS 97
1.4. Complement.
Definition 1.4.1. The complement of A
A = {x ∈ U |¬(x ∈ A)} = {x ∈ U |x 6∈ A}.
Discussion
There are several common notations used for the complement of a set. For exam-
ple, Ac is often used to denote the complement of A. You may find it easier to type
Ac than A, and you may use this notation in your homework.
1.5. Difference.
Definition 1.5.1. The difference of A and B, or the complement of B rela-
tive to A,
A − B = A ∩ B.
Definition 1.5.2. The symmetric difference of A and B,
A ⊕ B = (A − B) ∪ (B − A)
= (A ∪ B) − (A ∩ B).
Discussion
The difference and symmetric difference of two sets are new operations, which
were not defined in Module 1.1. Notice that B does not have to be a subset of A for
1. SET OPERATIONS 98
the difference to be defined. This gives us another way to represent the complement
of a set A; namely, A = U − A, where U is the universal set.
The definition of the difference of two sets A and B in some universal set, U , is
equivalent to A − B = {x ∈ U |(x ∈ A) ∧ ¬(x ∈ B)}.
The symmetric difference of two sets corresponds to the logical operation ⊕, the
exclusive “or”.
The definition of the symmetric difference of two sets A and B in some universal
set, U , is equivalent to
A ⊕ B = {x ∈ U |[(x ∈ A) ∧ ¬(x ∈ B)] ∨ [¬(x ∈ A) ∧ (x ∈ B)]}.
1.6. Product.
Definition 1.6.1. The (Cartesian) Product of two sets, A and B, is denoted
A × B and is defined by
A × B = {(a, b)|a ∈ A ∧ b ∈ B}
Discussion
Keep in mind the power set is a set where all the elements are actually sets and
the power set should include the empty set and itself as one of its elements.
1.8. Examples.
Example 1.8.1. Assume: U = {a, b, c, d, e, f, g, h}, A = {a, b, c, d, e}, B =
{c, d, e, f }, and C = {a, b, c, g, h}. Then
(a) A ∪ B = {a, b, c, d, e, f }
(b) A ∩ B = {c, d, e}
(c) A = {f, g, h}
(d) B = {a, b, g, h}
(e) A − B = {a, b}
(f ) B − A = {f }
(g) A ⊕ B = {a, b, f }
1. SET OPERATIONS 99
(h) (A ∪ B) ∩ C = {a, b, c}
(i) A × B = {(a, c), (a, d), (a, e), (a, f ), (b, c), (b, d), (b, e), (b, f ), (c, c), (c, d), (c, e),
(c, f ), (d, c), (d, d), (d, e), (d, f ), (e, c), (e, d), (e, e), (e, f )}
(j) P(A) = {∅, {a}, {b}, {c}, {d}, {e}, {a, b}, {a, c}, {a, d}, {a, e}, {b, c}, {b, d}, {b, e},
{c, d}, {c, e}, {d, e}, {a, b, c}, {a, b, d}, {a, b, e}, {a, c, d}, {a, c, e}, {a, d, e}, {b, c, d},
{b, c, e}, {b, d, e}, {c, d, e}, {a, b, c, d}, {a, b, c, e}, {a, b, d, e}, {a, c, d, e}, {b, c, d, e},
{a, b, c, d, e}}
(k) |P(A)| = 32
(1) B × A
(2) P(B)
(3) |P(U )|
Example 1.8.2. Let the universal set be U = Z+ the set of all positive integers,
let P be the set of all prime (positive) integers, and let E be the set of all positive
even integers. Then
Discussion
1. SET OPERATIONS 100
Venn Diagrams can be very helpful in visualizing set operations when you are
dealing with three or fewer sets (not including the universal set). They tend not
to be as useful, however, when considering more than three sets. Although Venn
diagrams may be helpful in visualizing sets and set operations, they will not be used
for proving set theoretic identities.
1.10. Examples.
Example 1.10.1. The following Venn Diagrams illustrate generic relationships
between two and three sets, respectively.
U
A B
A B C
Example 1.10.2. This Venn Diagram represents the difference A − B (the shaded
region).
U
A- B
A B
The figures in the examples above show the way you might draw the Venn diagram
if you aren’t given any particular relations among the sets. On the other hand, if you
knew, for example, that A ⊆ B, then you would draw the set A inside of B.
1. SET OPERATIONS 101
Example 1.11.1. Prove that the complement of the union is the intersection of
the complements:
A ∪ B = A ∩ B.
Proof 1. One way to show the two sets are equal is to use the fact that
A∪B =A∩B
iff
A ∪ B ⊆ A ∩ B and A ∩ B ⊆ A ∪ B.
Step 1. Show A ∪ B ⊆ A ∩ B.
Assume x is an arbitrary element of A ∪ B (and show x ∈ A ∩ B). Since
x ∈ A ∪ B, x 6∈ A ∪ B. This means x 6∈ A and x 6∈ B (De Morgan’s Law).
Hence x ∈ A ∩ B. Thus, by Universal Generalization,
∀x[x ∈ (A ∪ B) → x ∈ (A ∩ B)]
so that, by definition,
A ∪ B ⊆ A ∩ B.
Step 2. Show A ∩ B ⊆ A ∪ B.
Suppose x is an arbitrary element of A ∩ B. Then x 6∈ A and x 6∈ B.
Therefore, x 6∈ A ∪ B (De Morgan’s Law). This shows x ∈ A ∪ B. Thus, by
Universal Generalization,
∀x[x ∈ (A ∩ B) → x ∈ (A ∪ B)]
so that, by definition,
A ∩ B ⊆ A ∪ B.
Proof 2. The following is a second proof of the same result, which emphasizes
more clearly the role of the definitions and laws of logic. We will show
∀x[x ∈ A ∪ B ↔ x ∈ A ∩ B].
1. SET OPERATIONS 102
Assertion Reason
∀x:
x ∈ A ∪ B ⇔ x 6∈ [A ∪ B] Definition of complement
⇔ ¬[x ∈ A ∪ B] Definition of 6∈
⇔ ¬[(x ∈ A) ∨ (x ∈ B)] Definition of union
⇔ ¬(x ∈ A) ∧ ¬(x ∈ B) De Morgan’s Law
⇔ (x ∈ A) ∧ (x ∈ B) Definition of complement
⇔x∈A∩B Definition of intersection
(In practice we usually omit the formality of writing ∀x in the initial line of the
proof and assume that x is an arbitrary element of the universe of discourse.)
Proof 3. A third way to prove this identity is to build a membership table for
the sets A ∪ B and A ∩ B, and show the membership relations for the two sets are the
same. The 1’s represent membership in a set and the 0’s represent nonmembership.
Compare this table to the truth table for the proof of De Morgan’s Law:
¬(p ∨ q) ↔ (¬p ∧ ¬q)
Discussion
A set identity is an equation involving sets and set operations that is true for all
possible choices of sets represented by symbols in the identity. These are analgous to
identities such as
(a + b)(a − b) = a2 − b2
1. SET OPERATIONS 103
There are various ways to prove an identity, and three methods are covered here.
This is a good place to be reminded that when you are proving an identity, you must
show that it holds in all possible cases. Remember, giving an example does not prove
an identity. On the other hand, if you are trying to show that an expression is not
an identity, then you need only provide one counterexample. (Recall the negation of
∀xP (x) is ∃x¬P (x)).
Proof 1 establishes equality by showing each set is a subset of the other. This method
can be used in just about any situation.
Notice that in Proof 1 we start with the assumption, x is in A ∪ B, where
x is otherwise an arbitrary element in some universal set. If we can show
that x must then be in A ∩ B, then we will have established
∀x, [x ∈ A ∪ B] → [x ∈ A ∩ B].
That is, the modus operandi is to prove the implications hold for an arbitrary
element x of the universe, concluding, by Universal Generalization, that the
implications hold for all such x.
Notice the way De Morgan’s Laws are used here. For example, in the first
part of Proof 1, we are given that x 6∈ (A ∪ B). This means
¬[x ∈ (A ∪ B)] ⇔ ¬[(x ∈ A) ∨ (x ∈ B)] ⇔ [(x 6∈ A) ∧ (x 6∈ B)].
Proof 2 more clearly exposes the role of De Morgan’s Laws. Here we prove the identity
by using propositional equivalences in conjunction with Universal General-
ization. When using this method, as well as any other, you must be careful
to provide reasons.
Proof 3 provides a nice alternative when the identity only involves a small number
of sets. Here we show two sets are equal by building a member table for the
sets. The member table has a 1 to represent the case in which an element is
a member of the set and a 0 to represent the case when it is not. The set
operations correspond to a logical connective and one can build up to the
column for the set desired.
You will have proved equality if you demonstrate that the two columns for
the sets in question have the exact same entries. Notice that all possible
membership relations of an element in the universal set for the sets A and B
are listed in the first two columns of the membership table. For example, if
an element is in both A and B in our example, then it satisfies the conditions
in the first row of the table. Such an element ends up in neither of the two
sets A ∪ B nor A ∩ B.
This is very straight forward method to use for proving a set identity. It
may also be used to prove containment. If you are only trying to show the
containment M ⊆ N , you would build the membership table for M and N
as above. Then you would look in every row where M has a 1 to see that
1. SET OPERATIONS 104
N also has a 1. However, you will see examples in later modules where a
membership table cannot be created. It is not always possible to represent
all the different possibilities with a membership table.
Assertion Reason
x ∈ (A ∪ B) ∩ C
⇔ [x ∈ (A ∪ B)] ∧ [x ∈ C] definition of intersection
⇔ [(x ∈ A) ∨ (x ∈ B)] ∧ [x ∈ C] definition of union
⇔ [(x ∈ A) ∧ (x ∈ C)] ∨ [(x ∈ B) ∧ (x ∈ C)] distributive law of “and”
over “or”
⇔ [x ∈ (A ∩ C)] ∨ [(x ∈ (B ∩ C)] definition of intersection
⇔ x ∈ [(A ∩ C) ∪ (B ∩ C)] definition of union
A B C A ∪ B (A ∩ C) (B ∩ C) (A ∪ B) ∩ C (A ∩ C) ∪ (B ∩ C)
1 1 1 1 1 1 1 1
1 1 0 1 0 0 0 0
1 0 1 1 1 0 1 1
0 1 1 1 0 1 1 1
1 0 0 1 0 0 0 0
0 1 0 1 0 0 0 0
0 0 1 0 0 0 0 0
0 0 0 0 0 0 0 0
Since the columns corresponding to (A∪B)∩C and (A∩C)∪(B ∩C) are identical,
the two sets are equal.
1. SET OPERATIONS 105
A B C A − B B − C (A − B) − C A − (B − C)
1 1 1 0 0 0 1
1 1 0 0 1 0 0
1 0 1 1 0 0 1
1 0 0 1 0 1 1
0 1 1 0 0 0 0
0 1 0 0 1 0 0
0 0 1 0 0 0 0
0 0 0 0 0 0 0
Notice the only 1 in the column for (A−B)−C is the fourth row. The entry in the
same row in the column for A−(B −C) is also a 1, so (A−B)−C ⊆ A−(B −C).
Exercise 1.11.1. Prove the identity A − B = A ∩ B using the method of Proof 2
in Example 1.11.1.
Exercise 1.11.2. Prove the identity A − B = A ∩ B using the method of Proof 3
in Example 1.11.1.
Exercise 1.11.3. Prove the identity (A ∪ B) − C = (A − C) ∪ (B − C) using the
method of Proof 1 in Example 1.11.1.
Exercise 1.11.4. Prove the identity (A ∪ B) − C = (A − C) ∪ (B − C) using the
method of Proof 2 in Example 1.11.1.
Exercise 1.11.5. Prove the identity (A ∪ B) − C = (A − C) ∪ (B − C) using the
method of Proof 3 in Example 1.11.1.
and
n
\
Ai = A1 ∩ A2 ∩ A3 ∩ · · · ∩ An ,
i=1
respectively.
Discussion
If you have a collection of more than two sets, you can define the intersection
and the union of the sets as above. (Since the operations are associative, it isn’t
necessary to clutter the picture with parentheses.) The notation is similar to the Σ
notation used for summations. The subscript is called an index and the collection of
sets is said to be indexed by the set of indices. In the example, the collection of sets is
{A1 , A2 , ..., An }, and the set of indices is the set {1, 2, ..., n}. There is no requirement
that sets with different indices be different. In fact, they could all be the same set.
This convention is very useful when each of the sets in the collection is naturally
described in terms of the index (usually a number) it has been assigned.
n
[
Ai = {x|∃i ∈ {1, 2, . . . , n} such that x ∈ Ai }
i=1
and
n
\
Ai = {x|∀i ∈ {1, 2, . . . , n}, x ∈ Ai }.
i=1
1. SET OPERATIONS 107
Discussion
n
\
• Ci = ∅ if n > 4.
i=0
[∞
• Ci = {−2, −1, 0, 1, 2, 3, . . . }
i=0
\∞
• Ci = ∅
i=0
Exercise 1.14.1. For each positive integer k, let Ak = {kn|n ∈ Z}. For example,
• A1 = {n|n ∈ Z} = Z
• A2 = {2n|n ∈ Z} = {..., −2, 0, 2, 4, 6, ...}
• A3 = {3n|n ∈ Z} = {..., −3, 0, 3, 6, 9, ...}
Find
10
\
1. Ak
k=1
\m
2. Ak , where m is an arbitrary positive integer.
k=1
Exercise 1.14.2. Use the definition for Ak in exercise 1.14.1 to answer the fol-
lowing questions.
∞
\
(1) Ai
i=1
[∞
(2) Ai
i=1
Order the elements of the universal set and then assign a bit number to each
subset A as follows. A bit is 1 if the element corresponding to the position of the bit
in the universal set is in A, and 0 otherwise.
Example 1.15.1. Suppose U = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, with the obvious order-
ing. Then
Discussion
There are many ways sets may be represented and stored in a computer. One
such method is presented here. Notice that this method depends not only on the
universal set, but on the order of the universal set as well. If we rearrange the order
of the universal set given in Example 1.15.1 to U = {10, 9, 8, 7, 6, 5, 4, 3, 2, 1}, then
the bit string corresponding to the subset {1, 2, 3, 4} would be 0000001111.
A = (0101010101)
= 1010101010
= {1, 3, 5, 7, 9}
A ∪ B = 0101010101 ∨ 1111000000
= 1111010101
= {1, 2, 3, 4, 6, 8, 10}
A ∩ B = 0101010101 ∧ 1111000000
= 0101000000
= {2, 4}
A ⊕ B = 0101010101 ⊕ 1111000000
= 1010010101
= {1, 3, 6, 8, 10}
(b) A ∪ B
(c) A ∩ B ∩ C
(d) B − C