The Physics UniverseOpen the review site
AP Physics C: Electricity and Magnetism · Unit 12 · Topic 4 of 4 · 6 min lesson

Ampère’s Law

A short lesson with diagrams, a worked example, a problem to try, and a quick check. Then quiz yourself on 5 practice questions.

The big idea

Ampère’s law is the magnetic version of Gauss’s law: around any closed loop, ∮B · dl = μ0Ienc. When symmetry makes B constant along a well-chosen loop, it gives B in one line: wires, cylinders, solenoids and toroids.

1. Using the law

∮B · dl = μ0Iencany closed path
B = μ0Ienc/(2πr)anything with cylindrical symmetry
Ienc = ∫J dA = ∫J 2πr drnon-uniform current
B = μ0nIinside a long solenoid; n = turns per meter
B = μ0NI/(2πr)inside a toroid
μ0I/(2πR) inside B ∝ r outside: B ∝ 1/r R 2R 3R B r
A solid wire with uniform current: only the current inside radius r counts, so B grows linearly inside and falls as 1/r outside.

2. Choosing the loop

Wires and cylinders: use a circle centered on the axis. B is tangent and constant on it, so ∮B · dl = B(2πr).

Uniform current inside a wire: Ienc = I(r²/R²), so B = μ0Ir/(2πR²).

Solenoid: use a rectangle with one side inside. The outside field is nearly zero, so BL = μ0(nL)I.

Zero enclosed current means zero B only with symmetry: outside a coaxial cable carrying equal and opposite currents, B = 0; inside a hollow tube, B = 0.

3. Example, then try it

Example

A 0.30 m solenoid has 900 turns. What current makes a 0.012 T field inside it?

n = 900 ÷ 0.30 = 3000 turns/m.

I = B/(μ0n) = 0.012 ÷ [(4π × 10⁻⁷)(3000)] ≈ 3.2 A.

Try it · work it on paper first

A long wire of radius R carries current with density J = J0(1 − r/R): strongest at the center, zero at the surface. Find the total current and B inside the wire.

1

Enclosed current: Ienc = ∫0r J0(1 − r′/R) 2πr′ dr′ = 2πJ0(r²/2 − r³/3R).

2

Total (r = R): I = 2πJ0(R²/2 − R²/3) = πJ0R²/3.

3

Ampère: B(2πr) = μ0Ienc → B = μ0J0(r/2 − r²/3R).

4

Check: at r = R, B = μ0J0R/6 = μ0I/(2πR), matching the outside formula.

Answer: I = πJ0R²/3; B = μ0J0(r/2 − r²/3R) inside.

4. Common mistakes

Using the total current at every r.Only the current inside the loop counts.
Using total turns N for a solenoid.Use n = N/L, turns per meter.
Applying Ampère’s law without symmetry.It’s always true, but only useful when B is constant on the loop.
Check yourself

A long solenoid’s length is doubled with the same number of turns and the same current. What happens to the field inside?

B = μ0nI, and n = N/L halves when L doubles.

Ready to practice?

5 questions on Ampère’s Law, each with a hint and an explanation for every wrong answer.

Unit 12 topics

Every topic has a short lesson or quick review and its own quiz.