Fiveable

🔋Electromagnetism II Unit 1 Review

QR code for Electromagnetism II practice questions

1.6 Continuity equation

1.6 Continuity equation

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

Continuity equation overview

The continuity equation expresses charge conservation in mathematical form. It connects how charge density changes over time to how current density flows through space. In an Electromagnetism II course, this equation is essential because it acts as a consistency condition on Maxwell's equations and constrains the allowed forms of E\vec{E} and B\vec{B} fields in dynamic situations.

Charge conservation principle

Electric charge is never created or destroyed. It can only move from one place to another. This means the total charge in any isolated system stays constant over time.

The continuity equation is the mathematical statement of this fact. Rather than just saying "charge is conserved," it tells you exactly how the local redistribution works: any decrease in charge somewhere must be accounted for by current flowing outward.

Kirchhoff's current law

Kirchhoff's current law (KCL) is a direct consequence of charge conservation applied to circuit nodes. It states that the sum of currents entering any node equals the sum of currents leaving it. In other words, charge doesn't pile up at a junction. KCL is really just the continuity equation applied to a lumped-circuit element where you treat each node as a small volume with no charge accumulation.

Mathematical formulation

The continuity equation can be written in two equivalent forms. The differential form is a local statement (valid at every point), while the integral form is a global statement (valid over a finite volume).

Differential form

ρt+J=0\frac{\partial \rho}{\partial t} + \nabla \cdot \vec{J} = 0

  • ρ\rho is the volume charge density (C/m³)
  • J\vec{J} is the current density (A/m²)
  • J\nabla \cdot \vec{J} is the divergence of the current density

The physical meaning: if J>0\nabla \cdot \vec{J} > 0 at some point, current is diverging away from that point, so the local charge density must be decreasing (ρ/t<0\partial \rho / \partial t < 0). The equation enforces a strict balance between these two quantities at every point in space and at every instant.

Integral form

ddtVρdV=SJdA\frac{d}{dt} \int_V \rho \, dV = -\oint_S \vec{J} \cdot d\vec{A}

  • VV is any closed volume you choose
  • SS is the surface bounding that volume
  • dAd\vec{A} points outward by convention

The left side is the rate of change of total charge inside VV. The right side is the net inward current through the surface SS (the minus sign accounts for the outward convention of dAd\vec{A}). You can derive this from the differential form by integrating over VV and applying the divergence theorem to the J\nabla \cdot \vec{J} term.

Derivation sketch:

  1. Start with ρt+J=0\frac{\partial \rho}{\partial t} + \nabla \cdot \vec{J} = 0.
  2. Integrate both sides over a volume VV: VρtdV+VJdV=0\int_V \frac{\partial \rho}{\partial t} \, dV + \int_V \nabla \cdot \vec{J} \, dV = 0.
  3. Apply the divergence theorem to the second integral: VJdV=SJdA\int_V \nabla \cdot \vec{J} \, dV = \oint_S \vec{J} \cdot d\vec{A}.
  4. Rearrange to get the integral form above.

Physical interpretation

Relationship between charge and current

Current density J\vec{J} describes the charge flowing through a surface per unit area per unit time. The continuity equation ties this flow to the time evolution of ρ\rho: wherever current diverges outward, charge depletes; wherever current converges inward, charge accumulates.

A useful way to think about it: imagine a small box in space. If more current leaves the box than enters it (positive divergence), the charge inside must be dropping. If more enters than leaves (negative divergence), charge is building up.

Local vs. global conservation

  • Local conservation (differential form): charge is conserved at each point. No teleportation of charge is allowed; it must flow continuously through space.
  • Global conservation (integral form): the total charge inside any volume changes only because of current crossing the boundary.

Local conservation is the stronger statement. Global conservation follows from it, but not the other way around. A theory could conserve total charge globally while allowing charge to vanish at one point and appear at another. The continuity equation rules this out.

Kirchhoff's current law, Kirchhoff's circuit laws - Wikipedia

Continuity equation in electromagnetism

Deriving the continuity equation from Maxwell's equations

