Actually, this is not an unique topic about gradient but I still would like to share my experiments on gradient. I’d like to study gradient term from a different aspect here. The other resources will be listed at the end of the article.

How I came up with the gradient again? I had accepted it as partial derivatives of variables of a function for a long time till I need to find out the position vector to the extremum from any point on the x-axis. I need to understand geometrical meaning of the gradient vector. If you remember, gradient of a scalar function is a vector and gives us the results below:

1. It’s a vector that points in the direction of greatest increase of a function.
2. It’s zero at a local maximum or local minimum (because there is no single direction of increase)

I’ll look into a quadratic function here for my special case. At first, I thought that gradient vector would give me the vector points to the extremum point If exist. But it was an intuitive error. Let’s consider a quadratic function f(x) and examine its graph.

The graph on the left shows the curve of an f(x) function and its derivative df/dx. I studied here a function has a max. point because of the nature of the gradient and to understand it more precisely. The f(x) function curve has a max. point and df/dx curve cuts the x-axis on point x=2. As you see, maximum value of the function located on x=2 on x-axis with the value of f(x)=6. By the way, this graph was drawn by gnuplot.

df/dx is positive on the left side of maximum point and negative in the other direction. Especially for the sample, this means that the magnitude of gradient vector is positive on the left side and negative on the right side. This means the gradient vector on the left side points to the right (positive direction) and points to the left on the right side (negative direction). Now, we exactly know a gradient vector on points of x-axis in the direction of greatest increase of a function. (In this sample, to the maximum point).

Well, so what can we say about the magnitude of the vector? Of course, we know it already from birth. The magnitude of the vector would be equal to the df/dx. But even so, It would be nice to see the gradient vectors on the graph. Let’s see them.