How to calculate the massive growth of factorials using simple natural logarithms
In short: Factorials grow at a staggering rate, making them difficult to compute for large numbers. Stirling's approximation provides a brilliant shortcut, turning complex multiplication into a manageable logarithmic equation. By leveraging the properties of integrals and error terms, mathematicians can estimate these values with remarkable precision using only a few constants.
Factorials, denoted as n!, represent the product of all positive integers up to n. As n increases, this product expands rapidly, creating computational hurdles. Stirling's approximation, often called Stirling's formula, offers an asymptotic way to estimate these values. While named after James Stirling, who refined the constant in 1730, the initial breakthrough came from Abraham de Moivre in 1721. De Moivre provided a general form involving an unknown constant, but it was Stirling who identified that this constant is precisely the square root of 2π.
The mechanism behind the approximation relies on the natural logarithm of the factorial. Because the logarithm of a product is the sum of the logarithms of its factors, one can approximate the sum using an integral. By applying the Euler-Maclaurin formula, mathematicians can refine this estimate, accounting for the trapezoid rule error and higher-order terms. The resulting formula, n! ≈ √(2πn) * (n/e)^n, ensures that the ratio between the actual factorial and the approximation tends toward 1 as n approaches infinity.
This mathematical tool is not merely theoretical; it is essential in fields like computer science. When determining the lower bounds for comparison sorting algorithms, researchers often use a binary logarithm version of the formula to simplify calculations. The approximation remains highly accurate even for relatively small values of n, providing a robust bridge between discrete factorials and continuous functions. By transforming a product into an exponential expression involving the mathematical constant e, Stirling's formula turns an intractable calculation into a standard operation.
Opens the Intellect+ feed with this card first. Swipe up for the next one.
Sources
- Summary by Intellect · source: Stirling's approximation
To cite this card, link to https://intellectplus.co.uk/app/science-stirling-s-approximation.
How we source, check and correct cards: Editorial standards.
General information, not professional advice. Spotted an error? Flag the card or see corrections and complaints.
Intellect Plus is a visual educational discovery platform for exploring fascinating facts and ideas. Brain Food, Not Brain Rot. What is Intellect Plus?
Related
More in Functions · More in Science · Latest · A–Z · All topics