# What is the formula for factorial (!) .

## Recommended Posts

For example, I know sine is:

x - x^3/3! + x^5/5! - x^7/7! + x^9/9! ...

But how would one express 4! without saying 1x2x3x4 so that I can solve such questions as 5.6!

I heard that gamma(n-1) = n! , only problem is I dont know anything about gamma, can somebody offer some insight?

##### Share on other sites

! is not defined for non positive integers initially. 4! is defined to be 4.3.2.1 and as a function its domain is just {0,1,2..} where 0! is defined to be 1. As you state in another thread, it's just a mathematical invention created to do a certain job.

Of course there is no reason not to extend ! to a larger domain. We do it all the time. We could define x! = floor(x)! ie take the factorial of the integer part of x, or even the integer part of |x| would be better as that allows it to be defined for complex numbers too. However, that isn't very good. Such a function is not differentiable, never mind being analytic.

There is another way of thinking about !. It satisfies a recurrence relation, indeed, it is the unique solution to x_n=nx_{n-1} subject to x_0=1. This reminds us of functional equations.

It turns out there is a meromorphic function, gamma(x) that is closely related to the ! function. It is nasty, defined in terms of an integral and cannot be done by elementary means. It also has poles at the negative integers.

As ever, google for "thing of interest" and include the word wolfram and you'll get a good hit first up.

##### Share on other sites

Indeed. Wolfram has a good article on the Gamma function, but you'll need a good deal of knowledge of integration to understand it. You can find it at:

http://mathworld.wolfram.com/GammaFunction.html

##### Share on other sites

Thanks matt.

Yes, I have read the wolfram articale on factorial and have a pretty good understanding of it and how it relates to probability etc, and from that and what you have told me I am giving up (for now) my curiosity in this area of maths as it appears beyond me.

When I was young I realised that (x+y)^n followed this pattern:

1

1 1

1 2 1

1 3 3 1

1 4 6 4 1

1 5 10 10 5 1

I then when on to solve that this follows the pattern of:

x!

------

(x-y)! y!

Now I read about a man who solved this in the 1600s, it pisses me off that just about everything has been done with maths. I feel that had I lived a few hundred years ago I could have been a great mathematician. Enough of me being a winge.

##### Share on other sites
Now I read about a man who solved this in the 1600s, it pisses me off that just about everything has been done with maths. I feel that had I lived a few hundred years ago I could have been a great mathematician. Enough of me being a winge.
LOL sure you would. I'm sure not everything has already been done, in fact there's probably an infinite amount of things to do, just increasingly more obscure.

##### Share on other sites

Very few things have been solved in mathematics, and there are even fewer things that we understand; don't give up.

##### Share on other sites

$n!=n\frac{n+1}{2}$

##### Share on other sites
[math']n!=n\frac{n+1}{2}[/math]

Erm, not quite. The formula you gave is for the triangle numbers. According to that formula, 4! = 10. But 4! = 4*3*2*1 = 24.

If you want to define it recursively, you can define it as:

$n! = n \cdot (n-1)!, \ 0! = 1$

##### Share on other sites

sorry, that was $\sum_{k=1}^{n}k$ instead of $\prod_{k=1}^{n}k$

##### Share on other sites

You can extend the factorial to non-natural numbers (including the real numbers), by using Stirlings Approximation I believe.

Check here for some explenation and a proof

##### Share on other sites

Stirling's approximation doesn't even give n! for n integer; it gives an asymptotic approximation.

##### Share on other sites

Don't forget $$n! = \int_0^{\infty} x^n e^{-x} \,dx$$

##### Share on other sites

That'd be a specialized example gamma function mentioned in the first reply, in case anyone was wondering.

##### Share on other sites

But that's the point, isn't it? The gamma function has much broader applications than expressions of factorials, and all he wanted was that.

##### Share on other sites
Don't forget $$n! = \int_0^{\infty} x^n e^{-x} \' date=dx$$

Can you prove this?

##### Share on other sites

Rather easy induction proof by the look of it, wouldn't you say?

rather easy

##### Share on other sites
Can you prove this?

$$n! = \int_0^{\infty} x^n e^{-x} \,dx$$

check for n = 1

$$\int_0^{\infty} x^1 e^{-x} \,dx\ = 1$ $\ 1 = 1!$$

check for n = (k+1)

$$\int_0^{\infty} x^{k+1} e^{-x} \,dx\ = \Gamma(k+2)$ $\Gamma(k+2) = (k+1)!$$

##### Share on other sites

I also saw some proof dealing with an infinite cycle of integration. It's been years, but it has something to do with how (n-1)! would be expressed as an integral... I'm too tired for math...

##### Share on other sites
$$n! = \int_0^{\infty} x^n e^{-x} \' date=dx$$

check for n = 1

$$\int_0^{\infty} x^1 e^{-x} \,dx\ = 1$ $\ 1 = 1!$$

check for n = (k+1)

$$\int_0^{\infty} x^{k+1} e^{-x} \,dx\ = \Gamma(k+2)$ $\Gamma(k+2) = (k+1)!$$

But now you have to have proofs regarding Gamma function as a lemma to this as a theorem. Can you prove that one?

I guess the reason I am asking, is because there is an integration by parts in the proof i am thinking of, thats all.

##### Share on other sites
But now you have to have proofs regarding Gamma function as a lemma to this as a theorem. Can you prove that one?

I guess the reason I am asking' date=' is because there is an integration by parts in the proof i am thinking of, thats all.[/quote']

you ask the proof of one thing, which i gave, and now you want proof of another thing. are you gonna ask for proofs all the way down to the axioms?

if you want to get to know the gamma function:

##### Share on other sites

No, i would be satisfied to see whether or not you ever use integration by parts formula, during any phase of your proof.

I have used the gamma function, and proved the thing you used in the theorem above. It's the integration by parts 'thing' you have not supplied.

If you don't want to provide the lemma, don't, its ok.

##### Share on other sites
No' date=' i would be satisfied to see whether or not you ever use integration by parts formula, during any phase of your proof.

I have used the gamma function, and proved the thing you used in the theorem above. It's the integration by parts 'thing' you have not supplied.

If you don't want to provide the lemma, don't, its ok.[/quote']

i did the integration the way any sane person with better things to do does it these days. with a computer.

is that ok with you?

http://img266.echo.cx/img266/3554/integral1zf.jpg

i didnt think this was an exam where we i had to show all of our work. the results of the integrals are the proof, not the method of integration.

##### Share on other sites

It's ok with me, in fact the structure of your proof is good, its just that a lemma would be nice, which goes into the gamma function.

in other words prove the following statement

Lemma:

$\Gamma (n+1) = n!$