# Spherical coordinates vector question

1. Oct 23, 2011

### renlok

I've no idea where to put this question but here it is im trying to work through the examples our lecture has given in class and I wasn't getting them at all
the first thing that confused me was $\nabla . \underline{r} = 3$ I tried this myself with $\nabla . \underline{r} = \frac{1}{r^2}\frac{\delta{r^2}}{\delta{r}} = \frac{2}{r}$ (working in spherical coords)
but if you use $\textbf{e_r} = \frac{\textbf{r}}{r}$ it works but I have no idea where this comes from could someone at least point me in the right direction that would be really helpful thanks

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

2. Relevant equations

3. The attempt at a solution

2. Oct 23, 2011

### BruceW

You should try to use the template. But oh well.

You've had a go at using spherical coordinates - yep that's one way to do it. But I think you've done it wrong. When the function is purely radial (as it is in your case), the divergence is equal to:

$$\frac{1}{r^2} \frac{\partial}{\partial r} (r^2 F)$$
(where F is the magnitude of the vector function in question). For your problem, F=r.