Professional Documents
Culture Documents
Lec8 Part1 Uniform Exp
Lec8 Part1 Uniform Exp
distributions
• Uniform distribution
• Exponential distribution
• Normal distribution
Uniform Distribution
A Uniform Distribution has equally likely
values over the range of possible outcomes.
0
x
0 1 2 3 4 5
Temperature (degrees Celsius)
Example
Note that the total area under the
“curve” is 1.
P(x)
0.2
0
x
0 1 2 3 4 5
Temperature (degrees Celsius)
P(x)
Example
0.2
0 x
0 1 2 3 4 5
Temperature (degrees Celsius)
0 x
0 1 2 3 4 5
Temperature (degrees Celsius)
0.2
0 x
0 1 2 3 4 5
Temperature (degrees Celsius)
Example
What is the probability the temperature is
between 10C and 40C?
P(1 x 4) = (3)(.2)= 0.6.
P(x)
0.2
0 x
0 1 2 3 4 5
Temperature (degrees Celsius)
Uniform Distribution
The uniform distribution is a continuous distribution
in which the same height, of f(X), is obtained over a
range of values.
1
1 ba
b a for a xb
f ( x)
f ( x)
0 for all other values
Area = 1
a x b
Notation: X~uniform(a,b)
Uniform Distribution
• The cumulative distribution function .
0, if x a
xa
F ( x) b a , if a x b
1, if x b
1
F ( x)
a b
Uniform Distribution
Expectation:
E ( X ) xf ( x )dx
b
b 1 1 b a 2 2
xdx x
2
a ba 2(b a ) a 2(b a )
(b a )(b a ) b a
2(b a ) 2
11
Uniform Distribution
Variance:
Var ( X ) E ( X 2 ) 2
x 3 b
b3 a 3 b2 ab a 2
b 1
E( X ) x dx
2 2
a ba 3(b a ) 3(b a ) 3
a
b 2
ab a 2
( a b ) 2
E( X 2 ) 2
3 4
4b 4ab 4a
2 2
3b 6ab 3a
2 2
12 12
b 2 2ab a 2 (b a ) 2 (b a ) 2 b a
12 12 12 12
Example
You arrive at a bus stop at 10 o’clock knowing that the bus will arrive at some
time uniformly distributed between 10 and 10:30.
i)What is the probability that you will have to wait longer than 10 minutes?
ii)What is the probability that you will have to wait at most 15 minutes?
P(x)
1/30
0
10 10:10 10:15 10:20 10:30
x
Example
You arrive at a bus stop at 10 o’clock knowing that the bus will arrive at some
time uniformly distributed between 10 and 10:30.
i)What is the probability that you will have to wait longer than 10 minutes?
1 2
P (10 x 20) ( 20)( )
30 3
P(x)
1/30
0
10 10:10 10:15 10:20 10:30
x
Example
You arrive at a bus stop at 10 o’clock knowing that the bus will arrive at some
time uniformly distributed between 10 and 10:30.
ii)What is the probability that you will have to wait at most 15 minutes?
1 1
P (0 x 15) (15)( )
30 2
P(x)
1/30
0
10 10:10 10:15 10:20 10:30
x
Exponential distribution
• Let be a positive real number.
• We write X~ exponential() and say that X is
an exponential random variable with
parameter if the pdf of X is
e x , if x 0
f ( x)
0, otherwise
16
Exponential distribution
• A simple integration shows that the area
under f is 1:
t
dx lim e
x x x t
e dx lim e
t 0 t 0
lim e t
e 0
0 1 1
t
17
Exponential distribution
• The cumulative distribution function .
e x , if x 0
f ( x)
0, otherwise
x x
F ( x) e x
dx e x
dx e x x
0 0
e x
e 0
e x
1
0 if x 0
F ( x) x
1 e if x 0
18
Exponential distribution
Expectation:
E ( X ) x e x
t
dx lim x e x
dx. udv uv vdu.
t
0 0
x t
t 1 x t
e dx lim te 0 e
t x
lim xe
t
t
0
0 0
t 1 t 1 0 t 1 t 1
lim te e e lim te e
t
t
1 1
00
1
By a similar computation Var ( X ) 19
2
Exponential distribution
• Exponential distributions are sometimes
used to model waiting times or lifetimes.
20
Example
Suppose the wait time X for service at the post office has an
exponential distribution with mean 3 minutes. If you enter the
post office immediately behind another customer,
i)what is the probability you wait over 5 minutes?
ii)what is the probability of waiting between 2 and 4 minutes?
Since E(X)=1/=3 minutes, then =1/3, so
1
1
1
x 1
1
x x 135
5
P( X 5) e 3
dx e 3
e 3
e e 3 0.189
5 3 1
3 5
3
x
Or using the cumulative distribution function . F ( x) 1 e
P( X 5) 1 P( X 5) 1 F (5)
5
1
5
1 1 e 3 e 3 0.189
Example
Suppose the wait time X for service at the post office has an
exponential distribution with mean 3 minutes. If you enter the
post office immediately behind another customer,
i)what is the probability you wait over 5 minutes?
ii)what is the probability of waiting between 2 and 4 minutes?
4
2
P(2 X 4) F (4) F (2) 1 e 3 1 e 3
2 4
e 3
e 3
0.250
Example
The time to failure (in hours) of fans in a personal computer can
be modeled by an exponential distribution with mean =1/0.0003
i)what is the probability that the fans will operate at least 10000 hours?
ii)what is the probability that the fans will operate at most 7000 hours?
iii) Find the value c such that p(X<c)=0.9
Example
The time to failure (in hours) of fans in a personal computer can
be modeled by an exponential distribution with mean =1/0.0003
i)what is the probability that the fans will operate at least 10000 hours?
ii)what is the probability that the fans will operate at most 7000 hours?
P ( X 7000) F (7000)
P( X c) F (c)
1 e 0.0003( c ) 1 e 0.0003c 0.9
ln(0.1)
c c 7675.3
0.0003