Beruflich Dokumente
Kultur Dokumente
4 7 5
( 0) + (1) + ( 2) = 1.06
16 16 16
X
= E(x) = xf (x) If X is discrete
x
Z 1
= E(x) = xf (x)dx If X is continuous
1
Comparison
General formula of mean:
n
xi 1
x= =x
i =1 n x n
Discrete Expected Value
= E ( X ) = x f ( x)
x
Continuous Expected Value
= E ( X ) = x f ( x ) dx
Example
Refer to the two-coin tossing experiment and the
probability distribution for the random variable x
Demonstrate that the formula for E(x) gives the mean
of the probability distribution for the discrete random
variable x.
Solution
If we were to repeat the two-coin tossing experiment a
large number of times say 400,000 times, we would
expect to observe:
x = 0 heads approximately 100,000 times,
x = 1 head approximately 200,000 times,
x = 2 heads approximately 100,000 times.
.. (contd)
Calculating the mean of these 400,000 values
of x, we obtain
P
x x 100, 000(0) + 200, 000(1) + 100, 000(2)
=
N 400, 000
1 1 1
= (0) + (1) + (2)
4
X 2 4
= f (x)x
x
Solution
Let X represent the number of good components in the
sample. The probability distribution of X is
4 3
x 3 x x = 0, 1, 2, 3.
f (x) = 7 ,
3
A few simple calculations yield f(0) = 1/35, f(1) = 12/35,
f(2) = 18/35, f(3) = 4/35. Therefore
1 12 18 4
= E(X) = (0) + (1) + (2) + (3)
35 35 35 35
= 1.7
Thus, if a sample of size 3 is selected at random over and
over again from a lot of 4 good components and 3
defective components, it would contain, on average, 1.7
good components.
Challenge
Let X be the random variable that denotes the
life in hours of a certain electronic device. The
probability density function is
20,000
f (x) = x3 , x > 100
0, elsewhere
X
g(X) = E[g(X)] = g(x)f (x) If X is discrete
x
Z 1
g(X) = E[g(X)] = g(x)f (x)dx If X is continuous
1
Example
Suppose that the number of cars X that pass through a car
wash between 4:00 P.M. and 5:00 P.M. on any sunny
Friday has the following probability distribution:
x 4 5 6 7 8 9
(xi )
n 2
=
2
n
(xi )2
2 =
i=1 n
i=1 N
Variance
q Definition
Let X be a random variable with probability distribution f(x)
and mean . The variance of X is
X
2
= E[(X )2 ] = (x )2 f (x) If X is
discrete
Zx1
2
= E[(X )2 ] = (x )2 f (x)dx If X is
1 continuous
Solution
If we were to repeat the two-coin tossing experiment a
large number of times say 400,000 times, we would
expect to observe:
x = 0 heads approximately 100,000 times,
x = 1 head approximately 200,000 times,
x = 2 heads approximately 100,000 times.
Calculating the mean of these 400,000 values of x,
we obtain
P
x x 100, 000(0) + 200, 000(1) + 100, 000(2)
=
N 400, 000
1 1 1
= (0) + (1) + (2)
4
X 2 4
= f (x)x
x
Standard deviation:
r
p 1
= 2 = 0.707
2
Challenge
Let the random variable X represent the number of automobiles
that are used for official business purposes on any given workday.
The probability distribution for company A is
x 1 2 3
x 1 2 3
2
= E(X 2 ) ()2
Challenge
Let the random variable X represent the number of
defective parts for a machine when 3 parts are sampled
from a production line and tested. The following is the
probability distribution of X,
x 0 1 2 3
Calculate 2
Solution
Therefore
2
= 0.87 (0.61)2 = 0.4979
Challenge
The weekly demand for Pepsi, in thousands of liters,
from a local chain of efficiency stores, is a continuous
random variable X having the probability density
2(x 1), 1<x<2
f (x) =
0, elsewhere
Therefore
2
2 17 5 1
= =
6 3 18
Covariance
Covariance: measurement of the nature
association between two dependent random
variables X and Y
If covariance sign is positive (+), then X ~ Y
1
If covariance sign is negative (-), then X ~
Y
If X and Y is statistically independent,
then covariance equals to 0
Covariance of X and Y :
x
f(x,y) 0 1 2 Row
totals
| 0 3/28 9/28 3/28 15/28
| 2 1/28 1/28
Col. totals 10/28 15/28 3/28 1
2 2 2
x = E ( X ) = x f ( x, y ) = x g ( x )
x = 0 y =0 x =0
2 2
E ( XY ) = x y f ( x, y)
x =0 y =0
XY = E(XY ) x y = 3 / 14 (3 / 4)(1 / 2) = 9 / 56
39
Correlation Coefficient
Note that value of co-variance does not indicate strength of the
relationship since it depends on the scale. The correlation
coefficient is a scale-free version.
Let X and Y be random variables with standard deviations X
and Y, and covariance XY . The correlation coefficient of X
and Y is:
XY
XY = 1 XY 1
X Y
The correlation coefficient is scale-free, and:
if XY = 0, then XY = 0
40
Real Implementation
Correlation coefficient can be used in template
matching algorithm for pattern recognition or
object tracking
Find the position of small patch of an image, in
the sequential frames. Best matching will be the
maximum value of correlation coefficient
Means and Variances of Linear Combinations of
Random Variables
4. E(X, Y ) = E(X)E(Y )
2
5. aX+b = a2 2
X = a2 2
2
6. aX+bY = a2 2
X + b2 2
Y = 2ab XY
Chebyshev Theorem
Note: The late P.L. Chebyshev (1821-1894) was a Russian mathematician
Solution
15
P ( 4 < X < 20) = P [8 (4)(3) < X < 8 + (4)(3)]
16
P (|X 8| 6) = 1 P (|X 8| < 6)
=1 P( 6 < X 8 < 6)
1
=1 P [8 (2)(3) < X < 8 + (2)(3)]
4
The theorem does not tell you the exact probability distribution
NEXT : DISCRETE PROBABILITY
DISTRIBUTIONS
Covariance
The covariance of two random variable X and Y with
means X and Y, respectively, is given by
XY = E(XY ) X Y
Note
Nature of association between two random variables
The sign of covariance indicates whether the relationship
between two dependent random variables is positive or
negative
When X and Y are statistically independent, it can be
shown that the covariance is zero
Correlation coefficient
q Definition
Let X and Y be random variables with covariance XY
and standard deviations X and Y, respectively. The
correlation coefficient X and Y is
XY
XY =
X Y
and satisfies
1 XY 1