Solve ODE by using Fourier Transform $$- u''(x)+u(x)=f(x)$$
for every $x \in \mathbb{R}$ with $\lim_{|x| \to \infty}u(x)=0, \lim_{|x| \to \infty}u'(x)=0$ and $f \in  L^1(\mathbb{R}) \cap L^2(\mathbb{R})$. I need to solve this by using Fourier Transform.
It becomes more complicated since f(x) it is not defined but u(x) has to fulfill above conditions. 
Can somebody solve this or give more than a short hint?
 A: Let $U(k)=\int_{-\infty}^\infty u(x)e^{ikx}\,dx$ be the Fourier Transform of $u$ and let $F(k)=\int_{-\infty}^\infty f(x)e^{ikx}\,dx$ be the Fourier Transform of $f$.  
Then, integrating by parts twice and using $\lim_{|x|\to \infty}u(x)=0$ and $\lim_{|x|\to \infty}u'(x)=0$ reveals
$$\int_{-\infty}^\infty u''(x)e^{ikx}\,dx=-k^2U(k)$$
Therefore, the ODE for $u$ transforms to the equation
$$U(k)=\frac{F(k)}{k^2+1} \tag 1$$
Taking the inverse Fourier Transform of $(1)$, we obtain
$$\begin{align}
u(x)&=\frac1{2\pi}\int_{-\infty}^{\infty}\frac{e^{-ikx}}{k^2+1}F(k)\,dk\\\\
&=\frac1{2\pi}\int_{-\infty}^{\infty}\frac{e^{-ikx}}{k^2+1}\int_{-\infty}^\infty f(x')e^{ikx'}\,dx'\,dk\\\\
&=\int_{-\infty}^\infty f(x')\left(\frac1{2\pi}\int_{-\infty}^{\infty}\frac{e^{-ik(x-x')}}{k^2+1}\,dk\right)\,dx' \tag 2
\end{align}$$
The inner integral on the right-hand side of $(2)$ can be evaluated using the residue theorem with the result
$$\frac1{2\pi}\int_{-\infty}^{\infty}\frac{e^{-ik(x-x')}}{k^2+1}\,dk=
\frac12e^{-|x-x'|}$$
Finally, the solution to the ODE is given by
$$\bbox[5px,border:2px solid #C0A000]{u(x)=\int_{-\infty}^\infty f(x')\frac{e^{-|x-x'|}}{2}\,dx'}$$
