-1
$\begingroup$

How do you multiply the following logs... $$\log_5(n) * \log_2(n)$$

$\endgroup$
5
  • 2
    $\begingroup$ Looks like you're multiplying them just fine? $\endgroup$
    – GFauxPas
    Apr 26, 2015 at 20:09
  • $\begingroup$ In this problem I have I get something like this $$5^{\log_5(n)}$$ which is $n$ but I'm not sure what to do because I get \log_5(n) * \log_2(n) $\endgroup$
    – MD_90
    Apr 26, 2015 at 20:10
  • 2
    $\begingroup$ What's the original problem? $\endgroup$
    – littleO
    Apr 26, 2015 at 20:11
  • $\begingroup$ it's an asymptotics problem where we need to find $\Theta()$ of the following $T(n) = T(\frac{n}{5}) + \log_2(n)$ $\endgroup$
    – MD_90
    Apr 26, 2015 at 20:20
  • $\begingroup$ it's not that I can't do it I'm just stuck if I need to find an upper and lower bound to find theta or just do the canceling to end up with n, n-1, n-2, ... and more inside the logs making this run in constant time $\endgroup$
    – MD_90
    Apr 26, 2015 at 20:28

1 Answer 1

6
$\begingroup$

Notice that $$\log_x(y) = \frac{\log y}{\log x}$$ therefore $$\log_5(n) \log_2(n) = \frac{(\log(n))^2}{\log 5\log 2} \approx \frac{(\log(n))^2}{1.1156}$$ This is a "simplification" if $\log n$ is easy to compute, or you need some certain manipulation. However, sometimes $\log_2(n)$ or $\log_5(n)$ are easy to compute.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.