This is a homework question about using Master's theorem, and I can't seem to wrap my head around this question:
$$T(n)=2T\left(\frac{n}{3}\right)+\lg^2(n)$$
I've tried to apply the Master's theorem to this question like any other Master's theorem questions: $$a=2,b=3\, \text{ and }\, f(n)=(\lg(n))^2.$$
Now, I need to figure out which case this condition falls into.
$$n^{\lg_b(a)}=n^{\lg_3(2)}=n^{0.631}$$
But the problem is that I cannot express f(n) as a polynomial for comparison as shown below:
$$n^{\lg_b(a)+\epsilon}$$
How would I figure out which case of Master's theorem this lie on?
Would taking logarithms of both sides for comparison make sense since logarithm is a monotonic function?
$$2\cdot \lg(\lg(n)) \quad\text{and} \quad (0.631+\epsilon)\cdot \lg(n)$$
Then figure out what epsilon is ...
Thank you in advance,
kpark
A log-power $(\log n)^k$ is $O(n^c)$ for any $c > 0$. In other words, a power of $\log n$ grows more slowly than any positive power of $n$. (You can show this by evaluating $\lim_{n \to \infty} (\log n)^k / n^c$ using L'Hopital's rule repeatedly.) So you can assume that your additive function $f(n) = (\log n)^2$ satisfies $f(n) = O(n^c)$ for whatever low enough positive $c$ you need to satisfy the conditions of the Master theorem to show that the running time is the smallest possible.