E(|X|) for a normal r.v

6.1k Views Asked by At

I struggle with absolute value. Here I need to find $\mathbb{E}[X^4]$ and $\mathbb{E}[|X|]$ knowing that $X$ is a normally distributed random variable with zero mean and variance $\sigma^2$.

I know the pdf of the normal r.v. and the way to compute $\mathbb{E}[X^4]$:

$$\mathbb{E}[X^4]=\int x^4 f_X(x) dx$$

But how should I handle the absolute sign when I compute:

$$\int \mid x \mid f_X(x) dx $$

I understand I should divide the integral into the part from $-\infty$ to $0$ and 0 to $\infty$ and take that into account, but how ?

2

There are 2 best solutions below

2
On BEST ANSWER

Hint: $$ \int_{-\infty}^{+\infty}|x|f_X(x)\,dx= -\int_{-\infty}^0xf(x)\,dx+\int_0^{+\infty}xf(x)\,dx$$ this follows simply by definition of the absolute value.

3
On

Another way

Set $Y=|X|$ we have \begin{align*} G_Y(y)&=\mathbb{P}(Y\le y)\\ &=\mathbb{P}(\,|X|\le y\,)\\ &=\mathbb{P}(-y\le X\le y)\\ &=F_X(y)-F_X(-y) \end{align*}

Therefore

$$g_Y(y)=f_X(y)+f_X(-y)$$ In other words \begin{align*} g_Y(y)=\begin{cases} \frac{2}{\sqrt{2\pi}}e^{-\frac 12 y^2}\, &,\,y>0\\ 0 &,\text{o.w} \end{cases} \end{align*} thus

$$\mathbb{E}[|X|]=\mathbb{E}[Y]=\frac{2}{\sqrt{2\pi}}\int_{0}^{\infty}ye^{-\frac 12 y^2}dy$$