# Mixing gas and find the temperature

1. Dec 21, 2008

### KFC

1. The problem statement, all variables and given/known data
Assume there are two different kind of monoatomic ideal gas A and B. n moles of A are placed in a insulated compartment while m moles of B are placed in another insulated compartment. There is an insulated partition to join this two compartment. If the initial temperature and pressure of A is known (Ta, P) and the initial temperature and pressure of B is know (Tb, P), find the final temperature after the partition was removed. Assuming Tb>Ta, two initial volume for each compartment are the same.

2. The attempt at a solution
I know I should apply the energy relation to find out final temperature. That is, the energy absorbed by the low temperature gas is identical to the energy released by the high temperature gas. If we know the capacity heat, it is easily to write down some thing like

n C (Tf-Ta) + m C (Tf-Tb) = 0

I think this relation is correct, right?

Now, I just wondering how to solve for C in this case. There is two different capacity for ideal gas: isobar (Cp) or isovolumn (Cv). However, since while the gas is mixing the pressure must change and volume will also be change, it seems that both Cp or Cv is not suitable. How to find the capacity heat?

2. Dec 21, 2008

### Mapes

Constant volume. The equation

$$\Delta U=c_Vn\Delta T=(c_P-R)n\Delta T$$

always applies for an ideal gas, regardless of the process. (I know this can be confusing. But $U$ is a state variable; it is process independent. $c_V$ and $c_P$ are simply variables that are used in this state equation, not constraints on the type of process.) Does this make sense?

3. Dec 21, 2008

### KFC

Use Cv, I do can find the correct answer. Still quite confusing ... does it mean if only I know the temperature difference, no matter what process it is, the heat absorbed/released by the ideal gas always equal to $$Cv\Delta T$$ ? What also confuses me is: is this sense, why don't use $$C_p\Delta T$$ instead?

4. Dec 21, 2008

### Mapes

$C_V$ is the right variable to use because (whether you knew it or not) you're solving the problem by splitting it into two reversible processes: (1) isothermal expansion to the final volume and (2) isochoric heating or cooling. The isochoric heating or cooling is where $\Delta U=C_V\Delta T$ comes in.

You could also solve the problem by assuming isobaric heating or cooling ($\Delta H=C_P\Delta T$), and you'd get the same answer. It's a little more involved because an additional intermediate variable (the volume at the end of the isobaric process) comes into play. It's a good idea to try to solve the problem using a couple different approaches, though, to make sure everything's straight in your head.

5. Dec 21, 2008

### KFC

Thanks a lot.

6. Dec 21, 2008

### KFC

Sorry to bother again. According to your hint, I want to extend the problem to find the total entropy changed. I know the free expansion is not a reversible process so we cannot use the definition of entropy to calculate the total change of entropy. But since entropy is state variable, for the gas in the left compartment, I imagine two processes such that these process has same initial state and final state with free expansion.

1) The gas expand from V to 2V with the temperature unchanged (isotherm)
2) the expanded gas being heated up by absorbing some amount of heat (isochoric)

For the first process, since temperature doesn't change, the internal energy doesn't change, so $$dQ = PdV$$, we find the change of entropy

$$\Delta S_1 = \int_V^{2V}\frac{PdV}{T} = nR\int_V^{2V}\frac{dV}{V} = nR\ln 2$$

For second process, the volume doesn't change, hence, $$dU = dQ$$

$$\Delta S_2 = \int \frac{dQ}{T} = \int \frac{dU}{T} = nC_v\int_{T_a}^{T_f}\frac{dT}{T} = nC_v\ln \frac{T_f}{T_a}$$

the total change for the gas in the left compartment be

$$\Delta S_{left} = \Delta S_1 + \Delta S_2 = nR\ln 2 + nC_v\ln\frac{T_f}{T_a}$$

For the gas in the right compartment, we can also design a similar process to calculate the entropy. So the total change of entropy is just the sum of change of entropy of left gas and that of right gas. Is this a correct approach to calculate the change of entropy in this case?

Thanks and sorry to bother again.

7. Dec 21, 2008

### Mapes

Nice work!

8. Dec 21, 2008

### KFC

:)
Mapes, thanks a lot for your help and encouragement. Wish you have a great Christmas!