PR4 - Theorem 1 If M(n c log(n and c > 0 then T(n = O(n where T(n = 2T Proof T(n = 2T n M(n 2 n < 2T c log n 2 n n < 2 2T 2 c log c log n 2 2 < n n

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
Theorem 1. If M ( n ) c log( n ) and c > 0 , then T ( n ) = O ( n ) , where T ( n ) = 2 T n 2 · + M ( n ) . Proof. T ( n ) = 2 T n 2 · + M ( n ) < 2 T n 2 · + c log n < 2 2 T n 2 2 · + c log n 2 ·· + c log n < . . . < 2 k T n 2 k · + c 2 k - 1 log n 2 k - 1 + 2 k - 2 log n 2 k - 2 + ··· + 2 log n 2 + log n · , if n = 2 k = nT (1) + c ˆ log 2 k · 2 k - 1 + k · 2 k - 2 + ··· + k 2 ( k - 1) · 2 k - 1 +( k - 2) · 2 k - 2 + ··· +1 · 2 1 ! = nT (1) + c log 2 ( k · 2 k - 1 + k · 2 k - 2 + ··· + k ) - (
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/04/2010 for the course COMPUTER S cs300 taught by Professor Unkown during the Spring '08 term at Korea Advanced Institute of Science and Technology.

Ask a homework question - tutors are online