Home » Blog » Find the general solution of y′′ + y′ – 2y = ex + e2x

Find the general solution of y′′ + y′ – 2y = ex + e2x

Find the general solution of the second-order differential equation

    \[ y'' + y' - 2y = e^x + e^{2x}. \]

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


The general solution of the homogeneous equation

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

is given by Theorem 8.7 with a = 1 and b = -2. This gives us d = a^2 - 4b = 9; hence, k = \frac{1}{2} \sqrt{d} = \frac{3}{2}. Thus,

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

To find a particular solution of y'' + y' - 2y = e^{2x} assume y_1 = p(x)e^x is a solution. Then,

    \begin{align*}  y_1' &= p'(x) e^x + p(x) e^x \\  y_1'' &= p''(x) e^x + 2p'(x) e^x + p(x) e^x. \end{align*}

Therefore,

    \begin{align*}  &&p''(x) + 2p'(x) e^x + p(x) e^x + p'(x) e^x + p(x)e^x - 2p(x)e^x &= e^x (1+e^x) \\  \implies && 3p'(x) + p''(x) &= 1 + e^x.  \end{align*}

Then, let p(x) = Ax + B + Ce^x. This implies

    \begin{align*}  p'(x) &= A + Ce^x \\  p''(x) &= Ce^x. \end{align*}

Therefore,

    \[ 3A + 3Ce^x + Ce^x = 1 + e^x \quad \implies \quad A = \frac{1}{3}, \quad C = \frac{1}{4}. \]

Hence, p(x) = \frac{1}{3} + \frac{1}{4}e^x which gives us the particular solution

    \[ y_1 = \left( \frac{1}{3}x + \frac{1}{4} e^x \right) e^x  = \frac{1}{3}xe^x + \frac{1}{4}e^{2x}. \]

Finally, the general solution is then

    \[ y = c_1 e^x + c_2 e^{-2x} + \frac{1}{3} xe^x + \frac{1}{4}e^{2x} = \frac{1}{4}e^{2x} + \left( \frac{1}{3}x + c_1 \right) e^x + c_2 e^{-2x}. \]

One comment

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