The equation to solve : $y''-6y'+9y=e^{3x}$
This is the general solution from wolframalpha :
$y(x) = c_2 e^{3 x} x + c_1 e^{3 x} + 1/2 e^{3x} x^{2}$
This is the solution I calculated from the method of undetermined coefficients :
$y(x) = c_2 e^{3 x} x + c_1 e^{3 x} + Ax^2 e^{3x}$
This is the solution I calculated using the 'D' operator and shortcut method :
$y(x) = c_2 e^{3 x} x + c_1 e^{3 x} + e^{3x}/18$
I think I'm getting different particular integrals while using different methods because this differential equation has a family of solutions ?
But the fact that the last solution's P.I doesn't even have an 'x' term concerns me.
All of them are correct, am I right ?
Best Answer
Testing the solution $y(x) = b e^{3 x} x + a e^{3 x} + c x^2 e^{3x}$, we get
$$2c e^{3 x} \ne e^{3x}$$
This is not a solution.
Testing the solution $y(x) = b e^{3 x} x + a e^{3 x} + e^{3x}/18$, we get
$$0 \ne e^{3x}$$
This is not a solution.
Testing the solution, $y(x) = c_2 e^{3 x} x + c_1 e^{3 x} + 1/2 e^{3x} x^{2}$, we get
$$e^{3x} = e^{3x}$$
This is a solution.
Now, lets use Undetermined Coefficients to solve $y''-6y'+9y=e^{3x}$.
For the homogeneous solution, we have $ m^2 - 6 m + 9 = 0 \implies m_{1,2} = 3$, hence
$$y_h(x) = e^{3x}( c_1 + c_2 x)$$
Because our homogeneous solution, $e^{3x}(c_1 + c_2 x)$ shares the RHS $e^{3x}$, we choose $$y_p(x) = a x^2 e^{3x}$$
Substituting, we have
$$y_p(x)''-6y_p(x)'+9y_p(x) = 2 a e^{3x} =e^{3x} \implies a = \dfrac{1}{2}$$
We can now write
$$y(x) = y_h(x) + y_p(x) = e^{3x}( c_1 + c_2 x + \dfrac{1}{2} x^2)$$