4

(1) How should I parenthesize $\log n \log \log n$? Also: (2) What general rule/rationale is used to do this parenthesization?

To elaborate; I see why $\log\log n$ is unambiguous, but $\log n \log ...$ could mean at least 2 different things:

$\log(n\log(...))$

... or:

$\log(n)*\log(...)$

How do I best decide which one the author intended?

mormegil
  • 141
  • 3
    You're right it's ambiguous, but $\log(n)\cdot \log(\log(n))$ is always what is meant. – MJD Nov 06 '14 at 00:57
  • Wow, that was crazy fast. Why don't you post that as an answer so I can upvote you for it? – mormegil Nov 06 '14 at 00:58
  • 3
    Similar to reading $\cos x \sin y$ as $\cos(x)\times\sin(y)$ instead of $\cos (x \sin (y))$ it is generally safe to interpret such constructs as products rather than convolutions. It is what is usually meant. – Graham Kemp Nov 06 '14 at 01:06
  • Because without seeing the expression in context, I'm not certain I am correct. – MJD Nov 06 '14 at 01:14
  • 1
    Since $\log (n\log\log n) = \log n + \log\log\log n$, it is better to assume the one that cannot be written another way. Especially if this is a "big-O" approximation, since $O(\log n + \log\log\log n) = O(\log n)$. – Thomas Andrews Nov 06 '14 at 01:15
  • For context, I took the subexpression from the end of this section on the computation of the Factorial function: http://en.wikipedia.org/wiki/Factorial#Computation so it is in the context of "big-O". Thanks for the insight @ThomasAndrews! – mormegil Nov 06 '14 at 01:50

0 Answers0