Home » Blog » Find the general solution of y′′ – 2y′ + y = x + 2xex

Find the general solution of y′′ – 2y′ + y = x + 2xex

Find the general solution of the second-order differential equation

    \[ y'' - 2y' + y = x + 2xe^x. \]

If the solution is not valid everywhere, describe the interval on which it is valid.


The general solution of the homogeneous equation

    \[ y'' - 2y' + y = 0 \]

is given by Theorem 8.7 with a = -2 and b = 1. This gives us d = a^2 - 4b = 0; hence,

    \begin{align*}  y &= e^{-\frac{ax}{2}} (c_1 + c_2 x) \\  &= e^x (c_1 + c_2 x) \\  &= c_1 e^x + c_2 x e^x. \end{align*}

So, we obtain particular solutions of the of the homogeneous equation v_1(x) = e^x and v_2(x) = xe^x (by taking c_1 = 1, c_2 = 0 and c_1 = 0, c_2 = 1, respectively). We want to apply Theorem 8.9 (on page 330 of Apostol). From that theorem we have

    \[ R(x) = x  + 2xe^x. \]

Furthermore,

    \begin{align*}  W(x) &= v_1 v_2' - v_1' v_2 \\  &= e^x (e^x + xe^x) - e^x (xe^x) \\  &= e^{2x}. \end{align*}

So, a particular solution y_1 to the non-homogeneous equation is given by

    \begin{align*}  y_1(x) &= t_1 (x) v_1(x) + t_2(x) v_2(x) \\  t_1(x) &= -\int v_2(x) \frac{R(x)}{W(x)} \, dx \\  &= -\int \frac{x^2 e^x + 2x^2 e^{2x}}{e^{2x}} \, dx \\  &= -\int (x^2 e^{-x} + 2x^2)\, dx \\  &= e^{-x} (x^2 + 2x + 2) - \frac{2}{3} x^3 \\  t_2(x) &= \int v_1(x) \frac{R(x)}{W(x)} \, dx \\  &= \int \frac{xe^x + 2xe^{2x}}{e^{2x}} \, dx \\   &= \int (xe^{-x} + 2x) \, dx \\  &= e^{-x} (-x-1) + x^2. \end{align*}

Therefore, by Theorem 8.8 the general solution of the non-homogeneous equation is

    \begin{align*}   y &= c_1 e^x + c_2 x e^x + e^x \left(e^{-x} (x^2+2x+2) - \frac{2}{3} x^3 \right) + xe^x (e^{-x}(-x-1)+x^2) \\  &= e^x \left( c_1 + \frac{1}{3} x^3 + c_2 x \right) + x + 2. \end{align*}

One comment

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