Difference between a Gradient and Tangent
I am unable to understand the fundamental difference between a Gradient vector and a Tangent vector. I need to understand the geometrical difference between the both.
By Gradient I mean a vector $\nabla F(X)$ , where $ X \in [X_1 X_2\cdots X_n]^T $
Note: I saw similar questions on "Difference between a Slope and Gradient" but the answers didn't help me much.
Appreciate any effort.
$\endgroup$ 73 Answers
$\begingroup$Say you are standing on the side of a hill. Imagine somewhere beneath the hill, there is a flat $x,y$ plane that you can use to determine your position. Let's say $+x$ is east and $+y$ is north.
If the hill is smooth, then the height of the hill above this plane is some continuous function $f(x,y)$.
The gradient of $f$ at any point tells you which direction is the steepest from that point and how steep it is. To find the direction of the gradient of $f$ where you are standing, decide which direction is the steepest. The answer could be "north" or "30 degrees west of south". There is no vertical component to the gradient, it is telling you a direction with respect to the $x,y$ plane which is your reference. The magnitude of the gradient will be the slope of the hill in that direction.
The tangent plane is the plane that best approximates the shape of the hill where you are standing. The hill may be curved if you look at it from a distance, but maybe directly beneath your feet it is flat enough to set a pizza box down and have it be flush with the ground. The plane that the bottom of the pizza box defines would, roughly, be the "tangent" plane.
$\endgroup$ 2 $\begingroup$I suppose the question has been answered in the comments.
The gradient of a function $(x_1,x_2,\ldots,x_n)\mapsto y$ is the vector $\left(\dfrac{\partial y}{\partial x_1},\dfrac{\partial y}{\partial x_2},\ldots,\dfrac{\partial y}{\partial x_n}\right)$.
The tangent to a curve $x\mapsto(y_1,y_2,\ldots,y_m)$ is the vector $\left(\dfrac{\mathrm dy_1}{\mathrm dx},\dfrac{\mathrm dy_2}{\mathrm dx},\ldots,\dfrac{\mathrm dy_n}{\mathrm dx}\right)$.
Both can be thought of as special cases of the Jacobian of a vector-valued multivariate function $(x_1,x_2,\ldots,x_n)\mapsto(y_1,y_2,\ldots,y_m)$, which is the matrix $$\begin{pmatrix} \frac{\partial y_1}{\partial x_1} & \frac{\partial y_1}{\partial x_2} & \cdots & \frac{\partial y_1}{\partial x_n}\\ \frac{\partial y_2}{\partial x_1} & \frac{\partial y_2}{\partial x_2} & \cdots & \frac{\partial y_2}{\partial x_n}\\ \vdots & \vdots & \ddots & \vdots \\ \frac{\partial y_m}{\partial x_1} & \frac{\partial y_m}{\partial x_2} & \cdots & \frac{\partial y_m}{\partial x_n}\\ \end{pmatrix}$$
$\endgroup$ $\begingroup$The gradient is like the derivative of a function for multiple variables. It shows the rate of change depending on all the given variables of the function, and it is also a vector that points in the same direction as the normal to the function at a given point.
The tangent vector points along the surface of a function and can represent a plane that is parallel to point on that surface (a plane, if the surface is 3D). The tangent vector is thus perpendicular to the gradient.
It is easy to find the tangent plane from the normal vector, since the normal vector consists of the coefficients for the tangent plane.
$\endgroup$