---
title: Magnetic Energy
module: Electromagnetic Induction
moduleNumber: 8
lessonNumber: 7
order: 807
summary: >
  Building current in a coil means working against its back emf, and that work does not
  vanish — it sits in the magnetic field as recoverable energy $U_B=\tfrac12LI^2$, spread
  through space at density $u_B=B^2/(2\mu_0)$. We derive both forms, show they agree for a
  solenoid, and read a force out of the same energy: an armature is pulled toward higher
  inductance, and $B^2/(2\mu_0)$ doubles as a magnetic pressure. The lesson closes on the
  accounting a real switching event demands, where recoverable energy, copper heating,
  core loss, and clamp dissipation must balance a single ledger.
topics: [Electromagnetic Induction]
draft: false
sources:
  - book: Tipler & Mosca
    ref: "Ch. 28 — Magnetic Induction, §28-7 Magnetic Energy"
---

## Inductor Energy and Power

An inductor stores energy while its current changes, and a power balance shows how
much. Adopt the passive sign convention: current $I$ enters the terminal labelled
positive for the inductor voltage $V_L$. An ideal inductor obeys

$$
V_L=L\frac{\d I}{\d t}.
$$

The instantaneous electrical power entering the inductor is

$$
P_L=V_LI
=LI\frac{\d I}{\d t}.
$$

During a current increase, $I\,\d I/\d t>0$, so energy enters the
inductor. During a current decrease, the sign reverses and energy leaves the
inductor through the circuit. Integrating from zero current to a current $I$ gives

$$
U_L=\int_0^I LI'\,\d I'
=\frac12LI^2.
$$

The prime marks the integration variable. It prevents the upper-limit current from
being confused with the current value inside the integral. The result assumes that
$L$ remains constant over the current range. A linear air-core coil is often close
to this model; a magnetic core can require a nonlinear linkage curve.

The sign convention must be set before assigning a power sign. A source can impose
the same physical current rise while a voltage probe is wired in the opposite
direction. Its recorded voltage then has the opposite sign. The product $VI$ gives
power entering the labelled positive terminal only when the current reference also
enters that terminal. A graphing package cannot infer this convention from a
waveform; the terminal labels and current arrow must be recorded with the data.

A coil with internal resistance $r$ has terminal voltage

$$
V_{\rm terminal}=L\frac{\d I}{\d t}+rI.
$$

Terminal power separates into magnetic-storage and thermal terms,

$$
V_{\rm terminal}I
=\frac{\d U_L}{\d t}+rI^2.
$$

The $rI^2$ term is energy converted to internal heating. It does not remain
available as recoverable magnetic energy. A measured coil can have a large
terminal-energy input even when its stored energy is modest if the current rise is
slow or the winding resistance is large.

The stored-energy formula is quadratic in current. Doubling current at fixed
inductance quadruples $U_L$. Doubling inductance at fixed current doubles $U_L$.
Those scalings guide design, but they also raise practical limits. A winding can
overheat from resistance before the desired current is reached; a magnetic core can
leave its linear range; insulation and switching components must tolerate the
voltage needed to establish or interrupt the current.

$$
% caption: Stored energy grows with the square of current for a linear inductor. Doubling the current from one unit to two multiplies the stored energy by four, so equal current steps add progressively more energy.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->,black] (0,0)--(5.4,0) node[right] {current};
\draw[->,black] (0,0)--(0,3.6) node[above] {stored energy};
\draw[acc,very thick] plot[domain=0:4.2,samples=100] (\x,{0.18*\x*\x});
\draw[black,dashed] (2.1,0)--(2.1,0.79);
\draw[black,dashed] (0,0.79)--(2.1,0.79);
\draw[black,dashed] (4.2,0)--(4.2,3.17);
\draw[black,dashed] (0,3.17)--(4.2,3.17);
\node[below] at (2.1,-0.08) {one unit};
\node[below] at (4.2,-0.08) {two units};
\node[acc,left] at (0,0.79) {$U$};
\node[acc,left] at (0,3.17) {$4U$};
\end{tikzpicture}
$$

### Current, voltage, power, and energy records

A complete measurement records four time-dependent quantities.

- **Current $I(t)$** sets the stored energy through $\tfrac12LI^2$ when the
  inductance is linear.
- **Inductor voltage $V_L(t)$** sets the instantaneous storage power through
  $V_LI$.
- **Terminal voltage** includes resistive and lead drops when the measured device
  is a physical coil rather than an ideal inductor.
- **Energy $U(t)$** is an accumulated quantity, obtained from a state relation or
  from a time integral of power.

Under a prescribed current ramp $I(t)=\alpha t$ with constant $L$,

$$
V_L=L\alpha,\qquad
P_L=L\alpha^2t,\qquad
U_L=\frac12L\alpha^2t^2.
$$

Voltage is constant, power rises linearly, and stored energy rises quadratically.
The three traces have different shapes even though they describe the same energy
transfer. Confusing the area under a current graph with energy ignores the voltage
factor in $P=VI$.

$$
% caption: A constant-slope current ramp gives a linearly rising current, a constant inductor voltage, and a quadratically rising stored energy. The three traces describe one energy transfer yet have different shapes.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\begin{scope}
\draw[->,black] (0,0)--(2.0,0) node[right,black] {time};
\draw[->,black] (0,0)--(0,1.9);
\draw[acc,very thick] (0.1,0.1)--(1.7,1.5);
\node[acc,above] at (0.9,1.6) {current};
\end{scope}
\begin{scope}[shift={(3.1,0)}]
\draw[->,black] (0,0)--(2.0,0) node[right,black] {time};
\draw[->,black] (0,0)--(0,1.9);
\draw[acc,very thick] (0.1,1.0)--(1.7,1.0);
\node[acc,above] at (0.9,1.6) {voltage};
\end{scope}
\begin{scope}[shift={(6.2,0)}]
\draw[->,black] (0,0)--(2.0,0) node[right,black] {time};
\draw[->,black] (0,0)--(0,1.9);
\draw[acc,very thick] plot[domain=0:1.65,samples=60] (\x,{0.53*\x*\x+0.1});
\node[acc,above] at (0.9,1.6) {energy};
\end{scope}
\end{tikzpicture}
$$

