Joint Density and Spread of Uniform Order Statistics
Let $U_1, U_2, \ldots, U_n$ be i.i.d. $\text{Uniform}(0, 1)$ random variables, and let $U_{(1)} \leq U_{(2)} \leq \cdots \leq U_{(n)}$ denote their order statistics.
- Derive the joint density of $(U_{(i)}, U_{(j)})$ for \leq i < j \leq n$.
- Compute $E[U_{(j)} - U_{(i)}]$ and $\text{Var}(U_{(j)} - U_{(i)})$.
- Interpret the gap $U_{(j)} - U_{(i)}$ as a random spread. Explain its connection to the expected time between the $i$-th and $j$-th arrivals of a unit-rate Poisson process.
Hints
- Think about how to partition the $n$ uniform variables into groups determined by the values of $U_{(i)}$ and $U_{(j)}$. How many fall below $U_{(i)}$, between $U_{(i)}$ and $U_{(j)}$, and above $U_{(j)}$?
- The marginal distribution of $U_{(k)}$ is $\text{Beta}(k, n+1-k)$. Use the known mean, variance, and covariance formulas for order statistics of uniforms to compute the moments of the gap.
- For the Poisson connection, recall that conditioned on $N(1) = n$, the arrival times of a unit-rate Poisson process on $[0,1]$ are distributed as uniform order statistics. The $n+1$ spacings form a symmetric Dirichlet distribution.
Worked Solution
How to Think About It: Order statistics of uniforms are the bread and butter of quantitative probability. The key mental picture: if you drop $n$ points uniformly on $[0,1]$ and sort them, the $k$-th smallest lands near $k/(n+1)$ on average, and the gaps between them behave like rescaled exponentials. This is exactly the connection to Poisson processes -- uniform order statistics are Poisson arrival times in disguise (after a time change). Before diving into densities, anchor yourself: $E[U_{(k)}] = k/(n+1)$, so the expected spread $E[U_{(j)} - U_{(i)}]$ should be $(j - i)/(n+1)$. That is your quick sanity check.
Quick Estimate: For a concrete case, take $n = 10$, $i = 3$, $j = 7$. The expected spread is $(7 - 3)/(10 + 1) = 4/11 \approx 0.364$. For the variance, we will derive that $\text{Var}(U_{(k)}) = k(n + 1 - k)/((n+1)^2(n+2))$. With $n = 10$, $\text{Var}(U_{(3)}) = 3 \cdot 8 / (121 \cdot 12) = 24/1452 \approx 0.0165$ and $\text{Var}(U_{(7)}) = 7 \cdot 4 / 1452 = 28/1452 \approx 0.0193$. The covariance $\text{Cov}(U_{(i)}, U_{(j)}) = i(n+1-j)/((n+1)^2(n+2))$ gives $3 \cdot 4/1452 = 12/1452 \approx 0.00826$. So $\text{Var}(U_{(7)} - U_{(3)}) \approx 0.0165 + 0.0193 - 2(0.00826) \approx 0.0193$. Let us now verify this with the general formula.
Approach: We derive the joint density by a multinomial counting argument, then read off moments from the known Beta marginals and use the Poisson-uniform connection.
Part 1: Joint Density of $(U_{(i)}, U_{(j)})$
Partition $[0,1]$ into regions determined by values $x < y$: - $i - 1$ variables fall in $[0, x)$, - 1 variable equals $x$ (the $i$-th order statistic), - $j - i - 1$ variables fall in $(x, y)$, - 1 variable equals $y$ (the $j$-th order statistic), - $n - j$ variables fall in $(y, 1]$.
The multinomial coefficient for this arrangement is:
$\frac{n!}{(i-1)! \cdot 1! \cdot (j-i-1)! \cdot 1! \cdot (n-j)!}$
Since each $U_k \sim \text{Uniform}(0,1)$, the probability element for each region contributes the length raised to the count. The joint density is:
$f_{U_{(i)}, U_{(j)}}(x, y) = \frac{n!}{(i-1)!(j-i-1)!(n-j)!} \, x^{i-1}(y - x)^{j-i-1}(1 - y)^{n-j}$
for $0 < x < y < 1$.
Part 2: $E[U_{(j)} - U_{(i)}]$ and $\text{Var}(U_{(j)} - U_{(i)})]$
The marginal density of $U_{(k)}$ is $\text{Beta}(k, n+1-k)$, giving:
$E[U_{(k)}] = \frac{k}{n+1}, \quad \text{Var}(U_{(k)}) = \frac{k(n+1-k)}{(n+1)^2(n+2)}$
By linearity:
$E[U_{(j)} - U_{(i)}] = \frac{j}{n+1} - \frac{i}{n+1} = \frac{j - i}{n+1}$
For the variance, we need $\text{Cov}(U_{(i)}, U_{(j)})$. A clean derivation: for $i \leq j$,
$E[U_{(i)} U_{(j)}] = \int_0^1 \int_0^y x \cdot y \cdot f_{U_{(i)}, U_{(j)}}(x, y) \, dx \, dy$
Using the Beta integral identity repeatedly, this evaluates to:
$E[U_{(i)} U_{(j)}] = \frac{i(j+1)}{(n+1)(n+2)}$
So:
$\text{Cov}(U_{(i)}, U_{(j)}) = \frac{i(j+1)}{(n+1)(n+2)} - \frac{ij}{(n+1)^2} = \frac{i(n+1-j)}{(n+1)^2(n+2)}$
Note the elegant form: the covariance of $U_{(i)}$ and $U_{(j)}$ equals $\text{Var}(U_{(i)})$ scaled by $(n+1-j)/(n+1-i)$. It is always positive (knowing the $i$-th order statistic is large tells you the $j$-th is likely large too). Now:
$\text{Var}(U_{(j)} - U_{(i)}) = \text{Var}(U_{(j)}) + \text{Var}(U_{(i)}) - 2\text{Cov}(U_{(i)}, U_{(j)})$
$= \frac{j(n+1-j)}{(n+1)^2(n+2)} + \frac{i(n+1-i)}{(n+1)^2(n+2)} - \frac{2i(n+1-j)}{(n+1)^2(n+2)}$
$= \frac{j(n+1-j) + i(n+1-i) - 2i(n+1-j)}{(n+1)^2(n+2)}$
Expanding the numerator:
$j(n+1) - j^2 + i(n+1) - i^2 - 2i(n+1) + 2ij$ $= (j - i)(n+1) - (j^2 - 2ij + i^2) = (j-i)(n+1) - (j-i)^2 = (j-i)(n+1-j+i)$
Therefore:
$\boxed{\text{Var}(U_{(j)} - U_{(i)}) = \frac{(j - i)(n + 1 - j + i)}{(n+1)^2(n+2)}}$
Sanity check with our earlier example: $n = 10$, $i = 3$, $j = 7$: numerator is $(j-i)(n+1-j+i) = 4 \cdot 7 = 28$, denominator is
21 \cdot 12 = 1452$, giving8/1452 \approx 0.0193$. This matches our earlier estimate of $0.0193$ exactly, confirming the formula.Part 3: Connection to Poisson Process
The fundamental link between uniform order statistics and Poisson processes is this: if $T_1, T_2, \ldots$ are the arrival times of a unit-rate Poisson process on $[0, \infty)$, and we condition on exactly $n$ arrivals in $[0, 1]$, then the $n$ arrival times -- given $N(1) = n$ -- are distributed as the order statistics of $n$ i.i.d. $\text{Uniform}(0,1)$ random variables.
Under this correspondence: - $U_{(k)}$ corresponds to $T_k / T_{n+1}$ (the $k$-th arrival, normalized by the $(n+1)$-th arrival), - The gap $U_{(j)} - U_{(i)}$ corresponds to the fraction of the total interval consumed between the $i$-th and $j$-th arrivals.
For the unconditional Poisson process, the inter-arrival times are i.i.d. $\text{Exp}(1)$, so the time from the $i$-th to the $j$-th arrival is $T_j - T_i = \sum_{k=i+1}^{j} \text{Exp}(1) \sim \text{Gamma}(j - i, 1)$, with $E[T_j - T_i] = j - i$.
The conditional version (given $n$ arrivals in $[0,1]$) compresses these gaps. The $n+1$ "spacings" $U_{(1)}, U_{(2)} - U_{(1)}, \ldots, 1 - U_{(n)}$ are jointly $\text{Dirichlet}(1, 1, \ldots, 1)$ -- i.e., they are exchangeable and each has mean
/(n+1)$. The sum of $j - i$ consecutive spacings is $U_{(j)} - U_{(i)}$, which has $\text{Beta}(j - i, n + 1 - j + i)$ distribution. This is the conditional version of the $\text{Gamma}(j - i, 1)$ inter-arrival time, normalized to $[0, 1]$.The expected gap $E[U_{(j)} - U_{(i)}] = (j-i)/(n+1)$ is exactly $(j-i)$ spacings out of $(n+1)$ total, matching the Poisson intuition that each of the $n+1$ spacings claims an equal share on average.
Answer:
- Joint density: $f_{U_{(i)}, U_{(j)}}(x, y) = \frac{n!}{(i-1)!(j-i-1)!(n-j)!} \, x^{i-1}(y-x)^{j-i-1}(1-y)^{n-j}$ for $0 < x < y < 1$.
- $E[U_{(j)} - U_{(i)}] = \frac{j - i}{n + 1}$.
- $\text{Var}(U_{(j)} - U_{(i)}) = \frac{(j-i)(n+1-j+i)}{(n+1)^2(n+2)}$.
- The gap $U_{(j)} - U_{(i)}$ is the conditional version of a $\text{Gamma}(j-i, 1)$ Poisson inter-arrival time, compressed to $[0,1]$ by conditioning on $n$ arrivals. It follows a $\text{Beta}(j-i, n+1-j+i)$ distribution.
Intuition
Uniform order statistics are one of the most interconnected objects in probability. The joint density follows from a multinomial counting argument -- you are just asking how many of the $n$ points land in each of the regions created by fixing two values. The moments come out cleanly because each order statistic is marginally Beta-distributed, and the covariance has a simple formula that reflects how knowing one order statistic constrains the others.
The deeper lesson is the Poisson-uniform duality: uniform order statistics ARE Poisson arrival times, conditioned on the total count. This is why the spacings between consecutive order statistics behave like exponentials (they are Dirichlet, which is the conditional version of independent exponentials). In practice, this connection appears constantly -- in quantile estimation, in modeling bid-ask spread dynamics, and in constructing confidence bands for empirical distributions. Whenever you see gaps between ranked values, the Poisson process framework gives you a powerful toolkit for computing their distributional properties.