# What is the physical implication of Clausius inequality?

Clausius inequality is given as: $$\oint \frac{\delta Q_\text{res}}{T_\text{res}} \le 0\;.$$

From Carnot cycle, we get the equality relation as the entropy lost by the hot reservoir is the same as the entropy gained by the cold reservoir.

The inequality sign then of course mean that the entropy gained by the cold reservoir is less than the entropy lost by the hot reservoir.

But what happens actually that led the reservoirs sometimes to have no entropy change but in other cases, negative entropy change?

What is the physical implication of this relation both in ideal cases (where no damping or friction is present) & in reality (where dissipative agents are present)?

• Posted an answer. Edited the post right away with a TL;DR at the beginning. Nov 12, 2015 at 21:35
• I added a brief comment at the beginning of the post correcting some misconceptions in the question. It acts, I think, as a good introduction to the rest of the answer. Nov 13, 2015 at 0:00

### TL;DR

The integral in the Clausius inequality is negative the portion of the entropy change of the reservoirs that is due to energy exchange via heating with the system, i.e. $$0 \geq \oint \frac{\delta Q_{\text{sys}}}{T_{\textrm{res}}} = - \Delta S_{\text{res due to heat exchange with sys}}.$$ (I use the word "portion" because the reservoirs are allowed to exchange energy with the rest of the universe, and so some portion of the entropy change of the reservoirs could come from elsewhere). Strict inequality arises when (a) at least one of the processes undergone by the system is non-quasi-static or (b) the system and reservoirs exchange energy via heating when there is a finite temperature difference between them. Strict equality holds when neither (a) nor (b) hold, and in this case the cycle undergone by the system is called reversible.

Finally, one can use the Clausius inequality to characterize how much work we could have done but didn't by (b) not taking advantage of those finite temperature differences or (c) not taking advantage of the internal irreversibilities$-$like internal pressure gradients, internal temperature gradients, and so on, which synonymous with the processes not being quasi-static$-$to do work.

### Brief note on the question before the long explanation

In the question, you have written the Clausius inequality incorrectly. It is actually $$\oint \frac{\delta Q_{\text{sys}}}{T_{\textrm{res}}} \leq 0.$$ Note the subscripts! - the $Q$ is the heating of the system, but the $T$ is the temperature of the reservoirs! So when you say

The inequality sign then of course mean that the entropy gained by the cold reservoir is less than the entropy lost by the hot reservoir. But what happens actually that led the reservoirs sometimes to have no entropy change but in other cases, negative entropy change?

you are reversing things! The reservoirs' total entropy either stays the same or goes up, which is of course a consequence of the Second Law, keeping in mind that the change in system entropy is zero because the system operates on a cycle.

# Explanation

We'll take this in steps, starting with the Carnot cycle, moving on to an arbitrary reversible engine, move from there to an irreversible engine where the irreversibility is due to temperature difference between the system and the reservoir, and finally conclude by looking at an engine where there are irreversibilities present within the system.

## The reversible Carnot cycle

Here we compute the integral in the Clausius inequality for the four processes: the first is an isothermal compression, the second an adiabatic compression, the third an isothermal expansion, and the fourth an adiabatic expansion. During the isothermal phases, the system and the reservoir with which its in contact are at the same, constant temperature.We therefore break up the integral into these four parts as \begin{align} \oint \frac{\delta Q}{T_{\textrm{res}}} = \int_{1} \frac{\delta Q}{T_{\textrm{res}}}+\int_{2} \frac{\delta Q}{T_{\textrm{res}}} +\int_{3} \frac{\delta Q}{T_{\textrm{res}}}+\int_{4} \frac{\delta Q}{T_{\textrm{res}}}. \end{align} Processes 2 and 4 are adiabatic, so they contribute nothing to the integral, and so we are left with \begin{align} \oint \frac{\delta Q}{T_{\textrm{res}}} = \int_{1} \frac{\delta Q}{T_{\textrm{res}}}+\int_{3} \frac{\delta Q}{T_{\textrm{res}}} =\int_{1} \frac{\delta Q}{T_{\textrm{C}}}+\int_{3} \frac{\delta Q}{T_{\textrm{H}}} =\frac{1}{T_{\textrm{C}}}\int_{1} \delta Q + \frac{1}{T_{\textrm{H}}}\int_{3} \delta Q, \end{align} which is then just \begin{align} \oint \frac{\delta Q}{T_{\textrm{res}}} &=\frac{Q_{1}}{T_{\textrm{C}}} + \frac{Q_{3}}{T_{\textrm{H}}} =\frac{-Q_{\textrm{C}}}{T_{\textrm{C}}} + \frac{Q_{\textrm{H}}}{T_{\textrm{H}}}. \end{align} This quantity is zero for the Carnot cycle, as can be readily verified in various ways, so this satisfies the inequality.

