Limit of Error in Stirling's Formula

Theorem
Consider Stirling's Formula:
 * $n! \sim \sqrt {2 \pi n} \paren {\dfrac n e}^n$

The ratio of $n!$ to its approximation $\sqrt {2 \pi n} \paren {\dfrac n e}^n$ is bounded as follows:
 * $e^{1 / \paren {12 n + 1} } \le \dfrac {n!} {\sqrt {2 \pi n} n^n e^{-n} } \le e^{1 / 12 n}$

Proof
Let $d_n = \ln n! - \paren {n + \dfrac 1 2} \ln n + n$.

From the argument in Stirling's Formula: Proof 2: Lemma 3 we have that $\sequence {d_n - \dfrac 1 {12 n} }$ is an increasing sequence.

Then:

Let:
 * $\map f x := \dfrac 1 {2 x} \ln \dfrac {1 + x} {1 - x} - 1$

for $\size x < 1$.

By Stirling's Formula: Proof 2: Lemma 1:


 * $\ds \map f x = \sum_{k \mathop = 1}^\infty \frac {x^{2 n} } {2 n + 1}$

As $-1 < \dfrac 1 {2 n + 1} < 1$ it can be substituted for $x$ from $(1)$:

Next:

It follows that:

The numerator equals:
 * $12 n \paren {14 - 12} + \paren {13 - 36} = 24 n - 23 > 0$

for $n = 1, 2, 3, \ldots$

Therefore the sequence $\sequence {d_n - \dfrac 1 {12 n + 1} }$ is decreasing.

From Stirling's Formula, we have that:
 * $\ds \lim_{n \mathop \to \infty} d_n = d$

where $d = \ln \sqrt{2 \pi}$

and so:
 * $d_n - \dfrac 1 {12 n} < d < d_n - \dfrac 1 {12 n + 1}$

for $n = 1, 2, 3, \ldots$

Taking exponentials, and again from Stirling's Formula:
 * $e^{-1 / 12 n} < \dfrac {\paren {\sqrt{2 n} } n^{n + 1/2} e^{-n} } {n!} < e^{-1/\paren {12 n + 1} }$

from whence the result.