next up previous
Next: Example: Up: l2 Previous: Now for the boundary

Making a Good Guess



  1. Guess similar solutions to similar recurrences.

    T(n) = 2T(n/2 + 42) + n

    Guess: T(n) = O(nlgn)



  2. Narrow in on solution using loose upper and lower bounds.

    $\Omega(n)$ $\longrightarrow$ $\Theta(nlgn)$ $\longleftarrow$ O($n^2$)



Problems: Lower-order terms may defeat mathematical induction of substitution method.


next up previous
Next: Example: Up: l2 Previous: Now for the boundary