Writing Mathematical Proofs Guide
Writing Mathematical Proofs Guide
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Writing our First Proof
Theorem: If n is an even integer,
then n2 is even.
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
10 2·5
8 2·4
0 2·0
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Let’s Try Some Examples!
22 = 4 =2·2
102 = 100 = 2 · 50
02 = 0 =2·0
(-8)2 = 64 = 2 · 32
n2 = =2·? What’s
What’s the
the
pattern?
pattern? How
How do
do
we
we predict
predict this?
this?
n2 = 2(2k2)
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Our First Proof! 😃
even
even integer.
integer. We
We need
need to
to
From this, we see that there is an integer
2 use
use this
this definition
definition to
to make
make
m (namely, 2k ) where n = 2m.2
this
this proof
proof rigorous.
rigorous.
Therefore, n2 is even. ■
Our First Proof! 😃
Our
Theorem: If n is anultimate
Our ultimate goal
goal isis to
even integer, to prove
thenprove that
n2 isthat
even.
n
Proof: Let n be an
2
isis even.
n2even This
This means
integer.
even. means that
that we
we
need
need toto find
find some
some mm such
such that
that
Since n is even, there is some integer k
2m. Here,
nn22==2m.
such that n = 2k. Here, we're
we're explicitly
explicitly
showing
showing how
how we
we can
can do
do that.
that.
This means that n2 = (2k)2 = 4k2 = 2(2k2).
From this, we see that there is an integer
m (namely, 2k2) where n2 = 2m.
Therefore, n2 is even. ■
Our First Proof! 😃
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
11 2·5+1
7 2·3+1
1 2·0+1
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Let’s Try Some Examples!
1+1 = 2 = 2·1
137 + 103 = 240 = 2 · 120
-5 + 5 = 0 = 2·0
m+n = 2·?
What’s
What’s the
the
pattern?
pattern? How
How do
do
we
we predict
predict this?
this?
2k+1 2r+1
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: For any integers m and n, if m and n are odd, then
m + n is even.
Proof: Consider any arbitrary integers m and n where m and n are
odd. Since m is odd, we know that there is an integer k where
m = 2k + 1. (1)
Similarly, because n is odd there must be some integer r such
that
n = 2r + 1. (2)
By adding equations (1) and (2) we learn that
m + n = 2k + 1 + 2r + 1
= 2k + 2r + 2
= 2(k + r + 1). (3)
Equation (3) tells us that there is an integer s (namely, k + r + 1)
such that m + n = 2s. Therefore, we see that m + n is even, as
required. ■
Theorem: For any integers m and n, if m and n are odd, then
m + n is even.
Proof: Consider any arbitrary integers m and n where m and n are
odd. Since m is odd, we know that there is an integer k where
m = 2k + 1. (1)
This
This isis called
called making
making arbitrary
arbitrary choices.
choices.
Similarly, because n is odd there must be some integer r such
Rather
Rather than
than specifying
specifying what m and
what m and nn are,
are,
that
we’re
we’re signaling
signaling to the reader that they
n =to2r the
+ 1.reader that they (2)
could,
could, inin principle,
principle, supply
supply any
any choices
choices of
of mm
By adding equations (1) and (2) we learn that
and nn that they’d like.
m + n = 2k + 1 + 2rlike.
and that they’d +1
By
By picking m and
picking m n arbitrarily,
= n2k
and + 2r + 2 anything
arbitrarily, anything wewe
prove
prove about m and
about m and
= nn+
2(k will
r +generalize
will generalize
1). to
to all
(3)all
Equation (3) possible
possible
tells choices
choices
us that therewe
iscould
we could
an have
have smade.
integer made.
(namely, k + r + 1)
such that m + n = 2s. Therefore, we see that m + n is even, as
required. ■
Theorem: For any integers m and n, if m and n are odd, then
m + n is even.
Proof: Consider any arbitrary integers m and n where m and n are
odd. Since m is odd, we know that there is an integer k where
To
To prove
provemaa =
statement
2k + 1. of
statement of the
the form(1)
form
Similarly, because n is odd there must be some integer r such
that “If
“IfP,
P,then
thenQ”
Q”
n = 2r + 1. (2)
Assume
Assume that PP isis true, then show
By adding equations (1) that
and (2) wetrue,
learnthen
that show
that
that Q must be true as well.
m +Qn must
= 2k be
+ 1true
+ 2r as
+ 1well.
= 2k + 2r + 2
= 2(k + r + 1). (3)
Equation (3) tells us that there is an integer s (namely, k + r + 1)
such that m + n = 2s. Therefore, we see that m + n is even, as
required. ■
Numbering
Numbering these
these equalities
equalities lets
lets us
us
Theorem: For any integers
refer m and n,on,if m and n are odd, then
refer back
back to
to them
them later
later on,
m + n is even.
making
making the
the flow
flow of
of the
the proof
proof aa bit
bit
Proof: Consider any arbitrary
easier integers m and n where m and n are
easier to
to understand.
understand.
odd. Since m is odd, we know that there is an integer k where
m = 2k + 1. (1)
Similarly, because n is odd there must be some integer r such
that
n = 2r + 1. (2)
By adding equations (1) and (2) we learn that
m + n = 2k + 1 + 2r + 1
= 2k + 2r + 2
= 2(k + r + 1). (3)
Equation (3) tells us that there is an integer s (namely, k + r + 1)
such that m + n = 2s. Therefore, we see that m + n is even, as
required. ■
Theorem: For any integers m and n, if m and n are odd, then
m + n is even.
Proof: Consider any arbitrary integers m and n where m and n are
odd. Since m is odd, we know that there is an integer k where
m = 2k + 1. (1)
Similarly, because n is odd there must be some integer r such
that
n = 2r + 1. (2)
By
Thisadding equations
is a complete (1) andProofs
sentence! (2) weare
learn that
This is a complete sentence! Proofs are
expected
expected to to be
be written inin+
writtenm complete
n = 2k sentences,
complete + 1 + 2r + 1
sentences,
so
so you’ll
you’ll often
often use
use punctuation
punctuation at
at the
the end
end of
of
= 2k + 2r + 2
formulas.
formulas. = 2(k + r + 1). (3)
We
We recommend
Equation
recommend (3)using
tells the
using us “mugga
thethat mugga”
there
“mugga is an test
mugga” integer
test s (namely, k + r + 1)
–such
– ifif you read
that
you m+
read aan
proof
= 2s.and
proof replace
replace all
Therefore,
and all the
we see that m + n is even, as
the
required. ■notation with “mugga mugga,”
mathematical
mathematical notation with “mugga mugga,”
what
what comes
comes back
back should
should be
be aa valid
valid sentence.
sentence.
Theorem: For any integers m and n, if m and n are odd, then
m + n is even.
Proof: Consider any arbitrary integers m and n where m and n are
odd. Since m is odd, we know that there is an integer k where
m = 2k + 1. (1)
Similarly, because n is odd there must be some integer r such
that
n = 2r + 1. (2)
By adding equations (1) and (2) we learn that
m + n = 2k + 1 + 2r + 1
= 2k + 2r + 2
= 2(k + r + 1). (3)
Equation (3) tells us that there is an integer s (namely, k + r + 1)
such that m + n = 2s. Therefore, we see that m + n is even, as
required. ■
Some Little Exercises
●
Here’s a list of other theorems that are true about odd
and even numbers:
●
Theorem: The sum and difference of any two even numbers is
even.
●
Theorem: The sum and difference of an odd number and an
even number is odd.
●
Theorem: The product of any integer and an even number is
even.
●
Theorem: The product of any two odd numbers is odd.
●
Going forward, we’ll just take these results for granted.
Feel free to use them in the problem sets.
●
If you’d like to practice the techniques from today, try
your hand at proving these results!
Universal and Existential Statements
Theorem: For any odd integer n,
there exist integers r and s where r2 – s2 = n.
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: For any odd integer n,
there exist integers r and s where r2 – s2 = n.
This
This result
result isis true
true for
for every
every possible
possible
choice
choice of
of odd
odd integer
integer n.
n. It’ll
It’ll work
work
for
for nn == 1,1, nn == 137,
137, nn == 103,
103, etc.
etc.
Theorem: For any odd integer n,
there exist integers r and s where r2 – s2 = n.
We
We aren’t
aren’t saying
saying this
this isis true
true for
for
every
every choice
choice of
of rr and
and s. s. Rather,
Rather,
we’re
we’re saying that somewhere
saying that somewhere out out
there
there are
are choices
choices of
of rr and
and ss where
where
this
this works.
works.
Universal vs. Existential Statements
●
A universal statement is a statement of
the form
For all x, [some-property] holds for x.
●
We've seen how to prove these statements.
●
An existential statement is a statement of
the form
There is some x where [some-property] holds for x.
●
How do you prove an existential statement?
Proving an Existential Statement
●
Over the course of the quarter, we will
see several different ways to prove an
existential statement of the form
There is an x where [some-property] holds for x.
●
Simplest approach: Search far and
wide, find an x that has the right
property, then show why your choice is
correct.
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Let’s Try Some Examples!
1 = ___
1 2 – ___
02
3 = ___
2 2 – ___
12
5 = ___
3 2 – ___
22
We’ve
We’ve got
got aa
7 = ___
4 2 – ___
32 pattern
pattern –– but
but
why
why does
does this
this
9 = ___
5 2 – ___
42 work?
work?
k +1
k
(k+1)2 – k2 = 2k+1
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: For any odd integer n, there exist integers
r and s where r2 – s2 = n.
Proof: Pick any odd integer n. Since n is odd, we
know there is some integer k where n = 2k + 1.
Now, let r = k+1 and s = k. Then we see that
r2 – s2 = (k+1)2 – k2
= k2 + 2k + 1 – k2
= 2k + 1
= n.
This means that r2 – s2 = n, which is what we
needed to show. ■
Theorem: For any odd integer n, there exist integers
r and s where r2 – s2 = n.
Proof: Pick any odd integer n. Since n is odd, we
know there is some integer k where n = 2k + 1.
We
We make
make an
an arbitrary
arbitrary choice.
choice. Rather
Rather than
than
Now, let r = k+1 and s = k. Then we see that
specifying
specifying what
what nn is,
is, we’re
we’re signaling
signaling to
to the
the
r
reader 2 – s2 = (k+1) 2 – k2
reader that they could, inin principle,
that they could, principle, supply
supply
any
any choice
= knn2 that
choice + 2kthey’d
that + 1 –like.
they’d k2
like.
= 2k + 1
= n.
This means that r2 – s2 = n, which is what we
needed to show. ■
Theorem: For any odd integer n, there exist integers
r and s where r2 – s2 = n.
Proof: Pick any odd integer n. Since n is odd, we
know there is some integer k where n = 2k + 1.
Now, let r = k+1 and s = k. Then we see that
r2 – s2 = (k+1)2 – k2
We’re
We’re trying
trying to
to prove
prove an
an
=
existential
k2 + 2k + 1 – k2
existential statement.
statement. TheThe easiest
easiest
way
way to
=do 2k
to do
+ 1 to just
that
that isis to just give
give
concrete
concrete=choices
n.
choices ofof the
the objects
objects
being
being sought
sought out.
out.
This means that r – s = n, which
2 2 is what we
needed to show. ■
Time-Out for Announcements!
CURIS Poster Session
●
There’s a CURIS poster session showcasing work from
the summer going on from 3PM – 5PM Friday on the
Packard lawn. Feel free to stop on by!
●
Interested in seeing what research projects are open
right now? Visit https://curis.stanford.edu.
●
Have questions about research or how CURIS works?
●
Email PhD students and CURIS mentors Griffin Dietz and
Kexin Rong at curis-mentors@cs.stanford.edu.
●
Email CURIS admin Nan Aoki at nanaoki@cs.stanford.edu.
●
Email Phil Levis, the professor who runs CURIS, at
pal@cs.stanford.edu.
Piazza
●
We have a Piazza site for CS103.
●
Sign in to www.piazza.com and search
for the course CS103 to sign in.
●
Feel free to ask us questions!
●
Use the site to find a partner for the
problem sets!
Qt Creator Help Session
●
The lovely CS106B/X folks have invited all y’all
to join them for a Qt Creator Help Session this
evening if you’re having trouble getting Qt
Creator up and running on your system.
●
Runs 7:30PM – 9:30PM in the Tresidder first
floor lounge.
●
SCPD students – please reach out to us if you
need help setting things up. We’ll do our best
to help out.
Back to CS103!
Proofs on Sets
Theorem: If A, B, and C are sets, then for any
x ∈ (A ∩ B) ∪ C, we have x ∈ (A ∪ C) ∩ (B ∪ C).
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: If A, B, and C are sets, then for any
x ∈ (A ∩ B) ∪ C, we have x ∈ (A ∪ C) ∩ (B ∪ C).
This
Thisis theelement-of
isthe element-ofrelation
relation∈.
∈.ItIt
means
meansthatthatthis
thisobject
objectxxis
isone
oneof
ofthe
the
items
itemsinside
insidethese
thesesets.
sets.
Theorem: If A, B, and C are sets, then for any
x ∈ (A ∩ B) ∪ C, we have x ∈ (A ∪ C) ∩ (B ∪ C).
What
Whatare
are
these,
these,again?
again?
Set Combinations
●
In our last lecture, we saw four ways of
combining sets together.
S∪T
Definition:
Definition: The
Theset
setSS∪∪TTis isthe
theset
setwhere,
where,for
forany
anyx:
x:
xx∈∈SS∪∪TT when
when xx∈∈SSor orxx∈∈TT(or
(orboth)
both)
If
Ifyou
youknow
knowthat
thatxx∈∈SS∪ ∪T: T:
You
Youcan
canconclude
concludethat
thatxx∈∈SSor orthat
thatxx∈∈TT(or
(orboth).
both).
To
Toprove
provethat
thatxx∈∈SS∪ ∪T:T:
Prove
Proveeither
eitherthat
thatxx∈∈SSororthat
thatxx∈∈TT(or
(orboth).
both).
Set Intersection
S∩T
Definition:
Definition: The
Theset
setSS∩∩TTis
isthe
theset
setwhere,
where,for
forany
anyx:x:
xx∈∈SS∩ ∩TT when
when xx∈∈SSand andxx∈∈TT
If
Ifyou
youknow
knowthat
thatxx∈∈SS∩ ∩T:T:
You
Youcan
canconclude
concludeboth
boththat
thatxx∈∈SSand
andthat
thatxx∈∈T.
T.
To
Toprove
provethat
thatxx∈∈SS∩ ∩T:
T:
Prove
Proveboth
boththat
thatxx∈∈SSand
andthat
thatxx∈∈T.
T.
There are similar rules for
S – T and S Δ T.
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Let’s Try Some Examples!
A = {1, 2, 3}
B = {2, 3, 4}
C = {3, 4, 5}
x = 1?
x = 2?
x = 3?
Goal:
Goal: pick
pick …and
…and explain
explain why
why
elements
elements inside
inside (A ∪ C) they
they also
also have
(Btoto
have ∪be C)
be
of
of this
this shape…
shape… inin this
this shape.
shape.
C C
Amazing diagrams by Amy Liu.
(A ∪ C) (B ∪ C)
C C
Amazing diagrams by Amy Liu.
A B A B
First,
First, suppose
suppose we
we
pick
pick something
something in
in
(A ∪ C)set C. (B ∪ C)
set C.
C x C
Amazing diagrams by Amy Liu.
A B A B
(A ∪ C)
C x C
Amazing diagrams by Amy Liu.
A B A B
(B ∪ C)
C x C
Amazing diagrams by Amy Liu.
Otherwise,
Otherwise, imagine
imagine
picking
picking something
something
from
from AA∩∩B.
B.
(A ∪ C) (B ∪ C)
C C
Amazing diagrams by Amy Liu.
(A ∪ C)
C C
Amazing diagrams by Amy Liu.
(B ∪ C)
C C
Amazing diagrams by Amy Liu.
C C
Amazing diagrams by Amy Liu.
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we have x ∈ (A ∪ C) ∩ (B ∪ C).
Proof: Consider arbitrary sets A, B, and C, then choose any
x ∈ (A ∩ B) ∪ C. We will prove x ∈ (A ∪ C) ∩ (B ∪ C).
Since x ∈ (A ∩ B) ∪ C, we know that x ∈ A ∩ B or that x ∈ C.
We consider each case separately.
Case 1: x ∈ C. This in turn means that x ∈ A ∪ C and
that x ∈ B ∪ C.
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
x ∈ A and that x ∈ B. Therefore, we know that
x ∈ A ∪ C and that x ∈ B ∪ C.
In either case, we learn that x ∈ A ∪ C and x ∈ B ∪ C. This
establishes that x ∈ (A ∪ C) ∩ (B ∪ C), as required. ■
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we have x ∈ (A ∪ C) ∩ (B ∪ C).
Proof: Consider arbitrary sets A, B, and C, then choose any
x ∈ (A ∩ B) ∪ C. We will prove x ∈ (A ∪ C) ∩ (B ∪ C).
Since x ∈ (A ∩ B) ∪ C, we know that x ∈ A ∩ B or that x ∈ C.
These arbitrary choices.
We consider eachare
These are
casearbitrary choices. Rather
separately. Rather than
than
specifying
specifying what
what A,
A, B, C,and
B, C, and xx are,
are, we’re
Case 1: x ∈ C. This in turn means that x ∈we’re A∪C and
signaling
signaling to
to the
the reader
reader that
that they
they could,
could, inin
that x ∈ B ∪ C.
principle,
principle, supply
supply any
any choices
choices ofof A,
A, B,
B, C,
C,
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
and x that they’d like.
and x that they’d like.
x ∈ A and that x ∈ B. Therefore, we know that
x ∈ A ∪ C and that x ∈ B ∪ C.
In either case, we learn that x ∈ A ∪ C and x ∈ B ∪ C. This
establishes that x ∈ (A ∪ C) ∩ (B ∪ C), as required. ■
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we have x ∈ (A ∪ C) ∩ (B ∪ C).
Proof: Consider arbitrary sets A, B, and C, then choose any
x ∈ (A ∩ B) ∪ C. We will prove x ∈ (A ∪ C) ∩ (B ∪ C).
Since x ∈ (A ∩ B) ∪ C, we know that x ∈ A ∩ B or that x ∈ C.
We consider each case separately.
Case 1: x ∈ C. This in turn means that x ∈ A ∪ C and
that x ∈ B ∪ C.
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
x ∈ A and that x ∈ B. Therefore, we know that
This
This isis called
called aa proof
proof by
by cases
cases
x ∈ A ∪ C and that x ∈ B ∪ C.
(alternatively, aa proof
(alternatively, proof by
by exhaustion)
exhaustion)
In either case, we learn thatworks
and x∈A by∪showing
C andthat
x ∈the
B ∪theorem
C. This
and works by showing that the theorem
establishes that x ∈ (A ∪ C)
is ∩ (Bregardless
true ∪ C), as of
required. ■
what specific
is true regardless of what specific
outcome
outcome arises.
arises.
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we have x ∈ (A ∪ C) ∩ (B ∪ C).
After
Proof: Consider arbitrary sets A, splitting
After B, and C,
splitting into cases,
then
into it's
it's aa any
choose
cases,
good
good idea
x ∈ (A ∩ B) ∪ C. We will prove x ∈to
idea (Asummarize
to ∪ C) ∩ (B
summarize what∪ you
what C).
you
just
just did
did so
so that
that the
the reader
reader knows
knows
Since x ∈ (A ∩ B) ∪ C, we know
what that
to x ∈away
take A ∩from
B orit.
that x ∈ C.
what to take away from it.
We consider each case separately.
Case 1: x ∈ C. This in turn means that x ∈ A ∪ C and
that x ∈ B ∪ C.
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
x ∈ A and that x ∈ B. Therefore, we know that
x ∈ A ∪ C and that x ∈ B ∪ C.
In either case, we learn that x ∈ A ∪ C and x ∈ B ∪ C. This
establishes that x ∈ (A ∪ C) ∩ (B ∪ C), as required. ■
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we have x ∈ (A ∪ C) ∩ (B ∪ C).
Proof: Consider arbitrary sets A, B, and C, then choose any
x ∈ (A ∩ B) ∪ C. We will prove x ∈ (A ∪ C) ∩ (B ∪ C).
Since x ∈ (A ∩ B) ∪ C, we know that x ∈ A ∩ B or that x ∈ C.
We consider each case separately.
Case 1: x ∈ C. This in turn means that x ∈ A ∪ C and
that x ∈ B ∪ C.
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
x ∈ A and that x ∈ B. Therefore, we know that
x ∈ A ∪ C and that x ∈ B ∪ C.
If
Ifyou
In either you know
case,know that xx∈∈SxS∪
thatthat
we learn ∈∪AT:
T:∪ C and x ∈ B ∪ C. This
You
establishes can
canxconclude
Youthat conclude that
∈ (A ∪ C)thatxx∈∈
∩ (B ∪SS or that
oras
C), thatxx∈∈TT(or
required. ■both).
(or both).
If
Ifyou
youknow
knowthatthatxx∈∈SS∩∩T: T:
You
Youcan
canconclude
concludeboth
boththat
thatxx∈∈SSand
andthat
thatxx∈∈T.
T.
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we
To have x ∈that
prove (A ∪x C)
∈ ∩∪
S (BT:
∪ C).
To prove that x ∈ S ∪ T:
Proof:Prove either
Consider
Prove that
thatxx∈sets
arbitrary
either ∈SSorA,that
or xx∈∈C,
B, and
that TT(or
(orboth).
then choose any
both).
xTo
∈ (A ∩ B)that
prove ∪ C. xWe
∈ will
S ∩ prove
T: x ∈ (A ∪ C) ∩ (B ∪ C).
To prove that x ∈ S ∩ T:
Prove
SinceProveboth
x ∈ (A that
∩ B)
both xx∈∈
∪ C,
that weSSand
andthat
know xx∈
that
that T.
x∈∈T.A ∩ B or that x ∈ C.
We consider each case separately.
Case 1: x ∈ C. This in turn means that x ∈ A ∪ C and
that x ∈ B ∪ C.
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
x ∈ A and that x ∈ B. Therefore, we know that
x ∈ A ∪ C and that x ∈ B ∪ C.
In either case, we learn that x ∈ A ∪ C and x ∈ B ∪ C. This
establishes that x ∈ (A ∪ C) ∩ (B ∪ C), as required. ■
Theorem: If A, B, and C are sets, then for any x ∈ (A ∩ B) ∪ C,
we have x ∈ (A ∪ C) ∩ (B ∪ C).
Proof: Consider arbitrary sets A, B, and C, then choose any
x ∈ (A ∩ B) ∪ C. We will prove x ∈ (A ∪ C) ∩ (B ∪ C).
Since x ∈ (A ∩ B) ∪ C, we know that x ∈ A ∩ B or that x ∈ C.
We consider each case separately.
Case 1: x ∈ C. This in turn means that x ∈ A ∪ C and
that x ∈ B ∪ C.
Case 2: x ∈ A ∩ B. From x ∈ A ∩ B, we learn that
x ∈ A and that x ∈ B. Therefore, we know that
x ∈ A ∪ C and that x ∈ B ∪ C.
In either case, we learn that x ∈ A ∪ C and x ∈ B ∪ C. This
establishes that x ∈ (A ∪ C) ∩ (B ∪ C), as required. ■
To Recap
ns
In
o
tu
iti
iti
fin
on
De
s
Conventions
SS∪∪TTisisthe
theset
setwhere,
where,for
forany
anyx:
x:
xx∈∈SS∪∪TT when
when xx∈∈SSororxx∈∈TT(or
(orboth).
both).
SS∩∩TTisisthe
theset
setwhere,
where,for
forany
anyx:
x:
xx∈∈SS∩∩TT when
when both
bothxx∈∈SSand
andxx∈∈T.T.
SS⊆⊆TT when
when for
forany
anyxx∈∈S,
S,we
wehave
havexx∈∈T.
T.
SS==TT when
when SS⊆⊆TTand
andTT⊆⊆S.
S.
ry S o m e E x a m p le s !
Let’s T
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Set Theory Review
●
Recall from last time that we write x ∈ S
if x is an element of set S and x ∉ S if x is
not an element of set S.
●
If S and T are sets, we say that S is a
subset of T (denoted S ⊆ T) if the
following statement is true:
For every x, if x ∈ S, then x ∈ T.
●
What does this mean for proofs?
Subsets
S T
S⊆T
Definition:
Definition:IfIfSSand
andTTare
aresets,
sets,then
thenSS⊆⊆TTwhen
when
for
forevery
everyxx∈∈S,S,we
wehave
havexx∈∈T.T.
If
Ifyou
youknow
knowthat
thatSS⊆ ⊆T:
T:
IfIfyou
youhave
haveananxx∈∈S,
S,you
youcan
canconclude
concludexx∈∈T.T.
To
Toprove
provethat
thatSS⊆ ⊆T:T:
Pick
Pickananarbitrary
arbitraryxx∈∈S,S,then
thenprove
provexx∈∈T.
T.
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Let’s Draw Some Pictures!
A∩B
A B A B
x
Goal: …and
…and explain
explain why
why they
they also
Goal: pick
pick elements
elements also
inside have
have toCbe
be inin this
this shape.
inside of
of this
this shape…
C
shape… to shape.
Amazing diagrams by Amy Liu.
C C
Amazing diagrams by Amy Liu.
x
C C
Amazing diagrams by Amy Liu.
•What
•What happens
happens if if
we
we pick
pick an
an xx that
that
isn’t
isn’t in
in C?
C?
C C
Amazing diagrams by Amy Liu.
That
That meansmeans that
that xx
isis in
in this
this region
region
up
up here.
here.
C C
Amazing diagrams by Amy Liu.
C C
Amazing diagrams by Amy Liu.
C C
Amazing diagrams by Amy Liu.
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) ⊆ (A ∩ B) ∪ C.
Proof: Pick any sets A, B, and C. Then, choose any element
x ∈ (A ∪ C) ∩ (B ∪ C). We will prove that x ∈ (A ∩ B) ∪ C.
Since x ∈ (A ∪ C) ∩ (B ∪ C), we know that x ∈ A ∪ C and
that x ∈ B ∪ C. We now consider two cases.
Case 1: x ∈ C. This means x ∈ (A ∩ B) ∪ C as well.
Case 2: x ∉ C. Because x ∈ A ∪ C, we know that x ∈ A
or that x ∈ C. However, since we have x ∉ C, we’re
left with x ∈ A. By similar reasoning, from x ∈ B ∪ C
we learn that x ∈ B.
Collectively, we’ve shown that x ∈ A and that x ∈ B, so
we see that x ∈ A ∩ B. This means x ∈ (A ∩ B) ∪ C.
In either case, we see that x ∈ (A ∩ B) ∪ C, which is what
we needed to show. ■
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) ⊆ (A ∩ B) ∪ C.
Proof: Pick any sets A, B, and C. Then, choose any element
x ∈ (A ∪ C) ∩ (B ∪ C). We will prove that x ∈ (A ∩ B) ∪ C.
Since x ∈ (A ∪ C) ∩ (B ∪ C), we know that x ∈ A ∪ C and
that x ∈ B ∪ C. We now consider two cases.
These are arbitrary
arbitrary choices. Rather than
These
Case 1: x ∈ C.are
This means xchoices. Rather
∈ (A ∩ B) ∪ C than
as well.
specifying
specifying what
what A,
A, B,
B, and
and CC are,
are, we’re
we’re
Case 2: x ∉ C. Because x ∈ A ∪ C, we know that
x∈A
signaling
signaling to
to the
the reader
reader that
that they
they could,
could, inin
or that x ∈ C. However, since we have x ∉ C, we’re
principle,
x ∈ A.supply
principle,
left with supply any
any choices
By similar choices of
of A,
reasoning, B, and
B,
A, from and
x∈B∪C
we learn that x ∈ that
CCB.that they’d
they’d like.
like.
Collectively, we’ve shown that x ∈ A and that x ∈ B, so
we see that x ∈ A ∩ B. This means x ∈ (A ∩ B) ∪ C.
In either case, we see that x ∈ (A ∩ B) ∪ C, which is what
we needed to show. ■
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) ⊆ (A ∩ B) ∪ C.
Proof: Pick any sets A, B, and C. Then, choose any element
x ∈ (A ∪ C) ∩ (B ∪ C). We will prove that x ∈ (A ∩ B) ∪ C.
Since x ∈To(Aprove
∪ C) ∩ (B ∪S C),
that ⊆ we know that x ∈ A ∪ C and
T:
that x ∈ BTo∪ prove
C.
Pick We that consider
now S ⊆ T: two cases.
Pickan
anarbitrary
arbitraryxx∈∈S,S,then
thenprove
provexx∈∈T.
T.
Case 1: x ∈ C. This means x ∈ (A ∩ B) ∪ C as well.
Case 2: Notice
x ∉ C. that
Notice that the
Because statement
the x ∈ A ∪ C, of
statement of the
we the theorem
know that x ∈ A
theorem
or that x ∈ C. include
doesn’t However,anysince we have
variable namedx ∉x.C, We
we’re
doesn’t include any variable named x. We
left with x ∈ A. By similar reasoning, from x ∈ B ∪ C
introduced
introduced this variable because that’s what
we learn that x ∈this
B. variable because that’s what
the definition says to do.
the definition says
Collectively, we’ve shown that x ∈to do. that x ∈ B, so
A and
we see that x ∈ A ∩ B.inThis means x ∈ (A ∩ B) ∪call
C.
This is common proofwriting. Always
This is common in proofwriting. Always call
In either case, we see that x ∈ (A ∩ B) ∪ C, which is what
back
back to
to the
the definition
definition to
to make
make sure
sure you’re
you’re
we needed to show. ■
proving
proving the
the right
right thing!
thing!
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) ⊆ (A ∩ B) ∪ C.
Proof: Pick any sets A,
AsB,before,
and C. Then,
it’s choose
good to any element
summarize
As We
x ∈ (A ∪ C) ∩ (B ∪ C). before, it’s good
will prove that xto∈ summarize
(A ∩ B) ∪ C.
what
what we
we established
established when
when splitting
splitting
Since x ∈ (A ∪ C) ∩ (B ∪ C), weinto
know that x ∈ A ∪ C and
cases.
into cases.
that x ∈ B ∪ C. We now consider two cases.
Case 1: x ∈ C. This means x ∈ (A ∩ B) ∪ C as well.
Case 2: x ∉ C. Because x ∈ A ∪ C, we know that x ∈ A
or that x ∈ C. However, since we have x ∉ C, we’re
left with x ∈ A. By similar reasoning, from x ∈ B ∪ C
we learn that x ∈ B.
Collectively, we’ve shown that x ∈ A and that x ∈ B, so
we see that x ∈ A ∩ B. This means x ∈ (A ∩ B) ∪ C.
In either case, we see that x ∈ (A ∩ B) ∪ C, which is what
we needed to show. ■
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) ⊆ (A ∩ B) ∪ C.
Proof: Pick any sets A, B, and C. Then, choose any element
x ∈ (A ∪ C) ∩ (B ∪ C). We will prove that x ∈ (A ∩ B) ∪ C.
Since x ∈ (A ∪ C) ∩ (B ∪ C), we know that x ∈ A ∪ C and
that x ∈ B ∪ C. We now consider two cases.
Case 1: x ∈ C. This means x ∈ (A ∩ B) ∪ C as well.
Case 2: x ∉ C. Because x ∈ A ∪ C, we know that x ∈ A
or that x ∈ C. However, since we have x ∉ C, we’re
left with x ∈ A. By similar reasoning, from x ∈ B ∪ C
we learn that x ∈ B.
Collectively, we’ve shown that x ∈ A and that x ∈ B, so
we see that x ∈ A ∩ B. This means x ∈ (A ∩ B) ∪ C.
In either case, we see that x ∈ (A ∩ B) ∪ C, which is what
we needed to show. ■
Theorem: If A, B, and C are sets,
then (A ∪ C) ∩ (B ∪ C) = (A ∩ B) ∪ C.
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Set Equality
S T
S=T
Definition:
Definition:IfIfSSand
andTTare
aresets,
sets,then
thenSS=
=TTifif
SS⊆⊆TT andand TT⊆ ⊆S.S.
If
Ifyou
youknow
knowthat
thatSS= =T:
T:
IfIfyou
youhave
haveananxx∈∈S,
S,you
youcan
canconclude
concludexx∈∈T.T.
IfIfyou
youhave
haveananxx∈∈T,
T,you
youcan
canconclude
concludexx∈∈S.S.
To
Toprove
provethat
thatSS= =T:T:
Prove
Provethat
thatSS⊆⊆TTand
andTT⊆⊆S.S.
ns
In
What terms are What does this
used in this proof? theorem mean?
tu
iti
What do they Why, intuitively,
iti
formally mean? should it be true?
fin
on
De
s
Conventions
What is the standard
format for writing a proof?
What are the techniques
for doing so?
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) = (A ∩ B) ∪ C.
Proof: Fix any sets A, B, and C. We need to show that
(A ∪ C) ∩ (B ∪ C) ⊆ (A ∩ B) ∪ C (1)
and that
(A ∩ B) ∪ C ⊆ (A ∪ C) ∩ (B ∪ C). (2)
We’ve already proved that (1) holds, so we just need to
show (2). To do so, pick any x ∈ (A ∩ B) ∪ C. We need to
prove that x ∈ (A ∪ C) ∩ (B ∪ C). But this is something we
already know – we proved this earlier.
Since both (1) and (2) hold, we know that each of these two
sets are subsets of one another, and therefore that the sets
are equal. ■
Theorem: If A, B, and C are sets, then
(A ∪ C) ∩ (B ∪ C) = (AIt∩isB)common
∪ C.
It is common forfor proofs
proofs in
in math
math
Proof: Fix any sets A, B, and
to
to build
C. Weon
build one
need
on toanother.
one show that
another. That’s
That’s
how
(A ∪ C) ∩ (B ∪ C)how⊆we
we make progress
(A ∩
make B) ∪ C and
progress and make
(1)
make
and that new
new discoveries!
discoveries!
(A ∩ B) ∪ C ⊆ (A ∪ C) ∩ (B ∪ C). (2)
We’ve already proved that (1) holds, so we just need to
show (2). To do so, pick any x ∈ (A ∩ B) ∪ C. We need to
prove that x ∈ (A ∪ C) ∩ (B ∪ C). But this is something we
already know – we proved this earlier.
Since both (1) and (2) hold, we know that each of these two
sets are subsets of one another, and therefore that the sets
are equal. ■