When z = f(x, y) and both x and y depend on t, the rate dz/dt adds one term for each way t reaches z: dz/dt = f_x dx/dt + f_y dy/dt. The rule comes straight from linear approximation, dividing the total differential by dt. With two parameters, as when x and y depend on s and t, each partial derivative of z gets the same kind of sum, and a tree diagram keeps track of the routes. The same rule gives implicit differentiation in one line: dy/dx = −F_x / F_y for a curve F(x, y) = 0.
What you'll learn
Differentiate a function of several variables along a path
Use a tree diagram for functions of two parameters
Differentiate an implicit curve with −F_x/F_y
Solve related-rates problems with several changing quantities
A hiker walks along a trail, and the temperature at each point of the map is
T(x,y). As time passes, both coordinates change, so the temperature the
hiker feels changes through two routes at once. The chain rule adds them:
dtdz=∂x∂fdtdx+∂y∂fdtdy
Each term is a rate of f in one direction times how fast the path moves in
that direction.
Divide by the small change Δt that caused them and let it shrink:
ΔtΔx→dtdx and ΔtΔy→dtdy,
and the approximation becomes exact. Near any point the function is almost
linear, and for a linear function the effects of the two inputs add, which is
why the chain rule is a sum.
dtdw=y(2t)+x(3)=3t⋅2t+3t2=9t2, which is 36 at t=2. Substituting first, w=3t3, agrees.
For z=x2+y2 with x=et and y=e−t, find dtdz at t=0.
Answer
0
Full solution
dtdz=2xet+2y(−e−t)=2e2t−2e−2t, which is 0 at t=0.
For z=xy with x=st and y=s+t, find ∂s∂z at (s,t)=(1,2).
Answer
8
Full solution
∂s∂z=y⋅t+x⋅1. At (1,2): x=2 and y=3, so 3⋅2+2=8.
Find dxdy on the curve x2+xy+y2=7 at (1,2).
Answer
−54
Full solution
Fx=2x+y=4 and Fy=x+2y=5, so dxdy=−54.
Use −FyFx to find the slope of the circle x2+y2=25.
Answer
−yx
Full solution
Fx=2x and Fy=2y. At (3,4) the slope is −43, perpendicular to the radius, whose slope is 34.
A rectangle is 20 cm long, growing at 2 cm/s, and 10 cm wide, shrinking at 1 cm/s. How fast is its area changing?
Answer
0 cm²/s
Full solution
A=lw, so dtdA=wdtdl+ldtdw=10(2)+20(−1)=0. The two effects cancel at this instant.
Draw the tree diagram for w=f(x,y,z) with x, y, z each depending on t, and write dtdw.
Answer
dtdw=fxdtdx+fydtdy+fzdtdz
Full solution
Three branches lead from w to x, y and z, and each continues to t. Three paths give three products.
For T=x2+y2 on the path x=cost, y=2sint, where on the path does T increase fastest?
Answer
At t=4π and t=45π
Full solution
dtdT=3sin2t is largest, equal to 3, where sin2t=1.
For z=f(x,y) with x=rcosθ and y=rsinθ, write ∂r∂z.
Answer
fxcosθ+fysinθ
Full solution
∂r∂x=cosθ and ∂r∂y=sinθ. This is the rate of change of f moving straight out from the origin.
A student computes dtdz for z=x2y with x=t and y=t2 as 2x⋅1=2t. What went wrong?
Hint
How many routes lead from t to z?
Answer
The route through y is missing. dtdz=2xy⋅1+x2⋅2t=4t3.
Full solution
The student also dropped the factor y from fx=2xy. With both routes, 2t⋅t2+t2⋅2t=4t3, which matches differentiating z=t4 directly.
Frequently asked questions
What is the multivariable chain rule?
If z = f(x, y) with x = x(t) and y = y(t), then dz/dt = (∂f/∂x)(dx/dt) + (∂f/∂y)(dy/dt): one term for each intermediate variable.
Why does the chain rule add terms?
A small change in t moves both x and y, and the linear approximation dz ≈ f_x dx + f_y dy adds their effects. Dividing by dt gives the rule.
What is a tree diagram?
A picture with z at the top, the intermediate variables below it and the independent variables at the bottom. Each path from z down to a variable is one product in the sum.
How does the chain rule give implicit differentiation?
Differentiating F(x, y) = 0 with y = y(x) gives F_x + F_y dy/dx = 0, so dy/dx = −F_x / F_y wherever F_y is not zero.
What if x and y depend on two variables s and t?
Then ∂z/∂s = f_x x_s + f_y y_s and ∂z/∂t = f_x x_t + f_y y_t, the same rule with partial derivatives throughout.