A sampled record estimates energy with a quadrature rule. For samples separated by
$\Delta t$, one trapezoidal estimate is

$$
U(t_n)-U(t_0)
\approx
\sum_{k=0}^{n-1}\frac{V_{L,k}I_k+V_{L,k+1}I_{k+1}}{2}\Delta t.
$$

The sign of each product matters. A negative interval contributes energy leaving
the coil. Probe delay, bandwidth, and timing skew can corrupt the product because
the voltage and current must represent the same instant. A calibration pulse with a
known resistance can establish a relative delay before an inductive transient is
integrated.

## Field Energy and Density

The stored energy is associated with the magnetic field created by the current. A
long air-core solenoid makes the connection explicit. For turn density $n$, length
$\ell$, cross-sectional area $A$, and current $I$,

$$
B=\mu_0nI,\qquad
L=\mu_0n^2A\ell.
$$

Substitution into $U_L=\tfrac12LI^2$ gives

$$
U_L=\frac{B^2}{2\mu_0}A\ell.
$$

The factor $A\ell$ is the interior volume of the long-solenoid model. The energy
per unit volume is therefore

$$
u_B=\frac{B^2}{2\mu_0}.
$$

The result applies to vacuum or approximately to air when the magnetic field is
described by $B=\mu_0H$. The energy density has SI unit
$\mathrm{J\,m^{-3}}$. Since $1\ \mathrm{J\,m^{-3}}=1\ \mathrm{Pa}$, magnetic
energy density also has the dimensions of pressure.

$$
% caption: The long-solenoid model confines the magnetic energy to its interior volume. Multiplying the interior energy density by cross-sectional area and length recovers the coil's total stored energy.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[acc,thick,fill=acc!10] (-2.3,-0.5) rectangle (2.3,0.5);
\foreach \x in {-2.3,-1.86,-1.42,-0.98,-0.54,-0.1,0.34,0.78,1.22,1.66,2.1} {\draw[black,thick] (\x,-0.78)..controls(\x+0.16,-0.4)and(\x+0.16,0.4)..(\x,0.78);}
\draw[<->,black] (-2.3,-1.18)--(2.3,-1.18) node[midway,below] {length};
\draw[<->,black] (2.75,-0.5)--(2.75,0.5) node[midway,right] {diameter};
\draw[acc,->,thick] (3.5,1.4)--(1.4,0.3);
\node[acc,right] at (3.5,1.4) {interior volume};
\end{tikzpicture}
$$

The density formula yields a local estimate only after the field distribution is
known. A short solenoid has fringing near its ends. A toroid confines
its field in a curved core region. A coil near ferromagnetic material can have a
strongly nonuniform field. In those cases, integrate energy density over the volume
where the field exists:

$$
U_B=\int_{\mathcal V}u_B\,\d V.
$$

The field-bearing region sets the integration domain, rather than the copper-winding
volume. A large winding volume can surround a small magnetic-energy region; an air
gap can concentrate a substantial share of the energy in a small volume.

## Circuit Energy Balance

Consider a source $V_s$, a resistor
$R$, and an ideal inductor in series. With the passive current direction chosen
around the loop,

$$
V_s=RI+L\frac{\d I}{\d t}.
$$

Multiplication by $I$ produces

$$
V_sI=RI^2+\frac{\d }{\d t}
\left(\frac12LI^2\right).
$$

The left side is source power. The first term on the right is thermal power in the
resistor. The second is the rate of change of stored magnetic energy. This equation
is an energy balance at every instant, including the beginning of a switch action
when the current is zero and the inductor voltage can be large.

At long times after a dc source is connected, the current becomes constant.
Consequently $\d I/\d t=0$, the ideal inductor voltage is zero, and
the source power becomes $RI^2$. That steady power keeps the resistive current
flowing; it does not continue to increase magnetic energy. The stored energy is
then fixed at $\tfrac12LI^2$ until the current changes again.

When the source is removed and a closed resistance path remains, the balance becomes

$$
0=RI^2+\frac{\d U_L}{\d t}.
$$

The negative energy derivative equals the resistor heating rate. In an ideal
source-free RL decay, all initial inductor energy becomes $\int_0^\infty RI^2\,\d t$.
The equality is a strong experimental check: a current waveform, a measured
resistance, and an initial stored-energy estimate should agree within stated
calibration uncertainty.

The usual exponential current trace is a consequence of the same energy equation
and the loop equation. With initial current $I_0$,

$$
I(t)=I_0e^{-t/\tau},\qquad
\tau=\frac{L}{R}.
$$

Squaring the current exponential gives

$$
U_L(t)=\frac12LI_0^2e^{-2t/\tau}.
$$

At one electrical time constant, current has fallen to $e^{-1}$ of its starting
value, while energy has fallen to $e^{-2}$. A report that equates the fraction of
remaining current with the fraction of remaining magnetic energy misses the square
in $U_L\propto I^2$.

$$
% caption: Current and stored energy decay on related but distinct exponential scales. At one time constant the current has fallen to about 0.37 of its start while the energy has fallen to about 0.14.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->,black] (0,0)--(5.6,0) node[right] {time};
\draw[->,black] (0,0)--(0,3.4) node[above] {fraction};
\draw[acc,very thick] plot[domain=0:4.6,samples=120] (\x,{3.0*exp(-\x/1.6)});
\draw[black,thick] plot[domain=0:4.6,samples=120] (\x,{3.0*exp(-2*\x/1.6)});
\draw[black,dashed] (1.6,0)--(1.6,1.10);
\node[acc,left] at (0,1.10) {0.37};
\node[black,left] at (0,0.41) {0.14};
\node[acc,anchor=west] at (2.7,1.5) {current};
\node[black,anchor=west] at (2.7,0.55) {energy};
\node[below] at (1.6,-0.08) {one time constant};
\end{tikzpicture}
$$

