Lab › Geometry of Seeing › Part 1 · the program

The Visual Cortex as a Contact Manifold

Your brain fills in contours that do not exist. Petitot's neurogeometry models oriented cortical states by a contact bundle; this article separates the free sub-Riemannian geodesics from their smooth Euler-elastica siblings.

By Igor Moiseev · 25 April 2026 · arXiv:0807.4731 · with Yu. L. Sachkov
Geometry of Seeing
  1. The Visual Cortex as a Contact Manifold ← you are here
  2. Euler's Elastica and Jacobi Elliptic Functions
  3. Maxwell Strata: When Optimal Paths Fork
  4. The Exact Cut Time on SE(2) — and the Open Problem Beyond It
Appendices — theory background (5)
  1. A1. Lie Groups, Lie Algebras, and the Exponential Map of SE(2)
  2. A2. Distributions, Frobenius, and Contact Geometry
  3. A3. Calculus of Variations and the Pontryagin Maximum Principle
  4. A4. Jacobi Elliptic Functions, Elliptic Integrals, and the AGM
  5. A5. The Sub-Riemannian Exponential Map of SE(2)
What this article covers
How a neurogeometric model represents orientation-selective cortical architecture by a non-Euclidean contact geometry. We proceed from the illusion that motivates the model to the sub-Riemannian structure on SE(2), then separate its free, generically cuspidal geodesics from the smooth pinned Euler elastica. The payoff: both share one pendulum reduction, while the elastica curvature is parametrised by Jacobi elliptic functions and has period $4K(k^2)$.

The Illusion That Started Everything

Look at the figure below. You see a bright white equilateral triangle floating above three black discs. The triangle has sharp edges and appears slightly brighter than the background. None of that is actually printed on the page.

Kanizsa (1955) — the white triangle does not exist

Three "Pac-Man" shapes arranged so their open mouths point inward. Your visual system perceives a bright equilateral triangle with sharp edges — a modal completion of contours that are absent in the image. This is not a trick or an error; it is a fundamental feature of how V1 processes local orientation information into global contour structure.

This is the Kanizsa triangle (Kanizsa 1955), the canonical example of modal completion — the visual system’s tendency to infer the presence of a bounding contour from a set of locally consistent cues. The phenomenon is not subtle: the perceived edges are sharp, the interior surface appears measurably lighter than the background (Cornsweet 1970), and the effect survives rotation, scaling, and partial occlusion.

The question is: what is the computational rule that produces this completion? A satisfying answer did not arrive until 2003.

Orientation Columns in V1

The primary visual cortex (V1, also called area 17 or the striate cortex) is the first cortical stage of visual processing. Hubel and Wiesel (1959, 1962) received the Nobel Prize for discovering that neurons in V1 respond selectively to oriented edges: a neuron fires most vigorously when a bar of light oriented at a particular angle passes through a small region of the visual field.

At the resolution of this idealised orientation-column model, a cortical state is characterised by: \(\text{position }(x, y) \in \mathbb{R}^2 \quad\text{and}\quad \text{preferred orientation }\theta \in [0, \pi).\)

Neurons with the same preferred orientation cluster in orientation columns running perpendicular to the cortical surface. Mapped over a patch of cortex, the preferred orientations rotate continuously — completing a full $\pi$-rotation over a distance of about 1 mm. The resulting pattern of orientation preferences is called an orientation map, and it exhibits a characteristic structure of pinwheels: point singularities of topological charge $\pm\tfrac12$ — encircle one and the preferred orientation sweeps through a full half-turn, $\pm\pi$.

The figure below shows a schematic orientation map: each short line segment represents one cortical location $(x,y)$, oriented at the local preferred angle $\theta(x,y)$. Colours encode the orientation angle on a $[0, \pi)$ hue wheel.

