Continuous random variables
A continuous random variable is the variable whose probability is distributed over an interval. If
f (x) is the probability density function for a continuous random variable X over an interval
a ≤ x ≤ b, then it can be shown on a graph as in Figure below,
From calculus, the area A under the curve bounded by the x-axis, x=a, and x=b is given by
b
A=∫ f (x ) dx . This area serves as the probability of a continuous random variable. Hence, it
a
should add up to 1.
b
Thus,∫ f (x )dx =1.
a
This is the necessary condition for f(x) to be a probability density function of a continuous
random variable. Thus, if x is an event that lies between x1 and x2, then
1. A continuous random variable X is defined by f (x), where f (x) = kx for 0 ≤ x ≤ 4. Find
(
the value of k and P 1 ≤ x ≤ )
1
2
2. A continuous random variable X is defined by the following probability density function:
3. A continuous random variable X has a p.d.f defined by
4. Show that f (x) is a probability density function of a random variable X , hence find the
value of the constant c, if:
5. A random variable X has the probability density function
Expectation of a continuous random variable
Recall the expectation of a discrete random variable X. If X is a continuous random variable
under an interval, then
Examples:
1. Find the expectation if a continuous random variable has a probability density function
2
3x
f ( x )= , 0≤ x≤4
64
3
2. A continuous random variable has a p.d.f defined by f ( x )= ( x−5)(3−x ), 3 ≤ x ≤ 5.
4
Find the expectation value.
3. A secondary school teacher asked her, class to guess her height in meters. The teacher
considered that the height guessed by a randomly selected student can be modeled by the
random variable Y with probability density function defined by
Use the model to find the expectation value.
4. A random variable X has a probability density function f (x) = cx (6 - x)2 , for 0 ≤ x ≤ 6.
Find the constant c and the expectation value.
If g(x) is any function of continuous random variable X with p.d.f f(x), then from
∞ ∞
E [ X ] = ∫ xf ( x ) dx , It follow that E [ g( x ) ] =∫ g (x)f ( x ) dx ,
−∞ −∞
Examples:
1. A continuous random variable defined by g(x) = x 2 has p.d.f
1
f ( x )= ( x +3 ) for 0 ≤ x ≤ 4 . Find the expected value.
20
2. If g(x) = 2x −1 is a function of a continuous random variable whose p.d.f is defined
x
by f ( x )= for 0 ≤ x ≤ 4 . Find the expected value.
8
Variance and standard deviation of a continuous random
variable
Suppose g(x) = x is a function of a continuous random variable with probability density function
f (x), then
Which can also be written as
Find the variances and standard deviation of all the above examples.