TITLE: Show that $\int f=0$ implies $f=0$ a.e, given that $f$ is a nonnegative measurable function.
QUESTION [6 upvotes]: I am trying to show that $\int f=0$ implies $f=0$ a.e, given that $f$ is a nonnegative measurable function.
But I search my head from what I have learn I have no any clue of solving the problem. That is why I brought it to this room with the hope that somebody will give me a hint. 
Thanks

REPLY [9 votes]: Hint: $\{x: f(x)>0\}=\bigcup_n \{x: f(x)\geq \frac 1n\}$. So it suffices to show that $\{x: f(x)\geq\frac 1n\}$ has measure $0$.

REPLY [2 votes]: Hint: let $A_n:=\{f(x)\geq 2^{-n}\}$. Write $0\geq \int_{A_n}f(x)d\mu\geq 2^{-n}\mu(A_n)$. What about $\mu\left(\bigcup_{n\geq 1}A_n\right)$?