I need help with the problem!
xy' + xy + 2y - 2e^(-x) = 0
I had a hard time figuring out how to solve it... please help!
This equation is linear inhomogeneous:
xy' + xy + 2y = 2e^(-x) (1)
The book or lecture notes you have have instructions which say to first solve the homogeneous equation and then vary its constant to find the solution of the inhomogeneous equation.
Here is how it goes.
The homogeneous part is
xy' + xy + 2y = 0
we divide it by xy and rearrange terms conveniently:
y'/y = -1 - 2/x
now we take y' = dy/dx and multiply all by ...