Can you please show me how to do this...
$\displaystyle
\int_{0}^{pie}{x}^2sin{x}\,\,\,dx
$
thanks.
This calls for integration by parts. In general, if you have an integral: $\displaystyle \int u\,\,\,dv$, where both $\displaystyle u$ and $\displaystyle dv$ are functions of $\displaystyle x$, the integral can be rewritten as:
$\displaystyle uv - \int v\,\,\,du$
Usually, you want to pick a $\displaystyle u$ that is easy to differentiate and can usually differentiate down to 0. In this case, let's pick $\displaystyle x^{2}$ as $\displaystyle u$. Differentiating, we get $\displaystyle du=2x\,\,\,dx$. When we let $\displaystyle dv=sinxdx$, we can integrate that to get $\displaystyle v=-cosx$. Having these, we can simply rewrite the original integral as:
$\displaystyle -x^{2}cosx + 2\int xcosx\,\,\,dx$
Notice how the integral there cannot be easily integrated, so for that integral we need to do integration by parts a second time. Same rules apply; make your$\displaystyle u$ easy to differentiate. Let's pick $\displaystyle x$ as $\displaystyle u$. Differentiating, we get $\displaystyle du=dx$. Picking $\displaystyle cosxdx$ as your $\displaystyle dv$, when we integrate we will get $\displaystyle v=sinx$. We can therefore rewrite the previous expression as:
$\displaystyle -x^{2}cosx + 2xsinx - 2\int sinx\,\,\,dx$
The final integral is simply $\displaystyle -cosx$, we just simply write:
$\displaystyle -x^{2}cosx + 2xsinx + 2cosx$. I'll leave it up to you to evaluate the integral from $\displaystyle 0$ to $\displaystyle \pi$.
Notice how there was a 2 in front of the integral $\displaystyle \int xcosx\,\,\,dx$. That 2 is distributed to both the $\displaystyle xsinx$ and $\displaystyle \int sinx\,\,\,dx$ terms that resulted from the second time integrating by parts.
You have the 2 in your evaluation right here. Same 2 as in mine.