Curl, Divergence and Green’s Theorem

Paddle wheels that measure swirl, tiny circulations that cancel, and the planimeter, a machine that measures area by walking round it

Curl, Divergence and Green’s Theorem

Drop a tiny paddle wheel into a stream and it may turn; drop a blob of dye and it may swell. Those two responses are the curl and the divergence of the flow, and Green’s theorem says that adding them up over a region gives exactly what happens at its edge. Inside, everything cancels. Engineers built that cancellation in brass: an instrument that measures the area of any shape by running a pointer once round its outline.

The Paddle Wheel and the Dye

Drag the paddle wheel anywhere in the flow and let go to release a ring of dye. The wheel’s turning measures curl, the dye’s swelling measures divergence. Compare the shear flow, whose straight streamlines still turn the wheel, with the vortex, whose circular streamlines do not.

curl F = ∂Q/∂x − ∂P/∂y = −1
div F = ∂P/∂x + ∂Q/∂y = 0
−1.000
curl F at the hub
0.000
wheel spin Γ/(2πr²) ≈ curl/2
0.000
div F at the hub
1.00×
dye area now (∫ div predicts 1.00×)
Shear flow: every streamline is a straight line, yet the water above the wheel moves faster than the water below, so it turns clockwise. Curl −1. The wheel has turned 0.00 times.

The wheel turns at Γ/(2πr²), where Γ = ∮ F · dr round its rim (radius 0.34), the average angular velocity of the fluid touching it; as r → 0 this tends to curl F/2. It is a massless ideal wheel that does not disturb the flow. The dye ring is carried point by point (midpoint steps, capped near singularities) and refined where it stretches; its area is the shoelace formula, compared with exp(∫ div F dt) along the path of its centre, which is exact only for a small blob or a constant divergence. Animation time is scaled so the flow is visible.

Go deeper:Curl and Divergence as Rates

For a plane field F = (P, Q), both derivatives are limits of small loop integrals. Take a small circle C_r of radius r about a point p, enclosing area πr²:

curl F(p) = ∂Q/∂x − ∂P/∂y = lim_(r→0) (1/πr²) ∮_(C_r) F · dr

div F(p) = ∂P/∂x + ∂Q/∂y = lim_(r→0) (1/πr²) ∮_(C_r) F · n ds

The circulation ∮ F · dr adds up the flow along the rim of the wheel. Dividing by the rim length 2πr gives the average tangential speed, and dividing again by r turns it into an angular velocity: Γ/(2πr²), which tends to curl F/2. The factor of two is no accident. A rigid rotation with angular velocity ω has F = ω(−y, x) and curl 2ω: a wheel carried round by it turns at ω, like the Moon keeping one face to the Earth.

The shear flow F = (y, 0) has straight streamlines, yet water above the wheel moves faster than water below, so curl F = −1 and it turns clockwise. The vortex F = (−y, x)/(x² + y²) does the opposite: its streamlines are circles, but the speed falls off as 1/r, and the faster inner edge and the longer, slower outer edge balance exactly. Its curl is zero everywhere except at the centre, where the field is not defined; a wheel whose rim encloses the centre picks up circulation 2π.

Divergence is a rate of change of area. A small patch of fluid of area A carried by the flow obeys dA/dt ≈ (div F) A, so in a field of constant divergence the area grows exponentially, as the dye does in the source. Where div F = 0 the flow is incompressible: the dye is sheared and stretched but keeps its area.

Tiny Circulations Cancel

Each little square carries its own circulation, drawn as arrows round its edges. Press Cancel and watch the shared inner edges vanish in pairs. Only the boundary survives, and the three totals agree. Refine the grid, drag your own region, or switch to the flux form.

F = (x cos(y), y sin(x)), curl F = y cos(x) + x sin(y)
1.0811
∮_C F · dr round the curve
1.4709
sum of the 42 tiles’ circulations
1.0810
∬_R curl F dA
168
edge arrows still showing
Each of the 42 tiles carries its own circulation. On every inner edge two arrows sit side by side, one from each tile, pointing opposite ways with opposite colours. Press Cancel and watch them annihilate in pairs.

A tile belongs to the region when its centre does. Each edge integral is computed once, by 4-point Gauss–Legendre, and used with opposite signs by the two tiles that share it, so the sum over tiles equals the staircase sum to rounding error. The curve integral uses Gauss–Legendre along C; ∬ is an iterated integral over vertical slices of the region, computed without Green’s theorem, so its agreement with ∮_C is a genuine check. Hover over a tile to compare its circulation with the curl times its area.

