Magnetic Dipole Field Visualizer

Interactive magnetic dipole field visualization: adjust dipole moment magnitude and orientation, observe field lines, field strength heatmap, and cross-section views in different planes

Magnetic Dipole Field

Magnetic Dipole Field

A magnetic dipole is the simplest source of a magnetic field, analogous to a point charge in electrostatics but with fundamentally different topology. The field of a magnetic dipole with moment m = mẑ at the origin is B = (μ₀/4π) · (3(m·r̂)r̂ - m) / r³. In spherical coordinates: Bᵣ = (μ₀ m / 4πr³) · 2cosθ, B_θ = (μ₀ m / 4πr³) · sinθ. Key features: (1) The field falls off as 1/r³ — much faster than the 1/r² of a point charge. (2) Field lines form closed loops — there are no magnetic monopoles (div B = 0). (3) Along the dipole axis (θ = 0), B is twice as strong as at the equator (θ = π/2) at the same distance. (4) The field is azimuthally symmetric around the dipole axis. Bar magnets, current loops, and planetary magnetospheres all produce dipole fields to leading order.

Field Line Topology

Magnetic dipole field lines have a distinctive topology: they emerge from the north pole, curve through space, and return to the south pole, forming closed loops. This is a direct consequence of Gauss's law for magnetism: ∮ B·dA = 0 (no magnetic monopoles). The field line equation in spherical coordinates is r = r₀ sin²θ, where r₀ parameterizes different lines. At the equator (θ = π/2), the line reaches maximum distance r₀ from the dipole. Near the poles, lines are nearly radial and closely spaced. The density of field lines at any point is proportional to |B|, so the visual concentration near the poles correctly represents the stronger field there. This topology contrasts sharply with electric dipole field lines, which begin on positive charges and end on negative charges rather than forming closed loops.

Applications

Earth's magnetosphere: The geomagnetic field is approximately a dipole tilted ~11.5° from the rotation axis. It deflects solar wind particles and traps radiation in the Van Allen belts, creating the aurora at high latitudes where field lines converge. MRI: Magnetic resonance imaging uses superconducting dipole magnets (1.5-7 T) to align nuclear spins. The strong, uniform field is critical for image resolution. Compass navigation: A compass needle is itself a magnetic dipole that aligns with the ambient field — Earth's field or the field of nearby magnets. Electric motors and generators: Rotating magnetic dipoles (rotors) interact with stator fields to convert between electrical and mechanical energy. Magnetic recording: Hard disk drives use tiny magnetic domains (micro-dipoles) to store binary data. Particle accelerators: Dipole magnets bend charged particle beams along curved paths using F = qv × B. Planetary science: Jupiter's dipole field (~4.3 Gauss at equator, 20,000× stronger than Earth's) creates the strongest planetary magnetosphere in the solar system.

How to Use

The canvas shows a true 3D magnetic dipole sampled on a 2D cross-section plane. The yellow dipole axis rotates in the x-z plane: θ = 0 points along +z (aligned), while θ = 90 points along +x (horizontal). Blue curves trace the in-plane magnetic field lines, and the background heatmap shows the full field strength |B|. Start with the default XZ plane and Aligned (θ = 0) to see the classic dipole loops in a meridional cross-section. Switch to XY to see the equatorial slice, where the field can point mostly out of the plane, so field lines may disappear while the heatmap remains strong. Toggle Field Vectors to view the in-plane vector components, and Equipotential to overlay magnetic scalar potential contours. Hover over the canvas to inspect the field at the cursor position.