The continuity equation isn't an independent postulate. You can derive it directly from Maxwell's equations:

  1. Start with the Ampère-Maxwell law: ×B=μ0J+μ0ϵ0Et\nabla \times \vec{B} = \mu_0 \vec{J} + \mu_0 \epsilon_0 \frac{\partial \vec{E}}{\partial t}.
  2. Take the divergence of both sides. The left side vanishes because the divergence of any curl is identically zero: (×B)=0\nabla \cdot (\nabla \times \vec{B}) = 0.
  3. This gives: 0=μ0J+μ0ϵ0t(E)0 = \mu_0 \nabla \cdot \vec{J} + \mu_0 \epsilon_0 \frac{\partial}{\partial t}(\nabla \cdot \vec{E}).
  4. Use Gauss's law (E=ρ/ϵ0\nabla \cdot \vec{E} = \rho / \epsilon_0) to substitute: 0=μ0J+μ0ρt0 = \mu_0 \nabla \cdot \vec{J} + \mu_0 \frac{\partial \rho}{\partial t}.
  5. Divide by μ0\mu_0 and rearrange: ρt+J=0\frac{\partial \rho}{\partial t} + \nabla \cdot \vec{J} = 0.

This derivation shows why Maxwell needed the displacement current term μ0ϵ0Et\mu_0 \epsilon_0 \frac{\partial \vec{E}}{\partial t}. Without it, taking the divergence of Ampère's law would give J=0\nabla \cdot \vec{J} = 0, which only holds for steady currents (magnetostatics). The displacement current fixes this, ensuring charge conservation holds in all situations.

Current density vector

J\vec{J} represents the flow of electric charge per unit area per unit time, measured in A/m². Its direction indicates the direction of net positive charge flow, and its magnitude tells you how much charge crosses a unit area (perpendicular to J\vec{J}) per second.

For a simple conductor, J=σE\vec{J} = \sigma \vec{E}, where σ\sigma is the conductivity. But J\vec{J} is more general than this; it applies to any moving charge distribution, including convection currents (J=ρv\vec{J} = \rho \vec{v}) in plasmas or beams.

Charge density

ρ\rho is the volume charge density, measured in C/m³. It can be positive, negative, or zero depending on the local balance of positive and negative charges. In a neutral conductor at equilibrium, ρ=0\rho = 0 in the bulk, but surface charge densities can still be nonzero.

Applications

Electric circuits

In circuit analysis, the continuity equation reduces to Kirchhoff's current law at each node. For components like capacitors, the continuity equation is what allows a "current" to effectively flow through the gap between the plates: the changing electric field between the plates produces a displacement current ϵ0Et\epsilon_0 \frac{\partial \vec{E}}{\partial t} that maintains continuity of current.

Charge relaxation in conductors

A classic application: suppose you place excess charge inside a conductor with conductivity σ\sigma and permittivity ϵ\epsilon. How quickly does it dissipate?

  1. Start with the continuity equation: ρt+J=0\frac{\partial \rho}{\partial t} + \nabla \cdot \vec{J} = 0.
  2. Use J=σE\vec{J} = \sigma \vec{E}, so J=σE\nabla \cdot \vec{J} = \sigma \nabla \cdot \vec{E}.
  3. Apply Gauss's law: E=ρ/ϵ\nabla \cdot \vec{E} = \rho / \epsilon.
  4. Substitute: ρt+σϵρ=0\frac{\partial \rho}{\partial t} + \frac{\sigma}{\epsilon} \rho = 0.
  5. This is a first-order ODE with solution: ρ(t)=ρ0et/τ\rho(t) = \rho_0 \, e^{-t/\tau}, where τ=ϵ/σ\tau = \epsilon / \sigma.

The relaxation time τ=ϵ/σ\tau = \epsilon / \sigma tells you how fast free charge redistributes to the surface. For copper, τ1019\tau \sim 10^{-19} s (essentially instantaneous). For a poor conductor or dielectric, τ\tau can be much longer.

Electromagnetic wave propagation

