A conformal map preserves angles: near every point it behaves like a rotation followed by a uniform scaling. Explore them in a playground that warps grids and images — written with complex numbers, 2D vectors, and dual numbers.
Take a sheet of rubber, draw a fine square grid on it, and stretch it. Most deformations destroy the grid: squares become parallelograms, circles become ellipses, right angles open up or close. A conformal map is the special kind of deformation that never does that — at every point, and in every direction, it stretches by the same amount and rotates by the same angle. Locally it is a rotation and a zoom, nothing else.
That single constraint is surprisingly powerful. Conformal maps are the reason a Mercator projection keeps small shapes recognizable, the reason a Joukowski transform turns circles into airfoils, and the reason two-dimensional electrostatics and ideal fluid flow can be solved by drawing pictures. They are also the natural home of complex analysis: away from critical points, every holomorphic function is conformal.
The Playground
Below is a map from the plane to itself. The left panel is the domain (the -plane); the right panel is the image (the -plane, with ). Type any formula, drag to pan, scroll to zoom, and hover the domain to inspect the local behaviour at a point.
Conformal Map Playground
z is complex · also x, y, i, pi · exp log sqrt sin cos tan conj abs arg re im
A few things to try:
- Type
z^2, then hover near the origin and near . The distortion readout stays at everywhere except at the origin, where the derivative vanishes and the map stops being conformal. - Pick one of the test images — or drop your own image onto the panel. The image is warped through the same formula, so you can see exactly what the map does to recognizable shapes.
- Try
1/z,exp(z),log(z),sqrt(z), and(z - 1)/(z + 1)and watch where the grid tears, folds, or wraps around. - Hover the domain: the white circle is a tiny circle around , and its image is drawn on the right. The indigo and emerald arrows are the images of the and directions.
The expression language is small but expressive:
| Name | Meaning |
|---|---|
z | the complex point, |
x, y | real and imaginary parts of z |
r, theta | polar coordinates of z |
i, pi, tau, e | constants |
exp, log, sqrt, sin, cos, tan | the usual complex functions |
conj, abs, arg, re, im | conjugation and projections |
vec(u, v) | build a 2-vector from two real expressions |
pow, dot, cross, polar, cis | extras |
Powers can be written z^2, z**2, or even z²; √z is accepted as shorthand for sqrt(z).
A Derivative Is a Rotation and a Scale
Let be complex differentiable at . For a small complex step ,
The constant term moves the point; the whole local story is in the linear term . Write the derivative in polar form,
Multiplying a vector by rotates it by and scales it by . Every direction is rotated by the same and scaled by the same , so the angle between any two curves through is preserved — provided . At a critical point, where , the map collapses directions together and angles are multiplied by the order of the zero.
This is exactly what the playground reports when you hover:
- local scale , the geometric-mean stretch;
- rotation ;
- distortion , the ratio of the singular values of the Jacobian.
For a conformal map the distortion is : the Jacobian is a scalar multiple of a rotation matrix. That is the operational definition the rest of this post leans on.
A holomorphic function is conformal at every point where its derivative is nonzero. Conversely, a smooth map of the plane that is conformal and orientation-preserving is holomorphic. The two notions coincide in two dimensions.
The Cauchy–Riemann View
Write with real functions of . The Jacobian is
This matrix is a rotation composed with a uniform scale exactly when it has the form
which is equivalent to the Cauchy–Riemann equations
When they hold, , the determinant is , and both singular values equal .
The playground never solves these equations symbolically. It computes the two columns of exactly, using dual numbers, and then measures how far is from being a scaled rotation.
When Angles Are Not Preserved
A complex formula is only one way to write a map of the plane. A general map — a 2D vector field — need not satisfy Cauchy–Riemann, and then angles change. Switch the playground above to ℝ² vector mode and try vec(x, 2*y): horizontal lengths are untouched while vertical lengths double. The distortion readout becomes , and the hover circle turns into an ellipse.
A non-conformal stretch: F(x,y) = (x, 2y)
build a 2-vector with vec(u, v) · x, y, r, theta · dot, cross · same functions as ℂ
The singular-value decomposition of says the same thing geometrically: every linear map is a rotation, then a stretch along two perpendicular axes, then another rotation. The stretch is uniform — both axes stretched by the same factor — precisely when the map is conformal. The ratio measures how far it is from that ideal. A shear like vec(x + 0.5*y, y) has distortion , even though it preserves area.
Writing a conformal map as a vector field gives the same thing as writing it as a complex function. Compare
They are the same map: the vector is just the complex number in disguise. The vector notation emphasizes that the map is a deformation of the plane; the complex notation makes the rotation-and-scale structure obvious.
The vector and complex modes share the same evaluator. The only difference is what you write: vec(u, v) spells out the two real components, while z^2 uses complex algebra. The geometry is identical, and the conformality check is the same Jacobian calculation.
Dual Numbers: Derivatives Without Doing Calculus
To draw the derivative arrows and the distortion readout, the playground needs at arbitrary points, for arbitrary user formulas. Finite differences would work, but they lose precision and break down near singularities. Instead the evaluator uses dual numbers.
A dual number has the form , where
That single rule is enough to make Taylor's theorem exact to first order. For any analytic function,
Feed in , read off the coefficient of , and you have the derivative — no symbolic differentiation, no step size, no cancellation. This is forward-mode automatic differentiation, applied to complex numbers; the automatic differentiation article builds the same machinery for ordinary reals in C++.
The playground's values carry a complex dual part,
so a single expression can be evaluated with a complex seed. Multiplication follows the product rule:
function mul(a: Num, b: Num): Num {
return {
re: a.re * b.re - a.im * b.im,
im: a.re * b.im + a.im * b.re,
de: a.de * b.re - a.di * b.im + a.re * b.de - a.im * b.di,
di: a.de * b.im + a.di * b.re + a.re * b.di + a.im * b.de,
}
}The de and di fields are the real and imaginary parts of the -channel. Seeding with gives ; seeding it with gives . Two evaluations, both exact, and the Jacobian falls out:
const w = f(x, y, 0, 0) // f(z)
const dx = f(x, y, 1, 0) // ∂w/∂x stored in the ε-channel
const dy = f(x, y, 0, 1) // ∂w/∂y stored in the ε-channelBecause the seed can be any complex direction, the same machinery handles non-holomorphic formulas too: what comes out is the directional derivative . For a holomorphic , that equals for every — the rotation-and-scale property again.
Try It Explicitly
In ε dual mode, eps is the nilpotent unit itself. Writing f(z + eps) makes the derivative appear as the -coefficient. Try (z + eps)^3: the main part is , and the -part is .
Dual numbers: f(z + ε) = f(z) + ε·f′(z)
eps is the nilpotent unit, eps² = 0 · write f(z + eps) to read off the derivative
Now switch the step between , , and with the small buttons. For a holomorphic map the -part rotates with the step, but its length is unchanged: the derivative acts by a fixed rotation and scale. Then try (z + eps) + 0.5*conj(z + eps). The -part now changes length when you change the step direction — the map has a preferred direction, and angles are not preserved.
The -coefficient is a complex number, so it has a length and a direction. Those are exactly the local scale factor and the local rotation of the map. If you can compute the coefficient, you can draw the geometry.
The Usual Suspects
Some maps are worth knowing by name. Each is a useful experiment in the playground.
| Map | Behaviour | Conformal where |
|---|---|---|
| doubles angles; wraps the plane twice; right half-plane maps onto the plane slit along the negative real axis | everywhere except | |
| multiplies angles by ; -to-one | everywhere except | |
| inversion; sends circles and lines to circles and lines | everywhere except | |
| periodic with period ; vertical strips become annular sectors | everywhere | |
| inverse of ; unwraps the plane into a strip | away from the branch cut | |
| half-angle map; two branches | away from the branch cut | |
| Möbius transformation; generalized circles map to generalized circles | everywhere except the pole | |
| , | trigonometric distortions, periodic | where |
| Joukowski map; the unit circle folds onto the segment | everywhere except |
The Möbius maps are the celebrities. They are the only bijections of the Riemann sphere that are conformal everywhere, and they act on the set of circles and straight lines as a single family — a line is just a circle through infinity. The playground's (z - 1)/(z + 1) sends the imaginary axis to the unit circle and is a good way to see this.
The Joukowski map is the aerodynamics workhorse. Applied to a circle that passes near but encloses it, it produces something remarkably close to an airfoil cross-section. The map is conformal except at , where the derivative vanishes and a sharp trailing edge appears. That is not a coincidence: the sharp edge of the airfoil is a critical point of the map.
Holes, Folds, and Branch Cuts
Conformality is a local property. A map can be conformal at every point and still be globally wild:
- folds the plane onto itself; two points map to the same image. It is conformal at both of them (unless one is the origin).
- is conformal everywhere but repeats itself every .
- and cannot be continuous on a loop around the origin; a branch cut has to be chosen, and the map jumps across it.
- is conformal except at its pole, where the image runs off to infinity.
The playground draws all of these honestly. Near a pole the mapped grid escapes to very large coordinates; across a branch cut two nearby points land far apart. Those are features of the map, not rendering bugs. Folding also matters for image warping: when is not injective, different parts of the image land on top of each other.
For simply connected domains there is a spectacular global theorem. The Riemann mapping theorem states that any simply connected open proper subset of is conformally equivalent to the unit disk. Any such region can be flattened into a disk by a holomorphic bijection. The theorem says nothing about how to find the map, which is why numerical conformal mapping — Schwarz–Christoffel methods, zipper algorithms, circle packing — is a research area of its own.
Images Are Test Cards
A photograph is a great way to see a conformal map. Because the map is locally a rotation and a scale, small features stay legible: tiny text is rotated and resized, but not sheared. Distortion is uniform in every direction, so shapes look "bent" rather than "smeared."
The playground warps images with a triangle mesh: the source square is divided into a grid of cells, every corner is pushed through , and each cell is painted with a clipped affine transform. Increase the mesh density with the slider for a smoother warp; lower it to see the triangles.
Some experiments to run with the sample cards and your own uploads:
z^2on the face: the image is folded over itself along the real axis, and the face appears twice.1/zon the spiral: the spiral inverts into another spiral, and the centre blows up.exp(z)on the test card: the vertical grid lines become circles.(z - 1)/(z + 1)on the rings: circles that do not pass through the pole stay circles.- A shear in vector mode: the face leans, and every feature is smeared in one direction.
Outside the Möbius transformations there is no reason for a finite circle to stay a circle. Some lucky circles do — maps the unit circle to itself — but a general conformal map only turns infinitesimal circles into circles. The white hover circle in the playground is small but not infinitesimal, so it can look slightly oval under strong maps like : that is the higher-order term, not a violation of conformality.
Where Conformality Earns Its Keep
- Cartography. The Mercator projection is conformal: angles and small shapes are preserved, which is why it was indispensable for navigation. The price is enormous area distortion near the poles — Greenland looks like Africa.
- Fluid dynamics. In 2D ideal flow, the complex potential has streamlines and equipotential lines that meet at right angles. A conformal map preserves those angles, so a flow around a complicated obstacle can be computed by mapping it back to a simple one, such as a circle.
- Electrostatics. The same complex-potential machinery turns boundary-value problems on awkward domains into problems on rectangles or disks.
- Aerodynamics. The Joukowski map — and its generalizations — transforms a circle into an airfoil and gives closed-form lift predictions.
- Mesh generation and graphics. Angle-preserving parameterizations keep texture and simulation meshes well-shaped. Conformal surface parameterization is a standard tool in geometry processing.
- Statistical physics and field theory. Conformal invariance at critical points underlies conformal field theory and the study of percolation and other lattice models.
- Medical imaging. Flattening the retina or the cortical surface uses conformal or near-conformal maps, so that local shapes and areas are distorted as little as possible.
In three and higher dimensions the story changes abruptly. Liouville's theorem says that for , every conformal map of a domain in is a composition of translations, rotations, dilations, and inversions — the Möbius transformations. There is no room for the rich zoo of holomorphic functions. This is one reason two-dimensional conformal geometry is so special.
Conclusion
A conformal map is a deformation with no shear: at every point it is a rotation plus a uniform scale. In complex notation that is exactly what multiplication by does, and the Cauchy–Riemann equations are the coordinate-free statement of the same fact. The playground makes the definition operational — type a formula, watch the grid bend, hover to see the local rotation and scale, and read the distortion to see where conformality fails.
Dual numbers close the loop. They compute exactly from the same expression that draws the picture, which is why the local geometry can be displayed for arbitrary user formulas. If you want to go deeper into that machinery, the automatic differentiation article covers forward and reverse mode from scratch.
Further Reading
- Tristan Needham, Visual Complex Analysis — the best geometric introduction to the subject
- Lars Ahlfors, Complex Analysis — the classical treatment of conformal mapping
- Wikipedia: Conformal map, Cauchy–Riemann equations, Joukowsky transform, Riemann mapping theorem
- Wikipedia: Dual number and automatic differentiation
Related Articles
Automatic Differentiation
A deep-dive into automatic differentiation: symbolic vs. numerical vs. AD, AST transformation, dual numbers, tapes, hybrid methods, and a generic C++ implementation that computes gradients and solves optimisation problems.
The Fourier Transform: From Sines to Signals
A visual and mathematical journey through one of the most beautiful ideas in all of mathematics — decomposing any signal into its frequency components.
The Bertrand Paradox: When Randomness Needs a Definition
A deceptively simple question — what is the probability that a random chord of a circle is longer than the side of its inscribed equilateral triangle? — has three different correct answers depending on what 'random' means.
The Abelian Sandpile: A Group Hiding in a Pile of Sand
The Bak–Tang–Wiesenfeld sandpile model (ASM) is a deceptively simple cellular automaton that conceals a rich algebraic structure — an abelian group whose identity element is a non-trivial fractal-like configuration.