# Functions & vector fields

## Main Question or Discussion Point

Suppose that normal derivative = $\nabla$g . n = dg/dn,
then f $\nabla$g . n = f dg/dn
[I used . for dot product]

But how is this possible?
For f $\nabla$g . n, I would interpret it as (f $\nabla$g) . n
But f dg/dn = f ($\nabla$g . n) which is DIFFERENT (note the location of brackets)

I recall that if u,v are vectors, a is a scalar constant, then (au) . v=a(u . v) = u . (av), but in our case, f is a FUNCTION!!! So this rule cannot be applied.

f $\nabla$g . n = f dg/dn seems to be suggesting that f is a scalar constant, but consider the following case:
Let div F=$\nabla$ . F
If f were really a scalar constant, then by the rule, div (f $\nabla$g) = $\nabla$ . (f $\nabla$g) = f ($\nabla$ . ($\nabla$g)) which is WRONG becuase we know that in general div(fG)=f div G + ($\nabla$f) . G where f is function and G is vector field. But if this is wrong, then HOW can you justify that (f $\nabla$g) . n = f ($\nabla$g . n)?

I seriously can't understand this...there are two seemingly contradicting ideas crashing in my mind...

Would someone be nice enough to clear my doubts? Thanks!

Last edited:

Hurkyl
Staff Emeritus
Gold Member
I recall that if u,v are vectors, a is a scalar constant, then (au) . v=a(u . v) = u . (av), but in our case, f is a FUNCTION!!! So this rule cannot be applied.
Remember that two scalar fields are equal if and only if they have the same value at every point! What happens if you evaluate both $(f \nabla g) \cdot \vec{n}$ and $f (\nabla g \cdot \vec{n})$ at a generic point x?

Remember that two scalar fields are equal if and only if they have the same value at every point! What happens if you evaluate both $(f \nabla g) \cdot \vec{n}$ and $f (\nabla g \cdot \vec{n})$ at a generic point x?
At every fixed point, f would be a scalar constant, so "the rule" can be applied, right?

But if we can treat f as a scalar constant, then by "the rule", div (f $\nabla$g) = $\nabla$ . (f $\nabla$g) = f ($\nabla$ . ($\nabla$g)) which is WRONG becuase we know that in general there is an identity div(fG)=f div G + ($\nabla$f) . G where f is function and G is vector field. Using this identity gives a different answer.

Note: "the rule": if u,v are vectors, a is a scalar constant, then (au) . v=a(u . v) = u . (av)

Last edited:
Hurkyl
Staff Emeritus
Gold Member
You made an error when evaluating the derivative, though. The value of the derivative of a function at a point is (usually) not the derivative of the value of the function at that point.

In particular...

$$(\nabla \cdot f)(a) \neq \nabla \cdot f(a) \quad (= 0)$$

Another example, for comparison:

$$f'(a) \neq f(a)'$$

Last edited:
You made an error when evaluating the derivative, though. The value of the derivative of a function at a point is (usually) not the derivative of the value of the function at that point.

In particular...

$$(\nabla \cdot f)(a) \neq \nabla \cdot f(a) \quad (= 0)$$

Another example, for comparison:

$$f'(a) \neq f(a)'$$
Sorry, I don't quite get your point.
Can you please inform me where (which equal sign) exactly I am wrong?
div (f $\nabla$g) = $\nabla$ . (f $\nabla$g) = f ($\nabla$ . ($\nabla$g))

Also, for your " f ", is it a scalar or a vector field?

What's the problem? All you have done is multiply the normal derivative by f. There's no differential operation on f at all so you do not need to be concerned that it is a function rather than a scalar.

nicksauce
Homework Helper
What's the problem? All you have done is multiply the normal derivative by f. There's no differential operation on f at all so you do not need to be concerned that it is a function rather than a scalar.
Indeed. I think I am more stumped about why you are stumped than you are stumped about the problem at hand.

Hurkyl
Staff Emeritus
Gold Member
Sorry, I don't quite get your point.
Can you please inform me where (which equal sign) exactly I am wrong?
div (f $\nabla$g) = $\nabla$ . (f $\nabla$g) = f ($\nabla$ . ($\nabla$g))

Also, for your " f ", is it a scalar or a vector field?
I was using f for scalar field, as you were. Note that these expressions would be nonsense if f were a vector field.

$\nabla$ . (f $\nabla$g) = f ($\nabla$ . ($\nabla$g))
This is wrong -- you cannot simply pass f through the derivative. You need to use the chain rule.

