# Entropy of mixing

Hi again Physics Forums! Last time I was here, I was an undergrad student. Now I almost finished a PhD in quantum information and became a high school teacher.

I've never properly learnt thermodynamics. I'm now trying to get it on the same level, that I understand the other topics in classical physics, so that I could teach it properly also to the physics olympiad students.

Could you have a look at a problem that I think is solved wrong in the enclosed link?

1. Homework Statement

Take a look at the problem 7.20 in this pdf:

https://www.google.com/url?sa=t&rct...solution.pdf&usg=AOvVaw2vqk5Ol6WyVTr5UB9BB_G3

In the final equations for ΔSA and ΔSB they just subtitute in the final pressure of the whole gas. Shouldn't they use partial pressures of gas A and gas B respectively instead?

## Homework Equations

They start from ## dS=\frac{nc_VdT}{T}+\frac{nRdV}{V}## to get:
$$\Delta S = n c_p \log\frac{T_f}{T_0} - n R \log\frac{p_f}{p_0},$$
but I'm under the impression that ##n## here is taken to be constant, so they shouldn't plug in ##p_f## of the whole gas and ##p_0## of just the gas from one container.

## The Attempt at a Solution

[/B]
I start from the same equation and arrive at:
$$\Delta S = n c_V \log\frac{T_f}{T_0} + n R \log\frac{V_f}{V_0},$$
so in this problem, for the change of entropy of the universe I get:
$$\Delta S = n_A c_V \log\frac{T_f}{T_A}+n_B c_V \log\frac{T_f}{T_B} + (n_A + n_B) R \log\frac{V_f}{V_0},$$
which is consistent with:
$$\Delta S = n_A c_p \log\frac{T_f}{T_A}+n_B c_p \log\frac{T_f}{T_B} - n_A R \log\frac{p_f n_A}{p_A(n_A+n_B)} - n_B R \log\frac{p_f n_B}{p_A(n_A+n_B)},$$
and they have instead:
$$\Delta S = n_A c_p \log\frac{T_f}{T_A}+n_B c_p \log\frac{T_f}{T_B} - n_A R \log\frac{p_f}{p_A} - n_B R \log\frac{p_f}{p_A}.$$

Who's right?

## Answers and Replies

stockzahn
Homework Helper
Gold Member
Since the air is treated as homogeneous gas with general thermodynamic properties, there is no need to calculate the partial pressure. The answer given in the book is correct, I'm afraid your approach is wrong.

Are you aware that mass and not particle number is used to solve the task? It seems that you mixed kg and mol and the respective properties and values.

Do you know then where my mistake is?

I'm using the mole number, but when I plug in values to the last equation in my post, I get the answer from the book, so I don't think this is where the problem is.

stockzahn
Homework Helper
Gold Member
Do you know then where my mistake is?

I'm using the mole number, but when I plug in values to the last equation in my post, I get the answer from the book, so I don't think this is where the problem is.

I solved the problem using mass, not particle number. If you use the mole number and the values for ##R##, ##c_p##, ##c_v## etc. given in the book, then you shouldn't obtain the correct answer. So, for example, what value did you use for the gas constant ##R##?

I used ##R=8.31\frac{J}{mol K}##, ##c_V=\frac{5}{2}R##, ##c_p=\frac{7}{2}R## and got ##n_A=686.71## and ##n_B=264.34##. This gives their answer, when plugged into the last equation.

They use ##R'=\frac{R}{\mu}##, where ##\mu## is the molar mass, and then ##m=\mu n## so it's all consistent.

And e.g. if for air ##\mu=0.02897\frac{kg}{mol}## then one can check that indeed ##m_A=n_A \mu = 686.71\times 0.02897 \approx 19.89kg## as in the book.

Last edited:
stockzahn
Homework Helper
Gold Member
If I use this formula (Eq.1):

$$\Delta S = n_A c_p \log\frac{T_f}{T_A}+n_B c_p \log\frac{T_f}{T_B} - n_A R \log\frac{p_f n_A}{p_A(n_A+n_B)} - n_B R \log\frac{p_f n_B}{p_A(n_A+n_B)},$$

