From n! up to n^n there are only n terms, but this is not the most remarkable

Consider the formula:

n!=n^n-C_n^1(n-1)^n+C_n^2(n-2)^n-C_n^3(n-3)^n+...+(-1)^{( n-1)}C{_n}^{(n-1)}

If we consider the Stirling formula in the form of a series:

n! = \sqrt{2\pi n}(\frac{n}{e})^n(1+\frac{1}{12 n}+\frac{1}{288n^2}-\frac{139} {51840 n^3}+…)

Let us introduce the following notation:

-\delta(n)=n!-n^n

We get the formula:[\frac{\sqrt{2\pi n}(1+\frac{1}{12 n}+\frac{1}{288n^2}-\frac{139}{51840 n^3}+...)}{e^n-\sqrt{2\pi n}(1+\frac{1}{12 n}+\frac{1}{288n^2}-\frac{139}{51840 n^3}+...)}] n!  \approx \delta(n)

(**)

Let's calculate the formula (**), let's say for n=20.20!-20^{20}=-104857597567097991823360000

twenty! \approx 2.4329028230918*10^{18}

In this case, the exact value is: 20!=2432902008176640000

A formula of the form (**) shows the relationship between the Stirling series and the series of n terms from the right side of the formula

.However, if we take into account that

n!=(\frac{n}{e})^n \sqrt{2 \pi n}\sum_{k=0}^{\infty}\frac{a_k}{n^k} a_k=\sum_{j=1}^{2k}(-1)^j\frac{d_3(2k+2j,j)}{2^{j+k}(j+k)!},k \in N, (***)where

d_3(n,m)

– the number of permutations of n elements with m cycles, each of which has a length of at least 3.

Comtet L. Advanced Combinatorics: The Art of Finite and Infinite Expansions. – D. Reidel Publishing Company, 1974. – 267 p.It turns out a remarkable relationship between a finite number of terms containing binomial coefficients and series (***).