60.6k views
5 votes
8) (10) Solve the equation y''=x^2-y+3y' y(0)=1 and y'(0) =-1

1 Answer

2 votes


y''-3y'+y=x^2

The corresponding homogeneous equation,


r^2-3r+1=0

has two roots at
r=\frac{3\pm\sqrt5}2, so that the characteristic solution is


y_c=C_1e^((3+\sqrt5)/2\,x)+C_2e^((3-\sqrt5)/2\,x)

For the particular solution, assume one of the form


y_p=ax^2+bx+c


\implies{y_p}'=2ax+b


\implies{y_p}''=2a

Substituting
y_p and its derivatives into the non-homogeneous ODE gives


2a-3(2ax+b)+(ax^2+bx+c)=x^2


ax^2+(-6a+b)x+(2a-3b+c)=x^2


\implies\begin{cases}a=1\\-6a+b=0\\2a-3b+c=0\end{cases}\implies a=1,b=6,c=16

Then the general solution to the ODE is


\boxed{y(x)=C_1e^((3+\sqrt5)/2\,x)+C_2e^((3-\sqrt5)/2\,x)+x^2+6x+16}

User Feltope
by
8.6k points