Adiabatic Gas Expansion between Two Tanks
In this Demonstration, one mole of an ideal gas expands when a valve is partly opened (by selecting the play button), from tank A (top) into tank B (bottom), which is initially at vacuum. Both tanks are well insulated. You can change the volume of tank B and the initial pressure of the gas with sliders. This also changes the initial temperature since the volume of tank A and the total number of moles do not change in the process. When the pressure in the two vessels is equal, the valve closes. The expansion of the gas that remains in tank A is modeled as an adiabatic, reversible expansion. Thus, this fraction of the gas does work in pushing the rest of the gas through the valve.

Download the CDF file to view the simulation using the free Wolfram CDF player.