I'm trying to obtain Euler equation for a perfect fluid in laminar or stationary flow. A particle fluid is submitted at volume forces and surface force. The fist, in my case, is giving only by gravity and the second by pressure. By Newton's second law I obtain:
$$\vec{F}_V + \vec{F}_s = m\frac{d\vec{v}}{dt}.$$
An element of volume force is given by $$d\vec{F}_V = dm\vec{g}=\rho d\omega\vec{g}$$ and an element of surface force is given by $$d\vec{F}_S = -pd\vec{S}.$$
Integrating I obtain
$$ \int_V \rho \,d\omega\vec{g} - \int_S p\,d\vec{S} = \frac{d\vec{v}}{dt}\int_V \rho\, d\omega$$.
Now Euler equation is written in local form as $$\rho\vec{g} - \nabla p = \rho \frac{d\vec{v}}{dt}.$$
My question is this: where the gradient of $p$ comes from? I must have the following identity $$-\int_S pd\vec{S} = -\int_V \nabla p\,d\omega.$$
Why the transformation from a surface integral to a volume integral is given by the gradient and not by the divergence? I'm doing something wrong in the previous calculations?