A partial derivative measures how a function of several variables changes when only one variable changes and the others are held fixed. For \( f(x, y) \):
$$\frac{\partial f}{\partial x} = \lim_{h\to0}\frac{f(x + h, y) - f(x, y)}{h}$$
How to compute it: treat every other variable as a constant, then use the ordinary rules (power, product, chain).
That one idea is the whole technique. The rest of this guide shows you what a partial derivative means on a surface, how to handle quotients, three variables and second derivatives, and the mistakes that cost students the most points.
Notation
\( \frac{\partial f}{\partial x} \), \( f_x \), and \( \partial_x f \) all mean the same thing. The curly \( \partial \) signals “partial.”
To say “evaluated at the point \( (a, b) \),” write \( f_x(a, b) \) or put a vertical bar after the fraction. For second derivatives, the subscript notation lists variables in the order you differentiate: \( f_{xy} \) means “first \( x \), then \( y \).” The fraction notation reads right to left, so \( \frac{\partial^2 f}{\partial y\,\partial x} \) is the same thing. Both conventions are common, so take a moment to check which one your course uses.
Why it works: slicing the surface
Picture the graph of \( z = f(x, y) \) as a landscape. If you stand at a point and walk due east (the positive \( x \)-direction), your \( y \)-coordinate never changes. The path you trace is the curve where the surface meets the vertical plane \( y = b \). Along that curve, \( f \) is an ordinary function of one variable, and its slope is \( f_x(a, b) \).
Walk due north instead and you slice the surface with the plane \( x = a \). The slope of that curve is \( f_y(a, b) \). So a function of two variables has two basic slopes at each point, one for each axis direction.
This is exactly why “treat the other variable as a constant” works. On the slice \( y = b \), \( y \) really is a constant, so every one-variable rule applies without change. The limit definition says the same thing: only \( x \) moves, by \( h \), while \( y \) stays put.
A physical example makes it concrete. If \( T(x, y) \) is the temperature on a metal plate, then \( T_x \) is how fast the temperature changes, in degrees per centimeter, as you move in the \( x \)-direction only. A value of \( T_x = -3 \) means that moving a small step to the right cools you by about 3 degrees per centimeter.
Using the definition once
You rarely need the limit definition in practice, but working it once shows that the shortcut is correct. Take \( f(x, y) = x^2y \):
$$\begin{aligned} f_x &= \lim_{h\to0}\frac{(x + h)^2y - x^2y}{h} \\ &= \lim_{h\to0}\frac{(2xh + h^2)\,y}{h} \\ &= \lim_{h\to0}(2x + h)\,y = 2xy \end{aligned}$$
Expanding the square, the \( x^2y \) terms cancel, you divide out \( h \), and the limit leaves \( 2xy \). That is exactly what you get by treating \( y \) as a constant and applying the power rule to \( x^2 \).
Example 1: a polynomial
\( f(x, y) = x^2y + y^3 \)
- \( f_x = 2xy \) (\( y \) is a constant, so \( x^2y \to 2x\cdot y \) and \( y^3 \to 0 \))
- \( f_y = x^2 + 3y^2 \) (\( x \) is a constant)
Example 2: with the chain rule
\( f(x, y) = \sin(xy) \)
- \( f_x = y\cos(xy) \)
- \( f_y = x\cos(xy) \)
The inner function is \( xy \). Its partial derivative with respect to \( x \) is \( y \), and that factor must appear in front, just as the chain rule demands in one variable.
Example 3: product of both
\( f(x, y) = e^{2x}\sin y \)
- \( f_x = 2e^{2x}\sin y \)
- \( f_y = e^{2x}\cos y \)
You don’t need the product rule here. For \( f_x \), the factor \( \sin y \) is a constant multiplier; for \( f_y \), \( e^{2x} \) is. You only need the product rule when both factors contain the variable you’re differentiating with respect to.
Example 4: a quotient
\( f(x, y) = \dfrac{x}{x + y} \)
For \( f_x \), both the numerator and the denominator contain \( x \), so use the quotient rule:
$$f_x = \frac{(x + y)\cdot1 - x\cdot1}{(x + y)^2} = \frac{y}{(x + y)^2}$$
For \( f_y \), the numerator is a constant, so it’s easier to write \( f = x(x + y)^{-1} \) and use the chain rule:
$$f_y = -\frac{x}{(x + y)^2}$$
Choosing the lighter rule for each variable saves time and reduces algebra errors.
Example 5: three variables
\( f(x, y, z) = xy^2z^3 + e^{xz} \)
Now there are three partial derivatives. For each one, freeze the other two variables:
- \( f_x = y^2z^3 + ze^{xz} \)
- \( f_y = 2xyz^3 \) (the exponential has no \( y \), so it contributes 0)
- \( f_z = 3xy^2z^2 + xe^{xz} \)
Nothing new is needed for more variables. You simply have more constants to keep track of.
Evaluating at a point
For \( f(x, y) = x^2y + \sin(xy) \) at \( (1, 2) \):
$$f_x = 2xy + y\cos(xy) = 4 + 2\cos 2 \approx 3.1677$$
This is the slope of the surface in the \( x \)-direction at that point: the slope of the curve you’d get by slicing the surface with the plane \( y = 2 \).
The other slope at the same point is
$$f_y = x^2 + x\cos(xy) = 1 + \cos 2 \approx 0.5839$$
So the surface climbs more than five times faster heading east than heading north from \( (1, 2) \). Always differentiate first and substitute second; plugging in numbers too early erases the variable you need.
Second partial derivatives
Differentiate again. There are four for \( f(x, y) \):
$$f_{xx},\quad f_{yy},\quad f_{xy} = \frac{\partial}{\partial y}f_x,\quad f_{yx} = \frac{\partial}{\partial x}f_y$$
For \( f = x^2y + y^3 \): \( f_{xx} = 2y \), \( f_{yy} = 6y \), \( f_{xy} = f_{yx} = 2x \).
Clairaut’s theorem: if the mixed partials are continuous, \( f_{xy} = f_{yx} \). The order doesn’t matter, a great self-check.
The pure second partials describe concavity along each slice. The mixed partial \( f_{xy} \) tells you how the \( x \)-slope changes as you step in the \( y \)-direction, which measures the twist of the surface.
Example 6: all four second partials
\( f(x, y) = x^3y^2 + ye^x \)
First partials:
$$f_x = 3x^2y^2 + ye^x, \qquad f_y = 2x^3y + e^x$$
Second partials:
$$\begin{aligned} f_{xx} &= 6xy^2 + ye^x \\ f_{yy} &= 2x^3 \\ f_{xy} &= 6x^2y + e^x \\ f_{yx} &= 6x^2y + e^x \end{aligned}$$
The two mixed partials match, as Clairaut’s theorem predicts. If yours don’t, recheck your first partials before anything else.
Example 7: marginal product in economics
A factory’s output is \( Q = 10K^{1/2}L^{1/2} \), where \( K \) is capital and \( L \) is labor. The partial derivative with respect to labor is the marginal product of labor:
$$Q_L = 5K^{1/2}L^{-1/2}$$
At \( K = 16 \) and \( L = 25 \), \( Q_L = \frac{5\cdot4}{5} = 4 \). One more unit of labor, with capital unchanged, adds about 4 units of output. By the same method, \( Q_K = 5L^{1/2}K^{-1/2} = 6.25 \), so at this mix an extra unit of capital is worth more than an extra unit of labor.
Common mistakes
- Differentiating the “constant” variable. In \( f_x \) of \( x^2y + y^3 \), the term \( y^3 \) becomes 0, not \( 3y^2 \). Anything without an \( x \) is a constant.
- Dropping the chain-rule factor. \( \frac{\partial}{\partial x}\sin(xy) \) is \( y\cos(xy) \), not \( \cos(xy) \). The inner derivative is a partial derivative too.
- Using the product rule when you don’t need it. In \( x^2y \), \( y \) is a constant coefficient when you find \( f_x \). The product rule still gives the right answer, but it adds work and chances for error.
- Substituting the point too early. Find \( f_x \) as a formula, then plug in \( (a, b) \). If you substitute \( x = 1 \) first, the \( x \)-dependence is gone and the derivative looks like 0.
- Mixing up the order in mixed partials. \( f_{xy} \) means differentiate by \( x \) first. It usually doesn’t change the answer, but for functions whose mixed partials aren’t continuous it can.
Where partial derivatives are used
- The gradient and directional derivatives combine them into a vector.
- Finding maxima and minima of surfaces: solve \( f_x = f_y = 0 \), then use the second derivative test with \( D = f_{xx}f_{yy} - f_{xy}^2 \). For example, \( f = x^2 + xy + y^2 - 3x \) has \( f_x = 2x + y - 3 \) and \( f_y = x + 2y \). Both are zero at \( (2, -1) \), where \( D = 2\cdot2 - 1^2 = 3 > 0 \) and \( f_{xx} > 0 \), so \( f(2, -1) = -3 \) is a minimum. This is the two-variable version of finding critical points.
- Physics (heat and wave equations) and economics (marginal cost with several inputs).
- Integration in several variables: double integrals reverse the process, integrating in one variable while holding the other fixed.
- The tangent plane \( z = f(a,b) + f_x(a,b)(x - a) + f_y(a,b)(y - b) \) is the two-variable linear approximation.
Partial derivative calculator
Enter \( f(x, y) \) and a point. The gadget returns all first and second partials symbolically:
Partial Derivatives
First and second partials of \(f(x, y)\), evaluated at a point.
The full partial derivative calculator page has more examples, and for one-variable work the derivative calculator shows each rule step by step.
Practice problems
Try these before checking the answers.
- \( f = x^3y^2:\ f_x,\ f_y \)
- \( f = e^{xy}:\ f_x \)
- \( f = \ln(x^2 + y^2):\ f_x \)
- \( f = x^2\sin y:\ f_{xy} \)
- \( f = \sqrt{x^2 + y^2}:\ f_x \)
- \( f = x^2y^3:\ f_x(1, 2) \)
- \( f = xyz:\ f_z \)
Answers: (1) \( 3x^2y^2,\ 2x^3y \); (2) \( ye^{xy} \); (3) \( \frac{2x}{x^2 + y^2} \); (4) \( 2x\cos y \); (5) \( \frac{x}{\sqrt{x^2 + y^2}} \); (6) \( 16 \); (7) \( xy \).
For problem 4, \( f_x = 2x\sin y \), and differentiating that with respect to \( y \) gives \( 2x\cos y \). For problem 6, \( f_x = 2xy^3 \), which is \( 2\cdot1\cdot8 = 16 \) at \( (1, 2) \).
FAQ
What’s the difference between d and ∂?
\( d \) is used when the function has one variable; \( \partial \) when it has several and you differentiate with respect to one of them.
What is a mixed partial derivative?
A second derivative taken with respect to two different variables, like \( f_{xy} \).
What does a partial derivative mean geometrically?
It is the slope of the surface \( z = f(x, y) \) in one axis direction. \( f_x(a, b) \) is the slope of the curve cut out by the plane \( y = b \), and \( f_y(a, b) \) is the slope along the plane \( x = a \).
Is f_xy always equal to f_yx?
For almost every function you meet in a course, yes. Clairaut’s theorem guarantees it whenever both mixed partials are continuous near the point. There are specially built counterexamples where they differ, but they need a formula with a break in its second derivatives.
If both partial derivatives exist, is the function differentiable?
Not necessarily. The function equal to \( \frac{xy}{x^2 + y^2} \) away from the origin and 0 at the origin has \( f_x = f_y = 0 \) at \( (0, 0) \), yet it isn’t even continuous there. Partials only look along two directions. If the partials are continuous near the point, though, the function is differentiable.
How do I find partial derivatives with three or more variables?
The same way: pick one variable, hold all the others constant, and differentiate. A function of \( n \) variables has \( n \) first partial derivatives.
Further reading
- Partial Derivatives (Paul’s Online Math Notes) — many more worked examples, including implicit differentiation with partials.
- Higher Order Partial Derivatives (Paul’s Online Math Notes) — second and third partials and more on Clairaut’s theorem.
- Partial Derivatives (OpenStax Calculus Volume 3) — a full textbook section with the limit definition, exercises and an introduction to partial differential equations.
Calculators for this topic
Keep learning
Double Integrals: How to Evaluate Them Step by Step
Evaluate double integrals as iterated integrals, switch the order of integration, and use polar coordinates. Step-by-step worked examples.
Gradient and Directional Derivative: Formulas and Examples
The gradient ∇f collects partial derivatives; the directional derivative D_u f = ∇f · u gives the slope in any direction. Worked example and geometric meaning.

