# How to calculate decimal factorials, like $0.78!$ [duplicate]

When I enter $0.78!$ in Google, it gives me $0.926227306$. I do understand that $n! = 1\cdot2\cdot3 \cdots(n-1)\cdot n$, but not when $n$ is a decimal.

I also have seen that $0.5!=\frac12\sqrt{\pi}$.

Can anyone explain me how to calculate decimal factorials? Thanks a lot!

• – user171358
Oct 28, 2014 at 15:00

There is a function called the Gamma function, which basically interpolates the factorial function in a way that we also can have non integer arguments, which preserves the property $f(n+1)=nf(n)$ You can find it here: http://en.wikipedia.org/wiki/Gamma_function

Of course 'preserving' is not quite correct since $f(n+1) = (n+1)f(n)$ if $f(n) = n!$ but $f(n+1) = nf(n)$ if $f(n) = \Gamma(n)$. But it is basically the same function, just shifted by one unit.

The formula is $\Gamma(t) = \int_0^\infty x^{t-1} e^{-x} dx$.

Note that $\Gamma(t+1) = t!$

Mathematicians love to extend the things as much as they can, and do this is a "natural" way. If you were to define the factorials for fractional numbers, what could you do ?

A first approach: when you evaluate the factorial of two consecutive integers, the factorial of the half-integer should lie somewhere in between. Due to the (super)exponential growth of the factorial, it makes sense to consider the geometric mean, and define $$(n+\frac12)!\approx\sqrt{n!(n+1)!}=n!\sqrt{n+1}.$$

We can expect this approximation to be better and better for large $n$, and by applying $n!=n(n-1)!$ backwards, we can hope that $$\frac{(n+\frac12)!}{(n+\frac12)(n-\frac12)...\frac32}\approx\frac{n!\sqrt{n+1}}{(n+\frac12)(n-\frac12)...\frac32}\to\frac12!$$ will converge. This is indeed the case and the limit is $\sqrt\pi/2$, and we now have $$(n+\frac12)!=\frac{\sqrt\pi}2\frac32\frac52\dots(n+\frac12).$$ (The same method generalizes to other fractions.)

Another approach: this idea is to try an find a formula that equals $n!$ for integer $n$, but is not limited to integer arguments.

Consider the integral $$I_n=\int_0^\infty x^ne^{-x}\ dx.$$ By parts, $$I_n=-x^ne^{-x}\Big|_0^\infty+n\int_0^\infty x^{n-1}e^{-x}\ dx=nI_{n-1},$$and $$I_0=\int_0^\infty e^{-x}\ dx=1,$$ so that by recurrence $I_n=n!$.

As the integral is also defined for noninteger $n$, it can serve as our extension of the factorial.

It turns out that the two definitions coincide.