# Find general solution of the ODE:

Find general solution of the ODE:

$\dfrac{\operatorname{d^2y}}{\operatorname{dx^2}}+y=f(x)$ where $f(x)$ is a real valued continuous function on $(-\infty,\infty)$

C.F: $D\equiv \dfrac{\operatorname{d^2}}{\operatorname{dx^2}}$ then $D^2+1=0$.

Hence $y=A\cos x+ B\sin x$.

I can't find the particular integral .

• use the variation of parameters – E.H.E Dec 1 '15 at 16:38

Finding the general solution of the differential equation $\,\,y''+y=f(x)$
According to this post, you are missing a $\ldots+\int_{0}^{x} \sin(x-t)f(t) \ dt$ at the end.