Calculus 3 • Multivariable Functions & Partial Derivatives

Higher-Order & Mixed Partials — Higher-Order Partials and Clairaut's Theorem (Mixed Partials)

Discover when the order of differentiation doesn't matter—and why that symmetry is so powerful.

Three-dimensional axes with spatial movement and a multivariable function.
Inside this lesson 10 sections 5 questions 8 figures

SECTION 1

Historical Context & Motivation

The study of functions of several variables naturally leads to the question of how successive rates of change interact with one another. When you differentiate a function first with respect to one variable and then with respect to another, does the order in which you perform those operations matter? This deceptively simple question occupied some of the greatest mathematical minds of the eighteenth and nineteenth centuries, and its resolution—Clairaut's theorem—remains one of the most elegant and practically useful results in multivariable calculus.

The need for higher-order partial derivatives arose in diverse contexts: from modeling how heat flows through a solid bar to understanding the curvature of surfaces in three-dimensional space. Leonhard Euler and Alexis Clairaut, working in the mid-1700s, independently discovered that for 'well-behaved' functions the mixed second-order partials are equal regardless of differentiation order. However, making this intuition rigorous required the careful analytic machinery that would only mature a century later with the work of Karl Weierstrass and Hermann Schwarz.

1740s • Euler & Clairaut's Observations

Both Leonhard Euler and Alexis-Claude Clairaut observed that for functions arising in physics and geometry, the mixed partial derivatives fxy and fyx coincide. Clairaut published his result in the context of mechanics and differential equations.

1807 • Fourier's Heat Equation

Joseph Fourier's work on the heat equation ∂u/∂t = k ∂²u/∂x² relied heavily on second-order partial derivatives and mixed partials, demonstrating their centrality to mathematical physics and motivating rigorous study of their properties.

1867 • Schwarz's Rigorous Proof

Hermann Amandus Schwarz provided the first fully rigorous proof of the symmetry of mixed partials under the continuity hypothesis, closing the gap left by earlier informal arguments. His theorem is sometimes called the Schwarz–Clairaut theorem.

1880s • Young's Generalization

William Henry Young extended the result to broader classes of functions, weakening the continuity assumptions needed. His version—sometimes called Young's theorem—clarified the minimal conditions under which mixed partials commute.

The central question that motivated all of this development can be stated concisely: given a function f(x, y), when does differentiating first with respect to x and then y yield the same result as differentiating first with respect to y and then x? Clairaut's theorem provides the definitive answer—and understanding it is essential before you move on to topics like Taylor series in several variables, optimization via the second-derivative test, or partial differential equations.

SECTION 2

Core Principles & Definitions

Before we can state Clairaut's theorem precisely, we need to establish the foundational vocabulary. You are already familiar with first-order partial derivatives—the rates of change of a multivariable function with respect to a single variable while holding all others constant. Higher-order partial derivatives are obtained by differentiating partial derivatives themselves, producing second-order, third-order, and beyond. Among these, the mixed partial derivatives are of special interest because they involve differentiation with respect to more than one variable in succession.

1

Higher-Order Partial Derivative

A partial derivative of a partial derivative. For f(x, y), the second-order partial ∂²f/∂x² means differentiating f with respect to x twice. These measure how the rate of change itself is changing—analogous to acceleration in single-variable calculus.
2

Mixed Partial Derivative

A higher-order partial in which differentiation is performed with respect to at least two different variables. The notation ∂²f/∂y∂x means: first differentiate with respect to x, then differentiate that result with respect to y. The order of variables in the denominator reads right to left.
3

Continuity of Mixed Partials

Clairaut's theorem requires that the second-order mixed partials be continuous at the point in question. This is not an exotic condition—nearly every function you encounter in applications satisfies it, but pathological counterexamples do exist.
4

Clairaut's Theorem (Equality of Mixed Partials)

