Presentation is loading. Please wait.

Presentation is loading. Please wait.

Strong Induction 2/27/121. Induction Rule 2/27/122.

Similar presentations


Presentation on theme: "Strong Induction 2/27/121. Induction Rule 2/27/122."— Presentation transcript:

1 Strong Induction 2/27/121

2 Induction Rule 2/27/122

3 Strong Induction Rule 2/27/123

4 Fibonacci Numbers Start with a pair of rabbits After 2 months a new pair is born Once fertile a pair produces a new pair every month Rabbits always come in breeding pairs, and never die 2/27/124 http://morrischia.com/david/portfolio/boozy/research/fibona cci's_20rabbits.html

5 Fibonacci Numbers 0, 1, 0+1=1, 1+1=2, 1+2=3, 2+3=5, 3+5=8, … F n+1 =F n +F n-1 (n≥1) F 0 =0 F 1 =1 2/27/125

6 How Many Binary Strings of length n with No Consecutive 1s? 2/27/126 n 0<> 101 200011011 3000001010011100101110111

7 How Many Binary Strings of length n with No Consecutive 1s? 2/27/127 n 0<> 101 200011011 3000001010011100101110111

8 How Many Binary Strings of length n with No Consecutive 1s? 2/27/128 n 0<> 101 200011011 3000001010011100101110111

9 How Many Binary Strings of length n with No Consecutive 1s? 2/27/129 n 0<> 101 200011011 3000001010011100101110111

10 How Many Binary Strings of length n with No Consecutive 1s? 2/27/1210 n 0<> 101 200011011 3000001010011100101110111 1, 2, 3, 5, … ? Are these the Fibonacci numbers?? 0000000100100011 01000101 0110 0111 1000100110101011 1100110111101111

11 C n = #Binary Strings of length n with No Consecutive 1s 2/27/1211 n01234 CnCn 12358 C n = F n+2 ?? Why would that be? Say that a string is “good” if it has no consecutive 1s Why would a “good” string of length n+1 have something to do with good strings of shorter length? n0123456 FnFn 0112358

12 Getting Good Strings of Length n+1 2/27/1212 A good string of length n+1 ends in either 0 or 1. Call this good string x. [Try breaking the problem down into cases] If x ends in 0, the first n digits could be any good string of length n since adding a 0 to the end can’t turn a good string bad There are C n strings like that 0 Good string of length n x

13 Getting Good Strings of Length n+1 2/27/1213 If x ends in 1, the next to last digit must be 0 (otherwise x would end in 11 and be bad) But the previous n-1 digits could be any good string of length n-1. There are C n-1 strings like that Total = C n+1 = C n +C n-1 01 Good string of length n-1 x

14 Proof by Induction that C n =F n+2 2/27/1214 (Base cases) C 0 = 1 = F 0+2 C 1 = 2 = F 1+2 (Induction hypothesis) Assume n≥1 and C m =F m+2 for all m≤n. Need to show that C n+1 = F n+3 Then C n+1 = C n +C n-1 (by previous slide) = F n+2 +F n+1 (by the induction hypothesis) = F n+3 by defn of Fibonacci numbers

15 Finis 2/27/1215


Download ppt "Strong Induction 2/27/121. Induction Rule 2/27/122."

Similar presentations


Ads by Google