Steven R. Dunbar
Department of Mathematics
203 Avery Hall
University of Nebraska-Lincoln
Lincoln, NE 68588-0130
Probability Theory and Stochastic Processes
Steven R. Dunbar
Mathematically Mature: may contain mathematics beyond calculus with proofs.
Consider a family with 5 children. What is the probability of having all ﬁve children be boys? How many children must a couple have for at least a 0.95 probability of at least one girl? What is a proper and general mathematical framework for setting up the answer to these questions and similar questions?
An elementary experiment in this section consists of an experiment with two outcomes. An elementary experiment is also called a Bernoulli trial. Label the outcomes of the elementary experiment , occurring with probability and , occurring with probability , where . Often we name as success and as failure. For example, a coin toss would be a physical experiment with two outcomes, say with “heads” labeled as success, and “tails” as failure.
A composite experiment consists of repeating an elementary experiment times. The sample space, denoted is the set of all possible sequences of 0’s and 1’s representing all possible outcomes of the composite experiment. We denote an element of as , where each or . That is, . We assign a probability measure on by multiplying probabilities of each Bernoulli trial in the composite experiment according to the principle of independence. Thus, for ,
and inductively for each
Additionally, let be the number of 1’s in . Note that . We also say is the number of successes in the composite experiment. Then
We can also deﬁne a uniﬁed sample space that is the set of all inﬁnite sequences of 0’s and 1’s. We sometimes write . Then is the projection of the ﬁrst entries in .
A random variable is a function from a set called the sample space to the real numbers . For example as a frequently used special case, for let
then is an indicator random variable taking on the value or . (the dependence on the sequence is usually suppressed) indicates success or failure at trial . Then as above,
is a random variable indicating the number of successes in a composite experiment.
Remark. The notation indicates that we are considering a family of probability measures indexed by on the sample space .
Proof. From the inductive deﬁnition
and inductively for each
the probability assigned to an having 1’s and 0’s is . The sample space has precisely such points. By the additive property of disjoint probabilities,
and the proof is complete. □
Proof. First Proof: By the binomial expansion
Diﬀerentiate with respect to and multiply both sides of the derivative by :
Now choosing ,
For the variance, diﬀerentiate the binomial expansion with respect to twice:
Multiply by , substitute ,and expand:
Proof. Second proof: Use that the sum of expectations is the expectation of the sum, and apply it to the corollary with with .
Similarly, use that the sum of variances of independent random variables is the variance of the sum applied to with . □
Example. The following example appeared in the January 20, 2017 “Riddler” puzzler on the website fivethirtyeight.com.
You and I ﬁnd ourselves indoors one rainy afternoon, with nothing but some loose change in the couch cushions to entertain us. We decide that well take turns ﬂipping a coin, and that the winner will be whoever ﬂips 10 heads ﬁrst. The winner gets to keep all the change in the couch! Predictably, an enormous argument erupts: We both want to be the one to go ﬁrst.
What is the ﬁrst ﬂippers advantage? In other words, what percentage of the time does the ﬁrst ﬂipper win this game?
First solve an easier version of the puzzle where the ﬁrst person to ﬂip a head will win. Let the person who ﬂips ﬁrst be A, and the probability that A wins by ﬁrst obtaining a head is . Then adding the probabilities for the disjoint events that the sequence of ﬂips is H, or TTH, or TTTTH and so forth.
Another way to do this problem would be to use ﬁrst-step analysis from Markov Chain theory. Then the probability of the ﬁrst player winning is the probability of winning on the ﬁrst ﬂip plus the probability of both players each losing their ﬁrst ﬂip at which point the game is essentially starting over,
Now extend the same reasoning as in the ﬁrst approach to the case of the ﬁrst player to get 10 heads winning. The ﬁrst case for A to win is to get heads in ﬂips and the th head on ﬂip and for player B to get anywhere from to heads on ﬂips . This is probability and cumulative binomial probability respectively. The next disjoint probability case is for A to win is to get heads in ﬂips and the th head on ﬂip and for player B to get anywhere from to heads on ﬂips . This is probability and cumulative binomial probability respectively. In general, the disjoint probability case is for A to win is to get heads in ﬂips and the th head on ﬂip and for player B to get anywhere from to heads on ﬂips . This is probability and cumulative binomial probability respectively.
Then multiplying the independent probabilities for A and B in each case and adding all these disjoint probabilities
There does not seem to be an exact analytic or closed form expression for this probability as in the case of winning with a single head, so we need to approximate it. In the case of winning with 10 heads, .
Example. The following example appeared in the August 5, 2018 “Riddler” puzzler on the website fivethirtyeight.com.
I ﬂip a coin. If it is heads, I win the game. If it is tails, then I have to ﬂip again, now needing to get two heads in a row to win. If, on my second toss, I get another tails instead of a heads, then I now need three heads in a row to win. If, instead, I get a heads on my second toss (having ﬂipped a tails on the ﬁrst toss) then I still need to get a second heads to have two heads in a row and win, but if my next toss is a tails (having thus tossed tails-heads-tails), I now need to ﬂip three heads in a row to win, and so on. The more tails youve tossed, the more heads in a row youll need to win this game.
I may ﬂip a potentially inﬁnite number of times, always needing to ﬂip a series of heads in a row to win, where is and is the number of cumulative tails tossed. I win when I ﬂip the required number of heads in a row.
What are my chances of winning this game?
Some winning sequences of ﬂips are H, THH, TTHHH, THTHHH. From here the winning sequences get more numerous and more complicated. For winning with heads in a row, the shortest sequence is TTTHHHH to the longest THTHHTHHHH. But instead of considering the possibility of winning, consider instead the complementary probability of losing.
Let be the probability of losing when we have ﬂipped our th tail. Two possibilities can happen from here. First, we could ﬂip the heads in a row needed to win. Second, the complementary event is that we could ﬂip another tails before getting the necessary heads to win. Then the probability of losing is
In other words, if we don’t ﬂip the required heads in a row, we have the situation where we lose with probability . Then we can use this to form the product
The probability of winning this game is . This can be obtained by multiplying all the chances throughout the game that we don’t win, and subtracting from :
This expression is approximately , so there is about a chance of winning. This value is easily approximated and veriﬁed with a script, see the exercises.
This is the value using the Euler function
This function is the basic example of a relation between combinatorics and analysis. The coeﬃcient in the formal power series expansion for gives the number of all partitions of .
This section is adapted from: Heads or Tails, by Emmanuel Lesigne, Student Mathematical Library Volume 28, American Mathematical Society, Providence, 2005, Sections 1.2 and Chapter 4 . The ﬁrst example is heavily adapted from the weekly “Riddler” column of January 20, 2017 from the website fivethirtyeight.com. The second example is adapted from the weekly “Riddler” column of August 3, 2018 from Riddler, Where on Earth is the Riddler?..
The following Octave code in ineﬃcient in the sense that it generates far more trials than it needs. However, writing the code that captures exactly the number of ﬂips needed on each trial would probably take more lines, so it is easy to be ineﬃcient here.
I check all the information on each page for correctness and typographical errors. Nevertheless, some errors may occur and I would be grateful if you would alert me to such errors. I make every reasonable eﬀort to present current and accurate information for public use, however I do not guarantee the accuracy or timeliness of information on this website. Your use of the information from this website is strictly voluntary and at your risk.
I have checked the links to external sites for usefulness. Links to external websites are provided as a convenience. I do not endorse, control, monitor, or guarantee the information contained in any external website. I don’t guarantee that the links are active at all times. Use the links here with the same caution as you would all information on the Internet. This website reﬂects the thoughts, interests and opinions of its author. They do not explicitly represent oﬃcial positions or policies of my employer.
Information on this website is subject to change without notice.
Steve Dunbar’s Home Page, http://www.math.unl.edu/~sdunbar1
Email to Steve Dunbar, sdunbar1 at unl dot edu
Last modiﬁed: Processed from LATEX source on September 11, 2018