Library · Geometric Probability · Chapter 2

The longest of three pieces

Revised Report an error

Problem 2.1

A unit stick is snapped at two independent uniform random points. What is the probability that the longest of the three resulting pieces has length greater than 12\tfrac12?

Solution. Let the break points be at positions x,y∈[0,1]x, y \in [0,1], independent uniform. The three pieces have lengths min⁡(x,y)\min(x,y), ∣x−y∣|x-y|, and 1−max⁡(x,y)1 - \max(x,y). The longest piece exceeds 12\tfrac12 iff some piece exceeds 12\tfrac12: P(longest>12)=P(min⁡(x,y)>12  or∣x−y∣>12  or1−max⁡(x,y)>12).\begin{align*} \mathbb{P}(\text{longest} > \tfrac12) = \mathbb{P}\big( &\min(x,y) > \tfrac12 \;\text{or} \\ &|x-y| > \tfrac12 \;\text{or} \\ &1 - \max(x,y) > \tfrac12 \big). \end{align*} The three events are mutually exclusive: if min⁡(x,y)>12\min(x,y) > \tfrac12 then both x,y>12x, y > \tfrac12, forcing ∣x−y∣<12|x-y| < \tfrac12 and max⁡(x,y)>12\max(x,y) > \tfrac12; similarly if max⁡(x,y)<12\max(x,y) < \tfrac12 then ∣x−y∣<12|x-y| < \tfrac12. So we may add the three probabilities directly.

Each event corresponds to a region of the unit square:

  • {min⁡(x,y)>12}=[12,1]2\{\min(x,y) > \tfrac12\} = [\tfrac12, 1]^2, area 14\tfrac14,

  • {max⁡(x,y)<12}=[0,12]2\{\max(x,y) < \tfrac12\} = [0, \tfrac12]^2, area 14\tfrac14,

  • {∣x−y∣>12}\{|x-y| > \tfrac12\} is the union of two corner triangles (upper-left and lower-right), each of area 18\tfrac18, total area 14\tfrac14.

Summing, P(longest>12)=14+14+14=34.■\boxed{\mathbb{P}(\text{longest} > \tfrac12) = \tfrac14 + \tfrac14 + \tfrac14 = \tfrac34.} \qedhere

The unit square of break points (x,y) . The central sage region — where every piece has length \leq \tfrac12 — is a bow-tie of area \tfrac14 . Its complement (copper), of area \tfrac34 , is the region where the longest piece exceeds \tfrac12 .
The unit square of break points (x,y)(x,y). The central sage region — where every piece has length ≤12\leq \tfrac12 — is a bow-tie of area 14\tfrac14. Its complement (copper), of area 34\tfrac34, is the region where the longest piece exceeds 12\tfrac12.
import numpy as np
x, y = np.random.rand(2, 10**7)
pieces = np.stack([np.minimum(x,y), np.abs(x-y), 1-np.maximum(x,y)])
p = (pieces.max(axis=0) > 0.5).mean()
print(f"sim: {p:.5f}   exact: 0.75")
# sim: 0.74991   exact: 0.75
Report an error on this page

Reports are stored by Netlify. See the privacy note.