<<

Jason Filippou

CMSC250 @ UMCP

06-27-2016

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 1 / 48 Outline

1 and series Sequences Series and partial sums

2 Weak Induction Intro to Induction Practice

3 Strong Induction

4 Errors in proofs by mathematical induction

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 2 / 48 Sequences and series

Sequences and series

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 3 / 48 Sequences and series Sequences

Sequences

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 4 / 48 Examples: 2, 4, 6,... 10, 20, 30 1, 1, 2, 3, 5, 8, 13, 21,... So, sequences can be either finite or infinite. We will mostly care about infinite sequences.

Sequences and series Sequences Definitions

Definition () A a : N 7→ R is called a sequence.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 5 / 48 So, sequences can be either finite or infinite. We will mostly care about infinite sequences.

Sequences and series Sequences Definitions

Definition (Sequence) A function a : N 7→ R is called a sequence.

Examples: 2, 4, 6,... 10, 20, 30 1, 1, 2, 3, 5, 8, 13, 21,...

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 5 / 48 Sequences and series Sequences Definitions

Definition (Sequence) A function a : N 7→ R is called a sequence.

Examples: 2, 4, 6,... 10, 20, 30 1, 1, 2, 3, 5, 8, 13, 21,... So, sequences can be either finite or infinite. We will mostly care about infinite sequences.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 5 / 48 Described through an explicit formula... k bk = 2 rn = (n + 1)! Or a recursive formula...

Fn+1 = Fn + Fn−1 ∀n ≥ 1

Sequences and series Sequences Denoting sequences

A sequence can be enumerated...

a : a1, a2,... (or just a1, a2,... ) c0, c1, c2,... (notice the indices)

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 6 / 48 Or a recursive formula...

Fn+1 = Fn + Fn−1 ∀n ≥ 1

Sequences and series Sequences Denoting sequences

A sequence can be enumerated...

a : a1, a2,... (or just a1, a2,... ) c0, c1, c2,... (notice the indices) Described through an explicit formula... k bk = 2 rn = (n + 1)!

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 6 / 48 Sequences and series Sequences Denoting sequences

A sequence can be enumerated...

a : a1, a2,... (or just a1, a2,... ) c0, c1, c2,... (notice the indices) Described through an explicit formula... k bk = 2 rn = (n + 1)! Or a recursive formula...

Fn+1 = Fn + Fn−1 ∀n ≥ 1

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 6 / 48 a0 and ω fully define the sequence.

So, how can I write ar?

a1 + r ∗ ω r ∗ a0 a0 + r ∗ ω r ∗ a0

Sequences and series Sequences The arithmetic sequence

Definition ∗ Let a : a0, a1,... be a sequence and ω ∈ R. If aj = aj−1 + ω ∀j ∈ N , a is an arithmetic sequence (or progression).

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 7 / 48 Sequences and series Sequences The arithmetic sequence

Definition ∗ Let a : a0, a1,... be a sequence and ω ∈ R. If aj = aj−1 + ω ∀j ∈ N , a is an arithmetic sequence (or progression).

a0 and ω fully define the sequence.

So, how can I write ar?

a1 + r ∗ ω r ∗ a0 a0 + r ∗ ω r ∗ a0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 7 / 48 a0 and c fully define the sequence.

ar. How can I write it?

r r rc r c ∗ a0 a0 a0 a0 + c

Sequences and series Sequences The geometric sequence

Definition ∗ ∗ Let a : a0, a1,... be a sequence and k ∈ R . If aj = c ∗ aj−1 ∀j ∈ N , a is a geometric sequence (or progression).

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 8 / 48 Sequences and series Sequences The geometric sequence

Definition ∗ ∗ Let a : a0, a1,... be a sequence and k ∈ R . If aj = c ∗ aj−1 ∀j ∈ N , a is a geometric sequence (or progression).

a0 and c fully define the sequence.

ar. How can I write it?

r r rc r c ∗ a0 a0 a0 a0 + c

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 8 / 48 Sequences and series Series and partial sums

Series and partial sums

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 9 / 48 Definition (Partial sum) +∞ X Let n ∈ N. Then, the n-th partial sum of the series ai, denoted i=0 n X Sn, is the sum ai. i=0

The partial sums themselves also form a sequence!

Sequences and series Series and partial sums Definitions

