PHYS-382 · Lesson 12 of 12 · 27 min
Capstone: electrodynamics and relativity
Maxwell's equations predict that light travels at \(c = 1/\sqrt{\mu_0\varepsilon_0}\), with no mention of who is measuring. In Newtonian mechanics that is impossible: an observer chasing a light beam should see it slow down. Albert Einstein's 1905 paper On the Electrodynamics of Moving Bodies resolved the conflict by keeping Maxwell's equations exactly and changing mechanics instead. This capstone shows that classical electrodynamics is already a relativistic theory. Magnetism turns out to be what electric forces look like from a moving frame, the fields \(\mathbf{E}\) and \(\mathbf{B}\) mix into each other under a change of frame, and the whole theory can be written in a few lines using four-vectors and a single field tensor. A program confirms the invariants of the field, transforms a pure electric field into a mixture, and resolves the classic puzzle of a charge moving beside a current-carrying wire.
The puzzle of the moving magnet
Einstein opened his paper with an example from lesson 2. Move a magnet past a stationary loop of wire, and Faraday's law says the changing \(\mathbf{B}\) creates an electric field that drives a current. Move the loop past a stationary magnet instead, and there is no electric field at all; the current is driven by the magnetic force \(q\mathbf{v}\times\mathbf{B}\) on the moving charges. The two explanations are completely different, yet the current is exactly the same, depending only on the relative motion. Einstein took this as evidence that the distinction between electric and magnetic fields is not absolute but depends on the observer, and that the laws of physics, including Maxwell's equations, must take the same form in every inertial frame. Combined with the constancy of the speed of light, this principle of relativity leads to the Lorentz transformations studied in PHYS-271:
Hendrik Lorentz had found these transformations by 1904 precisely because they leave Maxwell's equations unchanged, though he interpreted them as effects of motion through the ether. Einstein showed that no ether is needed: they describe how space and time themselves relate between frames.
Magnetism as a relativistic effect
Consider a long neutral wire carrying current \(I\), modelled as positive ions at rest with line charge \(+\lambda\) and conduction electrons drifting at speed \(v_d\) with line charge \(-\lambda\). A test charge \(q\) moves parallel to the wire at speed \(u\), a distance \(s\) away. In the laboratory frame the wire is neutral, so there is no electric force. There is a magnetic field \(\mu_0I/2\pi s\), and the charge feels a magnetic force of magnitude \(quB = qu\mu_0I/2\pi s\), toward or away from the wire depending on the signs.
Now jump into the rest frame of the test charge. There it has no velocity, so it can feel no magnetic force; any force must be electric. And indeed the wire is no longer neutral in this frame. The ions now move at \(-u\), so their spacing is Lorentz contracted and their line charge rises to \(\gamma_u\lambda\). The electrons move at the relativistic difference of \(v_d\) and \(u\), and their line charge changes by a different factor. The two no longer cancel. Working through the velocity addition exactly, the net line charge seen by the test charge is \(\lambda_{\text{net}} = \gamma_u\lambda uv_d/c^2\), and its electric field \(\lambda_{\text{net}}/(2\pi\varepsilon_0s)\) exerts a force
This is \(\gamma_u\) times the laboratory force, exactly the factor by which a transverse force must transform between frames for the momentum change to agree, since the transverse momentum is the same in both frames but the time interval is dilated. The magnetic force in one frame is an electric force in another. The astonishing part is the size of the effect: the drift speed is a fraction of a millimetre per second, so the relativistic charge imbalance is about one part in \(10^{15}\). It is detectable only because the electric force between the vast numbers of charges in a wire is so enormous that this tiny imbalance still produces the familiar forces of every electric motor. The program evaluates the densities with 50-digit decimal arithmetic, since ordinary floating point cannot resolve a difference of one part in \(10^{15}\) reliably.
How the fields transform
In general, if a frame \(S'\) moves with velocity \(v\) along \(x\) relative to \(S\), the fields seen in \(S'\) are
The components along the motion are unchanged; the perpendicular components mix. These rules can be derived from simple configurations, a parallel-plate capacitor and a solenoid viewed from a moving frame, using the contraction of charge and current densities. For small \(v\) they reduce to \(\mathbf{E}' \approx \mathbf{E} + \mathbf{v}\times\mathbf{B}\), so the force on a charge at rest in \(S'\) equals the Lorentz force \(q(\mathbf{E} + \mathbf{v}\times\mathbf{B})\) that it feels in \(S\) while moving. That is the reconciliation of the moving-magnet puzzle.
Neither \(\mathbf{E}\) nor \(\mathbf{B}\) is invariant, but two combinations are the same in every frame:
They have important consequences. If \(\mathbf{E}\cdot\mathbf{B} = 0\) and \(E < cB\) in one frame, there is a frame in which the field is purely magnetic; if \(E > cB\), one in which it is purely electric. A plane wave has \(E = cB\) and \(\mathbf{E}\perp\mathbf{B}\), so both invariants vanish: light looks like light in every frame, never like a static field, though a moving observer measures it Doppler shifted in frequency and in amplitude.
The field of a moving charge
A charge \(q\) moving at constant velocity \(\mathbf{v}\) has, in its own rest frame, a pure Coulomb field. Transforming to the laboratory gives, at the present position of the charge,
where \(\mathbf{R}\) is the vector from the charge's present position to the field point and \(\theta\) the angle between \(\mathbf{R}\) and \(\mathbf{v}\). Remarkably, the field points away from where the charge is now, not where it was at the retarded time, even though the information travelled from the retarded position: for uniform motion the retarded position and velocity together predict the present position exactly. The field is weakened ahead of and behind the charge by \(1/\gamma^2\) and strengthened to the sides by \(\gamma\); at high speed the field lines crowd into a thin disc perpendicular to the motion. This flattened field is how a fast charged particle passing an atom delivers a brief, sharp pulse of force, which is the basis of the energy-loss formulas used to design particle detectors and radiation therapy.
Four-vectors and the field tensor
Relativity is most naturally expressed with four-vectors, quantities with a time component and three space components that transform like \((ct, \mathbf{r})\). Charge density and current density form the four-current \(J^\mu = (c\rho, \mathbf{J})\), and the continuity equation becomes \(\partial_\mu J^\mu = 0\), the four-dimensional divergence. The potentials form the four-potential \(A^\mu = (V/c, \mathbf{A})\), and the Lorenz gauge condition is \(\partial_\mu A^\mu = 0\). The fields themselves do not fit into a four-vector; there are six components, which fill an antisymmetric four-by-four tensor
In this language all of Maxwell's equations become two lines,
the first containing Gauss's law and the Ampère–Maxwell law, the second containing \(\nabla\cdot\mathbf{B} = 0\) and Faraday's law. The field transformation rules above are just the rule for transforming a tensor with two indices, and the invariants are the two scalars that can be built from \(F^{\mu\nu}\): \(F_{\mu\nu}F^{\mu\nu} = 2(B^2 - E^2/c^2)\) and a second proportional to \(\mathbf{E}\cdot\mathbf{B}\). The Lorentz force becomes \(dp^\mu/d\tau = qF^{\mu\nu}u_\nu\). Electricity and magnetism are not two forces that happen to be related; they are one field, seen in different ways from different frames.
import math, random
c = 2.99792458e8; mu0 = 4e-7 * math.pi; eps0 = 1 / (mu0 * c * c)
rnd = random.Random(382)
def boost_x(E, B, v):
"""Fields seen in a frame moving with speed v along x."""
g = 1 / math.sqrt(1 - (v / c) ** 2)
Ex, Ey, Ez = E; Bx, By, Bz = B
E2 = (Ex, g * (Ey - v * Bz), g * (Ez + v * By))
B2 = (Bx, g * (By + v / c**2 * Ez), g * (Bz - v / c**2 * Ey))
return E2, B2
dot = lambda a, b: sum(x * y for x, y in zip(a, b))
# 1. The invariants E^2 - c^2 B^2 and E . B are the same in every frame
E = (rnd.uniform(-1e4, 1e4), rnd.uniform(-1e4, 1e4), rnd.uniform(-1e4, 1e4))
B = (rnd.uniform(-1e-4, 1e-4), rnd.uniform(-1e-4, 1e-4), rnd.uniform(-1e-4, 1e-4))
for beta in (0.0, 0.5, 0.9, 0.99):
E2, B2 = boost_x(E, B, beta * c)
print(f"v = {beta:4.2f} c: E^2 - c^2 B^2 = {dot(E2, E2) - c * c * dot(B2, B2):.6e}, E.B = {dot(E2, B2):.6e}")
# 2. A pure electric field in one frame looks partly magnetic in another
E2, B2 = boost_x((0.0, 1000.0, 0.0), (0.0, 0.0, 0.0), 0.6 * c)
print(f"E = 1000 V/m along y, seen from a frame at 0.6 c: E' = {E2[1]:.1f} V/m, B' = {B2[2] * 1e6:.4f} uT along z")
# 3. Wire and moving charge: a neutral wire carries current I; a charge q moves parallel at speed u
# at distance s. Lab frame: purely magnetic force. Charge's frame: purely electric force.
# The relativistic density changes are tiny, so use 50-digit decimal arithmetic.
from decimal import Decimal as D, getcontext
getcontext().prec = 50
I, s, q, u = 10.0, 0.01, 1.602176634e-19, 1.0e5
F_lab = q * u * mu0 * I / (2 * math.pi * s)
lam = D(8.47e28) * D(math.pi) * D(0.5e-3) ** 2 * D(1.602176634e-19) # ion line charge, 1 mm wire
vd = D(I) / lam # electron drift speed (electrons move toward +x)
C, U = D(c), D(u) # the test charge moves at u toward +x too
gam = lambda w: 1 / (1 - (w / C) ** 2).sqrt()
lam_ions = lam * gam(U) # ions move at -u in the new frame: length contracted
ve = (vd - U) / (1 - vd * U / C ** 2) # relativistic velocity subtraction
lam_e = -lam / gam(vd) * gam(ve) # rest density of electrons times the new gamma
lam_net = lam_ions + lam_e
F_rest = q * float(lam_net) / (2 * math.pi * eps0 * s)
print(f"drift speed {float(vd) * 1e3:.4f} mm/s, net line charge seen by the moving charge {float(lam_net):.4e} C/m")
print(f"force: lab (magnetic) {F_lab:.6e} N, charge frame (electric) {F_rest:.6e} N")
print(f"ratio {F_rest / F_lab:.12f}, gamma(u) = {float(gam(U)):.12f}")
# 4. Field of a uniformly moving charge: strength along and across the motion at 1 m
k = 1 / (4 * math.pi * eps0); qc = 1e-9
for beta in (0.0, 0.5, 0.9, 0.99):
gg = 1 / math.sqrt(1 - beta * beta)
along = k * qc / gg ** 2; across = k * qc * gg
print(f"v = {beta:4.2f} c: field ahead {along:8.4f} V/m, field to the side {across:8.3f} V/m, ratio {across / along:8.1f}")v = 0.00 c: E^2 - c^2 B^2 = -4.539607e+08, E.B = -5.297291e-01 v = 0.50 c: E^2 - c^2 B^2 = -4.539607e+08, E.B = -5.297291e-01 v = 0.90 c: E^2 - c^2 B^2 = -4.539607e+08, E.B = -5.297291e-01 v = 0.99 c: E^2 - c^2 B^2 = -4.539607e+08, E.B = -5.297291e-01 E = 1000 V/m along y, seen from a frame at 0.6 c: E' = 1250.0 V/m, B' = -2.5017 uT along z drift speed 0.9382 mm/s, net line charge seen by the moving charge 1.1127e-11 C/m force: lab (magnetic) 3.204353e-18 N, charge frame (electric) 3.204353e-18 N ratio 1.000000055633, gamma(u) = 1.000000055633 v = 0.00 c: field ahead 8.9876 V/m, field to the side 8.988 V/m, ratio 1.0 v = 0.50 c: field ahead 6.7407 V/m, field to the side 10.378 V/m, ratio 1.5 v = 0.90 c: field ahead 1.7076 V/m, field to the side 20.619 V/m, ratio 12.1 v = 0.99 c: field ahead 0.1789 V/m, field to the side 63.711 V/m, ratio 356.2
The randomly chosen field gives the same \(E^2 - c^2B^2\) and \(\mathbf{E}\cdot\mathbf{B}\) at every boost speed, to all printed digits, though the individual components change enormously. A 1000 V/m electric field viewed from a frame moving at 0.6c becomes 1250 V/m and acquires a magnetic field of 2.5 \(\mu\)T. For the wire, the 1 mm copper conductor carrying 10 A has a drift speed under a millimetre per second; a proton moving beside it at 100 km/s sees a net line charge of about \(1.1 \times 10^{-11}\) C/m, against an ion line charge of about \(10^4\) C/m, and the electric force in its frame exceeds the laboratory magnetic force by exactly \(\gamma_u\), to twelve decimal places. Finally the moving charge's field 1 m ahead drops from 9.0 V/m at rest to 0.18 V/m at 0.99c, while the field to the side rises to 64 V/m: a ratio of \(\gamma^3 \approx 356\).
Looking back
This course began with the observation that the static equations could not be complete, added Faraday's law and the displacement current, and then followed the consequences: energy and momentum stored in and carried by fields, electromagnetic waves and their behaviour at surfaces, in conductors and plasmas and in guides, the potentials and their retardation, and radiation from accelerating charges. The capstone shows that the finished theory had been relativistic all along, a fact Maxwell could not have known. From here the road leads in several directions. Quantum electrodynamics, completed by Feynman, Schwinger, Tomonaga and Dyson in the late 1940s, quantizes the field into photons and predicts the magnetic moment of the electron to about one part in a trillion, the most precise agreement between theory and experiment in all of physics. General relativity, in PHYS-450, applies the same geometric ideas to gravity. And the gauge invariance of lesson 10 becomes the organizing principle of the Standard Model, in which the weak and strong forces are generalizations of electromagnetism.
Worked problem
A pure magnetic field seen from a moving frame
In the lab there is a uniform magnetic field \(\mathbf{B} = 0.50\) T along \(z\) and no electric field. An observer moves along \(x\) at \(v = 3.0 \times 10^7\) m/s. What fields does the observer measure, and what force does an electron at rest in the observer's frame feel?
Show solution
- \(\gamma = 1/\sqrt{1 - 0.01} = 1.00504\).
- \(E'_y = \gamma(E_y - vB_z) = -1.00504 \times 3.0 \times 10^7 \times 0.5 = -1.51 \times 10^7\) V/m; \(B'_z = \gamma B_z = 0.5025\) T.
- The electron at rest in \(S'\) feels \(F' = qE'_y = (-1.6 \times 10^{-19})(-1.51 \times 10^7) = 2.4 \times 10^{-12}\) N along \(+y\).
- In the lab the electron moves at \(v\) along \(x\) and feels \(q\mathbf{v}\times\mathbf{B} = 2.4 \times 10^{-12}\) N along \(+y\), smaller by \(\gamma\), as the transverse force transformation requires. The invariant \(E^2 - c^2B^2 = -c^2(0.25)\) is unchanged.
Answer: The observer sees \(E'_y \approx -1.5 \times 10^7\) V/m and \(B'_z \approx 0.50\) T, and the electron feels about \(2.4 \times 10^{-12}\) N along \(+y\), electric in that frame but magnetic in the lab.
Common mistakes
MistakeThinking magnetic and electric forces are unrelated.
InsteadA magnetic force in one frame is an electric force in another; they are parts of one field tensor.
MistakeExpecting relativistic effects to need high speeds to be noticeable in magnetism.
InsteadThe drift speed is tiny, but the forces between the charges in a wire are so large that the effect is everyday magnetism.
MistakeTransforming E and B as if they were separate vectors.
InsteadThe perpendicular components mix: \(E'_\perp = \gamma(\mathbf{E} + \mathbf{v}\times\mathbf{B})_\perp\).
MistakeAssuming the field of a moving charge points away from its retarded position.
InsteadFor uniform motion it points away from the present position, though it is flattened.
MistakeBelieving an observer moving fast enough could see light as a static field.
InsteadLight has \(E^2 - c^2B^2 = 0\) and \(\mathbf{E}\cdot\mathbf{B} = 0\) in every frame; it is always a wave.
Summary and key terms
- Maxwell's equations are invariant under Lorentz transformations; relativity changed mechanics, not electrodynamics.
- A magnetic force in one frame appears as an electric force in another; for a current-carrying wire the charge imbalance is about one part in \(10^{15}\).
- Under a boost the parallel field components are unchanged and the perpendicular ones mix; \(E^2 - c^2B^2\) and \(\mathbf{E}\cdot\mathbf{B}\) are invariant.
- The field of a uniformly moving charge points from its present position and is compressed into a disc perpendicular to the motion.
- With the four-current, four-potential and field tensor \(F^{\mu\nu}\), Maxwell's equations become \(\partial_\mu F^{\mu\nu} = \mu_0J^\nu\) and a second identity.
- Lorentz transformation
- The relation between space and time coordinates in two inertial frames that keeps the speed of light the same.
- field invariants
- Combinations E^2 - c^2 B^2 and E . B that have the same value in every inertial frame.
- four-current
- The four-vector (c rho, J) combining charge density and current density.
- four-potential
- The four-vector (V/c, A) combining the scalar and vector potentials.
- field tensor
- The antisymmetric tensor F^(mu nu) containing the six components of E and B.
- proper frame
- The frame in which a particle is at rest.
Practice problems
Work each problem on paper first, then reveal the answer to check.
A field has \(E = 2.0 \times 10^8\) V/m and \(B = 0.50\) T, perpendicular to each other. Is there a frame where the field is purely electric, or purely magnetic?
Show answer
\(E^2 - c^2B^2 = 4 \times 10^{16} - 2.25 \times 10^{16} > 0\) and \(\mathbf{E}\cdot\mathbf{B} = 0\), so there is a frame where it is purely electric, moving at \(v = c^2B/E = 0.75c\) perpendicular to both.
Show that the transformation rules reduce to \(\mathbf{E}' = \mathbf{E} + \mathbf{v}\times\mathbf{B}\) for \(v \ll c\).
Show answer
With \(\gamma \approx 1\), \(E'_y = E_y - vB_z\) and \(E'_z = E_z + vB_y\), which are the \(y\) and \(z\) components of \(\mathbf{E} + v\hat{\mathbf{x}}\times\mathbf{B}\).
A proton moves at 0.5c. By what factor is its field to the side stronger than at rest? Ahead of it?
Show answer
\(\gamma = 1.155\): to the side \(\times1.155\); ahead \(\times1/\gamma^2 = 0.75\).
Write the components \(J^0\) and \(J^1\) of the four-current for charge density \(\rho\) moving along \(x\) at speed \(u\).
Show answer
\(J^0 = c\rho\), \(J^1 = \rho u\); they transform like \((ct, x)\).
Verify that a plane wave has both field invariants equal to zero.
Show answer
\(E = cB\) gives \(E^2 - c^2B^2 = 0\), and \(\mathbf{E}\perp\mathbf{B}\) gives \(\mathbf{E}\cdot\mathbf{B} = 0\).
Two electron beams travel side by side in the same direction at nearly \(c\). Why do they repel each other only weakly?
Show answer
In the lab each beam's electric field repels the other, but each is also a current, and parallel currents attract. The magnetic attraction is \(v^2/c^2\) times the electric repulsion, so the net repulsion is reduced by the factor \(1 - v^2/c^2 = 1/\gamma^2\), which is tiny for beams near the speed of light.
Lesson quiz · 5 questions
Score 60% or more to complete this lesson.
Create a free account to save your progress, take quizzes and earn a certificate.