Gradient of a function g(x)

501 Views Asked by At

I was told that to calculate the vector that is normal to a surface as shown in the image (please ignore red markings) you take the gradient (partial derivative w/ respect to x), transpose. I do not understand why this is done. How does the gradient, transpose give you the normal vector?

Vector that is normal to the surface

2

There are 2 best solutions below

2
On

Given a smooth surface consisting of $x \in \mathbb{R}^n$ where $g(x)=0.$ Define a curve $x(t)$ on the surface. Then the tangent vectors $x'(t)$ to the curve are are also tangent to the surface. Also note that $$ \frac{d}{dt} g(x(t))=0 \ \ \ \Rightarrow \text{ (ChainRule)} \ \ \ \nabla g(x(t)) \cdot x'(t) = 0, $$ implying that the gradient $\nabla g(x)$ is orthogonal to the tangent vector at $x.$

0
On

Your graph is the isoline $g(x) = 0$ $$ 0 = g \Rightarrow 0 = dg = \mbox{grad } g \cdot du $$ so $\mbox{grad } g$ is orthogonal to the displacement $du$ if one follows $g$.

The diagram also shows that $\mbox{grad } g$ points towards the region of positive $g$.