Static electric fields are supposed to be conservative in nature and therefore give $0J$ work if traversed over a loop. However in the following problem I got non zero work by a static electric field. How can I explain this work ?

enter image description here
Note : This is done in field of line charge, diagram shows a cuboid type structure but that is just for differentiating between traversed path and line charge.

I am writing some of the important parts/equations here, but I have written the whole derivation here. $$W_{AB} = \frac{q\lambda}{4\pi\epsilon_0} [ln|\frac{(\sqrt{(L)^2+(r_1)^2}+L)(r_1)}{(\sqrt{(\frac{L}{2})^2+(r_1)^2}+\frac{L}{2})^2}|]$$

$$W_{BC} = \frac{q\lambda}{4\pi\epsilon_0}[ln|\frac{(\sqrt{(\frac{L}{2})^2+(r_1)^2}+(\frac{L}{2}))(r_2)}{(\sqrt{(\frac{L}{2})^2+(r_2)^2}+(\frac{L}{2}))(r_1)}|]$$

$$W_{CD} = \frac{q\lambda}{4\pi\epsilon_0} [ln|\frac{(\sqrt{(\frac{L}{2})^2+(r_2)^2}+\frac{L}{2})^2}{(\sqrt{(L)^2+(r_2)^2}+L)(r_2)}|]$$

$$W_{DA} = \frac{q\lambda}{4\pi\epsilon_0}[ln|\frac{(\sqrt{(L)^2+(r_2)^2}+(L))(r_1)}{(\sqrt{(L)^2+(r_1)^2}+(L))(r_2)}|]$$


$$W = \frac{q\lambda}{4\pi\epsilon_0} [ln|\frac{(\sqrt{(\frac{L}{2r_2})^2+1}+\frac{L}{2r_2})}{(\sqrt{(\frac{L}{2r_1})^2+1}+\frac{L}{2r_1})}|]$$

If field were to behave conservatively $W=0$ must have been satisfied, but unless $r_1 = r_2$, $W \neq 0$. Thus field is not behaving conservatively.

PS : This is not a homework question ! I am trying to explain the behaviour.

  • 2
    $\begingroup$ I haven't gone over the math in detail but as I don't see any vector notation anywhere it's a fair guess you mixed up the direction of the field somewhere. $\endgroup$
    – Kvothe
    Jan 20, 2014 at 19:07
  • $\begingroup$ I have checked it a few times, and I prefer to check the direction first and then do calculations based on magnitude since during the 4 paths direction is constant. $\endgroup$ Jan 20, 2014 at 19:22
  • 1
    $\begingroup$ And where is the origin of $x$ (and its direction)? You don't show the derivation of $W_{DC}$ and $W_{CB}$. It's already hard to follow due to all the roots, don't make it even worse. This is the math version of spaghetti code. $\endgroup$
    – Kvothe
    Jan 20, 2014 at 19:46
  • $\begingroup$ @Kvothe: Please read the question and link again I have tried my best to make it simple and detailed ! $\endgroup$ Jan 25, 2014 at 0:36
  • $\begingroup$ I think your equations for $E_{\bot}$ and $E_{\parallel}$ are incorrect. The derivation of the equation on hyperphysics.phy-astr.gsu.edu/hbase/electric/elelin.html does have sine and cosine terms (yes they are with respect to different angles than your diagram) but there's still an extra factor of $z^{-1}$! I also tried to calculate the divergence of your field and got $((p+x)^2+y^2)^{-1/2}-((p-x)^2+y^2)^{-1/2}$ where $p=L/2$ (by plugging in dot/cross product formulas for the sine and cosine), indicating there's a space charge. $\endgroup$
    – user12029
    Jan 25, 2014 at 3:53

3 Answers 3


The electrical field of a line charge is a potential field.

In the following we use cylindrical coordinates $\vec{r}(z,\alpha,r)$.

