# Homework Help: Divergence of F and plot.

1. Sep 12, 2014

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

2. Relevant equations

∇.F(r)

3. The attempt at a solution

I keep trying to plug F into the divergence theorem but end up with very ugly answers that I know are not right.

Is there a simple way to do this question? Also, how the heck would I plot this for for the specified function values! thanks! help with the flux would be appreciated to.

2. Sep 12, 2014

### Staff: Mentor

Your starting equation should be the equation for the divergence of an arbitrary vector in spherical coordinates. What is that equation?

Chet

3. Sep 12, 2014

### Staff: Mentor

Can you show us your approach and what you did to get ugly answers for the divergence?

Did you use spherical coordinates? and the spherical variant of the divergence operator?

http://en.wikipedia.org/wiki/Del_in_cylindrical_and_spherical_coordinates

For plotting you could use MATLAB or FreeMat (a free clone of MATLAB).

For the flux you have to integrate over the whole surface of the sphere. If you recall the surface of a sphere