Library · Geometric Probability · Chapter 47

Expected perimeter of a random triangle in a disc

Revised Report an error

Problem 47.1

Let P1,P2,P3P_1, P_2, P_3 be three points chosen independently and uniformly at random in the closed unit disc. What is the expected value of the perimeter of the triangle they form?

Solution. The perimeter of △P1P2P3\triangle P_1 P_2 P_3 is ∣P1P2∣+∣P2P3∣+∣P3P1∣|P_1 P_2| + |P_2 P_3| + |P_3 P_1|. By linearity of expectation, E[perimeter]=3⋅E[∣P1P2∣],\mathbb{E}[\text{perimeter}] = 3 \cdot \mathbb{E}[|P_1 P_2|], where P1,P2P_1, P_2 are iid uniform in the unit disc.

The constant E[∣P1P2∣]\mathbb{E}[|P_1 P_2|] is a classical “line-picking” constant, first computed by Czuber in 1884: E[∣P1P2∣]=12845π≈0.9054.\mathbb{E}[|P_1 P_2|] = \frac{128}{45 \pi} \approx 0.9054. (The derivation is a polar-coordinate integration that evaluates, after some effort, to this closed form.) Accepting this result, E[perimeter]=3⋅12845π=12815π≈2.716.■\boxed{\mathbb{E}[\text{perimeter}] = 3 \cdot \frac{128}{45 \pi} = \frac{128}{15 \pi} \approx 2.716.} \qedhere

Two remarks. First, the perimeter does not depend on the correlations between sides — linearity of expectation works even for dependent random variables — so we effectively get the three sides “for the price of one.” Second, the analogous mean distance between two random points of the unit square is 2+2+5ln⁡(1+2)15≈0.5214,\frac{2 + \sqrt{2} + 5 \ln(1 + \sqrt 2)}{15} \approx 0.5214, which makes the disc-perimeter 128/(15π)128 / (15 \pi) look positively elegant. (The three-dimensional cousin, the mean distance in a unit cube, is the genuinely notorious Robbins constant ≈0.6617\approx 0.6617; see Chapter 60.) The disc’s rotational symmetry is again the key.

import numpy as np
# Three uniform points in unit disc; compute triangle perimeter, average
r = np.sqrt(np.random.rand(3, 10**6))
t = np.random.rand(3, 10**6) * 2*np.pi
x, y = r*np.cos(t), r*np.sin(t)
d = lambda i, j: np.sqrt((x[i]-x[j])**2 + (y[i]-y[j])**2)
perim = d(0,1) + d(1,2) + d(2,0)
print(f"sim: {perim.mean():.5f}   exact: {128/(15*np.pi):.5f}")
# sim: 2.71704   exact: 2.71624
Report an error on this page

Reports are stored by Netlify. See the privacy note.