Professional Documents
Culture Documents
Name: Solution
Andrew ID:
Section:
Answer the questions clearly in the space provided following each question. Be sure to read the
directions to each question carefully. You have 20 minutes. Good Luck!
Assume for sake of contradiction that T (n) = O(f (n)). Then, there must exist some
constants c, n0 > 0 such that ∀n > n0 , n2 − 1 ≤ c. Let N = max{c + 1, n0 } + 1. Because
N > n0 , N 2 − 1 ≤ c, so N 2 ≤ c + 1. However, N > c + 1 and N > 0, so N 2 > c + 1. We
have a contraction, so no such c, n0 could exist, so T (n) 6= O(f (n)).
(10) (b) Prove that T (n) = Ω(f (n)). Be sure to provide any constants in the asymptotic definitions.
T (n) = Ω(f (n)) if and only if there exists some constant c, n0 > 0 such that ∀n > n0 ,
n2 − 1 ≥ c. Let c = 3 and n0 = 1. Thus, n ≥ 2, so n2 ≥ 4, so n2 − 1 ≥ 3 = c. Thus,
T (n) = Ω(f (n)).
T (n) = Θ(f (n)) if and only if T (n) = Ω(f (n)) and T (n) = O(f (n)). However, by part a,
T (n) 6= O(f (n)), so T (n) 6= Θ(f (n)).
15-211 Quiz 1 Page 2 of 2
2. Big-Oh Multiple Choice : Circle ALL answers that apply, not just the tightest bounds.
(15) (a) T (n) = 2 log n + 32n log n