Thursday 7 September 2017

calculus - Why does $y int_0^infty x^2 e^{-y|x|} , dx=frac 1 {y^2}int_0^infty x^2 e^{-x},dx$?



Find the variance of variance of random variable with pdf $f(x)=\frac \lambda 2 e^{-\lambda|x|}$




Solution:
$\operatorname E(X)$ is zero because density is even.
$$\operatorname{Var}X=\operatorname E(X^2)=\int x^2 f(x)\,dx=\lambda \int_0^\infty x^2e^{-\lambda|x|} \, dx=\frac 1 {\lambda^2}\int_0^\infty x^2 e^{-x} \, dx$$



Confusion:




  1. So $\operatorname E(X)$ is zero because density is even means that because pdf is an even function? So for even functions, when we integrate from negative $\infty$ to positive $\infty$ we get $0$? I forgot calculus so can anyone write out the full function of $\operatorname E(X)$ for me?




2.Why does $\lambda \int_0^\infty x^2 e^{-\lambda|x|} \, dx=\frac 1 {\lambda^2}\int_0^\infty x^2 e^{-x} \, dx$? Is there something from calculus I totally forgot about that relates to this?




  1. I did some research and the generalizaion of $\lambda \int_0^\infty x^p e^{-\lambda|x|} \, dx=\frac 1 {\lambda^p}\int_0^\infty x^p e^{-x} \, dx = \frac 1 {\lambda^p} \gamma(p+1)$ with $\gamma(p+1)$ being the gamma function. Can anyone explain the gamma function here being equal to integral of $x^p e^{-x}$?


Answer



You have
$$
\operatorname E(X) = \int_{-\infty}^\infty xf(x)\, dx
$$

provided $$\int_0^\infty xf(x)\,dx <+\infty \text{ and } \int_{-\infty}^0 xf(x)\,dx >-\infty. \tag 1$$



If $(1)$ holds, then
$$
\int_{-\infty}^\infty xf(x)\, dx = \lim_{a\,\to\,\infty} \int_{-a}^a xf(x)\,dx.
$$
If $f$ is an even function then $x\mapsto xf(x)$ is an odd function; i.e. $(-x)f(-x) = -\big( xf(x)\big).$ Thus we have
\begin{align}
\int_{-a}^0 xf(x)\,dx & = \int_a^0 (-w)f(-w) (-dw) \quad \text{where } w=-x \\[10pt]
& = \int_a^0 (-w) f(w) (-dw) \quad \text{because $f$ is even} \\[10pt]

& = \int_a^0 wf(w)\,dw \\[10pt]
& = -\int_0^a wf(w)\,dw \\[10pt]
& = -\int_0^a xf(x)\,dx \quad \text{because $w$ and $x$ are bound variables.}
\end{align}
Therefore
$$
\int_{-a}^a xf(x) \,dx = 0
$$
and thus $\lim\limits_{a\,\to\,\infty}$ of that integral is $0.$




\begin{align}
\lambda \int_0^a x^2 e^{-\lambda x} \, dx = \lambda \cdot \frac 1 {\lambda^3} \int_0^a (\lambda x)^2 e^{-\lambda x} (\lambda\, dx) = {} & \frac 1 {\lambda^2} \int_0^{\lambda a} u^2 e^{-u} \, du & & \text{where } u = \lambda x \\
& & & \text{and thus } du = \lambda\,dx \\[12pt]
= {} & \frac 1 {\lambda^2} \int_0^{\lambda a} x^2 e^{-x} \, dx
\end{align}
and then let $a\to\infty.$


No comments:

Post a Comment

real analysis - How to find $lim_{hrightarrow 0}frac{sin(ha)}{h}$

How to find $\lim_{h\rightarrow 0}\frac{\sin(ha)}{h}$ without lhopital rule? I know when I use lhopital I easy get $$ \lim_{h\rightarrow 0}...