I don't obtain the correct answer, regardless of the values I use for ##R##, ##c_p##, ##c_v##.

With this formula on the other hand (Eq.2):

$$\Delta S = n_A c_p \log\frac{T_f}{T_A}+n_B c_p \log\frac{T_f}{T_B} - n_A R \log\frac{p_f}{p_A} - n_B R \log\frac{p_f}{p_A}.$$

I obtain the correct answer using either mass or particle number with the respective values for##R##, ##c_p##, ##c_v##. Which formula does work for you (Eq.1) or (Eq.2)?

Same as you - Eq. 2 works and Eq. 1 doesn't.

So the question is why Eq. 1 is wrong, keeping in mind that I derived it from the other equations in my original post.

Lord Jestocost
Gold Member
In the final equations for ΔSA and ΔSB they just subtitute in the final pressure of the whole gas. Shouldn't they use partial pressures of gas A and gas B respectively instead?

To my mind, the book is right. As the gases in vessel A and B are identical, there is no mixing entropy. So you can imagine that nA gas molecules change there state from (nA, pA, TA) to (nA, pf, Tf) accompanied by an entropy change ΔSA and that nB gas molecules change there state from (nB, pB, TB) to (nB, pf, Tf) accompanied by an entropy change ΔSB.

To my mind, the book is right. As the gases in vessel A and B are identical, there is no mixing entropy. So you can imagine that nA gas molecules change there state from (nA, pA, TA) to (nA, pf, Tf) accompanied by an entropy change ΔSA and that nB gas molecules change there state from (nB, pB, TB) to (nB, pf, Tf) accompanied by an entropy change ΔSB.

I'm following that, but shouldn't a tottaly equivalent approach be that nA gas molecules change there state from (nA, V0, TA) to (nA, Vf, Tf) accompanied by an entropy change ΔSA and that nB gas molecules change there state from (nB, V0, TB) to (nB, Vf, Tf) accompanied by an entropy change ΔSB? That was my original line of thought and but it gives a different result.

stockzahn
Homework Helper
Gold Member
This equation is wrong:

so in this problem, for the change of entropy of the universe I get:
$$\Delta S = n_A c_V \log\frac{T_f}{T_A}+n_B c_V \log\frac{T_f}{T_B} + (n_A + n_B) R \log\frac{V_f}{V_0},$$

