The field outside the solenoid, which is not zero
Assumes: The field that wraps a current · The field with no ends, and the force that does no work
The derivation is one of the tidiest in the subject. Take a rectangular loop with one side inside the solenoid and one outside, apply Ampère’s law, note that the two short sides contribute nothing because the field there is perpendicular to them, and conclude that the difference between the inside and outside fields is . Then argue that the outside field must fall to zero far away and is the same everywhere outside by symmetry, so it is zero everywhere outside, so the inside field is and is uniform.
Nothing in that is wrong. It is a proof about an object that does not exist.
This essay computes what a finite winding actually does, and the interest is not that the textbook answer is wrong. It is that the three quantities the answer is usually quoted with — zero outside, uniform inside, half at the mouth — approach their ideal values at three different rates, and one of them cannot approach it at all without destroying the thing that makes a solenoid a magnet.
Where the infinity gets in
The rectangular-loop argument uses Ampère’s law twice, and Ampère’s law is exact both times. What it also uses, silently — as every symmetry argument in electrostatics does, is that the field outside is the same at every distance — otherwise a loop entirely outside the winding, with its two long sides at different radii, would enclose no current and yet return a nonzero circulation.
That sameness is a translation symmetry along the axis, and a finite winding does not have it. Slide a rectangular loop along a real solenoid and the field it encloses changes, because the loop gets nearer an end. So the step that turns “the difference between inside and outside is ” into “the outside is nothing” is the step that assumes the answer, and it is available only in the limit.
It is worth being precise about where the residue outside comes from, because “the field cancels” is the sentence that does the damage. Each turn on its own makes a field that wraps it, and outside the winding the contributions from neighbouring turns point in nearly opposite directions. Nearly, and not exactly: the cancellation between a turn and its neighbour is a subtraction of two large numbers that differ slightly, because the two turns are at slightly different distances from the point being asked about. What survives is a small residue rather than nothing, and it is largest near the ends, where a turn has a neighbour on one side only and so has nothing to cancel against on the other. That is the whole mechanism, and it is why the leak is an end effect: the middle of a long winding really is quiet, and the mouths are where the field gets out.
The flux has to come back
The rectangular-loop argument uses one of the four equations and never touches the one that settles the question. says the flux out of any closed surface is nothing at all. Wrap a cylinder round the middle of the winding, its two flat lids far out along the axis on either side and its curved wall at some radius outside the turns. The lids sit where the field has already become a dipole’s, falling as the inverse cube while their area grows only as the square, so what crosses them can be made as small as one likes by pushing them further out. Everything else leaves through the wall.
That is a conservation law, and it fixes a quantity rather than a shape. The flux running up the bore at the middle is — for a 5:1 winding, times the bore area — and every line of it is outside the winding somewhere. The aspect ratio decides how much room that return has, and nothing else. Lengthening a coil deletes no line; it hands the same bundle a longer object to get round, so the same flux is spread over more of the wall and the field at any one place on it is smaller. An inverse square is what that spreading looks like when it is written down, which is why the exponent measured below is a piece of geometry rather than a fitted curiosity.
The infinite solenoid escapes the constraint by having no outside in the sense that matters. Its return path has been sent to infinite radius, where unlimited room holds a finite flux at zero density, and a field of zero over an infinite area is a perfectly good way to carry . That is a legitimate limit and it is not a small idealisation: it is the whole of the difference between the derivation and the object. The same accounting is what makes a field’s energy something stored in space rather than in the wire, and the energy outside a real winding is the same flux counted a second way.
What the sum gives on the axis
Nothing below uses Ampère’s law. Each turn is a circular current, its field at a point is Biot–Savart integrated round the ring, and the winding’s field is the sum. On the axis the result can be checked against a closed form got by integrating the single-loop expression along the winding — a route that shares no arithmetic with a sum of three-dimensional cross products — and the two agree to five hundredths of a per cent.
Two familiar statements come out of that figure with their conditions attached.
“The field inside is ” is good to a per cent at five to one and to five parts in a thousand at ten to one. It is a statement about the middle: near the mouth the field is falling, and it has fallen to half by the time it reaches the end plane.
“The field at the end is half the field in the middle” is exact only in the limit and approached from above. At one to one it is 0.632, which is not half by any reading. The reason the half is so nearly right so quickly is that it comes from a symmetry rather than from a size: at the end plane the winding subtends a solid angle on one side and nothing on the other, so a long solenoid’s end sees exactly half of what its middle sees.
Outside: not zero, and falling as the inverse square of the length
The quantity the derivation gets most wrong is the one it is most confident about. Sampling the mid-plane at a fixed number of radii off the axis, and asking how the field there depends on how long the winding is, gives a power law rather than a vanishing.
An inverse square is a slow way to reach zero. Doubling the length of a winding buys a factor of four in how quiet it is outside; getting from a part in a hundred to a part in a million takes a factor of a thousand in length. That is the honest cost of magnetic screening by geometry alone, and it is why real apparatus screens with iron or with a return path instead.
Quieter nearby, louder far away
The two measurements this essay makes outside the winding pull in opposite directions, and the pull is worth stating plainly, because “a longer solenoid leaks less” is true only in the region where it was measured.
At the mid-plane, a couple of radii off the axis, the field falls as . Far away on the axis, the same winding is a point dipole of moment ; at a fixed turn density , so the moment is proportional to the length, and a dipole’s field at a fixed distance is proportional to its moment. Doubling the length of a winding at constant , and therefore divides the near-outside field by four and multiplies the far field by two. Both numbers are in the figures above, arrived at independently, and neither is a correction to the other.
There is no contradiction because there is one conserved quantity behind both. The return flux is being reshaped and not removed. Pushing it further from the mid-plane is what makes the near outside quiet; stretching the two ends further apart is precisely what makes the dipole moment large. So a coil built to be magnetically inconspicuous is built against a distance, and the distance has to be named before the design question means anything. The measurement two radii out and the measurement forty lengths out are not two estimates of one number.
The crossover between them is where the probe stops being close compared with the length and starts being far. The second leak figure shows its near edge directly: at four radii out the two-pole fit does not begin until 12:1, where at two radii it began at 6:1, because what the fit needs is . That the generator refuses to fit outside its window rather than returning a number is the same discipline a falloff exponent needs everywhere — an exponent read off the wrong range of distances is a measurement of the range.
What the loop argument does prove
Throwing the derivation away would be the wrong lesson, because the rectangular loop still constrains a finite winding. It constrains it more weakly, and the weaker statement is exact.
Take a closed loop lying entirely outside the winding, enclosing no turns. Ampère’s law returns zero circulation round it, for a real solenoid of any length whatever. That is not a claim that the field vanishes. It is a claim that the external field is conservative — that throughout the current-free region it is the gradient of a single scalar, in the way an electrostatic field is, so that one number at every point carries all of it. Which is what licenses the two-end picture used above: poles are sources of a potential, and without the circulation result there would be no potential for them to be sources of.
What the infinite case adds on top is the translation symmetry, and the symmetry is doing all of the remaining work. It says the gradient cannot depend on where along the axis it is measured, and a gradient that is the same everywhere and dies at large radius is zero everywhere. Remove the symmetry and the first half survives untouched while the second half has nothing left to stand on. A finite solenoid still has a scalar potential outside it. The potential simply has structure, and the structure is the two ends.
That is the standard shape of the mistake, and it is not particular to magnetism: the law is exact, the symmetry is an extra assumption smuggled in beside it, and the sentence that fails is the one after the law rather than the law itself. Gauss’s law has the same character — true for every charge distribution there is, and useful only where something independent of it says the field is constant over the surface.
Far away it is exactly a dipole, and that is the point
Follow the axis out past the end and the winding’s identity dissolves into a single number.
This is where the “confinement” claim and the “it is a magnet” claim collide. A magnetic moment is defined by the far field, in the way a dipole’s own lines define it; a body with no external field has no moment; a body with no moment feels no torque in an applied field and exerts none on anything else. So a solenoid that really had zero field outside could not be used as a magnet at all — could not deflect a compass, could not attract iron, could not be weighed in a gradient. The external field is not a leak from an otherwise perfect device. It is the device’s output.
What the ideal picture is still for
None of this makes the infinite solenoid a bad idealisation. It makes it a good one with a stated domain, which is the more useful object.
Start from a single loop and the point makes itself. One loop’s field is a dipole almost everywhere: there is no interior region where anything is uniform, and no aspect ratio to improve, because a loop has no length to be long compared with. Stacking loops is the entire manoeuvre, and what it buys is the uniform interior. What it does not buy, at anything like the same rate, is the absence of an exterior. The uniformity arrives long before the outside field becomes negligible — at five to one the interior is already within two per cent of while the exterior is still 1.6 per cent of the centre value — so a winding that is plainly “long enough” by the measure a designer usually has in mind is nothing of the kind by the other.
The two errors have different sizes and different signs, and knowing which matters decides the design. Both fall as roughly the inverse square of the aspect ratio — the interior shortfall runs 0.29, 0.019, 0.0050, 0.0013 at 1:1, 5:1, 10:1 and 20:1, and the exterior field runs 0.073, 0.017, 0.0041, 0.00086 — so a winding built long enough for one purpose is usually long enough for the other, and the design question is which of the two numbers the application can actually afford. What no amount of care in the winding changes is the exponent. Screening by length alone is an inverse square, and an inverse square is a slow road to a part in a million. A coil that has to produce a known field inside — a calibration coil, a magnetic-resonance bore, a Zeeman slower — cares about the interior number and can reach a part in a thousand at 20:1. A coil that must not disturb something nearby cares about the exterior number, which at 20:1 is still a part in a thousand of the centre field and falls only as the square of any further lengthening.
There is a practical consequence when a winding has to share its flux with something else, and it is the same arithmetic seen from the other end. The flux rule relates the emf in a coil to the flux threading it, and it carries no term at all for flux that got away — so any line that leaves one winding without entering the other is simply absent from the calculation. On a transformer that absence has a name and a number: it is the leakage inductance, and its size is set by exactly the geometry measured above. The rule is not wrong about the coil it is applied to. It is silent about where the rest of the field went, which is a different failing and a harder one to notice, because nothing in the calculation is missing — the calculation is complete and describes a smaller object than the one on the bench.
The number that decides most designs is not either field on its own but the ratio between them, and that ratio is what an aspect ratio actually buys. At 5:1 the interior is within two per cent of and the exterior two radii out is 1.6 per cent of the centre value, so the two are comparable; at 20:1 the interior shortfall is 0.0013 and the exterior 0.00086, so they have stayed comparable. Twenty-fold more winding has improved both by roughly the same factor and changed nothing about which of them dominates. A design that needs one of the two numbers three orders of magnitude better than the other cannot get there by lengthening at all, which is the practical content of the two errors sharing an exponent.
Where the model stops
Three limits, in increasing order of how easy they are to forget.
The winding is not a current sheet. Everything here treats each turn as a circular filament, which smooths the helical pitch away. A real helix carries a current along the axis as well as around it, and that component makes a field circling the solenoid outside — a component the sheet model has exactly zero of, and which does not fall with aspect ratio at all. It is cancelled in practice by a return wire brought back along the axis, which is why careful coils are wound that way.
The turns are evenly spaced. The uniformity of the interior is a statement about the winding density. A coil with a gap in it has a dip; a coil wound more densely at the ends can be made more uniform than an evenly wound one of the same length, which is the whole trick behind a compensated solenoid.
A “solenoid” long enough is a different object. The interior of a very long winding is uniform, and the ends are far away — but the field lines that leave one end still have to reach the other, and they do it through the whole of the surrounding space. The energy stored outside a 20:1 winding is a small fraction of the total and it is not a negligible one, and it is the reason the inductance of a finite solenoid is less than : the standard correction, Nagaoka’s coefficient, is 0.92 at 5:1 and 0.98 at 20:1, and it is exactly the accounting for flux that does not thread every turn.
And nothing here has any matter in it. Put iron inside — a material whose own moments align, as a magnet’s do — and the interior field is no longer but something set by the iron’s magnetisation, which is a material’s answer to a field rather than a geometric fact. The external field is then dominated by where the iron’s flux path goes, and the aspect-ratio argument above is replaced by a question about the magnetic circuit.
The rung after this one
Ampère’s law has been used here on a static current and found to be exactly true and not quite enough. The next rung is the case where it is not exactly true: a current that stops, in a circuit with a gap in it, where two surfaces bounded by the same loop give two different answers. That contradiction has a repair, the repair adds a term, and the term turns four equations into a wave — which is the argument the neighbouring ladder starts from.
The difficulty never arose here because this essay’s solenoid was steady, and a steady current is the one case where the two surfaces cannot disagree. A solenoid being switched on has the problem in full — and it is worth carrying away that the field such a winding throws outside itself while switching is a great deal larger than the static residue computed here. Every number in this essay is a statement about a coil that has settled down.
Part 2 of 5
This essay is one argument about Ampere law. The others:
What links here
Essays that reach for this one mid-argument — the half of a link its own author cannot write down.
The objects named here
The third axis, after the field and the reading path: the things themselves, and every essay that touches each one.
Amperes lawBoundary conditionsDipole radiationField linesFluxIdealisationMagnetic fieldMagnetic fluxMagnetic momentSolenoidSuperpositionSymmetry
- The angular momentum that is not a rotation magnetic moment, superposition, symmetry
- The charge that has to be somewhere else boundary conditions, field lines, superposition
- The field that makes the other, and only while it is changing field lines, flux, magnetic field
- The field that points against the magnet it is in boundary conditions, flux, magnetic field
- The force read off a surface that touches nothing flux, magnetic field, superposition
- A potential that does not come back to itself boundary conditions, magnetic field