Let $g_i:\mathbb{R}^N\to\mathbb{R}$ ($i=1,...N$) with $g_i\in W^{1,\infty}(\mathbb{R}^N)$ and define $g=(g_1,...,g_N)$. Let $G=\operatorname{div}g$, where $\operatorname{div}g=\frac{\partial g_1}{\partial x_1}+...+\frac{\partial g_N}{\partial x_N}$. Let $Q$ be the unit cube in $\mathbb{R}^N$ with center in origin and suppose that each $g_i$ is $Q$ periodic.
Can I conclude that $$\int_Q G=0$$
Remark: $Q$ periodic here mean: If we consider the relation $x=(x_1,x_2)\sim y=(y_1,y_2)$ if and only if $(x_1,x_2)=(y_1,y_2)+(2k,2n)$, for some $k,n\in \mathbb{Z}$, then $g_i(x)=g_i(y)$ if $x\sim y$.
Thank you.
Consider what happens in he one dimensional case. Then $G=g'$ and $$ \int_QG=\int_0^1g'=g(1)-g(0)=0 $$ by periodicity.
In the $N$-dimensional case use the divergence theorem and the fact that the flux of the vector field $g$ through two opposed faces of the cube is null because of periodicity and the fact that the normals point in different directions.