# Proving n! = (x^n)(e^-x) integrated from 0 to infinity

1. Oct 7, 2012

### tainted

1. The problem statement, all variables and given/known data
Prove $$\int_{0}^{\infty}x^{n}e^{-x} dx = n!$$

2. Relevant equations
$$0! = 1$$ (by convention)

3. The attempt at a solution
Basic step:
$$n=0 \\ \int_{0}^{\infty}x^{0}e^{-x} dx\ = 0! = 1\\ \int_{0}^{\infty}e^{-x} dx\ = -[e^{-\infty}-e^{0}]\\ -[e^{-\infty}-e^{0}] = -[\frac{1}{e^{\infty}}-1]\\ -[\frac{1}{e^{\infty}}-1] = -[0-1] = 1$$
Therefore the statement is true for n = 0.

Assuming that $$\int_{0}^{\infty}x^{n}e^{-x} dx = n!$$ is true,
I need to show $$\int_{0}^{\infty}x^{n+1}e^{-x} dx = (n+1)!$$

I don't really know what to do from here. I emailed the TA and he said to integrate by parts, but we haven't been taught that , and he hasn't replied again so if someone could help me out that would be great! Thanks!

2. Oct 7, 2012

3. Oct 7, 2012

### tainted

Well I would assume it is integrating the parts that are multiplied together, but I do not know how to do that.

4. Oct 7, 2012

### dextercioby

Then refresh your memory, go to the high-school book teaching you the part integration.

5. Oct 7, 2012

### SammyS

Staff Emeritus
Since you don't know integration by parts, you might try to integrate by trial & error. In other words, try to find the anti-derivative of $\displaystyle x^{n+1}e^{-x}$ by finding a function whose derivative is $\displaystyle x^{n+1}e^{-x}\ .$ In this case that's not a difficult as it may at first seem.

This step may strike you as a bit crazy, but what is the derivative of $\displaystyle x^{n+1}e^{-x}\ ?$ Well, the derivative of $\displaystyle x^{n+1}e^{-x}\$ has a term which is also the same function, $\displaystyle x^{n+1}e^{-x}\ .$

Integrate both sides of the result, & see where that takes you.

Now that I look at that, the result you want should be staring right at you.

Last edited: Oct 7, 2012
6. Oct 7, 2012

### tainted

Thanks guys! I looked up integration by parts, and got to

$$\int_{0}^{\infty} x^{n+1}e^{-x} dx,\ \\ u = x^{n+1} \\ du = (n+1)x^{n} dx\ \\ dv = e^{-x} dx \\ \frac{dv}{dx}\ = e^{-x} \\ v = -e^{-x}$$

Last edited: Oct 7, 2012
7. Oct 7, 2012

### SammyS

Staff Emeritus
Well, v = -e-x .

8. Oct 7, 2012

### tainted

Thanks, yeah I had that written, but I didn't get it down, can you tell me what was wrong with my LaTeX before I continue the rest of my work?

9. Oct 7, 2012

### SammyS

Staff Emeritus
You have an underscore, _ , in the fraction command, \frac_{}{} .

Also, you were missing the ^ with the ∞.

Have you completed the integration part of the proof ?

I was going to say, just "QUOTE" my post, but that won't work.

What will work is to "Right click" on the LaTeX output of my post, then "Show math as" to look at the TEX commands.

10. Oct 7, 2012

### tainted

$$\int_{0}^{\infty} x^{n+1}e^{-x} dx,\ \\ u = x^{n+1} \\ du = (n+1)x^{n} dx\ \\ dv = e^{-x} dx \\ \frac{dv}{dx}\ = e^{-x} \\ v = -e^{-x}\\ \int udv\ = uv - \int vdu\ \\ -x^{n+1}e^{-x} + (n+1)\int e^{-x}x^{n} dx\$$

Last edited: Oct 7, 2012
11. Oct 7, 2012

### tainted

Yeah, ha I'm posting as I work on other problems, so I post a little bit, and then I update. It should be edited as far as I have gotten now. I'm not really sure what to do to prove that equals $$(n+1)n!$$

12. Oct 7, 2012

### SammyS

Staff Emeritus
Turn that indefinite integral into a definite integral with limits 0 to ∞ , & use your induction hypothesis.

13. Oct 7, 2012

### tainted

$$-x^{n+1}e^{-x} + (n+1)n!$$
So do I have to prove the first part equals 0?

14. Oct 7, 2012

### happysauce

Pretty simple using L'hopitals rule.

15. Oct 7, 2012

### tainted

mmk, but what would the limit approach?

$$\lim_{x \to \ ?} \frac{-x^{(n+1)}}{e^{x}}$$
where
$$f(x) = -x^{(n+1)}\\ g(x) = e^{x}$$

16. Oct 7, 2012

### SammyS

Staff Emeritus
If $\displaystyle\ \ \int x^{n+1}e^{-x} dx= -x^{n+1}e^{-x} + (n+1)\int e^{-x}x^{n} dx\,,$

then $\displaystyle\ \ \left.\int_{0}^{\infty} x^{n+1}e^{-x} dx= -{\LARGE{(}}x^{n+1}e^{-x}\right|_0^\infty + (n+1)\int_0^\infty e^{-x}x^{n} dx\ .$

17. Oct 7, 2012

### tainted

$$\displaystyle\ \ \left.\int_{0}^{\infty} x^{n+1}e^{-x} dx= -{\LARGE{(}}x^{n+1}e^{-x}\right|_0^\infty{\LARGE{)}} + (n+1)\int_0^\infty e^{-x}x^{n} dx\ \\ = {\LARGE{[}}-\frac{x^{n+1}}{e^{\infty}} + x^{(n+1)}{\LARGE{]}} + (n+1)n! \\ = {\LARGE{[}}x^{(n+1)}{\LARGE{]}} + (n+1)n! \\ = (n+1)n! + x^{(n+1)}$$

That wouldn't equal (n+1)n!...
Then what would I do? I'm not really sure what I'm doing, it just seems to be getting more complicated to me =/
Thanks for helping me though!

Last edited: Oct 8, 2012
18. Oct 8, 2012

### happysauce

Well clealy at zero it's zero, the infinity part you use Lhopitals rule for x-> infinity.