1. Jul 16, 2009

### Faken

Hello everyone,

I have 2 components of a gradient, for example, the dz/dx and the dz/dy, I want to find the overall gradient it forms, how would I do that?

Is it simply by combining the two gradients like this:

overall gradient = ((dz/dx)^2 + (dz/dy)^2)^(1/2)

I don't need the direction, I don't really care about the direction, i just need the value of the combined gradients.

-Faken

Edit:

Well, it seems that I'm not asking my question clearly enough, let me try again but this time with a physical example.

Imagine a flat plate in 3D space that has a known slope in the x direction and the y direction (or dz/dx and dz/dy, in this case, we are using the right handed coordinate system with positive x going from left to right, positive y going away from you, and positive z going up).

If i place a ball on the plate and gravity acts on the ball in the negative z direction, which direction will the ball go (as viewed from above, or the path projected onto the XY plane), and what slope will the ball "see" going in that direction.

Basically its like converting Cartesian coordinates into polar coordinates, except I'm dealing with a gradient or slope.

Last edited: Jul 17, 2009
2. Jul 16, 2009

### dx

The gradient of a function is a vector field. If you are working in 3D space, then the vector field has three components. You cannot find the magnitude without knowing all three components.

3. Jul 16, 2009

### Faken

Ok maybe not 3d space.

4. Jul 17, 2009

### HallsofIvy

Staff Emeritus
What, exactly, do YOU mean by "overall gradient" then? If you start with two values, but the formula you then gives, assuming that z is a function of the two variables x and y, is for the magnitude of the gradient vector. The gradient vector itself is just $\left(\partial z/\partial x\right)\vec{i}+ \left(\partial z/\partial y}\left)\vec{j}$.
And, of course, you must be working in two dimensions, not three.