Gradient and level curves

Look at the level-curve map of a mountain, the gradient at the point you choose, how much you climb in each direction (the directional derivative), the tangent plane in 3D, the critical points with the Hessian and Lagrange with the constraint drawn. It is Roque, the site’s graphing tool, in guided mode: each step asks you what you think will happen before showing it. It works in the browser, on your phone too.

How to use it

  1. Start in “Guided”: the map of the Pico de las Nieves mountain and a question about which face is steeper.
  2. Open the gradient step by step: the two partial derivatives, their value at the point and the length of the vector, in the order you write them in the exam.
  3. Move the point with the a and b sliders and the direction with w: the gradient arrow always cuts its level curve at a right angle, and the direction that climbs most is its own.
  4. In 3D, rotate the mountain with its tangent plane; then the critical points of a surface with the Hessian and the extrema of xy on a circle with Lagrange.
  5. Switch to “Free” and try other functions and points, or press “MATLAB” to repeat it in the MATLAB playground.

What it computes

The partial derivatives and the gradient ∇f = (fx, fy) at the point you choose, with its length (the maximum directional derivative); the directional derivative in the direction u = (cos w, sin w), Duf = ∇f · u; the tangent plane z = f(a, b) + fx(x − a) + fy(y − b); the critical points with the discriminant D = fxxfyy − fxy2, and the Lagrange candidates, ∇f = λ∇g, compared with each other. The partial derivatives and gradient and extrema and optimization topics explain it step by step; the calculation of every command is checked with SymPy.