Definition (Series) +∞ X Let a0, a1,... be any sequence. Then, the sum ai is called a series. i=0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 10 / 48 The partial sums themselves also form a sequence!

Sequences and series Series and partial sums Definitions

Definition (Series) +∞ X Let a0, a1,... be any sequence. Then, the sum ai is called a series. i=0

Definition (Partial sum) +∞ X Let n ∈ N. Then, the n-th partial sum of the series ai, denoted i=0 n X Sn, is the sum ai. i=0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 10 / 48 Sequences and series Series and partial sums Definitions

Definition (Series) +∞ X Let a0, a1,... be any sequence. Then, the sum ai is called a series. i=0

Definition (Partial sum) +∞ X Let n ∈ N. Then, the n-th partial sum of the series ai, denoted i=0 n X Sn, is the sum ai. i=0

The partial sums themselves also form a sequence!

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 10 / 48 Theorem (Closed form of the arithmetic progression partial sum)

n(a1+an) If a is an arithmetic progression, Sn = 2 .

Theorem (Closed form of the geometric progression partial sum) n a1(c −1) If a is a geometric progression and c 6= 1, Sn = c−1 .

Both of those theorems can be proven via (weak) mathematical induction!

Sequences and series Series and partial sums Statements to prove!

To kickstart the discussion on induction, here are two theorems concerning partial sums:

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 11 / 48 Both of those theorems can be proven via (weak) mathematical induction!

Sequences and series Series and partial sums Statements to prove!

To kickstart the discussion on induction, here are two theorems concerning partial sums:

Theorem (Closed form of the arithmetic progression partial sum)

n(a1+an) If a is an arithmetic progression, Sn = 2 .

Theorem (Closed form of the geometric progression partial sum) n a1(c −1) If a is a geometric progression and c 6= 1, Sn = c−1 .

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 11 / 48 Sequences and series Series and partial sums Statements to prove!

To kickstart the discussion on induction, here are two theorems concerning partial sums:

Theorem (Closed form of the arithmetic progression partial sum)

n(a1+an) If a is an arithmetic progression, Sn = 2 .

Theorem (Closed form of the geometric progression partial sum) n a1(c −1) If a is a geometric progression and c 6= 1, Sn = c−1 .

Both of those theorems can be proven via (weak) mathematical induction!

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 11 / 48 Weak Induction

Weak Induction

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 12 / 48 Weak Induction Intro to Induction

Intro to Induction

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 13 / 48 Weak Induction Intro to Induction Proof methods: The story so far...

S

Existential Stmt. ? - + + - Universal Existential Proof Proof

Non- Indirect Constructive constructive Direct

Contradiction ? ? ? Generic Particular

Universal Statement Contraposition Division into cases Exhaustion

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 14 / 48 Weak Induction Intro to Induction Where induction fits

S

Existential Stmt. Universal Stmt - + + - Universal Existential Proof Proof

Non- Indirect Constructive constructive Direct

Contradiction Generic Contraposition Exhaustion Cases Particular

Induction

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 15 / 48 Weak Induction Intro to Induction The penny proposition: Statement

Suppose I have at least 4 in my wallet. Then, it turns out that all¢ my money can be stacked as 2 and 5 coins! ¢ ¢

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 16 / 48 What do you think of this proof?

Weak Induction Intro to Induction The penny proposition: Direct (non-inductive) proof

The penny proposition Every dollar amount greater than 3 s can be paid with only 2 and 5 coins. ¢ ¢ ¢ Proof (Direct, by cases). Suppose we have a total amount of C cents in our wallet. If C is an even number, then the statement is trivial by the definition of even numbers: We can just stack k 2 coins for some positive k. If C is an odd number greater than 3,¢ then it is 5 or greater. If it is 5, the problem is trivial: We only need one 5 coin. But every odd dollar amount after 5 can be retrieved by adding¢ any number of 2 coins, because of the¢ definition of parity. We are therefore done in¢ both cases.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 17 / 48 Weak Induction Intro to Induction The penny proposition: Direct (non-inductive) proof

The penny proposition Every dollar amount greater than 3 s can be paid with only 2 and 5 coins. ¢ ¢ ¢ Proof (Direct, by cases). Suppose we have a total amount of C cents in our wallet. If C is an even number, then the statement is trivial by the definition of even numbers: We can just stack k 2 coins for some positive integer k. If C is an odd number greater than 3,¢ then it is 5 or greater. If it is 5, the problem is trivial: We only need one 5 coin. But every odd dollar amount after 5 can be retrieved by adding¢ any number of 2 coins, because of the¢ definition of parity. We are therefore done in¢ both cases.

