Professional Documents
Culture Documents
5
CHAPTER OUTLINE
5-1 Two or More Random Variables
Distributions
Probability
3 0.02 0.10 0.05 0.15
(2) f x, y 1
x y
XY The sum of all probabilities is 1
(3) f XY x, y P X x, Y y (5-1)
f XY x, y dxdy ke dy dx k e dy e dx
0 x 0 x
e0.002 x 0.001x
k e dx 0.003 e 0.003 x
dx
0
0.002 0
1
0.003 1
0.003
Sec 5-1.1 Joint Probability Distributions 9
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-2: Server Access Time-2
Now calculate a probability:
1000 2000
P X 1000, Y 2000 f XY x, y dxdy
x
f X x f xy
times city of signal strength
name is stated 1 2 3 f (y ) =
y 1 0.01 0.02 0.25 0.28
fY y f xy 2 0.02 0.03 0.20 0.25
3 0.02 0.10 0.05 0.17
x
4 0.15 0.10 0.05 0.30
f (x ) = 0.20 0.25 0.55 1.00
Figure 5-6 From the prior example,
the joint PMF is shown in green
while the two marginal PMFs are
shown in blue.
Sec 5-1.2 Marginal Probability Distributions 11
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Marginal Probability Distributions (continuous)
• Rather than summing a discrete joint PMF, we integrate a
continuous joint PDF.
• The marginal PDFs are used to make probability
statements about one variable.
• If the joint probability density function of random
variables X and Y is fXY(x,y), the marginal probability
density functions of X and Y are:
f X x f XY x, y dy
y
fY y f XY x, y dx (5-3)
x
Sec 5-1.2 Marginal Probability Distributions 12
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-4: Server Access Time-1
For the random variables
times in Example 5-2, find
the probability that Y
exceeds 2000.
Integrate the joint PDF directly
using the picture to
determine the limits.
2000
P Y 2000 f XY x, y dy dx f XY x, y dy dx
0 2000 2000 x
Dark region left dark region right dark region
e
0.001 x y
e 0.002 y e 0.003 y
ke
0.002 y
6 103
0.001 0 0.002 2000 0.003 2000
e 4 e 6
0.002 y 1 e
0.001 y 3
6 10 0.05
ke 0.002 0.003
0.001
6 103 e 0.002 y 1 e 0.001 y for y 0
E Y y fY y y fY y dy Y
R R
V X x 2 f X x X2 x 2 f X x dx X2
R R
V Y y 2 fY y Y2 y 2 fY y dy Y2
R R
(2) f y dy 1
Yx
e 0.002 y
ke 0.001x
0.002
x
e 0.002
0.001 x
ke
0.002
0.003e 0.003 x for x 0
f XY x, y ke 0.001x 0.002 y
fY x y
fX x 0.003e 0.003 x
0.002e 0.002 x 0.002 y for 0 x y
Sec 5-1.3 Conditional Probability Distributions 19
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-6: Conditional Probability-2
Now find the probability that Y exceeds 2000 given that X=1500:
P Y 2000 X 1500
fY 1500 y dy
2000
0.002e 0.002 1500 0.002 y
2000
e 0.002 y
0.002e3
0.002 2000
e 4
1
0.002e3 e 0.368
Figure 5-8 again The conditional
0.002 PDF is nonzero on the solid line in
the shaded region.
Sec 5-1.3 Conditional Probability Distributions 20
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-7: Conditional Discrete PMFs
Conditional discrete PMFs can be shown as tables.
y = number of x = number of bars
times city of signal strength f(x|y) for y = Sum of
name is stated 1 2 3 f (y ) = 1 2 3 f(x|y) =
1 0.01 0.02 0.25 0.28 0.036 0.071 0.893 1.000
2 0.02 0.03 0.20 0.25 0.080 0.120 0.800 1.000
3 0.02 0.10 0.05 0.17 0.118 0.588 0.294 1.000
4 0.15 0.10 0.05 0.30 0.500 0.333 0.167 1.000
f (x ) = 0.20 0.25 0.55
1 0.050 0.080 0.455
2 0.100 0.120 0.364
3 0.100 0.400 0.091
4 0.750 0.400 0.091
Sum of f(y|x) = 1.000 1.000 1.000
V Y x y Y x
2
fY x y dy y 2 fY x y Y2 x
y y
1500 1500
e 0.002 y
e 0.002 y
0.002e y
3
dy
0.002 1500 1500 0.002
0.002 y
3 1500 3 e
0.002e e
0.002 0.002 0.002
1500
1500 3 e 3
0.002e e
3
0.002 0.002 0.002
e 3
0.002e 2000 2000
3
0.002
If the connect time is 1500 ms, then the expected time to be authorized is 2000 ms.
Sec 5-1.3 Conditional Probability Distributions 23
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-9
For the discrete random variables in Exercise 5-1, what is
the conditional mean of Y given X=1?
y = number of x = number of bars
times city of signal strength
name is stated 1 2 3 f (y ) =
1 0.01 0.02 0.25 0.28
2 0.02 0.03 0.20 0.25
3 0.02 0.10 0.05 0.17
4 0.15 0.10 0.05 0.30
f (x ) = 0.20 0.25 0.55 y*f(y|x=1) y2*f(y|x=1)
1 0.050 0.080 0.455 0.05 0.05
2 0.100 0.120 0.364 0.20 0.40
3 0.100 0.400 0.091 0.30 0.90
4 0.750 0.400 0.091 3.00 12.00
Sum of f(y|x) = 1.000 1.000 1.000 3.55 13.35
12.6025
0.7475
The mean number of attempts given one bar is 3.55 with variance of 0.7475.
Sec 5-1.3 Conditional Probability Distributions 24
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Joint Random Variable Independence
• Random variable independence means that
knowledge of the values of X does not change
any of the probabilities associated with the
values of Y.
• X and Y vary independently.
• Dependence implies that the values of X are
influenced by the values of Y.
• Do you think that a person’s height and weight
are independent?
Figure 5-10(a) shows marginal & joint Figure 5-10(b) show the conditional
probabilities, fXY(x, y) = fX(x) * fY(y) probabilities, fY|x(y) = fY(y)
(1) f XY x, y f X x fY y
(2) fY x y fY y for all x and y with f X x 0
(3) f X y y f X x for all x and y with f Y y 0
(4) P X A, Y B P X A P Y B for any
sets A and B in the range of X and Y , respectively. (5-7)
and (5-10)
h x, y f XY x, y for X , Y discrete
E h X , Y (5-13)
h x, y f XY x, y dxdy for X , Y continuous
1 0.3
2 0.4
3 0.3
μX = 2.4
Mean
XY E X X Y Y E XY X Y (5-14)
Figure 5-13 Joint probability distributions and the sign of cov(X, Y).
Note that covariance is a measure of linear relationship. Variables
with non-zero covariance are correlated.
Sec 5-2 Covariance & Correlation 46
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-20: Intuitive Covariance
y = number of x = number of bars
times city of signal strength
name is stated 1 2 3
1 0.01 0.02 0.25
2 0.02 0.03 0.20
3 0.02 0.10 0.05
4 0.15 0.10 0.05
Since X 0 and Y 0,
XY and cov X , Y have the same sign.
We say that XY is normalized, so 1 XY 1 (5-16)
Note that XY is dimensionless.
Variables with non-zero correlation are correlated.
Sec 5-2 Covariance & Correlation 48
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-21: Covariance & Correlation
x y f(x, y) x-μX y-μY Prod
Determine the 0 0 0.2 -1.8 -1.2 0.42
covariance and 1 1 0.1 -0.8 -0.2 0.01
correlation. 1 2 0.1 -0.8 0.8 -0.07
Joint
2 1 0.1 0.2 -0.2 0.00
2 2 0.1 0.2 0.8 0.02
3 3 0.4 1.2 1.8 0.88
0 0.2 covariance = 1.260
1 0.2 correlation = 0.926
2 0.2
Marginal
3 0.4 Note the strong
0 0.2 positive correlation.
1 0.2
2 0.2
3 0.4
μX = 1.8
Mean
μY = 1.8
Figure 5-14 Discrete joint σX = 1.1662
StDev
Joint
2 9 0.6 10.8
3 11 0.2 6.6
1 0.2 18.8 = E(XY)
2 0.6 0.80 = cov(X ,Y )
Marginals
3 0.2 1.00 = ρXY
7 0.2 Using Equations
9 0.6 5-14 & 5-15
11 0.2
μX = 2
Mean
μY = 9.0
Figure 5-15 Discrete joint σX = 0.6325
StDev
1 2
4 2
E XY x y dx dy
E X
16 0 0
x ydx dy 16 0 0
1
4 3 2
x 3 2 2 x
1
4
y dy
y dy 16 0 3 0
16 0 3 0
4
1 8
1 y 2 8 1 16 4
4
y 2 dy
16 0 3
16 2 0 3 6 2 3
1 y3 1 64 32
4
1
4 2
EY 6 3 6 3 9 Figure 5-15 A planar
16 0 0
0
2
xy dx dy
joint distribution.
4 2 2
1
y 2 x
dy XY E XY E X E Y
16 0 2 0
32 4 8
0
2 y 3 1 64 8
4 9 3 3
16 3 0 8 3 3
20!
P x1 14, x2 3, x3 2, x4 1 0.6140.330.0820.021 0.0063
14!3!2!1!
Using Excel
0.03582 = (FACT(20)/(FACT(12)*FACT(6)*FACT(2))) * 0.6^12*0.3^6*0.08^2
x2 ! x3 ! n x2 x3 !
for x2 0 to n x3 and x3 0 to n x2 .
1 x X 2 2 x X y Y y Y 2
u
2 1 2 X XY Y
2 2
for x and y .
x 0, x ,
Parameter limits: 1 1
y 0, y ,
Figure 5-17 These illustrations show the shapes and contour lines of two
bivariate normal distributions. The left distribution has independent X, Y
random variables (ρ = 0). The right distribution has dependent X, Y random
variables with positive correlation (ρ > 0, actually 0.9). The center of the
contour ellipses is the point (μX, μY).
Y
Y x Y x X
X
2
Yx
1 2
Y
2
Sec 5-3.2 Bivariate Normal Distribution 64
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Correlation of Bivariate Normal Random Variables
E Y c1 E X 1 c2 E X 2 ... c p E X p (5-25)
SD X 95 9.747 nm
If X
X 1 X 2 ... X p
and E X i
p
p
Then E X (5-28a)
p
p 2 2
Then V X 2
(5-28b)
p p
then Y c1 X 1 c2 X 2 ... c p X p
E Y c11 c2 2 ... c p p
and
SD Y 0.20 0.4472 cm
14.5 14
P Y 14.5 1 1 1.1180 0.1318
.4472
Using Excel
0.1318 = 1 - NORMDIST(14.5, 14, SQRT(0.2), TRUE)
Sec 5-4 Linear Functions of Random Variables 74
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.
Example 5-33: Beverage Volume
Soft drink cans are filled by an automated filling machine. The
mean fill volume is 12.1 fluid ounces, and the standard
deviation is 0.1 fl oz. Assume that the fill volumes are
independent, normal random variables. What is the probability
that the average volume of 10 cans is less than 12 fl oz?
Let X i denote the fill volume of the i th can
10
Let X X i 10
i 1
n
10 12.1
E X E X i 10 12.1 fl oz
i 1 10
10 0.1
2
2 10
VX 1 V X 0.001 fl oz 2
10 i 1 i
100
Using Excel
12 12.1
P X 12 3.16 0.00079
0.000783
0.001 = NORMDIST(12, 12.1, SQRT(0.001), TRUE)
fY y
y 4 2 1 y 4
for 4 y 12.
8 2 32
Chapter 5 Summary 81
© John Wiley & Sons, Inc. Applied Statistics and Probability for Engineers, by Montgomery and Runger.