I am trying to solve for the ODE $$y'' + 2y' + y = e^{-x}$$
I tried the ansatz of the form $$ y = Ae^{-x} $$ But the coefficients cancel out leaving me with $ 0 = e^{-x}$.
I'm guessing I have to be smarter with the ansatz? Maybe include a function like $y = Af(x)e^{-x}$ but that seems like it'll just result in another DE.
Any hint or suggestions on better ways to solve this would be appreciated.
For a problem like this, you would include a function like $y=Af(x)e^{−x}$
In this case though, it is important to note that the solution to the homogeneous equation has a repeated root, so the roots will take the form $y=C_1e^{−x}$ and $y=C_2f(x)e^{−x}$.
The particular solution must then have a form that is different than both of the homogeneous solutions. Thus if your homogeneous solution takes the form $y=C_1e^{-x} + C_2xe^{-x}$, then your particular solution must have a form with a higher order of x.
When you take the derivatives of your particular solution and plug them into the original equation, you solve for a constant that eliminates the differential equations. Your final solution adds together the two homogeneous solutions and the particular solution.