practicecalculus
Multivariable Calculus

Partial Derivatives: Notation, Meaning and Worked Examples

Learn how to compute partial derivatives, what they mean as slopes of traces, how to find second partials and why Clairaut's theorem makes mixed partials equal.

By the PracticeCalculus team Published 7 min read

On this page
  1. What is a partial derivative?
  2. Partial derivative notation
  3. How to find partial derivatives
  4. What a partial derivative means: slopes of traces
  5. Second partial derivatives
  6. Clairaut's theorem: why mixed partials match
  7. Common mistakes with partial derivatives
  8. Quick reference: partial derivatives
  9. Make it automatic with practice

A function like f(x, y) = x^2 y + y^3 depends on two inputs at once, so "the derivative" is no longer a single number. If you nudge x, the output changes one way. If you nudge y, it changes another. Partial derivatives measure each of those rates separately, and the good news is that you already know every rule you need.

This guide covers what partial derivatives mean, the notation, how to compute them (including with the chain rule), how to read them as slopes on a surface, and second partials with Clairaut's theorem.

What is a partial derivative?

The partial derivative of f with respect to x is the rate of change of f when x changes and every other variable is held constant. For a function of two variables it is defined by a limit, just like an ordinary derivative:

f_x(x, y) = \frac{\partial f}{\partial x} = \lim_{h \to 0} \frac{f(x + h, y) - f(x, y)}{h}
f_y(x, y) = \frac{\partial f}{\partial y} = \lim_{h \to 0} \frac{f(x, y + h) - f(x, y)}{h}

Only one variable moves in each limit. That is the whole idea: freeze the others and take a normal derivative.

Partial derivative notation

You will see several equivalent notations for the same thing:

Meaning Subscript Leibniz Operator
rate in the x direction f_x \frac{\partial f}{\partial x} \partial_x f
rate in the y direction f_y \frac{\partial f}{\partial y} \partial_y f
value at a point f_x(a, b) \left.\frac{\partial f}{\partial x}\right\rvert_{(a,b)}

If z = f(x, y), you may also see \frac{\partial z}{\partial x} or z_x.

How to find partial derivatives

The rule of thumb: every variable except the one you are differentiating with respect to is a constant. So y^3, 5y and \sin y all behave like numbers when you take \frac{\partial}{\partial x}.

Worked example 1: a polynomial

Find f_x and f_y for f(x, y) = 3x^2 y + y^3 - 4x.

Step 1. Differentiate with respect to x, holding y constant.

  • 3x^2 y: the constant 3y rides along, and x^2 becomes 2x, giving 6xy.
  • y^3: no x at all, so it is a constant and its derivative is 0.
  • -4x: derivative -4.
f_x = 6xy - 4

Step 2. Differentiate with respect to y, holding x constant.

  • 3x^2 y: the constant 3x^2 rides along, and y becomes 1, giving 3x^2.
  • y^3: derivative 3y^2.
  • -4x: no y, so 0.
f_y = 3x^2 + 3y^2

Worked example 2: using the chain rule

Find f_x and f_y for f(x, y) = \sin(x^2 y).

The outside function is \sin u and the inside is u = x^2 y, so the chain rule applies just as in single-variable calculus.

Step 1. With respect to x. The inside derivative is \frac{\partial}{\partial x}(x^2 y) = 2xy.

f_x = \cos(x^2 y) \cdot 2xy = 2xy\cos(x^2 y)

Step 2. With respect to y. The inside derivative is \frac{\partial}{\partial y}(x^2 y) = x^2.

f_y = x^2\cos(x^2 y)

Worked example 3: a logarithm and three variables

Find \frac{\partial f}{\partial x} for f(x, y) = \ln(x^2 + y^2), then find g_z for g(x, y, z) = x y^2 z^3.

Step 1. For the logarithm, differentiate \ln u to get \frac{1}{u} and multiply by \frac{\partial u}{\partial x} = 2x:

\frac{\partial f}{\partial x} = \frac{2x}{x^2 + y^2}

Step 2. With three variables nothing changes: hold x and y fixed and differentiate z^3.

g_z = 3x y^2 z^2

What a partial derivative means: slopes of traces

The graph of z = f(x, y) is a surface. Slice it with the vertical plane y = b and you get a curve, called a trace, that depends only on x: z = f(x, b). The partial derivative f_x(a, b) is the slope of that curve at x = a.

Take the dome f(x, y) = 6 - x^2 - 2y^2 at the point (1, 1), where f(1, 1) = 3.

Step 1. Slice with y = 1. The trace is z = 6 - x^2 - 2 = 4 - x^2.

Step 2. Differentiate. f_x = -2x, so f_x(1, 1) = -2. The trace is falling with slope -2 as x increases.

Step 3. Tangent line in the slice. z = 3 - 2(x - 1) = 5 - 2x.

The trace z = 4 − x² of the surface z = 6 − x² − 2y² in the plane y = 1, with slope −2 at x = 1
Slicing z = 6 - x^2 - 2y^2 at y = 1 gives z = 4 - x^2. Its tangent at x = 1 has slope f_x(1, 1) = -2. The vertical axis here is z.

Slicing the other way, with x = 1, gives the trace z = 5 - 2y^2. Its slope at y = 1 is f_y(1, 1) = -4y\big|_{y=1} = -4. So at this point the dome falls twice as steeply in the y direction as in the x direction.

In applied terms, f_x answers "how fast does the output change per unit of x, if nothing else changes?" If P(L, K) is a factory's output from labor L and capital K, then P_L is the extra output from one more unit of labor with capital held fixed.

Second partial derivatives

