One Variable Changes at a Time
A partial derivative measures how a function changes when one input coordinate changes and the other input coordinates are held fixed. The phrase “held fixed” is the key: a variable may appear in the formula and still be treated as a constant during a particular partial differentiation.
Many errors come from losing track of this instruction. A calculation may accidentally differentiate with respect to two variables, leave behind terms that should have vanished, or change which variables are being held fixed halfway through. The resulting algebra can look plausible while answering a different question.
This definition gives a practical test for a calculation: when finding \(f_x\), imagine that \(y\) has been assigned one fixed value. The calculation should then act like an ordinary one-variable derivative in \(x\). A term that does not change as \(x\) changes contributes zero to \(f_x\), even if that term contains \(y\).
Why the Other Variable Is Treated as a Constant
Fix a number \(b\), and define a one-variable function \(g(x)=f(x,b)\). By the definition above, the partial derivative \(f_x(a,b)\) is precisely the ordinary derivative \(g'(a)\), if that derivative exists. In the difference quotient, the second coordinate is \(b\) in both evaluations; it does not change with \(h\).
This explains why differentiating with respect to \(x\) means treating \(y\) as constant: after fixing \(y=b\), there is only one changing input. It also explains an important limitation. If \(y\) is made to vary with \(x\), the resulting rate describes change along that chosen path, not the partial derivative defined by holding \(y\) fixed.
Terms Independent of the Chosen Variable
When a sum is differentiated, each term is considered with respect to the chosen variable. Any term that stays constant as that variable changes contributes zero. “Independent” here means independent of the differentiation variable, not necessarily a numerical constant with respect to every variable.
Worked Example: Removing Terms Independent of \(x\)
Let \(f(x,y)=3x^2y+5y^2-4x+7\). Find \(f_x\) and \(f_y\), and evaluate both at \((1,2)\).
For \(f_x\), hold \(y\) fixed. The term \(3x^2y\) has the fixed factor \(y\), and the terms \(5y^2\) and \(7\) do not change with \(x\). Therefore, $$ f_x(x,y)=6xy+0-4+0=6xy-4. $$ At \((1,2)\), $$ f_x(1,2)=6(1)(2)-4=12-4=8. $$
For \(f_y\), hold \(x\) fixed. The term \(-4x\) and the constant \(7\) contribute zero, while \(3x^2y\) contributes \(3x^2\): $$ f_y(x,y)=3x^2+10y+0+0=3x^2+10y. $$ Thus, $$ f_y(1,2)=3(1)^2+10(2)=3+20=23. $$
Check the fixed-variable interpretation directly: with \(y=2\), \(f(x,2)=6x^2+27-4x\), whose derivative in \(x\) is \(12x-4\), giving \(8\) at \(x=1\). With \(x=1\), \(f(1,y)=3y+5y^2+3\), whose derivative in \(y\) is \(3+10y\), giving \(23\) at \(y=2\). Both checks agree.
A Reliable Calculation Routine
Before differentiating, identify the variable named by the subscript or instruction. Then mark every other input as fixed for that calculation. This simple pause helps prevent a common error: carrying out a familiar derivative operation without checking which quantities are changing.
For \(f_x\), only \(x\) changes. For \(f_y\), only \(y\) changes.
Regard each other input as a fixed number throughout this derivative.
Ask whether the term changes when the chosen variable changes. If it does not, its partial derivative is zero.
Keeping the formula general until the derivative is found makes it easier to see which variables were held fixed.
Worked Examples with More Than Two Variables
Worked Example: Differentiating with Respect to \(y\)
Let \(g(x,y,z)=\sin x+y^3z+\ln z+8\). Find \(g_y\), then evaluate it at \((0,2,3)\).
Only \(y\) changes; \(x\) and \(z\) stay fixed. The terms \(\sin x\), \(\ln z\), and \(8\) therefore contribute zero. The \(y\)-dependent term gives $$ g_y(x,y,z)=0+3y^2z+0+0=3y^2z. $$ At the specified point, $$ g_y(0,2,3)=3(2)^2(3)=3\cdot4\cdot3=36. $$
As a check, fixing \(x=0\) and \(z=3\) reduces the function to \(g(0,y,3)=y^3(3)+\ln 3+8\). Its derivative in \(y\) is \(9y^2\), which equals \(9(2)^2=36\) at \(y=2\).
Worked Example: Keeping the Same Variables Fixed
Let \(q(x,y)=x^2y+y^2\). Find \(q_x\) and evaluate it at \((1,2)\). In this calculation, \(y\) must remain fixed even though it appears in both terms.
Differentiate with respect to \(x\). The factor \(y\) in \(x^2y\) is constant, and \(y^2\) is independent of \(x\): $$ q_x(x,y)=2xy+0=2xy. $$ Then substitute the point: $$ q_x(1,2)=2(1)(2)=4. $$
Check by freezing \(y=2\) first: \(q(x,2)=2x^2+4\), so its derivative is \(4x\). At \(x=1\), this is \(4\), as required.
A Common Error: Letting a Fixed Variable Change
Suppose a calculation asks for \(f_x\) at a point. Substituting a relation such as \(y=x\) before differentiating changes the problem: \(y\) now varies with \(x\). The derivative of the resulting one-variable expression measures change along the curve \(y=x\), not change in the \(x\)-coordinate while \(y\) stays fixed.
Worked Example: Partial Derivative Versus Change Along a Path
Let \(f(x,y)=x^2y\). Find \(f_x(1,2)\), and compare it with the derivative obtained by restricting to the path \(y=x\) at \(x=1\).
For the partial derivative, hold \(y\) fixed: $$ f_x(x,y)=2xy, \qquad f_x(1,2)=2(1)(2)=4. $$
For the path \(y=x\), substitute into the function first: \(f(x,x)=x^2x=x^3\). The derivative of this one-variable function is \(3x^2\), so its value at \(x=1\) is \(3(1)^2=3\). This is not \(f_x(1,2)\): the path value is taken at \((1,1)\), and the \(y\)-coordinate changes along the path.
To compare changes along the path at the point \((1,2)\), use a path that passes through it, for example \(y=x+1\). Then \(f(x,x+1)=x^2(x+1)=x^3+x^2\), whose derivative at \(x=1\) is \(3(1)^2+2(1)=5\). The value \(5\) describes the rate along that path; the partial derivative \(4\) describes changing \(x\) while \(y=2\) stays fixed. These are different questions, so their answers need not agree.
Concrete Pitfall: Differentiating a Fixed Variable
A frequent incorrect step is to treat a fixed variable as if it were changing. For instance, in the preceding function, a wrong calculation might turn \(x^2y\) into \(2xy+x^2\) when finding \(f_x\). The extra \(x^2\) comes from differentiating \(y\) as though it changed with \(x\). That is not part of a partial derivative with respect to \(x\).
There is a related error in the opposite direction: leaving a term in the answer simply because it looks important. For example, \(y^2\) is not zero as a function, but its partial derivative with respect to \(x\) is zero. The right question is not whether a term has a nonzero value, but whether it changes as the chosen variable changes while the others remain fixed.
Why the Distinction Matters
Partial derivatives are coordinatewise rates. Their meaning depends on which coordinate is allowed to change, so the variable held fixed is part of the question—not a minor bookkeeping detail. An answer obtained after changing the held-fixed variables may be a valid rate for some other setup, but it cannot be used as the requested partial derivative without justification.
When unsure, return to the difference quotient: in \(f_x(a,b)\), compare \(f(a+h,b)\) with \(f(a,b)\). The \(y\)-input is exactly \(b\) in both terms. This check makes it clear why terms independent of \(x\) disappear and why allowing \(y\) to vary answers a different question.
Check Your Understanding
For each question, identify which variables are fixed before computing.
- If \(r(x,y)=x^3+xy+y^2\), which terms contribute zero to \(r_x\)?
- For \(s(x,y,z)=x\ln y+z^2\), find \(s_y\). Which variables are fixed?
- For \(p(x,y)=xy^2\), find \(p_x(2,3)\), then check by fixing \(y=3\) first.
- Why does substituting \(y=x\) before differentiating generally fail to compute \(f_x\)?
- In the difference quotient for \(f_y(a,b)\), which coordinate changes and which remains fixed?