It is also useful to compute the component of the change in entropy of the reservoirs during this process that is due to exchange of energy with the system. The reservoirs might be gaining or losing entropy because they might be interacting with other parts of the universe, but we don't care about that (or we can assume for now that the system plus reservoirs is thermally (but not mechanically) isolated from the rest of the universe. The change in entropy of the system is of course zero because it operates on a cycle. So: $$\Delta S_{\text{res}} = \frac{Q_{\text{hot}}}{T_{\text{H}}} + \frac{Q_{\text{cold}}}{T_{\text{C}}} = \frac{-Q_{\text{H}}}{T_{\text{H}}} + \frac{Q_{\text{C}}}{T_{\text{C}}}.$$ This is exactly the negative of the quantity we computed above (although of course, it's still zero in this case). This suggests that what we are computing is the change in entropy of the reservoirs that is brought about due to energy exchange via heating with the system.

## An arbitrary reversible engine

In this case, the system temperature is at all times equal to the temperature of the reservoir that it is in contact with. But since the temperature of the system can change while it is also exchanging energy via heating with the reservoir, the temperature of the reservoir must be changing along with the system (or, as is normally stipulated, the system is brought into contact with a sequence of reservoirs with infinitesimally different temperatures). If we calculate the portion of the net change in entropy of the reservoirs that is due to the exchange of energy via heating with the system, then we exactly compute $$\oint \frac{\delta Q_{\text{res}}}{T_{\text{res}}} = -\oint \frac{\delta Q_{\text{sys}}}{T_{\text{res}}}.$$ This is the negative of the quantity appearing in the Clausius inequality, and in this case it is again 0. This is harder to see, of course, but in the proof the Clausius inequality, it is shown that equality holds for reversible cycles.

Once again, this suggests that the left-hand side of the Clausius inequality is the negative of the change in entropy of the reservoirs that is brought about by exchange of energy via heating with the system (that is undergoing a cycle).

## A non-Carnot cycle operating between only two temperatures

Let's consider one of the simplest cases, which is the Otto cycle. The Otto cycle consists of an adiabatic compression (Processes 1), and adiabatic expansion (Process 3), and two isochors (Processes 2 and 4). During the adiabatic processes, no energy is exchanged by heating. Therefore, the change in entropy of the reservoirs brought about by exchange of energy via heating with the system is \begin{align} \oint \frac{\delta Q_{\text{res}}}{T_{\textrm{res}}} = \int_{2} \frac{\delta Q_{\text{res}}}{T_{\textrm{res}}}+\int_{4} \frac{\delta Q_{\text{res}}}{T_{\textrm{res}}} =\frac{Q_{\text{cold}}}{T_{\textrm{C}}} + \frac{Q_{\text{hot}}}{T_{\textrm{H}}} =\frac{Q_{\text{C}}}{T_{\textrm{C}}} + \frac{-Q_{\text{H}}}{T_{\textrm{H}}}. \end{align} Now, during Process 2, the system is always hotter than the reservoir, and during Process 4, the system is always cooler than the reservoir. We will do the careful calculation in just a second, but this implies that the quantity we've just calculated must be positive, which then implies that the negative of this quantity (which is the one that appears in the Clausius inequality) is negative.

