We wish to optimize a point on the surface f(x,y) given the constraint g(x,y)=z for a given height level z.
Both surface curves are liftings of the circle you see in the xy-plane below. The movable point is also lifted.
Check the boxes to see the gradient fields. The highest and lowest points on the blue surface occur at points where the gradient vectors align. Can you see it? Why do you think that happens?