# Electric field of half a wire

I am trying to calculate the electric field of a half wire in polar coordinates. At $y=R$ is a wire going from $-\infty$ to $0$ with charge density $\rho$.

I want to calculate the electric field at $(0,0)$

$$\vec{E} = \frac{1}{4\pi\epsilon_0} \int_{0}^{-\infty} dx \; \frac{\rho}{r^2} \hat{r}$$

My idea was to integrate over the angle $\theta$ from $0$ to $\pi/2$. Then I get $\vec{r} = \frac{R}{\cos \theta} \hat{\theta}$ and my integral is

$$\vec{E} = \frac{1}{4\pi\epsilon_0} \int_{0}^{\pi/2} d\theta \; \frac{\rho \cos^2 \theta}{R^2} \hat{\theta}$$

How do I solve this integral? I don't know what to do with $\hat{\theta}$ and what the resulting direction of the field is. Any suggestions?

• Do you REALLY have to place the origin in a random point in space? You see, obviously the electric fielf such a wire produces will have a cylindrical symmetry around the line the wire extends along. So you place the origin where the wire ends, align the $z$-axis with wire and then only have E as a function of $z$ and $\rho$ May 27, 2014 at 11:36
• I mean, if you have to calculate the electric field of a wire in the exact configuration depicted above, with wire running at the distance $R$ from the origin, there is no point in using cylindical coordinated. May 27, 2014 at 11:40
• Calculate separately for the horizontal and vertical direction - adding an additional sin or cos term.then it should be easy to do the integrals followed by a vector sum. May 27, 2014 at 11:52

Try itegrating over $\theta$ for the two components of the field, along $x$ and $y$ axes. So the integral equals $$E_x\propto\int_{0}^{\pi/2} \cos^2\theta \sin\theta d\theta = \int_{0}^{\pi/2} \frac12\sin{2\theta} \sin\theta d\theta = \int_{0}^{\pi/2} \frac14(\cos\theta - \cos{3\theta}) d\theta$$ $$E_y\propto\int_{0}^{\pi/2} \cos^3\theta d\theta = \int_{0}^{\pi/2} (\cos3\theta + \cos\theta\sin^2\theta )d\theta = \int_{0}^{\pi/2} (\cos3\theta + \cos\theta\frac{1-\cos2\theta}2)d\theta = \int_{0}^{\pi/2} (\cos3\theta + \frac{\cos\theta}2 - \frac14\cos3\theta -\frac14cos\theta)d\theta = \int_{0}^{\pi/2} (\frac34\cos3\theta + \frac14\cos\theta)d\theta$$
$$E_x\propto\int_{0}^{\pi/2} \cos^2\theta \sin\theta d\theta =-\int_{o}^{\pi/2} \cos^2\theta d\cos\theta =-\big[\frac13\cos^3\theta\big]_0^{\pi/2}=\frac13$$
• Yes - I figured that anyone who could write these integrals didn't actually need my suggestion to do so. Good work. ;-). But why not do the first integral directly as $\frac13 cos^3\theta$ - since the $sin\theta$ is just begging for you to do that... May 27, 2014 at 14:45