$\displaystyle\int_0^\pi x \sin x\, dx = ?$
- $0$
- $\pi$
- $\pi/2$
- $2\pi$
Show answer and solution
Correct answer: B. $\pi$
**Integration by parts:** $u = x$, $dv = \sin x\, dx$.
$[-x\cos x]_0^\pi + \int_0^\pi \cos x\, dx = \pi + [\sin x]_0^\pi = \pi + 0 = \pi$.
(Or use $\int_0^\pi x f(\sin x)\, dx = (\pi/2)\int_0^\pi f(\sin x)\, dx$ rule.)