Calculate the gradient of the function

In summary, the conversation discusses calculating the gradient of three different functions, V1, V2, and V3. The correct notation for gradient is "del f" or "grad f". The expressions for del f in Cartesian, cylindrical, and spherical coordinates are given, with the correct unit vectors being i, j, and k for Cartesian, 1ρ, 1Φ, and 1θ for cylindrical, and 1r, 1φ, and 1θ for spherical. The conversation also clarifies the use of angles phi and theta in cylindrical and spherical coordinates.
  • #1
DODGEVIPER13
672
0

Homework Statement


Calculate the gradient of:
(a) V1=6xy-2xz+z
(b) V2=10ρcos(phi)-ρz
(c) V3=(2/r)cos(phi)


Homework Equations





The Attempt at a Solution


Upload
 

Attachments

  • EPSON013.jpg
    EPSON013.jpg
    6.8 KB · Views: 495
Physics news on Phys.org
  • #2
You have the notation wrong for gradient. You wrote div instead. You can't take the div of a scalar. V1, V2 and V3 are all scalars.

You also have the wrong expressions for del F in cartesian, cylindrical and spherical coordinates. Look them up.
 
  • #3
so what you are saying is that instead of just del I should have used del f for notation?
(∂f/∂x)x+(∂f/∂y)y+(∂f/∂z)z (where x, y, and z should be x(hat), y(hat), and z(hat))
 
  • #4
so if I am right which I probably am not then (a) 6yUx+(-0)+zUz the reason I put 0 is the the partial derivative of -2xz with respect to y is 0 correct since there is no y term.
 
  • #5
DODGEVIPER13 said:
so what you are saying is that instead of just del I should have used del f for notation?
(∂f/∂x)x+(∂f/∂y)y+(∂f/∂z)z (where x, y, and z should be x(hat), y(hat), and z(hat))

You did not write "just del". You wrote del-dot. The dot was wrong. You can write del f or you can write grad f. Same thing. (But del-dot-F is OK whereas del F or grad F are not.)

Your expression for grad f is correct for Cartesian coordinates x,y,z. I use i, j , and k for the unit vectors. I also use bold type for all vectors.

When you get to V2 and V3 the expressions for grad V are very different from Cartesian. V2 is using cylindrical and V3 is using spherical.
 
  • #6
DODGEVIPER13 said:
so if I am right which I probably am not then (a) 6yUx+(-0)+zUz the reason I put 0 is the the partial derivative of -2xz with respect to y is 0 correct since there is no y term.

Yes, ∂(-2xz)/∂y = 0.
No, you are not following your formula in post 3 for V1.
Don't keep changing your notation for the unit vectors. Use i j k why not.
 
  • #7
dang I felt it might have actually been right. was it simply this 6yi+k
 
  • #8
DODGEVIPER13 said:
dang I felt it might have actually been right. was it simply this 6yi+k

Was what 6y i + k ?
 
  • #9
yes but it isn't correct I can imagine.
 
  • #10
I'm getting dizzy. Correct for what?

Tell you what, start over with your expression for grad V1 from your post 3, use i j k unit vectors, and let's see if we can't figure this one out. Remember to use V1, not f.
 
  • #11
∇V1=(∂f/∂x)i+(∂f/∂y)j+(∂f/∂z)k= 6y i + k
 
  • #12
DODGEVIPER13 said:
∇V1=(∂f/∂x)i+(∂f/∂y)j+(∂f/∂z)k= 6y i + k

I said use V1, not f.
OK, one term at a time. Try ∂(V1)/∂x again?
 
  • #13
ok ∂(V1)/∂x= 6y
 
  • #14
∂(V1)/∂x = 6y i sorry I forgot the "i" in the previous post.
 
  • #15
DODGEVIPER13 said:
∂(V1)/∂x = 6y i sorry I forgot the "i" in the previous post.

What about ∂(-2xz)/∂x?
 
  • #16
6y-2z i
 
  • #17
DODGEVIPER13 said:
6y-2z i

Better.
Now, can you do the rest of grad V1?
 
  • #18
(6y-2z)i + (6x)j + (1-2x)k
 
  • #19
for V2 (10cos(phi))-z)i-(10sin(phi))j-(ρ)k
 
  • #20
for V3 ((-2/r^2)cos(phi))i-((2sin(phi))/(r^2sin(theta)))k
 
  • #21
DODGEVIPER13 said:
(6y-2z)i + (6x)j + (1-2x)k

Right!
 
  • #22
DODGEVIPER13 said:
for V2 (10cos(phi))-z)i-(10sin(phi))j-(ρ)k

Right, except you can't use i and j for the ρ and phi unit vectors. Since I don't know how to put hats over letters I would use 1ρ and 1Φ which is still standard.
 
  • #23
DODGEVIPER13 said:
for V3 ((-2/r^2)cos(phi))i-((2sin(phi))/(r^2sin(theta)))k

Problem here.
With V2 I noticed the angle phi was used; I believe for cylindrical coordinates that angle is usually denoted by theta.

So I have to assume phi is the same angle for V3 as it was for V2, i.e. the angle between the x-y plane and the z axis, in which case grad V3 looks wrong. Do you know which angle is the one made with the z axis and which is in the x-y plane? Then I could check grad V3 also.

Anyway, you seem to be with the program here and have done quite well.
 
  • #24
Theta is with the z and phi is with the xy
 
  • #25
DODGEVIPER13 said:
for V3 ((-2/r^2)cos(phi))i-((2sin(phi))/(r^2sin(theta)))k

Correct, except again you don't use i j k as unit vectors for spherical coordinates. Use 1r, 1φ and 1θ.

V2 shoud have used θ instead of φ. It's not good for φ to be the z-axis angle in one coordinate system and the x-y angle in another. I would explain that to your instructor.
 
  • Like
Likes 1 person

FAQ: Calculate the gradient of the function

1.

What is the definition of the gradient of a function?

The gradient of a function is a vector that shows the rate and direction of change of the function at a specific point. It is calculated by taking the partial derivatives of the function with respect to each variable.

2.

Why is calculating the gradient important?

Calculating the gradient is important because it allows us to determine the direction of steepest ascent or descent of a function at a given point. This is useful in optimization problems and in understanding the behavior of multivariable functions.

3.

How do you calculate the gradient of a function?

The gradient of a function is calculated by taking the partial derivatives of the function with respect to each variable and then combining them into a vector. For example, if the function is f(x,y,z), the gradient would be [∂f/∂x, ∂f/∂y, ∂f/∂z].

4.

What does the gradient vector represent?

The gradient vector represents the direction of the greatest increase of the function at a specific point. The magnitude of the vector represents the rate of change in that direction.

5.

Can the gradient of a function be negative?

Yes, the gradient of a function can be negative. This would indicate that the function is decreasing in that direction at that point. A positive gradient indicates an increase, and a gradient of zero indicates no change.

Back
Top