Consider the random variable  $X$  with the following probability density function $$f(x) = \begin{cases} \frac{1}{18}(6-x), & 0\leq x\leq 6\\ 0,& \text{otherwise.} \end{cases}$$ (a) Compute $E(X)$.
(b) Compute $\operatorname{Var}(X)$.

I'm not sure what approach I should be using to get this answer. What is the method to get the final solutions for this answer?

For (b) I did

$\int^6_0\frac{1x^2}{18}(6-x)dx-6$ and plugged it into my calculator to get $0$ where did I got wrong?

  • $\begingroup$ Please use MathJax to accurately present your problem. $\endgroup$ – Em. Apr 3 '17 at 4:24
  • $\begingroup$ @Kate.K, in your edit you subtract the $\text{E}(X^2)$ from itself. We have that $\text{E}(X^2) = 6$, and $\text{E}(X) = 2$. Remember $\text{Var}(X) = \text{E}(X^2) - [\text{E}(X)]^2$. Notice the distinction between the two terms in the expression for variance. $\endgroup$ – Philip Apr 3 '17 at 4:55

These formulas will be useful. However, try adjusting the limits of $\text{E}(X)$ to better suit your PDF.

$$\text{E}(X) = \int_{\infty}^{- \infty} xf(x) dx$$

$$\text{Var}(X) = \text{E}(X^2) - [\text{E}(X)]^2$$

As a little side note, the $\text{E}(X)$ notation for the expected value is really just an instruction to multiply the the PDF by $x$, and integrate over all values of the random variable. The $\text{E}(X^2)$ notation is similar, except we just use $x^2$ instead.

| cite | improve this answer | |
  • $\begingroup$ Okay, I used this approach and got a right but b wrong. I got a=2 and b=0 $\endgroup$ – Kate.K Apr 3 '17 at 4:40
  • $\begingroup$ I'll be posting my working for b $\endgroup$ – Kate.K Apr 3 '17 at 4:40
  • $\begingroup$ Good idea :) @Kate.K $\endgroup$ – Philip Apr 3 '17 at 4:41
  • $\begingroup$ Just added the update $\endgroup$ – Kate.K Apr 3 '17 at 4:52
  • $\begingroup$ I've added my response as a comment to your question. Let me know if you still need some clarification. $\endgroup$ – Philip Apr 3 '17 at 4:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.