If are independent random variables, each with the uniform distribution on for , then has the symmetric triangular distributionThe convolution of probability densities gives . The overlap of these two intervals has length for and is empty otherwise, proving the formula. By linearity of expectation and the variance of a sum,For , its upper-tail probability is .
A useful model for elapsed time measured from two independently truncated clock readings uses as the display resolution and as the endpoint-offset difference. Independence is essential: uniform marginal probability distributions alone do not imply this triangular distribution. For example gives with certainty. In general, with the same uniform marginals, .
Past exam of the mathematics course of the University of Cambridge 2006 iii Paper 47 3 b i Solution Created 2026-10-03 Updated 2026-10-14
Use the uniform proposal on , with density . The triangular distribution peaks at with height , so the optimal constant for this proposal is . At each attempt take two fresh pseudo-random uniforms , and propose . The rejection method accepts according toIndeed these bounds are . Part (a) proves that the accepted value has the required density. Acceptance probability is , so the method needs two proposal attempts on average, and hence four uniforms on average if each attempt uses two. The validity of the ideal algorithm presumes independent uniform draws; merely belonging to does not by itself make a pseudo-random sequence uniform or independent.
The graph is a rectangle of height one over , with zero height elsewhere. Its unit area is the required normalization of the probability density function.
Let be the finish-time offset from the start of its displayed minute. The elapsed time is , so . To obtain the stated density, use the intended model that and are independent random variables, both with the uniform distribution on .
Their joint probability density function is one on the unit square. Equivalently, the convolution of probability densities givesThe integrand is one exactly where and . The overlap has length for , length for , and zero otherwise. ThereforeThis is a symmetric triangular distribution. The independence and finish-time uniformity are additional modelling assumptions: the two truncated clock readings alone do not imply them. For example, if then the elapsed time is exactly twenty-five minutes and , even though each endpoint offset is individually uniform.