What do you think of this proof?

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 17 / 48 Weak Induction Intro to Induction The principle

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 18 / 48 Weak Induction Intro to Induction The principle

Principle of Weak Mathematical Induction Assume P (n) is a predicate applied on any n, and a ∈ N. If: P (a) is true P (k + 1) is true when P (k) is true ∀k ≥ a then, ∀n ≥ a, P (n) is true.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 19 / 48 1 Inductive Base (IB): We prove P (n0). Most often, n0 will be 0, 1, or 2. 2 Inductive hypothesis (IH): If k ∈ N is a generic particular such that k ≥ n0, we assume that P (k) is true. 3 Inductive Step (IS): We prove that P (k + 1) is true by making use of the Inductive Hypothesis where necessary.

Weak Induction Intro to Induction The approach

Our task is to prove some proposition P (n), for all positive n ≥ n0. Mathematical induction includes the following steps:

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 20 / 48 2 Inductive hypothesis (IH): If k ∈ N is a generic particular such that k ≥ n0, we assume that P (k) is true. 3 Inductive Step (IS): We prove that P (k + 1) is true by making use of the Inductive Hypothesis where necessary.

Weak Induction Intro to Induction The approach

Our task is to prove some proposition P (n), for all positive integers n ≥ n0. Mathematical induction includes the following steps:

1 Inductive Base (IB): We prove P (n0). Most often, n0 will be 0, 1, or 2.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 20 / 48 3 Inductive Step (IS): We prove that P (k + 1) is true by making use of the Inductive Hypothesis where necessary.

Weak Induction Intro to Induction The approach

Our task is to prove some proposition P (n), for all positive integers n ≥ n0. Mathematical induction includes the following steps:

1 Inductive Base (IB): We prove P (n0). Most often, n0 will be 0, 1, or 2. 2 Inductive hypothesis (IH): If k ∈ N is a generic particular such that k ≥ n0, we assume that P (k) is true.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 20 / 48 Weak Induction Intro to Induction The approach

Our task is to prove some proposition P (n), for all positive integers n ≥ n0. Mathematical induction includes the following steps:

1 Inductive Base (IB): We prove P (n0). Most often, n0 will be 0, 1, or 2. 2 Inductive hypothesis (IH): If k ∈ N is a generic particular such that k ≥ n0, we assume that P (k) is true. 3 Inductive Step (IS): We prove that P (k + 1) is true by making use of the Inductive Hypothesis where necessary.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 20 / 48 Weak Induction Intro to Induction The penny proposition, revisited

We want to prove that all amounts of pennies consisting of at least 4 pennies can be built using only 2 and 4 coins. The following proposition captures¢ the essence¢ of what we want to prove more generally:

The penny proposition, mathematical version Let n be an integer equal to at least 4. Then, there exist integers m, k such that n = 2m + 5k.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 21 / 48 Weak Induction Intro to Induction Inductive proof of the penny proposition

Proof (By weak mathematical induction). Let P (n) be the proposition that we want to prove, where n ≥ 4. Let r ∈ N be a generic particular for all integers equal to at least 4. Then: Inductive base: For r = 4,P (4) holds, since for m = 2 and k = 0, 4 = 2m + 5k. Inductive hypothesis: For a specific r ≥ 4, assume P (r): there exist integers m, k such that r = 2m + 5k.

