High School Mathematics · Grades 10–12
33Random Variables and the Binomial Distribution
A random variable attaches a number to each outcome of an experiment: a gain, a count, a duration. Its expectation is the long-run average of the values it produces, its variance measures their spread. The star of this chapter is the binomial distribution, which counts successes in repeated independent trials. Random variables and the binomial distribution were first met in Chapters 18 and 19; this chapter reviews and deepens them, with the combinatorial tools of Chapter 27 now available.
33.1 Discrete random variables
Definition 33.1 (Random variable, distribution)
A random variable on a finite sample space is a function . Its distribution (or law) is the data of its possible values and of the probabilities
Definition 33.2 (Expectation, variance, standard deviation)
The expectation of is
its variance and standard deviation are
Proposition 33.3 (König–Huygens formula)
.
Proof. Write and expand:
∎
Proposition 33.4 (Affine transformation)
For :
Proof. The first is a rearrangement of the defining sum. For the second, deviates from its mean by , and squaring multiplies by . ∎
Example 33.5 (Fair games)
A game costs euros; a die is rolled, and the player receives the value shown if it is at least , nothing otherwise. The gain takes values (probability ), (), ():
On average, the player loses cents per game: the game is unfavorable (as most real games are).
33.2 Bernoulli trials and the binomial distribution
Definition 33.6 (Bernoulli distribution)
A Bernoulli trial is an experiment with two outcomes, success (probability ) and failure (). The indicator of success ( on success, on failure) follows the Bernoulli distribution :
(Indeed , , and König–Huygens gives .)
Definition 33.7 (Binomial distribution)
Repeat a Bernoulli trial times independently, and let be the total number of successes. The distribution of is the binomial distribution .
Theorem 33.8
If , then for :
and
Proof. A specified sequence of outcomes with successes and failures has probability by independence; the number of such sequences is the number of ways to place the successes among the trials, namely (Chapter 27). Summing over the sequences gives the formula — and the binomial theorem confirms .
For the expectation, using (Exercise 27.7):
The variance formula is proved similarly with the identity , giving , whence . (A structural proof — the variance of a sum of independent variables — comes with Theorem 34.4.) ∎
Method 33.9 (Recognizing a binomial situation)
Check the three ingredients before writing : a fixed number of trials; two outcomes per trial with the same success probability ; independence of trials (sampling with replacement, or from a large population). Then use
for “at least one success”, and a calculator or cumulative tables for general .
Example 33.10
How many times must one roll a die to have at least a chance of rolling a six? With : means , i.e. : from rolls on.
33.3 Exercises
Exercise 33.1 ★
A random variable takes the values with probabilities . Compute , and .
Solution
Solution of Exercise 33.1.
. , so by König–Huygens and .
Exercise 33.2 ★
A multiple-choice test has questions, each with choices, one of which is correct. A student answers uniformly at random, independently. Let be the number of correct answers.
- Give the distribution of , and .
- Compute , and .
Solution
Solution of Exercise 33.2.
1. The questions are independent Bernoulli trials with : , , .
2. ;
Exercise 33.3 ★
An insurance company insures clients; each files a claim during the year with probability , independently. Let be the number of claims. Identify the distribution of and compute its expectation and standard deviation.
Exercise 33.4 ★★
In the game of Example 33.5, the organizer wants a fair game () by changing the entry price . Find . Compute the variance of the gain for this fair version; is “fair” the same as “riskless”?
Solution
Solution of Exercise 33.4.
The payment received satisfies , so the fair price is euros. The fair gain takes values with probabilities :
A fair game has zero average gain but its outcomes still fluctuate: fair is not riskless.
Exercise 33.5 ★★
A basketball player scores free throws with probability . She shoots times (independent shots). Compute the probability that she scores: exactly ; at least ; at least once. What is the most probable number of scores?
Exercise 33.6 ★★
An airline knows that each booked passenger shows up with probability , independently. A flight has seats and the airline sells tickets. Express, using a binomial distribution, the probability that more passengers show up than there are seats, and bound it numerically using a calculator (give the exact expression).
Solution
Solution of Exercise 33.6.
The number of passengers showing up is ; the flight is overbooked when :
Selling more tickets than seats causes an incident on only about of flights — the economics behind overbooking.
Exercise 33.7 ★★
Let . Show that
and deduce that the distribution increases up to and decreases afterwards (the mode of the binomial).
Exercise 33.8 ★★★
(Saint Petersburg, tamed.) A fair coin is tossed until heads appears, but at most times. Let be the number of tosses used, and the player receives euros if heads appeared, otherwise.
- Give the distribution of restricted to the winning outcomes: for , and check the total probability of winning.
- Compute the expected payoff. What would it become without the cap of tosses?
Solution
Solution of Exercise 33.8.
1. Heads first at toss means tails then heads: probability , for . Total winning probability (the game is lost only on ten consecutive tails).
2. Expected payoff:
Without the cap, the sum diverges: the expected payoff is infinite, although the game almost always pays a small amount — the famous Saint Petersburg paradox, showing that expectation alone does not measure the value of a game.
33.4 Problem: The overbooked flight
Problem 33.1
Weekend problem — airlines sell more seats than they have, factories accept lots they barely inspected, and the binomial distribution referees both
An airline with seats happily sells tickets: about of passengers never show up, and empty seats earn nothing. How far can the airline push before bumped passengers eat the profit? The binomial distribution (Theorem 33.8) answers to the decimal — and the same machinery inspects factory lots, prices raffles, and keeps insurers solvent. Decisions under repetition: this is the binomial’s day job.
Part I — Fluency.
- Give the full distribution table of the number of sixes in three rolls of a die.
- Compute and (Definition 33.2).
- A stall charges euro for three rolls and pays euros per six obtained. Compute the expected gain: fair game?
- Checklist practice (Method 33.9): is the number of hearts in cards drawn without replacement binomial? With replacement? Justify.
- For : give and , then and for the score (Proposition 33.4).
Part II — The overbooked flight. Seats: . Tickets sold: . Each ticket-holder shows up with probability , independently; let be the number who show.
- Model: justify with the checklist — and confess the model’s weakest point (are no-shows really independent? think groups and storms).
- Compute and .
- Bumping occurs when : write as an explicit sum of five binomial terms.
- Evaluate the sum (calculator): what fraction of flights sees at least one bumped passenger?
- Money: the five extra tickets bring euros; each bumped passenger costs euros in compensation. Compute the expected number of bumped passengers, , the expected compensation, and the verdict on the policy.
- Design: the regulator tolerates . By testing tickets, find the largest allowed .
- The bell shortcut: for , compute the z-score of the bumping threshold, , and compare the crude “about , so roughly – in the upper tail” estimate with your exact answer. (The curve behind this shortcut is the next chapters’ star.)
Part III — The factory gate. A lot of parts is accepted if a sample of contains at most one defective part.
- If the true defect rate is (an honest lot), compute the probability of acceptance.
- If the rate is (a bad lot), compute it again.
- Name the two risks of the procedure (the honest lot rejected; the bad lot accepted), read their values from questions 13–14, and say what single change improves both at once — at what cost.
- Behind the improvement: show that the observed defect frequency in a sample of size has standard deviation , and conclude how precision scales with sample size (an old friend: the of grade 10).
Part IV — Games, raffles, reserves.
- The capped Saint Petersburg game of Exercise 33.8 has expected payoff euros. Contrast in one paragraph with the uncapped paradox met in Problem 18.1: what exactly does the cap tame, and what price would now be fair?
- A charity raffle sells tickets at euros; prizes: one -euro and two -euro baskets. Compute a ticket’s expected gain and the raffle’s margin; compare with European roulette’s house margin of . Why does the raffle get away with it?
- An insurer holds independent policies: claim probability each, claim size euros, premium euros. Compute the expected annual profit and the standard deviation of total claims. Compare the two numbers: what does the comparison force real insurers to hold?
- Finale — the binomial as decision referee: the recognition checklist; the compass ; tail probabilities as the price of risk; and the two standing caveats (independence is a modeling claim, and rare tails, not means, cause ruin). One sentence each, with the pointer: the law of large numbers and the bell curve, next chapters, complete the referee’s rulebook.
Solution
Solution of Problem 33.1.
1. : , , , .
2. ; .
3. Expected payout euro against a -euro stake: gain — exactly fair (a rarity).
4. Without replacement the draws are dependent (the second card’s chances depend on the first): not binomial — the checklist’s independence box fails. With replacement: fixed , constant , independent draws: binomial.
5. , . ; .
6. Fixed trials (the tickets), each a show/no-show with the same , assumed independent: binomial. The confession: families miss flights together and storms empty whole planes — independence is the model’s leap of faith, and correlated no-shows make the tails fatter than the binomial promises.
7. ; .
8. .
9. : about one flight in sixty bumps anyone at all.
10. passengers per flight: expected compensation euros — against euros of extra revenue. Overbooking by five is overwhelmingly profitable; hence every airline does it.
11. From the table of tail probabilities: : ; : ; : . The largest compliant sale is tickets.
12. : the threshold sits two standard deviations above the mean, and the bell-curve rule of thumb (“upper tail ”) lands close to the exact — the smooth curve shadowing the binomial is the coming chapters’ protagonist.
13. : the honest lot passes of the time.
14. : the bad lot still sneaks through of the time.
15. Producer’s risk: a good lot rejected (); consumer’s risk: a bad lot accepted (). A larger sample (with a proportional acceptance threshold) shrinks both — at the cost of more inspection: quality has a budget line.
16. : standard deviation . Quadruple the sample, halve the noise: the law of grade 10’s fluctuation intervals, now derived.
17. The cap bounds the payout at euros, so each of the ten rounds contributes exactly euro of expectation: . The uncapped game’s infinite expectation came entirely from astronomically rare, astronomically large payoffs; capping confesses that no bank pays euros. A fair ticket price for the capped game: euros — and suddenly nobody is paradoxed.
18. Expected prize money per ticket: euro against a -euro ticket: margin — eighteen times roulette’s . The raffle survives because its players are knowingly donating: the “loss” is the point.
19. Expected claims: ; premiums : expected profit euros. Standard deviation of total claims: euros — one ordinary bad year devours the whole expected profit. Hence capital reserves, reinsurance, and portfolios far larger than a thousand policies: insurers live off the law of large numbers and keep reserves against its slowness.
20. Checklist first — fixed , same , independence claimed — or no binomial at all. Then navigate by : means locate, deviations warn. Then price the tails: bumping, bad lots, ruinous years all live beyond . Caveats: independence is the modeler’s promise, not the world’s; and expectation ignores exactly what destroys you. The rulebook’s missing pages — how fast frequencies settle, and what shape the fluctuations take — are the next two chapters.