Each first partial is again a function of x and y, so you can take partials of it. A function of two variables has four second partials:

f_{xx} = \frac{\partial^2 f}{\partial x^2}, \quad f_{yy} = \frac{\partial^2 f}{\partial y^2}, \quad f_{xy} = \frac{\partial^2 f}{\partial y\,\partial x}, \quad f_{yx} = \frac{\partial^2 f}{\partial x\,\partial y}

The last two are the mixed partials. Read subscripts left to right: f_{xy} means "first x, then y." The Leibniz form lists the variables right to left, so \frac{\partial^2 f}{\partial y\,\partial x} also means "first x, then y."

f_{xx} measures the concavity of the x trace, and f_{yy} the concavity of the y trace. In the dome above, f_{xx} = -2 and f_{yy} = -4, both negative, so the surface bends downward in both directions.

Worked example 4: all four second partials

Find all second partials of f(x, y) = x^3 y^2 + 2xy^4.

Step 1. First partials.

f_x = 3x^2 y^2 + 2y^4, \qquad f_y = 2x^3 y + 8xy^3

Step 2. Differentiate f_x.

f_{xx} = 6xy^2, \qquad f_{xy} = \frac{\partial}{\partial y}\left(3x^2 y^2 + 2y^4\right) = 6x^2 y + 8y^3

Step 3. Differentiate f_y.

f_{yx} = \frac{\partial}{\partial x}\left(2x^3 y + 8xy^3\right) = 6x^2 y + 8y^3, \qquad f_{yy} = 2x^3 + 24xy^2

Step 4. Compare the mixed partials. f_{xy} = f_{yx} = 6x^2 y + 8y^3. They match.

Clairaut's theorem: why mixed partials match

That match in example 4 was not luck.

Clairaut's theorem: if f_{xy} and f_{yx} are both continuous on an open disk around (a, b), then f_{xy}(a, b) = f_{yx}(a, b).

Polynomials, exponentials, sines, cosines and their combinations have continuous partials wherever they are defined, so in practice the order of differentiation does not matter. That gives you two practical benefits:

  1. A free check. Compute both mixed partials. If they disagree, you made an arithmetic error.
  2. A shortcut. Pick whichever order is easier. For f(x, y) = y e^{x^2} + x, finding f_{yx} is faster: f_y = e^{x^2}, so f_{yx} = 2x e^{x^2}. By Clairaut, f_{xy} is the same.

Common mistakes with partial derivatives

  1. Differentiating the "constant" variable. In \frac{\partial}{\partial x}(x^2 y^3), the y^3 stays as y^3. The answer is 2xy^3, not 6xy^2.
  2. Keeping terms that should vanish. Any term with no x in it, like y^3 or \sin y, has \frac{\partial}{\partial x} = 0.
  3. Using the product rule when it is not needed. x^2 y^3 is a constant times x^2 when differentiating in x, so no product rule is required.
  4. Forgetting the chain rule factor. \frac{\partial}{\partial y} e^{xy} = x e^{xy}, not e^{xy}.
  5. Mixing up the order in f_{xy} versus \frac{\partial^2 f}{\partial x\,\partial y}. Under Clairaut it rarely changes the answer, but it does change the work you show.

Quick reference: partial derivatives

Function f_x f_y
x^m y^n m x^{m-1} y^n n x^m y^{n-1}
e^{xy} y e^{xy} x e^{xy}
\sin(xy) y\cos(xy) x\cos(xy)
\ln(x^2 + y^2) \frac{2x}{x^2+y^2} \frac{2y}{x^2+y^2}
\frac{x}{y} \frac{1}{y} -\frac{x}{y^2}
g(x) + h(y) g'(x) h'(y)

Make it automatic with practice

Partial derivatives are the foundation for everything else in multivariable calculus: the gradient and directional derivatives, tangent planes, optimization and Lagrange multipliers. The interactive lesson below gives you functions to differentiate one variable at a time, with instant feedback that tells you which variable you accidentally differentiated.

Practice it now

Partial derivatives

Solve real problems on this topic with instant feedback, hints and a step-by-step walkthrough for every answer. Free, no sign-up needed to start.

Practice this lesson

Frequently asked questions

What is a partial derivative in simple terms?

A partial derivative measures how a function of several variables changes when you change just one variable and hold all the others fixed. For f(x, y), f_x is the rate of change in the x direction and f_y is the rate of change in the y direction.

How do you take a partial derivative?

Pick the variable you are differentiating with respect to and pretend every other variable is a number. Then use the ordinary derivative rules: power, product, quotient and chain. For example, \frac{\partial}{\partial x}(x^2 y^3) = 2x y^3 because y^3 acts like a constant.

What does the ∂ symbol mean?

The curly \partial (read "partial" or "del") signals a partial derivative, so \frac{\partial f}{\partial x} means "the derivative of f with respect to x with the other variables held constant." It distinguishes partial derivatives from ordinary ones written with a straight d.

Are mixed partial derivatives always equal?

For almost every function you will meet in a calculus course, yes. Clairaut's theorem guarantees f_{xy} = f_{yx} whenever both mixed partials are continuous near the point. There are contrived functions where they differ, but they always involve a discontinuous mixed partial.

What is the difference between f_xy and f_yx?

The subscripts are read left to right: f_{xy} means differentiate with respect to x first, then y. In fraction notation the order flips, so f_{xy} = \frac{\partial^2 f}{\partial y\, \partial x}. Under Clairaut's theorem the two orders give the same answer anyway.

Written by the PracticeCalculus team

We build interactive calculus lessons and write every page to be clear and correct. Spotted something off? Tell us and we will fix it.