Chapter 4b notes (WORD)

advertisement
The Gamma Distribution and its Relatives
For any α > 0 the gamma function Г(α) is defined by

    x  1e  x dx
0
Properties:
1. For any α > 1, Г(α) = (α – 1) Г(α – 1 )
Proof.
Let α > 1, then

    x  1e  x dx
0
Integrating by parts. (Yeah!)
u = x α-1
dv = e –x dx
α-2
du = (α – 1) x
dx v = - e –x .
Therefore

    x 1e x |0   e x   1x  2dx
0

   0  0    1 x  2e x dx    1  1
0
So Г(α) = (α – 1) Г(α – 1), which is reminiscent of the factorial function:
n! = n (n – 1)!, in fact for any positive integer n, property 2
2.
Г(n) = (n – 1)!
3.
Г(½) = √π
which brings us to Gamma Distribution, which has pdf
 1
x 1e  x / 
x0
 
f x; ,       

0
otherwise

where α > 0 and β > 0
Integrating f(x; α, β) from 0 to infinity equals 1 and f(x; α, β) ≥ 0 so
f(x; α, β) is a pdf
There are an infinite number of Gamma distributions, based on α and β.
There are some pictures in your text of what their pdf’s look like.
Most times the gamma is used to model skewed distributions.
If X ~ Gamma(α, β) then
E(X) = αβ
V(X) = αβ2
The standard gamma distribution has β = 1 and has pdf:
 1  1  x
x e

f x;     

0

x0
otherwise
If X has a standard Gamma distribution with α, then the cdf is defined as:
x
F x;   
0
1
 
y 1e y dy
x>0
This is called the incomplete gamma function and there are tables for this
function.
For a general gamma with α and β the cdf is given by:
P(X ≤ x) = F(x; α, β) = F1(x/β, α)
where F1 is the incomplete gamma function.
Examples:
Find
Г(6) = 5! = 120
Г(5/2) = 3/2 Г(3/2) = (3/2) (1/2) Г(1/2) = 3/4 * √π = 1.329
F1(4; 5) where F() is the incomplete gamma function.
F1(4; 5) = .371
F1(5;4) = .735
F1(0,4) = 0
Page 162 #66 Student’s time on a terminal has a gamma distribution with
mean 20 and variance 80 minutes.
a. What are α and β?
E(X) = αβ = 20
V(X) = αβ2 = 80
Since α > 0, β = 4 and therefore α = 5.
b. P(X ≤ 24) = F1(24/4; 5) = F1(6; 5) = .715
or
24
1
P( X  24)   5
x 4e x / 4 dx


4

5
0
which is clearly .715, just integrate by parts four times.
c. P(20 ≤ X ≤ 40) = P(X ≤ 40) – P(X ≤ 20) = F(40) – F(20)
P(20 ≤ X ≤ 40) = F1(10;5) – F1(5; 5) = .971 - .560 = .411
40
P(20  X  40) 
1
 4 5 x e
5
4 x / 4
dx
20
The Exponential Distribution.
Called the waiting time or memory-less distribution.
X ~ Exp(λ)
for x > 0
f ( x)  ex
f(x) = 0
otherwise
The exponential distribution is a special case of the Gamma, with α = 1 and
β = 1/λ
μ = 1/λ and σ = 1/λ
note that f(x) > 0
The exponential distribution is really nice because there is a simple
expression for F(x). For x ≥ 0
P(X ≤ x) = F(x) = 1 – e –λx
P(X > x) = e –λx
Ex. Let X ~ Exp(λ = 0.1)
P(X > 15) = e –.1*15 = e –1.5 = .2231
P(X < 20) = 1 - e –.1*20 = 1- e –2 = .8647
E(X) = 1/(1/10) = 10
V(X) = 100
Example
Page 162 #61
Fans of diesel engines have an exponential distribution until time of failure.
E(X) = 25000  λ = 1/25000 = .00004
P(X ≥ 20000) = e –.00004*20000 = e –.8 = .449
P(X ≤ 30000) = 1 - e –.00004*30000 = 1 - e –1.2 = .699
P(20000 ≤ X ≤ 30000) = 1 - e –1.2 - (1 - e –.8 ) = e –.8 - e –1.2 = .449 - .301 =
.148
b. σ = 25000 2σ = 50000 3σ = 75000
P(|X – 25000| > 50000) = P(X < -25000) + P(X > 75000) = 0 + e –3 = .050
P(|X – 50000| > 75000) = P(X < -50000) + P(X > 100000) = 0 + e –4 = .018
Chi Squared Distribution
Let v be a positive integer. Then X has a Chi-Squared Distribution with
parameter v (degrees of freedom), and gamma density with α = v/2 and β =
2.
1

x ( v / 2) 1e x / 2
x0
 v/2
f x; v    2 v / 2

0
otherwise

Nice properties of Chi-Squared: table in back and Calculator function.
χ2 is used for a few statistical analyses, especially in categorical data
analysis.
and for testing variances.
Note that since χ2 is a gamma, this mean that:
E(X) = v
V(X) = 2v
Example
Suppose X has a χ2 distribution with 20 degrees of freedom. Find:
P(X ≤ 9.591) = 1 – 0.975 = .025
P(X > 31.410) = .05
P( 9.591 < X < 31.410) = .95 - .025 = .925
Suppose X has a χ2 distribution with 2 degrees of freedom. Find the
probability that X is within 1 standard deviation of it mean.
E(X) = 2
V(X) = 4
σ=2
P(|X – 2| < 2) = P(0 < X < 4) = P(X < 4) = .864
4
4
1
1
P( X  4)   1
x 0e x / 2 dx   e x / 2 dx  e x / 2 |04  e 2  1  .864
2 1
2
0
0
or
χ2cdf(0, 4, 2) = .864
page 163 #71 X2 ≤ y is equivalent to what event involving X?
Page 163 #69 A system consists of 5 identical components in series.
Download