Analytic and optimized approximations to the median of the gamma distribution
Richard F. Lyon
Abstract
The median νΓ(α) of the gamma distribution has no closed form, but its behavior at both ends is known: it is asymptotic to 2-1/αe-γ (with γ being the Euler-Mascheroni constant) as the shape parameter α 0, and approaches α- 1/3 as α ∞. We write approximations as interpolations (1 - g)ν0 + gν∞ between two elementary-function bounds or approximations, each exact in one limit, with an interpolator g(α) going from 0 to 1, and compare three such forms: a first one between previously proven bounds, a second ending in an approximation from the beta median that is exact at α= 1 but does not quite approach α- 1/3 as α ∞, and a third one, between bounds proved here, that corrects the large-α end of the second. For each form, the ideal interpolator's slope at 0, approach to 1, and value at α= 1 are derived in closed form. Rational interpolators with every coefficient set in closed form from these properties, with no numerical fitting, reach a worst relative error of 0.0011 over all α> 0, with absolute error below 0.0002. Fitting some of these or other coefficients numerically to minimize the worst absolute-or-relative error then trades accuracy against complexity: the Pareto frontier reaches 0.000087 with two fitted constants and 0.000041 with five, and from two on uses degree-4 rationals of the second form with no α2 term in the numerator. The proofs that the end functions of the first and third forms are bounds are machine-checked in Lean 4.
Create a lesson
Related papers
On the median of the beta distribution in relation to the median of the gamma distribution
Shared title terminology · Richard F. Lyon
Geometry, Local Minimax Risk, and the Limits of Sample Average Approximation in Linear Stochastic Optimization
Shared title terminology · Hanbo Yang, Ming Yuan
Approximating Distributions on Vertex Degrees in Random Hypergraphs via Stein's Method
Shared title terminology · Xianghe Zhu, Wenkai Xu, Gesine Reinert
Beyond least-favorable distribution pairs: asymptotically instance-optimal robust hypothesis testing
Shared title terminology · Aytijhya Saha, Aaditya Ramdas
Simple Private Noisy SGD is Minimax-Optimal under Population Strong Convexity
Shared title terminology · Valentin Roth, Marco Avella Medina
The Scaled Dirichlet Distribution: Lauricella Representations and Estimation
Shared title terminology · Jared N. Lakhani