If the line charge lies along the $z$-axis from $z=-L/2$ up to $z=L/2$ then the potential is $$ \varphi(\vec{r}(r,\alpha,z)) = \frac\lambda{4\pi\epsilon_0}\ln\left(\frac{\frac L2-z+\sqrt{\left(\frac L2-z\right)^2+r^2}}{\frac L2+z+\sqrt{\left(\frac L2+z\right)^2+r^2}}\right) $$ See, e.g., http://hyperphysics.phy-astr.gsu.edu/hbase/electric/potlin.html#c1. The work done by a point charge $q$ gone from point $\vec{r}_1$ to $\vec{r}_2$ is $$ W(\vec{r}_1,\vec{r}_2) = q(\varphi(\vec{r}_2)-\varphi(\vec{r}_1)) $$ If the path is closed we have $\vec{r}_2=\vec{r}_1$ and $W(\vec{r}_1,\vec{r}_2)=0$. Therefore, your calculation must be wrong.

Note, that the existence of the potential for the electrical field follows from the path-independence of the integral over the field-strength only the start point and the end point of the path are relevant.

The path independence of the integral follows from the zero circulation of the field which follows from the zero curl and the simple path-connectedness of the domain of definition for the field. (Every path can be continuously contracted to a point.)

You find this stuff in all elementary books on electrostatics.

The zero-circulation of the static E-field is a consequence of Faraday's law $$ \def\vr{{\vec{r}}}\def\vp{{\vec{p}}}\def\vE{{\vec{E}}}\def\vB{{\vec{B}}}\def\vA{{\vec{A}}} \def\cD{{\mathcal{D}}} \def\nR{{\mathbb{R}}} \oint_{\partial A} \vE(\vr,t) d \vA = \frac{d}{dt} \int_{A} \vB(\vr,t) d t $$ where $A$ is a surface within the spatial domain of definition $\cD$ of the electrostatic field. We assume that $\cD$ is simply path-connected.

If the flux density $\vB(\vr,t)$ and the area $A$ are time-independent then the right-hand side is zero. This directly shows that the circulation of the static E-field is zero: $$ \oint_{\partial A} \vE(\vr,t) d \vA = \vec{0}. $$ If we have two non-intersecting paths $\vp_1:[0,l_1]\rightarrow \cD,\vp_2:[0,l_2]\rightarrow \cD$ each running from $\vr_1\in\cD$ to $\vr_2\in\cD$ then the path $\vp_3:[0,l_1+l_2]\rightarrow\cD$ with $\vp_3(s):=\vp_1(s)$ for $s\in[0,l_1]$ and $\vp_3(s):=\vp_2(l_1+l_2-s)$ for $s\in[l_1,l_1+l_2]$ is closed. The simple path-connectedness essentially means that we find an oriented surface $A$ within $\cD$ such that $\vp_3$ parameterizes the oriented boundary of $A$ ($\vp_3 = \partial A$). Therefore, $$ \int_{\vp_1}\vE(\vr)\cdot d \vr -\int_{\vp_2}\vE(\vr)\cdot d \vr = \oint_{\vp_3}\vE(\vr)\cdot d \vr = \oint_{\partial A}\vE(\vr)\cdot d \vr = 0 $$ with Faraday's law. Thus the integral $$ \int_{\vp}\vE(\vr)\cdot d\vr $$ only depends on the start point $\vr_1$ and the end point $\vr_2$ of the path $\vp$ which gives the notation $$ \int_{\vp}\vE(\vr)\cdot d\vr = \int_{\vr_1}^{\vr_2}\vE(\vr)\cdot d\vr $$ its sense. With the electrostatic potential $$ \varphi(\vr) := -\int_{\vr_0}^{\vr}\vE(\vr)\cdot d\vr $$ one can express the electrical work integral for a path $\vp$ running from $\vr_1$ to $\vr_2$ as $$ W(\vp) = q(\varphi(\vr_2)-\varphi(\vr_1)) $$ The electrostatic field for a line charge is derived from Maxwell's equations including Faraday's law and some symmetry-considerations.

