Chapter. 5_Probability Distributions

Download Report

Transcript Chapter. 5_Probability Distributions

Chapter. 5_Probability Distributions
Discrete Random Variables
Random Variable (X):
• It is a real-valued function, defined on the Sample
Space (S), which assigns a Real Value (x) for each basic
outcome of (S)
• Example1: Toss a balanced
• coin twice
• S={HH, HT, TH, TT}
Lets define Random Variable X
such as
X= the total number of heads
1st
coin
2nd
coin
Basic
outco
mes
Head
(H)
H
HH
2
T
HT
1
H
TH
1
T
TT
0
Tail
(T)
Random
Variable X
X=1 if basic outcome is either HT or TH
X=2 if basic outcome is HH
X=0 if basic outcome is TT
When basic outcome is not a numerical value, Random
Variable (X) helps us to assign one & only numerical
value (x) for each basic outcome.
If Random Variable (X) can take countable
number of values we call it as DISCRETE
RANDOM VARIBALE.
In our example, it is seen that X=x, X=0 or X=1 or
X=2, such that x is an INTEGER. Thus X may
take three different value!  FINITE Number of
Values
Example2: Toss a coin up to Head appears
X=how many times we toss the coin
X=1 or X=2 or X=3, ….upto Head appears  X
may take INFINITE NUMBER of VALUES
but still X is COUNTABLE
• A random variable is a continuous
random variable if it can take any value in
an interval. INCOUNTABLE, INFINITE
• Example: X is defined in interval [0,1]
• It means 0<x<1 here X=x can be X=0.01,
or X=0.002 ..etc.  incountable! & infinite
(there are infinite number of real values
between 0 and 1)
Probability Distribution
• The probability distribution function, P(X=x), of a discrete random
variable X expresses the probability that X takes the value x, as a
function of x. That is,
• Continue Example 1:
Basic
outcomes
Probability
of each
basic
outcome
P( x)  P( X  x),
Random
Variable
X
HH
1/4
2
HT
1/4
1
for all valuesof x
Pr(X=x)
P(X=2) = P(2) =
P(HH) = 1/4
TH
1/4
1
P(X=1) = P(1) =
P(HT,TH) = 1/4 + 1/4 =1/2
TT
1/4
0
P(X=0) = P(0) = P(TT) = 1/4
X
P(x)
0
1/4
1
1/2
2
1/4
SUM =
1
Properties of Probability Distribution Functions
Let X be a discrete random variable with probability distribution function P(x).
Then
1) 0 <= P(x) <= 1 for any value x, and
P( x )  1

x
2) The individual probabilities sum to 1,
For our Example 1:
X
P(x)
F(x)
0
1/4
F(0)=P(X<=0) = P(X=0) = 1/4
1
1/2
F(1)=P(X<=1) =P(X=1)+P(X=0)=1/2+1/4=3/4
2
1/4
F(2)=P(X<=2) =P(X=2)+ P(X=1) + P(X=0)=1/4 + 1/2+1/4=1
CUMULATIVE PROBABILITY FUNCTION
The cumulative probability function, F(x0) for a random
variable X, expresses the probability that X does not
exceed the value x0, as a function of x0. That is
F(x0 )  P(X  x 0 ) 
 P(x)
xx 0
For our Example 1:
X
P(x)
F(x)
0 1/4
F(0)=P(X<=0) = P(X=0) = 1/4
1 1/2
F(1)=P(X<=1) =P(X=1)+P(X=0)=1/2+1/4=3/4
2 1/4
F(2)=P(X<=2) =P(X=2)+ P(X=1) + P(X=0)=1/4 + 1/2+1/4=1
Practice on Probability Distribution & Cumulative Probability
Function
X
0
1
2
3
4
5
6
P(x)
0.1
0.15
0.15
0.25
0.2
0.1
0.05
• EXAMPLE: The number of cars sold per day at a small town is
defined by the following probability distribution:
• a) P(X=3)=?
• b)F(5)=?
• F(5)= P(X<=5)= P(X=0)+P(X=1)+P(X=2)+P(X=3)+ P(X=4)+P(X=5) =
• c) P(2<X<6)= ?
• =P(X=3)+P(X=4)+P(X=5)
d)P(4<=X<5)= ?
e)P(2<X<=6)=?
Properties of Discrete Random Variable
•
Expected Value (or mean) of a discrete distribution (Weighted Average)
μ  E(x)   xP(x)
x
Variance and Standard Deviation
σ 2  E(X  μ)2  (x  μ)2 P(x)
2
(x

μ)
P(x)