An open switch can interrupt the decay path before the energy has been converted to
heat. The inductor then develops the voltage needed to continue current through
available stray capacitance, insulation leakage, a protective diode, or an arc.
The resulting voltage is an energy-routing consequence. A switch rating based only
on steady current omits the stored energy and the transient electric field that can
appear across a gap.

The energy ledger also distinguishes a source that delivers energy to an inductor from
a source that absorbs energy. A controlled current ramp down can return energy to a
storage element or a power supply designed to accept reverse power. The sign of
$V_LI$ identifies the direction at the inductor terminals. Whether that returned
energy is recovered, converted to heat, or dissipated in a clamp depends on the
rest of the circuit.

### Magnetic materials

A linear magnetic medium with constant permeability $\mu$ has field relations
$B=\mu H$ and magnetic energy density

$$
u_B=\frac{B^2}{2\mu}
=\frac12BH
=\frac12\mu H^2.
$$

The air or vacuum expression uses $\mu=\mu_0$. The form $\tfrac12BH$ identifies
the conjugate field quantities. In a nonlinear material,
$B/H$ varies with operating point. The energy density is then obtained from the
area under the $H$--$B$ relation,

$$
u_B(B)=\int_0^B H(B')\,\d B'.
$$

The integral describes energy supplied during a monotonic magnetization path. A
hysteretic material can dissipate energy over a cycle, so the energy returned on
decreasing current can differ from the energy supplied during the rise. A single
constant inductance cannot represent that history dependence over a broad current
range.

$$
% caption: In a linear material the energy density is the triangular area under the straight field line up to the operating point. A nonlinear material replaces the triangle with the integral under its measured curve.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->,black] (0,0)--(5.4,0) node[right] {magnetic B};
\draw[->,black] (0,0)--(0,3.2) node[above] {magnetic H};
\fill[acc!12] (0,0)--(3.2,0)--(3.2,2.0)--cycle;
\draw[acc,very thick] (0,0)--(4.5,2.81);
\draw[black,dashed] (3.2,0)--(3.2,2.0);
\node[acc] at (2.0,0.6) {energy density};
\node[below] at (3.2,-0.08) {operating point};
\end{tikzpicture}
$$

Magnetic cores can raise inductance by increasing flux linkage at a given current.
They also impose limits. Saturation reduces the incremental slope
$\d \Lambda/\d I$, so a current change can require a larger voltage
response than a small-signal inductance predicts. Hysteresis and eddy-current loss
convert part of the supplied energy to heat. Core data must therefore be matched to
the current range, frequency content, temperature, and geometry of the actual
device.

## Magnetic Force and Coupled Coils

Magnetic energy changes when an energized magnetic circuit changes shape. A coil
can pull an iron armature into a smaller gap, attract a movable core, or exert force
between conductors. The force calculation requires a declared electrical constraint.
Holding current fixed is different from isolating a coil so that its flux linkage is
fixed. The source exchanges energy with the circuit in the first case; in the second
case it does not.

Let a linear inductor have an inductance $L(x)$ that depends on a mechanical
coordinate $x$. At fixed current, flux linkage is $\Lambda=LI$. A small displacement
changes source work by

$$
\d W_{\rm source}
=I\,\d \Lambda
=I^2\d L.
$$

The magnetic stored energy changes by

$$
\d U_L
=\frac12I^2\d L.
$$

The remaining half becomes mechanical work. The force in the positive-$x$ direction
is

$$
F_x=\left.\frac{\partial W_{\rm mech}}{\partial x}\right|_I
=\frac12I^2\frac{\d L}{\d x}.
$$

The direction follows the slope of $L(x)$. An actuator is pulled toward a geometry
with larger inductance when current is held fixed. This result does not depend on
assigning a permanent magnetic charge to the core; it follows from the change in
field energy and the work supplied by the current source.

$$
% caption: A movable armature changes the magnetic-path geometry and hence the coil inductance. At fixed current the force points toward increasing inductance, here toward a smaller air gap.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[black,thick,fill=black!10] (0,-0.9) rectangle (1.2,0.9);
\foreach \x in {1.5,1.78,2.06,2.34} {\draw[black,thick] (\x,-0.55)..controls(\x+0.1,-0.24)and(\x+0.1,0.24)..(\x,0.55);}
\draw[black,thick,fill=black!10] (3.2,-0.9) rectangle (4.7,0.9);
\draw[<->,black] (2.6,-1.2)--(3.2,-1.2) node[midway,below] {gap};
\draw[->,acc,very thick] (4.0,1.3)--(3.0,1.3) node[midway,above] {motion};
\node[below] at (0.6,-1.02) {core};
\node[below] at (1.92,-1.02) {winding};
\node[below] at (3.95,-1.02) {armature};
\end{tikzpicture}
$$

The same force can be obtained under fixed flux linkage. Substitute
$I=\Lambda/L$ into the energy:

$$
U_L(\Lambda,x)=\frac{\Lambda^2}{2L(x)}.
$$

At fixed $\Lambda$,

$$
F_x=-\left.\frac{\partial U_L}{\partial x}\right|_\Lambda
=\frac{\Lambda^2}{2L^2}\frac{\d L}{\d x}.
$$

The numerical force agrees with the fixed-current result after the appropriate
current or flux state is inserted. The two derivations differ in energy accounting.
A source maintains current in one experiment and exchanges work while the mechanism
moves. An isolated superconducting loop approximates fixed linkage over a short
interval and has no source-work term of that kind.

A uniform air gap of cross-sectional area $A_g$ and nearly uniform magnetic field
$B_g$ has force scale set by gap energy

$$
U_g\approx\frac{B_g^2}{2\mu_0}A_g g.
$$

