Any differential equation of the form(1) is a second order differential equations and there is a standard technique for solving any equation of this sort. We solve the homogeneous equation(2) first for the 'complementary' solutionWe assume a solution of the formand substitute this into (2). We extract the non zero factor – since no exponential is zero for any finite x -to obtain a quadratic equation. We solve this equation to obtain solutionsandand then the general solution isHaving found the complementary solutionwe now find a particular solutionto (1) by assuming a solution 'similar' tothen the general solution to (1) is given by

Example: Solve the equation(2) subject toandat

Substitution of the above expressions into gives

We can factor out the nonzeroto obtain

Becauseis non zero we can divide by it to obtainand we factorise this expression to obtainand solve to obtainandThe complementary solution is then

To find a particular solution we assumesinceis a polynomial of degree one.andSubstitute these into (1)

Equating coefficients ofgives

Equating constants gives

whenimplies (3)

atimplies (4)

(3)+(4) givesthen from (3)

The solution is