4

Who can explain to me why $$T (n) = 4T (n/2) + n/ \log n \Longrightarrow T (n) = Θ(n^2) \tag{Case 1}$$

But for $$T (n) = 2T (n/2) + n/ \log n$$ ⇒ Master Theorem does not apply (non-polynomial difference between $f(n) = n^{\log_ba}$)

YohanRoth
  • 1,437

1 Answers1

2

As you can see $O(n^2)$ is at least $n$ times bigger than $O(\frac{n}{logn})$ so we can say there is a polynomial difference ( a difference measured in $n^k$).

For the second it doesn't apply because its $O(n)$ and $O(n/logn)$ the difference is not $n^k$. The difference is only $logn$ but master theorem apply only for polynomial, the difference here is not polynomial but logarithmic

  • Can you pls give more details? it is not fully clear to me.... (n/logn)/n^2 = 1/nlogn (n/logn)/n = 1/logn

    so... what should I get from this?

    – YohanRoth May 10 '15 at 21:15