MATH U101 · First-time lesson · Module 5, lectures L10–L11
Directional Derivatives, the Gradient and Tangent Planes, taught from zero
Thomas' Calculus (15th ed.) §14.5–14.6*: the slope of a surface in any direction, the one vector that knows all of those slopes, and the flat plane that hugs a surface at a point. Budget 90 minutes, in two sittings.
Gradient & directional derivatives (8.3 min, T6 Q8–Q12) · Tangent planes, normal lines & intersections (6.9 min, T7 Q1–Q3). Each one is sound-on and pauses for your next move.
Module 5 is Module 4 plus one dot product. If you can compute fx and fy, you already have 80% of it. What's new is one vector (the gradient) and the picture of what it means. None of it is in any 12th-class syllabus, JEE or otherwise, so the whole hall meets it for the first time together.
Why it's worth the 90 minutes: each of the last three mid-sems had a question on this block. In 2023 it was Q2 (15 of 60 marks), in 2024 Q3 (20 of 60), and in 2025 Q1 (18 of 50). This year's mid-sem (5 Oct, open book) covers Modules 1–6, so this block is in. Error estimation from §14.6 is excluded by the handout, and this page skips it.
First time: read in order, and attempt every green "check yourself" box before opening it. Revising: the notes page has the compressed map, three past-paper questions worked in full, and the exercise table.
1 · A slope in any direction §14.5
Module 4 gave the slope of a surface z = f(x, y) in exactly two directions: walking east (fx) and walking north (fy). But a hiker can walk north-east, or in any compass direction at all, and in each one the ground rises or falls at its own rate. That rate is the directional derivative.
A direction is described by a unit vector u = u1i + u2j, meaning u12 + u22 = 1. Starting from the point (a, b), walk a distance h in direction u: you arrive at (a + hu1, b + hu2). Rise over run, then let the step shrink:
Why must u be a unit vector? Because then h is exactly the distance walked, and "rise ÷ distance" is a genuine slope. With a longer vector, say length 5, a step of h covers a distance of 5h. The quotient comes out 5 times too big and measures nothing meaningful.
Two special cases show this is not a new idea, just a wider one. With u = i = (1, 0) the formula is exactly Module 4's definition of fx, and with u = j it is fy. Partial derivatives are directional derivatives along the axes.
2 · The shortcut: one dot product §14.5
Computing that limit every time would be slow. For the functions you normally meet there is a shortcut. Package the two partials into one vector, the gradient:
Then, whenever f is differentiable at the point (Module 4, §4: for example, when its partials are continuous there),
Unpack this step: where the dot product comes from
Put g(h) = f(a + hu1, b + hu2). The limit in section 1 is just g′(0). Module 4's chain rule (two routes, x and y, both depending on h) gives g′(0) = fx·u1 + fy·u2. That is the dot product. The chain rule needs differentiability, which is why the shortcut does too (section 6).
Watch it once. Take f(x, y) = x2 + 2y2 at (1, 1), walking towards the direction of the vector 3i + 4j.
- Gradient: fx = 2x and fy = 4y, so ∇f(1, 1) = 2i + 4j.
- Normalise the direction first. |3i + 4j| = √(9 + 16) = 5, so u = (3/5, 4/5).
- Dot: Duf = 2·(3/5) + 4·(4/5) = 6/5 + 16/5 = 22/5 = 4.4.
Dotting with (3, 4) itself gives 22, exactly 5 times the true slope. Every "in the direction of the vector …" question wants you to divide by the length first. The 2023 mid-sem's handwritten answer made the related slip of reporting a direction as (3, 4) instead of the unit vector (3/5, 4/5). On an open-book paper, that one division is an easy mark to protect.
Check yourself: f(x, y) = xy + y². Find the directional derivative at (2, 1) in the direction of i − j.
∇f = y i + (x + 2y) j, so ∇f(2, 1) = (1, 4). The direction has length √2, so u = (1/√2, −1/√2). Then Duf = 1/√2 − 4/√2 = −3/√2 ≈ −2.12. Negative: walking that way, the surface goes downhill.
3 · Which way is steepest? §14.5
A dot product has a second form: a · b = |a||b| cos φ, where φ is the angle between the vectors. Since |u| = 1,
Everything about direction follows from cos φ running between −1 and 1:
- Steepest ascent: φ = 0. Walk along ∇f itself; the rate is +|∇f|, the largest possible.
- Steepest descent: φ = π. Walk along −∇f; the rate is −|∇f|.
- No change: φ = π/2. Walk perpendicular to ∇f (there are two such directions); the rate is 0.
So the gradient is a compass and a speedometer in one: it points uphill, steepest way, and its length is how steep. Try it below on f = x2 + 2y2, whose level curves are ellipses. Turn the direction u and watch the rate follow cos φ.
Things to notice as you turn u: the rate peaks exactly when u lines up with the blue arrow, and it passes through 0 exactly when u runs along the green level curve. That second fact is the subject of section 5. At (1, 1) the numbers are |∇f| = |(2, 4)| = √20 = 2√5 ≈ 4.47, and the steepest direction is (1, 2)/√5.
Check yourself: for f = x² + 2y² at (1, 1), is there a direction with directional derivative 5? And which two directions give 0?
No. The largest possible rate is |∇f| = 2√5 ≈ 4.47 < 5. For zero, u must be perpendicular to (2, 4): u = ±(−2, 1)/√5. (Check: (2, 4)·(−2, 1) = −4 + 4 = 0 ✓.)
4 · Working backwards: find the direction from the rate
A favourite exam twist runs the formula in reverse: "the directional derivative at this point is k; find u." The 2023 mid-sem did exactly this (Q2a). The unknowns are u1 and u2, and you have two facts about them:
- the rate: fxu1 + fyu2 = k (a straight line in the (u1, u2) plane);
- unit length: u12 + u22 = 1 (the unit circle).
A line meets a circle in 2, 1 or 0 points, so expect two answers in general. There is one answer when |k| = |∇f| (the steepest direction itself), and none when |k| > |∇f|, as in the check above.
Twin of the exam question. f = x2y at (1, 1) with Duf = 1.
- ∇f = 2xy i + x2 j, so ∇f(1, 1) = (2, 1). Since |∇f| = √5 > 1, expect two answers.
- Rate equation: 2u1 + u2 = 1, so u2 = 1 − 2u1.
- Substitute into the circle: u12 + (1 − 2u1)2 = 1.
- Solve: 5u12 − 4u1 = 0, so u1 = 0 or u1 = 4/5.
- Back-substitute: u = (0, 1) or u = (4/5, −3/5). Check both: 2·0 + 1 = 1 ✓, 8/5 − 3/5 = 1 ✓, and both have length 1 ✓.
Unpack this step: expanding (1 − 2u₁)²
(1 − 2u1)2 = 1 − 4u1 + 4u12. Adding u12 gives 5u12 − 4u1 + 1 = 1. The 1s cancel, leaving u1(5u1 − 4) = 0.
Check yourself: same f = x²y at (1, 1). Find every unit u with directional derivative 0.
Rate: 2u1 + u2 = 0, so u2 = −2u1. Circle: 5u12 = 1, so u1 = ±1/√5. Answer: u = ±(1, −2)/√5, the two directions perpendicular to ∇f = (2, 1), exactly as section 3 predicts.
5 · The gradient is perpendicular to the level curves §14.5
Walk along a level curve and, by definition, f doesn't change: the rate in the direction of the curve is 0. Section 3 says the rate is 0 only for directions perpendicular to ∇f. Put the two together: at every point, ∇f is perpendicular to the level curve through that point, pointing towards higher values.
The same argument works one dimension up. For a function F(x, y, z), the gradient ∇F = (Fx, Fy, Fz) is perpendicular to the level surface F = c. That single fact builds every tangent plane in section 7.
6 · At a bad point, go back to the definition
This is the past papers' favourite question, and the one most students lose marks on. The setting: a function defined by a formula everywhere except one point, where it is given a separate value, like
At the origin the shortcut ∇f · u is not allowed. It needs differentiability, which is exactly what is in doubt. So use the definition from section 1 with (a, b) = (0, 0):
- Substitute the walk. f(hu1, hu2) = h3u12u2h4u14 + h2u22 = hu12u2h2u14 + u22 (cancel h2 top and bottom).
- Form the quotient. Subtract f(0, 0) = 0 and divide by h: u12u2h2u14 + u22.
- Let h → 0, splitting cases. If u2 ≠ 0, the h2 term vanishes: Duf(0, 0) = u12u2/u22 = u12/u2. If u2 = 0, the quotient is 0 for every h, so the limit is 0.
So the directional derivative exists in every direction. Now the surprise: this function is not even continuous at the origin. Along any straight line y = mx the values tend to 0, but along the parabola y = x2 they are x4/(x4 + x4) = ½ exactly, all the way into the origin. That is Module 3's two-path test, with a curve as the second path.
Three lessons, all examinable:
- Directional derivatives in every direction do not imply continuity. Directional derivatives only test straight lines, and a function can misbehave along curves.
- The shortcut gives the wrong answer here. Along the axes f is 0, so fx(0, 0) = fy(0, 0) = 0 and ∇f · u = 0. But the true value is u12/u2. When the definition and the shortcut disagree, the function is not differentiable at that point.
- At a special point, always use the definition. The 2024 mid-sem (Q3a) asked exactly this with x6 in place of x4. The same three steps give the same u12/u2.
The other way it can go: the limit exists in only some directions. Take f = xy/(x2 + y2) with f(0, 0) = 0. Then f(hu1, hu2) = u1u2 (the h2 cancels, and u12 + u22 = 1), so the quotient is u1u2/h. It has a finite limit only when u1u2 = 0, that is, only along the four axis directions, where it is 0. The 2025 mid-sem (Q1c) used this pattern, disguised by centring the function at (1, 1). A shift X = x − 1, Y = y − 1 strips the disguise.
Check yourself: for f = xy/(x² + y²), f(0, 0) = 0, does the directional derivative at the origin exist along u = (1/√2, 1/√2)?
No. There u1u2 = ½, so the quotient is (½)/h, which blows up as h → 0. Along the diagonal, f jumps from 0 at the origin to ½ everywhere else, and a jump has no slope.
7 · Tangent planes and normal lines §14.6
Zoom in on a smooth surface and it looks flat. That flat sheet is the tangent plane, and section 5 hands us its orientation for free. Write the surface as a level surface F(x, y, z) = c. Then ∇F at the point P = (x0, y0, z0) is perpendicular to the surface, so it is the plane's normal vector. A plane through P with normal (A, B, C) is A(x − x0) + B(y − y0) + C(z − z0) = 0. So:
Example. The sphere x2 + y2 + z2 = 14 at P = (1, 2, 3) (check: 1 + 4 + 9 = 14 ✓, so P is on it). With F = x2 + y2 + z2, ∇F = (2x, 2y, 2z) = (2, 4, 6) at P. The tangent plane is 2(x − 1) + 4(y − 2) + 6(z − 3) = 0, which simplifies to x + 2y + 3z = 14. The normal line is (1 + 2t, 2 + 4t, 3 + 6t); at t = −½ it passes through the centre (0, 0, 0), as a sphere's normals should.
When the surface is a graph z = f(x, y), move everything to one side: F = f(x, y) − z = 0. Then ∇F = (fx, fy, −1), and the plane rearranges to
For z = x2 + 2y2 at (1, 1, 3): z = 3 + 2(x − 1) + 4(y − 1).
"Where is the tangent plane parallel to the xy-plane?" (2023 mid-sem, Q2b.) The xy-plane has normal k = (0, 0, 1). Parallel planes have parallel normals, so ∇F must point straight up or down: Fx = 0 and Fy = 0, with Fz ≠ 0. Solve those together with the surface equation. Twin: on (x − 1)2 + (y − 2)2 + z2 = 9, Fx = 2(x − 1) = 0 and Fy = 2(y − 2) = 0 give x = 1, y = 2. The surface then forces z2 = 9, so the points are (1, 2, ±3): the top and bottom of the sphere, as you'd expect.
A unit normal (2024 mid-sem, Q3b) is ∇F divided by |∇F|, and its negative is equally valid. Give both, or say "±".
Check yourself: where is the tangent plane to x² + y² + z² = 14 parallel to the xz-plane?
The xz-plane has normal j, so we need Fx = 2x = 0 and Fz = 2z = 0. Then y2 = 14, so the points are (0, ±√14, 0).
Where two surfaces meet
Two surfaces usually cross along a curve: a cylinder cut by a plane gives a circle or an ellipse, and a sphere cut by a plane gives a circle. What is the tangent line to that curve at a point P on both?
Zoom in at P. Each surface looks like its tangent plane, so near P the curve looks like the place where the two tangent planes cross, and two planes cross in a straight line. That line is the tangent we want. It lies in the first plane, so it is perpendicular to the first normal ∇F; it lies in the second, so it is perpendicular to ∇G too. The one direction perpendicular to two given vectors is their cross product, so the direction is ∇F × ∇G. The recipe, a worked example and a 3D figure are in the notes, section 6; Tutorial 7 Q2–Q3 use exactly this.
Check yourself: the cylinder x² + y² = 4 and the plane z = 3 meet in a circle. What is the direction of its tangent line at (2, 0, 3)?
∇F = (2x, 2y, 0) = (4, 0, 0) and ∇G = (0, 0, 1). The cross product is (0·1 − 0·0, −(4·1 − 0·0), 4·0 − 0·0) = (0, −4, 0), so the direction is along j. That makes sense: the circle x2 + y2 = 4 at height 3 is heading straight in the y-direction at the point (2, 0).
8 · Linearization and the total differential §14.6*
The tangent plane is also the best flat approximation to the surface near the point. Its formula, used for estimating values, is called the linearization of f at (a, b):
For f = x2 + 2y2 at (1, 1): L(1.1, 0.9) = 3 + 2(0.1) + 4(−0.1) = 2.8, against the true value 1.21 + 1.62 = 2.83. The total differential packages the same idea as a change: df = fx dx + fy dy (here 2(0.1) + 4(−0.1) = −0.2). The handout excludes §14.6's error-estimation part, so the formulas and one numeric use like this are all you need.
9 · You're ready: what to do next
The whole module in five sentences. The directional derivative is the slope along a unit vector. For differentiable functions it is ∇f · u = |∇f| cos φ, so the gradient points steepest-uphill with length equal to the steepest slope. The gradient is perpendicular to level curves and surfaces, which makes it the normal of every tangent plane. At a special point of a piecewise function, the shortcut is off-limits: go back to the limit definition. Normalise every direction before you dot.
- Rehearse the exam patterns on the notes page: three past mid-sem questions worked in full.
- Then the real papers: the mid-sem past papers page has this block's questions from 2023, 2024 and 2025.
- Mechanics: the notes page's exercise table maps §14.5–14.6 (odd numbers, answers in the back).
Pin it to §14.5–14.6 so it doesn't wander into Lagrange multipliers (that's Module 6). Prompts that work:
"I'm learning Thomas' Calculus 15th ed. §14.5. Give me five functions and points; for each, ask me for the gradient, the directional derivative towards a given (non-unit) vector, and the direction of steepest ascent. Check my answers one at a time, and flag it if I forget to normalise."
"Using only the limit definition of the directional derivative, walk me through f = x²y/(x⁴ + y²), f(0,0) = 0, at the origin. Let me predict each step first. Then explain why this f is not continuous even though every directional derivative exists."
"Quiz me on tangent planes to level surfaces F(x, y, z) = c: give a surface and a point, ask me to verify the point is on it, then find the tangent plane and normal line. Stay within §14.6."
One caution: AI answers can contain confident errors. Cross-check any computed number against the textbook's answers in the back.