Multivariable calculus

Directional derivative of x^2 + 4y^2 at (1, 1)

At (1, 1) the gradient of f(x,y) = x^2 + 4y^2 is (2, 8). Dotting with the unit direction (0.96, -0.28) gives -8/25, that is -0.32. The direction sits a little past the tangent to the level ellipse, so the value is small and negative even though the bowl is steep here.

f(x,y)=x2+4y2f(x,y) = x^2 + 4y^2
Duf(1,1)=825=0.32D_{\mathbf{u}} f(1,1) = -\frac{8}{25} = -0.32

At x = 1, y = 1, in the unit direction (0.96, -0.28).

An elliptic bowl and its gradient

Each term differentiates on its own: x2x^2 gives 2x2x and contributes nothing to the yy partial, while 4y24y^2 gives 8y8y and contributes nothing to the xx partial.

f=2x,  8y,f(1,1)=2,8\nabla f = \langle 2x,\; 8y \rangle, \qquad \nabla f(1,1) = \langle 2, 8 \rangle

The lopsidedness matters. The 4 in front of y2y^2 makes the surface climb four times faster in yy than in xx at the same coordinate value, and the gradient leans heavily toward the yy axis.

Duf(1,1)=2(0.96)+8(0.28)=1.922.24=825D_{\mathbf{u}} f(1,1) = 2(0.96) + 8(-0.28) = 1.92 - 2.24 = -\frac{8}{25}

The mistake: assuming outward means uphill

The direction 0.96,0.28\langle 0.96, -0.28 \rangle moves away from the origin in xx, and the surface is a bowl, so students often expect an increase. The level curves are ellipses, not circles, and stepping that way crosses onto a slightly lower ellipse.

  • f(1,1)=5f(1,1) = 5, and the level curve through the point is x2+4y2=5x^2 + 4y^2 = 5
  • Step 0.10.1 along the direction to (1.096,0.972)(1.096, 0.972), where f4.980f \approx 4.980, lower than 5
  • Only for a circular bowl like x2+y2x^2 + y^2 would outward always mean uphill

The other frequent slip is writing fy=2y\frac{\partial f}{\partial y} = 2y and forgetting the 4. That would give 2(0.96)+2(0.28)=1.362(0.96) + 2(-0.28) = 1.36, positive, and the sign of the answer would be wrong as well as its size.

Almost tangent to the level ellipse

The angle between 2,8\langle 2, 8 \rangle and 0.96,0.28\langle 0.96, -0.28 \rangle is about 92.2 degrees, only just past the right angle. That is why the answer is close to zero despite a gradient of length 2,8=2178.246\lVert \langle 2, 8 \rangle \rVert = 2\sqrt{17} \approx 8.246.

Duf(1,1)=217cosθ,cosθ0.0388D_{\mathbf{u}} f(1,1) = 2\sqrt{17}\,\cos\theta, \qquad \cos\theta \approx -0.0388

The exactly tangent direction is 8,2/680.970,0.243\langle 8, -2 \rangle / \sqrt{68} \approx \langle 0.970, -0.243 \rangle, which is close to our direction but not equal to it. That small gap is the whole of the 0.32-0.32.

The build re-checks that (0.96, -0.28) has length 1, rebuilds the gradient of x^2 + 4y^2 at (1, 1) by central differences on the function itself, and fails unless the dot product is still -0.32.

Frequently asked questions

How can the answer be negative on a bowl that opens upward?

A bowl has directions of every kind at every point except its bottom. Here the 4y24y^2 term shrinks at rate 8(0.28)=2.248(0.28) = 2.24 while the x2x^2 term grows at only 2(0.96)=1.922(0.96) = 1.92, so the step nets out downhill.

Where is the only point with all directional derivatives zero?

At the origin, where f=0,0\nabla f = \langle 0, 0 \rangle. That is the minimum of the bowl, and it is the one place where no direction changes ff to first order.