# Ideal gas derivations

For an ideal gas, how can someone obtain this:

$$\bar{V}dP = RdT- P \bar{dV}$$

from which it can de deducted, that for a constant temperature

$$\frac{dP}{\bar{dV}} = -RT$$

This looks like the differential of the ideal gas equation. I'm going to use $V_m$ for the molar volume.

$$PV_m=RT$$

Now we convert each side to the differential. We keep $P$ and $V_m$ together since they are both variable. We can move $R$ out of the differential because it is a constant.

$$d\left(PV_m\right)=RdT$$

We can evaluate $d\left(PV_m\right)$ using the product rule:

$$d\left(PV_m\right) = PdV_m + V_mdP$$

Now:

$$PdV_m + V_mdP = RdT$$

Which is equivalent to your first equation.

**However, at constant temperature $dT=0$, so at constant temperature, the equation simplifies to:

$$PdV_m + V_mdP=0$$ $$V_mdP = - PdV_m$$ $$\frac{dP}{dV_m}=-\frac{P}{V_m}$$

Which is not equal to your second equation. The closest I can get is the following: $$\frac{dP}{dV_m}=-\frac{P}{V_m}\cdot\frac{V_m}{V_m}=-\frac{PV_m}{V^2_m}=-\frac{RT}{V^2_m}$$

Which is what we would get by evaulating:

$$\left(\frac{\partial}{\partial V_m}\right)_T \left(P=\frac{RT}{V_m}\right)$$