Partial derivatives are an important mathematical tool in a number of physics disciplines, most notably field theories (e.g. electricity & magnetism and general relativity) and in thermodynamics.

However, working with partial derivatives are always a bit tricky and teaching students about them is usually fraught with difficulties.  So it was to my pleasant surprise that I found a really nice discussion of how to derive the various ‘classic’ rules cleanly presented in Classical and Statistical Thermodynamics by Ashley H. Carter. 

My presentation here is strongly influenced and closely follows her presentation in Appendix A, although I’ve added on a bit in the theoretical flow and I’ve also provided explicit examples in terms of the standard paraboloid found in freshman calculus. 

Assume a function of 3 variables can be expressed as $$f(x,y,z) = 0$$.  This equation can be viewed as a constrain equation linking the values of the variables such that two variables are independent.  That means that we can (at least locally) solve for:

  • $$x(y,z) = 0$$
  • $$y(x,z) = 0$$
  • $$z(x,y) = 0$$

Focus on the first and second forms (other pairings will follow a simple relabeling of the variables).  The corresponding differentials are

\[ dx = \left( \frac{\partial x}{\partial y} \right)_z dy + \left( \frac{\partial x}{\partial z} \right)_y dz \; \]

and

\[ dy = \left( \frac{\partial y}{\partial x} \right)_z dx + \left( \frac{\partial y}{\partial z} \right)_x dz \; .\]

Now substitute the expansion of $$dy$$ into the expansion of $$dx$$

\[ dx = \left(\frac{\partial x}{\partial y}\right)_z \left[ \left(\frac{\partial y}{\partial x}\right)_z dx + \left(\frac{\partial y}{\partial z}\right)_x dz \right] + \left(\frac{\partial x}{\partial z}\right)_y dz \; ,\]

which simplifies to

\[ dx = \left(\frac{\partial x}{\partial y}\right)_z \left(\frac{\partial y}{\partial x}\right)_z dx + \left[ \left(\frac{\partial x}{\partial y}\right)_z \left(\frac{\partial y}{\partial z}\right)_x + \left(\frac{\partial x}{\partial z}\right)_y \right] dz \; .\]

Putting it all together gives

\[ \left[ 1 – \left(\frac{\partial x}{\partial y}\right)_z \left(\frac{\partial y}{\partial x}\right)_z \right] dx – \left[ \left(\frac{\partial x}{\partial y}\right)_z \left(\frac{\partial y}{\partial z}\right)_x + \left(\frac{\partial x}{\partial z}\right)_y \right] dz = 0 \; .\]

Since $$dx$$ and $$dz$$ are independent, each differential can be set to zero independently, giving one of the classic identities.

First set $$dz = 0$$ to get

\[ \left(\frac{\partial x}{\partial y}\right)_z = 1/ \left(\frac{\partial y}{\partial x}\right)_z \; , \]

which is called the reciprocal rule.

Next, setting $$dx = 0$$ yields

\[ \left(\frac{\partial x}{\partial y}\right)_z \left(\frac{\partial y}{\partial z}\right)_x = \; – \; \left(\frac{\partial x}{\partial z}\right)_y \; , \]

which is called the fraction rule.

The manipulations are complete when using the reciprocal rule in the fraction rule and simplify to get

\[ \left(\frac{\partial x}{\partial y}\right)_z \left(\frac{\partial y}{\partial z}\right)_x \left(\frac{\partial z}{\partial x}\right)_y = -1 \; , \]

which is called the cyclic rule.

Let’s take a look at these relationships in action. Consider the implicit definition of the paraboloid

\[ x^2 + y^2 – z = 0 \; . \]

As mentioned earlier, this equation can be considered as a constraint equation that selects out a value for any one of the three variables given the other two. In other words, we can imagine a look up table where we select a value of $$x$$ and $$y$$, we rummage through the table to find a row with both values and then we scan to the right to find the allowed value of $$z$$ that makes it satisfy the implicit equation.

How do you construct this table; not at a finite set of points but functionally so that it works at any point? It is natural and easy to determine $$z$$ given $$x$$ and $$y$$ by simply rewriting the implicit equation as

\[ z(x,y) = x^2 + y^2 \; .\]

However, it isn’t as easy to express $$x$$ or $$y$$ as functions of the remaining two variables because of the two possible signs that result from taking the square root. We need to have four functional relationships

\[ x_p(y,z) = \sqrt{ z \; – \; y^2 } \; ,\]

\[ x_n(y,z) = \; – \; \sqrt{z \; – \; y^2} \; , \]

\[ y_p(x,z) = \sqrt{z \; – \; x^2} \; , \]

and

\[ y_n(x,z) = \; – \; \sqrt{z \; – \; x^2} \; , \]

depending on the particular combination of whether $$x$$ is positive or negative and whether $$y$$ is also positive or negative.  In the language of differential geometry, we have a 5 charts in our atlas.

We are now in position to try the various relations derived above. For example, let’s examine the reciprocal relation in the first quadrant of the $$x$$-$$y$$ plane.  We need to use $$x_p$$ as our local chart.

\[ \left(\frac{\partial x_p}{\partial z}\right)_y = \frac{1}{2} \frac{1}{\sqrt{z – y^2}} \; \]

or once we recognize the denominator as $$x_p$$ 

\[\left(\frac{\partial x_p}{\partial z}\right)_y = \frac{1}{2 x_p} \; . \]

The ‘reciprocal’ partial derivative is

\[ \left( \frac{\partial z}{\partial x} \right)_y = 2 x = 2 x_p \; ,\]

where there is no need for the $$z$$-chart to distinguish between positive and negative values of $$x$$.  As expected the derivatives are reciprocals of each other.

Next, let’s test the fraction rule.  For fun, this time let’s test it in the 2nd quadrant in the $$x$$-$$y$$ plane ($$x < 0$$ and $$y > 0$$).  Calculating the partial derivatives on the left-hand side yields

\[ \left(\frac{\partial x_n }{\partial y_p } \right)_z = \frac{y_p}{\sqrt{z – y_p^2}} = \; – \; \frac{y_p}{x_n} \; \]

and

\[ \left(\frac{\partial y_p }{\partial z} \right)_{x_n} = \frac{1}{2\sqrt{z-x_n^2}} = \frac{1}{2 y_p} \; . \]

It is a simple matter to verify that

\[ \left(\frac{\partial x_n }{\partial y_p} \right)_z \left(\frac{\partial y_p }{\partial z} \right)_{x_n} = -\frac{1}{2 x_n} \; \]

is identical to 

\[ – \left(\frac{\partial x_n }{\partial z} \right)_{y_p} = \frac{1}{2 \sqrt{z – y_p^2} } = -\frac{1}{2 x_n} \; .\]

Finally, for the cyclic rule, let’s go into the 4th quadrant in the $$x$$-$$y$$ plane ($$x>0$$ and $$y<0$$).  Taking each partial derivative in turns yields

\[ \left(\frac{\partial x_p }{\partial y_n} \right)_{z} = -\frac{y_n}{\sqrt{z-y_n^2}} = -\frac{y_n}{x_p} \; ,\]

\[ \left(\frac{\partial y_n }{\partial z} \right)_{x_p} = -\frac{1}{2 \sqrt{z-x_p^2} } = \frac{1}{2 y_n} \; ,\]

and 

\[ \left(\frac{\partial z }{\partial x_p} \right)_{y_n} = 2 x_p \; .\]

Multiplying these terms in order gives

\[ -\frac{y_n}{x_p} \frac{1}{2 y_n} 2 x_p = -1 \; .\]

Nice, neat, and more than partially done.