Proving Lebesgue integration result I have a Lebesgue integration question and a proposed proof. Please advise.
Let $\Omega \subset \mathbb{R}^{n}$(denote the boundary as $\partial \Omega$) and consider $$\int_{\partial \Omega} vf d\lambda \geq 0 \text{  } \text{ for all } v \in C^{1}(\overline{\Omega}) \text{  } \text{  with } f \in C^{1}(\overline{\Omega})$$
then  it follows that $f \geq 0$ for every $x \in \partial \Omega$. Also we are given that $v|_{\partial \Omega} \geq 0$.
 A: Combining my ideas into an answer:
Define $v(x) = -f(x) \chi_{f^{-1}(-\infty,0]}(x)$. Note that in general $v$ is only $C^0$, not $C^1$, so we cannot simply use it as a test function directly.
Suppose there exists $x$ so that $f(x) < 0$. Then by continuity of $v$ and $f$, $\langle v,f \rangle < 0$. By Cauchy-Schwarz we have that $\| f \|_{L^2} > 0$, so we can define $\varepsilon = \frac{|\langle v,f \rangle|}{2 \| f \|_{L^2}}$. Find $w \in C^1$ so that $\| w - v \|_{L^2} < \varepsilon$. (It takes a little work to show this can be done.) Then, using Cauchy-Schwarz,
$$\left | \langle w,f \rangle - \langle v,f \rangle \right | = \left | \langle w-v,f \rangle \right | \leq \| w - v \|_{L^2} \| f \|_{L^2} \leq \frac{|\langle v,f \rangle| \| f \|_{L^2}}{2 \| f \|_{L^2}} = \frac{|\langle v,f \rangle|}{2}.$$
Consequently
$$\langle w,f \rangle \leq \frac{\langle v,f \rangle}{2} < 0$$
which achieves the desired contradiction.
A: Proof:
Assume that $f(x) \ngeq 0$ for every $x \in \partial \Omega$.
If we define $v(x) := \begin{cases}  &~~ 0 ~~~~~~~~~~~~~~~~~~\text{ if } f(x) \geq 0\\ &-f(x) ~~~~~~~~~~~\text{ if } f(x) < 0   \end{cases}$
then it follows that $v(x) \geq 0$ and $v(x)f(x) \leq 0$ for every $x \in \partial \Omega$, it can then easily be shown that $\int_{\partial \Omega}vf d\lambda \leq 0$. This implies that $\int_{\Omega}vf d\lambda = 0$(since we assume that $\int_{\partial \Omega}vf d \lambda \geq 0$) which implies $vf = 0$ for every $x \in \partial \Omega$ with $v$ defined as above. Consider a point $x \in \partial \Omega$ such that $f(x) < 0$ then $v = -f(x)$. Therefore, $v(x)f(x) = - f^{2}(x) < 0$, but $v(x)f(x) = 0$. Contradiction. Therefore $f(x) \geq 0$ for every $x \in \partial \Omega$. 
$\square$
Is the reasoning fine here? Is there a better way to prove this? Thanks.