So, all said holds for the field of a line charge.

Just to clarify your question:

What you want to do is to take the hard way and show for some special closed paths that the circulation over these paths is zero.

Maybe, this is fine for educational reasons.

You made a mistake and ask us to show you where it is.

$\def\vE{{\vec{E}}}\def\ve{{\vec{e}}} \def\l{\left}\def\r{\right}\def\eps{\varepsilon} \def\di{{\mathrm{d}}} \def\uuline#1{{\underline{\underline{#1}}}} \def\const{\operatorname{const}}$

To increase your trust into the theory of electrostatic fields I calculated the electrical work done over yor special closed path. The result is zero, as expected. The text is self-contained.

Calculation of the field of the line charge:

Definition of angles for the E-field calculation and the projections of the E-field onto the axes

Calculation of $\vE=E_\perp\cdot \ve_\perp+E_\parallel\cdot \ve_\parallel$. Parametrization of the integration path (the line charge): $$ z=r\cdot \tan(\gamma) $$ $$ \di z= r\frac{\di \gamma}{\cos^2(\gamma)} $$

Electrical field strength $\di E$ caused by a charge element $\di Q = \lambda \di z$: $$ \di E = \frac{\lambda\di z}{4\pi\eps \l(\frac{r}{\cos(\gamma)}\r)^2} $$ $$ = \frac{\lambda r\di \gamma}{4\pi\eps \l(\frac{r}{\cos(\gamma)}\r)^2 \cos^2(\gamma)} $$ $$ = \frac{\lambda \di \gamma}{4\pi\eps r} $$ Perpendicular component: $$ \di E_\perp = \frac{\lambda \cos(\gamma)\di \gamma}{4\pi\eps r} $$ $$ E_\perp = \frac{\lambda}{4\pi\eps r} \int_{-\alpha}^\beta \cos(\gamma)\di \gamma $$ $$ E_\perp = \uuline{\frac{\lambda}{4\pi\eps r}(\sin(\beta)+\sin(\alpha))} $$ Parallel component: $$ \di E_\parallel = \di E\cdot \sin(\gamma) = \frac{\lambda \sin(\gamma)\di \gamma}{4\pi\eps r} $$ $$ E_\parallel = \frac{\lambda}{4\pi\eps r} \int_{-\alpha}^\beta \sin(\gamma)\di \gamma = \frac{\lambda}{4\pi\eps r}\left[-\cos(\gamma)\right]_{\gamma=-\alpha}^{\beta} $$ $$ E_\parallel = \uuline{\frac{\lambda}{4\pi\eps r}(\cos(\alpha)-\cos(\beta))} $$ Axi-symmetric coordinates (alias cylinder-coordinates) with origin in the middle of the line charge for the point of field strength measurement: The height of the point is $z$ and the distance from the axis of the point is $r$. For brevity we define $a=\frac L2$. $$ \sin(\alpha)= \frac{a-z}{\sqrt{(z-a)^2 + r^2}} $$ $$ \sin(\beta) = \frac{z+a}{\sqrt{(z+a)^2 + r^2}} $$ $$ \cos(\alpha)= \frac{r}{\sqrt{(z-a)^2 + r^2}} $$ $$ \cos(\beta) = \frac{r}{\sqrt{(z+a)^2 + r^2}} $$ Therewith, the field strength becomes $$ E_r=\frac{\lambda}{4\pi\eps r}\l(\frac{a-z}{\sqrt{(z-a)^2 + r^2}} + \frac{z+a}{\sqrt{(z+a)^2 + r^2}}\r), $$

$$ E_z=\frac{\lambda}{4\pi\eps r}\l(\frac{r}{\sqrt{(z-a)^2 + r^2}}-\frac{r}{\sqrt{(z+a)^2 + r^2}}\r). $$


