\subsection{Inductance and Magnetic Energy Storage}

This subsection covers self-inductance, mutual inductance, and the energy stored in magnetic fields. When the current through a conductor changes, the magnetic flux it produces also changes, inducing an electromotive force (EMF) that opposes that change --- a phenomenon governed by Faraday's law and Lenz's law. The energy required to establish the current is stored in the magnetic field and can be recovered when the current decreases.

\dfn{Self-inductance}{The \emph{self-inductance} $L$ of a circuit (or coil) quantifies the magnetic flux linkage per unit current. If a current $I$ through a coil of $N$ turns produces a magnetic flux $\Phi_B$ through each turn, the total flux linkage is $N\Phi_B$. The self-inductance is defined by
\[
L = \frac{N\,\Phi_B}{I}.
\]
Equivalently, from Faraday's law of induction, a changing current induces an EMF
\[
\mathcal{E} = -\,L\,\frac{dI}{dt},
\]
where the negative sign reflects Lenz's law: the induced EMF opposes the change in current. The SI unit of inductance is the henry (H), where $1\;\mathrm{H} = 1\;\mathrm{V\!\cdot\!s/A} = 1\;\mathrm{kg\!\cdot\!m^2/(s^2\!\cdot\!A^2)}$.}

\nt{Inductance is purely a geometric property. For a fixed geometry (and no ferromagnetic material near the coil), $L$ is constant and independent of the current. The larger the coil, the more turns, and the greater the flux linkage per unit current, the larger the inductance. A coil with $L = 1\;\mathrm{H}$ and $dI/dt = 1\;\mathrm{A/s}$ develops a $1\;\mathrm{V}$ back EMF.}

\thm{Solenoid self-inductance}{For an ideal long solenoid of length $\ell \gg R$, total turns $N$, cross-sectional area $A = \pi R^2$, and vacuum permeability $\mu_0 = 4\pi\times 10^{-7}\,\mathrm{T\!\cdot\!m/A}$, the magnetic field inside is $B = \mu_0\,n\,I$ where $n = N/\ell$. The flux through each turn is $\Phi_B = B\,A = \mu_0 N I A/\ell$. Therefore
\[
L = \frac{N\,\Phi_B}{I} = \frac{\mu_0\,N^2\,A}{\ell}.
\]}

\nt{The solenoid inductance scales as $N^2$ because each additional turn both increases the flux linkage ($N$ factor) and increases the magnetic field produced per unit current ($N$ factor through $n = N/\ell$). The inductance is proportional to the cross-sectional area $A$ and inversely proportional to the length $\ell$.}

\dfn{Mutual inductance}{Consider two coils placed near each other. If a current $I_1$ in coil 1 produces a magnetic flux $\Phi_{21}$ through each turn of coil 2 (which has $N_2$ turns), the \emph{mutual inductance} $M_{21}$ is defined as
\[
M_{21} = \frac{N_2\,\Phi_{21}}{I_1}.
\]
By Faraday's law, a changing current in coil 1 induces an EMF in coil 2:
\[
\mathcal{E}_2 = -\,M_{21}\,\frac{dI_1}{dt}.
\]
Mutual inductance is symmetric: $M_{21} = M_{12} = M$. The SI unit is the henry (H).}

\nt{Mutual inductance is the operating principle of transformers. The amount of flux from coil 1 that threads coil 2 depends on their relative orientation, separation, and the presence of magnetic materials. When the coils are perfectly coupled (all flux from one threads the other), $M$ reaches its maximum value. In practice, the coupling is characterized by the coefficient $k = M/\sqrt{L_1 L_2}$, where $0 \leq k \leq 1$.}

\thm{Magnetic energy and energy density}{When a current $I$ flows through an inductor of inductance $L$, the magnetic field stores energy. The total energy stored is
\[
U = \frac{1}{2}\,L\,I^2.
\]
Inside an ideal solenoid, the magnetic field is uniform with magnitude $B = \mu_0 n I$. The energy can be expressed in terms of $B$ by noting that the energy is distributed throughout the volume $V = A\,\ell$. The \emph{magnetic energy density} (energy per unit volume) in vacuum is
\[
u_B = \frac{U}{V} = \frac{B^2}{2\,\mu_0}.
\]}

\pf{Magnetic energy from power}{The power delivered to an inductor by an external source to drive current $I$ against the back EMF $\mathcal{E} = -L\,dI/dt$ is
\[
P = -\,\mathcal{E}\,I = L\,I\,\frac{dI}{dt}.
\]
The rate of energy storage is $dU/dt = P$, so
\[
\frac{dU}{dt} = L\,I\,\frac{dI}{dt}.
\]
Integrating with respect to time as the current rises from $0$ to $I$:
\[
U = \int_0^I L\,i\;di = \frac{1}{2}\,L\,I^2.
\]}

\pf{Energy density of the B field (solenoid derivation)}{Consider an ideal solenoid with $N$ turns, length $\ell$, cross-sectional area $A$, carrying current $I$. Its inductance is $L = \mu_0 N^2 A/\ell$, and the stored energy is
\[
U = \frac{1}{2}\,L\,I^2 = \frac{1}{2}\,\frac{\mu_0\,N^2\,A}{\ell}\;I^2.
\]
The magnetic field inside is $B = \mu_0 N I/\ell$, so $I = B\,\ell/(\mu_0 N)$. Substituting:
\[
U = \frac{1}{2}\,\frac{\mu_0 N^2 A}{\ell}\,\left(\frac{B\,\ell}{\mu_0 N}\right)^{\!2} = \frac{1}{2}\,\frac{\mu_0 N^2 A}{\ell}\,\frac{B^2\,\ell^2}{\mu_0^2 N^2} = \frac{B^2}{2\,\mu_0}\;A\,\ell.
\]
The volume is $V = A\,\ell$, so the energy density is
\[
u_B = \frac{U}{V} = \frac{B^2}{2\,\mu_0}.
\]
This result is general: the energy density $u_B = B^2/(2\mu_0)$ holds at any point in space in vacuum wherever a magnetic field $B$ exists.}

\nt{The magnetic energy density $u_B = B^2/(2\mu_0)$ is the magnetic analogue of the electric energy density $u_E = \tfrac{1}{2}\varepsilon_0 E^2$. In both cases, energy is stored in the field itself, distributed throughout space. This field-energy viewpoint is essential in electrodynamics: changing fields carry energy via the Poynting vector $\vec{S} = \vec{E}\times\vec{B}/\mu_0$.}

\mprop{Key inductance and magnetic-energy formulas}{
\begin{itemize}
\item \textbf{Self-inductance definition:} $L = N\,\Phi_B/I = -\,\mathcal{E}/(dI/dt)$.
\item \textbf{Solenoid inductance:} $L = \mu_0 N^2 A/\ell$.
\item \textbf{Mutual inductance:} $M = N_2\,\Phi_{21}/I_1$.
\item \textbf{Magnetic energy:} $U = \tfrac{1}{2} L I^2$.
\item \textbf{Magnetic energy density (vacuum):} $u_B = B^2/(2\mu_0)$.
\end{itemize}}

\cor{Units check}{Energy density $u_B$ has units of joules per cubic metre ($\mathrm{J/m^3}$). Since $1\;\mathrm{J} = 1\;\mathrm{N\!\cdot\!m}$ and $1\;\mathrm{N} = 1\;\mathrm{T\!\cdot\!A\!\cdot\!m}$, we have $B^2/\mu_0$ in units of $(\mathrm{T})^2/(\mathrm{T\!\cdot\!m/A}) = \mathrm{T\!\cdot\!A/m} = (\mathrm{N/(A\!\cdot\!m)})\!\cdot\!(\mathrm{A/m}) = \mathrm{N/m^2} = \mathrm{J/m^3}$, as expected.}

\ex{Illustrative example}{A toroidal solenoid has mean circumference $0.40\,\mathrm{m}$, cross-sectional area $2.0\times 10^{-3}\,\mathrm{m^2}$, and $N = 500$ turns. Its inductance is $L = \mu_0 N^2 A/\ell = (4\pi\times 10^{-7})(500)^2(2.0\times 10^{-3})/(0.40) = 1.57\times 10^{-3}\,\mathrm{H} = 1.57\,\mathrm{mH}$. At $I = 3.0\,\mathrm{A}$, the stored energy is $U = \tfrac{1}{2}(1.57\times 10^{-3})(3.0)^2 = 7.07\times 10^{-3}\,\mathrm{J} = 7.1\,\mathrm{mJ}$.}

\qs{Worked example}{An ideal solenoid is $50.0\,\mathrm{cm}$ long and has $N = 1200$ turns uniformly distributed along its length. Its circular cross-section has radius $R = 2.0\,\mathrm{cm}$. A steady current $I = 5.0\,\mathrm{A}$ flows through the wire. Take $\mu_0 = 4\pi\times 10^{-7}\,\mathrm{T\!\cdot\!m/A}$.

Find:
\begin{enumerate}[label=(\alph*)]
\item the self-inductance $L$ of the solenoid,
\item the magnetic energy $U$ stored in the solenoid,
\item the magnitude of the magnetic field $B$ inside the solenoid, and
\item the magnetic energy density $u_B$ inside the solenoid.
Verify that $U = u_B\,V$, where $V$ is the interior volume of the solenoid.
\end{enumerate}}

\sol \textbf{Part (a).} The cross-sectional area of the solenoid is
\[
A = \pi R^2 = \pi\,(0.020\,\mathrm{m})^2 = \pi\times 4.0\times 10^{-4}\,\mathrm{m^2} = 1.26\times 10^{-3}\,\mathrm{m^2}.
\]
The length is $\ell = 0.500\,\mathrm{m}$. Using the solenoid inductance formula:
\[
L = \frac{\mu_0\,N^2\,A}{\ell}.
\]
Substitute the values:
\[
L = \frac{(4\pi\times 10^{-7}\,\mathrm{T\!\cdot\!m/A})(1200)^2(1.26\times 10^{-3}\,\mathrm{m^2})}{0.500\,\mathrm{m}}.
\]
Compute step by step:
\[
(1200)^2 = 1.44\times 10^{6},
\]
\[
\mu_0\,(1200)^2 = (4\pi\times 10^{-7})(1.44\times 10^{6}) = 4\pi\times 0.144 = 1.810\times 10^{-6}\,\mathrm{T\!\cdot\!m^2/A}.
\]
Then
\[
L = \frac{(1.810\times 10^{-6})(1.26\times 10^{-3})}{0.500}\,\mathrm{H} = \frac{2.28\times 10^{-9}}{0.500}\,\mathrm{H} = 4.56\times 10^{-3}\,\mathrm{H}.
\]
More precisely, carrying $\pi$ through:
\[
L = \frac{4\pi\times 10^{-7}\times 1.44\times 10^{6}\times \pi\times 4.0\times 10^{-4}}{0.500} = \frac{4\pi^2\times 5.76\times 10^{-5}}{0.500} = 8\pi^2\times 5.76\times 10^{-5}.
\]
\[
\pi^2 \approx 9.87,\qquad L = 8\times 9.87\times 5.76\times 10^{-5}\,\mathrm{H} = 4.55\times 10^{-3}\,\mathrm{H}.
\]
So
\[
L = 4.55\times 10^{-3}\,\mathrm{H} = 4.55\,\mathrm{mH}.
\]

\textbf{Part (b).} The stored magnetic energy is
\[
U = \frac{1}{2}\,L\,I^2.
\]
Substitute:
\[
U = \frac{1}{2}\,(4.55\times 10^{-3}\,\mathrm{H})\,(5.0\,\mathrm{A})^2.
\]
Since $(5.0)^2 = 25.0$:
\[
U = \frac{1}{2}\,(4.55\times 10^{-3})(25.0)\,\mathrm{J} = \frac{1}{2}\,(0.114)\,\mathrm{J} = 5.68\times 10^{-2}\,\mathrm{J}.
\]
So
\[
U = 5.68\times 10^{-2}\,\mathrm{J} = 56.8\,\mathrm{mJ}.
\]

\textbf{Part (c).} The magnetic field inside the solenoid is
\[
B = \mu_0\,n\,I,
\]
where $n = N/\ell$ is the turn density:
\[
n = \frac{1200}{0.500\,\mathrm{m}} = 2400\,\mathrm{turns/m}.
\]
Substitute:
\[
B = (4\pi\times 10^{-7}\,\mathrm{T\!\cdot\!m/A})(2400\,\mathrm{m^{-1}})(5.0\,\mathrm{A}).
\]
Compute:
\[
2400\times 5.0 = 1.20\times 10^{4},
\]
\[
B = 4\pi\times 10^{-7}\times 1.20\times 10^{4} = 4.80\pi\times 10^{-3}\,\mathrm{T}.
\]
Using $\pi \approx 3.1416$:
\[
B = 4.80\times 3.1416\times 10^{-3}\,\mathrm{T} = 1.51\times 10^{-2}\,\mathrm{T}.
\]
So
\[
B = 1.51\times 10^{-2}\,\mathrm{T} = 15.1\,\mathrm{mT}.
\]

\textbf{Part (d).} The magnetic energy density is
\[
u_B = \frac{B^2}{2\,\mu_0}.
\]
Substitute $B = 1.51\times 10^{-2}\,\mathrm{T}$:
\[
B^2 = (1.51\times 10^{-2})^2 = 2.28\times 10^{-4}\,\mathrm{T^2}.
\]
Then
\[
u_B = \frac{2.28\times 10^{-4}}{2(4\pi\times 10^{-7})}\,\mathrm{J/m^3} = \frac{2.28\times 10^{-4}}{2.51\times 10^{-6}}\,\mathrm{J/m^3} = 9.09\times 10^{1}\,\mathrm{J/m^3}.
\]
More precisely:
\[
u_B = \frac{2.283\times 10^{-4}}{2.513\times 10^{-6}}\,\mathrm{J/m^3} = 90.9\,\mathrm{J/m^3}.
\]
So
\[
u_B = 90.9\,\mathrm{J/m^3}.
\]

Now verify $U = u_B\,V$. The interior volume of the solenoid is
\[
V = A\,\ell = (\pi\times 4.0\times 10^{-4}\,\mathrm{m^2})(0.500\,\mathrm{m}) = 6.28\times 10^{-4}\,\mathrm{m^3}.
\]
Then
\[
u_B\,V = (90.9\,\mathrm{J/m^3})(6.28\times 10^{-4}\,\mathrm{m^3}) = 5.71\times 10^{-2}\,\mathrm{J}.
\]
Using more precise intermediate values: $B = 1.508\times 10^{-2}\,\mathrm{T}$, $B^2 = 2.274\times 10^{-4}$, $u_B = 90.6\,\mathrm{J/m^3}$, $V = 6.283\times 10^{-4}\,\mathrm{m^3}$, giving $u_B\,V = 5.69\times 10^{-2}\,\mathrm{J}$, which matches $U = 5.68\times 10^{-2}\,\mathrm{J}$ within rounding. The relation $U = u_B V$ holds, confirming that the energy is uniformly distributed throughout the solenoid volume at density $u_B = B^2/(2\mu_0)$.

\bigskip
\textbf{Final answers:}
\begin{enumerate}[label=(\alph*)]
\item $L = 4.55\times 10^{-3}\,\mathrm{H} = 4.55\,\mathrm{mH}$
\item $U = 5.68\times 10^{-2}\,\mathrm{J} = 56.8\,\mathrm{mJ}$
\item $B = 1.51\times 10^{-2}\,\mathrm{T} = 15.1\,\mathrm{mT}$
\item $u_B = 90.9\,\mathrm{J/m^3}$, and $U = u_B\,V$ verified
\end{enumerate}