The continuity equation constrains the source terms in Maxwell's equations. When deriving the wave equation for E\vec{E} and B\vec{B} in free space (ρ=0\rho = 0, J=0\vec{J} = 0), the continuity equation is automatically satisfied. In the presence of sources, it ensures that the charge and current distributions are self-consistent, which matters when you couple Maxwell's equations to the equations of motion for charged matter.

Kirchhoff's current law, Simple Circuit Calculations

Plasma physics

In plasmas, you typically write a separate continuity equation for each species (electrons, ions):

nst+(nsvs)=0\frac{\partial n_s}{\partial t} + \nabla \cdot (n_s \vec{v}_s) = 0

where nsn_s is the number density and vs\vec{v}_s is the fluid velocity of species ss. Multiplying by the charge qsq_s recovers the charge continuity equation for that species. These equations, combined with momentum equations and Maxwell's equations, form the magnetohydrodynamic (MHD) or two-fluid models used to describe fusion plasmas, the solar wind, and industrial plasma processing.

Limitations and assumptions

Validity in different media

The continuity equation ρt+J=0\frac{\partial \rho}{\partial t} + \nabla \cdot \vec{J} = 0 holds exactly in vacuum and in any continuous medium. At interfaces between different media, ρ\rho and J\vec{J} can have discontinuities, so you need to use the integral form (or equivalently, boundary conditions on the normal component of J\vec{J}) rather than the differential form directly at the interface.

For linear media, you often work with free charge density ρf\rho_f and free current density Jf\vec{J}_f, and the continuity equation applies to these free quantities: ρft+Jf=0\frac{\partial \rho_f}{\partial t} + \nabla \cdot \vec{J}_f = 0.

Quantum mechanical considerations

The classical continuity equation carries over to quantum mechanics, but with reinterpreted quantities. In the Schrödinger theory, the probability density ρ=Ψ2\rho = |\Psi|^2 and the probability current density J=2mi(ΨΨΨΨ)\vec{J} = \frac{\hbar}{2mi}(\Psi^* \nabla \Psi - \Psi \nabla \Psi^*) satisfy the same continuity equation. This ensures that total probability is conserved (normalization is preserved in time). For an Electromagnetism II course, the key point is that charge conservation is robust: it holds in classical, relativistic, and quantum frameworks.

Continuity equation vs. other conservation laws

The continuity equation for charge has the same mathematical structure as other conservation laws. Mass conservation in fluid dynamics takes the form ρmt+(ρmv)=0\frac{\partial \rho_m}{\partial t} + \nabla \cdot (\rho_m \vec{v}) = 0, and energy conservation can be written similarly with an energy density and energy flux.

Charge conservation is exact. Unlike mass conservation (which is only approximate in relativity, since mass can convert to energy via E=mc2E = mc^2) or classical energy conservation (which must be extended to include rest-mass energy in relativity), charge conservation holds without modification in every known physical theory. No experiment has ever detected a violation of charge conservation.

Problem-solving with the continuity equation

General approach

  1. Identify what's given. You'll typically know either J(r,t)\vec{J}(\vec{r}, t) or ρ(r,t)\rho(\vec{r}, t) (or a relationship between them, like J=σE\vec{J} = \sigma \vec{E}).
  2. Choose the right form. Use the differential form for problems asking about local behavior at a point. Use the integral form for problems involving total charge in a region or net current through a surface.
  3. Apply the continuity equation to relate the unknown to the known quantity.
  4. Use boundary/initial conditions to pin down constants of integration or determine the full solution.
  5. Check your answer. Does the sign make sense? (Outward current should decrease enclosed charge.) Do the units work out?

Identifying boundary conditions

Common boundary conditions include:

  • Specified ρ\rho or J\vec{J} at a surface
  • Jn^\vec{J} \cdot \hat{n} continuous across an interface (no surface current accumulation) or discontinuous by a known amount
  • Charge density vanishing at infinity for localized distributions
  • Initial charge distribution ρ(r,t=0)\rho(\vec{r}, t=0)

Solving for unknown quantities

For problems with high symmetry (planar, cylindrical, spherical), the continuity equation often reduces to an ODE that you can solve analytically (as in the charge relaxation example above). For more complex geometries or nonlinear constitutive relations, numerical methods (finite difference, finite element) are typically needed.