This preview shows pages 1–17. 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 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: 2 n for n >= 2 Induction: Base Case: Induction Hypothesis: T(n/2) <= c(n/2) log 2 (n/2) A better mergesort (?) Divide into 3 subarrays and recursively sort Apply 3way merge What is the recurrence? Unroll recurrence for T(n) = 3T(n/3) + dn T(n) = aT(n/b) + f(n) T(n) = T(n/2) + cn Where does this recurrence arise? Solving the recurrence exactly T(n) = 4T(n/2) + cn T(n) = 2T(n/2) + n 2 T(n) = 2T(n/2) + n 1/2 Recurrences Three basic behaviors Dominated by initial case Dominated by base case All cases equal we care about the depth...
View
Full
Document
This note was uploaded on 02/25/2012 for the course CSE 421 taught by Professor Richardanderson during the Fall '06 term at University of Washington.
 Fall '06
 RichardAnderson
 Algorithms, Sort

Click to edit the document details