Math 141Lecture 5: Expected Value
Albyn Jones1
1Library [email protected]
www.people.reed.edu/∼jones/courses/141
Albyn Jones Math 141
History
The early history of probability theory is intimately related toquestions arising in gambling.
For example:
Two gamblers playing a game that ends when one has wonall of the other’s money have to quit in the middle of thegame. What is the fair division of the pot?What is the fair price of a lottery ticket?
Albyn Jones Math 141
History
The early history of probability theory is intimately related toquestions arising in gambling.
For example:Two gamblers playing a game that ends when one has wonall of the other’s money have to quit in the middle of thegame. What is the fair division of the pot?
What is the fair price of a lottery ticket?
Albyn Jones Math 141
History
The early history of probability theory is intimately related toquestions arising in gambling.
For example:Two gamblers playing a game that ends when one has wonall of the other’s money have to quit in the middle of thegame. What is the fair division of the pot?What is the fair price of a lottery ticket?
Albyn Jones Math 141
Expected Value
Definition: Let X be a random variable with sample space
Ω = x0, x1, x2, . . .
with corresponding probabilities
P(X = x0) = p0, P(X = x1) = p1, P(X = x2) = p2, . . .
Then the expected value of X , denoted E(X ) is
E(X ) = x0p0 + x1p1 + x2p2 . . .
Expected value is just the weighted average of the set ofpossible outcomes, with weights equal to the probability eachoutcome occurs.
Albyn Jones Math 141
Example: Y ∼ Bernoulli(p)
Bernoulli Trials: Each trial results in either a 1 or a 0.
P(Y = 1) = p P(Y = 0) = (1− p) = q
Expected Value:
E(Y ) = (0 · q) + (1 · p) = p
Albyn Jones Math 141
Example: Y ∼ Bernoulli(p)
Bernoulli Trials: Each trial results in either a 1 or a 0.
P(Y = 1) = p P(Y = 0) = (1− p) = q
Expected Value:
E(Y ) = (0 · q) + (1 · p) = p
Albyn Jones Math 141
Die Rolls: Discrete Uniform
Let X be the outcome of the roll of a fair die:
Ω = 1,2,3,4,5,6
Fair: each value occurs with probability 1/6.
E(X ) = (1 · 16
) + (2 · 16
) + (3 · 16
) + (4 · 16
) + (5 · 16
) + (6 · 16
)
Adding it up:
E(X ) =216
= 3.5
Albyn Jones Math 141
Example: X is Geometric(p)
Probabilities: For k = 0,1,2, . . .
P(X = k) = p · qk
Expectation by Definition:
E(X ) = (0 · p · q0) + (1 · p · q1) + (2 · p · q2) + . . .
A Math 112 exercise in summing an infinite series.
Albyn Jones Math 141
Example: X is Geometric(p)
Probabilities: For k = 0,1,2, . . .
P(X = k) = p · qk
Expectation by Definition:
E(X ) = (0 · p · q0) + (1 · p · q1) + (2 · p · q2) + . . .
A Math 112 exercise in summing an infinite series.
Albyn Jones Math 141
Example: X is Geometric(p)
Probabilities: For k = 0,1,2, . . .
P(X = k) = p · qk
Expectation by Definition:
E(X ) = (0 · p · q0) + (1 · p · q1) + (2 · p · q2) + . . .
A Math 112 exercise in summing an infinite series.
Albyn Jones Math 141
Expectation by Heuristic:
Consider how long we wait for each six when rolling a fairdie. In the long run, roughly 1 of every 6 rolls is a six. Thusthe long run average must be 5 non-sixes before each six.
Consider how long we wait for Heads when tossing a faircoin. In the long run, roughly 1 of every 2 tosses yieldsHeads. Thus the long run average is 1 Tail before eachHeads.
5 = 6− 1 =1
1/6− 1 =
5/61/6
1 = 2− 1 =1
1/2− 1 =
1/21/2
1p− 1 =
1− pp
=qp
Albyn Jones Math 141
Expectation by Heuristic:
Consider how long we wait for each six when rolling a fairdie. In the long run, roughly 1 of every 6 rolls is a six. Thusthe long run average must be 5 non-sixes before each six.Consider how long we wait for Heads when tossing a faircoin. In the long run, roughly 1 of every 2 tosses yieldsHeads. Thus the long run average is 1 Tail before eachHeads.
5 = 6− 1 =1
1/6− 1 =
5/61/6
1 = 2− 1 =1
1/2− 1 =
1/21/2
1p− 1 =
1− pp
=qp
Albyn Jones Math 141
Expectation by Heuristic:
Consider how long we wait for each six when rolling a fairdie. In the long run, roughly 1 of every 6 rolls is a six. Thusthe long run average must be 5 non-sixes before each six.Consider how long we wait for Heads when tossing a faircoin. In the long run, roughly 1 of every 2 tosses yieldsHeads. Thus the long run average is 1 Tail before eachHeads.
5 = 6− 1 =1
1/6− 1 =
5/61/6
1 = 2− 1 =1
1/2− 1 =
1/21/2
1p− 1 =
1− pp
=qp
Albyn Jones Math 141
Expectation by Heuristic:
Consider how long we wait for each six when rolling a fairdie. In the long run, roughly 1 of every 6 rolls is a six. Thusthe long run average must be 5 non-sixes before each six.Consider how long we wait for Heads when tossing a faircoin. In the long run, roughly 1 of every 2 tosses yieldsHeads. Thus the long run average is 1 Tail before eachHeads.
5 = 6− 1 =1
1/6− 1 =
5/61/6
1 = 2− 1 =1
1/2− 1 =
1/21/2
1p− 1 =
1− pp
=qp
Albyn Jones Math 141
InterpretationWhat does expected value mean?
Physics analog: Center of mass of the probabilitydistribution.
In the long run: Sometimes more, sometimes less, but onthe average...Gambling: The fair price of a wager.Average as typical value: The average family has 2.4children.Silly question? How many families have 2.4 children?Synonyms: average, mean, expectation value
Albyn Jones Math 141
InterpretationWhat does expected value mean?
Physics analog: Center of mass of the probabilitydistribution.In the long run: Sometimes more, sometimes less, but onthe average...
Gambling: The fair price of a wager.Average as typical value: The average family has 2.4children.Silly question? How many families have 2.4 children?Synonyms: average, mean, expectation value
Albyn Jones Math 141
InterpretationWhat does expected value mean?
Physics analog: Center of mass of the probabilitydistribution.In the long run: Sometimes more, sometimes less, but onthe average...Gambling: The fair price of a wager.
Average as typical value: The average family has 2.4children.Silly question? How many families have 2.4 children?Synonyms: average, mean, expectation value
Albyn Jones Math 141
InterpretationWhat does expected value mean?
Physics analog: Center of mass of the probabilitydistribution.In the long run: Sometimes more, sometimes less, but onthe average...Gambling: The fair price of a wager.Average as typical value: The average family has 2.4children.
Silly question? How many families have 2.4 children?Synonyms: average, mean, expectation value
Albyn Jones Math 141
InterpretationWhat does expected value mean?
Physics analog: Center of mass of the probabilitydistribution.In the long run: Sometimes more, sometimes less, but onthe average...Gambling: The fair price of a wager.Average as typical value: The average family has 2.4children.Silly question? How many families have 2.4 children?
Synonyms: average, mean, expectation value
Albyn Jones Math 141
InterpretationWhat does expected value mean?
Physics analog: Center of mass of the probabilitydistribution.In the long run: Sometimes more, sometimes less, but onthe average...Gambling: The fair price of a wager.Average as typical value: The average family has 2.4children.Silly question? How many families have 2.4 children?Synonyms: average, mean, expectation value
Albyn Jones Math 141
Median: another measure of location
Definition: MedianLet X be a RV, then any number m satisfying
P(X ≤ m) ≥ 12
andP(X ≥ m) ≥ 1
2is a median. The median of a distribution may not be unique.
Albyn Jones Math 141
Median: examples
Consider a population with values for some variable X
1,1,2,3,4,5,10
What is the median?
3 satisfies the definition: at least half the population is lessthan or equal to 3, and at least half is greater than or equalto 3.Consider a population with values for some variable X
1,1,2,3,4,10
What is the median?Any number in the interval [2,3]!
Albyn Jones Math 141
Median: examples
Consider a population with values for some variable X
1,1,2,3,4,5,10
What is the median?3 satisfies the definition: at least half the population is lessthan or equal to 3, and at least half is greater than or equalto 3.
Consider a population with values for some variable X
1,1,2,3,4,10
What is the median?Any number in the interval [2,3]!
Albyn Jones Math 141
Median: examples
Consider a population with values for some variable X
1,1,2,3,4,5,10
What is the median?3 satisfies the definition: at least half the population is lessthan or equal to 3, and at least half is greater than or equalto 3.Consider a population with values for some variable X
1,1,2,3,4,10
What is the median?
Any number in the interval [2,3]!
Albyn Jones Math 141
Median: examples
Consider a population with values for some variable X
1,1,2,3,4,5,10
What is the median?3 satisfies the definition: at least half the population is lessthan or equal to 3, and at least half is greater than or equalto 3.Consider a population with values for some variable X
1,1,2,3,4,10
What is the median?Any number in the interval [2,3]!
Albyn Jones Math 141
Expectation as Typical Value
For a symmetric, unimodal population, the mean and medianagree, and both seem typical:
−3 −2 −1 0 1 2 3
0.00.1
0.20.3
0.40.5
Z
Dens
ity
Albyn Jones Math 141
Expectation as Typical Value
The mean is not so typical for a multimodal or skewedpopulation:
0 5 10 15
0.00.2
0.40.6
0.8
X
Dens
ity
median
mean
Albyn Jones Math 141
Expectation as Typical Value: Income
US Household Income: According to the US Census Bureau, in2009 the median household income in the United States was$49,777, while the mean household income $67,976.
Roughly 2/3 of all households earn less than the meanhousehold income. The US has a very skewed incomedistribution. Depending on how you define income, The top 1%of the US population gets about 24% of all income, and the top10% gets close to 50% of the total.
Albyn Jones Math 141
Properties of Expected ValueBack to probability Theory!
Let X be a RV, and a and b constants, then
E(a + b · X ) = a + b · E(X )
Like any average, expected values are well behaved withrespect to translation (shift) and rescaling.
Albyn Jones Math 141
Example
Let X be a Bernoulli(1/2) trial. We know E(X ) = p = 1/2. LetY = 2 · X − 1. What is E(Y )?
From the definition: Ωy = 2 · 1− 1, 2 · 0− 1 = 1,−1,each with probability 1/2, so
E(Y ) = −1 · 12
+ 1 · 12
= 0
Using the linearity of E:
E(Y ) = E(2X − 1) = 2E(X )− 1 = 2 · 12− 1 = 0
Albyn Jones Math 141
Example
Let X be a Bernoulli(1/2) trial. We know E(X ) = p = 1/2. LetY = 2 · X − 1. What is E(Y )?
From the definition: Ωy = 2 · 1− 1, 2 · 0− 1 = 1,−1,each with probability 1/2, so
E(Y ) = −1 · 12
+ 1 · 12
= 0
Using the linearity of E:
E(Y ) = E(2X − 1) = 2E(X )− 1 = 2 · 12− 1 = 0
Albyn Jones Math 141
Example
Let X be a Bernoulli(1/2) trial. We know E(X ) = p = 1/2. LetY = 2 · X − 1. What is E(Y )?
From the definition: Ωy = 2 · 1− 1, 2 · 0− 1 = 1,−1,each with probability 1/2, so
E(Y ) = −1 · 12
+ 1 · 12
= 0
Using the linearity of E:
E(Y ) = E(2X − 1) = 2E(X )− 1 = 2 · 12− 1 = 0
Albyn Jones Math 141
Expected Values scale like averages
The average height of an adult female in the US is about 64inches. What is the average height of an adult female in the USin centimeters?
The conversion factor is 2.54 cm per inch. Thus the averageheight of an adult female in the US is
2.54cmin× 64 in ≈ 162.5 cm
Albyn Jones Math 141
More Properties of Expected ValueE is a linear operator
Let X and Y be RV’s, and a and b constants, then
E(a · X + b · Y ) = a · E(X ) + b · E(Y )
Thusthe expected value of a sum is the sum of the expectedvalues:
E(X + Y ) = E(X ) + E(Y )
Albyn Jones Math 141
Expected Value of a Binomial
Let X be a Binomial(n,p) RV. From the definiton of expectation,
E(X ) =k=n∑k=0
k ·(
nk
)pkqn−k
which may be algebraically challenging for some. But we canthink of X as the sum of n (independent) Bernoulli(p) trials Yi ,each with E(Yi) = p, so
E(X ) = E(Y1 + . . .Yn) = E(Y1) + . . .E(Yn) = np
Albyn Jones Math 141
Example: Coin Tossing
Toss a fair coin 100 times, and count the number of Heads.What is the expected number of Heads?
Albyn Jones Math 141
The Poisson
Let X ∼ Poisson(µ). What is E(X )?
Hint: X is like a Binomial(n,p) with large n and small p, wherewe define µ = n · p.
Albyn Jones Math 141