I was using f for scalar field, as you were. Note that these expressions would be nonsense if f were a vector field.
You said that $$(\nabla \cdot f)(a) \neq \nabla \cdot f(a) \quad (= 0)$$, but how can a vector be dotted with a scalar?

This is wrong -- you cannot simply pass f through the derivative. You need to use the chain rule.
But if u,v are vectors, a is a scalar, then (au) . v=a(u . v) = u . (av)

Now $\nabla$ is a vector, f is a scalar, $\nabla$g is a vector, so I just applied the above property, getting $\nabla$ . (f $\nabla$g) = f ($\nabla$ . $\nabla$g)

How come it works for the first case (normal derivative case), but not this one? This is the part I don't understand...

Thanks for explaining!

Last edited:
nicksauce
Homework Helper
$$\nabla$$ not only a vector, but an operator as well. You can't just blindly apply vector rules, but you must apply derivative rules well.

$$\nabla \cdot (f\nabla g) \neq f (\nabla \cdot \nabla g)$$
because it is operating on both f and g.

$$(f\nabla g) \cdot (\vec{n}) = f(\nabla g \cdot \vec{n})$$
because it is operating just on g.

Last edited:
Hurkyl
Staff Emeritus
Gold Member
You said that $$(\nabla \cdot f)(a) \neq \nabla \cdot f(a) \quad (= 0)$$, but how can a vector be dotted with a scalar?
You're right; I forgot about that example (and the example with f'). Those examples were a vector field and a function of the reals, respectively.

$$\nabla$$ not only a vector, but an operator as well. You can't just blindly apply vector rules, but you must apply derivative rules well.

$$\nabla \cdot (f\nabla g) \neq f (\nabla \cdot \nabla g)$$
because it is operating on both f and g.

$$(f\nabla g) \cdot (\vec{n}) = f(\nabla g \cdot \vec{n})$$
because it is operating just on g.
So for the first case, we need to use the product rule, right?

nicksauce
Homework Helper
Yes.

$$\nabla$$ not only a vector, but an operator as well. You can't just blindly apply vector rules, but you must apply derivative rules well.

$$\nabla \cdot (f\nabla g) \neq f (\nabla \cdot \nabla g)$$
because it is operating on both f and g.

$$(f\nabla g) \cdot (\vec{n}) = f(\nabla g \cdot \vec{n})$$
because it is operating just on g.
Sorry, but something is still not perfectly clear to me...
Why is $$\nabla$$ operating on BOTH f and g for the first case?
If we could treat f as a scalar, we should be able to pull it out like a constant...

Hurkyl
Staff Emeritus
Gold Member
Why is $$\nabla$$ operating on BOTH f and g for the first case?
The operator $\nabla \cdot$ is not operating on either of them. It's operating on the vector field $f \nabla g$.

If we could treat f as a scalar, we should be able to pull it out like a constant...
f is a scalar (field), but it's not a constant scalar (field). If you want to treat scalar fields like numbers, you have to distinguish between the constant scalars and the nonconstant scalars.

The point I made earlier was about evaluating the expression at a point. If I have the scalar field g given by (u and v are vector fields)

$$g = u \cdot v$$

then what is the value of g at a point a? i.e. what is g(a)?

Now, if I instead have the scalar field

$$g = \nabla \cdot u$$

then what is the value of g at a point a? i.e. what is g(a)?

Last edited:
The operator $\nabla \cdot$ is not operating on either of them. It's operating on the vector field $f \nabla g$.

f is a scalar (field), but it's not a constant scalar (field). If you want to treat scalar fields like numbers, you have to distinguish between the constant scalars and the nonconstant scalars.

The point I made earlier was about evaluating the expression at a point. If I have the scalar field g given by (u and v are vector fields)

$$g = u \cdot v$$

then what is the value of g at a point a? i.e. what is g(a)?

Now, if I instead have the scalar field

$$g = \nabla \cdot u$$

then what is the value of g at a point a? i.e. what is g(a)?
For the first case, g(a)=(u.v)(a), just dot u with v to get an expression and substitute in the value a?

For the second case, g(a)=(del.u)(a) just do the dot product FIRST and then sub. in the value a? I can't see any difference... :(

One more related question:

(f . $\nabla$) g

f . ($\nabla$g)

Are these equivalent? If so, then why write in the fist form? My textbook keeps writing in the first form and I don't know why...