# Work done on a gas when it is doing work?

I’m confused about work and gases. So let’s say we have a container with gas in it as well as a piston above it that is moveable. If we draw a force diagram of the gas, it has a force applied from the piston/surroundings, and an equal and opposite force from the container. So when a gas does work on its surroundings , as in it expands, the piston and surroundings are still applying a force to the gas over this change in distance. So does it make sense to say that when a gas does work on its surroundings, work is still being applied to it? But that doesn’t make any sense to me. Please help!

If a force moves in the same direction as the force itself, then it is doing (positive) work. So if a gas pushes a piston outwards, we say that the gas is doing work on the piston, and therefore on the surroundings.

But, you say, the surroundings are exerting a force 'inwards' on the piston. When the piston moves outwards, the force exerted on it by the surroundings is in the opposite direction to the direction of motion of that force. The surroundings therefore do a negative amount of work on the piston. In other words, the surroundings have work done on them – exactly as we concluded in the first paragraph by considering the work done by the gas!

During expansion, the gas exerts a force on its surroundings in the direction of the displacement of the piston and the atmosphere. When force is in the same direction as displacement, the work being done by that force is positive. Positive work means the source of the work (the gas) is transferring energy to the surroundings.

Now looking at it from the perspective of the surroundings (piston and atmosphere), it is exerting a force on the gas that is opposite the direction of the displacement. Consequently, the surroundings is doing negative work on the gas. When negative work is done the source of the work (surroundings) takes energy away from the gas.

For conservation of energy, the energy transferred from the gas to the surroundings due to positive work equals the energy taken from the gas by the surroundings due to negative work.

Hope this helps.

• does that mean that the system of gas is loosing the Same amount of energy twice : one due to its positive work and the other because of the negative work on it ? Commented Oct 20, 2020 at 15:02
• No. The gas does the positive work and the surroundings does an equal amount of negative work. Commented Oct 20, 2020 at 15:09
• okay. The gas does a positive work on the surrounding and so it loses some energy and also the surrounding does equal negative work on the system so it will also take out some energy from the system again . So isn't the system losing twice the energy ? Commented Oct 20, 2020 at 16:12