Inductive step: We want to prove P (r + 1): there exist m0, k0 ∈ N such that r + 1 = 2m0 + 5k0. By the inductive hypothesis, we have that r = 2m + 5k ⇔ r + 1 = 2m + 5k + 1 ⇔ r + 1 = 2m + 5k + (6 − 5) ⇔ r + 1 = 2 (m + 3) +5 (k − 1) ⇔ r + 1 = 2m0 + 5k0. So P (r + 1) holds. | {z } | {z } m0 k0 Since r is a generic particular for the of integers above 3, the result holds for every n ∈ {4, 5,... }. We are done.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 22 / 48 1 To state which variable you are inducing on (“Proof by induction on n, a, r, . . . 2 Properly using your generic particulars. 3 Explicitly proving the inductive basis, no matter how obvious it may seem. 4 Clearly assuming the inductive hypothesis 5 Explicitly mentioning where the inductive hypothesis is used in the inductive step.

Weak Induction Intro to Induction Rules for authoring mathematical induction proofs

THOU SHALT NOT NEGLECT:

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 23 / 48 2 Properly using your generic particulars. 3 Explicitly proving the inductive basis, no matter how obvious it may seem. 4 Clearly assuming the inductive hypothesis 5 Explicitly mentioning where the inductive hypothesis is used in the inductive step.

Weak Induction Intro to Induction Rules for authoring mathematical induction proofs

THOU SHALT NOT NEGLECT: 1 To state which variable you are inducing on (“Proof by induction on n, a, r, . . .

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 23 / 48 3 Explicitly proving the inductive basis, no matter how obvious it may seem. 4 Clearly assuming the inductive hypothesis 5 Explicitly mentioning where the inductive hypothesis is used in the inductive step.

Weak Induction Intro to Induction Rules for authoring mathematical induction proofs

THOU SHALT NOT NEGLECT: 1 To state which variable you are inducing on (“Proof by induction on n, a, r, . . . 2 Properly using your generic particulars.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 23 / 48 4 Clearly assuming the inductive hypothesis 5 Explicitly mentioning where the inductive hypothesis is used in the inductive step.

Weak Induction Intro to Induction Rules for authoring mathematical induction proofs

THOU SHALT NOT NEGLECT: 1 To state which variable you are inducing on (“Proof by induction on n, a, r, . . . 2 Properly using your generic particulars. 3 Explicitly proving the inductive basis, no matter how obvious it may seem.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 23 / 48 5 Explicitly mentioning where the inductive hypothesis is used in the inductive step.

Weak Induction Intro to Induction Rules for authoring mathematical induction proofs

THOU SHALT NOT NEGLECT: 1 To state which variable you are inducing on (“Proof by induction on n, a, r, . . . 2 Properly using your generic particulars. 3 Explicitly proving the inductive basis, no matter how obvious it may seem. 4 Clearly assuming the inductive hypothesis

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 23 / 48 Weak Induction Intro to Induction Rules for authoring mathematical induction proofs

THOU SHALT NOT NEGLECT: 1 To state which variable you are inducing on (“Proof by induction on n, a, r, . . . 2 Properly using your generic particulars. 3 Explicitly proving the inductive basis, no matter how obvious it may seem. 4 Clearly assuming the inductive hypothesis 5 Explicitly mentioning where the inductive hypothesis is used in the inductive step.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 23 / 48 Weak Induction Practice

Practice

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 24 / 48 +∞ X 2 2 ∗ n n=0 +∞ X 3 2 ∗ n n=1 0 X 4 2 ∗ i n=0 100 X 5 0 n=0

Weak Induction Practice Mini-quiz

Are the following partial sums (“Sn”s) of a series? YES NO

100 X 1 2 ∗ n n=0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 25 / 48 +∞ X 3 2 ∗ n n=1 0 X 4 2 ∗ i n=0 100 X 5 0 n=0

Weak Induction Practice Mini-quiz

Are the following partial sums (“Sn”s) of a series? YES NO

100 X 1 2 ∗ n n=0 +∞ X 2 2 ∗ n n=0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 25 / 48 0 X 4 2 ∗ i n=0 100 X 5 0 n=0

Weak Induction Practice Mini-quiz

Are the following partial sums (“Sn”s) of a series? YES NO

100 X 1 2 ∗ n n=0 +∞ X 2 2 ∗ n n=0 +∞ X 3 2 ∗ n n=1

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 25 / 48 100 X 5 0 n=0

Weak Induction Practice Mini-quiz

Are the following partial sums (“Sn”s) of a series? YES NO

100 X 1 2 ∗ n n=0 +∞ X 2 2 ∗ n n=0 +∞ X 3 2 ∗ n n=1 0 X 4 2 ∗ i n=0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 25 / 48 Weak Induction Practice Mini-quiz

Are the following partial sums (“Sn”s) of a series? YES NO

100 X 1 2 ∗ n n=0 +∞ X 2 2 ∗ n n=0 +∞ X 3 2 ∗ n n=1 0 X 4 2 ∗ i n=0 100 X 5 0 n=0

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 25 / 48 Weak Induction Practice Three sums!

The following are some statements we will prove inductively in class! Note the different ways in which the theorems can be presented.

Theorem (Partial sum of a special-case arithmetic progression)

Let a be an arithmetic progression with a1 = ω = 1. Then, prove that n(n+1) Sn = 2 .

Theorem (Partial sum of a special-case geometric progression) Pn i rn+1−1 For r 6= 1 and n ∈ N, prove that i=0 r = r−1

Theorem (Some random theorem Jason found in an old book of his) 3 3 3  n(n+1) 2 For n ≥ 1, 1 + 2 + ··· + n = 2 .

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 26 / 48 Weak Induction Practice Problems beyond sums

Mathematical induction is useful for proving other properties of integers as well! Let’s prove the following theorems inductively:

Theorem For all integers n ≥ 1, 22n − 1 is divisible by 3.

Theorem For all integers n ≥ 3, 2n + 1 < 2n.

Theorem √ For all integers n ≥ 2, n < √1 + √1 + ··· + √1 . 1 2 n

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 27 / 48 Strong Induction

Strong Induction

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 28 / 48 Strong Induction Nets instead of dominoes

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 29 / 48 Is there any relation to the principle of Weak Induction?

YES NO

Strong Induction Strong induction principle

Principle of Strong Induction Let n, a, b ∈ N : a ≤ b. If: 1 P (a),P (a + 1),...,P (b) are all true, and 2 ∀k > b, if P (i) is true ∀i : a ≤ i < k, then P (k) is true, then, P (n) ∀n ≥ a.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 30 / 48 Strong Induction Strong induction principle

Principle of Strong Induction Let n, a, b ∈ N : a ≤ b. If: 1 P (a),P (a + 1),...,P (b) are all true, and 2 ∀k > b, if P (i) is true ∀i : a ≤ i < k, then P (k) is true, then, P (n) ∀n ≥ a.

Is there any relation to the principle of Weak Induction?

YES NO

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 30 / 48 Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N. That’s our safety net!

Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here) Inductive step: We prove that if the hypothesis holds, then P (k) should also hold. Notice that the inductive hypothesis does not cover P (k)! All 5 rules for cleanly authoring inductive proofs still apply.

Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 That’s our safety net!

Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here) Inductive step: We prove that if the hypothesis holds, then P (k) should also hold. Notice that the inductive hypothesis does not cover P (k)! All 5 rules for cleanly authoring inductive proofs still apply.

Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here) Inductive step: We prove that if the hypothesis holds, then P (k) should also hold. Notice that the inductive hypothesis does not cover P (k)! All 5 rules for cleanly authoring inductive proofs still apply.

Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N. That’s our safety net!

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 Inductive step: We prove that if the hypothesis holds, then P (k) should also hold. Notice that the inductive hypothesis does not cover P (k)! All 5 rules for cleanly authoring inductive proofs still apply.

Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N. That’s our safety net!

Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here)

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 Notice that the inductive hypothesis does not cover P (k)! All 5 rules for cleanly authoring inductive proofs still apply.

Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N. That’s our safety net!

Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here) Inductive step: We prove that if the hypothesis holds, then P (k) should also hold.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 All 5 rules for cleanly authoring inductive proofs still apply.

Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N. That’s our safety net!

Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here) Inductive step: We prove that if the hypothesis holds, then P (k) should also hold. Notice that the inductive hypothesis does not cover P (k)!

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 Strong Induction Strongly inductive proofs: Sketch

