Does $\int f^2 =0$ implies $\int f=0$? Let $f$ be an integrable function. Then does $\int f^2 =0$ implies $\int f=0$ or even $f=0$?. 

After seeing the comment, I find inside my problem there were problems. 
Sorry for my mathematical immaturity. 
Consider the most simple case. 
i.e., $1$ dimension, $f$ is real-valued function, then what i want to know is 
\begin{align}
\int f^2(x) dx =0 \quad \Rightarrow \quad \int f(x) dx =0, \quad\textrm{or} \quad  f=0
\end{align}
 A: Assuming $f\colon[a,b]\to\mathbb R$, the latter is true only if $f$ is continuous. Things like
$$f(x) = \begin{cases} 1 & \text{if $x\in\mathbb Q$}\\
0 & \text{otherwise}\end{cases}$$
also have $\int f^2=0$ (where $\int$ is Lebesgue integral).
A: The other unanswered question is about complex values.  If $f(x) = \cos(x) +i \sin(x)$ on $[0,2\pi]$, then $\int_0^{2\pi} f(x)^2\;dx = 0$ even though $|f(x)| = 1$ for all $x$.
A: If $g$ is nonnegative and the measure of $\{x\mid g(x)>0\}=\bigcup_{n=1}^{\infty}\{x\mid g(x)\geq\frac1n\}$ is positive then also for some $n$ the measure of $\{x\mid g(x)\geq\frac1n\}$ is positive. 
Consequently then: $$\int g\;d\mu\geq\int\frac1n\mathbf1_{\{x\mid g(x)\geq\frac1n\}}\;d\mu\geq\frac1n\mu\left(\{x\mid g(x)\geq\frac1n\}\right)>0$$
So $\int g\;d\mu=0$ allows us to conclude that $\{x\mid g(x)>0\}$ has zero measure.
So we cannot say that $g$ is zero, but that $g$ is zero almost everywhere.
This can be applied on $g=f^2$ and here $\{x\mid g(x)>0\}=\{x\mid f(x)>0\}$.
If a nonnegative function is zero almost everywhere then its integral takes value $0$, so the answer on the question in your title is: yes.
