# Differential equation: $Ay'' + By' + Cy = h(x)$

I'm stuck solving the equation $y'' - 3y' + 2y = 2x^3-30$.

The auxiliary equation is $k^2 - 3k + 2 = 0$ where $k_1 = 1, k_2=3$. Thus the general solution is: $$y_g = C_1e^x + C_2e^{3x}$$ Then, I tried to find the particular solution taking into consideration that $h(x) = Q_n(x) \cdot e^{\alpha x}$ where $\alpha$ is zero and doesn't equal one of auxiliary equation's roots, and $n$ is the order of $h(x)$ and equals 3. So, I get the equations as: $$y_p = Ax^3 + Bx^2 +Cx + D, \\ y'_p = 3Ax^2 + 2Bx + C, \\ y''_p = 6Ax + 2B$$

Having substituted they in the initial equation I get the system: $$\begin{cases} A = 2, \\ B + 3A = 0, \\ C + 2B + 6A = 0, \\ D + C + 2B = -30 \end{cases} \implies \begin{cases} A = 2, \\ B = -6, \\ C = 0, \\ D = -18 \end{cases}$$

Thus my particular solution is $y_p = 2x^3 - 6x^2 - 18$ but the correct answer is: $$y_p = x^3 + \frac{9}{2}x^2 + \frac{21}{2}x - \frac{15}{4}$$

Where was I wrong?

• It looks like you did $y_p''+y_p'+y_p=2x^3-30$ But this isn't the equation you had. You should be doing $y_p''-3y_p'+2y_p=2x^3-30$ – randomgirl Jul 30 '15 at 3:13

First of all your factorization is wrong: $k_1=1, k_2=2$,so general solution will be,

$$y_g = C_1e^x + C_2e^{2x}$$

Next, $$y_p = Ax^3 + Bx^2 +Cx + D, \\ y'_p = 3Ax^2 + 2Bx + C, \\ y''_p = 6Ax + 2B$$and using all this you will get,

$$\begin{cases} 2A = 2, \\ -9A+2B = 0, \\ 6A-6B+2C = 0, \\ 2B-3C+2D = -30 \end{cases} \implies \begin{cases} A = 1, \\ B = 9/2, \\ C = 21/2, \\ D = -15/4 \end{cases}$$ Using these your $$y_p = x^3 + \frac{9}{2}x^2 + \frac{21}{2}x - \frac{15}{4}$$

Sol: $y=y_g+y_p$

• Oops didn't bother looking at the first part. Great observation. – randomgirl Jul 30 '15 at 4:16
• I see, it was a silly mistake. But I didn't catch why 2A = 2, I thought A =2 was right. – flipback Jul 30 '15 at 6:07
• @flipback we have to compare the corresponding coefficient of both sides, if you will put the values of $y_p,y_p',y_p''$ in equation first you will get $2Ax^3+...=2x^3-30$ so we have $2A=2$ – Chiranjeev_Kumar Jul 30 '15 at 6:16

The equations you should have are: $2A=2 \\ -9A+2B=0 \\ 6A-6B+2C=0 \\ 2B-3C+2D=-30 \\ \text{ Solving this system should give you your solution. }$