We want to prove a statement P (n) ∀n ≥ n0 (like in Weak Induction)

Inductive base: We prove that P (n0),P (n0 + 1),...,P (n0 + r) are true, for some r ∈ N. That’s our safety net!

Inductive hypothesis: For some k > n0 + r, we assume that P (i) is true for all i between n0 and k − 1. (Make sure you pay extra attention to the inequalities here) Inductive step: We prove that if the hypothesis holds, then P (k) should also hold. Notice that the inductive hypothesis does not cover P (k)! All 5 rules for cleanly authoring inductive proofs still apply.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 31 / 48 Strong Induction An example proof

Theorem (Divisibility of an integer by a prime) Prove that any integer n > 1 is divisible by a .

We already proved this one through a very complicated direct proof by cases. The strong inductive hypothesis allows for a much more consise proof! Notice that, in this case, r = 0.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 32 / 48 Which one among those is a correct definition?

1 F1 = 0,F2 = 1,Fn = Fn−1 + Fn−2 ∀n ≥ 3 2 F0 = 0,F1 = 1,Fn = Fn−1 + Fn−2 ∀n ≥ 2 3 F0 = 1,F1 = 1,Fn+1 = Fn + Fn−1 ∀n ≥ 2 4 F0 = 1,F1 = 1,Fn = Fn−1 + Fn−2 ∀n ≥ 2

