# General solutions for non-homogeneous diff eq

#### MariiaBlue

Hey guys ! I have some troubles with these types of differential equations. I have to find the general solution of this eq :

y''-4y'+5y=e^(2s)

I have found the general solution of the homogeneous part of this eq.

Yh= e^(2s) * ( c1* cos s - c2 * sin s )

I hope it's correct. Well, my problem comes at the particular solution. I don't understand how to find it.

Can anyone help me? Thank you !

#### Country Boy

Math Team
Yes, that is the correct solution to the "associated homogeneous equation". I presume you know that the general solution to the entire equation is that general solution to the associated homogeneous equation plus a single solution to the entire equation.

One method for finding that one solution, called "undetermined coefficients" is to look for a solution of the form $$\displaystyle Pe^{2s}$$ (we need to "determine" the coefficient P).

If $$\displaystyle y= Pe^{2s}$$ then $$\displaystyle y'= 2Pe^{2s}$$ and $$\displaystyle y''= 4Pe^{2s}$$ so that $$\displaystyle y''- 4y'+ 5y= 4Pe^{2s}- 4Pe^{2s}+ 5Pe^{2s}= 5Pe^{2s}= e^{2s}$$ so that P= 1/5.

The general solution to the differential equation is $$\displaystyle y(s)= e^{2s}(A cos(s)+ B sin(s))+ (1/5)e^{2s}$$.

Last edited by a moderator:
• 1 person

#### skipjack

Forum Staff
You slipped up; $P = 1$.