Is $\log{N}^2$ read as $(\log{N})^2$ or $\log{(N^2)}$?
How can I write $(\log{N})^2$ without using parenthesis?
Is $\log{N}^2$ read as $(\log{N})^2$ or $\log{(N^2)}$?
How can I write $(\log{N})^2$ without using parenthesis?
On
I've seen both. I think most people would say $\log\left(N^2\right)$ is "correct", because in the order of operations, an exponentiation has higher priority than a function application.
However, I have also seen authors write $\log N^2$ and intend $\left(\log N\right)^2$. These authors are avoiding the ugliness of the parentheses in $\left(\log N\right)^2$, and rely on the reader knowing the context of the expression to understand what they mean.
To write $\left(\log N\right)^2$ in a way that doesn't use parentheses and respects the order of operations as I described it above, you only have uglier options: $\log N \log N$ (which is maybe equally problematic without parentheses) or $\log N^{\log N}$.
$\log{N^2}=\log(N^2)$.
$(\log{N})^2=\log^2N$.