It must read (if I didn't make a mistake):

$$\Delta S = n_A c_V \log\frac{T_f}{T_A}+n_B c_V \log\frac{T_f}{T_B} + n_A R \log\frac{V_f n_A}{V_0 (n_A+n_B)}+ n_B R \log\frac{V_f n_B}{V_0 (n_A+n_B)}$$

It must read (if I didn't make a mistake):

$$\Delta S = n_A c_V \log\frac{T_f}{T_A}+n_B c_V \log\frac{T_f}{T_B} + n_A R \log\frac{V_f n_A}{V_0 (n_A+n_B)}+ n_B R \log\frac{V_f n_B}{V_0 (n_A+n_B)}$$

I agree that what you derived, follows from Eq. 2 from our discussion, and gives the right result. But I don't understand why my equation is wrong. E.g. my form of ##\Delta S## is derived here http://web.mit.edu/16.unified/www/SPRING/propulsion/notes/node39.html . It appears just above Eq. (5.3).

stockzahn
Homework Helper
Gold Member
I agree that what you derived, follows from Eq. 2 from our discussion, and gives the right result. But I don't understand why my equation is wrong. E.g. my form of ##\Delta S## is derived here http://web.mit.edu/16.unified/www/SPRING/propulsion/notes/node39.html . It appears just above Eq. (5.3).

I didn't derive this equation from (Eq.2). The ratio of particle numbers of the "different" components correspond to the ratio of their volumina and the partial pressures:

$$\frac{n_i}{n_{tot}}=\frac{V_i}{V_{tot}}=\frac{p_i}{p_{tot}}$$

Therefore your last term

$$n_{tot} R ln\left(\frac{V_f}{V_0}\right)$$

is wrong, since the different components ##A## and ##B## consist of a different number of moles and therefore occupy different volumina in the final state. Component A occupies

$$V_{f A}=V_f \frac{n_A}{n_A +n _B}$$

and component B occupies

$$V_{f B}=V_f \frac{n_B}{n_A +n _B}$$

and the equation reads

$$\Delta S = n_A c_V \ln\frac{T_f}{T_A}+n_B c_V \ln\frac{T_f}{T_B} + n_A R \ln\frac{V_{f A}}{V_0}+ n_B R \ln\frac{V_{f B}}{V_0}$$

where ##V_f \neq V_{f A} \neq V_{f B}##.

Oh I see, thanks! That might be something I have to read about.

So you're saying for either one of the gases A and B separately, one should use full pressure and partial volume. But why not partial pressure and full volume?

stockzahn
Homework Helper
Gold Member
Oh I see, thanks! That might be something I have to read about.

So you're saying for either one of the gases A and B separately, one should use full pressure and partial volume. But why not partial pressure and full volume?

I'm not sure about the English expressions, so I just try to translate them word-for-word. The pressure is an intrinsic (?) value, the volume an extrinsic (?). Image you separate the final volume into two chambers. In each chamber the pressure is identical, but the (absolute) volumina decrease. Therefore the calculation of the entropy change with the volumina already contains the information about the size of the system, where calculating it with an intrinsic value (pressure, specific volume, ...) doesn't contain this information.

But suppose we have equal amounts ##\frac{n}{2}## of gas A and gas B separated in two equal volumes ##\frac{V}{2}##. The temperatures are the same and hence the pressures are the same. If we remove the separating wall, the gases will mix. In the final state their partial volumes will still be ##\frac{V}{2}##. The temperature didn't change. So ##\Delta S=0##? But that's clearly an irreversible process.

stockzahn
Homework Helper
Gold Member
But suppose we have equal amounts ##\frac{n}{2}## of gas A and gas B separated in two equal volumes ##\frac{V}{2}##. The temperatures are the same and hence the pressures are the same. If we remove the separating wall, the gases will mix. In the final state their partial volumes will still be ##\frac{V}{2}##. The temperature didn't change. So ##\Delta S=0##? But that's clearly an irreversible process.

If you separate them again, you will have the same properties for the two chambers - you can't distinguish the different molecules from each other, they are equivalent. Maybe the process is microscopically irreversible, since some molecules will have changed chambers, but macroscopically nothing would have had changed and ##\Delta S=0##.

Hi again,

Stockzahn, thanks for your replies. In my studying I got to gas mixtures (hence the delay) and while I still can't fully justify to myself the procedure shown in the book, I found this paper:
https://www.google.com/url?sa=t&rct..._paradox.pdf&usg=AOvVaw0MiqUFVeGti78hZzy1Q0PP

I'm under the impression that Eq. 1 would be correct if gases A and B were distinguishable. Then according to the Gibbs' theorem (as stated in the paper), for the final state I would need to add entropies of the gases, as if they occupied the whole volume - therefore I would need to use their partial pressures. But if the gases are indistinguishable, it doesn't work that way, and there's a different formula for the entropy change - Eq. 2. Does that make sense?

Chestermiller
Mentor
Hi again,

Stockzahn, thanks for your replies. In my studying I got to gas mixtures (hence the delay) and while I still can't fully justify to myself the procedure shown in the book, I found this paper:
https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=5&cad=rja&uact=8&ved=2ahUKEwiQ7u6Tps_cAhXNYVAKHcRIDwcQFjAEegQIBhAC&url=http://fisica.unipv.it/Mihich/gibbs_paradox.pdf&usg=AOvVaw0MiqUFVeGti78hZzy1Q0PP

I'm under the impression that Eq. 1 would be correct if gases A and B were distinguishable. Then according to the Gibbs' theorem (as stated in the paper), for the final state I would need to add entropies of the gases, as if they occupied the whole volume - therefore I would need to use their partial pressures. But if the gases are indistinguishable, it doesn't work that way, and there's a different formula for the entropy change - Eq. 2. Does that make sense?
It does to me.