This whole subtopic is higher level. Nothing in it is on an SL paper.
Educerie · IB Diploma · Mathematics: analysis and approaches
IB Mathematics AA 5.14 · HL only
Implicit differentiation, related rates and optimisation
How do you differentiate a relationship you cannot solve for y, how fast does one quantity change when another linked to it is changing, and where exactly is the best value of a model, including when it sits at the edge of what is allowed?
What you will learn
HL Understand implicit differentiation as differentiating an equation as it stands, with the chain rule on every term in y
HL Understand related rates as one equation differentiated with respect to time to link two rates
HL Know how to build an optimisation model from a description, using the chain rule or implicit differentiation
HL Know that the best value on an interval can lie at an end point, not only at a stationary point
You must be able to
HL Find dy ÷ dx for an implicit curve and use it for the tangent or normal at a point
HL Solve related rates problems with a linking equation, units and the correct sign
HL Solve an optimisation problem in context and justify that the answer is a maximum or minimum
HL Find the points where an implicit curve has a horizontal or vertical tangent
HL Determine when the optimum is at an end point of the domain
HL Find d²y ÷ dx² by implicit differentiation and use it to classify a stationary point
In the exam. most often on Paper 3 and Paper 2, less often on Paper 1. Paper 3: implicit differentiation and rates of change as steps inside a longer investigation, often a family of curves or a general result built up through "Show that" and "Hence" parts. Paper 2: related rates and optimisation in context, about 6 marks, with a GDC to solve the final equation. Paper 1 (no calculator): implicit differentiation for a gradient, tangent, normal or second derivative (3 to 5 marks a part), and related rates with exact answers such as 5π4. "Find" and "Show that" are by far the commonest command terms here, so you must be able to reach a printed result as well as produce one.
1Implicit differentiation
Why not just solve for y?
Take the circle x2+y2=25. Solving gives y=±25−x2: two functions, one for each half.
At x=3 there are two points, (3,4) and (3,−4). Their tangents have different gradients, so no single f(x) describes the whole curve.
For x3+y3=6xy, this course's algebra cannot solve for y at all. We need a method that works on the equation itself.
The one habit
Differentiate every term with respect to x. A term in x behaves as usual. A term in y is a function of a function, since y depends on x. So
dxd(g(y))=g′(y)dxdy.
In words: differentiate as though y were the variable, then attach dxdy. A term mixing both, such as xy, also needs the product rule.
Term
Derivative with respect to x
Rule used
y3
3y2dxdy
chain rule
ey
eydxdy
chain rule
siny
cosydxdy
chain rule
lny
y1dxdy
chain rule
xy
y+xdxdy
product rule, then chain rule on y
x2y
2xy+x2dxdy
product rule
xy2
y2+2xydxdy
product rule, chain rule on y2
a constant
0
Gather every term containing dxdy on one side, factorise it out, and divide.
Worked example 1. Paper 1. Find dxdy for x2+y2=25, and the gradient at (3,4) and at (3,−4).
The result has a y in it. That is normal: a point on the curve needs both coordinates before you can read off a gradient. That is how one formula gives two gradients at x=3. Figure 1 draws both tangents.
Figure 1 · One formula, dy ÷ dx = −x ÷ y, gives both tangents at x = 3
Check: the radius to (3,4) has gradient 34, and −43 is its negative reciprocal. So the tangent meets the radius at a right angle, as it must.
Worked example 2. Paper 1. The curve C is given by x2y+xy2=12. Show that (1,3) lies on C, and find the equation of the tangent at that point.
Both terms are products, so the product rule is used twice.
check: 12(3)+(1)(32)=3+9=12✓2xy+x2dxdy+y2+2xydxdy=0product rule on each termdxdy(x2+2xy)=−(2xy+y2)gather the dxdy termsdxdy=−x2+2xy2xy+y2at (1,3):dxdy=−1+66+9=−715tangent: y−3=−715(x−1),soy=736−15x
Worked example 3. Paper 1. The curve x3+y3=6xy passes through (3,3). Find the tangent and the normal there.
Figure 2 shows this curve. It has a loop and crosses itself at the origin, so no single y=f(x) covers it.
3x2+3y2dxdy=6y+6xdxdyproduct rule on 6xydxdy(3y2−6x)=6y−3x2dxdy=y2−2x2y−x2divide top and bottom by 3at (3,3):dxdy=9−66−9=−1tangent: y−3=−(x−3),soy=−x+6normal: gradient 1,soy−3=x−3,y=x
Figure 2 · The tangent and normal to x³ + y³ = 6xy at (3, 3)
The normal is the line y=x, a line of symmetry of the curve. Swapping x and y leaves the equation unchanged, so the curve is its own mirror image in that line.
When only one coordinate is given
For "the tangent where x=3", substitute into the curve to find y. Expect possibly more than one answer.
On the circle in example 1, x=3 gives y=4 or −4: two tangents (Figure 1). Find the gradient at each point separately.
Horizontal and vertical tangents
A tangent is horizontal where dxdy=0. The numerator of your fraction is zero, with the denominator non-zero.
A tangent is vertical where the denominator is zero, with the numerator non-zero.
Each condition links x and y. Substitute it into the curve to find the points. Where numerator and denominator are both zero, the rule cannot decide, so confirm the other part is non-zero at every point you report.
Worked example 4. Paper 1. Find the points on x2−2xy+4y2=12 where the tangent is horizontal, and where it is vertical.
2x−2y−2xdxdy+8ydxdy=0dxdy=4y−xy−xhorizontal: y−x=0,soy=xx2−2x2+4x2=12⇒3x2=12⇒x=±2substitute into the curvepoints (2,2) and (−2,−2);denominator 4y−x=3x=0vertical: 4y−x=0,sox=4y16y2−8y2+4y2=12⇒y=±1points (4,1) and (−4,−1);numerator y−x=−3y=0
Second derivatives
To get dx2d2y, differentiate the equation that still contains dxdy once more. This is usually easier than the quotient rule on the solved form.
Treat dxdy as a function of x: a term ydxdy needs the product rule, which creates (dxdy)2. Finish by substituting the earlier result for dxdy.
Worked example 5. Paper 1. For x2+y2=25, show that dx2d2y=−y325, and state whether the curve is concave up or down at (3,4) and at (3,−4).
2x+2ydxdy=0the first derivative, as in example 12+2(dxdy)2+2ydx2d2y=0differentiate again; product rule on ydxdydx2d2y=−y1+(dxdy)2=−y1+y2x2=−y3x2+y2=−y325use dxdy=−yxat (3,4):−6425<0,concave downat (3,−4):+6425>0,concave up
This agrees with Figure 1: the top half curves down, the bottom half up.
To classify a stationary point of an implicit curve, put dxdy=0 into the second-derivative equation before solving for dx2d2y. Most terms vanish and one remains (see Try it Q7).
In 5.15 the same method produces the derivatives of arcsinx, arccosx, arctanx and ax.
2Related rates of change
In a related rates problem, several quantities vary with time and obey one equation. One rate is given and another is wanted, at one instant. You can link them in two ways:
A direct chain rule, when one quantity is written in terms of another: dtdA=drdA×dtdr.
A linking equation. When the quantities are tangled together, differentiate it with respect to t, as in section 1 with t replacing x.
The method, in five steps.
Draw the situation and give every changing quantity a letter. Keep the numbers for the special instant out of the diagram: they are true only for a moment.
State the rate you are given and the rate you want, with units, as derivatives with respect to t. A decreasing quantity has a negative rate.
Find one equation joining the quantities. If it has an extra variable, remove it with something that stays true all the time: a fixed length, similar triangles, or right-angled trigonometry. Pythagoras handles sliding and rope problems.
Differentiate with respect to t.
Only now put in the numbers for the instant, and solve for the wanted rate.
Worked example 6. Paper 1. A snowball melts so that its volume falls at 12cm3min−1. It stays spherical. Find the rate at which its radius is changing, and the rate at which its surface area is changing, when the radius is 3cm.
The radius shrinks at about 0.106cmmin−1 and the surface area shrinks at 8cm2min−1.
The second answer reuses the first: once dtdr is known, anything depending on r follows by one more chain rule.
A steady rate for one quantity does not make the others steady. dtdr varies as r21, so at r=1.5cm the same melting shrinks the radius four times as fast.
Worked example 7. Paper 1. A rectangular rubber sheet is stretched lengthways: its length x grows at 1.5cms−1 while its width y narrows at 0.5cms−1. Find the rate of change of its area when x=18cm and y=5cm.
When two factors both move, the product rule gives one term per factor.
A=xy,dtdx=1.5,dtdy=−0.5dtdA=dtdxy+xdtdyproduct rule, with respect to tdtdA=(1.5)(5)+(18)(−0.5)=7.5−9=−1.5
The area is falling at 1.5cm2s−1, even though the length is growing. At that instant the narrowing removes more area than the stretching adds.
Worked example 8. Paper 1. A ladder 6.5m long leans against a vertical wall. The foot slides away from the wall at 0.3ms−1. How fast is the top moving down the wall when the foot is 2.5m from the wall? Figure 3 sets it up.
Figure 3 · The ladder: x and y change, the 6.5 m does not
x2+y2=6.52=42.25Pythagoras; the ladder’s length never changes2xdtdx+2ydtdy=0differentiate with respect to tdtdy=−yxdtdxat the instant: x=2.5, so y=42.25−6.25=6;dtdx=0.3dtdy=−62.5(0.3)=−0.125
The top descends at 0.125ms−1. The minus sign means y is decreasing. In the final sentence give the speed and say "down". The algebra is that of example 1: the ladder's relation is a circle again.
Worked example 9. Paper 1. A conical tank has its vertex at the bottom, height 5m and top radius 2m. Water enters at 0.8m3 per minute.
Find the rate at which the depth is rising when the depth is 2.5m. Find also the rate at which the radius of the water surface is growing then.
The water forms a smaller cone with depth h and surface radius r, both changing (Figure 4). V has two variables, so eliminate r first.
Figure 4 · The water is a cone similar to the tank
hr=52,sor=52hsimilar triangles, true at every momentV=31πr2h=31π(52h)2h=754πh3dtdV=254πh2dtdhdifferentiate with respect to t0.8=(254π×6.25)dtdh=πdtdhat h=2.5, dtdV=0.8dtdh=π0.8=5π4≈0.255m per minutedtdr=52dtdh=25π8≈0.102m per minute
Putting r=1 (its value at h=2.5) into V before differentiating treats r as fixed and gives the wrong equation. That is why step 5 comes last.
Worked example 10. Paper 1. A spotlight stands 80m from a long straight wall, level with the point O on the wall nearest to it. The beam turns at a steady 0.2rads−1.
The spot of light on the wall is x metres from O. The beam makes angle θ with the line from the lamp to O. Find the speed of the spot when θ=4π.
Right-angled trigonometry is the link. Use radians, so the derivative of tan holds.
The spot moves at 32ms−1. A steady turn gives a spot that speeds up as it moves away from O. At θ=0 the speed is only 16ms−1.
When V is given as a function of h
If a question supplies V=f(h), the link already exists: dtdV=f′(h)dtdh, so dtdh=f′(h)1×dtdV.
The instant is often given as a volume, not a depth. Solve f(h)= that volume first. Hold exact values (or three significant figures) to the end. Rounding too soon costs the last mark.
Worked example 11. Paper 2. Water runs into a flower vase at 6cm3s−1. At depth hcm the volume is V=0.4h3−5h2+30hcm3, for 0≤h≤12. Find the rate at which the depth is increasing at the moment the vase holds 100cm3.
0.4h3−5h2+30h=100⇒h=6.880…GDC; the only real rootdhdV=1.2h2−10h+30=18.00…at this hdtdV=dhdV×dtdh⇒6=18.00dtdhdtdh=0.333cms−1
Typical slips: using 100 as the depth in dhdV, or putting h=100 into the formula. 100 is a volume, so solve for the depth.
3Optimisation, including end points
At SL you found a greatest or least value by solving f′(x)=0 and checking the nature. HL adds two things the guide spells out:
The function is built from a description. Differentiating it may need the chain rule or implicit differentiation.
The domain has limits. The best value can lie at an end point, not at a stationary point.
The method.
Name the quantity to optimise and the variable you will differentiate with respect to. Draw a figure if there is geometry.
Use the constraint to remove other variables until one remains. Write down its domain.
Differentiate and solve for the stationary points. Discard any outside the domain.
Justify the nature (second derivative, or sign of the first derivative either side).
Compare with the values at the end points. Then answer in context with units.
On a closed interval a≤x≤b, the greatest and least values occur either at a stationary point inside the interval or at an end point. Evaluate them all.
Worked example 12. Paper 2. A power cable must run from a station A on one bank of a straight river, 600m wide, to a factory B on the other bank. The factory is 2000m downstream of the point O directly across from A.
Cable under water costs €50 per metre. Cable along the bank costs €30 per metre. The cable crosses to a point P on the far bank, xm from O, then follows the bank to B (Figure 5). Find the x that minimises the cost.
Figure 5 · The cable crosses to P, then follows the bank
C(x)=506002+x2+30(2000−x),0≤x≤2000C′(x)=360000+x250x−30chain rule on the square rootC′(x)=0:50x=30360000+x22500x2=900(360000+x2)square both sides (x≥0)1600x2=324000000,x2=202500,x=450C(450)=50(750)+30(1550)=84000end points: C(0)=90000,C(2000)≈104403
The cheapest cable costs €84,000, at x=450m. The end-point values are larger, so 450 wins over the whole interval. The sign of C′ agrees: C′(0)=−30<0 and C′(2000)≈17.9>0.
Now alter one fact: the factory is only 300m downstream. Then C(x)=506002+x2+30(300−x) on 0≤x≤300.
The derivative has the same form and still vanishes only at x=450, outside the domain. On the interval C′(x)<0 throughout (C′(300)≈−7.6). So C falls all the way, and the minimum is at the end point x=300: lay everything under water, straight to the factory.
C(300)=50450000≈33541all under waterC(0)=30000+9000=39000straight across, then 300m of bank
Figure 6 shows both cost curves. In the first, the minimum is the bottom of a valley. In the second, the valley lies beyond the right-hand edge, so the lowest allowed point is the edge.
Figure 6 · The minimum at a stationary point, and at an end point
A stationary point outside the domain is not an answer. Writing 450 and stopping would earn almost nothing in the second version.
Worked example 13. Paper 1. A cylinder is cut from a solid hemisphere of radius 3cm. Its base lies on the flat face of the hemisphere and its axis passes through the centre of that face (Figure 7). Find the greatest possible volume of the cylinder.
Figure 7 · A cylinder inside a hemisphere of radius 3
Let the cylinder have radius r and height h. The top rim touches the curved surface, so the right-angled triangle in the cross-section ties them together.
r2+h2=9,sor2=9−h2Pythagoras in the cross-sectionV=πr2h=π(9−h2)h=π(9h−h3),0<h<3dhdV=π(9−3h2)=0⇒h2=3,h=3dh2d2V=−6πh<0ath=3,so a maximumr2=9−3=6V=π×6×3=63π≈32.6cm3
The guide names "appropriate use of the chain rule or implicit differentiation". The implicit route reaches the same answer without solving the constraint for r2. Keep r and h, and differentiate the constraint and the volume with respect to h.
2rdhdr+2h=0⇒dhdr=−rhdifferentiate r2+h2=9 implicitlydhdV=π(2rhdhdr+r2)=π(r2−2h2)product rule on V=πr2hdhdV=0⇒r2=2h22h2+h2=9⇒h=3,r2=6back into the constraint: the same cylinder
Substituting first is shorter here. The implicit route earns its place when the constraint cannot easily be solved for one variable.
At either end of 0<h<3, the cylinder is a flat disc or a thin needle and V→0. So the single stationary point must be the maximum.
For a whole sphere of radius 3 the same steps give h=23 and V=123π. By symmetry, that is the hemisphere answer doubled.
Worked example 14. Paper 1. A farmer encloses a rectangular pen against a straight barn wall. She uses 120m of fence for three sections perpendicular to the wall (two ends and a divider) and one section parallel to it. Let each perpendicular section be xm.
(a) Find the greatest area.
(b) The wall is only 45m long, so the side of the pen along it is at most 45m. Find the greatest area now.
parallel side y=120−3x,A(x)=x(120−3x)=120x−3x2,0<x<40A′(x)=120−6x=0⇒x=20,y=60,A=1200(a); A′′=−6<0y≤45⇒120−3x≤45⇒x≥25,domain 25≤x<40(b)A′(x)=120−6x<0forx≥25⇒A is decreasingA(25)=25(45)=1125
In (a) the best pen has area 1200m2. In (b) the old optimum x=20 is no longer allowed. The best allowed value is the end point x=25, where the pen uses the whole wall and has area 1125m2.
Worked example 15. Paper 1. Find the point on the curve y=x2 that is closest to A(3,0), and the shortest distance.
For a point (x,x2), the distance is D=(x−3)2+x4. The square root is awkward, but D>0, so D is least exactly where D2 is least. By the chain rule, dxdD=2D1×dxd(D2), so the two derivatives vanish together. Minimise D2.
D2=(x−3)2+x4dxd(D2)=2(x−3)+4x3=2(2x3+x−3)=2(x−1)(2x2+2x+3)x=1 is a root, so x−1 is a factor2x2+2x+3=0has discriminant 4−24<0,so x=1 is the only stationary pointdx2d2(D2)=2+12x2>0,so a minimumD2=(1−3)2+1=5,D=5≈2.24
The closest point is (1,1), at distance 5. Here x can be any real number and D2→∞ as x→±∞, so the single minimum is the least value overall. On a restricted arc, compare with the ends as in examples 12 and 14.
Check: A to (1,1) has gradient −21 and the tangent there has gradient 2. They are perpendicular, as the shortest route to a smooth curve must be.
Practice questions
30 questions on this note, from easy to hard. Each one you get right lights a star of this topic's constellation.
Practice · 5.14 Implicit differentiation, related rates and optimisation