1 2 3 4

Strong Induction Reminder: recursively defined sequences

Strong induction is very popular for solving problems with recursively defined sequences. The Fibonacci sequence is perhaps the most famous such sequence.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 33 / 48 Strong Induction Reminder: recursively defined sequences

Strong induction is very popular for solving problems with recursively defined sequences. The Fibonacci sequence is perhaps the most famous such sequence. Which one among those is a correct definition?

1 F1 = 0,F2 = 1,Fn = Fn−1 + Fn−2 ∀n ≥ 3 2 F0 = 0,F1 = 1,Fn = Fn−1 + Fn−2 ∀n ≥ 2 3 F0 = 1,F1 = 1,Fn+1 = Fn + Fn−1 ∀n ≥ 2 4 F0 = 1,F1 = 1,Fn = Fn−1 + Fn−2 ∀n ≥ 2

1 2 3 4

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 33 / 48 Strong Induction A proof on a recursive sequence

A statement on a recursive sequence

Let a : a1, a2,... be a sequence, recursively defined as follows:

a1 = 0

a2 = 0

ak =3abk/2c + 2 ∀k ≥ 3

Prove that an is even for each integer n ≥ 1.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 34 / 48 Strong Induction Proof

Proof via strong induction on k. Let r ≥ 1 be an integer generic particular and P (n) be the proposition that we want to prove. We proceed inductively:

Inductive Base: For r = 1 and r = 2, a1 and a2 are even, so P (1) and P (2) hold. (Strong) Inductive Hypothesis: For some r > 2 and for all 1 ≤ i < r, assume that P (i) is true: ai is even.

Inductive step: We want to prove that P (r) is true, i.e that ar = 3abr/2c + 2 is even. From a known theorem, we know that the product of an even and an odd integer is even, while the sum of two even numbers is also even. Since we covered the cases r = 1 and r = 2 in the inductive basis, it is the case that r r ≥ 3, and for all such choices of r, b /2c < r. But this means that abr/2c is even, by the inductive hypothesis. Therefore, ar is even, since it consists of a sum of an even number (2) added to another even number (3 times an even number). ∗ ∗ Since r was chosen arbitrarily from the set N , the result holds ∀n ∈ N .

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 35 / 48 Strong Induction Another proof on a recursive sequence

The closed form for another recursive sequence Let a be a sequence such that:

a1 = 1

a2 = 8

an = an−1 + 2an−2, ∀n ≥ 3

n−1 n Prove that an = 3 · 2 + 2(−1) .

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 36 / 48 Strong Induction Proof

Proof (by strong induction on n). ∗ Let k be a generic particular for N , and P (n) be the proposition that we want to show. We proceed inductively: 0 1 Inductive base: P (1) is the proposition: a1 = 3 · 2 + 2 · (−1) ⇔ a1 = 1. Since, by the definition of the sequence a, a1 = 1, P (1) is true. P (2) is the proposition: 1 2 a2 = 3 · 2 + 2(−1) ⇔ a2 = 8. Once again, this is true by the definition of a, so P (2) also holds. (Strong) inductive hypothesis: For some k > 2, we assume P (i) is true i−1 i ∀i ∈ {1, 2, . . . , k − 1}, i.e ai = 3 · 2 + 2 · (−1) . k−1 k Inductive step: We want to prove P (k), i.e ak = 3 · 2 + 2(−1) . By the definition of an for n ≥ 3, we have:

ak = ak−1 + 2ak−2 = 3 · 2k−2 + 2(−1)k−1 + 2[3 · 2k−3 + 2(−1)k−2] (By Inductive Hypothesis) = 3 · 2k−2 + 2(−1)k−1 + 3 · 2k−2 + 2 · 2(−1)k−2 (By distributing the factor 2) = 3 · 2k−1 + 2[(−1)k−1 + 2(−1)k−2] (By grouping terms) = 3 · 2k−1 + 2(−1)k (By equality of the red terms) ⇔ P (k) is true ∗ Since our result was reached for an arbitrarily selected k,it holds ∀n ∈ N .

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 37 / 48 Do you perhaps remember what the direct proof that we discussed previously looked like? Strong induction will lead us to a much more consise proof!

