Proofs with Predicates
Inference Rules for Quantification
Æ -introduction (for propositions …and now predicates)
[p]
[p(x)]
q
q(x)
pÆq
p(x) Æ q(x)
$ -introduction
aŒU
p(a)
$ xŒU: p(x)
" -introduction
[xŒU]
q(x)
" xŒU: q(x)
Two More Inference Rules
Quantifier Elimination
$-elimination
$ x Œ U : p(x)
aŒU Ÿ p(a)
" - elimination
" xŒU : p(x)
p(a)
Inference Rules for Quantification II
• "-elimination is like Ÿ - elimination
• $ -introduction is like ⁄ -introduction
• $ -elimination is like ‘…let’s call it a.’
• " -introduction: ‘…x is arbitrary in U’
Using Quantifiers
Goldbach’s Conjecture (1742)
• Informally: Every even integer above 2 is the sum of two
primes; e.g., 4=2+2, 6=3+3, 8=5+3, 10=7+3, …
• Formally: " even integer > 2 : $ primes p, q : n = p + q
" Introduction - One We Can Prove
•
•
•
Look for the definition of “even” below:
Theorem (Informal):
If the sum of two integers is even, so is their difference.
Theorem (Formal):
" n, m Œ I: ($ k Œ I : n+m = 2k) Æ ($ j Œ I such that n-m = 2j)
Proof: n and m are arbitrary; we need to find the j
m+n = 2k
m = 2k-n
m – n = 2k – 2n = 2(k-n)
so select j = k-n
The Product of Two Odds is Odd
[aŒN Ÿ b ŒN]
[odd9a) Ÿ odd(b)]
odd(a)
$ wŒ N (a=2w+1) def. of odd
a = 2x+1
odd(b)
$ wŒN (b=2w+1)
b = 2y+1
ab= 2(2xy+x+y) +1
ab = 2z+1
$ wŒN (ab=2w + 1)
odd(ab)
(odd(a) Ÿ odd(b)) Æ odd(ab)
"aŒN, " bŒN ((odd(a) Ÿ (odd(b))Æodd(ab))
$-elimination
$-elimination
$-introduction
Æ -introduction
Why We Need to do it Formally
Mistakes People Make
• Arguing from examples
– Let m = 6 and n = 20 then m+n = 2k where k = 13 and
m-n = 2j where j = -7 therefore ..
– “Every integer is a power of 2 the sum of two of them
or prime.” is true for a while (1, 2, 3, 4, … , 13) then
false for 14.
• Mixing up symbols
– Given m+n = 2k show m-n = 2k
• Begging the question
– Given m+n = 2k then if m-n = 2j we know j = m-n/2
which is an integer.
Consecutive Integers
• Theorem: Any two consecutive integers have
opposite parity:
• Definition: Two integers are consecutive if one is
one more than the other
• " m, n Œ I if n = m+1 then m is even ´ n is odd
and m is odd ´ n is even.
• " m Œ I m is even ´ m+1 is odd and m is odd ´
m+1 is even
[mŒI]
Proof
assumption
assumption
[m is even]
…………
m+1 is odd
conclusion
(m even) Æ (m+1 odd)
Æ intro
[m+1 odd]
assumption
…………
m even
conclusion
(m+1 odd) Æ (m even)
Æ intro
(m even) ´ (m+1 odd)
biconditional
[m is odd]
assumption
…………
m+1 is even
conclusion
(m odd) Æ (m+1 even)
Æ intro
[m+1 even]
assumption
…………
m odd
conclusion
(m+1 even) Æ (m odd)
Æ intro
(m odd) ´ (m+1 even)
biconditional
(m even) ´ (m+1 odd) Ÿ (m odd) ´ (m+1 even)
Ÿ intro
" mŒI (m even) ´ (m+1 odd) Ÿ (m odd) ´ (m+1 even)
" intro
First Conclusion
[m ŒI]
[m is even]
$ k ŒI : m = 2k
m = 2a
m+1 = 2a + 1
$ j ŒI : m+1= 2j + 1
m+1 odd
(m even) Æ (m+1) odd
assumption
assumption
definition of even
$ elimination
algebra
$ introduction
definition of odd
Æ introduction
• The other conclusions are the same
Mathematical Induction
• Mathematical induction is one of many ways to
operate on or prove something about arbitrarily
many things in a fixed amount of space.
• Others are
–
–
–
–
–
–
–
Iteration
Loops
Recursive functions
Recursive definitions
Universal quantification
Summations - S
Products - P
Mathematical Induction
• Proves an infinite family of propositions
• Call them P1, P2, P3…
• Base case: Prove the first proposition
– What if we can’t prove P1 but we can prove Pa ?
• Inductive step: Prove "I: Pi-1 Æ Pi
– M.I. Makes proofs easier by letting us use Pi-1 to help in proving Pi
– Inductive step justifies all these arrows
• P1 (base case) Æ P2 Æ P3 Æ P4 Æ …
• The inductive step is often written "i: Pi Æ Pi+1
– Does it matter whether the index is i-1 or i?
Domino Analogy
•
•
•
•
Imagine you have an infinite number of dominoes
When you tip the ith domino, all behind it fall
When you tip the first domino. They all fall
The base case amounts to tipping the first domino
–
–
–
–
–
–
P1 tips P2
P2 tips P3
P3 tips P4
P4 tips P5
……….
and Pn tips
Sum of the First n Numbers
Example 1
n
Theorem: S i = n(n+1) / 2
i=1
Proof:
n
n-1
S i = n + S i but the second term is the I.H.
i=1
i=1
= n + {(n-1)[(n-1)+1]}/2 = 2n/2 + n(n-1)/2
= {2n + n(n-1)}/2 = {2n+ n2 – n}/2 = {n2+n}/2
= n(n+1)/2
The Lore of Karl Friedrich Gauss
• The teacher wanted to read the newspaper
• He gave the students some busy work
• Gauss ruined his morning
1
2 3 4 5 … 98 99 100
100 99 98 97 96 … 3
2
1
101 101 101 101 101 …101 101 101
Flexibility
• Weak vs. strong
– Each proposition (after P1) follows from its
• Predecessor by weak induction
• Predecessors by strong induction
• Pi Æ Pi+1 is the inductive step, but be careful about the
starting point
• Example
– Let Pi be the proposition 2i > i2
– Pi is true for all i ≥ 5, but not for i = 2, 3 and 4
– So we must start at P5 not P4
– Base case P5 : 25 = 32 > 25= 52
– And we use i ≥ 6 in proving the inductive step
Exponentials Outgrow Polynomials
Example 2
•
•
•
•
Theorem: "i ≥ 5: 2i > i2
Base Case: 25 = 32 > 25 = 52
Inductive Hypothesis: 2i-1 > (i-1)2
Inductive Step:
2i = 2 * 2i-1 > 2(i-1) 2
= 2(i2 -2i+1) = i2 + i2 – 4i+2
= [with i > 5] i2 + 5i – 4i+2 = i2 + i + 2 > i2
Geometric Sequence
Theorem: " n Œ N : "r≠1Œ R
n
S r i = (r n+1 –1)/r-1
i=0
0
P(0) = S r i = r 0 = 1 and (r 0+1 –1)/r-1 =r-1/r-1 = 1
i=0
n-1
I.H. P(n-1) = S r i = (r (n-1)+1 –1)/r-1= (r n –1)/r-1
i=0
n
Prove P(n) = S r i = (r n+1 –1)/r-1
i=0
Inductive Step
n
n-1
P(n) = S r i = r n + S r i = r n +(r n –1)/r-1
i=0
i=0
= r n (r-1)/(r-1)+(r n –1)/r-1 = {(r n+1 – r n)+ (r n
–1)}/r-1
= (r n+1 – r n + r n –1)/r-1 = (r n+1 –1)/r-1
Math Induction as a Rule of Inference
P1
"i >1 Pi-1 Æ Pi
"i ≥1: Pi
• The bottom line is what we want to prove
• The second line introduces "and Æ , so it needs
– "-introduction (assume only that it is ‘some’ positive
integer - IH)
– Æ -introduction (assume the left hand side Pi-1 )
M.I Formal From
……
P(0)
Base Case
[n≥1]
assumption
[P(n-1)]
Inductive hypothesis
……
P(n)
Inductive conclusion
P(n-1) Æ P(n)
Æ introduction
" n ≥ 1 P(n-1) ÆP(n)" introduction
" n ≥ 0 P(n)
Mathematical induction
Strategies for M.I.
• When Pi doesn’t hold for small i…
– Take a larger value of i for the base case
• When Pi-1 isn’t enough to prove Pi…
– Use strong induction
• If the predicate is only true for odd integers…
– Let Pi = Q2i+1
– And for powers of 2, let Pi = Q2i
• When Pi is and equation Li = Ri
– Li = Li-1 + xxx = Ri-1 + yyy = Ri
– Work inward from the edges trying to show xxx = yyy
Sum of Odd Integers
Theorem: The sum of the first n odd integers is n2
Formally,
n
" n : S (2k-1) = 1 + 3 + …+ 2n-1 = n2
k=1
Use M.I.
Inductive Step
Base Case: P(1) = 2*1-1 = 1 and 12 = 1
n-1
IH
S P(k) =(n-1) 2
k=1
n
S P(k) =P(n) + (n-1) 2 = (2n-1) + (n-1) 2 =
k=1
2n – 1 + n 2 –2n +1= n 2
Divisibility
• Theorem: For all integers ≥ 1, 4n –1 is divisible by 3
Formally, " k : $ r: 4k –1 = 3r
• Base Case: 41 –1 = 3
• I.H. - assume 4(k-1) -1 = 3r
Then
4k -1 = 4(4(k-1) ) - 4 + 4 - 1 = 4(3r) + 3 = 3(4r + 1) = 3s
Weak Induction ÆStrong Induction
• Assume weak induction holds
– P0 and Pn-1 Æ Pn fi "n ≥ 0 Pn
• Prove strong induction
– P0 and P0 Ÿ P1, Ÿ P2, Ÿ … Ÿ Pn-1 Æ Pn fi "n ≥ 0 Pn
• Proof:
– Define Qn = Pk true 0£ k £n
– Show Qn true for all n ≥ 0
Weak Induction ÆStrong Induction
cont’d
• Q0 = P0 base case
• Assume Qn-1 true which means P0 Ÿ P1 Ÿ P2 Ÿ … Ÿ Pn-1
true
• Pn true from the strong inductive hypothesis
• Thus Qn true by definition
• And thus by weak induction "n ≥ 0 Qn
• Hence, weak induction Æ strong induction
© Copyright 2026 Paperzz