Fiveable

🔋Electromagnetism II Unit 1 Review

QR code for Electromagnetism II practice questions

1.2 Gauss's law for magnetic fields

1.2 Gauss's law for magnetic fields

Written by the Fiveable Content Team • Last updated August 2025
Written by the Fiveable Content Team • Last updated August 2025
🔋Electromagnetism II
Unit & Topic Study Guides

Gauss's Law for Magnetic Fields

Gauss's law for magnetic fields captures a simple but profound fact: magnetic field lines always form closed loops. The total magnetic flux through any closed surface is exactly zero, which means there are no magnetic "charges" (monopoles) from which field lines begin or end. This is one of Maxwell's four equations and marks a key difference between how electric and magnetic fields behave.

Magnetic Flux

Magnetic Flux Through a Surface

Magnetic flux (ΦB\Phi_B) quantifies how much magnetic field passes through a given surface. You calculate it by integrating the magnetic field over the surface:

ΦB=SBdA\Phi_B = \int_S \vec{B} \cdot d\vec{A}

The dot product matters here. Flux depends not just on the field strength but on the angle between B\vec{B} and the surface normal dAd\vec{A}. A surface parallel to the field lines has zero flux through it, while a surface perpendicular to the field captures maximum flux.

Units of Magnetic Flux

  • The SI unit is the weber (Wb), equivalent to Tm2\text{T} \cdot \text{m}^2
  • Can also be expressed as volt-seconds (V·s)
  • Magnetic flux density is just another name for the magnetic field B\vec{B} itself, measured in teslas (T), representing flux per unit area

Integral Form of Gauss's Law

Closed Surface Integral

The integral form states that the net magnetic flux through any closed surface is zero:

SBdA=0\oint_S \vec{B} \cdot d\vec{A} = 0

Here B\vec{B} is the magnetic field and dAd\vec{A} is the outward-pointing area element on the closed surface SS. "Closed surface" means a surface that fully encloses a volume with no holes, like a sphere or a cube.

The physical meaning: every magnetic field line that enters the closed surface must also exit it. There's no net source or sink of B\vec{B} inside any volume you can draw.

Why the Net Flux Is Always Zero

Because magnetic monopoles don't exist, there's nothing inside any closed surface that can act as a net source of magnetic flux. Compare this to the electric case, where a charge inside the surface produces a nonzero net electric flux. For magnetic fields, the "enclosed magnetic charge" is always zero. That's the entire content of this law.

Differential Form of Gauss's Law

Magnetic flux through a surface, Explaining Gauss’s Law | CircuitBread

Divergence of the Magnetic Field

Applying the divergence theorem to the integral form gives the differential (local) version:

B=0\nabla \cdot \vec{B} = 0

The divergence B\nabla \cdot \vec{B} measures the net outward flux of B\vec{B} per unit volume at a point. Setting it to zero means magnetic field lines never start or stop at any point in space. They either form closed loops or extend to infinity in both directions.

This holds everywhere, at every point, not just on average over some surface. That's what makes the differential form more powerful for local analysis.

Absence of Magnetic Monopoles

In electrostatics, E=ρ/ϵ0\nabla \cdot \vec{E} = \rho / \epsilon_0, so electric field lines can originate on positive charges and terminate on negative charges. The magnetic analog would be a magnetic monopole, an isolated north or south pole.

No experiment has ever confirmed the existence of magnetic monopoles. Every magnet ever observed has both a north and south pole. Cut a bar magnet in half and you get two smaller dipoles, not an isolated north and a south. Gauss's law for B\vec{B} encodes this experimental fact directly.

Applications of Gauss's Law for Magnetic Fields

Checking Validity of Proposed Field Configurations

The most direct use of B=0\nabla \cdot \vec{B} = 0 is as a consistency check. If someone proposes a magnetic field configuration, you can compute its divergence. If it's nonzero anywhere, that field is unphysical.

Constraining Field Components

In problems with symmetry, B=0\nabla \cdot \vec{B} = 0 can eliminate certain components of B\vec{B}. For example, if you're analyzing a solenoid using a cylindrical Gaussian surface, the law tells you that the radial component of B\vec{B} must vanish (assuming translational symmetry along the axis). This simplifies the problem before you even apply Ampère's law.

A Note on Common Field Results