If fxy and fyx are both continuous on an open region, then fxy = fyx throughout that region. The order of differentiation is interchangeable.
✦

KEY TAKEAWAY

Think of partial differentiation as walking along a grid on a hilly landscape. Suppose you walk one block east (differentiate with respect to x) and then one block north (differentiate with respect to y). Clairaut's theorem guarantees that—provided the terrain is smooth enough—the net change you perceive is the same as if you had walked one block north first and then one block east. The path through the grid doesn't affect the final measurement of curvature, as long as the surface has no sudden 'tears' or discontinuities in its slopes.

SECTION 3

Visual Explanation — Differentiation Tree

The following diagram shows the tree of all second-order partial derivatives for a function f(x, y). Starting from f at the top, the first level of branching produces the two first-order partials, and the second level produces the four second-order partials. Clairaut's theorem tells us that the two mixed partials in the center are equal whenever they are continuous, effectively reducing four independent quantities to three.

Second-Order Partial Derivative Tree for f(x, y)f(x, y)∂/∂x∂/∂yf_x = ∂f/∂xf_y = ∂f/∂y∂/∂x∂/∂y∂/∂x∂/∂yf_xx = ∂²f/∂x²f_xy = ∂²f/∂y∂xf_yx = ∂²f/∂x∂yf_yy = ∂²f/∂y²f_xy = f_yx(Clairaut's Theorem, when continuous)"Pure" second partial"Pure" second partial4 second-order partials → 3 independent quantities
The differentiation tree branches from f into two first-order partials, then into four second-order partials. The pink-highlighted mixed partials fxy and fyx are connected by Clairaut's theorem (green box), collapsing four second-order partials to three independent quantities.

Notice that the two 'pure' second-order partials—fxx and fyy—measure concavity along each coordinate axis independently, while the mixed partials capture the cross-interaction between the two variables. This cross-interaction is what appears, for example, in the discriminant D = fxxfyy − (fxy)² of the multivariable second-derivative test for local extrema. Clairaut's theorem is what guarantees we don't need to worry about which mixed partial appears in that formula.

SECTION 4

Mathematical Framework

Notation for Higher-Order Partials

For a function f(x, y), we have two standard notation systems. In Leibniz notation, the second-order partial obtained by differentiating first with respect to x and then with respect to y is written ∂²f/∂y∂x. In subscript notation, the same derivative is written fxy. A crucial point: in Leibniz notation the differentiation order reads right to left (first x, then y), whereas in subscript notation it reads left to right (first x, then y). Both notations denote the same operation.

SECOND-ORDER PURE PARTIALS

fxx=∂2f/∂x2=∂/∂x(∂f/∂x)fyy=∂2f/∂y2=∂/∂y(∂f/∂y)f_xx = ∂²f/∂x² = ∂/∂x(∂f/∂x) f_yy = ∂²f/∂y² = ∂/∂y(∂f/∂y)

These measure concavity along the x- and y-directions respectively—analogous to the second derivative f″(x) in single-variable calculus.

SECOND-ORDER MIXED PARTIALS

fxy=∂2f/∂y∂x=∂/∂y(∂f/∂x)fyx=∂2f/∂x∂y=∂/∂x(∂f/∂y)f_xy = ∂²f/∂y∂x = ∂/∂y(∂f/∂x) f_yx = ∂²f/∂x∂y = ∂/∂x(∂f/∂y)

These measure how the slope in one direction changes as you move in the perpendicular direction. The notation ∂²f/∂y∂x means: differentiate f with respect to x first (rightmost variable), then differentiate the result with respect to y.

CLAIRAUT'S THEOREM (SYMMETRY OF MIXED PARTIALS)

IffxyandfyxarecontinuousonanopensetD,thenfxy(a,b)=fyx(a,b)forall(a,b)∈D.If f_xy and f_yx are continuous on an open set D, then f_xy(a, b) = f_yx(a, b) for all (a, b) ∈ D.

The hypothesis of continuity is essential. Without it, one can construct pathological functions (see Section 7) where the mixed partials differ. In practice, polynomials, exponentials, trigonometric functions, and their compositions all satisfy this condition everywhere they are defined.

Extension to Higher Orders and More Variables

Clairaut's theorem generalizes inductively. For a function f(x, y, z) with all relevant mixed partials continuous, any permutation of the differentiation variables yields the same result. For instance, fxyz = fxzy = fyxz = fyzx = fzxy = fzyx. The number of truly independent n-th order partials of a function of k variables is the multiset coefficient C(n + k − 1, n), rather than kn, a substantial simplification.

SECTION 5

Detailed Breakdown — Computing Second-Order Partials

To solidify the mechanics, let us walk through the computation of all four second-order partial derivatives of a concrete function and verify Clairaut's theorem. The diagram below illustrates the process on a surface, showing how the slope along one axis changes as we shift along the other.

Geometric Meaning of Mixed Partials on f(x,y) = x²y + 3xy³Step 1: First-Order Partials∂f/∂x = 2xy + 3y³→ treat y as constant, differentiate w.r.t. x∂f/∂y = x² + 9xy²→ treat x as constant, differentiate w.r.t. yStep 2: Pure Second-Order Partialsf_xx = ∂/∂x(2xy + 3y³) = 2y→ concavity in the x-directionf_yy = ∂/∂y(x² + 9xy²) = 18xy→ concavity in the y-directionStep 3a: Mixed Partial f_xyf_xy = ∂/∂y(2xy + 3y³) = 2x + 9y²→ differentiate f_x with respect to yResult: 2x + 9y²Step 3b: Mixed Partial f_yxf_yx = ∂/∂x(x² + 9xy²) = 2x + 9y²→ differentiate f_y with respect to xResult: 2x + 9y²✓ f_xy = f_yx = 2x + 9y² — Clairaut's Theorem Verified
A step-by-step computation of all four second-order partial derivatives of f(x, y) = x²y + 3xy³. The two mixed partials (pink boxes) yield the same expression 2x + 9y², confirming Clairaut's theorem.
DerivativeMeaningFor f = x²y + 3xy³
fxSlope of f in the x-direction2xy + 3y³
fySlope of f in the y-directionx² + 9xy²
fxxConcavity in x-direction (acceleration of slope)2y
fyyConcavity in y-direction18xy
fxy = fyxCross-curvature: how x-slope changes with y (or vice versa)2x + 9y²

Summary of all second-order partials for f(x, y) = x²y + 3xy³

⚠

Notation Warning

In Leibniz notation, ∂²f/∂y∂x, the order of differentiation reads right to left: differentiate with respect to x first, then y. In subscript notation fxy, the order reads left to right: differentiate with respect to x first, then y. Both notations denote the same derivative, but misreading the order is a common source of confusion.

SECTION 6

Worked Example

Let us work through a more involved example that features transcendental functions, demonstrating that Clairaut's theorem applies far beyond polynomials.

Find all second-order partial derivatives of f(x, y) = eˣ sin(y) + x²y³ and verify Clairaut's theorem.

  1. 1

    Step 1 — Compute fxf_x

    Differentiate f(x, y) = eˣ sin(y) + x²y³ with respect to x, treating y as a constant. The derivative of eˣ sin(y) with respect to x is eˣ sin(y) since sin(y) is a constant factor. The derivative of x²y³ with respect to x is 2xy³.
    fx = eˣ sin(y) + 2xy³
  2. 2

    Step 2 — Compute fyf_y

    Differentiate f with respect to y, treating x as a constant. The derivative of eˣ sin(y) with respect to y is eˣ cos(y). The derivative of x²y³ with respect to y is 3x²y².
    fy = eˣ cos(y) + 3x²y²
  3. 3

    Step 3 — Compute f_xx (pure second partial)

    Differentiate fx = eˣ sin(y) + 2xy³ with respect to x again. We get eˣ sin(y) + 2y³.
    fxx = eˣ sin(y) + 2y³
  4. 4

    Step 4 — Compute f_yy (pure second partial)

    Differentiate fy = eˣ cos(y) + 3x²y² with respect to y again. The derivative of eˣ cos(y) with respect to y is −eˣ sin(y), and the derivative of 3x²y² with respect to y is 6x²y.
    fyy = −eˣ sin(y) + 6x²y
  5. 5

    Step 5 — Compute f_xy (mixed partial: first x, then y)

    Differentiate fx = eˣ sin(y) + 2xy³ with respect to y. The derivative of eˣ sin(y) with respect to y is eˣ cos(y), and the derivative of 2xy³ with respect to y is 6xy².
    fxy = eˣ cos(y) + 6xy²
  6. 6

    Step 6 — Compute f_yx (mixed partial: first y, then x)

    Differentiate fy = eˣ cos(y) + 3x²y² with respect to x. The derivative of eˣ cos(y) with respect to x is eˣ cos(y), and the derivative of 3x²y² with respect to x is 6xy².
    fyx = eˣ cos(y) + 6xy²
  7. 7

    Step 7 — Verify Clairaut's Theorem

    Both mixed partials equal eˣ cos(y) + 6xy². Since eˣ cos(y) and 6xy² are continuous everywhere on ℝ², Clairaut's theorem is satisfied and the equality fxy = fyx holds on all of ℝ².
    ✓ fxy = fyx = eˣ cos(y) + 6xy² everywhere

SECTION 7

When Does Clairaut's Theorem Fail?

Clairaut's theorem is remarkably robust—so much so that students sometimes assume mixed partials are always equal. However, the continuity hypothesis is not vacuous. Understanding the boundary cases deepens your grasp of the theorem and helps you appreciate why mathematicians insisted on rigor.

ScenarioMixed Partials Equal?Reason
Polynomials in x, yAlways ✓All partial derivatives of polynomials are polynomials, hence continuous everywhere.
Smooth functions (C∞)Always ✓All derivatives of all orders exist and are continuous.
Piecewise-defined with discontinuous mixed partials at originMay fail ✗Classic counterexample: f(x,y) = xy(x²−y²)/(x²+y²) at (0,0). Here f_xy(0,0) = 1 but f_yx(0,0) = −1.
Functions with isolated discontinuities in mixed partialsFails at the point ✗Clairaut's theorem requires continuity on an open set containing the point. Failure at a single point is sufficient for inequality.
Rational, exponential, trig functions on their domainsAlways ✓These are analytic on their domains, so all derivatives are continuous wherever the function is defined.

When Clairaut's theorem applies and when it may fail

⚠

The Classic Counterexample

Consider f(x, y) = xy(x² − y²)/(x² + y²) for (x, y) ≠ (0, 0) and f(0, 0) = 0. One can show by careful limit computations that fxy(0, 0) = 1 while fyx(0, 0) = −1. The mixed partials exist at the origin but are not continuous there, so Clairaut's hypothesis is violated and the conclusion fails.
✦

PRACTICAL GUIDELINE

In engineering and applied science, functions built from standard elementary building blocks (polynomials, exponentials, logarithms, trigonometric and hyperbolic functions, and their compositions) satisfy the hypotheses of Clairaut's theorem everywhere on their natural domains. You can confidently swap differentiation order in these cases without checking continuity explicitly. Reserve caution for piecewise-defined functions or functions with singularities—analogous to how you would check a bridge's load rating only if it looks structurally unusual.

SECTION 8

Connections to Advanced Topics

Clairaut's theorem is not an isolated result—it serves as a linchpin connecting several branches of multivariable calculus and beyond. Understanding where higher-order and mixed partials appear downstream will help you appreciate why this theorem is worth internalizing thoroughly.

This Lesson's ConceptAdvanced TopicHow They Connect
fxy = fyxSecond Derivative TestThe discriminant D = f_xx f_yy − (f_xy)² classifies critical points. Clairaut's theorem ensures the (f_xy)² term is unambiguous.
Higher-order mixed partialsTaylor Series in Several VariablesThe multivariable Taylor expansion involves terms like ∂ⁿf/∂xⁱ∂yʲ. Clairaut's theorem reduces the number of distinct coefficients.
Equality of mixed partialsExact Differential EquationsAn equation M dx + N dy = 0 is exact iff ∂M/∂y = ∂N/∂x, which is precisely the condition f_xy = f_yx for a potential function f.
Second-order partials f_xx, f_yyLaplacian & PDEsThe Laplacian ∇²f = f_xx + f_yy appears in the heat equation, wave equation, and Poisson's equation—foundations of mathematical physics.
Symmetry of the Hessian matrixOptimization & Linear AlgebraThe Hessian H = [[f_xx, f_xy],[f_yx, f_yy]] is symmetric by Clairaut's theorem, guaranteeing real eigenvalues—critical for constrained optimization and convexity analysis.

How higher-order and mixed partials feed into advanced mathematics

As you advance into topics like differential geometry, the symmetry of mixed partials generalizes into the statement that the Hessian matrix is symmetric. This seemingly modest property has profound consequences: it guarantees that the eigenvalues of the Hessian are real, which in turn makes the second-derivative test well-defined. In optimization theory, the entire classification of quadratic forms—and hence the theory of local minima, maxima, and saddle points—rests upon this symmetry.

SECTION 9

Practice Problems

Question 1: CONCEPTUAL

State Clairaut's theorem precisely. In particular, what hypothesis must be satisfied for the conclusion to hold? If someone computes fxy and fyx for a polynomial and finds them equal, explain why this outcome was guaranteed without any computation.
Show answer
Clairaut's theorem states that if the second-order mixed partial derivatives f_xy and f_yx are both continuous on an open region D, then f_xy = f_yx throughout D. For a polynomial, every partial derivative of any order is itself a polynomial, and polynomials are continuous everywhere on ℝ². Therefore the continuity hypothesis is automatically satisfied, and the equality of mixed partials is guaranteed a priori. No computation of the mixed partials is needed to predict the outcome—only to find their common value.

Question 2: BASIC CALCULATION

Let f(x, y) = x³y² − 4xy⁵. Compute fxx, fyy, fxy, and fyx, and verify that fxy = fyx.
Show answer
First, fxf_x = 3x²y² − 4y⁵ and fyf_y = 2x³y − 20xy⁴. Then f_xx = ∂/∂x(3x²y² − 4y⁵) = 6xy², and f_yy = ∂/∂y(2x³y − 20xy⁴) = 2x³ − 80xy³. For the mixed partials: f_xy = ∂/∂y(3x²y² − 4y⁵) = 6x²y − 20y⁴, and f_yx = ∂/∂x(2x³y − 20xy⁴) = 6x²y − 20y⁴. Since both mixed partials equal 6x²y − 20y⁴, Clairaut's theorem is confirmed. This was expected because f is a polynomial, so all its derivatives are continuous everywhere.

Question 3: INTERMEDIATE

Let g(x, y) = ln(x² + y²). Find gxy and simplify. Then determine the domain on which Clairaut's theorem guarantees gxy = gyx.
Show answer
First, gxg_x = 2x/(x² + y²). Then g_xy = ∂/∂y[2x/(x² + y²)] = 2x · (−2y)/(x² + y²)² = −4xy/(x² + y²)². You can verify g_yx yields the same expression by computing gyg_y = 2y/(x² + y²) and then differentiating with respect to x. The function g(x,y) = ln(x² + y²) is defined and smooth on ℝ² \ {(0,0)}, the entire plane except the origin. All partial derivatives are rational functions of x and y with denominator (x2+y2)n(x² + y²)^n, which is positive whenever (x,y) ≠ (0,0). Therefore Clairaut's theorem guarantees equality of mixed partials on the open set ℝ² \ {(0,0)}.

Question 4: APPLIED

The temperature distribution on a thin plate is given by T(x, y) = 50e−x50e^{−x} cos(y), where x and y are in meters and T is in degrees Celsius. Compute all four second-order partial derivatives. Then verify that T satisfies Laplace's equation ∇²T = T_xx + T_yy = 0, which characterizes steady-state heat flow.
Show answer
We have TxT_x = −50e−x50e^{−x} cos(y) and TyT_y = −50e−x50e^{−x} sin(y). The second-order partials are: T_xx = 50e−x50e^{−x} cos(y), T_yy = −50e−x50e^{−x} cos(y), T_xy = 50e−x50e^{−x} sin(y), and T_yx = 50e−x50e^{−x} sin(y). First, T_xy = T_yx as expected by Clairaut's theorem since T is composed of smooth elementary functions. Second, ∇²T = T_xx + T_yy = 50e−x50e^{−x} cos(y) + (−50e−x50e^{−x} cos(y)) = 0. Therefore T satisfies Laplace's equation, confirming it describes a steady-state (equilibrium) temperature distribution with no internal heat sources.

Question 5: CRITICAL THINKING

Consider the function f(x, y) = xy(x² − y²)/(x² + y²) for (x, y) ≠ (0, 0) and f(0, 0) = 0. Using the limit definition of a partial derivative, show that fxy(0, 0) ≠ fyx(0, 0). Explain which hypothesis of Clairaut's theorem fails.
Show answer
First compute fxf_x(0, y) using the limit definition: fxf_x(0, y) = lim⁡h→0\lim_{h→0} [f(h,y)−f(0,y)]/h = lim⁡h→0\lim_{h→0} [hy(h²−y²)/(h²+y²)]/h = lim⁡h→0\lim_{h→0} y(h²−y²)/(h²+y²) = y(−y²)/y² = −y for y ≠ 0, and fxf_x(0,0) = 0. So fxf_x(0,y) = −y. Then f_xy(0,0) = lim⁡k→0\lim_{k→0} [fxf_x(0,k)−fxf_x(0,0)]/k = lim⁡k→0\lim_{k→0} (−k)/k = −1. By a symmetric argument, fyf_y(x,0) = x, and f_yx(0,0) = lim⁡h→0\lim_{h→0} [fyf_y(h,0)−fyf_y(0,0)]/h = lim⁡h→0\lim_{h→0} h/h = 1. Thus f_xy(0,0) = −1 ≠ 1 = f_yx(0,0). The hypothesis that fails is the continuity of the mixed partial derivatives at the origin. One can show that f_xy(x,y) oscillates as (x,y) → (0,0) along different paths and does not have a single limit, hence it is discontinuous at the origin.

SUMMARY

Summary

Summary

Higher-order partial derivatives are obtained by differentiating partial derivatives repeatedly. For a function f(x, y), the four second-order partials are the two pure partials fxx and fyy, which measure concavity along each axis, and the two mixed partials fxy and fyx, which capture cross-variable interactions.

Clairaut's theorem guarantees that if the mixed partials are continuous on an open region, then fxy = fyx throughout that region—the order of differentiation does not matter. This result reduces the number of independent second-order partials from four to three, simplifies the Hessian matrix to a symmetric matrix, and underpins the second derivative test, Taylor expansions in several variables, and the theory of exact differential equations. For standard elementary functions—polynomials, exponentials, trigonometric functions, and their compositions—the continuity hypothesis is always met, so you can freely interchange the order of partial differentiation.

Varsity Tutors • Calculus 3 • Higher-Order & Mixed Partials — Higher-Order Partials and Clairaut's Theorem (Mixed Partials)