# Change in entropy of thermodynamic environment during isobaric or isochoric processes

When an ideal gas follows a isobaric or isochoric transformation (no matter if it is reversible or not) I'm not sure what is the change in entropy of the thermodynamic environment.

First of all, suppose there is no such thing as a thermostat (or body with infinite thermal capacity) in contact with the gas, so the thermodynamic environment changes its temperature throughout the process.

Now is it correct to calculate the change in entropy of the thermodynamic environment as follows?

$$\mathrm{isochoric : \,} \Delta S=-n c_V \mathrm{ln}\frac{T_f}{T_i}$$ $$\mathrm{isobaric : \,} \Delta S=-n c_P \mathrm{ln}\frac{T_f}{T_i}$$

• That would be correct if the processes were reversible. Otherwise, it's not, and there's no way to calculate the change in entropy of the environment without knowing the particular process it is undergoing (and even then, it might not be possible if the environment isn't undergoing a quasistatic process); alternatively, if the environment is in an equilibrium state at the beginning and end of the process, and you happen to know the equation of state, then you can calculate the change in entropy from there. Jun 20 '16 at 17:03
• (I assumed in my comment above that your expressions involved state variables of the system. If those variables are actually the ones associated with the environment, then your calculation is correct as long as the environment is an ideal gas, even if the environment is not undergoing a quasistatic process.) Jun 20 '16 at 17:05
• @march Thanks for the answer! About your second comment: I'm not thinking as environment an ideal gas, but, for istance, an object with thermal capacity $C$. But, indipendently for the reversibility of the process, the temperature of this object at the beginning and at the end must be the same as the gas. Furthermore the entropy is a function of state so it has the same expression indipendently from the reversibility. Jun 20 '16 at 18:12
• My argument was just the following: in a reversible isochoric process I can write $d Q= n c_V dT$, so the change in entropy of the environment is $d S=\frac{-dQ}{T}=\frac{- n c_V dT }{T} \implies \Delta S=-nc_V \mathrm{ln} \frac{T_f}{T_i}$. Now, since I can calculate the entropy of irreversible process along a reversible process, I can say that $\Delta S$ has that expression for any process, indipendently from the reversibility. Could this be correct? Jun 20 '16 at 18:15
• I think I see what you mean, but it would be useful to be make fully explicit in your question what quantities refer to the environment and which quantities refer to the system. (By the way, something seems mysterious in your last comment: I don't quite follow your argument, so I could be wrong about this, but it seems like $dT$ refers to the system $dT$ whereas the $T$ in the denominator seems like the environment $dT$, so it seems there's an inconsistency.) Jun 20 '16 at 21:09

If you can take the environment to be one with constant specific heats $c_p$ and $c_V$, then you can write $$dS_{\textrm{env}}=\frac{\delta Q_{\textrm{env}}}{T_{\textrm{env}}} = \begin{cases} \frac{nc_VdT}{T} & \textrm{if isochoric} \\ \frac{nc_pdT}{T} & \textrm{if isobaric} \end{cases},$$ where the temperatures all refer to the environment. Then, when integrated between final and initial temperatures, we arrive at $$\Delta S_{\textrm{env}} = \begin{cases} n c_V \ln\left(\frac{T_f}{T_i}\right) & \textrm{if isochoric} \\ n c_p \ln\left(\frac{T_f}{T_i}\right) & \textrm{if isobaric} \end{cases},$$ where, again, all quantities refer to the environment.

I assumed above that the processes undergone by the environment were quasi-static (or quasi-equilibrium). If the process was not quasi-static, we can only use the above expressions to compute the change in entropy provided the initial and final state variables of the environment match up correctly.

For instance, suppose that during the quasi-static, isobaric process assumed above, the environment moves from the state described by $(T_i,V_i,p_i)$ to the state described by $(T_f,V_f,p_f = p_i)$. Then the change in entropy of the environment during a non-quasi-static process taking place between the same two states would again be given by $$\Delta S_{\textrm{env}} = n c_p \ln\left(\frac{T_f}{T_i}\right).$$ However, this process would most likely not be isobaric, since intensive state variables like pressure tend to not be well-defined during non-quasi-static processes.

For further reference: supposing that the system and the environment are exchanging energy with each other via heat but are otherwise isolated from their environments, we can write $$\delta Q_{\textrm{env}} = -\delta Q_{\textrm{sys}},$$ in which case $$dS_{\textrm{env}} = \frac{\delta Q_{\textrm{env}}}{T_{\textrm{env}}} = -\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{env}}} \geq -\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}}.$$ Let's prove the inequality:

1. If $T_{\textrm{sys}} \geq T_{\textrm{env}}$, then the system loses energy to the environment via heat, and so $\delta Q_{\textrm{sys}} < 0$. In that case, $-\delta Q_{\textrm{sys}} = |\delta Q_{\textrm{sys}}|$, and so $$-\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{env}}} =\frac{|\delta Q_{\textrm{sys}}|}{T_{\textrm{env}}} \geq \frac{|\delta Q_{\textrm{sys}}|}{T_{\textrm{sys}}} = -\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}},$$ where the inequality comes in because we have replaced the smaller environment temperature with the larger system temperature.

