Why does the piston move? The figure is a thermodynamic system with two pistons of area $S$ and $S+\mathrm{d}S$ held together by a unstretchable thread. A question said that when we apply heat to the gas between the pistons, the pistons start to move and the pressure remains constant but I don’t understand why wouldn’t the pressure increase and rather the system starts to move.$\hspace{200px}$
I thought the thread as a rod cause they are unstretchable. Then imagined the gas being heated and in the end all I could think of was that the pressure should increase on adding heat. (The pistons also have mass and gravity is pulling them down. $p_0$ in the figure is atmospheric pressure.)
I've know mathematical way to prove that the piston moves but that doesn't seem to make physical sense to me as I've explained in the description above. Could someone give me an intuitive and logical reasoning please.
 A: Works like this:


*

*Initially, everything is stationary; $p_0=p_{\text{internal}}$.

*Heating the gas increases $p_{\text{internal}}$, causing a non-zero force$$
\begin{alignat}{7}
F_{\text{piston}}&~~=~~ F_{\text{top}}  - F_{\text{bottom}}\\
&~~=~~ \left(p_{\text{internal}}-p_0\right)A_{\text{large}} -  \left(p_{\text{internal}}-p_0\right)A_{\text{small}} \\
&~~=~~\left(A_{\text{large}} - A_{\text{small}}\right) \left(p_{\text{internal}}-p_0\right) \, .
\end{alignat}
$$

*The force $F_{\text{piston}}$ causes the piston to move in the direction of the larger contact area.

*As the piston moves, the internal volume that the gas has access to increases, increasing $V_{\text{internal}}$ and thus decreasing $p_{\text{internal}}$.

*The piston continues to move until either:


*

*the pressures equalize and it's again stationary;

*the smaller contact area falls into the larger part of the tubular area, allowing gas to escape and disrupting the system.
If the question says that the pressure remains constant, then it may mean one of two things:


*

*The external pressure, $p_0$, is constant (as assumed above).

*The internal pressure, $p_{\text{internal}}$, is pseudo-constant because the heating is incredibly slow, such that the system responds too quickly for appreciable changes in pressure to be observable.
A: Let's assume that the initial pressure of the gas is $p_1$. 
Before the heat is applied, the pistons are held in place due to the balance between the weight of the system and the upward pressure, $mg=\Delta pdS$, where $\Delta p=p_1-p_0$.
When the gas is heated, the pressure of the gas increases to $p_2$, which increases $\Delta p$ and therefore the upward force. As a result, the pistons will be pushed up. 
As the pistons move up, the volume of the gas will increase, which, at some point, should decrease the gas pressure back to $p_1$ and restore the balance of the forces acting on the system, so the system will stop moving. 
