

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


(a) Core of computer science; of the youngest of math disciplines (b) Definitions / Purposes (c) An algorithm is good, bad, better than, best, or worst – how? In terms of what? (d) Today: Functions & Rates of Growth (O, Θ, and Ω)
Let n, c, c 1 , c 2 be positive integers Let all functions be of non-negative range
(a) T (N) = O(f (N)) iff ∃c, ∃n :: ∀N > n, T (N) ≤ c · f (N) (b) T (N) = Ω(g(N)) iff ∃c, ∃n :: ∀N > n, T (N) ≥ c · g(N) (c) T (N) = Θ(h(N)) iff ∃c 1 , ∃c 2 , ∃n :: ∀N > n, T (N) ≤ c 1 · h(N) and T (N) ≥ c 2 · h(N), or (c) T (N) = Θ(h(N)) iff T (N) = O(h(N)) and T (N) = Ω(h(N)) (d) T (N) = o(p(N)) iff T (N) = O(p(N)) and T (N) 6 = Θ(p(N))
(a) Recurrence relation formation; example: Fibonacci (b) Solving: three general methods: substitution, iteration, “master” i. Substitution: