Answer
$\frac{1}{4}t^2-\frac{1}{4}t\sin 2t-\frac{1}{8}\cos 2t+C$
Work Step by Step
$\int t\sin^2 t\ dt$
Use integration by parts with $u=t$ and $dv=\sin^2 t\ dt$. Then $du=dt$. To find $v$, use the half-angle identity to rewrite $v=\int\sin^2 t\ dt$ as $v=\frac{1}{2}\int(1-\cos 2t)\ dt=\int\frac{1}{2}\ dt-\int\frac{1}{2}\cos 2t\ dt$. Using the substitution $w=2t$, it becomes $v=\frac{1}{2}t-\frac{1}{4}\sin 2t$.
So using the integration by parts formula $\int u\ dv=uv-\int v\ du$ with $u=t$, $du=dt$, $v=\frac{1}{2}t-\frac{1}{4}\sin 2t$, and $dv=\sin^2 t\ dt$, the original integral equals:
$=t(\frac{1}{2}t-\frac{1}{4}\sin 2t)-\int (\frac{1}{2}t-\frac{1}{4}\sin 2t)dt$
$=\frac{1}{2}t^2-\frac{1}{4}t\sin 2t-(\frac{1}{2}*\frac{t^2}{2}-\frac{1}{4}*\frac{1}{2}*(-\cos 2t)+C)$
$=\frac{1}{2}t^2-\frac{1}{4}t\sin 2t-(\frac{1}{4}t^2+\frac{1}{8}\cos 2t+C)$
$=\boxed{\frac{1}{4}t^2-\frac{1}{4}t\sin 2t-\frac{1}{8}\cos 2t+C}$