At a specified field, the energy decreases as the gap $g$ decreases. The associated
pressure scale is

$$
p_B\approx\frac{B_g^2}{2\mu_0},
\qquad
F\approx p_BA_g.
$$

The formula assumes a uniform gap field, linear air response, and small fringing.
The same units appear in energy density and pressure because moving a boundary by
a distance $\d g$ changes volume by $A_g\d g$. A measured actuator
may depart from this estimate when the gap is wide, the armature saturates, the
force is off-axis, or winding current is controlled by a finite-bandwidth circuit.

$$
% caption: Magnetic pressure across a narrow air gap acts over the gap area. The field-energy density in the gap sets the pressure scale for a first force estimate.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[black,thick,fill=black!10] (0,-0.95) rectangle (1.8,0.95);
\draw[black,thick,fill=black!10] (3.0,-0.95) rectangle (4.8,0.95);
\foreach \y in {-0.6,-0.3,0,0.3,0.6} {\draw[acc,thick,->] (1.85,\y)--(2.95,\y);}
\draw[<->,black] (1.8,-1.3)--(3.0,-1.3) node[midway,below] {air gap};
\draw[->,acc,very thick] (1.05,1.35)--(1.75,1.35);
\draw[->,acc,very thick] (3.75,1.35)--(3.05,1.35);
\node[acc,above] at (2.4,1.42) {attraction};
\node[below] at (0.9,-1.66) {core face};
\node[below] at (3.9,-1.66) {armature face};
\end{tikzpicture}
$$

Force calculations can be checked by units and limiting cases. Since
$I^2\,\d L/\d x$ has unit $\mathrm{A^2H\,m^{-1}}$, it reduces to
$\mathrm{N}$. If the inductance does not change with position, the energy-gradient
force vanishes. Reversing current leaves the ideal $I^2$ force magnitude unchanged,
although current reversal can change the magnetic state of a hysteretic core and
the direction of forces between separate conductors.

### Coupled coils

Two coils can link part of the same magnetic field. In a linear pair with
self-inductances $L_1,L_2$ and mutual inductance $M$, the total magnetic energy is

$$
U=\frac12L_1I_1^2+\frac12L_2I_2^2+MI_1I_2.
$$

The sign of the cross term depends on the chosen current directions and winding
reference marks. It represents a shared field contribution. A physically realizable
linear pair satisfies

$$
|M|\le\sqrt{L_1L_2}.
$$

The equality limit corresponds to ideal complete coupling. Air gaps, flux leakage,
and coil separation reduce the magnitude of $M$. The formula belongs to energy
bookkeeping for coupled magnetic circuits; transformer voltage ratios and AC
operation require their own circuit analysis.

## Measurements and Uncertainty

Three measurements can estimate the energy stored in a coil. Their agreement tests
both the electrical model and the instrumentation.

- **State relation.** Measure inductance in the relevant operating range and record
  current. A linear-coil estimate uses $U_L=\tfrac12LI^2$.
- **Power integration.** Measure inductor voltage and current with matched time
  references, then integrate $\int V_LI\,\d t$ over a current change.
- **Dissipation route.** Disconnect the source through a known resistance and
  integrate $\int RI^2\,\d t$ until current is negligible.

The state relation is compact but depends on the correct value of $L$. The power
integral captures a changing inductance if voltage and current are measured
accurately. The dissipation route relies on a complete known energy path. A physical
test can use all three, then compare their uncertainty ranges.

For sampled data, the voltage channel should measure the inductor voltage rather
than source voltage. A source waveform includes resistor drops, lead resistance,
and switch voltage. Subtracting those terms can recover $V_L$ when direct
differential measurement is unavailable, but every subtracted measurement adds
uncertainty. A low-resistance current shunt may supply current through
$I=V_{\rm shunt}/R_{\rm shunt}$; its inductance and bandwidth become important
during a fast transient.

Timing alignment is often the limiting issue. If voltage leads current by a sample
period, their product can create a false positive or false negative power spike.
Use a common trigger, measure channel delay with a known resistive load, and shift
the records before integration. The residual energy estimate after a complete
source-free decay should approach zero within sensor offsets. A persistent residual
usually indicates a baseline error, incomplete integration window, or energy
remaining in another storage element.

For independent small errors in a linear state estimate,

$$
\frac{\sigma_U}{U}
\approx
\sqrt{\left(\frac{\sigma_L}{L}\right)^2+
\left(2\frac{\sigma_I}{I}\right)^2}.
$$

Current uncertainty enters twice because energy depends on $I^2$. The formula
describes random, independent uncertainty only. A core with current-dependent
inductance, a shunt whose resistance changes with temperature, or a clipped current
probe produces systematic error that should be modelled or bounded separately.

$$
% caption: Stored energy plotted against current squared falls on a straight line of slope one half the inductance. Curvature would signal a changing incremental inductance or an uncorrected measurement effect.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->,black] (0,0)--(5.6,0) node[right] {current squared};
\draw[->,black] (0,0)--(0,3.4) node[above] {stored energy};
\draw[acc,very thick] (0.2,0.15)--(5.0,2.9);
\foreach \x/\y in {0.65/0.30,1.42/0.85,2.08/1.10,2.88/1.68,3.66/1.98,4.52/2.58} {\filldraw[draw=black,fill=black!8] (\x,\y) circle (2pt);}
\node[acc,anchor=west] at (3.3,2.95) {linear f\/it};
\end{tikzpicture}
$$

