Temperature in statistical mechanics and differentiating entropy

In statistical mechanics, the entropy of an isolated system with energy $E$ (with fixed volume $V$ and chemical composition $N$) is defined as $S(E) = k \log \Omega$, where $\Omega$ is the number of microstates with total energy $E$. The temperature $T$ is then defined (in basically all the sources I've been able to find) via the relation $$\left( \frac{\partial S}{ \partial E} \right)_{N, V} = \frac{1}{T}$$

Since entropy is a discrete quantity (being essentially just a counting function), how does one make sense of the derivative? Is it more correct to replace the derivative by a difference quotient?

Yes, there is a subtlety there. Also notice that in quantum mechanics we have finely resolved energy eigenstates, and in a typical complicated system all degeneracies are broken so that at any given energy there is at most one state ($\Omega = 1$) but most likely there is no state at exactly that energy ($\Omega = 0$). So it would seem that $\log \Omega$ is never bigger than 0, how can entropy ever be so high as we observe?

In classical mechanics too, if you ask me how many states have energy exactly $E$ I will say zero since a randomly chosen state will almost never exactly match energy $E$.

So there is a quite a mistake with saying "$\Omega$ is the number of states with energy $E$" since essentially this would give $\Omega = 0$. (I have no idea why textbooks say this, it just confuses the learner and they know it is wrong). There are two ways to solve this and to get a real, functioning definition of $S$:

1. Consider all states between $E$ and $E+\Delta E$, indeed with a finite difference $\Delta E$ --- not too big but not too small. From this you can define a thermodynamic density of states $\nu = \Delta \Omega / \Delta E$. Then, entropy is defined as $S = k \log \nu$ or alternatively as $S = k \log (\Delta \Omega)$, depending on who you ask. Both work. (Perhaps you noticed, there is a problem that either entropy depends on units of energy when we take log of something with units of 1/energy, or, the entropy depends on how big of $\Delta E$ we chose. But this just gives an entropy offset and as long as we are consistent with units, and keep $\Delta E$ the same for all systems, this works out.)

2. Consider all states with energy less than $E$ and define this number as $\Omega$. (Sounds strange, I know, but it does work and is quite simply defined.)

The definitions disagree but both are valid; both reproduce thermodynamics in large systems. Interestingly though neither is mathematically satisfactory, and they have real problems for small systems. In particular the "temperature" as defined by $1/(\partial S/\partial E)$ actually fails to have the property that two systems with equal temperature are in equilibrium. And we can even define evil systems with strange density of states where, as $E$ is increased, the value of $T$ fluctuates up and down and up and down.

Can we do any better? Yes, abandon the requirement that a system has exactly specified energy $E$. That was anyways unrealistic since you never perfectly know a system's energy with absolute certainty. If instead you fix the temperature, you get a canonical ensemble for which entropy is uniquely defined (and is mathematically sane).

See wikipedia's microcanonical ensemble for more info (disclaimer: I wrote that article, mostly).

• Thanks. So would it be correct to say that there is no one universally agreed on definition of temperature for an isolated system? Is there an unambiguous notion of "the temperature" of, say, a system of $N$ spins in a magnetic field? – Casey Feb 25 '15 at 15:09
• If the $N$ spins are truly isolated and have a known, fixed energy, then unfortunately no, there's not an unambiguous definition of temperature. In fact it can be argued that, strictly speaking, the system cannot be regarded as in thermal equilibrium with any other system of given temperature, and so temperature is not a well defined concept when energy is fixed. But, provided $N$ is large enough then there are many definitions of temperature that agree with each other. If large enough the system can be said to be "in equilibrium with itself", i.e., acting as its own heat bath. – Nanite Feb 26 '15 at 8:50
• Of course in a realistic case there would be some tiny interaction with environment that means energy is not exactly fixed, becoming randomized. If you maintain this connection the energy will fluctuate, but if its average is keeping steady then the system is demonstrably in thermal equilibrium with its environment. Then temperature can become well defined. This is true all the way down to considering a single spin. You can say a spin has temperature $T$ if it is in equilibrium with an environment of that temperature. This concept of temperature is precisely that in the canonical ensemble. – Nanite Feb 26 '15 at 8:54
• Returning to the isolated $N$ spins in magnetic field, this is a quite curious case since you can have "negative temperature" by inverting the spin population, i.e. giving the spins a higher energy than if fully randomized. This is a special case where my definitions 1 and 2 show a serious disagreement, even for large $N$. By definition 1, temperature may be negative if density of states decreases with energy. By definition 2, temperature is always positive but it can be a nonmonotonic function of energy. This is not just a thought experiment; inverted spin populations have been really made. – Nanite Feb 26 '15 at 9:00
• Well I could go on but instead have some links en.wikipedia.org/wiki/Negative_temperature sites.google.com/site/entropysurfaceorvolume – Nanite Feb 26 '15 at 9:07

The number of microstates is usually so large that we may approximate using a derivative. After all, look at $10^{23}$ molecules in a jar. It is quite easy to think that you are looking at a continuum.