Some useful indefinite integrals: $$ \int \frac{\di x}{\sqrt{1+x^2}} \overset{\underbrace{x=\sinh(\xi)}}{=} \int \frac{\cosh(\xi)\di \xi}{\sqrt{1+\sinh^2(\xi)}} = \int\di \xi=\xi = \sinh^{-1}(x)+C $$ $$ = \ln(x+\sqrt{1+x^2})+C. $$ Now, we solve

$$ \int \frac{\di x}{x\sqrt{1+x^2}}. $$ for $x>0$ using the bijective substitutions $x=\sinh(\xi)$ with $\xi>0$ and $\xi = \ln(\eta)$ with $\eta>1$ $$ \int\frac{\di x}{x\sqrt{1+x^2}} =\int \frac{\cosh(\xi)\di\xi}{\sinh(\xi)\sqrt{1+\sinh(\xi)^2}} =\int\frac{\di\xi}{\sinh(\xi)} $$ $$ =\int\frac{2\di \xi}{e^\xi - e^{-\xi}} = \int\frac{2e^\xi\di\xi}{(e^\xi)^2 - 1} =\int\frac{2\di\eta}{\eta^2-1}=\l(\int\frac{\di\eta}{\eta-1}-\int\frac{\di\eta}{\eta+1}\r) $$ $$ = \ln\l|\frac{\eta-1}{\eta+1}\r| + C $$ with $x = \sinh(\ln(\eta))=\frac12\l(\eta+\frac1\eta\r)$ and $\eta=x \pm \sqrt{x^2 + 1}$ where $\eta=x-\sqrt{x^2+1}$ is a spurious solution since is does not satisfy the condition $\eta>1$. That leaves us with $\eta=x+\sqrt{x^2+1}$. $$ \int\frac{\di x}{x\sqrt{1+x^2}} = \ln\l|\frac{x-1+ \sqrt{x^2 + 1}}{x +1+ \sqrt{x^2 + 1}}\r| $$ For the integrals in $r$-direction we use in the two cases $z\neq \pm a$ the terms $$ \int \frac{a\mp z}{r\sqrt{(a\mp z)^2 + r^2}} \di r = \int\frac{\di\l(\frac{r}{a\mp z}\r)}{\frac{r}{(a\mp z)}\sqrt{1+\l(\frac{r}{a\mp z}\r)^2}} $$ $$ = \ln\l|\frac{\l(\frac{r}{a\mp z}\r)-1+ \sqrt{\l(\frac{r}{a\mp z}\r)^2 + 1}}{\l(\frac{r}{a\mp z}\r) +1+ \sqrt{\l(\frac{r}{a\mp z}\r)^2 + 1}}\r| $$ For $z=0$ both cases $\mp$ in the above integral evaluate to the same result $\ln\l|\frac{r/a-1+\sqrt{\l(r/a\r)^2+1}}{r/a+1+\sqrt{\l(r/a\r)^2+1}}\r|$.

For the integrals in $z$-direction we use the terms (note, $r>0$): $$ \int \frac{\di z}{\sqrt{(z\mp a)^2 + r^2}} = \int \frac{\di \l(\frac{z\mp a}{r}\r)}{\sqrt{\l(\frac{z\mp a}{r}\r)^2+1}} + \const $$ $$ = \ln\l(\frac{z\mp a}{r}+\sqrt{\l(\frac{z\mp a}{r}\r)^2 + 1}\r)+\const $$

Now, we continue with the actual field calculation:

Path for the calcultion of the electrical work

