Example where convergence in mean does not imply convergence in quadratic mean

examples-counterexamplesprobabilityprobability theory

Is there an example where convergence in mean does not imply convergence in quadratic mean. $E|X_n-X|\rightarrow 0$ but $E|X_n-X|^2 \nrightarrow 0$. It seems like this should be fairly straightforward, but I cannot really come up with an answer. I'd imagine the answer would look something like

$$X_n=\begin{cases}a & \text{with probability } \frac{1}{n} \\\
0& \text{with probability } 1-\frac{1}{n} \end{cases}$$

Best Answer

On $(0,1)$ with Lebesgue measure let $X_n=\sqrt {n} I_{(0,\frac 1 n)}$. Then $E|X_n-0|\to 0$ but $E|X_n-0|^{2}=1$ for all $n$.