HuntsvilleEngineers mark
HE Reference Shelf — huntsvilleengineers.com
The Reference Shelf · Analysis & Transforms

Line and surface integrals

Adding up a field as you march along a path or spread across a surface — that sum is the work, the EMF, or the flux you actually care about.

Also known as: path integral · flux integral · work integral · circulation

The formula

Line integral of a scalar field (arc-length integral):

∫_C f ds = ∫_a^b f(r(t)) · |r'(t)| dt

Reads: walk the curve C, sample f at each point, and weight every sample by how fast you're covering ground. ds is a scrap of arc length.

Line integral of a vector field (the work / circulation integral):

∫_C F · dr = ∫_a^b F(r(t)) · r'(t) dt

Reads: only the part of F that points along your direction of travel counts. Dot product throws away the sideways component. Along a closed loop this same integral is the circulation, written with a circle on the sign:

Γ = ∮_C F · dr

Surface integral of a scalar field:

∬_S f dS = ∬_T f(r(s,t)) · |r_s × r_t| ds dt

Reads: parametrize the surface with two knobs (s,t); the cross product of the two partial-derivative vectors gives the area of the little patch each knob-step sweeps out.

Surface integral of a vector field (the flux integral):

Φ = ∬_S F · dS = ∬_T F(r(s,t)) · (r_s × r_t) ds dt

Reads: only the part of F poking through the surface counts. dS = n̂ dS is a patch of area pointing along the outward normal. Field lying flat against the surface contributes zero flux.

The three theorems that make these tractable:

∮_C F · dr = ∬_S (∇ × F) · dS      (Stokes / Kelvin–Stokes)
∯_S F · dS = ∭_V (∇ · F) dV        (Gauss / divergence theorem)
∫_C ∇g · dr = g(end) − g(start)     (fundamental theorem for line integrals)

Reads, in order: circulation around a loop equals the curl piled up over any surface the loop bounds; total flux out of a closed surface equals the divergence piled up inside it; if the field is a gradient, the path doesn't matter — only the endpoints.

Where you meet it

  • EMF around a loop on the bench. Faraday's law is a line integral of E around a closed loop set equal to the rate of change of a flux integral of B through the loop: ∮ E·dr = −dΦ_B/dt. Every transformer turns-ratio calc, every rogowski coil, every eddy-current probe is that equation wearing different clothes. When a strain-gauge lead loop picks up 60 Hz hum on a test stand, you're fighting a flux integral you didn't mean to enclose.

  • Antenna gain and radiated power at a design review. Total radiated power is the flux integral of the Poynting vector over a sphere around the antenna: P = ∯ S·dS. Power density on that sphere, divided into that total, is where directivity and gain numbers come from. The review board asking "does this close the link budget" is asking whether your flux integral over the receive aperture clears the noise floor.

  • Work and pumping energy on a fluid or structural job. Work done by a force field moving a part along a path is W = ∫ F·dr. Same integral sizes the energy to push flow along a duct, or the work a cam does over one rotation. If the force is conservative (a gradient of potential), you skip the integral entirely and subtract two endpoint values — which is why a spring's stored energy doesn't depend on the wiggly path you took to compress it.

  • Mass or heat flow through a control surface. Flow rate through a cross-section is the flux integral of velocity (times density) over that area. The divergence theorem is how a CFD solver turns "what's leaking out of this cell" into a volume balance — conservation of mass falls straight out of ∯ (ρv)·dS = 0 for steady flow.

How it works

The whole subject is one idea: pick a parametrization, and the intimidating symbol collapses into an ordinary single or double integral you can hand to a calculator. dr becomes r'(t) dt. dS becomes |r_s × r_t| ds dt. Everything after that is bookkeeping.

Numbers to anchor it. Take the swirling field F = (−y, x) around the unit circle, counterclockwise. Its circulation ∮ F·dr comes out to 2π ≈ 6.283. That's not an accident — Green's theorem says it equals the curl (which is a constant 2 here) times the enclosed area π. Now take the radial field F = (x, y, z) through the unit sphere: the flux ∯ F·dS is 4π ≈ 12.566, matching the divergence (a constant 3) times the sphere's volume 4π/3. Run the arc-length integral of the constant 1 around the unit circle and you get — the circumference — because the scalar line integral of 1 is just "how long is the path."

