Solveeit Logo

Question

Question: How do you integrate \({{x}^{2}}\sin xdx\)?...

How do you integrate x2sinxdx{{x}^{2}}\sin xdx?

Explanation

Solution

In this question, we are given a function containing two terms multiplied and we need to find the integration of this function. For a product of two functions, we will use the formula of integration by parts which is given by udv=uvvdu\int{udv}=uv-\int{vdu}. So we will suppose one of the terms as u and another term as dv. Using it we will find du and v to use the formula and find the required integration.

Complete step by step answer:
Here we are given the function as x2sinxdx{{x}^{2}}\sin xdx.
We need to find its integration.
Since this function is a product of two separate functions x2{{x}^{2}} and sinx. So let us use integration by parts here. As we know from integration by parts that udv=uvvdu(1)\int{udv}=uv-\int{vdu}\cdots \cdots \cdots \left( 1 \right).
As we need to find x2sinxdx\int{{{x}^{2}}\sin xdx}.
So let us suppose u as x2{{x}^{2}} and dv as sinxdx.
We need the value of u, v, du, dv to solve this integration so let us find them.
As supposed earlier, u=x2u={{x}^{2}} we need the value of du.
So taking derivatives with respect to x we get dudx=2xdu=2xdx\dfrac{du}{dx}=2x\Rightarrow du=2xdx.
So value du=2xdx(2)du=2xdx\cdots \cdots \cdots \left( 2 \right).
As supposed earlier dv=sinxdxdv=\sin xdx.
We need the value of v. So let us use integration on both sides we get dv=sinxdx\int{dv}=\int{\sin xdx}.
As we know that sinxdx=cosx\int{\sin xdx}=-\cos x so we get v=cosx(3)v=-\cos x\cdots \cdots \cdots \left( 3 \right).
Putting in the values of u, v, du from (2), (3) in (1) we get,
x2sinxdx=x2cosx(2xcosx)dx\int{{{x}^{2}}\sin xdx}=-{{x}^{2}}\cos x-\int{\left( -2x\cos x \right)dx}.
Simplifying the negative sign we get x2sinxdx=x2cosx+2xcosxdx(4)\int{{{x}^{2}}\sin xdx}=-{{x}^{2}}\cos x+2\int{x\cos xdx}\cdots \cdots \cdots \left( 4 \right).
We still need to evaluate the integral xcosxdx\int{x\cos xdx}.
Let us solve it now.
We again have a product of two functions. So using integration by parts again.
Now supposing the value of u as x and dv as cosxdx so we want du and v.
We have u = x let us find dx.
Taking derivatives on both sides we get dudx=1du=dx(5)\dfrac{du}{dx}=1\Rightarrow du=dx\cdots \cdots \cdots \left( 5 \right).
We have dv=cosxdxdv=\cos xdx.
We need to find the value of v. So let us take integration on both sides we get dv=cosxdx\int{dv=}\int{\cos xdx}.
We know that cosxdx=sinx\int{\cos xdx}=\sin x so we get v=sinx(6)v=\sin x\cdots \cdots \cdots \left( 6 \right).
Now let us put value of u, v, du again in (1) to get the integral xcosx\int{x\cos x} we get xcosx=xsinxsinxdx\int{x\cos x}=x\sin x-\int{\sin xdx}.
As we know that, sinxdx\int{\sin xdx} is equal to -cosx. So we get xcosx=xsinx(cosx)\int{x\cos x}=x\sin x-\left( -\cos x \right).
Simplifying the negative sign we get xcosx=xsinx+cosx\int{x\cos x}=x\sin x+\cos x.
Putting this value of integral in (4) we get,
x2sinxdx=x2cosx+2(xsinx+cosx) x2sinxdx=x2cosx+2xsinx+2cosx \begin{aligned} & \int{{{x}^{2}}\sin xdx}=-{{x}^{2}}\cos x+2\left( x\sin x+\cos x \right) \\\ & \Rightarrow \int{{{x}^{2}}\sin xdx}=-{{x}^{2}}\cos x+2x\sin x+2\cos x \\\ \end{aligned}.
Adding the necessary constant c we get the final answer of required integral as x2sinxdx=x2cosx+2xsinx+2cosx+c\int{{{x}^{2}}\sin xdx}=-{{x}^{2}}\cos x+2x\sin x+2\cos x+c.

Note:
Students should keep in mind all the derivative integral formulas for basic functions. Do not forget to add any constant at the end as this is an indefinite integral. Take care of signs as well.