# What is pressure energy in a closed system?

Let's consider a gas inside a closed cylinder with a piston. This can be considered a closed system. The First Law of Thermodynamics (FLD) for a closed stationary system can be given as

Q = U + W

where,

Q is the heat out of the system

U is the change in internal energy of the system

W is the work done on the system

Now I can compress this gas by doing some work on it. If I compress the gas isothermally, there is no change in the internal energy of the system, and the work done on the system will equal the heat out of the system, i.e., Q = W. In this case, the pressure of the system increases due to compressing the gas isothermally. Question: The energy into the system due to work done on it is equal to the energy out of the system in the form of heat. But the pressure of the system increases, which has the 'capacity to do work'. This increase in pressure seems to store energy, like a compressed spring. Where is this energy, stored as pressure, coming from?

• Your statement of the first law is wrong. Work and heat relate to change of internal energy, not to value of internal energy. Jun 3 at 22:32
• @JánLalinský Thanks, made the correction. Jun 4 at 6:26

This increase in pressure seems to store energy, like a compressed spring.

It seems to, but for an ideal gas, it doesn’t (store internal energy, that is); it stores negative entropy in the form of a smaller available volume to explore.

Unlike the physical spring, whose stiffness is enthalpic (with atoms raised to higher energy levels upon deformation), the stiffness of the ideal gas is solely entropic.

Note that in both cases, the Gibbs free energy—which depends on both the enthalpy and the (negative) entropy—increases, meaning we do indeed gain the capacity to extract work.

• You are becoming more and more Bronstedian with every passing day: "... it stores negative entropy in the form of a smaller available volume to explore", what is this world coming to? Jun 3 at 18:16

This increase in pressure seems to store energy, like a compressed spring. Where is this energy, stored as pressure, coming from?

Pressure is an energy density. You originally had $$p_0V_0$$ amount of such energy in the system. The final state has $$p_fV_f=p_0V_0$$, and you should see that the compression of the volume is the cause of the energy density to have increased. The total energy stored in the pressure form is the same.

• For ideal gas, pressure is proportional to energy density, but it is not the energy density itself. This is because energy density is $\frac{U}{V} = c n k_B T = cp$ where $c$ is some positive constant factor ($3/2$ for monoatomic gas). Jun 3 at 22:37
• and for more general system pressure is a partial derivative of the energy and not necessarily proportional to energy density at all. Jun 4 at 2:53
• I know that. I am pointing out that it is an energy density, not all the energy density of the system. I was thinking about Bernoulli's principle and the $U=TS-pV$ when I wrote that. Jun 4 at 5:15
• In Bernoulli's principle, pressure is not energy density. Bernoulli principle is valid for incompressible fluid, which takes zero work to compress to howsoever high a pressure. Jun 4 at 14:31