Path from $(r,z)=(r_1,0)$ to $(r_1,-a)$: $$ W_{BA}=\int_{0}^{-a} qE_z(r_1,z) \di z $$ $$ = \frac{q\lambda}{4\pi\eps}\int_{z=0}^{-a}\l(\frac{1}{\sqrt{(z-a)^2 + r^2}}-\frac{1}{\sqrt{(z+a)^2 + r^2}}\r)\di z $$ $$ =\frac{q\lambda}{4\pi \eps}\Biggl( \underbrace{\ln\l| - L/r_1 + \sqrt{ (L/r_1)^2 + 1} \r|}_{\stackrel{\textstyle z=-a}{\textstyle\text{term with }z+a\text{ vanishes}}} - \underbrace{\ln\l| \frac{ -a/r_1 + \sqrt{(a/r_1)^2 + 1}}{a/r_1+\sqrt{(a/r_1)^2+1}} \r|}_{z=0} \Biggr) $$ Similar path from $(r_2,-a)$ to $(r_2,0)$: $$ W_{DC}=\int_{-a}^{0} qE_z(r_2,z) \di z = \frac{q\lambda}{4\pi\eps}\Biggl( \underbrace{\ln\l| \frac{ -a/r_2 + \sqrt{(a/r_2)^2 + 1}}{a/r_2+\sqrt{(a/r_2)^2+1}} \r|}_{z=0} - \underbrace{\ln\l| - L/r_2 + \sqrt{ (L/r_2)^2 + 1} \r|}_{z=-a} \Biggr) $$ The sum $W_{BA}+W_{DC}$ can be expressed as difference of two terms which result from a common general term in dependence of the variable $r$ once with $r=r_1$ and once with $r=r_2$: $$ W_{BA}+W_{DC}=\frac{q\lambda}{4\pi\eps} \ln\l| \frac{\l(\sqrt{L^2 + r^2}- L\r)\l(a+\sqrt{a^2+r^2}\r)}{r(\sqrt{a^2 + r^2}-a)} \r|_{r=r_2}^{r_1} $$ Path from $(r_2,0)$ to $(r_1,0)$: $$ W_{CB}=\int_{r_2}^{r_1} qE_r(r,0) \di r $$ $$ =\frac{q\lambda}{4\pi\eps}\int_{r_2}^{r_1}\frac{2 a\di r}{r\sqrt{a^2 + r^2}} $$ $$ =\frac{q\lambda}{4\pi\eps}\cdot 2 \ln\l|\frac{r/a-1+\sqrt{\l(r/a\r)^2+1}}{r/a+1+\sqrt{\l(r/a\r)^2+1}}\r|_{r=r_2}^{r_1} $$ $$ =\frac{q\lambda}{4\pi\eps}\ln\l|\frac{\l(r/a-1+\sqrt{\l(r/a\r)^2+1}\r)^2}{\l(r/a+1+\sqrt{\l(r/a\r)^2+1}\r)^2}\r|_{r=r_2}^{r_1} $$ Path from $(r_1,-a)$ to $(r_2,-a)$ (The integral with $a+z$ in the integrand vanishes.): $$ W_{AD} = \int_{r_1}^{r_2} qE_r(r,-a) \di r $$ $$ = \frac{q\lambda}{4\pi\eps}\int_{r_1}^{r_2}\l( \frac{L}{r\sqrt{L^2 + r^2}} \r)\di r $$ $$ = \frac{q\lambda}{4\pi\eps} \ln\l|\frac{r/L-1+\sqrt{(r/L)^2+1}}{r/L+1+\sqrt{(r/L)^2+1}}\r|_{r=r_1}^{r_2} $$ To adapt the term to the other ones we exchange the integral bounds: $$ W_{AD}=\frac{q\lambda}{4\pi\eps} \ln\l|\frac{r/L+1+\sqrt{(r/L)^2+1}}{r/L-1+\sqrt{(r/L)^2+1}}\r|_{r=r_2}^{r_1} $$ Overall work: $$ W = W_{BA}+W_{AD}+W_{DC}+W_{CB} $$ The terms for $r_1$ and $r_2$ must vanish separately. $$ W=\frac{q\lambda}{4\pi\eps}\ln\l|\frac{ (\sqrt{L^2+r^2}-L)(a+\sqrt{a^2+r^2}) % W_BA (r+L+\sqrt{r^2+L^2}) % W_AD (r-a+\sqrt{r^2+a^2})^2 }{ r(\sqrt{a^2+r^2}-a) % W_BA (r-L+\sqrt{r^2+L^2}) % W_AD (r+a+\sqrt{r^2+a^2})^2 } \r|_{r=r_2}^{r_1} $$ We investigate the factors with $r,a$ in the numerator: $$ (a+\sqrt{a^2+r^2})(r-a+\sqrt{r^2+a^2})^2=\l(r(a+\sqrt{a^2+r^2})+(\sqrt{a^2+r^2}+a)(\sqrt{a^2+r^2}-a)\r)(r-a+\sqrt{r^2+a^2}) $$ $$ =\l(r(a+\sqrt{a^2+r^2})+(r^2+a^2-a^2)\r)(r-a+\sqrt{r^2+a^2}) $$ $$ =r\l(a+\sqrt{a^2+r^2}+r\r)(r-a+\sqrt{r^2+a^2}) $$ and now the factors with $r,a$ in the denominator: $$ r(\sqrt{a^2+r^2}-a)(r+a+\sqrt{r^2+a^2})^2= r(r(\sqrt{a^2+r^2}-a)+(\sqrt{r^2+a^2}+a)(\sqrt{a^2+r^2}-a))(r+a+\sqrt{r^2+a^2}) $$ $$ =r\l(r\l(\sqrt{a^2+r^2}-a\r)+a^2+r^2-a^2\r)\l(r+a+\sqrt{r^2+a^2}\r) $$ $$ =r^2\l(\sqrt{a^2+r^2}-a+r\r)\l(r+a+\sqrt{r^2+a^2}\r) $$ Now we investigate the remaining factors with $L,r$ in the numerator: $$ (\sqrt{L^2+r^2}-L)(r+L+\sqrt{r^2+L^2})= r(\sqrt{L^2+r^2}-L) + (\sqrt{L^2+r^2}-L)(L+\sqrt{r^2+L^2}) $$ $$ = r(\sqrt{L^2+r^2}-L) + L^2+r^2 - L^2 $$ $$ = r(\sqrt{L^2+r^2}+r-L) $$ This is just the remaining term with $L,r$ in the denominator multiplied by $r$ which matches the superfluous $r$ in the result of the $r,a$-terms.

