Show that a necessary condition for $-\Delta u-u =f$ to have a weak solution in $H_0^1(U)$ is that $\int_{U}f(x)\frac{\sin{|x|}}{|x|}dx = 0$. Let $U = \{x\in\mathbb{R}^3 : |x|<\pi\}$. Show that a necessary condition for $-\Delta u-u =f$ to have a weak solution in $H_0^1(U)$ is that
$\int_{U}f(x)\frac{\sin{|x|}}{|x|}dx = 0$.
My attempt: We want to show that the integral equaling 0 proves that we have a weak solution. I was thinking we could use the Lax-Milgram Theorem, but that would give a unique weak solution, which we don't need. If we were to go this route, then I'm not sure what we would set $B[u,v]$ to. Is the idea that we take $v = \frac{\sin{|x|}}{|x|}$?
If it's not immediately obvious, I'm very lost. Any help appreciated!
 A: First note that the function $v \in C^2(\bar{U})$ and that $v=0$ on $\partial U$ since $\sin(\pi)=0$.  Second, note that for a radial function $w(x) = f(|x|)$ we have that 
$$
\Delta w(x) = f''(|x|) + \frac{n-1}{|x|} f'(|x|).
$$
For $v(x) = \sin(|x|)/|x|$ we have that $f(r) = \sin(r) / r$, and so
$$
f''(r) + \frac{3-1}{r} f'(r) = \frac{-r^3 \sin(r) -2r^2 \cos(r) + 2r \sin(r)}{r^4} + \frac{2(r \cos(r) - \sin(r))}{r^3} = \frac{-r^3 \sin(r)}{r^4} = - \frac{\sin(r)}{r} = - f(r).
$$
Consequently, 
$$
\Delta v(x) = -v(x) \Rightarrow -\Delta v(x) - v(x) =0.
$$
With this information in hand we can complete the argument.  Suppose that $u \in H^1_0(U)$ is a weak solution to your problem.  Then 
$$
\int_U \nabla u \cdot \nabla w - u w = \int_U fw \text{ for all }w \in H^1_0(U).
$$
In particular, we can use $w=v \in C^2(\bar{U}) \cap H^1_0(U)$ as a test function, and we can integrate by parts to compute
$$
\int_U fv  = \int_U \nabla u \cdot \nabla v - u v = \int_U (-\Delta v -v) u =0. 
$$
Thus 
$$
0 = \int_U f v = \int_U f(x) \frac{\sin(|x|)}{|x|} dx,
$$
as desired.
