Divergence theorem to calculate the flux I have the vector field $\vec{F}(x,y,z)=(-x,-y,z^2)$ and i want to find the flux through the part of the cone $\{z=\sqrt{x^2+y^2}\}$ between the planes $z=1$ and $z=2$. How do I use the divergence theorem here? 
I thought that i must add two surfaces at the top and bottom to get a closed surface, but further I don't know what to do
 A: Let $S^+$ be the disk of equation $S^+:z=2, x^2+y^2\leq z^2$, and similarly, $S^-:z=1, x^2+y^2\leq z^2$. Let $S$ be the part of the cone $z^2=x^2+y^2, z\in[1,2]$, and $V$ the volume between those surfaces, i.e. $V=\{(x,y,z)\mid x^2+y^2\leq z^2, z\in[1,2]\}$.
The divergence theorem gives
$$
\int_{S\cup S^+\cup S^-}\vec F\cdot\vec \nu dS= \int_V\operatorname{div}(\vec F)dV
$$
where $\vec \nu$ is the outward pointing unit vector. We then write
$$
\int_S\vec F\cdot\vec \nu dS= \int_V\operatorname{div}(\vec F)dV-\int_{S^-}\vec F\cdot\vec \nu dS-\int_{S^+}\vec F\cdot\vec \nu dS.
$$
For any point $(x,y,z)\in S^+$, $\vec\nu=(0,0,1)$, so
$$
\int_{S^+}\vec F\cdot\vec \nu dS=\int_{S^+} z^2dS = z^2\cdot \pi z^2 = 16\pi
$$
since $z$ is constant throughout $S^+$. Likewise, 
$$
\int_{S^-}\vec F\cdot\vec \nu dS=-z^4\pi=-\pi
$$
Finally, 
$$
\begin{aligned}
    \int_V \operatorname{div}(\vec F)dV &= \int_V (-2+2z) dxdydz \\
    &=\int_{z=1}^{z=2}\left(\int_{x^2+y^2\leq z^2}(-2+2z) dxdy\right)dz\\
    &=\int_1^2 (-2+2z)\left(\int_{x^2+y^2\leq z^2}dxdy\right)dz\\
    &=\int_1^2 (-2+2z)\pi z^2 dz\\
    &=2\pi\left[-z^3/3 + z^4/4\right]_1^2\\
    &=17\pi /6
\end{aligned}
$$
and the flux we were looking for is
$$
\int_S\vec F\cdot\vec \nu dS=\pi(17/6+1-16)=-73\pi/6.
$$