Each term in the numerator has a counterpart in the denominator. The quotient becomes 1 and $\ln(1)$ is zero.

Overall, we get $W=0$, as expected.

  • $\begingroup$ In your link they have simply summed up potential or point charges they have not checked what is happening over different paths. I know what must happen but both intuitively and mathematically I am getting something else ! $\endgroup$ Jan 20, 2014 at 22:44
  • $\begingroup$ Actually on the contrary I want to show that there is some discrepancy and work done over closed path is not zero every time. I have quite a few more examples but this was the one with easiest maths to write down, I have some with ideal electric fields which point in one direction and decreases linearly too. And wanted some insight on how to explain what I am obtaining ! $\endgroup$ Jan 21, 2014 at 16:55
  • $\begingroup$ I tried reading it a few times, still seem to get tangled in the mathematics ! Please check the link once again that I have provided in my answer, I have changed the derivation there and made it a bit more detailed. If you can find some fault with it, please tell. $\endgroup$ Jan 25, 2014 at 0:28
  • $\begingroup$ I have multiplied the missing charge $q$ to the work integrals. Sorry for this error. $\endgroup$
    – Tobias
    Jan 25, 2014 at 7:01
  • $\begingroup$ I know it sounds petty but I am interested in knowing if something is wrong with my derivation or not. I am not really interested in other derivations of the same thing. $\endgroup$ Jan 25, 2014 at 9:33

