Top Banner
Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural Induction
41

We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Apr 16, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Outline

We will cover

Mathematical Induction (or Weak Induction)

Strong (Mathematical) Induction

Constructive Induction

Structural Induction

Page 2: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Principle of (Weak) MathematicalInduction

P(1)

(∀n ≥ 1)(P(n) → P(n + 1))

∴ (∀n ≥ 1)(P(n))

Page 3: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Principle of (Weak) MathematicalInduction

P(1)

(∀n ≥ 1)(P(n) → P(n + 1))

∴ (∀n ≥ 1)(P(n))

Alternate view:

P(1)

(∀n ≥ 2)(P(n − 1) → P(n))

∴ (∀n ≥ 1)(P(n))

Page 4: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Requirements

Mathematical Inductive proofs must have:

Page 5: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Requirements

Mathematical Inductive proofs must have:

Base case: P(1)Usually easy

Page 6: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Requirements

Mathematical Inductive proofs must have:

Base case: P(1)Usually easy

Inductive hypothesis: Assume P(n − 1)

Page 7: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Requirements

Mathematical Inductive proofs must have:

Base case: P(1)Usually easy

Inductive hypothesis: Assume P(n − 1)

Inductive step: Prove P(n − 1) → P(n)

Page 8: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Arithmetic series: A first example

Example

For all n ≥ 1

n∑

i=1

4i − 2 = 2 + 6 + 10 + . . . + (4n − 6) + (4n − 2)

= 2n2

Do in class.

Page 9: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Arithmetic series: Gauss’s sum

Example

For all n ≥ 1

n∑

i=1

i = 1 + 2 + 3 + . . . + (n − 1) + n

=n(n + 1)

2

Do in class.

Page 10: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Sum of powers of 2

Example

For all n ≥ 1

n−1∑

k=0

2k = 1 + 2 + 4 + 8 + . . . + 2n−2 + 2n−1

= 2n − 1

Do in class.

Page 11: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Geometric Series

Example

For all n ≥ 1 and real r 6= 1

n−1∑

k=0

r k = 1 + r + r 2 + r 3 + . . . + rn−2 + rn−1

=rn − 1

r − 1

Do in class.

Page 12: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A divisibility property

Example

For all integers n ≥ 0

n3 ≡ n (mod 3)

Do in class.

Use P(n) → P(n + 1) and/or start with InductionHypothesis.

Page 13: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Size of Power Set

Theorem

Let A be a finite set. Then

|P(A)| = 2|A|

Proof in class.

Page 14: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A recurrence relation

Example

Let

an =

