Welcome to Calculus. I'm professor Greist. We're about to begin Lecture 27, Bonus Material. After that main lesson, you may be thinking what is all this good for? Well, stay tuned because when we get to chapter 4. On applications of integrals, we're going to see that there are many instances where an improper integral tells us something about an application that we care about. Whether it's geometry or probability and statistics in fact there are some functions whose very definitions implicate improper integrals. Let's consider the gamma function that is defined as follows gamma of x is the integral. As t goes from 0 to infinity of t to the x minus 1, times e to the negative t dt. And the first thing that one has to worry about is, is this well-defined? Does it converge? I'll leave it to you to argue that four positive values of x. We have no difficulties here. The reason being that t to the x minus 1 for any fixed value of x is going to be dominated. By the e to the negative t term as the integration domain is going to infinity. Well, given that, what do people care about this function for? It is closely related to the factorial. We have stated before Implicitly, now we will state explicitly that x factorial is defined as gamma of x plus 1. Now we hope that this is really the same thing as x times quantity x minus 1 factorial. So, that this really is the factorial function even for non-integer values of x. So, let's see if we can prove that. The claim is that gamma of x plus 1 Is x times gamma of x that matches up with our intuition from factorials. So, how do we proceed with a proof? Let us consider gamma at x plus 1. This is the integral. As t goes from zero to infinity of t to the x times e to the minus t, dt. To handle this, let's use integration by parts. If we let u be t to the x and dv be e to the minus t dt. Then du and v work out very simply and when we apply the intergration by parts formula what are we going to get. Well, we have to take a limit as T goes to infinity of negative t to the x times e to the minus t. Evaluated as little t goes from zero to T. That's the uv term. Then we need to subtract off the next term, which is the integral. As t goes from zero to T of x times t to the x minus 1 times e to the negative t dt. Now, notice the minus signs conspire to give a plus sign, and notice that the limit of the first term It's going to go to zero as T gets very, very large. Again, that e to the minus t dominates. But when we do the other limit, that little t equals zero, that too goes away. So, the only thing that is left is that second term, the integral term. And taking a limit as T goes to infinity, what do we see? Well, we can pull out the x because it is not the integration variable t, and what is left is the integral as t goes from 0 to infinity and the limit of t to the x minus 1, e to the minus t dt that we've seen before. It is of course gamma of x. And so, we've proven that this gamma function behaves like a factorial. Now, this is just one example of an interesting function whose very definition requires one to worry about an improper integral. We haven't discussed what happens to the gamma function when x is negative. In particular, when x is a negative integer, then you wind up having a blow up at the lower limit, at the t equals zero case. I'll leave it to you to worry about that if you want to. If you don't, don't worry about it. We're going to be seeing improper integrals all throughout the remainder of this course. It takes a little while to get used to the idea of not always worrying about the exact value, just worrying about convergence or divergence. But with practice and some hard work, you will get good at determining this.