Strong Induction Re-visiting an older theorem

Theorem (Divisibility by a prime) Every integer n > 1 is divisible by a prime number.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 38 / 48 Strong induction will lead us to a much more consise proof!

Strong Induction Re-visiting an older theorem

Theorem (Divisibility by a prime) Every integer n > 1 is divisible by a prime number.

Do you perhaps remember what the direct proof that we discussed previously looked like?

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 38 / 48 Strong Induction Re-visiting an older theorem

Theorem (Divisibility by a prime) Every integer n > 1 is divisible by a prime number.

Do you perhaps remember what the direct proof that we discussed previously looked like? Strong induction will lead us to a much more consise proof!

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 38 / 48 Strong Induction Proof Proof (by strong induction on n). Let q be a generic particular for the set {2, 3,... } and P (n) be the proposition we are trying to prove. We proceed inductively: Inductive base: For q = 2, we have that 2 is divisible by a prime number, namely itself. Therefore, P (2) holds. (Strong) Inductive hypothesis: For q > 2, we assume that P (i) holds ∀i ∈ {2, 3, . . . , q − 1}, i.e i is divisible by a prime number. Inductive step: We want to prove P (q), i.e that q > 2 is divisible by a prime number. We distinguish between two cases: 1 q is prime. In this case, since q|q, we are done. 2 q is not prime. Therefore, q is composite, which means that a ∃a, b ∈ N : q = a · b. Since both a and b are above 1 (if one of them was 1, the other would have to be q, making q prime), we conclude that both of them have to be smaller than q. By the inductive hypothesis, this means that there exists some prime p that divides at least one of a or b, and by transitivity of divisibility we have that p|q. This is exactly P (q). Since q was selected arbitrarily from {2, 3,... }, we have that the result holds for every integer in this set.

aWe only care about the positive divisors of q.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 39 / 48 Strong Induction Practice

Let’s split into teams and solve these problems!

Yet another recursive sequence

Suppose that the sequence s is such that: s0 = 12, s1 = 29 and k k sk = 5sk−1 − 6sk−2 ∀k ≥ 2. Prove that sk = 5 · 3 + 7 · 2 , ∀k ∈ N.

More Fibonacci? Sure, why not. Show that the Fibonacci sequence follows an “odd-odd-even” pattern. More formally, if by F we denote this sequence, show that ∗ ∀m ∈ N ,F3m−2 and F3m−1 are odd, while F3m is even.

The “Tribonacci” Sequence (yes, seriously)

The Tribonacci sequence is defined as: T0 = T1 = T2 = 1 and Tn = Tn−1 + Tn−2 + Tn−3 for n ≥ 3. Prove that, for all n+1 n ∈ N,Tn < 2

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 40 / 48 Errors in proofs by mathematical induction

Errors in proofs by mathematical induction

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 41 / 48 Errors in proofs by mathematical induction This section

We will present some examples of non-sensical statements proven via the principle of induction, or of correct statements with incorrect proofs! The teaching staff assumes no responsibility for students believing those to be valid statements or proofs! All examples courtesy of materials taken from MATH 347, Summer ’14, UIUC.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 42 / 48 Errors in proofs by mathematical induction Non-sensical proof #1 Sum of first n non-zero integers

n ∗ X 1 1 2 ∀n ∈ N , i = (n + ) i=1 2 2

Proof (By weak induction on n).

∗ Let r ∈ N be a generic particular and P (n) the statement we want to solve. We proceed inductively: 1 Inductive base: For r = 1, P (1) holds. r X 1 1 2 Inductive hypothesis: Assume that P (r) holds ∀r ≥ 1, i.e i = (r + )2 i=1 2 2 r+1 X 1 1 3 Inductive step: We want to prove P (r + 1), i.e i = ((r + 1) + )2. Beginning from the LHS i=1 2 2 we have:

r+1 r X X 1 1 i = i + (r + 1) = (r + )2 +( r + 1) (By breaking apart the sum and by I.H) i=1 i=1 2 2 1  1  1  3 9 1  = (r2 + r + )+ (2 r + 2) = (r + )2 − 3r − + r + + (2r + 2) (By algebra) 2 4 2 2 4 4 1  1 2 = (r + 1) + ⇒ P (r + 1) holds. (By algebra) 2 2

