Partial derivative of $PV=nRT$ with respect to $T$

We all know for an ideal gas $$PV=nRT$$ then, if we differentiate it partially w.r.t $$T$$ shouldn't we get

$$\frac{\partial}{\partial T}(PV)=P\left(\frac{\partial V}{\partial T}\right)_P+V\left(\frac{\partial P}{\partial T}\right)_V$$

and $$\frac{\partial}{\partial T}(nRT)=nR$$ so that $$P\left(\frac{\partial V}{\partial T}\right)_P+V\left(\frac{\partial P}{\partial T}\right)_V=nR?$$

But every book says $$P\left(\frac{\partial V}{\partial T}\right)_P=nR$$ for an ideal gas from $$PV=nRT$$. $$\frac{\partial}{\partial T}(PV)$$ is always nR. There is no confusion about it. But I want to know why they write "$$P\left(\frac{\partial V}{\partial T}\right)_P=nR$$" instead of "$$P\left(\frac{\partial V}{\partial T}\right)_P+V\left(\frac{\partial P}{\partial T}\right)_V=nR?$$"?? They use this relation $$P\left(\frac{\partial V}{\partial T}\right)_P=nR$$ to derive $$C_p-C_v=nR$$ and just wrote there that it's hold for the ideal gas. Why they did so? What is wrong in my derivation? please help.

• Oh no...I missed the n in last line. Sorry, my question was not why n went, there was a n obviously, but my question was where did the another part go in the partial derivative. Shouldn't be there 2 derivatives as mentioned in my question? – Srijan Ghosh Apr 11 at 17:35

You are applying the product rule incorrectly. You have to specify which variables your derivative holds constant "at the beginning". In other words, you don't mix what is held constant. So if you want to hold volume (and number of particles) constant you do

$$\left[\frac{\partial(PV)}{\partial T}\right]_{n,V}=V\left(\frac{\partial P}{\partial T}\right)_{n,V}+P\left(\frac{\partial V}{\partial T}\right)_{n,V}=V\left(\frac{nR}{V}\right)+0=nR$$

To verify: $$\left[\frac{\partial(PV)}{\partial T}\right]_{n,V}=\left[\frac{\partial(nRT)}{\partial T}\right]_{n,V}=nR$$ or you can do the same thing with pressure being held constant. You will find the same thing.

What you propose will actually end up adding $$nR$$ twice and will thus give you $$2nR$$. The expression $$\frac{\partial}{\partial T}(PV)$$ isn't very good to use since you aren't specifying what you are holding constant (and you can't hold all other variables constant or else you wouldn't be able to change the temperature due to the ideal gas law).

Now, we technically don't need to hold $$P$$ or $$V$$ constant, but in general we would need to at least specify how one of these changes with respect to the other variables, since there is more than one way $$P$$ and $$V$$ could both vary as we change the temperature. However, it turns out for the ideal gas that this specification is irrelevant. Let's see why by only holding $$n$$ constant. Then we have \begin{align}\left[\frac{\partial(PV)}{\partial T}\right]_n&=V\left(\frac{\partial P}{\partial T}\right)_{n}+P\left(\frac{\partial V}{\partial T}\right)_{n} \\ & =V\left(\frac{\partial (nRT/V)}{\partial T}\right)_{n}+P\left(\frac{\partial V}{\partial T}\right)_{n} \\ & =nR-\frac{nRT}{V}\left(\frac{\partial V}{\partial T}\right)_{n}+P\left(\frac{\partial V}{\partial T}\right)_{n} \\ & =nR-P\left(\frac{\partial V}{\partial T}\right)_{n}+P\left(\frac{\partial V}{\partial T}\right)_{n}\\ & =nR\end{align}

So as you can see, this will always be the case. The key is that you need to specify the constraints on your variables before taking the derivative. The constraints don't just come out of nowhere.

• What if both p and v are varying? P and V can vary simultaneously, isn't it? – Srijan Ghosh Apr 11 at 17:42
• In that case p, v both would be considered as constant in partial derivative of PV – Srijan Ghosh Apr 11 at 17:59
• P is inversely proportional to V. If we increase V ,P will decrease and vice versa.If gas is in closed system V is constant.If it is in open system P may be is constant – user227513 Apr 11 at 18:03
• @Broly That is assuming constant temperature. In general you could have temperature, volume, and pressure all increasing (if you do the necessary work/heat addition to cause this to happen) – Aaron Stevens Apr 11 at 20:33
• @SrijanGhosh I explain that in my answer.... That is an incorrect application of the product rule, and would evaluate to $2nR$. When you take a derivative you need to specify the constraints at the beginning. The product rule should follow these constraints, not determine them. – Aaron Stevens Apr 12 at 10:48

For an ideal gas PV=nRT

if we differentiate it partially w.r.t $$T$$ we get

$$P\left(\frac{\partial V}{\partial T}\right)+V\left(\frac{\partial P}{\partial T}\right)=nR$$

At constant pressure $$\frac{\partial P}{\partial T}=0$$

So, $$P\left(\frac{\partial V}{\partial T}\right)_p$$=nR

I saw this relation be used to derive the formula $$C_p -C_v =nR$$

By first law of thermodynamics

$$dq=dE+PdV$$

Or, $$dq/dT=\frac {dE+PdV}{dT}$$

Or$$C=\frac {dE+PdV}{dT}$$.......(1)

at constant volume dV=0

So, $$C_v=(\frac{dE}{dT})_v$$........(2)

Enthalpy $$H=E+PV$$

$$(\frac {dH}{dt})_p=(\frac{dE}{dT})_p +P(\frac{dV}{dT})_p$$.........(3)

By (1)&(3)

$$C_p=(\frac{dH}{dT})_p$$........(4)

We know that $$H=E+PV=E+nRT$$

Or, $$\frac{dH}{dT}=\frac{dE}{dT} +R$$

By (2) &(4)

$$C_P-C_v=R$$

Thanks to all for responding to my question. I got it. I can understand my fault. I applied product rule for partial derivative incorrectly. The derivation should be as follows-$$PV=nRT$$, so to find $$P\left(\frac{\partial V}{\partial T}\right)_p$$ we have to express V as a function of T and P at first. So, I should write $$V=V(P,T)=\frac{nRT}{P}$$ from which we get $$\left(\frac{\partial V}{\partial T}\right)_p=\frac{nR}{P}$$ Which implies the relation $$P\left(\frac{\partial V}{\partial T}\right)_p=nR$$ as said in those books.