 In this video, we'll develop the method of integration by parts. This method is used to find the antiderivative of a product of two functions. For our purposes, let's consider the functions f of x and g of x, and the respective antiderivatives capital f of x and capital g of x. Our goal here is to find a way to evaluate the integral of f of x times g of x dx. Consider the product of f of x and capital g of x. Differentiating the product of these two functions requires the use of the product rule. And this is equal to d dx of f of x times capital g of x plus f of x g of x. This then implies that f of x times capital g of x is equal to the integral of what I have on the right side. df dx capital g of x plus f of x times g of x dx. According to rules of integration, we can express this as the integral of df dx capital g of x dx plus the integral of f of x times g of x dx. Therefore, by subtracting this term from both sides, we find that the integral of f of x times g of x is equal to f of x times capital g of x minus this term, the integral of df dx g of x. In practice, you may see this expressed as the integral of u dv equaling u v minus the integral of v du with f of x being u capital g of x being v. With u being f of x du dx is equal to df dx, which is also expressed as f prime of x, and g of x being the derivative of capital g of x, so dv dx is equal to g of x. Now with du dx being f prime, we can express that as du equals f prime dx, and with dv dx being g of x, we have that dv is equal to g of x dx. So to make this a bit clearer, we have this expression and this expression. So with f times capital G, we have u v, df dx we see here is du dx, capital G is v times dx, which can then be simplified to be written as v du, and this is a form you'll likely see in most textbooks. Now part of the challenge in applying the method is identifying the functions in the integrand to define as u and v. Let's work through an example to help make this definition clear. Consider the integral of x e to the x. Since this is an integral of the product of two functions, we can apply our new method. One function being x, the other being e to the x. Let's let u equal x. As a result, du is equal to dx. If I think of this as differentiating both sides with respect to x, this would be du dx equals one, which can be re-expressed as du equals dx. We'll define dv as e to the x dx. You can view this also as dv dx is equal to e to the x. Well, if dv dx is equal to e to the x, we think then that the antiderivative of that is e to the x. Now we're calling our method, this integral represents the integral of u dv. uv would then be x times e to the x. Here's v. Here's u minus the integral of v du. We have one more integral to evaluate or to find. x e to the x minus the integral of e to the x dx is e to the x. And of course, this is an indefinite integral, which means we need to compensate for our constant. So we get x e to the x minus e to the x plus c for some constant c. We can check our results by differentiating. Let's take the answer we arrived at in the previous slide and check that when we differentiate, we obtain the integrand of our original problem. So differentiating x e to the x by the product rule, we get e to the x plus x e to the x minus the derivative of e to the x, which is e to the x plus the derivative of a constant, which is 0, and this gives us x e to the x, which is our original integrand. Now, I chose u and dv in a certain way. What if we decided instead to let u equal e to the x and dv equal x dx? Well, in that case, du dx would be e to the x, which tells us then that du is equal to e to the x dx. And with this definition of dv, we would know that v is equal to 1 half x squared. Using the method we'd get e to the x times 1 half x squared minus integral of 1 half x squared du, which is e to the x dx. And what we notice here is that it brings us to a more complicated integral than we had before and shows that there are oftentimes choices for u and dv that are better than others. The important thing is to practice so that you can make those decisions efficiently.