2. If $T_{\textrm{sys}} \leq T_{\textrm{env}}$, then the system gains energy from the environment via heat, and so $\delta Q_{\textrm{sys}} > 0$. In that case, $-\delta Q_{\textrm{sys}} = -|\delta Q_{\textrm{sys}}|$, and so $$-\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{env}}} =-\frac{|\delta Q_{\textrm{sys}}|}{T_{\textrm{env}}} \geq \frac{|\delta Q_{\textrm{sys}}|}{T_{\textrm{sys}}} = -\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}},$$ where here, the replacement of a smaller denominator makes a "larger negative" number, in which case we get the same inequality.

Then, in the case that the system undergoes either an isochoric or isobaric process, we can write $$\Delta S_{\textrm{env}} \geq \begin{cases} -n_{\textrm{sys}} c_{V,\textrm{sys}} \ln\left(\frac{T_{f,\textrm{sys}}}{T_{i,\textrm{sys}}}\right) & \textrm{if isochoric} \\ -n_{\textrm{sys}} c_{p,\textrm{sys}} \ln\left(\frac{T_{f,\textrm{sys}}}{T_{i,\textrm{sys}}}\right) & \textrm{if isobaric} \end{cases}.$$ Of course, we knew this already, because if we go back to $$dS_{\textrm{env}}\geq -\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}},$$ we can identify the right-hand side as minus the change in entropy of the system, and re-arranging, we get---of course---the Second Law of Thermodynamics: \begin{align*} dS_{\textrm{env}}&\geq -\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}} = -dS_{\textrm{sys}} \Longrightarrow\\ 0 &\leq dS_{\textrm{env}} + dS_{\textrm{sys}}. \end{align*}

• The second part of the answer is exactly what I meant ( heat is exchanged only between system and environment)! But the change in entropy is always calculated along a reversible process, that is $dS_{\textrm{env}} = (\frac{\delta Q_{\textrm{env}}}{T_{\textrm{env}}})_{reversible}= (\frac{-\delta Q_{\textrm{sys}}}{T_{\textrm{env}}})_{reversible}$. Now in a reversible process thermal equilibrium is always present, so $(\frac{-\delta Q_{\textrm{sys}}}{T_{\textrm{env}}})_{reversible}=-\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}}=dS_{\textrm{env}}$. I do not understand that $\geq$. Jun 21 '16 at 11:23
• I would have written $dS_{\textrm{env}}=(\frac{-\delta Q_{\textrm{sys}}}{T_{\textrm{env}}})_{reversible}=-\frac{\delta Q_{\textrm{sys}}}{T_{\textrm{sys}}}\geq (\frac{-\delta Q_{\textrm{sys}}}{T_{\textrm{env}}})_{irreversible}$. Jun 21 '16 at 11:25
• The same holds for the integration to: $\Delta S_{\textrm{env}} \geq \begin{cases} -n_{\textrm{sys}} c_{V,\textrm{sys}} \ln\left(\frac{T_{f,\textrm{sys}}}{T_{i,\textrm{sys}}}\right) & \textrm{if isochoric} \\ -n_{\textrm{sys}} c_{p,\textrm{sys}} \ln\left(\frac{T_{f,\textrm{sys}}}{T_{i,\textrm{sys}}}\right) & \textrm{if isobaric} \end{cases}$ I think $\geq$ should be $=$ because the integral is made along a reversibile process. Maybe I’m missing something important, but I do not see why the formula proposed should hold only for reversible processes, since entropy is a function of state. Jun 21 '16 at 11:26
• I think you're not distinguishing between quasistatic and reversible. A system undergoes a quasistatic (or quasiequilibrium) process when it the system goes through a sequence of equilibrium states. When that happens, we can calculate as we've done above. A system undergoes a reversible process if the process is quasistatic and the system can be reset to its original state in such a way that the environment is reset, too. From a practical standpoint, this means that the system and environment must exchange energy via heat only when they are at the same temperature, ... Jun 21 '16 at 16:29
• ... making the inequality above into an equality. As to your first comment, I think you're correct, except that you need to be careful about the endpoints of the process (the last paragraph of the first part of my answer). To calculate the change in entropy during an irreversible process, you need to find a reversible process taking place between the same two endpoints and use that to calculate the change in entropy. You just need to be really careful about this: what I often see when teaching thermodynamics is that students tend miss that, and so get confused when $\Delta S$ ... Jun 21 '16 at 16:29

Your analysis is totally correct (except for the sign of the change), provided cv refer and cp refer to the heat capacities of the environment, and Tf and Ti are the final and initial temperatures of the environment. In such an analysis, the "environment" becomes your system. The signs are, of course, incorrect. They should be +'s.