How can this result in Thermodynamics be rigorously proved? In Fermi's "Thermodynamics" there's a proof of the formula: $$W=\int _{V_1} ^{V_2} p\,\text dV,$$that is, the work done by the pressure of a gas that expands from a volume $V_1$ to a volume $V_2$ on the surface that contains it is equal to the integral above. The proof goes like this:

Consider a surface element $\text d \sigma $ and let $\text d n$ be its
  displacement in the direction normal to it. The infinitesimal work
  done on this element during the expansion is given by $$F_\perp \text
 d n=p\,\text d\sigma \, \text d n.$$ Since the pressure is assumed to be
  constant everywhere, this gives:$$\text d W=p\int \text d \sigma \, \text
 d n.$$ On the other hand, the variation $\text d V$ is given by the
  surface integral:$$\text d V=\int \text d \sigma \, \text d n$$ and so
  the formula.

I don't think it is unrespectful to Fermi to call this a fake proof, at least by the mathematician's point of view. I was wondering how could one rigorously justify all the passages, starting from the usual definition of work:$$W=\int _{\mathbf r _1} ^{\mathbf r _2} \mathbf F\cdot \text d\mathbf r .$$ In particular, how could I make sense of the (very puzzling) formula $\text d V=\int \text d \sigma \, \text d n$?
This is one of a billion cases, in elementary physics, where is used an infinitesimal reasoning to get a finite result (where there's no “differential forms” or other sophisticated technology implied) and I think it would be interesting to hear a mathematician point of view.
 A: I know this is not really what the OP wanted, but to me  $W = \int {\rm d}{\bf r \cdot F}$ is a bad starting point.  It's a bit like a schoolboy saying Pythagoras' theorem is $a^2 + b^2 = c^2$ and forgetting about triangles.  I am sure you can sharpen it up by defining just what manifold to apply the formula too, but the classic definition of thermodynamic work is more physical:
Work is done by a system on the surroundings if the sole effect on the surroundings could have been raising a weight. 
I think my university textbook was much more pedantic.  In particular it would have taken care of the weight falling as well.  But I will leave that as an exercise.
So here is my proof of $\Delta W = P\Delta V$, for any constant-pressure process (turning this into $dW = PdV$ really is about maths).  Go to the theoretical physics lab (place of thought experiments) and:


*

*Place the system of interest inside a bath filled with an incompressible fluid of negligible density.  

*Seal the that bath with a piston of weight $mg$, have a vacuum above the piston.

*Allow any thermodynamic process to occur in your system, and observe the change in height $\Delta y$ of the piston/weight after it has come to rest.


proof: If $\Delta y >0$, then by the definition above the system has done work $W = mg\Delta y$.  By Pascal's law, the pressure of the fluid on the piston is the same as $P$ for the system under test.  Since the fluid is incompressible, the volume change in the system $\Delta V$ is also the volume change in the whole bath.  But if the piston's area is $A$, then $\Delta V = A\Delta Y$.  But the hydrodynamic force on the piston has to balance gravity, thus $PA = mg$.  Therefore $P\Delta V = mg\Delta Y = W$.
I like to think that proof is even more aggravating to mathematician's than Fermi's "fake" proof.  But what interests me is that it probably buries $W = \int {\rm d}{\bf r \cdot F}$ underneath some physical assumption.  My guess is that it is in Pascal's law.  But then you need Pascal's law to make sense of the formula in the first place.  
A: Indeed, $\vec{F}$ $\large\left(~\mbox{due to the pressure}~\right)$ is perpendicular to the surface. That defines the pressure $P$ according to $\vec{F} \equiv P\,{\rm d}\vec{S}$. $P$ is always a scalar. In addition, the displacement ${\rm d}\vec{r}$ is parallel to ${\rm d}\vec{S}$. Then,
$$
\vec{F}\cdot{\rm d}\vec{r}
=
P\,{\rm d}\vec{S}\cdot{\rm d}\vec{r}
=
P\
\overbrace{\quad%
\left\vert{\rm d}\vec{S}\right\vert
\cdot
\left\vert{\rm d}\vec{r}\right\vert\cos\left(0\right)\quad}
^{\displaystyle{{\rm d}V}}
=
P\,{\rm d}V
$$
The result is misleading since $P\,{\rm d}V$ is evaluated at the surface and $P\,{\rm d}V$ is not an exact differential.
Whenever $\vec{F}$ isn't parallel to ${\rm d}\vec{S}$ is due to other physical contributions as the viscosity which is added to the contribution from the pressure. In any case, $P$ remains as a scalar. By the way, $\eta\nabla^{2}\vec{v}$ is the force per unity of volume due to the viscosity. $\eta > 0$: Viscosity coefficient. $\vec{v}$: Fluid velocity.
