Let's start with a definite integral:
∫02πsinnxdx
We can derive the following result:
∫02πsinnxdx=−∫02πsinn−1xd(cosx)
Using integration by parts, where ∫udv=uv−∫vdu, we get:
−∫02πsinn−1xd(cosx)=−(sinn−1xcosx)02π+∫02πcosxd(sinn−1x)
=∫02πcos2x⋅(n−1)sinn−2xdx=(n−1)∫02π(sinn−2x−sinnx)dx
Thus:
∫02πsinnxdx=(n−1)∫02π(sinn−2x−sinnx)dx
We get:
n∫02πsinnxdx=(n−1)∫02πsinn−2xdx⟹∫02πsinnxdx=nn−1∫02πsinn−2xdx
Therefore:
For even n, i.e., n=2k:
∫02πsin2kxdx=2k2k−1∫02πsin2k−2xdx=2k2k−1⋅2k−22k−3⋯21∫02πsin0xdx=2k2k−1⋅2k−22k−3⋯21⋅2π
For odd n, i.e., n=2k+1:
∫02πsin2k+1xdx=2k+12k∫02πsin2k−1xdx=2k+12k⋅2k−12k−2⋯32∫02πsin1xdx=2k+12k⋅2k−12k−2⋯32
Here, we need the double factorial:
m!!=m(m−2)(m−4)⋯
Thus:
∫02πsin2kxdx=(2k)!!(2k−1)!!⋅2π
∫02πsin2k+1xdx=(2k+1)!!(2k)!!
Since sin2k+1x<sin2kx<sin2k−1x for x∈(0,2π), we have:
∫02πsin2k+1xdx<∫02πsin2kxdx<∫02πsin2k−1xdx
Substituting the above formulas:
(2k+1)!!(2k)!!<(2k)!!(2k−1)!!⋅2π<(2k−1)!!(2k−2)!!
We can examine the difference between the bounds for ∫02πsin2kxdx:
k→∞lim((2k−1)!!(2k−2)!!−(2k+1)!!(2k)!!)=k→∞lim((2k−1)!!(2k−2)!!−2k+12k⋅(2k−1)!!(2k−2)!!)=k→∞lim2k+11⋅(2k−1)!!(2k−2)!!=0
Note: Here 2k−12k−2<1
For the inequality:
(2k+1)!!(2k)!!<(2k)!!(2k−1)!!⋅2π<(2k−1)!!(2k−2)!!
Multiply all terms by (2k−1)!!(2k)!!:
(2k+1)!!(2k−1)!!(2k)!!2<2π<(2k−1)!!2(2k−2)!!(2k)!!
We can further examine the difference between the bounds for 2π:
k→∞lim((2k−1)!!2(2k−2)!!(2k)!!−(2k+1)!!(2k−1)!!(2k)!!2)=k→∞lim(2k1−2k+11)⋅(2k+1)!!(2k−1)!!(2k)!!2=k→∞lim2k1⋅(2k+1)!!2(2k)!!2=0
Thus, we obtain Wallis's Formula:
k→∞lim(2k+1)!!(2k−1)!!(2k)!!2=2π
This formula introduces Wallis's result in preparation for deriving Stirling's formula.
Stirling's formula reveals a relationship between n!, nn, and en.
As n approaches infinity, n! is approximately 2πn(en)n.
First, introduce a limit:
n→∞lim(nnn!)n1=e1
Proof:
n→∞lim(nnn!)n1=n→∞limen1ln(nnn!)
which is equivalent to proving:
n→∞limn1ln(nnn!)=−1
We have:
n→∞limn1ln(nnn!)=n→∞limn1(lnn1+lnn2+⋯+lnnn)=∫01lnxdx=(xlnx−x)01=−1
QED.
Thus,
nnn!∼en1
We would like to verify:
n→∞limnnn!en=1
Let’s test this.
Using the ratio test:
an=nnn!en,an+1=(n+1)n+1(n+1)!en+1
n→∞limanan+1=(1+n1)ne>1
Although the limit of the expression is e, it is always approaching e from below, so it is still greater than 1, indicating that an is divergent.
Mathematicians have attempted various approaches and found:
an=nn+21n!en
To prove that an converges, use the ratio test again:
an=nn+21n!en,an+1=(n+1)n+23(n+1)!en+1
n→∞limanan+1=(1+n1)n+21e
Compare this with:
(1+n1)n+21=e(n+21)ln(1+n1)
and e.
Thus, compare:
(n+21)ln(1+n1)
with 1.
Specifically, compare lnnn+1 with n+211:
Since:
n+11<ln(1+n1)<n1
Note: The right side follows from the inequality ln(1+x)<x (for x=0).
The left side follows from: 1−n+1n<ln(nn+1), where n+1n is considered as a whole. This is high school knowledge.
Because x1 is a concave function:
∫nn+1x1dx=lnnn+1>n+211
Therefore:
n→∞limanan+1=(1+n1)n+21e<1
Thus, an is monotonically decreasing and an>0, so it must converge, i.e., it has a limit.
Let:
n→∞limnn+21n!en=a
Then, we need to find this limit.
From the earlier Wallis formula:
k→∞lim(2k+1)!!(2k−1)!!(2k)!!2=2π
(2n)!!=2n(2n−2)⋯2=2nn!
(2n−1)!!=(2n)!!(2n)!=2nn!(2n)!
(2n+1)!!=(2n+2)!!(2n+2)!=2n+1(n+1)!(2n+2)!
Thus, Wallis' formula becomes:
n→∞lim(2n)!(2n+2)!16n(n!)4(2n+2)=2π
Using:
n!∼ae−nnn+21
Substitute into:
n→∞lim4(nn+1)2n+23a2e2=2π
Solve for:
a=2π
Thus, as n approaches infinity:
n!∼2πe−nnn+21
or equivalently:
n!∼2πn(en)n