Hover a cell:
Schematic orientation map of a patch of V1. Each line segment represents an idealised orientation-selective cortical state at position $(x,y)$, oriented at its preferred angle $\theta$ (colour encodes $\theta$ via a hue wheel); the orientation field is smooth almost everywhere, with a pinwheel singularity near the centre of the patch. Tick the boxes to overlay pinned Euler-elastica candidates, integrated from $(\dot x, \dot y, \dot\theta) = (\cos\theta, \sin\theta, \kappa(s))$. These smooth curves solve the pinned-forward-speed problem; they are not the generically cuspidal planar projections of free SR geodesics. Each solves a tangent-matching boundary-value problem from the source state to the target state's $(x,y,[\theta])$, with the target-tangent residual driven to $0$ (mod $\pi$) by a damped Newton. All four start at the blue source state, tangent to its preferred orientation, and end exactly tangent to the target state's stroke. The endpoint of each curve is highlighted with the family's colour, and the label gives the modulus and plane arc length $L$ in pixels. Axes: the panel is the retinal plane, position $(x, y)$, drawn in a $680 \times 460$ px frame at 78 px per model length unit ($x$ to the right; no tick axes by design — the scale bar, bottom left, marks one unit); the preferred orientation $\theta$ is read in degrees, mod $180°$, in the hover readout. The first three families display the pendulum regimes of the pinned problem: inflectional ($-1\!<\!E\!<\!1$) — $\kappa(s) = 2k\,\mathrm{cn}(s\mid k^{2})$, generic S-shaped curve; non-inflectional ($E\!>\!1$) — $\kappa(s) = 2\,\mathrm{dn}(s\mid m)$, one-signed curvature, wavy-circle shape; borderline elastica ($E = 1$) — $\kappa(s) = 2\,\mathrm{sech}\,s$, the separatrix between the two regimes; elastica mirror pair — two closed figure-eight extremals that leave the source in opposite directions along the same line (curve B is the mirror image of curve A, traversed in reverse). Their equal-length return after $4K(k^2)$ illustrates the reflection mechanism, but it is not the free-SR cut event at $2K(k^2)$.

A key discovery from Bosking et al. (1997) is that the long-range horizontal connections in V1 — axons that reach across several millimetres of cortex — connect neurons with the same preferred orientation that lie roughly along the direction of that orientation. In other words, a neuron at $(x,y)$ preferring angle $\theta$ connects strongly to neurons at $(x’, y’)$ where the displacement $(x’-x, y’-y)$ is approximately parallel to $\theta$.

This is the empirical association field (Field, Hayes & Hess 1993): two oriented line elements are perceptually grouped together if they lie along a smooth curve that is tangent to both elements.

Petitot’s Insight: V1 Is a Contact Bundle

Jean Petitot (1999, 2003) made the key observation: the idealised data $(x,y,[\theta])$ encoding an orientation-selective cortical state — together with the horizontal connectivity pattern just described — is not a 2D image map. It is a 3-dimensional contact manifold.

Specifically, unoriented edge elements live in $\mathbb{R}^2\times\mathbb P^1$, because $\theta$ and $\theta+\pi$ label the same line. For calculation we lift to the oriented double cover $(x,y,\theta)\in\mathbb{R}^2\times S^1\cong\mathrm{SE}(2)$, where opposite headings remain distinct. It carries a contact structure $\xi = \ker(\sin\theta\,dx - \cos\theta\,dy)$: the constraint that a curve $(x(t), y(t), \theta(t))$ can only move horizontally (forward in direction $\theta$, or rotate in place) — it cannot slide sideways.

This constraint is satisfied by any curve whose position $(x,y)$ moves in the direction the neuron prefers: \(\dot x = u_1 \cos\theta, \quad \dot y = u_1 \sin\theta, \quad \dot\theta = u_2.\)

The bundle $(\mathbb{R}^2 \times S^1, \xi)$ is canonically isomorphic (as a contact manifold) to the unit cotangent bundle $ST^*\mathbb{R}^2$ and can be identified with SE(2), the Lie group of orientation-preserving rigid motions of the plane.

The Lie Group SE(2)

What SE(2) is, concretely