As for the calculation, we can write $\bar{T}_{\text{sys},2} > T_{\text{C}}$, where $$\bar{T}_{\text{sys},2} = \frac{1}{\Delta S_2}\int_2 TdS$$ is the average temperature during Process 2. Similarly, during Process 4, the system is always cooler than the reservoir, so $\bar{T}_{\text{sys},4} < T_{\text{H}}$. The change in entropy for the cycle can be written in terms of the average temperatures as \begin{align} 0 &= \Delta S_{\text{sys}} = \Delta S_1 + \Delta S_2 + \Delta S_3 + \Delta S_4 = \Delta S_2 + \Delta S_4\\ &=\frac{Q_2}{\bar{T}_{\text{sys},2}} + \frac{Q_4}{\bar{T}_{\text{sys},4}} =\frac{-Q_{\text{C}}}{\bar{T}_{\text{sys},2}} + \frac{Q_{\text{H}}}{\bar{T}_{\text{sys},4}} \\ & > \frac{-Q_{\text{C}}}{{T}_{\text{C}}} + \frac{Q_{\text{H}}}{{T}_{\text{H}}} \end{align}

This quantity is exactly the negative of the quantity above, which shows that the net change in entropy (due to the interactions with the system) of the reservoirs during the cycle is necessarily positive and that the Clausius inequality is then again satisfied (because the integral in the inequality is the negative of the change in entropy of the reservoir that we computed above).

## Intermission

To sum up, the quantity $$-\oint \frac{\delta Q_{\text{sys}}}{T_{\text{res}}}$$ is exactly the portion of the change in entropy of the reservoirs that is due to exchange of energy via heating with the system (which is undergoing a thermodynamic cycle). By carefully comparing the temperatures of the system and the reservoirs while heating is going on, we have determined that this quantity must be non-negative, and hence the inequality is satisfied.

So far, strict inequality is a result of the system and reservoirs exchanging energy via heating when they are at different temperatures, which makes sense since heat flow across a finite temperature difference is an irreversible process. However, the Clausius inequality should be strict for all irreversible processes, so we need to analyze the case where there are so-called irreversibilities within the system itself during the operation of the cycle: these are things like friction, temperature differentials within the system, pressure gradients within the system, etc. Anything that leads the system to undergo non-quasi-static processes, essentially.

## Internal irreversibilities

This situation is hard to analyze, and I'm not entirely sure I can do it with any sort of rigor at all. So let's work in reverse and consider a special case. Let's suppose we've got a system undergoing a thermodynamic cycle in which all of the processes are reversible except for one which is an irreversible, adiabatic expansion. There could for instance be a very rapid expansion of the system due to a large pressure differential between the system and its environment.

In order for the the Clausius inequality to be strict, there must be, in one of the other processes, more heat flow out compared to the reversible version of the cycle$-$making $\delta Q/T_{\text{res}}$ more negative for the process$-$of less heat flow in compared to the reversible version$-$making $\delta Q/T_{\text{res}}$ smaller for the process. This is consistent with the engine being less efficient, because either there's more waste, or there's the same amount of waste but less available energy.

Basically, during the adiabatic expansion, there is less work done than if the adiabatic expansion was reversible (but took place between the same two volumes) (this is, by the way, another way to state the Second Law).

Again, this is all very nebulous because I don't actually know how to "mathematize" this part. But the overall point is this: if the system is allowed to undergo non-quasi-static (i.e. internally reversible) processes during the cycle, then it actually generates more entropy that it has to then get rid of to the reservoirs (in order for $\Delta S_{\text{sys,cycle}} = 0$), and as a consequence, this extra entropy is added to the reservoirs, which is why the Clausius inequality is strict in this case.

## Final words

And this is all ignoring possible irreversible processes elsewhere. The reservoirs themselves could be exchanging energy via heating with other parts of the universe, and as a consequence, the entropy of the universe could be increasing even if the Clausius inequality applied to this collection of system and reservoirs is actually an equality.

This, I think, is the final piece of the puzzle that always bugged me before. The Clausius inequality is really about calculating how much irreversibility there is associated with a system undergoing a thermodynamic cycle, and the irreversibility consists of two parts: (a) non-quasi-static processes going on inside the system and (b) energy exchange via heating between system and reservoir when they are at different temperatures.

In thermal systems engineering (I am a physicist, but I teach an engineering thermodynamics course as a service course for the engineering department), the Clausius inequality is used to characterize how much work could have been done but wasn't due to (a) and (b) above. There, the idea is that if the Clausius inequality is strict, this means that a sufficiently clever engineer can fix the engine in order to get more work out and hence get the Clausius inequality closer to an equality. For instance, we can always put a little Carnot engine between the original system and the reservoir it is exchanging energy with if they are exchanging energy when at different temperatures, and hence extract more work.