Go deeper:Green’s Theorem

Let R be a region in the plane bounded by a piecewise smooth simple closed curve C, traversed counterclockwise (so the region is on the left), and let P and Q have continuous partial derivatives on and inside C. Then

∮_C P dx + Q dy = ∬_R (∂Q/∂x − ∂P/∂y) dA

Applied to the field (−Q, P) it gives the flux form, the divergence theorem in the plane:

∮_C F · n ds = ∬_R (∂P/∂x + ∂Q/∂y) dA

For a rectangle [a, b] × [c, d] the proof is the fundamental theorem of calculus, once in each direction: ∬ ∂Q/∂x dx dy = ∫_c^d (Q(b, y) − Q(a, y)) dy, which is the line integral of Q dy up the right side and down the left, and the ∂P/∂y term gives the bottom and top. Glue rectangles together and the shared edges cancel, just as in the demo; a limiting argument handles curved boundaries. The demo’s three readouts are computed independently, the double integral by slicing the region, so their agreement is a real check.

With P = −y/2 and Q = x/2 the curl is 1, which turns area into a line integral: A = ½∮(x dy − y dx). It is the shoelace formula for polygons, and the principle of the planimeter below.

The theorem carries the name of George Green, a self-taught miller’s son from Nottingham, whose 1828 essay on electricity and magnetism contained closely related integral identities. The plane statement in today’s form was given by Cauchy in 1846 and proved by Riemann in his doctoral thesis of 1851.

The Planimeter

Drag the tracer once round a shape, or press Auto-trace. The arms follow, and the green wheel can only roll sideways to its arm. When the loop closes, its reading times the arm length is the area. Try a freehand loop, and move the pole inside a shape to see what changes.

0.000
wheel turns (the dial)
0.000
b × roll: the planimeter’s area
0.000
shoelace area of the traced loop
5.309
true area of the outline
Drag the tracer round the dashed outline, back to where it started, or press Auto-trace.

The elbow is found by intersecting the circle of radius a about the pole with the circle of radius b about the tracer, keeping the branch nearest its last position. The wheel sits on the tracer arm a quarter of the way from the elbow; each small step it rolls by the component of its motion perpendicular to the arm (n · dW) and slides along the arm without turning. Drag the pole weight to move it, and put it inside a large shape to see the zero-circle correction. Areas are in square units of the grid.

Go deeper:Measuring Area by Walking Round It

The polar planimeter was invented in 1854 by the Swiss instrument maker Jakob Amsler, and for more than a century engineers, surveyors and naval architects used it to measure areas on maps, indicator diagrams and ship drawings by tracing their outlines.

Why it works: let the tracer arm have length b, direction u and normal n. As the arm moves it sweeps out area at the rate b (n · v), where v is the velocity of its midpoint. The wheel, on the arm at distance c from the elbow, rolls by n · dW = n · dE + c dθ, where θ is the angle of the arm. Adding up round a closed trace,

area(tracer) − area(elbow) = b · roll + b(b/2 − c) Δθ

With the pole outside the shape, the elbow just swings back and forth along its arc, enclosing no area, and the arm ends at its starting angle, Δθ = 0. So the area is exactly b times the roll, wherever the wheel sits on the arm. With the pole inside, both arms go once round and the constant π(a² + b² − 2bc), the area of the so-called zero circle, has to be added.

In the language of Green’s theorem: when the tracer is at T, let N(T) be the unit normal to the arm. The wheel computes ∮ N · dr, and one can check that curl N = 1/b throughout the reachable ring, so the reading is the area divided by b. The machine never looks inside the shape.

Key Takeaways

  • Curl F = ∂Q/∂x − ∂P/∂y is circulation per unit area: a tiny paddle wheel turns at curl/2. It need not match how curved the streamlines look.
  • Div F = ∂P/∂x + ∂Q/∂y is outward flux per unit area: the rate at which a small blob of fluid grows.
  • Green’s theorem: ∮_C P dx + Q dy = ∬_R (∂Q/∂x − ∂P/∂y) dA, because inner edges cancel in pairs; the flux form does the same for divergence.
  • Area is a boundary integral, A = ½∮(x dy − y dx): the planimeter and the shoelace formula both use it.

Spot a mistake or have an idea?

Search