Michael K. answered 04/26/19
PhD professional for Math, Physics, and CS Tutoring and Martial Arts
Given the second order linear differential equation above...
∂2y/∂x2 + 3∂y/∂x + 2y = xe-x
We see that there are two solutions for y ( the homogeneous and the particular ). First let's solve the homogeneous solution (which is equivalent to solving the differential equation equal to zero).
∂2y/∂x2 + 3∂y/∂x + 2y = 0
Using the ansatz of y(x) = erx due to the constant coefficients in the differential equation...
r2erx + 3rerx + 2erx = 0
Since erx can never be zero (except at x=infinity) we have the simple quadratic equation to solve for r...
r2 + 3r + 2 = 0 --> (r+1)(r+2)
r = -1, -2
y1(x) = e-x, y2(x) = e-2x
These represent the potential homogeneous solution which can be written as
yH(x) = Ae-x + Be-2x
No we deal with the forcing function (xe-x) to see if we can find a representation via a educated guess for the particular solution...
let yP(x) = Cxe-x
y'(x) = Ce-x - Cxe-x
y''(x) = -Ce-x -Ce-x + Cxe-x = -2Ce-x + Cxe-x
Substitute into the differential equation to see if a value of C can be uniquely found...
-2Ce-x + Cxe-x + 3 * ( Ce-x - Cxe-x ) + 2Cxe-x = xe-x
Ce-x + 0 ≠ xe-x
Therefore we cannot find a C that fits this condition and hence our guess is too restrictive...
Instead lets try yP(x) = Cx2e-x + Dxe-x
y'(x) = 2Cxe-x - Cx2e-x + De-x - Dxe-x = Cx2e-x + (2C - D)xe-x + De-x
y''(x) = 2Cxe-x - Cx2e-x + (2C - D)e-x - (2C - D)xe-x - De-x
Placing these derivatives into the equation with the forcing function yields...
C = 1/2, D = -1
Therefore the final solution = yH(x) + yP(x) = Ae-x + Be-2x + (1/2)x2e-x - xe-x