1. Dec 7, 2006

### Psi-String

Consider a function of two variable x,y , is it possible to understand the geometric meaning of the gradient just by looking its definition
$$\nabla f = \frac{\partial f}{\partial x} \hat{x} + \frac{\partial f}{\partial y} \hat{y}$$

I can understand the geometric meaning by directional derivative

$$\nabla f \cdot \vec{u}$$ where u is unit vector

But I want to interpret gradient's geomecric meaning "just" by it's definition, could someone tell me how?

thanks a lot

Last edited: Dec 7, 2006
2. Dec 7, 2006

### HallsofIvy

I thought this was covered in every calculus book. The gradient of a function f, $\nabla f$, is the vector pointing in the direction of fastest increase of f. It's length is the rate of increase in that direction. Of course, that means that $-\nabla f$ points in the opposite direction, the direction of fastest decrease. And if you were to walk around the hill, staying at the same altitude, you rate of increase on that path would be 0: $\nabla f\cdot \vec{v}= 0$: the path is perpendicular to the gradient at every point.

If you were standing on the side of hill with altitude given by z= f(x,y), then $\nabla f$ at your position would point up the hill in the steepest direction and its length would be the slope of the hill in that direction.

3. Dec 7, 2006

### Psi-String

I know the geometric meaning of gradient. I just want to try to interpret it straightfowardly just from the definition

$$\nabla f = \frac{\partial f}{\partial x} \hat{x} + \frac{\partial f}{\partial y} \hat{y}$$

Why gradient has that geometric meaning??

4. Dec 7, 2006

### HallsofIvy

As you said before, the rate of change of the function f(x,y) in the direction of the unit vector $\vec{v}$ is $\nabla f\cdot \vec{v}$. Any unit vector in 2d can be written in the form $cos(\theta)\vec{i}+ sin(\theta)\vec{j}[\itex] where $\theta$ is the angle the vector makes with the x-axis. Then the rate of change of f(x,y) in that direction is $$\nabla f\cdot \vec{v}= \frac{\partial f}{\partial x}cos(\theta)+ \frac{\partial f}{\partial y}sin(\theta)$$ What value of$\theta[/itex] makes that a maximum? Differentiate with respect to $\theta$ and set equal to 0:
$$-\frac{\partial f}{\partial x} sin(\theta)+ \frac{\partial f}{\partial y}cos(\theta)= 0$$
$$\frac{\partial f}{\partial y}cos(\theta)= \frac{\partial f}{\partial x}sin(\theta)[/itex] so [tex]\frac{sin(\theta)}{cos(\theta)}= tan(\theta)= \frac{\frac{\partial f}{\partial x}}{\frac{\partial f}{\partial y}}[/itex] If you think of the gradient of f as pointing along the hypotenuse of a right triangle having legs of length $\frac{\partial f}{\partial x}$ and $\frac{\partial f}{\partial y}$ then you see that equation shows gradient vector points in the direction $\theta$ that makes the rate of increase maximum or minimum. Its easy to see that the direction of the gradient is the direction of maximum increase, the opposite direction is minimum increase (i.e. maximum decrease). Look at $\frac{\partial f}{\partial x}cos(\theta)+ \frac{partial f}{\partial y}sin(\theta)$ to see that the length of the gradient is the rate of change in that direction. 5. Dec 7, 2006 ### HallsofIvy As you said before, the rate of change of the function f(x,y) in the direction of the unit vector $\vec{v}$ is $\nabla f\cdot \vec{v}$. Any unit vector in 2d can be written in the form $cos(\theta)\vec{i}+ sin(\theta)\vec{j}$ where $\theta$ is the angle the vector makes with the x-axis. Then the rate of change of f(x,y) in that direction is [tex]\nabla f\cdot \vec{v}= \frac{\partial f}{\partial x}cos(\theta)+ \frac{\partial f}{\partial y}sin(\theta)$$

What value of [/itex]\theta[/itex] makes that a maximum? Differentiate with respect to $\theta$ and set equal to 0:
$$-\frac{\partial f}{\partial x} sin(\theta)+ \frac{\partial f}{\partial y}cos(\theta)= 0$$
[tex]\frac{\partial f}{\partial y}cos(\theta)= \frac{\partial f}{\partial x}sin(\theta)[/itex]
so
[tex]\frac{sin(\theta)}{cos(\theta)}= tan(\theta)= \frac{\frac{\partial f}{\partial x}}{\frac{\partial f}{\partial y}}[/itex]
If you think of the gradient of f as pointing along the hypotenuse of a right triangle having legs of length $\frac{\partial f}{\partial x}$ and $\frac{\partial f}{\partial y}$ then you see that equation shows gradient vector points in the direction $\theta$ that makes the rate of increase maximum or minimum. Its easy to see that the direction of the gradient is the direction of maximum increase, the opposite direction is minimum increase (i.e. maximum decrease). Look at $\frac{\partial f}{\partial x}cos(\theta)+ \frac{\partial f}{\partial y}sin(\theta)$ to see that the length of the gradient is the rate of change in that direction.

6. Dec 7, 2006

### Psi-String

I see.... thanks a lot