A point of $\mathrm{SE}(2)$ is a triple $(x, y, \theta)$: a position $(x, y) \in \mathbb{R}^2$ together with an orientation $\theta \in S^1$. This is the oriented double-cover data used for one idealised cortical state in Figure 2. As a $3\times3$ matrix the configuration $g$ acts on the plane as a rotation followed by a translation:

\[g \;=\; \begin{pmatrix} \cos\theta & -\sin\theta & x \\ \sin\theta & \cos\theta & y \\ 0 & 0 & 1 \end{pmatrix}.\]

The two motions that are directly available

The horizontal connectivity of V1 (Bosking et al. 1997) lets the cortex move its neural locus in only two ways:

In $(x, y, \theta)$ coordinates these are the two left-invariant vector fields

\[X_1 \;=\; \cos\theta\,\partial_x + \sin\theta\,\partial_y, \qquad X_2 \;=\; \partial_\theta.\]

The third direction — sliding the locus perpendicular to the current orientation — is forbidden:

\[X_3 \;:=\; -\sin\theta\,\partial_x + \cos\theta\,\partial_y \;\notin\; \mathrm{span}\{X_1, X_2\}.\]

V1 has no “move my edge sideways” connection at this level.

How sideways motion still happens — the Lie bracket

The cortex can nevertheless reach a perpendicularly-displaced neuron, by a short loop of the two moves it does have. The figure below shows the canonical four-step manoeuvre

\[+\varepsilon X_1 \;\to\; +\varepsilon X_2 \;\to\; -\varepsilon X_1 \;\to\; -\varepsilon X_2 .\]

Each leg is small (length $\varepsilon$). The net effect is to leave the orientation unchanged but to displace the position by an amount of order $\varepsilon^2$ in the perpendicular direction:

\[\Phi^{X_2}_{-\varepsilon} \!\circ\! \Phi^{X_1}_{-\varepsilon} \!\circ\! \Phi^{X_2}_{\varepsilon} \!\circ\! \Phi^{X_1}_{\varepsilon}\;(g_0) \;=\; g_0 \,-\, \varepsilon^2\, X_3 \,+\, O(\varepsilon^3).\]

The infinitesimal limit of this loop is exactly the Lie bracket of $X_1$ and $X_2$. With $X_3$ fixed as above, a direct computation gives

\[[X_1, X_2] \;=\; -X_3 \;=\; \sin\theta\,\partial_x - \cos\theta\,\partial_y.\]

The sign is a convention artefact — $[X_2, X_1] = X_3$ — and changes nothing that follows: what matters is that the bracket points along $X_3$, the direction the two horizontal moves cannot reach on their own.

θ(s) = +0.0° κ(s) = dθ/ds = +0.000 /unit cell field θ at (x,y) = +0.0° Δθ = θ(s) − cell = +0.0°
Figure 3. The moving Frenet–Serret frame along a pinned Euler-elastica candidate. Drag the slider to advance the arc-length parameter $s \in [0, L]$ along one of the BVP-solved trajectories (use the dropdown to switch). At every $s$ the figure shows the planar position $(x(s), y(s))$ on the orientation field and the moving frame $\{T(s), N(s)\}$ — both arrows always labelled: $T = (\cos\theta(s), \sin\theta(s)) = X_1\!\restriction_{\gamma(s)}$, the forward horizontal direction, and $N = (-\sin\theta(s), \cos\theta(s)) = X_3\!\restriction_{\gamma(s)}$, the perpendicular direction that is only reachable through the Lie bracket $[X_1, X_2]$. Axes and units: the same retinal plane as Figure 2, at 78 px per model length unit (scale bar, bottom left: one unit). The readouts give arc length $s$ and total length $L$ in those length units, the curvature $\kappa$ per unit length, and the angles $\theta$ in degrees.

