# Ampere's law and solenoids.

## Main Question or Discussion Point

When deriving the formula for the magnetic field of a solenoid it is said that the side of the rectangle outside and parallel to the solenoid can be ignored because it is taken far away and the contributions of the field outside is negligible.

But any arbitrary path can be taken and the results should be the same. So what if the fourth side was not taken to be sufficiently far away but instead close enough to the solenoid for the outside field to make an actual contribution? Wouldn't this result be different?

Related Classical Physics News on Phys.org
Since the circulation of the magnetic field around any loop that does not intersect the current is zero (by Ampere's Law) the position of the 4'th side does not matter.
This is because the near and far 4'th sides can be connected to make a loop that does not surround any the current.

The curl of the magnetic field is zero away from currents so its line integral over a loop that does not surround any current is zero.

So now I have another question. What I got from what you said is that basically a rectangle can be made outside the solenoid so that it does not enclose any current. Since the integral must be zero, the top and the bottom must be equal. The rectangle can be arbitrary size and since at infinity the field must be 0, the entire field must be uniformly zero.

Now consider just a plane of wires, each carrying charge away from the screen. Essentially the cross-section of an ideal solenoid without the other half.

x x x x x x x x x x x

The same argument can be said for the top and bottom of this plane. A rectangle can be made on top or bottom such that it does not enclose current, and the field must be uniformly zero on both sides. But clearly there must be a field?

Born2bwire
Gold Member
Ampere's Law states:
$$\oint_C \mathbf{B} \cdot \mathrm{d}\boldsymbol{\ell} = \mu_0 \iint_S \mathbf{J_f} \cdot \mathrm{d}\mathbf{S}$$

If no current is penetrating normal to our surface, than the line integral along the boundary of the surface of the magnetic flux density is zero. It does not say that the magnetic field is zero, only its integral along the boundary. Inside the ideal solenoid, the magnetic field is constant, pointing along the axial direction. Thus, the line integral will be zero for any closed line inside the solenoid. This can be seen by a choice of a rectangular surface. Only the two sides parallel to the axial direction will have a contribution (since the other sides are normal to the field) and the contributions will be equal and opposite since the field strength does not vary but the direction of the line integral reverses between the two sides.

the magnetic field is not zero, only its circulation around a loop that does not surround any current.

Note that the magnetic fields outside an infinitely long solenoid (having constant current) are zero magnitude. For a solenoid of finite length there will be some non zero field strength.

The field inside an infinitely long solenoid is

B = μ0nI, where nI is ampere-turns per meter.

The field inside near the end of a half-infinite solenoid is

B = μ0nI/2

Therefore, the field outside near the end is the same:

B = μ0nI/2

See Smythe "Static and Dynamic Electricity" 3rd edition page 297 for exact solution.

Bob S

Last edited: