How do I go about manipulating this summation equation to solve it?

741 Views Asked by At

In my textbook, Introduction to Algorithms, the following is shown:

enter image description here

And I believe I understand that. However, I have a similar equation to the one on the first line, but instead of $(\frac{3}{16})^i$, I have $\log_2({\frac{n}{2^i})}$.

$\sum\limits_{i=0}^{\log_2{n-1}} \log({\frac{n}{2^i}})$

I'm really confused where I'd go with that difference. How do I deal with the fact it's a logarithm in order to get it down to solving for big-O?

1

There are 1 best solutions below

4
On

You can bound the sum quite coarsely by $\sum\limits_{i=0}^{\log_2{n-1}} \log({\frac{n}{2^i}}) \lt (\log_2 n)(\log n)=O((\log n)^2) $ which is dominated by the other term