Ampere's Circuital Law — Field Inside a Solenoid

hard CBSE JEE-MAIN JEE Advanced 2023 4 min read

Question

A long solenoid has nn turns per unit length and carries current II. Using Ampere’s Circuital Law, derive the magnetic field BB inside the solenoid.

This is a classic derivation that JEE Advanced and CBSE Class 12 both love — it tests whether you understand why we choose a particular Amperian loop, not just the final formula.


Solution — Step by Step

A solenoid is a tightly wound helix of wire. For a long solenoid, the field outside is essentially zero, and the field inside runs parallel to the axis (along z^\hat{z}). This is the physical picture we exploit.

We pick a rectangular loop ABCDABCD straddling the solenoid wall. Side ABAB (length LL) lies inside the solenoid along the axis. Side CDCD lies outside. The two short sides BCBC and DADA are perpendicular to the axis.

Why this shape? Because B\vec{B} is parallel to ABAB and perpendicular to BCBC, DADA. That kills off two sides immediately.

Ampere’s law states:

Bdl=μ0Ienc\oint \vec{B} \cdot d\vec{l} = \mu_0 I_{\text{enc}}

We go around ABCDABCD:

  • Side AB (inside, field =B= B, length =L= L): contribution =BL= BL
  • Side CD (outside, field 0\approx 0): contribution =0= 0
  • Sides BC and DA (Bdl\vec{B} \perp d\vec{l}): contribution =0= 0

So: Bdl=BL\oint \vec{B} \cdot d\vec{l} = BL

The loop encloses the portion of the solenoid of length LL. Number of turns in this length =nL= nL. Each turn carries current II, so:

Ienc=nLII_{\text{enc}} = nLI

Plugging into Ampere’s law:

BL=μ0nLIBL = \mu_0 \cdot nLI B=μ0nI\boxed{B = \mu_0 n I}

The LL cancels — beautiful. The field is uniform inside and independent of position along the axis.


Why This Works

The power of Ampere’s law is symmetry exploitation. We don’t compute the contribution of each tiny current loop separately (that would be Biot-Savart, and it’s brutal for a solenoid). Instead, we pick a loop where the integral is either trivially zero or trivially BLBL.

The assumption that Boutside=0B_{\text{outside}} = 0 deserves scrutiny. For a real solenoid of finite length, the outside field isn’t exactly zero — but for a long solenoid (length \gg radius), it’s negligible. JEE problems always specify “long solenoid” for exactly this reason.

Also notice that BB depends on nn (turns per unit length), not the total number of turns or the total length separately. A solenoid twice as long with twice as many turns has the same BB — because nn stays constant.


Alternative Method

You can also arrive at B=μ0nIB = \mu_0 n I by integrating the Biot-Savart result for a circular loop along the solenoid axis. Treat the solenoid as an infinite stack of rings, each carrying current II, with ndxn\,dx turns in a length dxdx.

The field on the axis of a single circular loop of radius RR at its centre is μ0I2R\frac{\mu_0 I}{2R}. Summing over all rings with proper geometry and integrating from -\infty to ++\infty gives the same B=μ0nIB = \mu_0 n I.

This method works, but takes two pages of integration. That’s why Ampere’s law is the preferred route in exams — same answer, one-tenth the effort.

JEE Advanced often asks you to find BB at the end of a semi-infinite solenoid. The answer there is μ0nI2\frac{\mu_0 n I}{2} — exactly half. Think about it: only half the infinite solenoid contributes.


Common Mistake

Students write Ienc=II_{\text{enc}} = I instead of Ienc=nLII_{\text{enc}} = nLI. They forget that multiple turns pass through the Amperian loop. Each of the nLnL turns is a separate wire carrying current II, so the total enclosed current is their sum. Ampere’s law counts total current threading the loop — not current per wire.

This single error drops the nn from your answer, giving B=μ0I/LB = \mu_0 I / L, which has wrong dimensions of μ0×current/length\mu_0 \times \text{current} / \text{length}… actually the same dimensions, which is why students don’t catch it immediately. But plugging in numbers will give a wildly wrong magnitude.

Want to master this topic?

Read the complete guide with more examples and exam tips.

Go to full topic guide →

Try These Next