# Homework Help: Gradient of (1/r)

1. Sep 11, 2014

### physics12

1. The problem statement, all variables and given/known data

gradient(1/r) = r(hat) / r^2

2. Relevant equations
r = (x-x')i + (y-y')j + (z-z')k

2. Sep 11, 2014

### ShayanJ

gradient(1/r) = -r(hat) / r^2

3. Sep 11, 2014

### physics12

how do you prove that?

4. Sep 11, 2014

### ShayanJ

In spherical coordinates, the gradient of a scalar function f is:
$\vec\nabla f(r, \theta, \phi) = \frac{\partial f}{\partial r}\hat r+ \frac{1}{r}\frac{\partial f}{\partial \theta}\hat\theta+ \frac{1}{r \sin\theta}\frac{\partial f}{\partial \phi}\hat\phi$.
And we have $\frac{d}{dr}\frac 1 r=-\frac{1}{r^2}$.

5. Sep 11, 2014

### physics12

can this be done in cartesian coordinates?

6. Sep 11, 2014

### HallsofIvy

Or, in Cartesian coordinates,
$$\frac{1}{r}= \frac{1}{x^2+ y^2+ z^2}= (x^2+ y^2+ z^2)^{-1/2}$$

$$\left(\frac{1}{r}\right)_x= -\frac{1}{2}(x^2+ y^2+ z^2)^{-3/2}(2x)= -\frac{rcos(\theta)sin(\phi)}{r^3}= -\frac{1}{r^3} (rcos(\theta)sin(\phi))$$

$$\left(\frac{1}{r}\right)_y= -\frac{1}{2}(x^2+ y^2+ z^2)^{-3/2}(2y)= -\frac{rsin(\theta)sin(\phi)}{r^3}= -\frac{1}{r^3} (rsin(\theta)sin(\phi)($$

$$\left(\frac{1}{r}\right)_z= -\frac{1}{2}(x^2+ y^2+ z^2)^{-3/2}(2z)= -\frac{rcos(\phi)}{r^3}= -\frac{1}{r^3} (rcos(\phi))$$

So that $$\nabla \frac{1}{r}= -\frac{1}{r^3}\vec{r}= -\frac{1}{r^2}\frac{\vec{r}}{r}= -\frac{1}{r^2}\hat{r}$$

Where $\hat{r}$ is the unit vector in the direction of $\vec{r}$.

Last edited by a moderator: Sep 11, 2014