The well-known results for symmetric current distributions are actually derived using Ampère's law, not Gauss's law for B\vec{B}:

  • Infinite straight wire: B=μ0I2πrB = \frac{\mu_0 I}{2\pi r}
  • Solenoid interior: B=μ0nIB = \mu_0 n I

Gauss's law for B\vec{B} plays a supporting role in these derivations by constraining which components of the field can be nonzero, but the quantitative result comes from Ampère's law. Don't confuse the two on an exam.

Comparison to Gauss's Law for Electric Fields

Magnetic flux through a surface, Flux - Wikipedia

Similarities in Mathematical Form

Both laws are closed-surface integrals (or divergence equations):

Electric FieldsMagnetic Fields
Integral formSEdA=Qencϵ0\oint_S \vec{E} \cdot d\vec{A} = \frac{Q_{\text{enc}}}{\epsilon_0}SBdA=0\oint_S \vec{B} \cdot d\vec{A} = 0
Differential formE=ρϵ0\nabla \cdot \vec{E} = \frac{\rho}{\epsilon_0}B=0\nabla \cdot \vec{B} = 0

Key Differences in Physical Interpretation

  • Electric flux through a closed surface can be nonzero because electric charges (monopoles) exist. Magnetic flux is always zero because magnetic monopoles don't.
  • Electric field lines can begin and end on charges. Magnetic field lines must form closed loops.
  • Note: the claim that "electric fields are conservative while magnetic fields are not" is a separate issue from Gauss's law. Electrostatic fields are conservative (×E=0\nabla \times \vec{E} = 0 in statics), but this property relates to Faraday's law, not to the divergence equations.

Validity and Scope

This Law Is Always Valid

Unlike some approximations in electromagnetism, B=0\nabla \cdot \vec{B} = 0 holds universally in classical electromagnetism. It's valid for:

  • Static fields
  • Time-varying fields
  • Fields in vacuum or in matter
  • Any configuration whatsoever

This is worth emphasizing because it's sometimes mistakenly stated that Gauss's law for B\vec{B} only applies to static fields. That's incorrect. Even when fields are changing rapidly and Faraday's law produces induced electric fields, the magnetic field still has zero divergence at every instant. Maxwell's equations include B=0\nabla \cdot \vec{B} = 0 without any time-dependent modifications.

Role in Maxwell's Equations

One of Four Fundamental Laws

Gauss's law for magnetic fields is the second of Maxwell's four equations:

  1. Gauss's law for electric fields (E=ρ/ϵ0\nabla \cdot \vec{E} = \rho/\epsilon_0)
  2. Gauss's law for magnetic fields (B=0\nabla \cdot \vec{B} = 0)
  3. Faraday's law (×E=B/t\nabla \times \vec{E} = -\partial \vec{B}/\partial t)
  4. Ampère-Maxwell law (×B=μ0J+μ0ϵ0E/t\nabla \times \vec{B} = \mu_0 \vec{J} + \mu_0 \epsilon_0 \, \partial \vec{E}/\partial t)

Connection to the Other Equations

Gauss's law for B\vec{B} is actually consistent with Faraday's law in an interesting way. Take the divergence of both sides of Faraday's law:

(×E)=t(B)\nabla \cdot (\nabla \times \vec{E}) = -\frac{\partial}{\partial t}(\nabla \cdot \vec{B})

The left side is identically zero (divergence of any curl vanishes). So (B)/t=0\partial(\nabla \cdot \vec{B})/\partial t = 0, meaning if B=0\nabla \cdot \vec{B} = 0 at any one time, it stays zero forever. The structure of Maxwell's equations is self-consistent in preserving the absence of magnetic monopoles.

Pep mascot
Upgrade your Fiveable account to print any study guide

Download study guides as beautiful PDFs See example

Print or share PDFs with your students

Always prints our latest, updated content

Mark up and annotate as you study

Click below to go to billing portal → update your plan → choose Yearly → and select "Fiveable Share Plan". Only pay the difference

Plan is open to all students, teachers, parents, etc
Pep mascot
Upgrade your Fiveable account to export vocabulary

Download study guides as beautiful PDFs See example

Print or share PDFs with your students

Always prints our latest, updated content

Mark up and annotate as you study

Plan is open to all students, teachers, parents, etc
report an error
description

screenshots help us find and fix the issue faster (optional)

add screenshot

2,589 studying →