What is the particular solution of the following ODE:
$$y''(t)+y(t)=-\sin{t}|\sin{t}|$$
My idea is to take a Fourier expansion of $|\sin{t}|$ which makes the right side to be $$-\sin{t}\left[{2\over\pi}-{4\over\pi}\sum_{k=1}^\infty{\cos(2k t)\over 4k^2-1}\right]$$ If so far it's correct, then what to do next?
The right side is odd-symmetric, so that there exists an odd-symmetric solution. To get $y(0)=0$ as required for that symmetry use a term of the general solution so that on $[0,\pi]$ $$\begin{align} y(t)&=-\frac12\left(1+\frac13\cos(2t)-\frac43\cos(t)\right) =-\frac12\left(\frac43(1-\cos(t))+\frac13(\cos(2t)-1)\right) \\ &=-\frac12\left(\frac43\frac{\sin^2(t)}{1+\cos(t)}-\frac23\sin^2(t)\right) \end{align}$$ Now it is easy to change the sign like the sign of $\sin(t)$ $$ y(t)=-\frac13\sin(t)|\sin(t)|·\frac{1-\cos(t)}{1+\cos(t)} $$ Note that the roots of the denomitor cancel against the roots of the sine terms, one could also transform that back to $$ y(t)=-\frac13{\rm sign}(\sin t)·(1-\cos(t))^2 $$