{

an−1 + (2n − 1) if n ≥ 2

1 if n = 1

Thenan = n2 for n ≥ 1

Do in class.

Page 15: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

An inequality

Example

For all integers n ≥ 3

2n + 1 < 2n

Do in class.

Page 16: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Another inequality

Example

For all integers n ≥ 0 and real x ≥ 0

1 + nx ≤ (1 + x)n

Do in class.

Page 17: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Catalan Numbers

Example

Cn =1

n + 1

(

2n

n

)

=(2n)!

n!(n + 1)!

For all integers n ≥ 1

(2n)!

n!(n + 1)!≥

4n

(n + 1)2

Do in class.

Page 18: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A less mathematical example

Example

If all we have is 2 cent and 5 cent coins, we can makechange for any amount of money at least 4 cents.

Do in class.

Page 19: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A recurrence relationExample

Start with a0 = 1. a1 = a0 + 1 = 1 + 1 = 2.a2 = (a0 + a1) + 1 = (1 + 2) + 1 = 4.a3 = (a0 + a1 + a2) + 1 = (1 + 2 + 4) + 1 = 8.a4 = (a0 +a1 +a2 +a3)+1 = (1+2+4+8)+1 = 16.

In general,

an =

(

n−1∑

i=0

ai

)

+ 1 = (a0 + a1 + a2 + . . . + an−1) + 1

= 2n

Page 20: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A recurrence relationExample

Start with a0 = 1. a1 = a0 + 1 = 1 + 1 = 2.a2 = (a0 + a1) + 1 = (1 + 2) + 1 = 4.a3 = (a0 + a1 + a2) + 1 = (1 + 2 + 4) + 1 = 8.a4 = (a0 +a1 +a2 +a3)+1 = (1+2+4+8)+1 = 16.

In general,

an =

(

n−1∑

i=0

ai

)

+ 1 = (a0 + a1 + a2 + . . . + an−1) + 1

= 2n

Proof on next slide!!!

Page 21: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Proof of recurrence relation bymathematical inductionTheorem

an =

{

1 if n = 0(

n−1

i=0ai

)

+ 1 = a0 + a1 + . . . + an−1 + 1 if n ≥ 1

Then an = 2n.

Proof by Mathematical Induction. Base case easy.

Induction Hypothesis: Assume an−1 = 2n−1.Induction Step:

an =

(

n−1∑

i=0

ai

)

+ 1 =

(

n−2∑

i=0

ai

)

+ an−1 + 1 Now what?

Page 22: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Proof of recurrence relation bymathematical inductionTheorem

an =

{

1 if n = 0(

n−1

i=0ai

)

+ 1 = a0 + a1 + . . . + an−1 + 1 if n ≥ 1

Then an = 2n.

Proof by Mathematical Induction. Base case easy.

Induction Hypothesis: Assume an−1 = 2n−1.Induction Step:

an =

(

n−1∑

i=0

ai

)

+ 1 =

(

n−2∑

i=0

ai

)

+ an−1 + 1 Now what?

= (an−1 − 1) + an−1 + 1 = 2an−1 = 2 · 2n−1 = 2n.

Page 23: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Principle of Strong (Mathematical)InductionRecall weak mathematical induction:

P(1)

(∀n ≥ 2)(P(n − 1) → P(n))

∴ (∀n ≥ 1)(P(n))

Page 24: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Principle of Strong (Mathematical)InductionRecall weak mathematical induction:

P(1)

(∀n ≥ 2)(P(n − 1) → P(n))

∴ (∀n ≥ 1)(P(n))

Strong mathematical induction:

P(1)

(∀n ≥ 2)(P(1) ∧ P(2) ∧ · · · ∧ P(n − 1) → P(n))

∴ (∀n ≥ 1)(P(n))

Page 25: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Proof of recurrence relation bystrong inductionTheorem

an =

{

1 if n = 0(

n−1

i=0ai

)

+ 1 = a0 + a1 + . . . + an−1 + 1 if n ≥ 1

Then an = 2n.

Proof by Strong Induction. Base case easy.

Induction Hypothesis: Assume ai = 2i for 0 ≤ i < n.Induction Step:

an =

(

n−1∑

i=0

ai

)

+ 1 =

(

n−1∑

i=0

2i

)

+ 1

= (2n − 1) + 1 = 2n.

Page 26: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Another recurrence relation

Example

Let

an =

1 if n = 0

1 if n = 1

3 if n = 2

an−1 + an−2 − an−3 if n ≥ 3

Then an is odd, for n ≥ 0.

Do in class.

Page 27: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Yet another recurrence relation

Example

Let

ai =

0 if i = 0

7 if i = 1

2ai−1 + 3ai−2 if i ≥ 2

Then for all integers i ≥ 0

ai ≡ 0 (mod 7)

Do in class.

Page 28: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

And yet another recurrence relation

Example

Let

ai =

0 if i = 1

2 if i = 2

3a⌊ i

2⌋ if i ≥ 3

Then for all integers i ≥ 1, ai is even.

Do in class.

Page 29: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Size of prime numbers

Example

Let pn be the nth prime number. Then

pn ≤ 22n

Proof in class.

Page 30: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Jigsaw Puzzle

How many “moves” does it take to puttogether a jigsaw puzzle with n pieces?

Do in class.

Page 31: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Principle of Constructive Induction

If you know or guess the form of theanswer, you can sometimes derive theactual answer while doing mathematicalinduction to prove it.

Page 32: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Constructive Induction: ExampleExample

For all n ≥ 1n∑

i=1

4i − 2 = ?

Guess that for all integers n ≥ 1,

n∑

i=1

4i − 2 = an2 + bn + c Why?

Find constants a, b, and c such that this holds.

Do in class.

Page 33: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Constructive induction: RecurrenceExample

Let

an =

2 if n = 0

7 if n = 1

12an−1 + 3an−2 if n ≥ 2

What is an? Guess that for all integers n ≥ 0,

an ≤ ABn Why?Find constants A and B such that this holds:

Primarily find smallest B and secondarily smallest A.

Do in class.

Page 34: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Structural Induction

Definition (Loosely speaking . . .)

Structural induction is strong induction over recursivelydefined objects.

Page 35: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A geometric exampleDefinition

A triangulated polygon is a decomposition of the polygoninto triangles by non-intersecting lines.

Example in class.

Page 36: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A geometric exampleDefinition

A triangulated polygon is a decomposition of the polygoninto triangles by non-intersecting lines.

Example in class. Not recursively defined.

Page 37: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A geometric exampleDefinition

A triangulated polygon is a decomposition of the polygoninto triangles by non-intersecting lines.

Example in class. Not recursively defined.

Definition (Alternative recursive version)

A triangulated polygon is

Either a triangle,

or a polygon with a straight line drawn between twovertices (that are not next to each other), where thetwo polygons formed by this line and the originalpolygon are themselves triangulated polygons.

Page 38: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

A geometric example continued

Definition

A coloring of a triangulated polygon is an assignment ofcolors to all of the vertices of the polygon so that no twovertices that share an edge have the same color.

Example in class.

Theorem

Every triangulated polygon is 3-colorable.

Proof in class.

Page 39: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Full binary treeDefinition

A full binary tree is a rooted tree where every node hasexactly zero or two children.

Definition (Alternative recursive version)

A full binary tree is

Either a single node, called the root,

or a single node, called the root, with exactly twochildren, where each child is the root of a full binarytree.

Example in class.

Page 40: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Tree definitionsDefinition

The distance between two nodes is the number of edgesbetween them.

Definition

A leaf is a node with no children.An internal node is a node with children.

Definition

The external path length is the sum of the distances fromthe root to all of the leaves.The internal path length is the sum of the distances fromthe root to all of the internal nodes.

Page 41: We will cover Mathematical Induction (or Weak Induction ...Outline We will cover Mathematical Induction (or Weak Induction) Strong (Mathematical) Induction Constructive Induction Structural

Internal and external path lengths

Theorem

Let N be the number of nodes in a full binary tree. Let E

and I be its external and internal path lengths,

respectively. Then

E = I + N − 1

Two proofs in class.