Comment
Share
Q)

Find the mean and variance for the following probability density functions $f(x) = \left\{ \begin{array}{l l} \alpha e^{-\alpha x} ,& \quad \text{if$x$$>$$0$}\\ 0 ,& \quad \text{otherwise} \end{array} \right.$

Comment
A)
Toolbox:
• Let X be a continuous random variable with probability density function f(x). Then the mathematical expectation of X is defined as $E(X)=\int_{-\infty}^\infty x f(x)dx$
• $E(\phi (X))=\int_{\infty}^{\infty}\phi(x) f(x)dx$
• Var$(X)=E(X^2)-[E(X)]^2$
• $E(c)=c$
• $E(aX\pm b)=aE (X)\pm b$
Step 1:
$E(X)=\int_{-\infty}^\infty x f(x) dx$
$\qquad=\int_0^\infty x\alpha e^{-\alpha x}dx$
$\qquad=\alpha\bigg[x\large\frac{e^{\Large -\alpha x}}{-\alpha}-$$1.\large\frac{e^{\Large -\alpha x}}{\alpha^2}\bigg]_0^{\infty}$
$\qquad=\large\frac{1}{\alpha}$
Mean =$\large\frac{1}{\alpha}$
Step 2:
$E(X^2)=\int_{\infty}^\infty x^2f(x)dx$
$\qquad=\int_0^{\infty} x^2e^{-\alpha x} dx$
Here $u=x^2$
$u'=2x$
$v=\large\frac{e^{\Large -\alpha x}}{-\alpha}$
$u''=2$
$v_1=\large\frac{e^{\Large-\alpha x}}{\alpha^2}$
$v_2=\large\frac{-e^{\Large-\alpha x}}{\alpha^3}$
$E(X^2)=uv-u'v_1+u''v_2\bigg]_0^\infty$
$\qquad\;\;=\large\frac{-x^2e^{\Large-\alpha x}}{\alpha}-\frac{2xe^{\Large-\alpha x}}{\alpha^2}-\frac{2e^{\Large-\alpha x}}{\alpha^3}\bigg]_0^\infty$
$\qquad\;=\large\frac{2}{\alpha^3}$
Step 3:
$Var(X)=E(X^2)-[E(X)]^2$
$\qquad\quad=\large\frac{2}{\alpha^3}-\large\frac{1}{\alpha^2}$