Why are the virial coefficients functions of temperature only? I have read in multiple places that the virial coefficients in the virial equation of state, $Z=1+{B \over v}+{C \over v^2}...$, are functions of temperature only and are independent of pressure (or equivalently, molar volume).  Is this purely an empirical observation or is there some deeper statistical mechanics reason why the virial coefficients should not depend on how close the particles are together (i.e. the molar volume)?  
I understand that $B$ represents pair-wise interactions, $C$ represent three-particle interactions, etc. but again shouldn't the coefficient, say $B$, depend on how close the two particles are to each other?
 A: I will only give a general idea of why this should be so. The concrete derivation for non-ideal gas is a little tricky and not very illuminating in my opinion. So, let us write the grand canonical partition function
$$\Omega \equiv \sum_n Z_n {\lambda}^n$$
where $\lambda = e^{\mu \over k_B T}$ and $Z_n$ is $n$-particle canonical partition function.
Now, the virial expansion is nothing else than cluster expansion of $\Omega$. This is just a combinatorial theorem, so that you can write $$\log(\Omega) = \sum_n B_n {\lambda}^n$$ with $B_n = V^{n-1} f_n(Z_1, \cdots, Z_n)$ and $f_n$ determined by the cluster expansion theorem.
Because none of the $Z_n$ depends on the pressure, $B_n$ can't either. Actually, the pressure enters these formulas only through the thermodynamic identity $\log(\Omega) = {pV \over k_B T}$.
A: You asked two different questions:


*

*Why it doesn't depend on the the pressure? Because pressure is not an independent variable. You can calculate it as the derivative of the thermodynamical potential, although, to be honest, in this case at least, the thermodynamical potential is already $-Pv$ because you do this expansion using a grand-canonical ensemble.

*Why it doesn't depend on how close the particles are? Well, it does not depend because you average over it. When you do thermodynamics, you don't care about specific micro-states, just the ensemble average. If you see the definition of the virial coefficients, you will realize that those are integrals over the positions with a probability density that comes from a perturbative expansion of the Gibbs distribution. This is the average I'm referring to.
A: I think, this is only a math trick. Take the equation of state $f(P,T,\rho)=0$ and rewrite it as $P=P(T,\rho)$. Multiply it by $V$: $$PV=g(T,\rho)$$ Now expand it into Taylor series:  
$$PV=g(T,0)+\frac{\partial g(T,0)}{\partial\rho}\rho+ \frac{1}{2}\frac{\partial^2 g(T,0)}{\partial\rho^2}\rho^2+...$$ Here $\rho$ is density. Because $\rho\sim\frac{1}{v}$ we get an expansion like in the question.