A first check which serves to narrow the error in the overall calculation down: It turns out that $W_{AB}=-W_{BA}$ holds with the value for $W_{AB}$ from your formulas and $W_{BA}$ from the answer above even if it does not look like that at the first glance.

From your formulas: $$ W_{AB} = \frac{q\lambda}{4\pi\epsilon_0} \ln\left(\frac{\left(\sqrt{L^2+r_1^2}+L\right)r_1}{\left(\sqrt{\left(\frac{L}{2}\right)^2+r_1^2}+\frac{L}{2}\right)^2}\right) $$ From my solution above: $$ W_{BA} = \frac{q\lambda}{4\pi \epsilon}\ln\left(\frac{\left(\sqrt{\left(\frac L2\right)^2+r_1^2}+\frac L2\right)\left(\sqrt{L^2+r_1^2}-L\right)}{\left(\sqrt{\left(\frac L2\right)^2+r_1^2}-\frac L2\right)r_1}\right) $$ Note, that to see that $W_{AB}=-W_{BA}$ with the above mentioned values it suffices to show $$ \frac{\left(\sqrt{L^2+r_1^2}+L\right)}{\left(\sqrt{\left(\frac L2\right)^2+r_1^2}+\frac L2\right)}=\frac{\left(\sqrt{\left(\frac L2\right)^2+r_1^2}-\frac L2\right)}{\left(\sqrt{L^2+r_1^2}-L\right)} $$ which becomes evident after multiplying both sides of the equation with both denominators.

Could you please compare the following integral to yours and check? Thanks. $$ W_{BC} = \frac{q\lambda L}{4\pi\epsilon_0}\int_{r_1}^{r_2}\frac{d r}{r\sqrt{\left(\frac L2\right)^2+r^2}} $$ You did not explicate the calculation of the integral on your page therefore I can only guess what you did.

The factor $\frac 2L$ looks suspicious in the next equation in comparison to your version. It results from extracting the coefficient $\frac L2$ from the square root. I think you wrote $\frac 1{2L}$ instead in your formulas. $$ W_{BC}=\frac{q\lambda L}{4\pi\epsilon_0}\frac 2L\int_{r_1}^{r_2}\frac{d \left(\frac{2r}{L}\right)}{\frac{2r}L\sqrt{1+\left(\frac{2r}{L}\right)^2}} $$ This time I am using the indefinite integral delivered by http://www.integral-calculator.com/#expr=1%2F%28x%2Asqrt%281%2Bx%5E2%29%29. $$ W_{BC}=\frac{q\lambda L}{4\pi\epsilon_0}\frac 2L\left[-\sinh^{-1}\left(\frac1{\left(\frac{2r}{L}\right)}\right)\right]_{r=r_1}^{r_2} $$ Next, I am using the $\sinh^{-1}$ in the form given at http://en.wikipedia.org/wiki/Inverse_hyperbolic_function (the form I gave in my answer above is equivalent). I also multiply the factor $\frac 2L$ into the first quotient. $$ W_{BC}=\frac{q\lambda}{2\pi\epsilon_0}\left[-\ln\left(\frac{L}{2r}+\sqrt{\left(\frac{L}{2r}\right)^2+1}\right)\right]_{r=r_1}^{r_2} $$ Applying the limits gives: $$ W_{BC}=\frac{q\lambda}{2\pi\epsilon_0}\ln\left( \frac{ r_2\left(\frac L2 + \sqrt{\left(\frac L2\right)^2+r_1^2}\right) }{ r_1\left(\frac L2 + \sqrt{\left(\frac L2\right)^2+r_2^2}\right) } \right) $$ Up to a factor 2 this is what you have.

Please, allow me also a remark on the electrical field $\vec{E}= \vec{e}_x k y$ which you investigate at this page. This nicely fits into your question.