> **Worked example (Stored-energy measurement and its uncertainty).** An air-core
> inductor has $L=(2.40\pm0.05)\ \mathrm{H}$. A calibrated current sensor reports
> $I=(1.50\pm0.02)\ \mathrm{A}$ after a slow ramp, where the voltage trace confirms
> $\d I/\d t\approx0$. The stored-energy estimate is
>
> $$
> U_L=\frac12(2.40)(1.50)^2
> =2.70\ \mathrm{J},
> $$
>
> and the fractional uncertainty is
>
> $$
> \frac{\sigma_U}{U}
> \approx
> \sqrt{\left(\frac{0.05}{2.40}\right)^2+
> \left(2\frac{0.02}{1.50}\right)^2}
> =0.034,
> $$
>
> so $U_L=(2.70\pm0.09)\ \mathrm{J}$ to two significant uncertainty digits. The current
> term dominates because it enters squared. A subsequent decay through a
> $6.00\ \Omega$ resistor tests the result by integrating the resistor power; the
> electrical time constant is $\tau=L/R=0.400\ \mathrm{s}$.

The calculation does not certify that the coil is lossless. It estimates the
recoverable field energy associated with the stated current and linear inductance.
Winding heat accumulated during the ramp, core loss, and energy in nearby
capacitance require separate measurements when they are significant. A report
should state the time interval, current reference, inductor model, and treatment of
losses alongside the numerical energy.

> **Worked example (Field-energy density and total).** In air or vacuum,
> $u_B=B^2/(2\mu_0)$. A uniform field of $B=0.0200\ \mathrm{T}$ has
>
> $$
> u_B=\frac{(0.0200)^2}{2(4\pi\times10^{-7})}
> =159\ \mathrm{J\,m^{-3}},
> $$
>
> and if that field fills a volume $V=1.73\times10^{-3}\ \mathrm{m^3}$, the magnetic
> energy is
>
> $$
> U_B=u_BV=0.275\ \mathrm{J}.
> $$
>
> The volume must match the field-bearing region: using the outer dimensions of a coil
> form instead of the interior field volume can change the estimate by a large factor.
> The quadratic field scaling is also visible here — doubling $B$ multiplies energy
> density by four.

### Electric and magnetic storage

Capacitors and inductors store energy in different field configurations. A capacitor
stores electric-field energy,

$$
U_C=\frac12CV^2=\frac{Q^2}{2C},
$$

whereas an inductor stores magnetic-field energy,

$$
U_L=\frac12LI^2=\frac{\Lambda^2}{2L}.
$$

The variables $V$ and $I$ play complementary roles in elementary circuit dynamics.
A capacitor resists an abrupt voltage change because changing its charge requires
current. An inductor resists an abrupt current change because changing its flux
linkage requires voltage. Energy can move back and forth between the two in an LC
system, while resistance converts some of it to heat.

In empty space, the energy-density formulas are

$$
u_E=\frac12\epsilon_0E^2,\qquad
u_B=\frac{B^2}{2\mu_0}.
$$

Electromagnetic waves contain both contributions. In a plane wave in vacuum their
time-averaged contributions are equal. In a near-field storage device, the energy
can be predominantly electric or predominantly magnetic depending on geometry and
operating frequency. A circuit diagram alone does not identify the spatial
distribution; the field solution and component geometry do.

An LC exchange makes the time dependence explicit. In the ideal lossless model,

$$
U_C(t)+U_L(t)=U_{\rm total}.
$$

When capacitor voltage is largest, current is zero and inductor energy is zero.
One quarter cycle later, capacitor voltage is zero, current magnitude is largest,
and magnetic energy reaches the total. Real resistance, radiation, dielectric loss,
and core loss reduce the total from cycle to cycle. The energy balance remains a
diagnostic because every loss channel appears as a positive dissipative term.

$$
% caption: Ideal LC storage alternates between electric and magnetic forms while the total energy stays constant. The two component curves are out of phase and sum to the horizontal total-energy line.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->,black] (0,0)--(5.6,0) node[right] {time};
\draw[->,black] (0,0)--(0,3.2) node[above] {energy};
\draw[acc,very thick] plot[domain=0:5.0,samples=160] (\x,{0.1+2.1*(cos(deg(3.1416*\x/5.0)))^2});
\draw[black,thick] plot[domain=0:5.0,samples=160] (\x,{0.1+2.1*(sin(deg(3.1416*\x/5.0)))^2});
\draw[black,dashed] (0,2.3)--(5.0,2.3) node[right,black] {total};
\node[acc,anchor=west] at (3.7,2.85) {magnetic};
\node[black] at (2.5,2.85) {electric};
\end{tikzpicture}
$$

## Storage Limits and Model Scope

An energy target does not determine a feasible inductor by itself. The relevant
limits include peak current, winding temperature, magnetic-core state, insulation
voltage, mechanical force, and stored-energy discharge path. A design record should
list the limiting quantity and the event at which it applies. Peak current may occur
at the end of a charge ramp, peak voltage may occur at interruption, and peak
temperature may occur after repeated cycles.

Winding loss follows

$$
P_{\rm winding}=I^2R_{\rm winding}.
$$

At constant current, stored energy is fixed while winding heat continues to grow
linearly with time. A high-inductance coil can therefore be a poor energy-storage
device if its required current produces excessive resistance loss. Increasing wire
cross section reduces resistance, but it can enlarge the winding and alter
inductance, thermal path, and magnetic geometry.

Core saturation changes the relation between current and flux linkage. The
incremental inductance

$$
L_{\rm inc}=\frac{\d \Lambda}{\d I}
$$

can decrease sharply near saturation. A voltage source then drives a larger current
slope because $V_L=L_{\rm inc}\,\d I/\d t$. The energy calculation
must use the measured linkage curve or a field model over that range. Applying a
small-signal inductance to a saturated high-current pulse can overstate stored
energy and understate current rise.

Insulation and switch limits are set by voltage, not by stored energy alone. The
ideal inductor law states

$$
V_L=L\frac{\d I}{\d t}.
$$

A rapid forced interruption of a fixed initial current requires a large voltage. A
clamp circuit reduces voltage by allowing current to decay more slowly or by
directing energy into a controlled absorber. The suitable clamp must have both a
voltage rating and an energy rating for the event sequence. Repeated pulses can
exceed its thermal rating even when one pulse is safe.

