Library · Geometric Probability · Chapter 7

Broken stick, second break on the longer piece

Revised Report an error

Problem 7.1

A unit stick is broken at a uniform random point X∈[0,1]X \in [0, 1]. 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 X≤12X \leq \tfrac12 and X≥12X \geq \tfrac12, we may condition on X≤12X \leq \tfrac12; the other case is handled identically by reversing the stick. So take X≤12X \leq \tfrac12, giving a shorter piece of length XX and a longer piece of length 1−X1 - X. Now break the longer piece: let Y∈[0,1−X]Y \in [0, 1 - X] be uniform, giving two pieces of lengths YY and 1−X−Y1 - X - Y.

The three lengths are XX, YY, and 1−X−Y1 - X - Y. They form a triangle iff each is less than the sum of the other two, equivalently iff each is less than 12\tfrac12: X<12,Y<12,1−X−Y<12.X < \tfrac12, \quad Y < \tfrac12, \quad 1 - X - Y < \tfrac12. The first is automatic under our conditioning. The remaining two are: Y<12,Y>12−X.Y < \tfrac12, \qquad Y > \tfrac12 - X. Given XX, YY is uniform on [0,1−X][0, 1 - X], so P(triangle∣X)=12−(12−X)1−X=X1−X.\mathbb{P}(\text{triangle} \mid X) = \frac{\tfrac12 - \left( \tfrac12 - X \right)}{1 - X} = \frac{X}{1 - X}. Integrating over X∈[0,12]X \in [0, \tfrac12] with density 22 (after conditioning on X≤12X \leq \tfrac12): P(triangle)=∫01/2X1−X⋅2 dX=2∫01/2(11−X−1)dX.\mathbb{P}(\text{triangle}) = \int_0^{1/2} \frac{X}{1 - X} \cdot 2 \, dX = 2 \int_0^{1/2} \left( \frac{1}{1 - X} - 1 \right) dX. Evaluate: =2[−ln⁡(1−X)−X]01/2=2[−ln⁡12−12]=2ln⁡2−1.= 2 \left[ -\ln(1 - X) - X \right]_0^{1/2} = 2 \left[ -\ln \tfrac12 - \tfrac12 \right] = 2 \ln 2 - 1. So P(triangle)=2ln⁡2−1≈0.386.■\boxed{\mathbb{P}(\text{triangle}) = 2 \ln 2 - 1 \approx 0.386.} \qedhere

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 12\tfrac12, which happens with probability 1−34=141 - \tfrac34 = \tfrac14. Breaking the longer piece second gives 2ln⁡2−1≈0.3862 \ln 2 - 1 \approx 0.386, which is larger than 14\tfrac14: this biased procedure increases the chance, by (2ln⁡2−1)−14=2ln⁡2−54≈0.136(2 \ln 2 - 1) - \tfrac14 = 2 \ln 2 - \tfrac54 \approx 0.136. (The value 12\tfrac12 belongs instead to Chapter 1, where three lengths are sampled independently from [0,1][0,1], 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
Report an error on this page

Reports are stored by Netlify. See the privacy note.