Evaluate the divergence of the following vector fields
(a) A= XYUx+Y^2Uy-XZUz
(b) B= ρZ^2Up+ρsin^2(phi)Uphi+2ρZsin^2(phi)Uz
(c) C= rUr+rcos^2(theta)Uphi
Don't know if this post is still important to you since it's a little old, but your expression for the divergence in polar coordinates is incorrect, as there are extra factors in the formula (it's not the same as you would in Cartesian). Take another look at it.