Mechanical integrity can also limit stored energy. Magnetic pressure across a gap
can load pole faces and fasteners. Current-carrying conductors experience forces
from their own and neighbouring fields. A winding may be stable at low current yet
move, vibrate, or rub insulation during a high-current pulse. Mechanical design
uses the field-force estimate together with temperature expansion, support stiffness,
and fault-current conditions.

## Numerical Field-Energy Estimates

Many magnetic-storage geometries do not have one uniform field and one obvious
volume. A measured or computed field map can still yield an energy estimate. Divide
the field-bearing region into small cells of volume $\Delta V_k$, measure or
calculate a representative field $B_k$, and form

$$
U_B\approx\sum_k\frac{B_k^2}{2\mu_0}\Delta V_k.
$$

In a linear magnetic medium, replace $\mu_0$ by the relevant constant
permeability. In a nonlinear medium, use an energy density from the local
$H(B)$ curve. The calculation must resolve regions where field magnitude changes
rapidly because energy density depends on the square of $B$. Averaging $B$ over a
cell before squaring can underestimate energy when the field is strongly nonuniform.

Measurement begins with a spatial reference. A Hall probe reports one component of
field along its sensitive axis. Its position, orientation, offset, and calibration
must be recorded. A vector field can require three orthogonal components or a probe
that is rotated through known angles. Near a coil surface, a probe volume samples an
average over a finite region; the probe itself can perturb a small air gap or alter
the spacing being measured.

An axisymmetric device such as a long solenoid permits a two-dimensional map to be
revolved about the axis. A small annular cell at radius $r$ has volume

$$
\Delta V\approx2\pi r\,\Delta r\,\Delta z.
$$

The radial factor is essential. Treating each rectangular plot cell as the same
three-dimensional volume gives too much weight to data near the axis and too little
weight to data at large radius. Toroids require a similar geometrical volume factor
around their circular path.

Convergence should be checked by refining the map or simulation mesh. Compute energy
on an initial grid, refine the cells in high-gradient regions, and compare the
result. A changing estimate indicates unresolved field structure or an insufficient
domain. The outer boundary matters as well: a coil's fringe field extends beyond
the region that looks visually important. Truncating the domain at a convenient
box can omit energy in the surrounding space.

Numerical energy should be checked against a circuit estimate when both are
available. With a linear coil at current $I$, compare $\tfrac12LI^2$ with the
field-volume integral. A difference can indicate omitted fringe volume, incorrect
material data, or a flux-linkage calculation that uses a different current path.
Agreement alone does not prove every local field value; it is one constraint on the
whole model.

### Energy release and fault paths

Stored energy remains in a coil after the drive source is disconnected. A safe
design identifies the intended path before a switch action occurs. The path may be
a resistor, a controlled semiconductor clamp, a second energy-storage element, or a
source that can accept returned power. Each path has a current, voltage, energy, and
thermal limit.

A resistor absorbs magnetic energy as heat. Given initial energy $U_0$, the
minimum thermal capacity of the element must exceed the energy delivered in one
event with margin for its initial temperature and cooling interval. Its voltage
during early decay is approximately $I_0R$. Increasing $R$ shortens the electrical
time scale $L/R$ and raises initial voltage. A design therefore selects a resistance
within both decay-time and voltage limits.

An unintended open circuit has no designed resistive path. Parasitic capacitance can
temporarily receive energy,

$$
U_C=\frac12CV^2.
$$

Equating it with initial magnetic energy gives a voltage scale

$$
V\approx I_0\sqrt{\frac{L}{C}}.
$$

Even a small stray capacitance can lead to a large voltage because the stored
magnetic energy transfers into an electric field over a short interval. An arc,
insulation breakdown, or clamp can then create a new current path. The event may
damage contacts or produce electromagnetic interference, so intentional discharge
hardware is preferable to relying on parasitics.

Superconducting windings remove most dc winding resistance, so their stored energy
can remain for a long interval. They still require quench detection and an energy
extraction path. A local transition to resistive material can convert energy to heat
in a small region. The current, field, structural force, and cryogenic state must be
considered together. Zero dc resistance changes the loss model; it does not remove
magnetic energy or its discharge requirements.

## Two Routes to the Stored Energy

The circuit formula $\tfrac12LI^2$ and the field integral $\int u_B\,\d V$ must return
the same stored energy. A solenoid lets both be evaluated in closed form.

> **Worked example (Solenoid energy by two routes).** Take a long air-core solenoid
> with $N=1200$ turns, length $\ell=0.200\ \mathrm{m}$, cross-sectional area
> $A=5.00\times10^{-4}\ \mathrm{m^2}$, and operating current $I=1.50\ \mathrm{A}$. The
> long-solenoid approximation gives
>
> $$
> L=\mu_0\frac{N^2A}{\ell}
> =(4\pi\times10^{-7})
> \frac{(1200)^2(5.00\times10^{-4})}{0.200}
> =4.52\times10^{-3}\ \mathrm{H},
> $$
>
> so the circuit-storage value is
>
> $$
> U_L=\frac12LI^2
> =\frac12(4.52\times10^{-3})(1.50)^2
> =5.09\times10^{-3}\ \mathrm{J}.
> $$
>
> The same geometry predicts an interior field
>
> $$
> B=\mu_0\frac{N}{\ell}I
> =1.13\times10^{-2}\ \mathrm{T},
> $$
>
> and with interior volume $A\ell=1.00\times10^{-4}\ \mathrm{m^3}$ the field-energy
> route gives
>
> $$
> U_B=\frac{B^2}{2\mu_0}A\ell
> =5.09\times10^{-3}\ \mathrm{J}.
> $$
>
> The two routes agree because they share the long-solenoid assumptions; the match is
> an algebra and unit check, not an independent confirmation. The circuit method starts
> from flux linkage, the field method from energy density and volume, so an error in
> area, turn density, or the factor one half shows up differently in each.

