# Difference of two random variables and convergence

I have a question concerning this task:

Let $X$ be a random variable and $X_n=X+Y_n$ where $$E[Y_n]=\frac{1}{n}\quad\text{ and }\quad\operatorname{Var}(Y_n)=\frac{\sigma^2}{n}\quad \text{where }\sigma>0$$ Show that $X_n\xrightarrow{P}X$

Now I know that I can prove this by using the Chebyshev inequality, but can I also do it with the Markov inequality, meaning is this correct:

$$\lim\limits_{n\to \infty}P(|X_n-X|\geq \epsilon)=\lim\limits_{n\to \infty}P(|X+Y_n-X|\geq \epsilon)$$ $$=\lim\limits_{n\to \infty}P(|Y_n|\geq \epsilon)\leq \lim\limits_{n\to \infty}\frac{E[|Y_n|]}{\epsilon}= \lim\limits_{n\to \infty} \frac{1}{n\epsilon}=0$$

Here I came across $X-X$ and since both are random variables, I don't know if I can just cancel them? Is this correct?

The expected value of $Y_n$ is equal to $1/n$ ($\operatorname EY_n=1/n$), not the first absolute moment. We cannot say that $\operatorname EY_n=\operatorname E|Y_n|$. Hence, the last step in your proof is not justified.
However, we can use Lyapunov's inequality (which follows from Jensen's inequality) to conclude the proof. We have that $$\operatorname E|Y_n|\le(\operatorname EY_n^2)^{1/2}=(\operatorname {Var}Y_n+(\operatorname EY_n)^2)^{1/2}=\biggl(\frac{\sigma^2}n+\frac1{n^2}\biggr)^{1/2}.$$
• Thank you. But what about $X-X=0$, can I just subtract two random variables like that or is this not correct? Jul 6, 2016 at 15:21
• @MarcE You're welcome! Yes, we can subtract two random variables like that. Strictly speaking, a random variable is a measurable function $X:\Omega\to\mathbb R$, where $(\Omega,\mathcal F,P)$ is the probability space. The difference of two random variables $X$ and $Y$ defined on the same probability space is given by $X(\omega)-Y(\omega)$ for each $\omega\in\Omega$ (let us observe that $X(\omega)$ and $Y(\omega)$ are just real numbers). If $X(\omega)=Y(\omega)$, then $X(\omega)-Y(\omega)=0$ for each $\omega\in\Omega$ which is what we use in the proof. Jul 6, 2016 at 15:39