Chapter 4
4.1
Probability density function:
For a continuous random variable X, a probability density function is a function such that
1. F ( x)≥0
∞
2. ∫ f ( x ) dx=1
−∞
b
3. P ( a ≤ X ≤ b )=∫ f ( x ) dx = area under f(x) from a to b for any a and b
a
If X is a continuous random variable, for any x1 and x2,
P ( x 1 ≤ X ≤ x 2 ) =P ( x 1< X ≤ x 2 )=P ( x 1 ≤ X < x 2 )=P(x 1< X < x 2)
Example
−x
f ( x ) ¿ e for 0< x
∞
a. P ( 1< x )=∫ e−x dx=[−e−x ]=e−1 =0.2858
1
2.5
P ( 1< x<2.5 )=∫ e dx=[−e ]=e −e
−x −x −1 −2.5
b. =0.2037
1
4
P ( x< 4 )=∫ e dx=[−e ]=1−e =0.9817
−x −x −4
c.
0
x
P ( X < x )=0.10 →∫ e dx=[−e ]=1−e =0.10→ x=−ln ( 0.9 )=0.1054
−x −x −x
d.
0
4.2
The cumulative distribution function of a continuous random variable is
x
F ( x )=P ( X ≤ x ) =∫ f ( u ) du for−∞ < x <∞
−∞
Probability density function from the cumulative distribution function
dF (x )
Given F(x), f ( x )= as long as the derivative exists
dx
Example
{
0 x <0
F ( x )= 0.25 x 0 ≤ x< 5
1 5≤ x
a. P ( x<2.8 )=P( x ≤2.8) because X is a continuous random variable.
Then, P( X< 2.8)=F(2.8)=0.2(2.8)=0.56
b. P ( x>5 )=1−P ( x ≤ 1.5 )=1−0.2 ( 1.5 )=0.7
c. P ( X ←2 )=Fx (−2 )=0
, d. P ( x> 6 )=1−Fx ( 6 )=0
4.3
The mean or expected value of X, denoted as u or E(X) is
∞
μ= E ( X )= ∫ f ( u ) du for−∞ < x< ∞
−∞
The variance of X, denoted as V(X) or σ2 is
∞
σ =V ( X )= ∫ ¿ ¿
2
−∞
The standard deviation of X is σ =√ σ 2
Expected value of a function of a continuous random variable
E¿
Example
2
f ( x )=1.5 x for−1< x< 1
[ ]
1 4
x
a. E ( X ) =∫ 1.5 x dx= 1.5
3
=0
−1 4
1
b. V ( X )=∫ 1.5 x ¿ ¿
3
−1
4.4
Continuous uniform distribution
A continuous random variable X with a probability density function
1
f ( x )= a≤x ≤b
( b−a )
Is a continuous uniform random variable
Mean and variance
If X is a continuous uniform random variable over a ≤ x ≤ b
a+b 2
μ= E ( X )= ∧σ =V ( X )=¿ ¿
2
Example
Uniform distribution over the interval [-1,1]
−1+1
a. E ( X ) =
2
V ( X )=¿ ¿
σ =0,577
x
1
b. P (−x< X < x )=0.90 → ∫ dt= [ 0,5 t ] =0.5 ( 2 x ) =x
−x 2
, {
0 x←1
c. Cumulative distribution function: F ( x ) = 0.5 x+ 5−1 ≤ x <1
1 1≤ x
4.5
Normal distribution
A random variable X with probability density function
1
f ( x )= e−¿¿¿
√2 π σ
Is a normal random variable with parameters μ where−∞< μ< ∞∧σ >0
Also, E ( X ) =μ∧V ( X ) =σ 2
And the notation N( μ , σ 2) is used to denote the distribution
Standard normal random variable
A normal random variable with μ=0 and σ2=1 is called a standard normal random variable and is
denoted as Z.
The cumulative distribution function of a standard random variable is denoted as
Ф ( z )=P(Z ≤ z)
Standardizing a normal random variable
If X is a normal variable with E(X)=μ and V(X)=σ 2, the random variable
X−μ
Z= is a normal random variable with E(Z)=0 and V(Z)=1.
σ
That is, Z is a standard normal random variable
Standardizing to calculate a probability
Suppose that X is a normal random variable with mean μ and variance σ 2. Then,
P ( X ≤ x )=P ( X−μ
σ
≤
σ )
x−μ
=P (Z ≤ z ) where Z is a standard normal random variable, and
x−μ
z= is the z-value obtained by standardizing X.
σ
x−μ
The probability is obtained by using Appendix table III with z=
σ
Example
X is normally distributed with a mean of 10 and a standard deviation of 2
a) P(X < 13) = P(Z < (13-10)/2) = P(Z < 1.5) = 0.93319
b) P(X > 9) = 1 - P(X < 9) = 1 - P(Z < (9-10)/2) = 1 - P(Z < -0.5) = 0.69146
c) P(6 < X < 14) = = P(-2 < Z < 2) = P(Z < 2) -P(Z < - 2)]= 0.9545
d) P(2 < X < 4) = = P(-4 < Z < -3) = P(Z < -3) - P(Z < -4) = 0.00132
e) P(-2 < X < 8) = P(X < 8) - P(X < -2) = = P(Z < -1) - P(Z < -6) = 0.15866
4.6
Normal approximation to the binomial distribution
, If X is a binomial random variable with parameters n and p,
X−np
Z= is approximately a standard normal random variable.
√np (1− p)
To approximate a binomial probability with a normal distribution, a continuity correction is applied
as follows:
(
P ( X ≤ x )=P ( X ≤ x+ 0.5 ) ≈ P Z ≤
x+ 0.5−np
√ np ( 1− p ) )
And
P ( x ≤ X )=P( x−0.5 ≤ X) ≈ P
(
x−0.5−np
√ np ( 1− p )
≤Z
)
The approximation is good for np> 5∧n (1− p)> 5
Normal approximation to the Poisson distribution
If X is a Poisson random variable with E(X)=λ and V(X)=λ,
X−λ
Z= is approximately a standard normal random variable.
√λ
The same continuity correction used for the binomial distribution can also be applied.
The approximation is good for λ>5
Example
X is a binomial random variable with n=200 and p=0.4
a) E(X) = 200(0.4) = 80, V(X) = 200(0.4)(0.6) = 48 and σ X =√ 48
Then,
P( X≤70)≃P Z≤
√ (
70. 5−80
48 )
=P( Z≤−1. 37 )=0 . 0853
P(70<X <90)≃P
√ 48 (
70 .5−80
<Z≤
89 . 5−80
√ 48
=P(−1 . 37<Z≤1. 37 )
)
b) =0 .9 1466-0 . 08534=0 . 8293
c)
4.7
Exponential distribution
The random variable X that equals the distance between successive events from Poisson process with
mean number of events λ>0 per unit interval is an exponential random variable with parameter λ.
The probability density function of X is,
4.1
Probability density function:
For a continuous random variable X, a probability density function is a function such that
1. F ( x)≥0
∞
2. ∫ f ( x ) dx=1
−∞
b
3. P ( a ≤ X ≤ b )=∫ f ( x ) dx = area under f(x) from a to b for any a and b
a
If X is a continuous random variable, for any x1 and x2,
P ( x 1 ≤ X ≤ x 2 ) =P ( x 1< X ≤ x 2 )=P ( x 1 ≤ X < x 2 )=P(x 1< X < x 2)
Example
−x
f ( x ) ¿ e for 0< x
∞
a. P ( 1< x )=∫ e−x dx=[−e−x ]=e−1 =0.2858
1
2.5
P ( 1< x<2.5 )=∫ e dx=[−e ]=e −e
−x −x −1 −2.5
b. =0.2037
1
4
P ( x< 4 )=∫ e dx=[−e ]=1−e =0.9817
−x −x −4
c.
0
x
P ( X < x )=0.10 →∫ e dx=[−e ]=1−e =0.10→ x=−ln ( 0.9 )=0.1054
−x −x −x
d.
0
4.2
The cumulative distribution function of a continuous random variable is
x
F ( x )=P ( X ≤ x ) =∫ f ( u ) du for−∞ < x <∞
−∞
Probability density function from the cumulative distribution function
dF (x )
Given F(x), f ( x )= as long as the derivative exists
dx
Example
{
0 x <0
F ( x )= 0.25 x 0 ≤ x< 5
1 5≤ x
a. P ( x<2.8 )=P( x ≤2.8) because X is a continuous random variable.
Then, P( X< 2.8)=F(2.8)=0.2(2.8)=0.56
b. P ( x>5 )=1−P ( x ≤ 1.5 )=1−0.2 ( 1.5 )=0.7
c. P ( X ←2 )=Fx (−2 )=0
, d. P ( x> 6 )=1−Fx ( 6 )=0
4.3
The mean or expected value of X, denoted as u or E(X) is
∞
μ= E ( X )= ∫ f ( u ) du for−∞ < x< ∞
−∞
The variance of X, denoted as V(X) or σ2 is
∞
σ =V ( X )= ∫ ¿ ¿
2
−∞
The standard deviation of X is σ =√ σ 2
Expected value of a function of a continuous random variable
E¿
Example
2
f ( x )=1.5 x for−1< x< 1
[ ]
1 4
x
a. E ( X ) =∫ 1.5 x dx= 1.5
3
=0
−1 4
1
b. V ( X )=∫ 1.5 x ¿ ¿
3
−1
4.4
Continuous uniform distribution
A continuous random variable X with a probability density function
1
f ( x )= a≤x ≤b
( b−a )
Is a continuous uniform random variable
Mean and variance
If X is a continuous uniform random variable over a ≤ x ≤ b
a+b 2
μ= E ( X )= ∧σ =V ( X )=¿ ¿
2
Example
Uniform distribution over the interval [-1,1]
−1+1
a. E ( X ) =
2
V ( X )=¿ ¿
σ =0,577
x
1
b. P (−x< X < x )=0.90 → ∫ dt= [ 0,5 t ] =0.5 ( 2 x ) =x
−x 2
, {
0 x←1
c. Cumulative distribution function: F ( x ) = 0.5 x+ 5−1 ≤ x <1
1 1≤ x
4.5
Normal distribution
A random variable X with probability density function
1
f ( x )= e−¿¿¿
√2 π σ
Is a normal random variable with parameters μ where−∞< μ< ∞∧σ >0
Also, E ( X ) =μ∧V ( X ) =σ 2
And the notation N( μ , σ 2) is used to denote the distribution
Standard normal random variable
A normal random variable with μ=0 and σ2=1 is called a standard normal random variable and is
denoted as Z.
The cumulative distribution function of a standard random variable is denoted as
Ф ( z )=P(Z ≤ z)
Standardizing a normal random variable
If X is a normal variable with E(X)=μ and V(X)=σ 2, the random variable
X−μ
Z= is a normal random variable with E(Z)=0 and V(Z)=1.
σ
That is, Z is a standard normal random variable
Standardizing to calculate a probability
Suppose that X is a normal random variable with mean μ and variance σ 2. Then,
P ( X ≤ x )=P ( X−μ
σ
≤
σ )
x−μ
=P (Z ≤ z ) where Z is a standard normal random variable, and
x−μ
z= is the z-value obtained by standardizing X.
σ
x−μ
The probability is obtained by using Appendix table III with z=
σ
Example
X is normally distributed with a mean of 10 and a standard deviation of 2
a) P(X < 13) = P(Z < (13-10)/2) = P(Z < 1.5) = 0.93319
b) P(X > 9) = 1 - P(X < 9) = 1 - P(Z < (9-10)/2) = 1 - P(Z < -0.5) = 0.69146
c) P(6 < X < 14) = = P(-2 < Z < 2) = P(Z < 2) -P(Z < - 2)]= 0.9545
d) P(2 < X < 4) = = P(-4 < Z < -3) = P(Z < -3) - P(Z < -4) = 0.00132
e) P(-2 < X < 8) = P(X < 8) - P(X < -2) = = P(Z < -1) - P(Z < -6) = 0.15866
4.6
Normal approximation to the binomial distribution
, If X is a binomial random variable with parameters n and p,
X−np
Z= is approximately a standard normal random variable.
√np (1− p)
To approximate a binomial probability with a normal distribution, a continuity correction is applied
as follows:
(
P ( X ≤ x )=P ( X ≤ x+ 0.5 ) ≈ P Z ≤
x+ 0.5−np
√ np ( 1− p ) )
And
P ( x ≤ X )=P( x−0.5 ≤ X) ≈ P
(
x−0.5−np
√ np ( 1− p )
≤Z
)
The approximation is good for np> 5∧n (1− p)> 5
Normal approximation to the Poisson distribution
If X is a Poisson random variable with E(X)=λ and V(X)=λ,
X−λ
Z= is approximately a standard normal random variable.
√λ
The same continuity correction used for the binomial distribution can also be applied.
The approximation is good for λ>5
Example
X is a binomial random variable with n=200 and p=0.4
a) E(X) = 200(0.4) = 80, V(X) = 200(0.4)(0.6) = 48 and σ X =√ 48
Then,
P( X≤70)≃P Z≤
√ (
70. 5−80
48 )
=P( Z≤−1. 37 )=0 . 0853
P(70<X <90)≃P
√ 48 (
70 .5−80
<Z≤
89 . 5−80
√ 48
=P(−1 . 37<Z≤1. 37 )
)
b) =0 .9 1466-0 . 08534=0 . 8293
c)
4.7
Exponential distribution
The random variable X that equals the distance between successive events from Poisson process with
mean number of events λ>0 per unit interval is an exponential random variable with parameter λ.
The probability density function of X is,