The mistake people make is on orientation. Reverse the direction you walk a curve and the vector line integral flips sign; the scalar arc-length integral does not. Flip a surface's chosen normal and the flux flips sign. Stokes' theorem only works if the loop's direction and the surface's normal obey the right-hand rule together — curl the fingers of your right hand around the loop, the thumb is the normal. Get that backward and your EMF has the wrong sign, which on a real board means your feedback loop is now positive and your amplifier is an oscillator.

The second trap is assuming path-independence when you don't have it. ∫ F·dr depends only on endpoints if and only if F is conservative — meaning F = ∇g for some potential, equivalently ∇ × F = 0 on a simply-connected domain. Gravitational and electrostatic fields qualify; the magnetic field around a current-carrying wire does not — Ampère's law says its circulation around the wire is the enclosed current, not zero, even though its curl vanishes everywhere off the wire (the domain has a hole in it, so curl-free isn't enough). The field that actually lets you extract net energy going around a loop is the electric field induced when the enclosed magnetic flux changes — Faraday's ∮ E·dr = −dΦ_B/dt — which is what a transformer runs on, and why "voltage" between two points gets slippery once time-varying magnetic fields are in the room. Test it before you trust it: compute the same work integral along two different paths sharing the same endpoints. For the swirling field F=(−y,x), going from (1,0) to (−1,0) along the top half of the unit circle gives +π; the bottom half gives −π. They disagree, so the field is not conservative and endpoints alone won't save you. Equivalently, its 2π circulation around the full circle already sinks it — a conservative field integrates to zero around any closed loop.

Limits of validity worth remembering: the divergence and Stokes theorems assume the field is smooth (differentiable) over the whole region. A point charge, a line current, a crack tip — any singularity inside your surface — and the theorem's volume integral blows up or misses the enclosed source. That's not a bug; it's Gauss's law telling you a charge is in there. The fix is to exclude the singularity with a small surface and account for it separately, which is the whole trick behind residues and behind Ampère's law with enclosed current.

History

The pieces arrived out of order and got the wrong names, which is normal for this stuff. Lagrange was working with surface integrals by 1760 and, by most accounts, had the divergence theorem itself in hand around 1762 — a full lifetime before it got anyone's name attached [1]. Carl Friedrich Gauss proved special cases in 1813 while grinding through the gravitational pull of an ellipsoid, and returned to it in the 1830s [1]. The first proof of the general divergence theorem came from Mikhail Ostrogradsky in 1826, out of his work on heat flow — which is why much of the Russian and French literature calls it Ostrogradsky's theorem, and why the fair name is really Gauss–Ostrogradsky [1].

George Green, a self-taught miller's son in Nottingham, published his essay on applying analysis to electricity and magnetism in 1828 and proved the special cases that carry his name today [1]. He had almost no formal schooling when he wrote it and printed it by subscription; the mathematical world barely noticed until after his death.

The best-named theorem of the bunch may be the most misattributed. Stokes' theorem was first written down by William Thomson — Lord Kelvin — in a letter to George Gabriel Stokes on July 2, 1850 [2][4]. Stokes never claimed to have invented it. What he did was set it as a problem on the 1854 Smith's Prize examination at Cambridge [2][3][4]. Among the students who sat that exam was James Clerk Maxwell — he tied for first — and he met the result as an exam question with Stokes' name on the paper; the name stuck to the theorem instead of to the exam [2][4]. So the theorem that ties circulation to curl, the one every field engineer leans on through Maxwell's equations, is named for the man who graded it, not the man who found it.

Related tools

  • /tools/transformer-turns
  • /tools/skin-depth
  • /tools/rf-power-density
  • /tools/link-budget
  • /tools/inductor-energy

Sources

  1. https://en.wikipedia.org/wiki/Divergence_theorem
  2. https://en.wikipedia.org/wiki/Generalized_Stokes_theorem
  3. https://www.newworldencyclopedia.org/entry/George_Gabriel_Stokes
  4. Victor J. Katz, "The History of Stokes' Theorem," Mathematics Magazine 52 (1979), 146–156 — https://www.jstor.org/stable/2690275

Written by HE in our own words from the cited sources — engineering judgment included, your stamp still required. All entries →

★ The Reference Shelf

Reading is free. The shelf is for cardholders.

Your library card is an email address: pin it to your shelf, print the card, take the FE/PE quick-reference pack, read the Huntsville history. The shelf remembers what you reach for.

Already on the list? Enter with your subscribed email →