Library · Geometric Probability · Chapter 7
Broken stick, second break on the longer piece
Problem 7.1
A unit stick is broken at a uniform random point . Of the two resulting pieces, the longer one is then broken at a uniform random point along its length. What is the probability that the three resulting pieces form a triangle?
Solution. By symmetry between the two outcomes and , we may condition on ; the other case is handled identically by reversing the stick. So take , giving a shorter piece of length and a longer piece of length . Now break the longer piece: let be uniform, giving two pieces of lengths and .
The three lengths are , , and . They form a triangle iff each is less than the sum of the other two, equivalently iff each is less than : The first is automatic under our conditioning. The remaining two are: Given , is uniform on , so Integrating over with density (after conditioning on ): Evaluate: So
Compare with the ordinary two-cut broken stick of Chapter 2: breaking at two independent uniform points of the whole stick, the three pieces form a triangle iff no piece exceeds , which happens with probability . Breaking the longer piece second gives , which is larger than : this biased procedure increases the chance, by . (The value belongs instead to Chapter 1, where three lengths are sampled independently from , a different model.) The problem is a well-known variant in the Putnam / Eastern European olympiad tradition.
import numpy as np
x = np.random.rand(10**7) # first break point
short = np.minimum(x, 1 - x)
longp = 1 - short # longer piece
y = np.random.rand(10**7) * longp # second break on the longer piece
pieces = np.stack([short, y, longp - y])
triangle = (pieces < 0.5).all(axis=0)
print(f"sim: {triangle.mean():.5f} exact: {2*np.log(2) - 1:.5f}")
# sim: 0.38640 exact: 0.38629