Why the green field stroke is tangent at the endpoints but not in between. The green stroke at the moving point is $\theta_{\mathrm{field}}(x(s), y(s))$ — the orientation that the model orientation field assigns at the planar position $(x(s), y(s))$. The blue arrow $T$ is the orientation that the candidate curve happens to have at this $s$. These are two different things:
  • The orientation field $\theta_{\mathrm{field}}$ is a fixed scalar function on the $(x, y)$ retinal plane — it labels each cortical column with its preferred orientation.
  • The candidate's tangent $\theta(s)$ is the third coordinate of a curve in the 3-D contact bundle $\mathrm{SE}(2)$. In this figure it is reconstructed from a pinned elastica curvature profile $\kappa(s)=d\theta/ds$ — not by what the field happens to read at $(x(s), y(s))$.
The boundary value problem only forces equality at the two ends: $\theta(0) = \theta_{\mathrm{field}}(\text{source})$ and $\theta(L) = \theta_{\mathrm{field}}(\text{target})$, because that is what "connect these two neurons" means — start and finish on the cortical columns the field assigns. In between the two ends, the candidate is free to leave the field's prescription. Watching $\Delta\theta$ as you drag the slider, you see it go from $0°$ at $s = 0$ to a non-zero excursion in the middle and back to $0°$ at $s = L$ — that excursion is the cost of horizontality: the curve has to keep $\dot\theta = \kappa$, $\dot x = u\cos\theta$, $\dot y = u\sin\theta$ consistent with the horizontal reconstruction ODE, and the cortical orientation field plays no role in that constraint.

Maxwell-pair mode. When the dropdown is set to the elastica mirror pair, two frames advance in lock-step along the two members of the pair $\gamma_A, \gamma_B$ (frame labels become $T_A, N_A$ and $T_B, N_B$). Both close back to the source after the same arc length $L = 4K(k_c^2)/\omega$, but their final tangents differ by exactly $\pi$: $\theta_A(L) - \theta_B(L) = \pi \pmod{2\pi}$. The two pinned elastica are reversed-heading partners — they leave the source in opposite directions and traverse $\sigma$-mirrored figure-8 loops. Because the model's preferred orientation is a line, identified mod $\pi$, both endpoint headings $\theta_{\mathrm{src}}$ and $\theta_{\mathrm{src}}+\pi$ represent the same projective orientation state. The pair therefore gives two distinct pinned extremals with the same projected line-element endpoint and equal arc length. It visualises an elastica Maxwell symmetry (Sachkov, J. Dyn. Control Syst. 2008); it does not assert that these curves are free-SR minimisers or that their $4K$ tie is the SR cut time.

Hörmander condition ⇒ V1 is a contact manifold

Because $[X_1, X_2] = -X_3$ is not in $\mathrm{span}{X_1, X_2}$ but the three together ${X_1,\, X_2,\, [X_1, X_2]}$ span the full tangent space $T_g\,\mathrm{SE}(2) \cong \mathbb{R}^3$ at every $g$, the 2-plane field

\[\mathcal{H} \;:=\; \mathrm{span}\{X_1, X_2\}\]

satisfies the Hörmander (bracket-generating) condition. By the Chow–Rashevskii theorem (Rashevskii 1938, Chow 1939) any two configurations in $\mathrm{SE}(2)$ can therefore be joined by a horizontal path — a curve whose velocity lies in $\mathcal{H}$ at every point. Geometrically, $\mathcal{H}$ is a contact structure on $\mathrm{SE}(2)$. Petitot’s model proposes that orientation-selective V1 connectivity is usefully idealised as a discrete realisation of this contact geometry.

The Sub-Riemannian Metric and the Minimisation Problem

We equip the horizontal distribution $\mathcal{H}$ with the left-invariant inner product: \(\langle u_1 X_1 + u_2 X_2,\; u_1 X_1 + u_2 X_2 \rangle = u_1^2 + u_2^2.\)

This defines a sub-Riemannian (SR) metric on SE(2): the length of a horizontal curve is $\int_0^T \sqrt{u_1^2 + u_2^2}\,dt$, and the SR distance between two points is the infimum of lengths over all horizontal paths.

