Methods of Proof

Overview
• Methods of mathematical argument (i.e.,
proof methods) can be formalized in terms
of rules of logical inference.
• Mathematical proofs can themselves be
represented formally as discrete structures.
• We will review both correct & fallacious
inference rules, & several proof methods.
Methods of Proof
Rosen 5th ed., §§1.5
§§1.5
1
Proof Terminology
2
More Proof Terminology
• Lemma - A minor theorem used as a steppingstone to proving a major theorem.
• Corollary - A minor theorem proved as an easy
consequence of a major theorem.
• Conjecture (猜想) - A statement whose truth
value has not been proven. (but may be widely
believed to be true, regardless.)
• Theory (理論) - The set of all theorems that can
be proven from a given set of axioms.
• Theorem (定理)
– A statement that can be shown to be true.
• Proof (證明)
– A sequence of statements that
demonstrates a theorem is true
• Axioms (公理) and postulates (公設)
/pas/
– Underlying assumptions about
mathematical structures
3
Inference Rules - General
Form
Inference Rules &
Implications
• Inference Rule (推論規則) –
– Pattern establishing that if we know that a set
of antecedent statements of certain forms are
all true, then a certain related consequent
statement is true.
推論規則是說…
• antecedent 1
antecedent 2 …
∴ consequent
前提 1
前提 2
結論
4
當前題1, 前題2, …
皆為true時, 結論也
必為true
“∴” means “therefore”
• Each logical inference rule corresponds to
an implication that is a tautology.
• antecedent 1
Inference rule
antecedent 2 …
∴ consequent
• Corresponding tautology:
((ante. 1) ∧ (ante. 2) ∧ …) → consequent
A tautology
5
6
1
A Tautology?! 什麼意思?
Some Inference Rules
•意思是說不管 ante. 1, ante. 2, …的真值組
合為何,((ante. 1) ∧ (ante. 2) ∧ …) →
consequent 的真值永遠為true.
ante. 1 ante. 2
F
T
:
T
… ante. n
((ante. 1) ∧ (ante. 2) ∧ …) → consequent
F … F
F … F
:
:
…
T
T
All true
T
T
:
T
p
∴ p∨q
• p∧q
∴p
•
p
q
∴ p∧q
•
當任一前題為false時,
此implication自然為true
當全部前題為true時,
結論必須為true才能
使此implication為true
Rule of Addition
(p → p ∨ q)
Rule of Simplification
(p ∧ q → p)
Rule of Conjunction
(p ∧ q → p ∧ q)
7
8
Modus Ponens & Tollens
p
p→q
∴q
• ¬q
p→q
∴¬p
•
Syllogism Inference Rules
Rule of modus ponens
“the mode of
(a.k.a. law of detachment) affirming”
Rule of modus tollens
p→q
q→r
∴p→r
• p∨q
¬p
∴q
•
Rule of hypothetical
syllogism
Rule of disjunctive
syllogism
(p ∨ q) ∧ ¬p → q
“the mode of denying”
Aristotle
(ca. 384-322 B.C.)
9
Formal Proofs
Premises
p1, p2,…,pn
Inference
rule
Consequent
2nd step
:
Premises +
Consequents
Inference
rule
Consequent
last step
Premises +
Consequents
Inference
rule
Conclusion
1st step
10
Valid Arguments
• An argument form (proof) is valid if
– whenever all the hypotheses are true, the
conclusion is also true.
• A valid argument can lead to an incorrect
conclusion if one or more false
propositions are used within the argument
• A proof demonstrates that if the premises are
true, then the conclusion is true. (但前提不見得是對的)
11
12
2
Formal Proof Example
Proof Example cont.
• Suppose we have the following premises:
“It is not sunny and it is cold.”
划獨木舟
“We will swim only if it is sunny.”
“If we do not swim, then we will canoe.” /kə’nu/
“If we canoe, then we will be home early.”
• Given these premises, prove the theorem
“We will be home early” using inference rules.
• Let us adopt the following abbreviations:
– sunny = “It is sunny”; cold = “It is cold”;
swim = “We will swim”; canoe = “We will
canoe”; early = “We will be home early”.
• Then, the premises can be written as:
(1) ¬sunny ∧ cold (2) swim → sunny
(3) ¬swim → canoe (4) canoe → early
13
Proof Example cont.
14
Inference Rules for Quantifiers
Proved by
Premise #1.
Simplification of 1.
Premise #2.
Modus tollens on 2,3.
Premise #3.
Modus ponens on 4,5.
Premise #4.
Modus ponens on 6,7.
Step
1. ¬sunny ∧ cold
2. ¬sunny
3. swim→sunny
4. ¬swim
5. ¬swim→canoe
6. canoe
7. canoe→early
8. early
• ∀x P(x)
∴P(o)
• P(g)
∴∀x P(x)
• ∃x P(x)
∴P(c)
• P(o)
∴∃x P(x)
(substitute any object o)
(for g a general element of u.d.)
(substitute a new constant c)
(substitute any extant object o)
15
16
Proof Methods for
Implications
Common Fallacies (謬論)
/
æ
ə
/
For proving implications p→q, we have:
• A fallacy is an inference rule or other proof
method that is not logically valid.
– May yield a false conclusion!
• Fallacy of affirming the conclusion:
– “p→q is true, and q is true, so p must be true.” (No,
because F→T is true.)
• Fallacy of denying the hypothesis:
•
•
•
•
•
Direct proof: Assume p is true, and prove q.
Indirect proof: Assume ¬q, and prove ¬p.
Vacuous proof: Prove ¬p by itself.
Trivial proof: Prove q by itself.
Proof by cases:
Show p→(a ∨ b), and (a→q) and (b→q).
– “p→q is true, and p is false, so q must be false.”
(No, again because F→T is true.)
17
18
3
Direct Proof Example
Indirect Proof Example
• Definition: An integer n is called odd iff n=2k+1
for some integer k; n is even iff n=2k for some k.
• Axiom: Every integer is either odd or even.
• Theorem: (For all integers n)
If 3n+2 is odd, then n is odd.
• Proof: Suppose that the conclusion is false, i.e.,
that n is even. Then n=2k for some integer k.
Then 3n+2 = 3(2k)+2 = 6k+2 = 2(3k+1). Thus
3n+2 is even, because it equals 2j for integer j =
3k+1. So 3n+2 is not odd. We have shown that
¬(n is odd)→¬(3n+2 is odd), thus its contrapositive (3n+2 is odd) → (n is odd) is also true.
□
• Theorem: (For all numbers n) If n is an odd
integer, then n2 is an odd integer. (奇數平方仍為奇數)
• Proof: If n is odd, then n = 2k+1 for some
integer k. Thus, n2 = (2k+1)2 = 4k2 + 4k + 1 =
2(2k2 + 2k) + 1. Therefore n2 is of the form 2j +
1 (with j the integer 2k2 + 2k), thus n2 is odd. □
19
空的
Vacuous Proof Example
/
æ
k ju
20
Trivial Proof Example
/
• Theorem: (For all n) If n is both odd and
even, then n2 = n + n.
• Theorem: (For integers n) If n is the sum
of two prime numbers, then either n is odd
or n is even.
• Proof: The statement “n is both odd and
even” is necessarily false, since no
number can be both odd and even. So,
the theorem is vacuously true. □
• Proof: Any integer n is either odd or even.
So the conclusion of the implication is true
regardless of the truth of the antecedent.
Thus the implication is true trivially. □
21
Proof by Cases
22
Proofs of Equivalence
• To prove
• To prove
(p1 ∨ p2 ∨ … ∨ pn) → q
We can prove pi → q, i = 1, 2, …, n
individually since
(p1 ∨ p2 ∨ … ∨ pn) → q ↔ (p1 → q) ∧ (p2 → q)
∧ … ∧ (pn → q) is a tautology
p↔q
We can prove both p → q and q → p, since
(p ↔ q) ↔ [(p → q) ∧ (q → p)] is a tautology
23
24
4
Proof: √2 is irrational (無理數
(無理數))
Proof by Contradiction
• A method for proving p.
• Assume ¬p, and prove both q and ¬q for
some proposition q.
• Thus ¬p→ (q ∧ ¬q)
• (q ∧ ¬q) is a trivial contradiction, equal to F
• Thus ¬p→F, which is only true if ¬p=F
• Thus p is true.
• Rational number (有理數)
– A real number r is rational if there exist integers a and
b (b ≠0) such that r = a / b
• p: “√2 is irrational” q: “√2 = a / b for some a, b,
where a and b have no common factors”
• Assume ¬p: “√2 is rational”, we have ¬p → q.
• ¬p → 2 = a2 / b2 ⇒ a2 = 2b2 ⇒ a is even. ⇒ a = 2c
for some c. ⇒ 4c2 = 2b2 ⇒ b2 = 2c2 ⇒ b is even. ⇒
¬q, a contradiction
25
Review: Proof Methods So
Far
• Direct, indirect, vacuous, and trivial proofs
of statements of the form p→q.
• Proof by contradiction of any statements.
• Next: Constructive and nonconstructive
existence proofs.
26
Proving Existences
• A proof of a statement of the form ∃x P(x)
is called an existence proof.
• If the proof demonstrates how to actually
find or construct a specific element a such
that P(a) is true, then it is a constructive
建設性的
proof.
• Otherwise, it is nonconstructive.
非建設性的
27
Constructive Existence Proof:
An Example
• Theorem: There exists a positive integer n
that is the sum of two perfect cubes in two
立方數
different ways:
– equal to j3 + k3 and l3 + m3 where j, k, l, m are
positive integers, and {j,k} ≠ {l,m}
• Proof: Consider n = 1729, j = 9, k = 10,
l = 1, m = 12. Now just check that the
equalities hold.
此證明指出一個使定理成立的例子
29
28
Constructive Existence Proof:
Another Example
• Theorem: For any integer n>0, there
exists a sequence of n consecutive
composite integers (合成數). 連續的
–合成數: 非質數.
• Same statement in predicate logic:
∀n>0 ∃x ∀i (1≤i≤n)→(x+i is composite)
• (你相信會有連續10,000個非質數出現嗎?!)
• Proof follows on next slide…
30
5
Nonconstructive Existence
Proof: An Example
The proof...
• Given n>0, let x = (n + 1)! + 1.
• Consider x + 1 = (n + 1)! + 2, which can be
divided by 2.
=1×2×3×…×(n+1)
• Similarly, x + 2 = (n + 1)! + 3 can be divided by 3,
x + 3 = (n + 1)! + 4 can be divided by 4, and so
on.
• Generally, x+i = (n + 1)! + (i + 1) can be divided
by (i+1) for all 1 ≤ i ≤ n
• ∴ x+i is composite for all 1 ≤ i ≤ n.
• ∴ ∀n ∃x ∀1≤i≤n : x+i is composite. Q.E.D.
此證明說明如何找出使定理成立的例子
• Theorem:
質數
“There are infinitely many prime numbers.”
– Any finite set of numbers must contain a maximal
element, so we can prove the theorem if we can
just show that there is no largest prime number.
– i.e., show that for any prime number, there is a
larger number that is also prime.
– More generally: For any number, ∃ a larger prime.
– Formally: Show ∀n ∃p>n : p is prime.
31
The Proof Using
Proof by Cases
32
Uniqueness Proofs
• Given n>0, prove there is a prime p>n.
• Consider x = n!+1. Since x>1, we know
(x is prime) ∨ (x is composite).
• Case 1: x is prime. Obviously x>n, so let
p=x and we’re done.
• Case 2: x has a prime factor p. But if p≤n,
then p mod x = 1. So p>n, and we’re
done.
x = n!+1
• There is exactly one element with a
particular property
• Two parts of a uniqueness proof
– Existence
– Uniqueness
33
Uniqueness Proof Example
• If p is a integer, then there exists a unique
integer q such that p + q = 0
• Existence: if p is a integer, we find that p +
q = 0 when q = -p
• Uniqueness: Suppose that r ≠ q is another
integer such that p + r = 0. Then p + q = p +
r . It follows that q = r, which contradicts
our assumption.
35
34
Mistakes in Proof
• To prove 1 = 2
a=b
a2 = ab
a2 - b2 = ab - b2
(a - b)(a + b) = b(a - b)
a+b=b
2b = b
2=1
What’s wrong?
36
6