It is possible to construct an electromagnetic field with this electrical field. Faraday's law requires $$ \def\rot{\operatorname{rot}}\def\div{\operatorname{div}} \dot{\vec{B}} = - \rot \vec{E} = \vec{e}_z k. $$ Note, that the constructed elecromagnetic field must be time-variable and cannot be static.

An appropriate ansatz for the B-field is $\vec B=\vec{e}_z k t$. This B-field is source free ($\div{B}=0$) since it does not depend on the space-variables. Furthermore, with the material laws $$\vec{B}=\mu_0 \vec{H}$$, $$\vec{D} = \epsilon_0 \vec{E}$$ and $$\vec{J}=0$$ of vacuum Ampere's law (including Maxwell's term) $$ \rot{H} = \dot{\vec{D}} + \vec{J} $$ is also satisfied. Thus the ansatz really leads to an electromagnetic field. But this electromagnetic field is not static and therefore the associated E-field does not fit the definition of an electrostatic field.

A word on the idealized nature of this field seems to be appropriate. The restriction of the discussed electromagnetic field to some bounded domain can be a good approximation of a real field (for an example a section of the electromagnetic field within the gap of a large electromagnet in the first phase after switching it on). To deal with the field in full space eases the calculation.

Note to the readers beside Rijul Gupta: This answer has undergone excessive editing and error correction. Please, look into the edit history to follow the comments.

  • $\begingroup$ If you change $(L-x)^2$ with $(x-L)^2$ then integration will give $ln|x-L+\sqrt{(x-L)^2 + (r_1)^2}|$ on applying the limits it will also give the result I have obtained. Please see to this mistake of yours. $\endgroup$ Jan 25, 2014 at 9:26
  • $\begingroup$ I really was sloppy here and did make a mistake. I have corrected this. Thanks for the hint. But, there is also a mistake in your calculation. See my corrected answer. $\endgroup$
    – Tobias
    Jan 25, 2014 at 10:45
  • $\begingroup$ You cannot simply compare two indefinite integrals ! Not without their constants. Your equation of equality has to be $ln|\sqrt{(L-x)^2+(r_1)^2}+L-x|+C_1 = ln|\sqrt{(x-L)^2+(r_1)^2}+x-L| +C_2$. Which gives $r_1 = e^{\frac{C_1-C_2}{2}}$.Otherwise you can apply limits and compare or differentiate and compare. Please check your work Again ! $\endgroup$ Jan 25, 2014 at 10:53
  • $\begingroup$ I have added the integration constant. It does not really matter. $\endgroup$
    – Tobias
    Jan 25, 2014 at 12:02
  • $\begingroup$ Did you even see my comment ? You are supposed to add integration constants for both sides ! You can't just suppose one of the constants to be 0, and on what basis you say $C_2 \neq 0$ ? $\endgroup$ Jan 25, 2014 at 12:05

To reiterate on Tobias's answer:

The potential induced by a line charge extending from $(L_1,0)$ to $(L_2,0)$ is $$\phi(x,y)=\log \left(\frac{\sqrt{\left(L_2-x\right){}^2+y^2}+L_2-x}{\sqrt{\left(L_1-x\right){}^2+y^2}+L_1-x}\right)$$ which is nonsingular over the loop you drew. But then $W=\oint_\Gamma \mathbf{E}d\mathbf{s}=\oint_\Gamma\nabla\phi d\mathbf{s}=0$ since the loop $\Gamma$ is closed, and the work over the loop vanishes.

Would you like me to try to figure out where the mistake in your derivation is? I was going to do this, but your expressions for $W_{AB}$ etc have $r_1,r_2$ etc in them, but these don't show up in your diagram that you drew. It'd be a lot easier if you wrote your answer in terms of the things that you drew in your diagram.

  • $\begingroup$ That is a writing thing, the distances marked on the right vertically are $r_1$ and $r_2$. Anyway I have figured out the mistake it was of a division factor of 2 in $W_{BC}$ Thank you anyways ! $\endgroup$ Feb 8, 2014 at 5:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.