The easy way is to use complex numbers
Finding the complementary function is straightforward,
but sorting out a particular integral using phase
angles can be tough. Complex numbers are the
answer!
To make it all look easier, let us consider a
numerical example

Now sin t is the real part of
-j ejt
so we will consider
x as
C ejt,
where C is likely to be complex. We are only
interested in the real part, so
we will take the real
part of our final expression when we have worked out
a value for C.
If we differentiate e
jt we get je
jt.
So the first and second derivatives of
x
are
jx and
-x respectively, so
for
we have
(-1 + 5j +6) x
= -j ejt
i.e.

We rationalise
this by multiplying top and bottom by (1 - j) to get

so
x = (-j - 1) ejt /10 = (-1 -
j) (cos t + j sin t) /10
Finally we take just the real part, to get
x = -0.1 cos t + 0.1 sin t
I challenge you to work it out faster using the
phase-shift!
The general case
We have

Remember that there are two parts to the solution,
the 'Complementary function' and the 'Particular
integral'.
For the first, we assume that the input is
zero. We look for solutions of the form x
ect (where c might be complex) so
that we can use the fact that the first and second
derivatives will then be cx and c2x
respectively.
When we substitute this function into the equation
we get

We solve the quadratic to get two values for c
(though they might be equal roots.)
If they are real, the complementary function will be
the sum of two exponentials, each multiplied by a
constant to match up the initial conditions.
If they are complex, say if c = a +/- jb, then the
complementary function will be
eat(A
cos bt + B sin bt)
where constants A and B are chosen to match the
initial conditions.
For the 'Particular integral' we apply the input
function and look for any solution function that
will fit. It is fairly obvious that in this
case the solution will be a mixture of the sine and
cosine of omega t, but sorting out the values with
be a trigonometric nightmare!
So we put our trust in complex numbers.
We know that the forcing function is the real part
of

(multiply it out, with the exponential replaced by
(cos + j sin) to check)
so we look for a value of x of the form

where we will end by taking the real part of

So here goes. From the differential equation
we have

so

and so

It might look nasty, but that is really the fault of
the way the equation was written. Most of the Greek
characters are just numbers and the leading fraction
is just a complex number. To work it out we
write it as

and rationalise
it.
Then we multiply out the complex numbers, take the
real part and we are home!
To see that it is really not all that difficult,
look again at the numerical example above.