# Computing derivatives "at constant" quantities in thermodynamics

What does it mean in thermodynamics when a derivative is computed "at constant $$X$$"? If I see

$$\left.\frac{\partial S(E, N)}{\partial E}\middle| \right._N$$

how is the derivation performed any differently? Other than forcing any derivatives of $$N$$ that happen to be present in the function $$S$$ to zero?

• Why do you think it means something more than this? Sep 24, 2020 at 19:34
• @G.Smith Because my solution doesn't match the published solution, lol Sep 24, 2020 at 19:59

From a "physical" point of view, this means that we are only interested in the variation of $$S$$ as $$E$$ changes, even though probably changing $$E$$ might also (if $$N$$ depends on $$E$$ in some way) somewhat affect $$N$$ and therefore change $$S$$ not directly by the change of $$E$$ but rather through $$N$$. The partial derivative you wrote ignores this "implicit", "hidden" effect. What follows is a more detailed explanation.
The partial derivative you wrote, $${\partial S \over \partial E}|_N$$, means you can treat $$N$$ as a constant. So for example if $$S=\alpha N^2E$$ its partial derivative with respect to to $$E$$ with $$N$$ constant is simply $$\alpha N^2$$ because $$N^2$$ can be treated as a constant (I just used a random expression, there is no entropy I can think of with that expression..!).
This is usually not an issue when doing computations, you just regard $$N$$ as a constant and that's it, but it does avoid confusion when both $$N$$ and $$E$$ are functions of another parameter, say $$w$$ so that $$E=E(w)$$ and $$N=N(w)$$. In this case, you cannot claim to be just "slightly" changing $$E$$ keeping $$N$$ constant because they are intertwined by $$w$$. In this case, if what interested you is the total rate of change of $$S$$ then you would have to compute the total derivative of $$S$$ i.e. (by the chain rule): $${dS(E(w), N(w)) \over dw}={\partial S \over \partial E}|_N{dE\over dw}+{\partial S \over \partial N}|_E{dN\over dw}$$ You see that this expression takes into account not only the variation of $$S$$ with respect to $$N$$ but also the contribution due to the variation of $$E$$.
Also, in general, it could be that $$N$$ is a function of $$E$$, so that for example: $$S=\alpha N(E)^2E$$ In this case, when computing the partial derivative at constant $$N$$ we ignore this dependency and we are only concerned in the variation of $$S$$ as the part of it that explicitly contains $$E$$ varies, so that again we get $${\partial S \over \partial E}|_N=\alpha N(E)^2$$ because we treat $$N$$ as constant even though it contains an implicit dependency on $$C$$. Differently the total derivative would be (by the chain rule / by the formula above with $$E$$ instead of $$w$$):
$$dS/dE=\alpha N(E)^2+ 2\alpha N(E){dN\over dE} E$$