The visual completion problem now takes a precise form:

Problem (Petitot 2003)
Given two idealised oriented cortical states $(x_0,y_0,[\theta_0])$ and $(x_1,y_1,[\theta_1])$, find the horizontal curve $(x(t), y(t), \theta(t))$ in SE(2) of minimum length connecting chosen lifts—or minimise over both endpoint lifts when the projective line bundle is the intended state space.

The spatial projection $(x(t),y(t))$ is the contour predicted by this model for the chosen boundary data. This is a mathematical hypothesis about completion, not an assertion that V1 literally solves this homogeneous optimisation problem.

Two closely related problems share this setup, and the series will keep them carefully apart. Pinning $u_1=1$ makes $s$ plane arc length and $\kappa=u_2$ the signed curvature. At fixed length, the quadratic control energy $\tfrac12\int(1+\kappa^2)\,ds$ differs by a constant from the classical Euler elastica problem — critical curves of the bending energy \(\int_0^L \kappa^2(s)\,ds,\) whose smooth solutions Part 2 parametrises with elliptic functions. The free sub-Riemannian problem ($u_1$ unconstrained) shares the same pendulum core but its plane projections are different curves — generically with cusps where the forward speed changes sign (Part 2 and Appendix A3 make the relation precise). Both are alternative mathematical models of completion; deciding which better describes psychophysics or cortical dynamics is an empirical question.

$k\!<\!1$ inflectional  ·  $k\!=\!1$ borderline  ·  $k\!>\!1$ non-inflectional
Figure 4. Family of candidate completion curves — Euler's elastica, the smooth solutions of the pinned ($u_1 = 1$) problem that Part 2 derives from the shared pendulum (the free SR geodesics project to cuspidal cousins of these curves; Appendix A3). The single parameter $k$ traverses all three regimes: $k \in (0, 1)$ — inflectional, $\kappa(s) = 2k\,\mathrm{cn}(s\mid k^{2})$; $k = 1$ — the borderline (solitary) elastica, the separatrix $\kappa(s) = 2\,\mathrm{sech}\,s$; $k > 1$ — non-inflectional, $\kappa(s) = 2\,\mathrm{dn}(s\mid m)$ with its own modulus $m \in (0,1)$ (one-signed periodic curvature; plane closure requires a separate zero-displacement condition); the slider just sweeps $m$ downward as $k$ runs past 1. Drag the slider to set the maximum $k$ rendered; the vertical bar on the right is the colour scale, with the red tick marking the separatrix $k=1$. As $k\to1$ the period $4K(k^2)$ diverges and the family approaches the non-periodic borderline elastica on bounded intervals. Beyond the separatrix the non-inflectional curves resemble deformed circles, but are not generically closed (Part 2). Axes: the panel is the plane $(x, y)$ — $x$ to the right, $y$ up, every curve starting at the black dot — with dimensionless coordinates in units of the elastica length scale $\ell$ — the unit of arc length in which the inflectional curvature is $\kappa(s) = 2k\,\mathrm{cn}(s\mid k^2)$ and the pendulum equation is $\ddot\varphi + \sin\varphi = 0$. There are no tick axes by design; the scale bar (bottom left) gives the length scale and rescales with the slider.

From Petitot’s Model to the Open Problem

Petitot’s paper established the model. The subsequent mathematical programme — carried out primarily by Sachkov and collaborators — aimed to characterise the global structure of this SR geometry: which geodesics are actually optimal (globally length-minimising), and up to what arc length?

In every statement that follows, “length” means the sub-Riemannian length — the only length the visual cortex’s contact-bundle geometry actually defines. For a horizontal curve $\gamma : [0, T] \to \mathrm{SE}(2)$ with controls $(u_1, u_2)$ along the horizontal frame ${X_1, X_2}$,

\[L_{\mathrm{SR}}(\gamma) \;=\; \int_{0}^{T} \sqrt{u_1^{2} + u_2^{2}}\,dt.\]

