Clairaut’s theorem states that if a function has continuous second-order partial derivatives, then the order of partial differentiation doesn’t matter:

In other words, you can take partial derivatives in either order and get the same result.

This is also known as Schwarz’s theorem or the equality of mixed partials.

Why it matters

The theorem looks like a technicality, but it’s the test for exact differential equations (Exact equation). For an ODE in the form , a potential function exists (with , ) if and only if

This is just Clairaut applied to the candidate : if then , and if then . By Clairaut, these must agree.

So Clairaut gives us the exactness test for free.

When it fails

The continuity hypothesis matters. There exist (pathological) functions where the second mixed partials exist but aren’t equal. The classic counterexample:

Computing but . The second partials exist but disagree.

The reason is that the second partials aren’t continuous at the origin. Once you require continuity (which Clairaut demands), the equality holds.

For all “nice” functions encountered in physics and engineering — anything built from polynomials, exponentials, trig functions, smooth combinations — the second partials are continuous and Clairaut applies.

Proof sketch

The proof is a standard mean-value-theorem argument. Define

This double-difference can be evaluated two ways:

  1. As , which equals by another application of the fundamental theorem.
  2. Symmetrically via , giving .

Both equal . Dividing by and taking limits as , the integrals approach and respectively. Continuity of the second partials makes these limits well-defined. So they’re equal.

Practical use

Beyond Exact equation tests, Clairaut shows up in:

  • Conservative vector fields: a vector field is conservative (has a potential) iff .
  • Path independence in line integrals: line integrals of depend only on endpoints (not path) when the field is conservative — equivalent to on simply connected regions.
  • Thermodynamics Maxwell relations: the equality (and similar) come from Clairaut applied to thermodynamic potentials.
  • Hessian symmetry: the matrix of second partials of a smooth function is symmetric.

In all these contexts, the underlying fact is the same: smooth functions have symmetric mixed partials.