Stirling's Approximation Proof

633 Views Asked by At

I was searching for the reason why Stirling's Approximation holds true. I found the website Stirling's Approximation which apparently shows why this is the case. Does this part of the equation make sense in the proof? If so why?

$$\int_{1}^{n}\ln(x)dx\approx\sum_{k=1}^{n}\ln(k)$$

2

There are 2 best solutions below

1
On BEST ANSWER

For large $n$, the approximation holds, because $$\sum_{k=1}^{n-1} \log k = \int_{x=1}^n \log \lfloor x \rfloor \, dx < \int_{x=1}^n \log x \, dx < \int_{x=1}^n \log \lceil x \rceil \, dx = \sum_{k=2}^n \log k.$$ Therefore, the error between the integral and sum is at most $O(\log n)$, which is what the asymptotic statement of Stirling's approximation provides: $$\log n! \sim n \log n - n + O(\log n).$$

0
On

Think of it as a Riemann sum sampling at the points $2$ to $n$. Note $\log{1} = 0.$ Since the $\log$ function is increasing,

$$ \int_1^N\log x \: dx = \sum_{k=1}^{n-1} \int_k^{k+1} \log x \: dx > \sum_{k=1}^{n-1} \log{(k+1)} = \sum_{k=2}^{n} \log k.$$