Why is $\ln(x^x)=x\ln(x)$ valid? I know that $\ln(x^k)=k\ln(x)$ for any constant $k$, but why is $\ln(x^x)=x\ln(x)$. The exponent $x$ is not constant.

The general rule for logarithms is $\log(a^b)=b\log(a)$ for any real numbers $a$ and $b$ (as long as $a$ is positive).  In particular, it holds when $a=b=x$ (assuming, again, that $x$ is positive).
