# Charge density in terms of (r,θ) but need it in terms of the vector r'

1. Nov 8, 2009

### darkpsi

1. The problem statement, all variables and given/known data
A sphere of radius R, centered at the origin, carries charge density
ρ(r,θ) = (kR/r2)(R - 2r)sinθ,
where k is a constant, and r, θ are the usual spherical coordinates.
Find the approximate potential for points on the z axis, far from the sphere.

2. Relevant equations
potential of the dipole
V(r,θ) = 1/4πεo * 1/r2 ∫ r'cosθ' ρ(r') dτ'

3. The attempt at a solution
I just want to know why I'm giving the charge density in terms of r and θ and yet I need it in terms of r'. I know that the vector r' is related to θ' by r' = rcosθ'
So I tried to say that since θ is the inclination from the xy plane and θ' is the angle between r and r' so that θ'+θ = π/2. Then that would give me
sinθ = [(π/2))-θ'] = cosθ'
Since the direction of r' is cosθ' I thought maybe I could replace r with r'?
so maybe
ρ(r',θ') = (kR/r'2)(R - 2r')cosθ' so
ρ(r') = (kR/r'2)(R - 2r') ?????

Last edited: Nov 8, 2009
2. Nov 8, 2009

### jdwood983

Looks to me that you are confusing yourself on a simple matter. When inside the integral, it is often convenient to use primed-coordinates to separate from the original matter. If you had

$$V(r,\theta)=\frac{1}{4\pi\varepsilon_0}\,\frac{1}{r^2}\int r\cos[\theta]\rho(r)d\tau$$

it might confuse you because your limits of integration would also be in terms of $r$ and $\theta$. The prime markers just show that, inside the integrand, $r'$ is slightly different from $r$, but does become $r$ after integration; this way you have

$$V(r,\theta)=\frac{1}{4\pi\varepsilon_0}\,\frac{1}{r^2}\int r'\cos[\theta']\rho(r')d\tau'$$

to tell the difference between what needs to be integrated and what is already taken care of through integration.

3. Nov 8, 2009

### darkpsi

so in ρ(r,θ) = (kR/r2)(R - 2r)sinθ, r and θ are bascially r' and θ'?
when I integrate it that way I'm getting
∫ r'cosθ' kR(R-2r')sin2θ' dr'dθ'dφ'
then integrating ∫sin2θ' cosθ' dθ' I get
1/3sin3θ' (0 -> pi) which gives me zero.
And the answer is supposed to be
V(z) = 1/4πεo kπ2R5/(24z2)

4. Nov 8, 2009

### gabbagabbahey

What makes you think that?...I also get that the monopole and dipole terms both vanish, and so the dominant term will be the quadrapole term....

5. Nov 8, 2009

### darkpsi

But then the answer I'm supposed to be aiming for is wrong? At least I know maybe my qudrapole term wasn't wrong then, and maybe it's right?
3πkR5/64εoz3 ?
I got the anwser that it is suppose to be of this website http://einstein1.byu.edu/~masong/emsite/S2Q50/S2Q50.html

Last edited by a moderator: Apr 24, 2017
6. Nov 8, 2009

### gabbagabbahey

That's a pretty sketchy website to be looking for homework solutions...the answer they give doesn't even have the correct units, so that should be a dead giveaway that something is wrong.

7. Nov 8, 2009

### darkpsi

Here goes:

V(r,θ) = 1/4πεo * 1/r3 ∫∫∫0R (3/2 cos2θ' - 1/2) kRsin2θ' (Rr'2 - 2r'3) dr'dθ'dφ'

= 1/4πεo * 1/r3 ∫∫0π (3/2 cos2θ' - 1/2) kRsin2θ' (-1/6 kR4) dθ'dφ'

| Using 3/2 cos2θ'(cos2θ' - 1)
| = 3/2 (cos4θ' - cos2θ')
| = 3/2 [(1/2 + 1/2cos2θ')2 - cos2θ']

= 1/4πεo * 1/r3 ∫∫0π [3/2 [(1/2 + 1/2cos2θ')2 - cos2θ'] sin2θ' (-1/6 kR4) dθ'dφ'

= 1/4πεo * 1/r3 ∫∫0π 3/2[(1/4 + 1/2cos2θ' + 1/4cos22θ')- cos2θ'] -1/2sin2θ' (-1/6 kR4) dθ'dφ'

= 1/4πεo * 1/r3 (-1/6 kR4) ∫0( 3/2[(θ'/4 + 1/4sin2θ' + θ'/8 + 1/16sin2θ')] - 1/2(θ'/2 - 1/4sin2θ'|0π dφ'

| Since all the sine terms are zero I got

= 1/4πεo * 1/r3 (-1/6 kR4) ∫0( 3/2[(θ'/4 + θ'/8)] - 1/2(θ'/2)|0π dφ'

= 1/4πεo * 1/r3 (-1/6 kR4) ∫0 3/2(-3/8π) dφ'

= 1/4πεo * 1/r3 (-1/6 kR4) 3/2(-3/8π) * 2π

= 3πkR5 / 64εor3 |r=z

= 3πkR5 / 64εoz3

I think there may be a mistake in my use of the half-angle identity?

8. Nov 8, 2009

### gabbagabbahey

Why are you using this?

$$\left(\frac{3}{2}\cos^2\theta'-\frac{1}{2}\right)=\frac{1}{2}(3\cos^2\theta'-1)=\frac{1}{2}[3(1-\sin^2\theta')-1]=1-\frac{3}{2}\sin^2\theta'\neq\frac{3}{2}\cos^2\theta'(\cos^2\theta'-1)$$

9. Nov 8, 2009

### darkpsi

Because I was distributing the sin2 to just that term and then trying to solve that integral. But I see that you're way is much easier. Thanks!