$$
% caption: The circuit route and the field route reach the same stored energy. Inductance and current give one half L I squared; energy density and interior volume give the volume integral of the density.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[black,thick,fill=black!8] (0,1.0) rectangle (1.7,1.7);
\draw[black,thick,fill=black!8] (0,0.0) rectangle (1.7,0.7);
\node at (0.85,1.35) {inductance};
\node at (0.85,0.35) {current};
\draw[black,thick,fill=black!8] (5.6,1.0) rectangle (7.5,1.7);
\draw[black,thick,fill=black!8] (5.6,0.0) rectangle (7.5,0.7);
\node at (6.55,1.35) {energy density};
\node at (6.55,0.35) {interior volume};
\draw[acc,thick,fill=acc!10] (3.05,0.5) rectangle (4.55,1.2);
\node at (3.8,0.85) {stored energy};
\draw[->,black,thick] (1.7,1.35)--(3.05,1.0);
\draw[->,black,thick] (1.7,0.35)--(3.05,0.7);
\draw[->,black,thick] (5.6,1.35)--(4.55,1.0);
\draw[->,black,thick] (5.6,0.35)--(4.55,0.7);
\node[below] at (0.85,-0.25) {circuit route};
\node[below] at (6.55,-0.25) {spatial route};
\end{tikzpicture}
$$

The example contains idealizations that should be tested before it is used for a
physical coil. The winding is assumed long compared with its diameter. End fringing
is ignored. The current distribution is assumed uniform, the magnetic response is
that of air, and the coil is treated as a lumped component. A short coil can have a
smaller central field and a larger fraction of energy outside the nominal interior
volume. A metal support or nearby conductor can alter the field and add eddy-current
loss during a changing current.

Suppose the current is uncertain by $1.3\%$, the area by $1.0\%$, and the length by
$0.5\%$, while turn count is exact. The fractional uncertainty in the energy
calculated from geometry and current is approximately

$$
\frac{\sigma_U}{U}
\approx
\sqrt{\left(\frac{\sigma_A}{A}\right)^2+
\left(\frac{\sigma_\ell}{\ell}\right)^2+
\left(2\frac{\sigma_I}{I}\right)^2}
=2.8\%.
$$

The current term remains dominant because it enters squared. A direct inductance
measurement can replace the geometric estimate and shift the uncertainty budget
toward current calibration, voltage-probe timing, and the chosen current event.

### Experimental procedure and data checks

A laboratory energy measurement should begin in a low-current range where the
inductance is approximately constant. Record the coil's dc resistance with a
four-terminal method or a calibrated current-voltage measurement. Apply several
slow current levels, allow the current and temperature to settle as required by the
model, and record current, coil-terminal voltage, and a field probe value at a
defined position. The current sweep establishes whether $U$ follows an $I^2$ law
and whether the field scales linearly with current.

A transient measurement adds timing requirements. Use a source pulse that produces
a smooth current change, measure voltage directly across the coil, and record a
common trigger. Integrate $V_LI$ over the same event window. A current rise followed
by a controlled decay provides two energy estimates: energy entering during the
rise and energy dissipated during decay. Their difference should be explained by
winding loss, core loss, stored electric energy, measurement offsets, or an
incomplete time window.

Keep calibration records with the data. A current sensor has gain and offset. A
Hall probe has gain, offset, angular sensitivity, and temperature dependence.
A differential voltage probe has finite common-mode range and frequency response.
An energy integral magnifies a small dc offset when the integration window is long.
Subtract baseline values measured with the same sensor settings, then include the
baseline uncertainty in the result.

Use these checks to catch common errors.

- **Units:** $\mathrm{H\,A^2}$ reduces to joules; $\mathrm{T^2/\mu_0}$ reduces
  to joules per cubic metre.
- **Current scaling:** a linear inductor has $U(2I)=4U(I)$.
- **Energy direction:** a rising current has positive storage power under the
  passive convention; a controlled decay has negative storage power.
- **Geometry:** the field-volume integral uses the field-bearing volume, including
  fringe regions when their contribution is material.
- **Event definition:** the current used in $\tfrac12LI^2$ must be tied to a
  labelled time in the voltage and switch records.

### Scope and reporting

The lumped formula $\tfrac12LI^2$ is accurate when a component has a well-defined
linear inductance, the relevant current is known, and the electromagnetic transit
time is much shorter than the circuit time scale. A large distributed winding, a
fast pulse, or a geometry with significant capacitance can require a transmission
line or field simulation. A nonlinear core requires a measured linkage curve or a
magnetic-material model. A switching event with arcing or breakdown requires a
new circuit topology once the path changes.

Report magnetic storage with its model and event. A complete statement gives the
current, the inductance or field map, the geometry or calibration source, the
energy result with uncertainty, and the assumed discharge path. For example,
“At the labelled peak current, the linear-coil model gives the stated stored energy;
the controlled resistor path receives that energy during the measured decay.” The
same statement makes clear what a later field map, core test, or high-speed voltage
record could refine.

Flux linkage and current determine circuit storage; field magnitude and volume
determine spatial storage; power measurements track the transfer between source,
coil, heat, and mechanical motion. The chosen current path determines where the
energy goes when a drive source changes state.

### Arbitrary current programs and nonlinear linkage

The expression $U_L=\tfrac12LI^2$ applies when flux linkage is proportional to
current with one constant $L$. A prescribed current waveform can have any shape:
step-limited ramp, triangle, pulse train, sinusoid, or feedback-controlled path.
In a linear inductor, the energy at a given current depends only on the current
state, not on the waveform used to reach it. A slow ramp and a fast ramp end with
the same ideal magnetic energy at the same $I$, although they can produce different
resistive, core, and radiation losses.

With a nonlinear but single-valued linkage curve $\Lambda(I)$, start from electrical
power:

$$
P=VI=I\frac{\d \Lambda}{\d t}.
$$

The energy required to increase current from zero to $I$ is

