We are going to show how we calculate work for both reversible and irreversible processes
where we have expansion and compression in a piston/cylinder. So first we will look at
expansion and we will look at a reversible process. So work, in general, for both types
of processes, work is minus the integral of the external pressure times the differential
volume change. Because we are talking about a reversible process, a reversible process,
the external pressure is identical to pressure inside of the piston, the pressure of the
gas. And so this becomes the integral of the pressure, times the change in volume, where
now we are talking about the pressure of the gas. That means that work is the area under
the curve here, shown in crosshatch. This is reversible work the area is proportional
to the reversible work. As we expand from point 1 to point 2. So the piston then moves
from left to right. So now let's look in contrast to an irreversible process. So I am showing
a specific irreversible process and there's essentially an infinite number. But here we
are going to expand where the final pressure is pressure 2. Again work is equal to P external
dV. I am making the external pressure the final pressure. So P external delta V and
this area, now, this is the irreversible work. So first notice the irreversible work is smaller,
so this is work irreversible. Work is smaller, we have less resisting force. This of course
is only one of many ways we could carry out an irreversible process. We could do it in
steps where we would first go to half the pressure and get an area for example like
this, and then get a second area here for the other half. Or we could have no resistance,
get no work out when we do an irreversible expansion. But for doing expansion the irreversible
work is going to be less than the reversible work. And these two processes are for any
pathway, it doesn't have to be adiabatic or isothermal it can be something in between
for example. So that's expansion let's look at the case now for compression. So of course
for compression we are going to start at the low pressure 0.1 and go to the higher pressure.
Again, work is for a reversible process, integral of the pressure of the gas dV with a minus
sign. So this again reversible work looks identical but the sign is going to be opposite
for the numerical value, we are putting work into the system, as we compress it as the
gas moves from a larger volume to the smaller volume. In contrast if we look at the irreversible
process, so for the irreversible process we are going to have to use the external pressure,
in this case we are looking at a case where we have the final pressure, we have to at
least have the final pressure to compress to that value. We don't have to have it the
entire time but we certainly have to have it at the end. And we are going to do it irreversibly
so again it is P external dV and we are looking at a case where it is a constant external
pressure, P2. Notice this area is the irreversible work and it is much larger than the reversible
work right? So the work irreversible, we have to put more work in to compress irreversibly
because now we are using the same large pressure during the entire compression and so the pressure
external is higher than the gas pressure to get to the final point 2. For compression
the work we have to put in, numerical value is larger for expansion. The work we get out,
numerical value smaller for irreversible process.