In this tutorial you are shown the formulae that are used to calculate the mean, E(X) and the variance Var(X) for a continuous random variable by comparing the results for a discrete random variable. There is a brief reminder of what a discrete random variable is at the start.

Example

In this next example you are asked to calculate the mean and variance of a continuous random variable. Again it would be a good one to try first and then check your work against the worked solution. I would strongly suggest looking at the video anyway as there is a simple way of finding the mean for this example which you should be aware of.

A continuous random variable X has a probability density function f(x) given by

f\left( x \right) = \left\{ \begin{array}{l} \frac{3}{4}\left( {1 - x} \right)\left( {x - 3} \right),{\rm{      }}1 \le x \le 3\\ 0,{\rm{                            otherwise}} \end{array} \right.

Find the mean E(X) and the variance Var(X).