Biot-Savart Law & Ampere's Law
Magnetic forces, the Biot-Savart law, Ampere's law, and the divergence and curl of B.
5.1 Magnetic Force & Lorentz Force
A charge $q$ moving with velocity $\mathbf{v}$ in a magnetic field $\mathbf{B}$experiences the magnetic Lorentz force:
The magnetic force $q\mathbf{v} \times \mathbf{B}$ is always perpendicular to $\mathbf{v}$, so it does no work. The force per unit length between two parallel wires carrying currents$I_1$ and $I_2$ separated by distance $d$ is:
5.2 The Biot-Savart Law
The magnetic field produced by a steady current $I$ in a wire element $d\boldsymbol{\ell}'$ at position $\mathbf{r}'$ is given by the Biot-Savart law:
$\boldsymbol{\mathscr{r}} = \mathbf{r} - \mathbf{r}'$, $\mu_0 = 4\pi \times 10^{-7}\,\text{T}\cdot\text{m/A}$
For a general current distribution:
5.2.1 Magnetic Field on Axis of a Circular Loop
For a circular loop of radius $R$ carrying current $I$, at a point on the axis distance $z$ from the center:
By symmetry, only the axial component $B_z$ survives. Each element $Rd\phi$contributes $dB_z = (\mu_0 I R\,d\phi)/(4\pi\mathscr{r}^2) \cdot R/\mathscr{r}$ where$\mathscr{r} = \sqrt{R^2 + z^2}$. Integrating over $2\pi$:
At center ($z=0$): $B = \mu_0 I / (2R)$
5.3 Ampere's Law
Analogous to Gauss's law, Ampere's law exploits symmetry to find $\mathbf{B}$ without integrating the Biot-Savart law:
Infinite solenoid (n turns/m)
Infinite wire (radius $s$)
5.3.1 Divergence and Curl of B
$\nabla \cdot \mathbf{B} = 0$ is the second of Maxwell's four equations. It states there are no magnetic charges (monopoles).
Simulation: Biot-Savart for a Circular Loop
Computes $\mathbf{B}$ by direct numerical summation of the Biot-Savart law, compares with the analytic on-axis formula, and maps the 2D field in the $xz$-plane.
Biot-Savart: Circular Current Loop
Numerical Biot-Savart integration for a circular loop, compared against the analytic on-axis result.
Click Run to execute the Python code
First run will download Python environment (~15MB)