solvability condition for differential operator While reading the research article I came across following derivation,
given a self-adjoint operator,
\begin{eqnarray}
L = \frac{d^2}{dx^2} + f(x)
\end{eqnarray}
\begin{eqnarray}
L\psi_1(x) &=& 0 \\
L\psi(x) &=& M(x)
\end{eqnarray}
That is $\psi_1(x)$ is a homogeneous solution of operator $L$. and we need to solve for $\psi(x)$ when right hand side of the equation is nonzero.
The result given in the article is, for a non trivial solution of $\psi(x)$ to exist following integral should be zero,
\begin{eqnarray}
\int^{+\infty}_{-\infty}M(x)\psi_1(x) = 0
\end{eqnarray}
I am not able to understand how this condition is derived. 
I tried to understand this in a following (clearly wrong) way,
\begin{eqnarray}
L\psi_1(x) &=& 0 \\
L\psi(x)\psi_1(x) &=& 0 \\
M(x)\psi_1(x) &=& 0 \\
\int^{+\infty}_{-\infty}M(x)\psi_1(x) &=& 0
\end{eqnarray}
by this logic the integral can be set to zero in any arbitrary interval implying that integrand is identically equal to zero.
Can someone please explain the solvability condition or point out some reference material to understand the condition? I am also not sure of how to tag this question.
 A: First thing: self-adjoint in which space?
Second thing: try to apply the Fredholm alternative - if you have an operator $A$ satisfying the Fredholm alternative, then $$b\in im(A)\iff b \in (\ker A^*)^\bot.$$
A: With some manipulation with integration by parts I found the solution
\begin{eqnarray}
\int^{+\infty}_{-\infty} (L\psi) \psi_1 dx &=& \int^{+\infty}_{-\infty} \left(\left[\frac{d^2}{dx^2} + f(x)\right]\psi \right)\psi_1 dx \\
&=& \frac{d\psi}{dx}\psi_1\Bigg|^{+\infty}_{-\infty} -\int^{+\infty}_{-\infty}\frac{d\psi}{dx}\frac{d\psi_1}{dx} dx + \int^{+\infty}_{-\infty}f(x)\psi\psi_1 dx \\
&=& \frac{d\psi}{dx}\psi_1\Bigg|^{+\infty}_{-\infty} -\frac{d\psi_1}{dx}\psi\Bigg|^{+\infty}_{-\infty} + \int^{+\infty}_{-\infty}\psi\frac{d^2}{dx^2}\psi_1 dx + + \int^{+\infty}_{-\infty}f(x)\psi\psi_1 dx \\
&=& \frac{d\psi}{dx}\psi_1\Bigg|^{+\infty}_{-\infty} -\frac{d\psi_1}{dx}\psi\Bigg|^{+\infty}_{-\infty} + \int^{+\infty}_{-\infty}\left(\left[\frac{d^2}{dx^2} + f(x)\right]\psi_1 \right)\psi dx  \\
&=& 0
\end{eqnarray}
