Library · The Fiddler: Solutions · Chapter 75
Can You Sweep the Series?
In a best-of-seven series the favoured team wins each game independently with probability . For which range is “winning in exactly five games” the single most likely of the eight possible series results?
The Fiddler, Zach Wissner-Gross, May 9, 2025(original post)
Solution
Writing , the favoured team wins in games with probabilities and the losing results are smaller in this regime. Win-in-five beats win-in-four when and beats win-in-six when , i.e. So the range is (that is, ).
The computation
Tabulate all eight series outcomes (win or lose in to games) and, scanning , mark where “win in five” is the single largest. The marked band runs from to .
import numpy as np
def best(p):
q = 1 - p
d = {'w4': p**4, 'w5': 4*p**4*q, 'w6': 10*p**4*q**2, 'w7': 20*p**4*q**3,
'l4': q**4, 'l5': 4*q**4*p, 'l6': 10*q**4*p**2, 'l7': 20*q**4*p**3}
return max(d, key=d.get)
ps = [p for p in np.linspace(.001, .999, 99999) if best(p) == 'w5']
print(round(min(ps), 3), round(max(ps), 3)) # 0.6 0.75
Extra Credit
Let be the probability that the Celtics (the favourites) sweep the Knicks in four games, and the probability that the series goes to seven games, with either team winning. Suppose is chosen uniformly at random from the interval found above, so that the likeliest result is the Knicks losing in five. How likely is it that is greater than ?
Solution
A Celtics sweep means winning the first four games: . The series reaches a seventh game exactly when the first six games split three apiece, which happens in orders, so , where . Dividing by , the sweep is likelier when As rises the left side increases and the right side decreases, so they cross exactly once. At the right side is , larger than . At it is , smaller than . So the crossing lies inside the interval, and the sweep is likelier for . In terms of , the crossing solves . That cubic has one real root, , so . The fraction of the interval above it is about percent. So for a slight majority of the plausible values of , a seven-game series is the likelier of the two, and Stephen A. Smith’s “closer to a sweep” is true only a little less than half the time.
The computation
The check plays out the series instead of using the formulas for and . For a given it runs through all win-loss sequences, stops each series once a team has four wins, and adds up the probability of a four-game Celtics sweep and of a seventh game. It then takes evenly spread values of across the interval, standing in for the uniform choice, and counts how often the sweep is likelier. Finally it bisects for the crossing point.
from itertools import product
def outcomes(p):
"""Play out all 2^7 game sequences; series stops at four wins."""
sweep = seven = 0.0
for games in product((1, 0), repeat=7): # 1 = Celtics win
prob = 1.0
for g in games: prob *= p if g else 1 - p
c = k = 0
for n, g in enumerate(games, 1):
c += g; k += 1 - g
if c == 4 or k == 4: break
if n == 4 and c == 4: sweep += prob
if n == 7: seven += prob
return sweep, seven
a, b, M = 0.6, 0.75, 3000
grid = [a + (b - a)*(i + 0.5)/M for i in range(M)] # uniform p, midpoints
share = sum(s > t for s, t in map(outcomes, grid)) / M
lo, hi = a, b # where the two cross
for _ in range(50):
mid = (lo + hi)/2
s, t = outcomes(mid)
if s > t: hi = mid
else: lo = mid
print("share of p with sweep likelier: %.4f" % share)
print("crossover p = %.6f, share = %.5f" % (hi, (b - hi)/(b - a)))
It prints
share of p with sweep likelier: 0.4893
crossover p = 0.676582, share = 0.48945
The grid count agrees to within its spacing, and the bisection gives the boxed value.