Under the standard unit-speed parametrisation $u_1^{2} + u_2^{2} = 1$, this collapses to $L_{\mathrm{SR}}(\gamma) = T$ — the SR arc-length parameter. Crucially, Euclidean arc length on the projected plane curve $(x(s), y(s))$ is not what gets minimised; only horizontal motion (forward + rotation) costs anything, and “sliding sideways” is forbidden, not free.

This requires understanding two geometric loci, both defined with respect to $L_{\mathrm{SR}}$:

For a sub-Riemannian manifold as symmetric as SE(2), the cut and Maxwell loci are tightly linked: characterising the Maxwell strata is the main result of arXiv:0807.4731 (joint work with Yu. L. Sachkov), and pinning the cut locus down exactly is the subject of arXiv:0903.0727. The first point on the cut locus along a given geodesic is the cut time $t_\mathrm{cut}$.

The remarkable — and, for SE(2) itself, now settled — result is:

Theorem (Moiseev–Sachkov 2010; Sachkov 2010, 2011)
For the SR problem on SE(2) the cut time equals the first Maxwell time of the discrete symmetry group of the exponential map: $t_\mathrm{cut} = \mathfrak{t}(\lambda)$. For the generic oscillating-pendulum family ($C_1$) with modulus $k$ this is $$t_{\mathrm{cut}} \;=\; 2K(k^2),$$ half the pendulum period, with $K$ the complete elliptic integral of the first kind — and along this whole family there are no conjugate points at all: local optimality never fails, only the global tie does. What remains open is the general theory this exact solution exemplifies: a structural theorem making "cut = first Maxwell" checkable for left-invariant SR problems at large, rather than proved group by group (Part 4).

The four parts of this series develop the full story:

  1. This article: the model, the geometry, the problem statement.
  2. Part 2 (Euler’s Elastica): deriving the pendulum equation and solving it with Jacobi elliptic functions $\mathrm{sn}(s\mid k^2)$, $\mathrm{cn}(s\mid k^2)$, $\mathrm{dn}(s\mid k^2)$.
  3. Part 3 (Maxwell Strata): characterising the locus where two geodesics of equal length meet; the reflection group $(\mathbb{Z}_2)^3$ of the pendulum; the mirror-pair tie computed exactly on the elastica family, and the SR cut value $2K(k^2)$.
  4. Part 4 (The Exact Cut Time on SE(2) — and the Open Problem Beyond It): Sachkov’s cut-time theorem — what is proved for SE(2) — and the general Maxwell-equals-cut question that remains open beyond it.

References

  1. J. Petitot (2003). "The neurogeometry of pinwheels as a sub-Riemannian contact structure." Journal of Physiology–Paris 97(2–3): 265–309.
  2. I. Moiseev & Yu. L. Sachkov (2010). "Maxwell strata in sub-Riemannian problem on the group of motions of a plane." ESAIM: COCV 16(2): 380–399. arXiv:0807.4731
  3. G. Citti & A. Sarti (2006). "A cortical based model of perceptual completion in the roto-translation space." J. Math. Imaging Vision 24(3): 307–326.
  4. D. H. Hubel & T. N. Wiesel (1962). "Receptive fields, binocular interaction and functional architecture in the cat's visual cortex." J. Physiology 160: 106–154.
  5. D. J. Field, A. Hayes & R. F. Hess (1993). "Contour integration by the human visual system: Evidence for a local 'association field'." Vision Research 33(2): 173–193.
  6. W. H. Bosking et al. (1997). "Orientation selectivity and the arrangement of horizontal connections in tree shrew striate cortex." J. Neuroscience 17(6): 2112–2127.
  7. G. Kanizsa (1955). "Margini quasi-percettivi in campi con stimolazione omogenea." Rivista di Psicologia 49: 7–30.
  8. Yu. L. Sachkov (2011). "Cut locus and optimal synthesis in the sub-Riemannian problem on the group of motions of a plane." ESAIM: COCV 17(2): 293–321. arXiv:0903.0727