# How do you evaluate the definite integral xsin 2x dx from 0 to pi/2?

Feb 22, 2015

I would first use Integration by Parts to solve the indefinite integral and then apply the Fundamental Theorem of Calculus:
Integration by Parts:
$\int f \left(x\right) g \left(x\right) \mathrm{dx} = F \left(x\right) g \left(x\right) - \int F \left(x\right) g ' \left(x\right) \mathrm{dx}$
Where:
$F \left(x\right) = \int f \left(x\right) \mathrm{dx}$
$g ' \left(x\right) = \frac{\mathrm{dg} \left(x\right)}{\mathrm{dx}}$
Let us choose:
$f \left(x\right) = \sin \left(2 x\right)$
$g \left(x\right) = x$
Applying Integration by Parts you get:
$x \cdot - \cos \frac{2 x}{2} - \int - \cos \frac{2 x}{2} \cdot 1 \mathrm{dx} =$
$- x \cos \frac{2 x}{2} + \sin \frac{2 x}{4}$
Now the Fundamental Theorem of Calculus:
${\int}_{a}^{b} f \left(x\right) \mathrm{dx} = F \left(b\right) - F \left(a\right)$
$- x \cos \frac{2 x}{2} + \sin \frac{2 x}{4} {|}_{0}^{\frac{\pi}{2}}$$=$
$= \left[- \frac{\pi}{2} \cos \frac{\pi}{2} + \sin \frac{\pi}{4}\right] - 0 =$
$= \frac{\pi}{4}$