∗ Since r was chosen arbitrarily from N , we conclude that the result must hold for all positive integers.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 43 / 48 Errors in proofs by mathematical induction Non-sensical proof #2

Raising 2 to a non-negative integer equals 1

n ∀n ∈ N, 2 = 1

Proof (by strong induction on n).

Let P (n) be the proposition that we’re trying to prove and r ∈ N be a generic particular. We proceed inductively: 1 Inductive base: For r = 0, 2r = 1. So P (0) = 1. 2 Inductive hypothesis: For r > 0, we assume that ∀i ∈ {0, 1, . . . , r}, P (i) holds, i.e that 2i = 1. 3 Inductive step: We want to prove that P (r + 1) holds, i.e that 2r+1 = 1. We begin from the LHS: 2r+1 =21 · 2r (By properties of ) =1 · 1 (By inductive hypothesis) = 1

Therefore, P (r + 1) holds. Since r was arbitrarily chosen within N, the result holds ∀n ∈ N.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 44 / 48 Errors in proofs by mathematical induction Non-sensical proof #3

LOL WUT All real numbers are equal.

Proof. Equivalently, we want to prove that, ∀k ∈ N, a1 = a2 = ··· = ak, where ∗ ai ∈ R. We will proceed via strong induction on k. Let r ∈ N be a generic particular and P (k) be the proposition we’re trying to solve. We proceed inductively:

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 45 / 48 Errors in proofs by mathematical induction “All reals are equal” proof, contd.

Proof.

1 Inductive base: For r = 1, the statement is trivially true: a1 = a1. 2 Inductive hypothesis: For r > 1, we will assume that ∀i ∈ {0, 1, . . . , r − 1}, P (i) is true, i.e any i reals are true: a1 = a2 = ··· = ai. 3 Inductive step: We want to prove that P (r) is true, i.e that a1 = a2 = ··· = ar. Consider the first r − 1 reals. Since r − 1 < r, from the I.H we can deduce: a1 = a2 = ··· = ar−1 (1) The same can be deduced for the last r − 1 reals:

a2 = a3 = ··· = ar (2)

From (1) and (2) we conclude that a1 = a2 = ··· = ar−1 = ar, and P (r) is true.

Since r was arbitrarily chosen, the result holds ∀k ∈ N.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 46 / 48 Errors in proofs by mathematical induction True statement, incorrect proof

Parity of the

∀n > 1, n! is even

Proof (via strong induction on n). Let r ∈ {2, 3,... } be a generic particular and P (n) be the proposition we’re trying to prove. We proceed inductively: 1 Inductive base: For r = 2, 2! = 2 · 1 = 2. 2 is even, therefore P (2) holds. 2 Inductive hypothesis: For r > 2, we assume P (i) ∀i ∈ {2, 3, . . . , r − 1}, i.e i! is even. 3 Inductive step: We want to prove P (r + 1), i.e that (r + 1)! is even. By the recursive definition of the factorial, (r + 1)! = (r + 1) · r! From the inductive hypothesis, we know that r! is even. From a known theorem, we know that the product of two integers, where at least one is even, is also even. Therefore, (r + 1)! is even and P (r + 1) holds. Since r was chosen arbitrarily, the result holds for every integer n ≥ 2.

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 47 / 48 Errors in proofs by mathematical induction Vote!

Proof (via strong induction on n). Let r ∈ {2, 3,... } be a generic particular and P (n) be the proposition we’re trying to prove. We proceed inductively: 1 Inductive base: For r = 2, 2! = 2 · 1 = 2. 2 is even, therefore P (2) holds. 2 Inductive hypothesis: For r > 2, we assume P (i) ∀i ∈ {2, 3, . . . , r − 1}, i.e i! is even. 3 Inductive step: We want to prove P (r + 1), i.e that (r + 1)! is even. By the recursive definition of the factorial, (r + 1)! = (r + 1) · r! From the inductive hypothesis, we know that r! is even. From a known theorem, we know that the product of two integers, where at least one is even, is also even. Therefore, (r + 1)! is even and P (r + 1) holds. Since r was chosen arbitrarily, the result holds for every integer n ≥ 2.

This proof has an error in:

The Ind. Base The Ind. Hypothesis The Ind. Step Somewhere else

Jason Filippou (CMSC250 @ UMCP) Induction 06-27-2016 48 / 48