Professional Documents
Culture Documents
Example 2.33 (Example 2.32 Continued). Let X be the amount we win on the coin tossing
experiment of Example 2.32. Then the fairness of the coin implies that P(X = 1) = .5 and
P(X = 2) = .5. The expected value of X is then given by (2.31) as
E(X) = 1 * P(X = 1) + 2 * P(X = 2) = 1 * .5 + 2 * .5 = 1.5.
This matches the expected value we had intuitively associated with X in Example 2.32. 0
Example 2.34 (Bernoulli Random Variable). Let X be a B(p) random variable with pmf as
in (2.3). Then, by (2.31 ), we have
E(X) = 0 · P(X = 0) + 1 · P(X = 1) = 0(1- p) + 1p = p.
Thus the expected value of the B(p) random variable is p. 0
Example 2.35 (Sum of Two Dice). Let X be the sum of the outcomes from tossing two fair
dice as in Example 2.9. Using the pmf given there we get
L kP(X = k)
12
E(X) =
k=2
1 2 3 4 5
=2*- +3*- +4* -+5*- +6*-
36 36 36 36 36
6 5 4 3 2 1
+ 7 * - + 8 * - + 9 * - + 10 * - + 11 * - + 12 * -
36 36 36 36 36 36
= 7. (2.32)
0
Example 2.36 (Binomial Random Variable). Let X be a Bin(n, p) random variable, with
pmf given in (2.4 ). Then
n
E(X) = LkP(X = k)
k=O
_
n
k
n'· pk(1 _ p)n-k
-6
~
k! (n- k)!
= 6 n
(k-
I
)
n - 1 1·
n-1 (
_ n k 1_
6
~ n-1-k
- p k!(n -1-k)!p ( p)
=np(p+1-pt- 1
=np. (2.33)
0
50 2. Univariate Random Variables
Example 2.37 (Poisson Random Variable). Let X be a P(A) random variable with pmf given
in (2.7). Then
L kP(X = k)
00
E(X) =
k=O
00 • Ak
= Lke-A-
k=O k!
00 Ak-1
-A""' e-). _ __
6 (k -1)!
='Ae-). L-Ak
00
k=O k!
= Ae-).l
=A. (2.34)
0
When X is a discrete random variable taking values in S = {0, 1, 2, ... } we can show that
(see Conceptual Problem 2.14)
E(X) = (2.35)
k=O
This formula sometimes simplifies the computation of E(X). We illustrate with the following
example:
Example 2.38 (Geometric Random Variable). Let X be a G(p) random variable with pmf
given in (2.5). Then,
P(X>k)=(l-pl, k::::O.
Hence, from (2.35)
L P(X > k)
00
E(X) =
k=O
1-(1-p)
1
(2.36)
p 0
For the expected values of other discrete random variables, see Table 2.2 in Section 2.11.
2.9. Expectation of a Continuous Random Variable 51
Definition 2.21 (Expected Value). Let X be a continuous random variable with pdf JO.
i:
Then the expected value of X is defined as
Example 2.39 (Uniform Random Variable). Let X be a U(a, b) random variable with pdf
i:
given in (2.15). Then
E(X) = xf(x)dx
= fh x -1-dx
la b- a
I b2 - a2
b -a 2
a+b
= (2.38)
2
Since the random variable is uniformly distributed over a to b, it is intuitively clear that its
expected value should be the midpoint of the interval (a, b). 0
Example 2.40 (Triangular Density). Consider a random variable X with the following
I:
density over (0, 2):
if X < 0,
ifO::: X::: I,
f(x)=
2-x if 1 ::: X ::: 2,
0 if X > 2.
i:
Then the expected value of X is given by
E(X) = xf(x)dx
= 1 /1 I
x 2 dx + 1
- x(2 - x) dx
_- 2 -x3)1
x31 + ( X 1 2
- -
3 0 3 I
=1. (2.39)
This is what we would expect, since the density is symmetric around I. 0
52 2. Univariate Random Variables
Example 2.41 (Exponential Random Variable). Let X be an Exp(A.) random variable with
l:
pdf given in (2.17). Then
E(X) = xf(x)dx
= 100 xA.e-h dx
=- 11
A. o
A.e-h(A.x)dx
00
1
-A.
Here the last integral is one since it is an integral of an Erl(2, A.) density. 0
Example 2.42 (Erlang Random Variable). Let X be an Erl(k, A.) random variable with pdf
L:
given in (2.19). Then
E(X) = xf(x)dx
= 10
oo
xA.e-J.x
(A.xl-I
(k - 1)!
dx
=- k 100 A.e-J...x--dx
(A.xl
A. 0 k!
k
=- (2.40)
A.
Here the last integral is one since it is an integral of an Erl(k + I, A.) density. 0
Example 2.43 (Normal Random Variable). Let X be a Normal random variable with pdf
L:
given in (2.23) with JL = 0 and a 2 = 1. Then
E(X) = xf(x)dx
= 100 J2ii
-oo
1
x--exp{-4x 2 }dx.
=0. (2.41)
Here the last equality follows because the integrand is an odd function of x. We shall see
in the next section how the expected value of an N(JL, a 2) random variable can be easily
computed from this. 0
We can establish the following for a nonnegative continuous random variable (see Con-
ceptual Problem 2.15):
E(X) = 1 00
(1- F(x))dx. (2.42)
We illustrate the use of (2.42) with the help of an Exp(A.) random variable.
2.1 0. Expectation of a Function of a Random Variable 53
Example 2.44 (Exponential Random Variable). Let X be an Exp(A.) random variable. Then
I - F(x) = P(X > x) = e-h.
E(X) = 1 00
e-J..x dx
I
(2.43)
See Table 2.3 for the expected values of the common continuous random variables.
If.
also a random variable and showed how its cdf Fr (or pmf py, or pdf fr) can be computed.
Since Y is a random variable, it has an expectation. From (2.31) and (2.37), we see that
L; Yi py(y;) if Y is discrete,
E(Y) =
)' yfy(y)dy if Y is continuous.
Unfortunately, this method requires the pdf or pmf of Y, which is difficult to compute, as
we saw in Section 2.7. Is there an easier way? There is indeed a way to avoid computing
the distribution of Y. It is called
Proof. Assume that X is discrete with state space {x0 , x 1, ••• } • Then Y is necessarily discrete.
Let its state space be {y0 , y1, .•• }. We have
P(Y = yj) = L P(X =X;). (2.45)
i:g(x;)=y1
Now,
Lg(x;)px(x;) = L L g(x;)P(X = x;)
i j i :g(x; )=YJ
= E(Y).
This proves the theorem in the discrete case. The proof in the continuous case is similar but
requires technicalities, hence we omit it. 0
where a and bare constants. To begin with, assume that X is a continuous random variable
with pdf f. Let Y =aX+ b. Then
E(Y) = E(aX +b)
=I:
I: I:
(ax+ b)f(x)dx
=a xf(x)dx +b f(x)dx
= aE(X) +b.
Here the second equality follows due to (2.44 ), the third equality follows due to the linearity
property of integrals, and the fourth equality follows due to (2.37) and (2.14 ). In particular,
the above derivation shows that
E(c) = c
for any constant c. In general we have
E(gJ (X)+ gz(X)) = E(g 1(X))+ E(g 2(X)) (2.47)
for all random variables X, continuous or discrete.
Example 2.45 (Expectation of N(t-t, a 2 )). Let X be a standard Normal random variable.
Then using the results of Example 2.27 we see that Y = a X+ t-t is an N(t-t, a 2 ) random
variable. Hence, using Example 2.43 and (2.46) we get
E(Y) = aE(X) + t-t =a . 0 + t-t = fk. 0
(2.48) we get
Var(X) = E((X- mf)
= E(X 2 - + m2)
2Xm
= E(X 2 ) - E(2Xm) + m2 (from (2.47))
= E(X 2 ) - 2mE(X) + m2
= E(X 2) - 2m 2 + m2
= E(X 2 ) - m2 •
Hence we have
(2.49)
Example 2.46 (Variance of Bin(n, p)). Let X be a Bin(n, p) random variable. We first
compute
n'
n
= ~)k(k- I)+ k) . lo- p)n-k
k=O k! (n- k)!
6 8
n f n f
= (k- 2)~(n- k)! lo- Pt-k + (k- I)~(n- k)! l<I- Pr-k
n (n - 2)!
= n(n- I)p2 ~ l-2(1 - p)n-k
6_ (k- 2)! (n - k)!
f-- (n - 1)!
6
k-1 1 n-k
+np (k -l)!(n -k)!p ( - p)
(n - 2)!
lo- pt-Z-k
n-2
= n(n- 1)p 2 ~
{:ok!(n-2-k)!
n-J ( 1)1
~ n- · k I n-J-k
+ np {:o k! (n- I - k)! p ( - p)
See Tables 2.2 and 2.3 in Section 2.11 for the variances of common random variables.
56 2. Univariate Random Variables
=-- 0
n+l
Poisson A P(A) A. A.
2.12. Problems
CONCEPTUAL PROBLEMS
2.1. Show that:
This shows that the hazard rate uniquely determines the cdf.
2.14. Prove (2.35).
2.15. Prove (2.42).
Definition 2.27 (Factorial Moments of a Random Variables). The second factorial moment
of a random variable is defined as E(X(X - I)). The rth factorial moment of a random
variable is defined as E(X(X - I )(X - 2) ... (X - r + 1)).
2.16. Compute the second factorial moment of a P().) random variable.
2.17. Compute the second factorial moment of a Bin(n, p) random variable.
2.18. Show that E(X 2 ) ::: (E(X)) 2 . When does the equality hold?
2.19. Show that Var(aX +b)= a2 Var(X), where a and bare constants.
2.20. Show that the variance of a standard Normal random variable is 1. (Hint: Use the
I:
identity
2.21. Using Example 2.27, Conceptual Problems 2.I9 and 2.20 show that the variance of
an N(JL, a 2 ) random variable is a 2 .
2.22. Show that the nth moment of an Exp(.A) random variable is given by n !j.A n.
2.23. Let X be a nonnegative random variable with cdf G( ·). Let T be a fixed nonnegative
constant. Show that
COMPUTATIONAL PROBLEMS
2.1. State the sample space and the random function in the following experiments:
(1) Toss three coins and observe the outcome on each coin. X= the number of heads-
the number of tails.
2.12. Problems 59
(2) Toss two dice and observe the outcome on each die. X = the absolute value of
the difference between the two outcomes.
2.2. State the sample space and the random function in the following experiments:
(1) Toss three coins and observe the outcome on each coin. Suppose we win $3 for
every head, and lose $2 for every tail. Let X = net winnings.
(2) The movement of a coin on a game board is based on the outcome of tossing two
dice. If the outcome is not a double, move the sum of the two outcomes, or else
move twice the sum of the two outcomes. X = the number of spaces the coin is
moved.
2.3. Compute the pmf of the total number of heads obtained on three independent tosses of
a fair coin.
2.4. Compute the pmfs of the random variables defined in Computational Problem 2.1.
Assume all outcomes in the sample space are equally likely.
2.5. Compute the pmfs of the random variables defined in Computational Problem 2.2.
Assume all outcomes in the sample space are equally likely.
2.6. Compute the pmf of the random variable Y defined in Example 2.3. Assume all outcomes
in the sample space are equally likely.
2. 7. A multiple choice question has five choices, only one of which is correct. A student is
given one point if he circles the right answer, and a -1/4 point if he circles a wrong answer.
If a student does not know the answer and picks a random answer to circle, compute the
distribution of the points the student will get for that question.
2.8. Compute the cdf of the random variable in Example 2.19.
2.9. Suppose the weather condition on a given day is classified as dry or wet. Assume that
the weather conditions on successive days are independent, and the probability of a wet
day is .3. We say that there is a rainy spell on day n if the days n - 2, n - 1, and n are
wet. Let Xn be the indicator random variable of a rainy spell on day n, n > 2. Compute the
distribution of Xn.
2.10. A patient is tested for blood sugar every morning. If his sugar level is outside the
normal range for 2 days in a row, he is started on a sugar control regime. Suppose the
successive sugar levels are independent, and the probability of the sugar level being outside
the normal range is p. Let X be the day the patient is put on the sugar control regime. What is
the state space of X? Is X a geometric random variable? Compute P(X = k) fork= 2, 3, 4.
2.11. Suppose the patient in Computational Problem 2.10 is declared as having no sugar
problem if he is not put on a sugar control regime for the first 4 days. Let X be 1 if the
patient is declared as problem free, and 0 otherwise. Compute the distribution of X.
2.12. A coin is tossed 10 times in an independent fashion. It is declared to be a fair coin if
the number of heads and tails on the 10 trials differ at most by 2. Let X be the indicator of
60 2. Univariate Random Variables
the event that the coin is declared to be fair. If the probability of heads is p, compute the
distribution of X.
2.13. Suppose that each incoming customer to a store is female with probability .6 and male
with probability .4. Assuming that the store had nine customers in the first hour, what is the
probability that the majority of them were females?
2.14. Redo Example 2.12 for the odd parity protocol, i.e., the parity digit is set to one or
zero so as to make the total number of ones in the byte an odd number.
2.15. Suppose a family has six children. Compute the distribution of the number of girls in
the six children if each child is equally likely to be a boy or a girl.
2.16. Consider the k-out-of-n system of Conceptual Problem 2.24. The probability that a
component is functioning at time t is given to be e-r. Compute the probability that the
system is functioning at time t for n = 3, k = 2.
2.17. Each lottery ticket has a 15-digit number. Each digit of the winning number is decided
by a random draw of a ball (with replacement) from a basket containing three hundred balls.
Thirty of the balls are labeled 0, thirty are labeled 1, and so on. What is the probability that
at least three of the digits of the winning number are seven or more?
2.18. A couple decides to have children until a daughter is born. What is the distribution
of the number of children born to the couple if each child is equally likely to be a girl or a
boy?
2.19. A couple decides to have children until two sons are born. What is the distribution of
the number of children born to the couple if each child is equally likely to be a girl or a boy?
2.20. Consider the machine of Example 2.13. Suppose a shock causes a unit damage to
the machine with probability .1 and no damage with probability .9. Successive shocks are
independent. Suppose the damages are cumulative and the machine can withstand at most
four units of damage. (That is, the machine fails when the fifth unit of damage is inflicted
on it.) What is the probability that the kth shock kills the machine?
2.21. A student takes a test repeatedly until he passes it three times in total. If the probability
of passing the test on any given attempt is .7 and is independent of the other tests, what is
the probability that the student will have to repeat the test exactly seven times?
2.22. Suppose the number of movies produced during a summer season is a P(8) random
variable. Each movie ticket is $5. If a person has a budget of $25 for summer movies, what
is the probability that he/she will be able to see all the movies during the season?
2.23. In a city of 2.5 million residents, each person has a probability of 1o- 6 of carrying the
TB infection, independent of each other. What is the probability that the city has at least
five TB patients? Approximate the answer using a Poisson distribution.
2.24. A broker gives a client a choice of 10 mutual funds, six bonds and eight stocks for
building a portfolio. Suppose the client chooses exactly five of these financial instruments
in a random fashion. What is the pmf of the number of mutual funds picked by the client?
2.12. Problems 61
if x > 2a.
x ~ 2a, (2.51)
if X > 1.
1, (2.53)
2.31. The lifetime X of a radioactive atom is exponentially distributed with mean 2138
years. What is its half-life, i.e., what is the value of x such that P(X > x) = .5?
62 2. Univariate Random Variables
2.32. The weight of a ketchup bottle is Erlang distributed with k = 10 and).= .25 (oz)- 1•
The bottle is declared to be under weight if the weight is under 39 oz. What is the probability
that the bottle is declared under weight?
2.33. Consider Example 2.24. Suppose there are two vendors and each provides 50% of the
items. The lifetime (in days) of an item from the first vendor is Exp(.l), and that from the
second vendor is Exp(.08). Compute the probability that a randomly picked item will last
more than 12 days.
2.34. The temperature indicator of an industrial oven indicates that the temperature is 1200°
Fahrenheit. However, the actual temperature is distributed as aN ormal random variable with
parameters 1-t = 1200 and a 2 = 400. What is the probability that the actual temperature is
greater than 1230°?
2.35. Suppose X has the density given in Computational Problem 2.25. Compute the density
of2X + 3.
2.36. Suppose X has the density given in Computational Problem 2.27. Compute the density
of X2 .
2.37. Suppose X has the density given in Computational Problem 2.29. Compute the cdf of
(X- 2) 2 .
other is Erl(2, Jl ). If the aim is to maximize the probability that the lifetime of the product
is greater than 8 months, which of the two products should be chosen?
2.47. Compute the expected value of the random variable with pdf as given in Computational
Problem 2.25.
2.48. Compute the expected value of the random variable with pdf as given in Computational
Problem 2.27.
2.49. Compute the expected value of the random variable with pdf as given in Computational
Problem 2.29.
2.50. Compute the variance of the random variable with pdf as given in Computational
Problem 2.25.
2.51. Compute the variance of the random variable with pdf as given in Computational
Problem 2.27.
2.52. Compute the variance of the random variable with pdf as given in Computational
Problem 2.29.
2.53. The lifetime of an item is an exponential random variable with mean 5 days. We replace
this item upon failure or at the end of the fourth day whichever occurs first. Compute the
expected time of replacement.
2.54. Consider the k-out-of-n system of Computational Problem 2.16. Suppose we visit this
system at time t = 3 and replace all the failed components, at a cost of $75 each. If the
system has failed, it costs us an additional $1000. Compute the expected total cost incurred
at time 3.
3_____________________
Next we investigate how the random nature of the multivariate random variables can be
described mathematically. Let X = (XI, X2, ... , X 11 ) be a multivariate random variable
with state space S. Following the discussion in Section 2.2 we see that we can describe
such a random variable by giving its multivariate cumulative distribution function (cdf) as
defined below.
The probabilities of other events associated with the multivariate random variable can be
computed in terms of its multivariate cdf. For example, we can show that in the bivariate case
As in the univariate case, a multivariate discrete random variable can be described by its
multivariate probability mass function (pmf) defined below.
Definition 3.4 (Multivariate pmf). Let X = (X 1 , Xz, ... , X11 ) be a multivariate random
variable with state space S = S1 x S2 x · · · x Sn. The function
p(XJ, Xz, ... , X11 ) = P(XI =XJ, Xz =Xz, ... , Xn =X11 ), X; E S; for I :::: i :::: n,
is called the multivariate pmf or joint pmf of X.
The multivariate cdf of a multivariate discrete random variable X can be computed from its
multivariate pmf, and vice versa. Hence multivariate pmf is an equivalent way of describing
a multivariate discrete random variable.
3.3. Multivariate Continuous Random Variables 67
TABLE 3.1. The pmf P(X 1 = k1, X 2 = k2 ) for the two dice example.
kz t k1 ~ 1 2 3 4 5 6
1 2 2 2 2 2
1 - - - - - -
36 36 36 36 36 36
2 0
1
- -2 2
- -
2
-2
36 36 36 36 36
I 2 2 2
3 0 0 -36 -36 -36 -
36
4 0 0 0 -
1
-2 2
-
36 36 36
I 2
5 0 0 0 0 - -
36 36
I
6 0 0 0 0 0 -
36
Example 3.2 (Tossing Two Dice). Let (X 1, X2) be as defined in Example 3.I. The bivariate
pmf (i.e., multivariate pmf for a bivariate random variable) of (X 1 , X2 ) is given in Table 3.1.
0
Example 3.3 (Multinomial Random Variable). Consider an experiment that can result in
one and only one of r distinct outcomes. Let p; be the probability of observing outcome
i, I :S i :S r. We assume that p; > 0 and PI + P2 + · · · + p, = I. Suppose this experiment
is repeated n times in an independent fashion. Let X; be the number of times outcome i
is observed in these n trials. Then X = (X 1, X2, ... , X,) is called a multinomial random
variable. Its state space is
(k) _ n! k1 k1 k,
k E S. (3.2)
P - k 1k 1 ••• k 1P1 P2 · · · Pr ,
I· 2 · r·
JO such that
(3.3)
X is also called jointly continuous and f is called the multivariate pdf or joint pdf of X.
Suppose the multivariate cdf F(x 1, Xz, ... , x11 ) of X = (X 1 , X 2 , ... , X11 ) is a continuous
and piecewise differentiable function of (x 1, x 2 , ... , X11 ). Let
an
j(XI, X2, ... , Xn) = F(XI, X2, ... , X11 ). (3.4)
ax! ax2 ... axn
Then X is a multivariate continuous random variable with multivariate pdf JO given above
if (3.3) is satisfied. We can intuitively interpret the multivariate pdf as follows:
P(x; <X;:::; X;+ h;, 1:::; i:::; n) ~ f(xi, Xz, ... , X11 )h1h2 · · · h11 •
Any function f(x 1, x2 , ... , X11 ) is a valid multivariate density if it satisfies the following:
and
1 1 ···1
00
-oo
00
-oo
00
-oo
j(UJ,U2, ... ,U 11 )du1du2···dun = 1. (3.6)
11 2 2
c(u1 + u2)du1 du2 = 8c = 1.
Hence
c= s·I
For 0 :::; x 1, x2 :::; 2, the joint cdf is given by
Thus the marginal cdf of X; is the same as the cdf of the univariate random variable X;.
The marginal cdf of X; can be computed from the joint cdf of X as follows:
We classify the random variable X; as discrete or continuous based on its marginal cdf,
using the definitions of Chapter 2. Then we define the concepts of the marginal pmf of X;
if it is discrete, and marginal pdf of X; if it is continuous.
The marginal pmf of X; can be computed from the joint pmf of X as follows:
Px,(x) = P(X; = x)
= L ···LL ···L p(XJ, • .. , X;-J, X,Xi+I• ... , Xn). (3.11)
XJ x.
Here the last equation follows from the law of total probability. Thus the marginal pmf of
X; is obtained by summing the multivariate pmf over all other coordinates.
Example 3.5 (Tossing Two Dice). Let X1 and X2 be as defined in Example 3.1. The joint
pmf of (X 1, X2) is shown in Table 3.1. The marginal pmfs of X1 and Xz are given in
Table 3.2. The entries in the table are computed by using the following equations:
6
P(XJ = k1) = L P(XJ = k1, Xz = kz),
kz=I
6
P(Xz = kz) = L P(XJ = k1, Xz = kz), I ::: kz ::: 6.
0
kJ=l
70 3. Multivariate Random Variables
TABLE 3.2. The marginal pmfs Px 1 (k), px2 (k) for the two dice example.
k 1 2 3 4 5 6
1 3 5 7 9 11
P(X 1 = k) -
36
-
36
-
36
-36 -36 -36
11 9 7 3
P(X 2 = k) - -5 -
1
36 36 36 36 36 36
Example 3.6 (Multinomial Random Variable). Consider the Multinomial random variable
X = (X 1, X2 , .•. , X,) with joint pmf as given in (3.2). Using (3.11) we compute the margi-
nal pmf of X 1 as follows:
PxJk,) = P(X, = kJ)
= I: ... I: p(k,. k2 • ... , k, >
kz k,
_"' "' n! k1 kz k,
- 1....J .. · i....J k 1k 1 ••• k 1P1 P2 · · · P,
kz k, I . 2. r.
= n! ki
PJ
L . . . L (n- ki)! P2 ... p' kz k
k,!(n-kl)! kz k, k2! .. ·k,! '
·
n' k1 ( + P3 + · · · + Pr )n-k
-k-,-(---k-)-
1 P1 P2
1
I· n I ·
n'
k I·' (n ~ k I )'p~~(l-
·
p,t-kl, 0:::; k,:::; n.
Here we have used
PI + P2 + P3 + ···+ Pr = 1
and the multinomial expansion formula
"' · · ·"
'-..J
kl
i....J' n! k1 Xkz · ·
X1 2
k = ( XJ
·X,' + X2 + · · · + Xr) n ,
k, k,! .. ·k,!
where the sum is taken over all nonnegative integers (k,, k2, ... , k,) such that k1 + k2 +
···+k, = n. We see that X 1 is a Bin(n, Pi) random variable. In a similar way we can show
that the marginal distribution of Xi is Bin(n, Pi). D
Definition 3.8 (Marginal pdf). Suppose Xi is a continuous random variable. The function
fx/) is called the marginal pdf of Xi if
Suppose X is a multivariate continuous random variable. Then the marginal pdf of X; can
be computed from the joint pdf of X as follows:
Here the last equation follows from the law of total probability. Thus the marginal pdf is
obtained by integrating the multivariate pdf over all other coordinates.
Example 3.7 Compute the marginal pdf for the bivariate density function given in
Example 3.4.
L:
From (3.13) we have, 0 ~ x 1 ~ 2,
= 1 2
i<x1 + xz)dxz
= 1o +xi).
From symmetry we get
!xl(xz) = 10 + xz), 0 ~ x2 ~ 2. 0
So far we have discussed computing the marginal cdf, pmf, or pdf of Xi from the joint
cdf, pmf, or pdf of (X 1, Xz, ... , Xn). These results can be extended to computing the joint
distributions of (Xi, X j ), i # j. We give the final result below, without proof. We use
i = 1, j = 2 for concreteness.
Example 3.8 (Multinomial Random Variable). Let (XJ, X2 , ... , X,) be a Multinomial
random variable with joint pmf as given in Example 3.3. Compute the joint pmf of (X 1 , X2 ).
Using (3.15) and Example 3.6 we get
or (in the discrete case) their marginal pmfs are identical, i.e.,
or (in the continuous case) their marginal pdfs are identical, i.e.,
3.5. Independence
The concept of independence arises naturally when we study multivariate random variables.
We have encountered this concept in connection with events in Section 1.8. Recall that events
A and B are said to be independent if
P(AB) = P(A)P(B).
This suggests that the "independence" of two random random variables should imply
P(X1 E A; X2 E B)= P(X1 E A)P(X2 E B)
for all subsets A and B of real numbers. This prompts the following fonnal definition:
Definition 3.10 (Independent Random Variables). The jointly distributed random vari-
ables (X 1 , X2 , ... , Xn) are said to be independent if
F(xl, X2, ... , Xn) = Fx 1 (XI)Fx 2 (X2) ... Fxn(Xn),
In many applications we shall encounter random variables X 1, X 2 , •.. , Xn that are inde-
pendent and have identical marginal distributions. Such random variables are called
independent and identically distributed random variables, or iid random variables for
short.
3.5. Independence 73
Example 3.9. Consider a bivariate random variable (X 1, X2) with joint pdf as given in
Example 3.4. Are X1 and X2 independent?
The marginal pdfs of X1 and Xz are given in Example 3.7. From those results we see that
Hence the random variables X1 and X2 are not independent. They are, however, identically
distributed. 0
= P(X1 ~ t; Xz ~ t; ... ; Xn ~ t)
Z=X1+Xz+ .. ·+Xn.
First consider the discrete case. Let p(x 1, x2) be the bivariate pmf of (X 1, Xz) and let
Z = X1 + Xz. Then
pz(z) = P(Z = z)
= P(X1 + Xz = z)
= LP(X1 = x1; Xz = z -x1). (3.17)
Here the last equality follows from the law of total probability.
k I
We have used the binomial expansion of (p 1 + p2 )k to evaluate the last sum. The last
expression implies that X 1 + X2 is a Bin(n, p1 + p 2 ) random variable. 0
Next consider the continuous case. Let f(x 1, xz) be the bivariate pmf of (X 1, Xz) and let
Z = X1 + X2 • Then we have
Fz(z) = P(Z ~ z)
= P(X 1 +Xz ~ z)
3.6. Sums of Random Variables 75
d 100 1Z-X2
=- f(xJ, xz)dxl dxz
dz -oo -oo
1
= 00 f(z- xz, Xz)dxz.
-oo
(3.18)
Example 3.13. Consider a bivariate random variable (X 1 , X 2 ) with joint pdf as given in
Example 3.4. Compute the density of Z = X 1 + X 2 .
From Example 3.4 we have the joint pdf of (X 1, X 2 ) as follows:
Since 0 :S X 1 , X 2 ::: 2, we see that 0 ::: Z ::: 4. Also, if Z = z, then we must have
max(O, z - 2) :S x 2 :S min(2, z) in order to keep 0 :S x 1, x2 :S 2. Substituting in (3.18) we
i:
get, for 0 ::: z ::: 4,
= 1 min(2.z)
max(O.z-2)
k<z- Xz + Xz)dx 2
= kCz)(min(2, z) - max(O, z - 2))
if 0 ::: z ::: 2,
D
if 2 ::: z ::: 4.
(3.22)
where the last equality was obtained from the well-known Binomial identity:
Recall that a B(p) random variable is the same as a Bin(l, p) random variable. Hence the
above result can be used to show the following: Let Xi, I ~ i ~ n, be iid B(p) random
variables. Then X1 + Xz + ··· + Xn is a Bin(n, p) random variable.
(3.23)
Thus, (3.23) implies that the sum of independent Poisson random variables P(A. 1) and P()'-2),
is a P(A. 1 +A- 2) random variable. This can be extended to sums of more than two independent
Poisson random variables. 0
3.7. Expectations 77
i:
When (X 1, X2 ) are continuous independent random variables, (3.18) reduces to
Example 3.16 (Sums of Exponentials). Suppose X 1and X2 are iid Exp(A.) random variables.
Compute the pdf of Z = X1 + X2 .
i:
Using (3.24) we get
= 1z A.e-).(z-x2l)ce-).x2 dxz
= A.2e-).z 1z dxz
= e-).z(A.2z)
= A.e-).z (A.z)l.
1!
The last expression can be recognized as the pdf of an Erl(2, A.) random variable. Thus the
sum of two iid Exp(A.) random variables is an Erl(2, A.) random variable. Similarly we can
show that the sum of n iid Exp(A.) random variables is an Erl(n, A.) random variable. 0
3.7. Expectations
We studied the expectations of univariate random variables and of functions of univariate
random variables in Section 2.1 0. In particular, we saw in Theorem 2.4 that if X is a
univariate random variable, then
if X is discrete,
(3.26)
if X is continuous.
Now suppose X = (X 1, Xz, ... , Xn) is a multivariate random variable. Letg(x 1, Xz, ... , Xn)
be a real-valued function of (x1, Xz, ... , Xn). Then Z = g(X 1, Xz, ... , Xn) is a univariate
random variable, and hence has an expectation. We can compute this expectation by first
computing the pdf or pmf of Z, but this is in general difficult. Fortunately, Theorem 2.4
extends to the multivariate case. We state it below without proof.
78 3. Multivariate Random Variables
(3.27)
The above theorem makes it easy to compute the expectations of functions of multivariate
random variables. As a special case, consider the function
1
X) Xn
where the last equation follows from (3.13). This is consistent with the definition of the
expectation of X 1 . In the discrete case we get
E(X1) = I>tPx (XJ).
XJ
1
Proof. We consider the continuous case. The discrete case follows similarly. From Theorem
3.lweget
E(Xt + Xz + .. · + Xn)
= 11· ··1 (Xt + Xz + ···+ Xn)f(xJ, Xz, ... , Xn)dxt dxz · · · dxn
11· ··1
X! X2 Xn
+11· ·
XJ X2 X11
1 1 1
XI Xz Xn
Thus the expected value of a sum of a fixed number of random variables is the sum of
the expected values of those random variables. This holds even if the random variables are
not independent! In fact this result provides an important tool for the computation of the
expected values of random variables.
Example 3.17 (Random Pairing). Consider the random pairing experiment discussed in
Example 1.16. Compute the expected number of women that get paired with their own
husbands.
Let X; be 1 if the ith woman gets paired with her own husband. Now X; is a B(1 / n) random
variable (see Example 2.10). Hence
1
E(X;) = -.
n
The number of women who get paired with their own husbands is given by
X=Xt+X2+ .. ·+Xn.
Note that X 1, ••• , Xn are dependent random variables. However, (3.28) remains valid.
Hence we get
E(X) = E(Xt) + E(X2) + · · · + E(Xn)
1 1 1
=-+-+ .. ·+-
n n n
=1.
Thus regardless of the number of couples involved in the game, on average, one couple will
get paired correctly! 0
Example 3.18 (Expectation of Binomial). Let Xi, 1 ::::; i ::::; n, be iid B(p) random vari-
ables. We have argued earlier that X= X1 + X2 + · · · + Xn is aBin(n, p) random variable.
Hence
E(X) = E(Xt) + E(X2) + · · · + E(Xn) = np.
The above equation follows because E(Xi) = p for all1 ::::; i ::::; n. D
Example 3.19 (Expectation of an Erlang). Let Xi, 1 ::::; i ::::; n, be iid Exp(.A.) random
variables. Using Example 3.16 we can show that X= X1 + X2 + · · · + Xn is an Erl(n, .A.)
random variable. Hence
n
E(X) = E(Xt) + E(X2) + · · · + E(Xn) = -.
).
The above equation follows because E(X;) = 1/.A. for alii ::::; i ::::; n. 0