Home » Blog » Find the general solution of the equation y′′ + 9y = sin (3x)

Find the general solution of the equation y′′ + 9y = sin (3x)

For a nonzero constant k prove that

    \[ y_1 = \frac{1}{k} \int_0^x R(t) \sin k(x-t) \, dt, \]

is a particular solution of the differential equation

    \[ y'' + k^2 y = R(x). \]

Find the general solution of the equation

    \[ y'' + 9y = \sin 3x. \]


Proof. The general solution of y'' + k^2 y = 0 is y = c_1 \cos (kx) + c_2 \sin (kx). So, we have particular solutions given by v_1 = \cos (kx) and v_2 = \sin (kx) (taking c_1 = 1, \ c_2 = 0 and c_1 = 0, \ c_2 = 1, respectively). The Wronskian of v_1 and v_2 is

    \begin{align*}  W(x) &= v_1 v_2' - v_1' v_2 \\  &= (\cos (kx))(k \cos (kx)) - (-k \sin(kx))(\sin (kx)) \\  &= k \cos^2(kx) + k \sin^2 (kx) \\  &= k (\cos^2 (kx) + \sin^2 (kx)) \\  &= k. \end{align*}

So, we have the functions t_1 and t_2 of Theorem 8.9 given by

    \begin{align*}  t_1 (x) &= -\int v_2 \frac{R}{W} \, dx \\  &= -\frac{1}{k} \int_0^x \sin (kt) R(t) \, dt \\  t_2 (x) &= \int v_1 \frac{R}{W} \, dx \\  &= \frac{1}{k} \int_0^x \cos(kt) R(t) \, dt. \end{align*}

This means we have a particular solution y_1 of the non-homogeneous equation given by

    \begin{align*}  y_1 &= t_1 v_1 + t_2 v_2 \\  &= -\frac{\cos (kx)}{k} \int_0^x \sin (kt) R(t) \, dt + \frac{\sin(kx)}{k} \int_0^x \cos(kt) R(t) \, dt\\  &= \frac{1}{k} \left( \int_0^x R(t) \big( \cos(kt) \sin (kx) - \cos (kx) \sin (kt) \big) \, dt \right) \\  &= \frac{1}{k} \int_0^x R(t) \sin (k(x-t)) \, dt. \qquad \blacksquare \end{align*}

Using this theorem we can compute the general solution of

    \[ y'' + 9y = \sin (3x). \]

We have

    \begin{align*}  y &= c_1 \cos (3x) + c_2 \sin (3x) + \frac{1}{3} \int_0^x (\sin (3t))\sin (3 (x-t)) \, dt \\  &= c_1 \cos (3x) + c_2 \sin (3x) + \frac{-x}{6} \cos(3x) - \frac{1}{18} \sin (3x) \\  &= \left(c_1 - \frac{x}{6} \right) \cos (3x) + \left( c_2 - \frac{1}{18} \right) \sin (3x). \end{align*}

2 comments

  1. S says:

    I got -1/6x * cos(3x) +1/18 sin(3x) for the integral solution. However the constant of sin(3x) is anyways absorbed in c2, so I’m not sure why the solution in the book has it explicitly set to -1/18.

Point out an error, ask a question, offer an alternative solution (to use Latex type [latexpage] at the top of your comment):