$$
U(I)=\int_0^I I'\frac{\d \Lambda}{\d I'}\,\d I'
=\int_0^\Lambda I(\Lambda')\,\d \Lambda'.
$$

The two forms use the same area under the constitutive curve with axes exchanged.
If $\Lambda=LI$, evaluation gives $\tfrac12LI^2$. If the slope changes with
current, inserting one nominal inductance can produce an energy estimate with no
clear operating-point meaning. A measured $\Lambda$--$I$ table can be integrated
numerically without forcing it into a linear fit.

$$
% caption: For a nonlinear inductor the stored energy is the area under the measured current-linkage curve up to the operating linkage. A constant inductance replaces this area with a triangle only when the curve is straight.
\begin{tikzpicture}[>=stealth,font=\footnotesize]
\definecolor{acc}{HTML}{4A6FA5}
\draw[->,black] (0,0)--(5.6,0) node[right] {linkage};
\draw[->,black] (0,0)--(0,3.4) node[above] {current};
\fill[acc!12] plot[domain=0.2:2.5,samples=60] (\x,{0.15+0.1*\x+0.13*\x*\x}) -- (2.5,0) -- (0.2,0) -- cycle;
\draw[acc,very thick] plot[domain=0.2:3.9,samples=90] (\x,{0.15+0.1*\x+0.13*\x*\x});
\foreach \x in {0.5,1.2,1.9,2.6,3.3} {\filldraw[draw=black,fill=black!8] (\x,{0.15+0.1*\x+0.13*\x*\x}) circle (1.5pt);}
\draw[black,dashed] (2.5,0)--(2.5,1.21);
\node[acc,anchor=west] at (2.5,3.0) {measured curve};
\node[acc] at (1.3,0.4) {energy};
\node[below] at (2.5,-0.08) {operating linkage};
\end{tikzpicture}
$$

Incremental inductance is a local slope,

$$
L_{\rm inc}(I)=\frac{\d \Lambda}{\d I}.
$$

The immediate voltage response to a small current perturbation is

$$
V=L_{\rm inc}(I)\frac{\d I}{\d t}.
$$

Stored energy depends on the full path from zero current to the operating state.
Incremental inductance alone cannot determine that total unless the linkage curve
is linear over the entire range. This distinction matters in a saturated core:
high-current pulses can have a small local slope while retaining energy accumulated
through lower-current states.

Hysteresis adds another qualification. If the linkage curve follows different paths
during rise and fall, a closed cycle encloses energy converted to material loss.
The energy returned to the external circuit during a current decrease can then be
less than the energy supplied during the increase. The difference appears as core
heating and may depend on frequency, peak field, temperature, and prior magnetic
history.

### Common analysis errors

Several checks prevent a magnetic-energy calculation from drifting away from its
physical model.

- **Factor one half.** Energy is the integral of a current that rises from zero;
  using $LI^2$ doubles the linear-inductor result.

- **Energy density evaluated from average field.** Compute or measure local
  $B^2$ before volume integration. Squaring an average can miss high-field cells.

- **Resistance counted as stored energy.** The $I^2R$ term is heat. It belongs in
  the source-energy balance, while $\tfrac12LI^2$ represents ideal field storage.

- **A current event without a time label.** Peak current, steady current, and
  current just before a switch opens can differ. Link the energy calculation to a
  recorded event.

- **Nominal inductance applied beyond its range.** A core, a movable armature, or
  a nearby conductor can make linkage nonlinear or position dependent.

- **An assumed energy path after interruption.** The discharge resistor, clamp,
  parasitic capacitor, or arc determines the subsequent voltage and heating.

The dimensions provide a final rapid check.

$$
[\mathrm{H\,A^2}]
=[\mathrm{Wb\,A}]
=[\mathrm{V\,A\,s}]
=\mathrm{J},
$$

and

$$
\left[\frac{B^2}{\mu_0}\right]
=\mathrm{J\,m^{-3}}.
$$

The first identity connects inductance to circuit energy. The second connects field
strength to spatial energy density. A result in watts has stopped at a power
calculation; multiplication by a time interval or integration is still required to
obtain energy.

### From a calculation to a device claim

A stored-energy value answers one question: how much recoverable magnetic-field
energy is present at a stated current and state of the device. It does not by itself
specify continuous power, pulse repetition rate, actuator travel, or delivered output.
Those quantities require a time scale and an energy path. A coil holding
$10\ \mathrm{J}$ can release that energy slowly through a resistor, rapidly through
a high-voltage clamp, or partly into mechanical motion. The same initial energy
therefore supports different device behaviour under different circuit constraints.

For repeated operation, compare energy per event with the interval between events.
If a fraction $f_{\rm loss}$ becomes heat each cycle at repetition rate $q$, the
average loss power is

$$
\overline P_{\rm loss}=f_{\rm loss}U_{\rm event}q.
$$

The relation separates energy capacity from thermal duty. A component can survive
one stored-energy discharge while overheating during repeated pulses. Cooling,
thermal mass, winding resistance, core loss, and the discharge path determine the
allowed duty cycle. A test report should include the initial component temperature,
event rate, current waveform, and the time allowed for cooling.

Magnetic-force work is bounded by the available energy change. If an actuator
starts and ends at nearly the same current and geometry, its net magnetic-energy
change is small even if the instantaneous force was large. If it moves from a low
inductance geometry to a high inductance geometry at controlled current, the source
delivers both the field-energy change and the mechanical work. These distinctions
keep a force estimate, an energy estimate, and a source-power estimate in their
proper roles.

An accurate final statement names three things: the stored energy at a labelled
current; the current-dependent linkage model or field map; and the intended route for
energy after the drive condition changes. Those records make the calculation
checkable, measurable, and applicable to the circuit or device being designed.

When two energy estimates disagree, preserve both records before selecting a model.
Compare their event times, current references, voltage-polarity convention, field
volume, and calibration corrections. The discrepancy often identifies a physical
loss path or geometric region that the simpler calculation excluded. Repeating the
test at a lower current can distinguish an instrumental offset from a nonlinear
magnetic response.
