Strong Induction, WOP and Invariant Method - PowerPoint PPT Presentation

1 / 19
About This Presentation
Title:

Strong Induction, WOP and Invariant Method

Description:

Well Ordering Principle. Every non-empty set of positive integers contains a smallest ... Well Ordering Principle - Ans. Assume the is solution for the equation ... – PowerPoint PPT presentation

Number of Views:107
Avg rating:3.0/5.0
Slides: 20
Provided by: appsrvCs
Category:

less

Transcript and Presenter's Notes

Title: Strong Induction, WOP and Invariant Method


1
Strong Induction, WOP and Invariant Method
  • Leo Cheung

2
Project
  • Register your group at
  • http//spreadsheets.google.com/viewform?hlenform
    keydEE5R181ZkJNMXVDNTV2eUNSaGxjR1E6MA

3
A Quick Review
  • Strong induction
  • Well ordering principle
  • Invariant method

4
Recall Strong Induction (Lecture 5, Slide 35)
Prove P(0). Then prove P(n1) assuming all of
P(0), P(1), , P(n) (instead of just
P(n)). Conclude ?n.P(n)
Strong induction
equivalent
0 ? 1, 1 ? 2, 2 ? 3, , n-1 ? n. So by the time
we got to n1, already know all of
P(0), P(1), , P(n)
Ordinary induction
5
Strong Induction
  • Given
  • f1 1
  • fk 2 ffloor(k/2)
  • Prove fn lt n

6
Strong Induction - Answer
  • Base case
  • f1 1 lt 1
  • Assume fj j, 1 j k
  • fk1 2 ffloor((k1)/2)
  • 2 floor((k1)/2)
  • k1
  • Done.

7
Strong Induction
  • Given
  • g0 12
  • g1 29
  • gk 5gk-1 6gk-2 for all integers k gt2
  • Prove gn 5x3n 7x2n for all integers ngt0

8
Strong Induction - Answer
  • Base Case
  • n 0, 1 Trivial
  • Assume the hypothesis is true for 0,1,2,.k-1,k
  • By induction, the proof is done.

9
Well Ordering Principle
  • Every non-empty set of positive integers contains
    a smallest element.

10
Well Ordering Principle
  • To prove P is true
  • Assume P is false
  • Then there are set of counter examples
  • C c P(c) is false
  • By WOP, choose the smallest element x in C
  • From x, we get y lt x s.t. P(y) is also false
  • Contradiction!

11
Well Ordering Principle
  • The equation
    has no non-zero positive integer solution

12
Well Ordering Principle - Ans
  • Assume the is solution for the equation
  • By WOP, we pick the solution (u,v,w,x)
    (a,b,c,d) such that (a,b,c,d) has the smallest
    value of u among all the solutions to the
    equation.
  • We get
  • Since all the term of left hand side is even, d
    must be even, so
  • where

13
Well Ordering Principle - Ans
  • Divide both sides by 2 we get
  • Here c must be even, again we can rewrite the
    equation as
  • where
  • Divide both sides by 2 and we get

14
Well Ordering Principle - Ans
  • Apply the same technique to b and a, we will get
  • where
  • Observe that (a,b,c,d) is now another set of
    solution to the equation
    and a lt a
  • This contradicts the claim that (a,b,c,d) is the
    solution set with the smallest value of u
  • The assumption is false, hence the equation has
    no nonzero positive integer solution.

15
Invariant Method
  • Find properties (the invariants) that are
    satisfied throughout the whole process.
  • Show that the target do not satisfy the
    properties.
  • Conclude that the target is not achievable.

16
Invariant Method
  • Integers 1, 2, 3, 4 and 5 are written on a board.
    Tom picks any two of the numbers, deletes them,
    and writes on the board the absolute value of
    their difference. He repeats this procedure with
    the resulting 4 numbers, and so on. After he does
    it 4 times, only one number remains on the board.
    Can this number be 2?

17
Invariant Method - Answer
  • Observe that whatever move you made, you can only
    get an odd number in the final answer.
  • Observe that the total sum of the numbers on the
    board remains odd.
  • Consider a move, you pick m and n on the board,
    and write back m-n.
  • Change in total sum mn-(m-n) 2n
  • Which means whatever move you make, the change in
    total sum must be even
  • The parity of total sum is the invariant
  • Since we start with an odd total sum 15, it is
    not possible have 2 as the final number because
    it is even.

18
Exercises
  • Following exercises can be found in textbook
  • 4.4 4, 15, 18, 22

19
END
Write a Comment
User Comments (0)
About PowerShow.com