Now we will look for a particular solution of the form \(\displaystyle x_p(t) = A\cos 2t + B\sin 2t\)
\(\displaystyle \frac{dx_p}{dt} = -2A\sin 2t + 2B\cos 2t\)
\(\displaystyle \frac{d^2x_p}{dt^2} = -4A\cos 2t - 4B\sin 2t\)
When we substitute this in the original differential equation, we get:
\(\displaystyle -4A\cos 2t - 4B\sin 2t + 2(-2A\sin 2t + 2B\cos 2t) + 2(A\cos 2t + B\sin 2t) = \sin 2t\)
\(\displaystyle -4A\cos 2t - 4B\sin 2t - 4A\sin 2t + 4B\cos 2t + 2A\cos 2t + 2B\sin 2t = \sin 2t\)
\(\displaystyle (4B - 2A)\cos 2t + (-2B - 4A)\sin 2t = \sin 2t\)
If we compare the left side with the right side, we see that:
\(\displaystyle 4B - 2A = 0\)
\(\displaystyle -2B - 4A = 1\)
This gives:
\(\displaystyle A = 2B\)
\(\displaystyle -2B -4(2B) = 1\)
\(\displaystyle -2B - 8B = 1\)
\(\displaystyle -10B = 1\)
\(\displaystyle B = -\frac{1}{10}\)
And
\(\displaystyle A = 2\left(-\frac{1}{10}\right) = -\frac{1}{5}\)
Then,
\(\displaystyle x_p(t) = -\frac{1}{5}\cos 2t - \frac{1}{10}\sin 2t\)

