** Next:** About this document ...
** Up:** Linear First Order Differential
** Previous:** The variation of constants

This method is more limited in scope; it applies only to the special case
of (2), where *p*(*t*) is a constant and *g*(*t*) has some special form.
The advantage of the method is that it does not require any integrations and
is therefore quick to use. The homogeneous equation

has the solution
To solve the inhomogeneous equation
it suffices to find one particular solution *y*_{p}(*t*). If *y*_{p}(*t*) is any
particular solution, then the general solution is
The idea behind the method of undetermined coefficients is to look for
*y*_{p}(*t*) which is of a form like that of *g*(*t*). This is possible only for
special functions *g*(*t*), but these special cases arise quite frequently in
applications.

We start with the case where *g*(*t*) is an exponential:

We look for *y*(*t*) in a similar form
This leads to
So the differential equation becomes
We can solve this to find . This leads to the particular
solution
and the general solution
| |
(3) |

Example: Find the general solution of the equation

*y*'+2*y*=*e*^{t}.

The solution of the homogeneous equation is , and we look
for a particular solution in the form *y*_{p}=*ae*^{t}. Setting *y*=*ae*^{t} in
the equation, we find
*ae*^{t}+2*ae*^{t}=*e*^{t},

leading to *a*=1/3. The general solution is
Why did this work? The idea is simply that if *y* is an exponential, then so
is *y*', and so if both *y* and *g* are exponentials, then all terms in
the equation are exponentials and we can hope to obtain a solution by setting
coefficients equal to each other.

There are some other classes of functions for which this works. For instance,
if *y* is a polynomial of degree *n*, then *y*' is a polynomial of degree
*n*-1. If *g* is a polynomial, we can therefore look for polynomial solutions.
Consider

*y*'+2*y*=*t*^{2}.

The right hand side is a polynomial of degree 2, so we look for a solution
in the same form *y*=*at*^{2}+*bt*+*c*. This leads to *y*'=2*at*+*b*, and
*y*'+2*y*=2*at*^{2}+(2*a*+2*b*)*t*+*b*+2*c*=*t*^{2}.

To satisfy this, we want to set
This leads to *a*=1/2, *b*=-1/2, *c*=1/4.
So a particular solution is
The general solution is
We note that the solution (3) breaks down if , since
it would involve a division by zero. More generally, if the equation reads

and , with *P*_{n}(*t*) an *n*th degree polynomial,
then we can find a particular solution , where
*Q*_{n}(*t*) is some other *n*th degree polynomial as long as .In the two examples above, we had and , ,respectively, so . If, on the other hand,
, we have to modify the procedure. The modification is
simply to include an extra factor *t* in the solution. That is, instead of
setting , you set .**Examples:**

1.

*y*'+2*y*=*te*^{-2t}.

Here and , so . The right hand side
is a first degree polynomial times *e*^{-2t}. So we look for a solution of
the form
*y*=*te*^{-2t}(*at*+*b*)=*e*^{-2t}(*at*^{2}+*bt*).

We find
*y*'=*e*^{-2t}(-2*at*^{2}+(2*a*-2*b*)*t*+*b*),

so that
*y*'+2*y*=*e*^{-2t}(2*at*+*b*)=*te*^{-2t}.

We compare coefficients to find *a*=1/2, *b*=0.
The general solution of the equation is
2.

*y*'+2*y*=*te*^{t}.

In this case and , so , and we
do not need the extra factor *t*. So we look for a solution of the form
*y*=*e*^{t}(*at*+*b*).

This leads to
*y*'+2*y*=*e*^{t}(3*at*+3*b*+*a*)=*te*^{t},

so we need
leading to *a*=1/3, *b*=-1/9.
The general solution is
3.

*y*'=*t*.

In this case , and the right hand side is a first degree
polynomial, so we look for a particular solution of the form *y*=*t*(*at*+*b*)=*at*^{2}
+*bt*. We find
*y*'=2*at*+*b*=*t*,

leading to *a*=1/2, *b*=0. The general solution is

** Next:** About this document ...
** Up:** Linear First Order Differential
** Previous:** The variation of constants
*Michael Renardy*

*1998-08-27*