Home » Blog » Solve the differential equation x′ + x = e2t for given initial values

Solve the differential equation x′ + x = e2t for given initial values

Solve the following differential equation:

    \[ \frac{dx}{dt} + x = e^{2t} \qquad \text{on} \qquad (-\infty, +\infty) \]

with x = 1 when t = 0.


From Theorem 8.3 (page 310 of Apostol) we know that a differential equation of the form

    \[ y' + P(x)y = Q(x), \qquad \text{with} \quad f(a) = b, \]

on an interval I has solution given by

    \[ f(x) = be^{-A(x)} + e^{-A(x)} \int_a^x Q(t)e^{A(t)} \, dt \]

where

    \[ A(x) = \int_a^x P(t) \, dt. \]

In this particular case we apply the theorem (noting that in this problem we have x is a function of t, rather than y a function of x as in the theorem… of course, the names of the variables doesn’t matter, but we take care to apply the theorem properly) with

    \[ P(t) = 1, \qquad Q(t) = e^{2t}, \qquad a = 0, \ b = 1. \]

This gives us

    \[ A(t) = \int_0^t P(s) \, dt = \int_0^t \,ds = t. \]

Therefore,

    \begin{align*}  f(t) &= be^{-A(t)} + e^{-A(t)} \int_a^s Q(s) e^{A(s)} \, ds \\[9pt]  &= e^{-t} + e^{-t} \int_0^s e^{2s} e^{s} \, ds \\[9pt]  &= e^{-t} + e^{-t} \int_0^s e^{3s} \, ds \\[9pt]  &= e^{-t} + e^{-t} \left( \frac{1}{3}e^{3t} - \frac{1}{3} \right) \\[9pt]  &= \frac{1}{3}e^{2t} + \frac{2}{3}e^{-t}. \end{align*}

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