Uniformly Charged Rod of Finite Length
A uniformly charged straight wire of negligible thickness has length $L$ and carries charge $Q>0$.
Given: useful antiderivative
\int{\frac{dx}{{\left(x^2+a^2\right)}^{3/2}}}=\frac{x}{a^2\sqrt{x^2+a^2}}
1. Determine the direction and magnitude of the electric field created by the finite-size wire at point $P$ which is a distance $d$ from the wire along the perpendicular bisector.
View answerThe charge $Q$ is continuously distributed along the rod and we therefore consider the contribution of an infinitesimal portion $dx$ with infinitesimal charge $dQ=\lambda dx$.
By symmetry, we conclude that the net electric field at point $P$ is directed along the $y$-axis and has no horizontal component. Indeed, for any (red) infinitesimal charge $dQ$ located on the left side of the rod, an equivalent (green) infinitesimal charge $dQ$ can be found on the right side of the rod. When considering the infinitesimal electric fields they create at point $P$, we conclude that their horizontal components cancels and that, therefore, the net electric field at point $P$ has no horizontal component and is vertical (upward). We therefore only seek to compute the $y$-component of the electric field at point $P$.
To derive the net electric field at point $P$, we consider one of the charges $dQ$ and argue that it creates an infinitesimal field $d\overrightarrow{E}$ with a $y$-component $dE_y$ given by:
dE_y=dE{\mathrm{cos} \left(\theta \right)\ }=\frac{kdQ}{x^2+h^2}\cdot {\mathrm{cos} \left(\theta \right)\ }
Recalling that ${\mathrm{cos} \left(\theta \right)\ }=h/\sqrt{x^2+h^2}$ and $dQ=\lambda dx$, we conclude that the $y$-component of the infinitesimal electric field $d\overrightarrow{E}$ is equal to
dE_y=\frac{kdQ}{x^2+h^2}\cdot {\mathrm{cos} \left(\theta \right)\ }=\frac{\lambda kh}{{\left(x^2+h^2\right)}^{3/2}}dx
To find the magnitude $E_y$ of the electric field, we integrate $dE_y$ over $x$ from $x=-L/2$ to $x=L/2$ which yields
\begin{aligned} E_y&=\int^{L/2}_{-L/2}{\frac{\lambda kh}{{\left(x^2+h^2\right)}^{3/2}}dx} \\ \\ &=\lambda kh\cdot {\left.\frac{x}{h^2\sqrt{x^2+h^2}}\right|}^{L/2}_{-L/2} \\ \\ &=\frac{\lambda k}{h}\left(\frac{L}{2\sqrt{h^2+L^2/4}}-\frac{-L}{2\sqrt{h^2+L^2/4}}\right) \\ \\ &=\frac{\lambda kL}{h\sqrt{h^2+L^2/4}} \end{aligned}
The electric field created by the finite length wire at point $P$ is equal to
\boxed{\overrightarrow{E}=\frac{\lambda kL}{h\sqrt{h^2+L^2/4}} \ \ \hat{y}=\frac{kQ}{h\sqrt{h^2+L^2/4}} \ \ \hat{y}}