### Video Transcript

By setting π’ equal to π to the power of π₯ and dπ£ equal to the cos of π₯ dπ₯, evaluate the integral of π to the power of π₯ multiplied by the cos of π₯ with respect to π₯ by integrating by parts.

Weβre given an integral to evaluate, and we can see that our integrand is the product of two functions. Itβs π to the power of π₯ multiplied by the cos of π₯. And we know a few different ways of evaluating an integral which is the product of two functions. In this question, weβre asked to use integration by parts. Letβs start by recalling what we mean by integration by parts. This tells us the integral of π’ times dπ£ by dπ₯ with respect to π₯ is equal to π’ times π£ minus the integral of π£ multiplied by dπ’ by dπ₯ with respect to π₯.

In other words, this gives us a method of integrating the product of two functions π’ and dπ£ by dπ₯. And in fact, in the question, we can see weβre told what to set our functions π’ and π£ equal to. Weβre told to set π’ to be π to the power of π₯. And saying dπ£ is equal to the cos of π₯ dπ₯ is differential notation to say dπ£ by dπ₯ is equal to the cos of π₯. So weβll set π’ equal to π to the power of π₯ and dπ£ by dπ₯ to equal the cos of π₯.

Now, to use integration by parts, we see we need expressions for π£ and dπ’ by dπ₯. Letβs start with dπ’ by dπ₯. Thatβs the derivative of the exponential function π to the power of π₯ with respect to π₯. But we know the derivative of the exponential function with respect to π₯ is just the exponential function. So dπ’ by dπ₯ is π to the power of π₯. Now, letβs find an expression for π£. π£ will be an antiderivative of the cos of π₯. One way of finding this is integrating the cos of π₯ with respect to π₯. We know this will give us the sin of π₯ plus a constant of integration πΆ. But we just need any antiderivative, so weβll just use the sin of π₯.

Weβre now ready to evaluate the integral of π to the power of π₯ times the cos of π₯ with respect to π₯ by using integration by parts. Substituting in our expressions for π’, π£, dπ’ by dπ₯, and dπ£ by dπ₯ into our formula for integration by parts, we get π to the power of π₯ times the sin of π₯ minus the integral of the sin of π₯ multiplied by π to the power of π₯ with respect to π₯. And now we can see a problem. We donβt know how to evaluate the integral of the sin of π₯ times π to the power of π₯ with respect to π₯. It has the same problems as our original integral.

Our integrand is the product of two functions. However, this time, we can notice something interesting. If we were to apply this integration-by-parts process one more time, we would integrate the sin of π₯, giving us negative the cos of π₯. So, in our integration-by-parts formula, since when we differentiate the exponential function we just get the exponential function, we would end up with the integral of negative the cos of π₯ times π to the power of π₯ with respect to π₯. But this is exactly the integral weβre trying to calculate. So we could rearrange and solve for the value of this integral.

So letβs try applying integration by parts one more time. This time, weβll use this to evaluate the integral of the sin of π₯ times π to the power of π₯ with respect to π₯. Weβll set π’ to be the exponential function π to the power of π₯ and dπ£ by dπ₯ to be the sin of π₯. By differentiating π’ with respect to π₯, we get dπ’ by dπ₯ is equal to π to the power of π₯. And by integrating the sin of π₯ with respect to π₯, we get that π£ is equal to negative the cos of π₯. Substituting in our expressions for π’, π£, dπ’ by dπ₯, and dπ£ by dπ₯ into our formula for integration by parts, we get π to the power of π₯ times negative the cos of π₯ minus the integral of negative the cos of π₯ times π to the power of π₯ with respect to π₯.

And we can simplify this expression. First, we can write π to the power of π₯ multiplied by negative the cos of π₯ as negative π to the power of π₯ times the cos of π₯. Similarly, we can simplify our integral. We have a factor of negative one inside of our integrand. We can take this outside of our integral, so weβre just instead adding the integral. Then, we can just rewrite our integrand as π to the power of π₯ multiplied by the cos of π₯. So weβve now shown the integral of the sin of π₯ times π to the power of π₯ with respect to π₯ is equal to negative π to the power of π₯ times the cos of π₯ plus the integral of π to the power of π₯ multiplied by the cos of π₯ with respect to π₯.

Now, all we need to do is substitute this expression for the integral of the sin of π₯ times π to the power of π₯ with respect to π₯ into our formula for our original integral. Substituting this expression in, we get π to the power of π₯ times the sin of π₯ minus negative π to the power of π₯ multiplied by the cos of π₯ plus the integral of π to the power of π₯ times the cos of π₯ with respect to π₯. And now we can start simplifying this expression. Weβll start by distributing negative one over our parentheses. This gives us π to the power of π₯ sin π₯ plus π to the power of π₯ cos π₯ minus the integral of π to the power of π₯ cos of π₯ with respect to π₯.

And remember, this is equal to the integral of π to the power of π₯ cos of π₯ with respect to π₯. And we can see this expression appears on both sides of our equation. So we can solve for this by adding the integral of π to the power of π₯ cos of π₯ with respect to π₯ to both sides of this equation. Adding this to both sides of our equation, on the left-hand side, weβll now have two times the integral of π to the power of π₯ times the cos of π₯ with respect to π₯. And on the right-hand side of this equation, our third term is canceled out. This gives us π to the power of π₯ times the sin of π₯ plus π to the power of π₯ times the cos of π₯.

Now weβll divide both sides of our equation through by two. And remember, since weβre calculating a definite integral, weβll need a constant of integration. Weβll call this πΆ. The last thing weβll do is rearrange this expression and take out the common factor of π to the power of π₯. And this gives us one-half π to the power of π₯ multiplied by the sin of π₯ plus the cos of π₯ plus our constant of integration πΆ.

Therefore, by using integration by parts twice, we were able to show that the integral of π to the power of π₯ times the cos of π₯ with respect to π₯ is equal to one-half π to the power of π₯ multiplied by the sin of π₯ plus the cos of π₯ plus the constant of integration πΆ.