σ  σ2 
x
x
Example1: Toss a balanced coin twice
S={HH, HT, TH, TT}
X
Lets define Random Variable X
such as
X= the total number of heads
P(x) (x-µ)2
P(x)
µ=
xP(x)
(x-µ)2
0
1/4
0
(-1)2
0.25
1
1/2
0.5
(0)2
0
2
1/4
0.5
(1)2
0.25
Mean (µ)
1
Variance
E(x) = (0 x 1/4) + (1 x 1/2) + (2 x 1/4)= 1.0
0.5
σ  σ 2  0.5
Function of Random
Variables
• If P(x) is the probability function of a
discrete random variable X , and g(X) is
some function of X , then the expected
value of function g, E(g(X)), is
E[g(X)] 
 g(x)P(x)
x
Function of Random Variables
Continue to Example 1:Toss a balanced coin twice S={HH, HT, TH, TT}
Define Random Variable X such as: X= the total number of heads
Suppose that you claim to pay (5X + 200)$ for any realization of random
variable X thus we define following pay of function g(x) such that
g(x)= 5x + 200
g(0)= 5.0+200 = 200
g(1)=5.1 +200 = 205
g(2)= 5.2 +200 = 210
What is the expected amount
(mean) that you pay off?
X
P(x)
Y=
g(x)=5x+200
0
1/4
200
¼
1
1/2
205
½
2
1/4
210
1/4
P(y)
E[g(X)]  g(x)P(x) 200(1 / 4)  205(1 / 2)  210(1 / 4)  205
x
Therefore we can consider g(x) as an another RANDOM VARIABLE,
lets call as Y, such that Y=G(x) and the underlying probability of Y
depends of X=x
Linear Function of Random Variables
• Let random variable X have mean µx and variance σ2x & Let a and
b be any constants.
E(a)  a , Var(a)  0
i.e., if a random variable always takes the value ‘a’, it will have mean ‘a’ and
variance ‘0’.
Example:
x
P(x)
xP(x)
(x-mean)2P(x)
5
1/4
5/4
0
5
1/4
5/4
0
5
1/4
5/4
0
5
1/4
5/4
0
mean
variance
5
0
Linear Function of Random
Variables
E(bX)  bE( X )  bμ X , Var(bX)  b Var(X)  b σ
2
2 2
X
Please see below Table as an example. Here X is a r.v. and Y is a linear
function of X such that Y = 10*X
X
P(x)
E(X)=X.P(X)
0
1/4
0
0
0
1
1/2
1/2
10
10/2
2
1/4
2/4
20
20/4
1
Y=10*X
E(Y)= YP(x)
10
Linear Function of Random Variables
• Let random variable X have mean µx and variance
σ2x & Let a and b be any constants.
• We define a linear function Y=a+bX such that
• Then the mean of Y is
μ Y  E(a  bX)  a  bμ X
• the and variance and standard deviation of Y are
σ2 Y  Var(a bX)  b2σ2 X
σY  b σX
Solve the problem applying the rules of Linear Function of
Random Variables
Continue to Example 1:Toss a balanced coin twice S={HH, HT, TH, TT}
Define Random Variable X such as: X= the total number of heads
Suppose that you claim to pay (5X + 200)$ for any realization of random variable
X thus we define following pay of function g(x) such that
g(x)= 5x + 200
g(0)= 5.0+200 = 200
g(1)=5.1 +200 = 205
g(2)= 5.2 +200 = 210
What is the expected amount , mean, that you pay off?
X
P(x)
Y= g(x)=5x+200
P(y)
0
1/4
200
¼
1
1/2
205
½
2
1/4
210
1/4