Solve $ \int{x\sin^2(x)}\ dx$ I need to solve this integral:
$$ \int{x\sin^2(x)}\ dx $$
I SOLVED it by writting: $$ \sin^2(x) = \frac{1-\cos(2x)}{2} $$
and used integration by parts for $x\cos(2x)$, and the result is:
$$ \frac{1}{4}(x^2-x\sin(2x)-\frac{\cos(2x)}{2}) + C $$
I need to know other methods of solving this integral (preferable simple methods). Thank you!

Although this is a more complicated sotution way ,but different from your method $$\int { x\sin ^{ 2 } (x) } dx=\int { \sin ^{ 2 } (x)d\left( \frac { { x }^{ 2 } }{ 2 }  \right) =\frac { { x }^{ 2 }\sin ^{ 2 } (x) }{ 2 }  } -\frac { 1 }{ 2 } \int { { x }^{ 2 }\sin { 2x } dx } =\\ =\frac { { x }^{ 2 }\sin ^{ 2 } (x) }{ 2 } +\frac { 1 }{ 4 } \int { { x }^{ 2 }d\cos { 2x } =\frac { { x }^{ 2 }\sin ^{ 2 } (x) }{ 2 } +\frac { 1 }{ 4 } \left( { x }^{ 2 }\cos { 2x } -2\int { x\cos { 2xdx }  }  \right) = } \\ =\frac { { x }^{ 2 }\sin ^{ 2 } (x) }{ 2 } +\frac { 1 }{ 4 } \left( { x }^{ 2 }\cos { 2x } -\int { xd\sin { 2x }  }  \right) =\frac { { x }^{ 2 }\sin ^{ 2 } (x) }{ 2 } +\frac { 1 }{ 4 } \left( { x }^{ 2 }\cos { 2x } -x\sin { 2x+\int { \sin { 2xdx }  }  }  \right) =\\ =\frac { { x }^{ 2 }\sin ^{ 2 } (x) }{ 2 } +\frac { { x }^{ 2 }\cos { 2x- } x\sin { 2x }  }{ 4 } -\frac { 1 }{ 8 } \cos { 2x } +C$$
