This preview shows pages 1–10. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: 201ICS 141: Discrete Mathematics I (Spr 2008University of HawaiiICS141: Discrete Mathematics for Computer Science IDepartment of Information and Computer SciencesUniversity of HawaiiStephen Y. Itoga202ICS 141: Discrete Mathematics I (Spr 2008University of HawaiiLecture 20Chapter 4. Induction and Recursion4.3 Recursive Definitions and Structural Induction4.4 Recursive Algorithms203ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiSome material in these slides were taken/adapted from the slides made by Prof. Michael P. Frank and Prof. Jonathan L. Gross which are provided through the publisher of Discrete Mathematics and Its Applications written by Kenneth H. Rosen.Some slides were done by Prof. Baek.204ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiRecursive DefinitionsIn induction, we proveall members of an infinite set satisfy some predicate Pby:proving the truth of the predicate for larger members in terms of that of smaller members.In recursive definitions, we similarly definea function, a predicate, a set, or a more complex structure over an infinite domain (universe of discourse) by:defining the function, predicate value, set membership, or structure of larger elements in terms of those of smaller ones.In structural induction, we inductively prove properties of recursivelydefined objects in a way that parallels the objects own recursive definitions.205ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiThe Fibonacci NumbersThe Fibonacci numbersfn0is a famous series defined by:f= 0, f1= 1, fn2= fn1+ fn211235813206ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiInductive Proof about Fibonacci NumbersTheorem: fn<2n.Proof:By inductionBase cases: f= 0 <2= 1f1= 1 <21= 2Inductive step: Use 2ndprinciple of induction Note use of base cases ofrecursive definitionImplicitly for all nN207ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiA Lower Bound on Fibonacci NumbersTheorem.For all integers n3, fnn2, where = (1+51/2)/2 1.61803.Proof.(Using strong induction.)Let P(n) = (fnn2).Base cases: For n=3, note thatn2=<2 = f3. For n=4, n2=2= (1+251/2+5)/4 = (3+51/2)/2 2.61803 <3 = f4.Inductive step: For k4, assume P(j) for 3jk, prove P(k+1). fk+1= fk+ fk1k2+ k3(by 208ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiMore Easy ExamplesWrite down recursive definitions for:i+n(iinteger, nnatural) using only s(i) = i+1.an(areal, nnatural) using only additionan(areal, nnatural) using only multiplication0inai(for an arbitrary series of numbers {ai})0inai (for an arbitrary series of numbers {ai})0inSi(for an arbitrary series of sets {Si})209ICS 141: Discrete Mathematics I (Spr 2008)University of HawaiiRecursively Defined SetsAn infinite set Smay be defined recursively, by giving:A small finite set of baseelements of S....
View
Full
Document
This note was uploaded on 09/12/2008 for the course ICS 141 taught by Professor Idk during the Fall '08 term at Hawaii.
 Fall '08
 IDK

Click to edit the document details