Suppose there is a random variable $X$ which is defined as follows:$$X=k\times log(Y)$$ where Y is distributed uniformly on the $[0,1]$ interval and $k$ is a negative real number. I want to calculate the mean of X. I take expectations on both sides:$$E[X]=E[klog(Y)]$$ $$=kE[log(Y)]$$ $$=k[\int_{0}^{1}log(y)f(y)dy]$$ and using the fact that $f(y)=1$ , we obtain the definite integral:$$=k[xlog(x)-x\}_{0}^{1}]$$ which does not exist because $log(0)$ is undefined. How do I procoeed?
1 Answer
$\begingroup$
$\endgroup$
Because
$$ \lim_{x \rightarrow 0} \ x \log(x) = 0 $$
it is convention to define $0 \times \log(0) = 0$. Therefore, the integral equals $-k$.