Independent scholarship · Open accessThe monthly digest

Full manuscript · browser edition

Diffeology in Higher Categories

Continuous, single-column reading. Equations, tables, proofs, references and appendices stay in document order.

Contents · 104 sections

Higher Categorical Semantics  Monograph

Diffeology in
Higher Categories

Concrete sheaves, cohesive shape, and stacks
behind Iglesias-Zemmour’s Diffeology

with applications to arithmetic, cryptography,
machine learning, artificial intelligence, and system design

image

One leaf of the Kronecker foliation of slope α=(5−1)/2\alpha=(\sqrt5-1)/2 on T2T^2.
Its leaf space Tα=R/(Z+αZ)T_\alpha=\mathbb{R}/(\mathbb{Z}+\alpha\mathbb{Z}) is a point for topology, a group for diffeology, and BZ2\mathbf{B}\mathbb{Z}^2 for homotopy.

Anonymous submission

Prepared for higher-categorical-semantics.pages.dev  27 November 2026

Abstract

In Diffeology [1], Patrick Iglesias-Zemmour develops differential geometry on sets equipped with a family of “plots”, and proves that this datum suffices for homotopy theory, Cartan calculus, fibre bundles and symplectic geometry far outside the category of manifolds. The arguments there are carried out directly with sets and maps. Here the categorical language is added, and the theory is then raised one categorical level.

Part I. The three axioms of a diffeology are the sheaf condition on a concrete site, and the structural theorems of the book (limits, colimits, function spaces, inductions and subductions) follow from the fact that Diff\mathsf{Diff} is the quasitopos of concrete sheaves on Cartesian spaces (Baez–Hoffnung, Dubuc). Part II. Diff\mathsf{Diff} embeds in the cohesive ∞\infty-topos H=Sh∞(Cart)\mathbf{H}=\mathsf{Sh}_\infty(\mathsf{Cart}) of smooth ∞\infty-groupoids. There the book’s smooth homotopy groups are the homotopy groups of the shape ∫X\mathord{\textstyle\smallint}X; its differential forms are maps into the non-concrete classifying sheaves Ωk\Omega^k; its fibre bundles are maps into classifying stacks BG\mathbf{B}G that are not diffeological spaces; and the failure of de Rham’s theorem on the irrational torus becomes a spectral sequence whose first obstruction group is the group of principal R\mathbb{R}-bundles. The organising statement is a trichotomy of quotients, X/ ⁣ ⁣/G  ⟶  π0(X/ ⁣ ⁣/G)  ⟶  conc⁡ π0(X/ ⁣ ⁣/G)=X/G,X/\!\!/G\;\longrightarrow\;\pi_0(X/\!\!/G)\;\longrightarrow\;\operatorname{conc}\,\pi_0(X/\!\!/G)=X/G , stack, smooth set, diffeological space, with exact criteria for when each arrow is an equivalence.

Part III consists of applications. In number theory, the irrational torus TαT_\alpha realises GL⁡2(Z)\operatorname{GL}_2(\mathbb{Z})-equivalence, real quadratic units and Diophantine type as diffeological invariants. In cryptography, tori with real multiplication form a torsor under the class group of a real quadratic order, and deciding diffeomorphism is the principal ideal problem. In machine learning we prove correctness of forward-mode automatic differentiation by gluing over Diff\mathsf{Diff}, and that orbit spaces have no differentiable canonicalisation at points with isotropy. In artificial intelligence, a global smooth motion planner exists exactly on smoothly contractible spaces, and an agent restricted to smooth scalar observations can determine a space only up to its reflexive hull. In system design we give a minimal-realisation theorem with two inequivalent quotients, and classify multi-clock systems by their frequency module. Each of these chapters contains at least three theorems with proofs; every chapter ends with solved exercises graded from warm-up to proof.

Keywords. Diffeological space; concrete sheaf; quasitopos; cohesive ∞\infty-topos; shape; smooth stack; irrational torus; de Rham obstruction; real multiplication; automatic differentiation; motion planning.
MSC 2020. 58A40, 18F10, 18N60, 18B25, 55P60, 57R18, 11R11, 11J70, 68T07, 94A60.

Preface

What this is

A companion to the source text, a 450-page treatise whose method is to stay as close to the sets and the maps as possible. That method is a strength: the reader of [1] never needs a universe, a model structure or a coherence theorem. Three of the book’s central objects, however, are not objects of the category of diffeological spaces:

  1. the object that classifies differential kk-forms, Ωk\Omega^k, is a sheaf with exactly one point;

  2. the object that classifies principal GG-bundles, BG\mathbf{B}G, is a stack;

  3. the homotopy type ∫X\mathord{\textstyle\smallint}X is an ∞\infty-groupoid.

In [1] each of these is treated by an explicit construction on plots. We put all three in one ambient ∞\infty-topos, where the constructions become representability statements.

Attribution

A Theorem, Proposition or Lemma with a name or a reference in its heading is taken from the literature, and is given with that reference and, when it is short, a proof. Every other numbered statement is proved in the text. Formalisation in a proof assistant is the subject of a sequel; in Coda the statements are sorted by the infrastructure required.

How to read

Parts I and II are cumulative. The application chapters depend on them as follows.

image

application chapter draws on
9  Number theory Chapters 1, 5, 6, 7
10  Cryptography Chapter 9; Chapter 8 for orbifolds
11  Machine learning Chapters 1–3 and 8
12  Artificial intelligence Chapters 1–3, 5 and 8
13  System design Chapters 3, 7 and 9

Conventions

A domain is an open subset of some Rn\mathbb{R}^n, n≥0n\ge 0; a Cartesian space is a domain diffeomorphic to Rn\mathbb{R}^n. Dom\mathsf{Dom} and Cart\mathsf{Cart} are the corresponding categories with smooth maps. We cite the source as [IZ, art. x.yx.y] for its numbered articles and [IZ, Exercise nn] for its exercises. “Smooth” means C∞C^{\infty}. All ∞\infty-categorical statements are about (∞,1)(\infty,1)-categories in the sense of [42]; limits and colimits in H\mathbf{H} are homotopy limits and colimits. R\mathbb{R} denotes the smooth additive group and Rδ\mathbb{R}^{\delta} the same group with the discrete diffeology. For a group GG acting on XX we write X/GX/G for the diffeological quotient and X/ ⁣ ⁣/GX/\!\!/G for the homotopy quotient in H\mathbf{H}; much of what follows is about the difference.

Diffeology as a category of sheaves

Plots

A diffeology is a choice of which parametrisations of a set are smooth. We recall the axioms, the two transport operations (pullback and pushforward), and the two distinguished classes of maps (inductions and subductions), organised around one fact: the underlying-set functor Diff→Set\mathsf{Diff}\to\mathsf{Set} is topological. Three examples introduced here — the irrational torus, the orbit space R/{±1}\mathbb{R}/\{\pm1\} and the cross — are the test cases for every later construction.

Source in the book. [IZ, Chapter 1] and the D-topology of [IZ, Chapter 2].

The axioms

A parametrisation of a set XX is a map P ⁣:U→XP\colon U\to X whose source is a domain. We write Param(X)\mathrm{Param}(X) for the set of all of them.

Definition 1.1 ([IZ, art. 1.5]). A diffeology on a set XX is a subset D⊆Param(X)\mathcal D\subseteq\mathrm{Param}(X), whose elements are called plots, such that

  1. covering: every constant parametrisation is a plot;

  2. locality: if P ⁣:U→XP\colon U\to X restricts to a plot on each member of an open cover of UU, then PP is a plot;

  3. smooth compatibility: if P ⁣:U→XP\colon U\to X is a plot and F ⁣:V→UF\colon V\to U is a smooth map between domains, then P∘FP\circ F is a plot.

A diffeological space is a set with a diffeology. A map f ⁣:X→X′f\colon X\to X' is smooth if f∘Pf\circ P is a plot of X′X' for every plot PP of XX. Diffeological spaces and smooth maps form the category Diff\mathsf{Diff}; its isomorphisms are called diffeomorphisms.

A diffeology is a family of maps into a set from domains of every dimension. By axiom [D3] the family is closed under smooth reparametrisation; by axiom [D2] membership in the family is a local property of the source. No structure on XX itself is required.

Two observations set the tone for everything that follows.

Remark 1.2 (Plots are the smooth maps from domains). Give a domain UU the diffeology of all smooth parametrisations. Then by [D3] a parametrisation P ⁣:U→XP\colon U\to X is a plot if and only if it is a smooth map U→XU\to X. So D(U)=Diff(U,X)\mathcal D(U)=\mathsf{Diff}(U,X): a diffeological space is the functor it represents on Dom\mathsf{Dom}. This is made precise in Concrete sheaves.

Remark 1.3 (No condition on XX). A manifold is a set that is locally modelled on Rn\mathbb{R}^n. A diffeological space is a set that domains can be mapped into. The first is a condition on the object; the second is the choice of a structure. This is why every construction below exists without hypotheses.

Example 1.4.

  1. A domain, or more generally a smooth manifold MM, carries the standard diffeology of smooth parametrisations. A map between manifolds is smooth in the sense of 1.1 exactly when it is smooth in the usual sense, so Mfd↪Diff\mathsf{Mfd}\hookrightarrow\mathsf{Diff} is full and faithful.

  2. The discrete diffeology on a set consists of the locally constant parametrisations; the coarse diffeology consists of all parametrisations.

  3. The wire diffeology on Rn\mathbb{R}^n consists of the parametrisations that are, near each point, either constant or of the form γ∘h\gamma\circ h with h ⁣:V→Rh\colon V\to\mathbb{R} and γ ⁣:R→Rn\gamma\colon\mathbb{R}\to\mathbb{R}^n smooth [IZ, art. 1.10]. For n≥2n\ge2 it is strictly finer than the standard one ([exo:wire]).

The underlying-set functor is topological

The diffeologies on a fixed set XX are ordered by inclusion: D\mathcal D is finer than D′\mathcal D' if D⊆D′\mathcal D\subseteq\mathcal D'. Arbitrary intersections of diffeologies are diffeologies, so they form a complete lattice with the discrete diffeology at the bottom and the coarse one at the top. A subset F⊆Param(X)\mathcal F\subseteq\mathrm{Param}(X) generates the smallest diffeology ⟨F⟩\langle\mathcal F\rangle containing it; explicitly, P∈⟨F⟩P\in\langle\mathcal F\rangle if and only if near each point PP is constant or of the form Q∘FQ\circ F with Q∈FQ\in\mathcal F and FF smooth [IZ, art. 1.66–1.68].

Definition 1.5. Let f ⁣:X→X′f\colon X\to X' be a map of sets.

  1. If X′X' is diffeological, the pullback f∗(D′)f^*(\mathcal D') is the set of parametrisations PP of XX with f∘P∈D′f\circ P\in\mathcal D'. It is the coarsest diffeology on XX making ff smooth.

  2. If XX is diffeological, the pushforward f∗(D)f_*(\mathcal D) is the diffeology on X′X' generated by { f∘P:P∈D }\{\,f\circ P : P\in\mathcal D\,\}. It is the finest diffeology on X′X' making ff smooth.

A smooth map f ⁣:X→X′f\colon X\to X' is an induction if it is injective and D=f∗(D′)\mathcal D=f^*(\mathcal D'); it is a subduction if it is surjective and D′=f∗(D)\mathcal D'=f_*(\mathcal D).

Unwinding, ff is a subduction exactly when it is surjective and plots of X′X' lift locally: for every plot P ⁣:U→X′P\colon U\to X' and every r∈Ur\in U there are an open V∋rV\ni r and a plot Q ⁣:V→XQ\colon V\to X with f∘Q=P∣Vf\circ Q=P|_V [IZ, art. 1.48]. Dually, ff is an induction exactly when it is injective and a parametrisation of XX is a plot as soon as its composite with ff is one [IZ, art. 1.31].

The two distinguished classes of smooth maps. In The quasitopos \mathsf{Diff} they become the strong epimorphisms and the strong monomorphisms of Diff\mathsf{Diff}.

The whole of [IZ, Chapter 1] can be compressed into one categorical statement.

Theorem 1.6 (The underlying-set functor is topological). Let ∣⋅∣ ⁣:Diff→Set|\cdot|\colon\mathsf{Diff}\to\mathsf{Set} be the underlying-set functor.

  1. (Initial lifts.) For every family of maps fi ⁣:X→∣Xi∣f_i\colon X\to |X_i| into diffeological spaces there is a unique diffeology on XX such that a map g ⁣:Z→Xg\colon Z\to X from a diffeological space is smooth if and only if every fi∘gf_i\circ g is smooth. It is ⋂ifi∗(Di)\bigcap_i f_i^*(\mathcal D_i).

  2. (Final lifts.) For every family of maps gi ⁣:∣Xi∣→Xg_i\colon |X_i|\to X there is a unique diffeology on XX such that a map h ⁣:X→Zh\colon X\to Z is smooth if and only if every h∘gih\circ g_i is smooth. It is generated by ⋃i{ gi∘P:P∈Di }\bigcup_i\{\,g_i\circ P : P\in\mathcal D_i\,\}.

Consequently Diff\mathsf{Diff} is complete and cocomplete, ∣⋅∣|\cdot| preserves limits and colimits, and ∣⋅∣|\cdot| has a left adjoint (discrete diffeology) and a right adjoint (coarse diffeology).

Proof. (i) An intersection of diffeologies is a diffeology, and P∈⋂ifi∗(Di)P\in\bigcap_i f_i^*(\mathcal D_i) means that each fi∘Pf_i\circ P is a plot. If g ⁣:Z→Xg\colon Z\to X and all fi∘gf_i\circ g are smooth, then for a plot QQ of ZZ each fi∘g∘Qf_i\circ g\circ Q is a plot, so g∘Qg\circ Q is a plot of XX; the converse is composition. Uniqueness: two diffeologies with the property make the identity smooth in both directions. (ii) Let D\mathcal D be the generated diffeology. If every h∘gih\circ g_i is smooth and P∈DP\in\mathcal D, then locally PP is constant or P=gi∘Q∘FP=g_i\circ Q\circ F, so h∘Ph\circ P is locally a plot of ZZ, hence a plot by [D2]. The rest is as in (i). For the consequences: a limit of a diagram (Xj)(X_j) is the limit of the underlying sets with the initial diffeology for the projections; a colimit is the colimit of sets with the final diffeology for the coprojections. The adjoints are the initial and final lifts of the empty family. ◻

Specialising 1.6 gives the constructions of the book with their universal properties attached:

construction diffeology reference
subspace A⊆XA\subseteq X initial for A↪XA\hookrightarrow X (plots of XX with values in AA) [IZ, art. 1.33]
product ∏iXi\prod_i X_i initial for the projections (componentwise plots) [IZ, art. 1.55]
quotient X/∼X/{\sim} final for X→X/∼X\to X/{\sim} (plots lift locally) [IZ, art. 1.50]
sum ∐iXi\coprod_i X_i final for the injections (plots locally in one summand) [IZ, art. 1.39]

Proposition 1.7 (Stability).

  1. Subductions are closed under composition, under products, and under pullback along arbitrary smooth maps.

  2. Inductions are closed under composition, under products, and under pullback along arbitrary smooth maps.

  3. A map that is both an induction and a subduction is a diffeomorphism.

The proof is [exo:stability]. Part (i) is false in Top\mathsf{Top} for quotient maps, and is the first respect in which Diff\mathsf{Diff} has better exactness properties than Top\mathsf{Top}.

Function spaces

Definition 1.8 ([IZ, art. 1.57]). For diffeological spaces X,YX,Y, the functional diffeology on C∞(X,Y)C^{\infty}(X,Y) consists of the parametrisations P ⁣:U→C∞(X,Y)P\colon U\to C^{\infty}(X,Y) whose adjoint (r,x)↦P(r)(x)(r,x)\mapsto P(r)(x) is a smooth map U×X→YU\times X\to Y.

Theorem 1.9 (Cartesian closure, [IZ, art. 1.60]). For diffeological spaces X,Y,ZX,Y,Z, currying is a diffeomorphism C∞(X×Y,Z)  ≅  C∞(X,C∞(Y,Z)),f⟼(x↦f(x,−)).C^{\infty}(X\times Y,Z)\;\cong\;C^{\infty}\bigl(X,C^{\infty}(Y,Z)\bigr),\qquad f\longmapsto\bigl(x\mapsto f(x,-)\bigr). In particular evaluation ev ⁣:C∞(Y,Z)×Y→Z\mathrm{ev}\colon C^{\infty}(Y,Z)\times Y\to Z and composition C∞(X,Y)×C∞(Y,Z)→C∞(X,Z)C^{\infty}(X,Y)\times C^{\infty}(Y,Z)\to C^{\infty}(X,Z) are smooth.

The proof is [exo:ccc]. Two consequences: paths in a function space are the same thing as homotopies, and a smooth family of smooth maps is the same thing as a smooth map out of a product. Both are false for manifolds, where the function space does not exist, and both will be used without comment from Shape on.

Three running examples

The irrational torus

Fix α∈R∖Q\alpha\in\mathbb{R}\smallsetminus\mathbb{Q}, let Λα=Z+αZ⊂R\Lambda_\alpha=\mathbb{Z}+\alpha\mathbb{Z}\subset\mathbb{R}, and let qα ⁣:R⟶Tα:=R/Λαq_\alpha\colon\mathbb{R}\longrightarrow T_{\alpha}:=\mathbb{R}/\Lambda_\alpha carry the quotient diffeology. Since Λα\Lambda_\alpha is dense in R\mathbb{R}, the quotient topology on TαT_{\alpha} is indiscrete. Equivalently TαT_{\alpha} is the space of leaves of the linear foliation of slope α\alpha on T2=R2/Z2T^2=\mathbb{R}^2/\mathbb{Z}^2: the map (x,y)↦y−αx(x,y)\mapsto y-\alpha x descends to a bijection T2/R→TαT^2/\mathbb{R}\to T_{\alpha}, which is a diffeomorphism for the quotient diffeologies. The two descriptions are drawn in 1.3.

Two pictures of the irrational torus. Left: the leaf space of the Kronecker foliation. Right: the quotient of R\mathbb{R} by the dense subgroup Λα\Lambda_\alpha, itself the image of Z2\mathbb{Z}^2 under a linear projection (the “cut and project” description of a one-dimensional quasicrystal).

Proposition 1.10.

  1. Every smooth map from TαT_{\alpha} to a manifold is constant; in particular C∞(Tα,R)=RC^{\infty}(T_{\alpha},\mathbb{R})=\mathbb{R}.

  2. The diffeology of TαT_{\alpha} is neither discrete nor coarse.

  3. qαq_\alpha is a subduction with discrete fibres, and any two local lifts of a plot differ by a locally constant element of Λα\Lambda_\alpha.

Proof. (i) If f ⁣:Tα→Mf\colon T_{\alpha}\to M is smooth then f∘qα ⁣:R→Mf\circ q_\alpha\colon\mathbb{R}\to M is continuous and Λα\Lambda_\alpha-invariant, hence constant on a dense set, hence constant. (iii) qαq_\alpha is a subduction by definition. If Q,Q′ ⁣:V→RQ,Q'\colon V\to\mathbb{R} lift the same plot then Q−Q′Q-Q' is a continuous map into the countable set Λα\Lambda_\alpha, so it is locally constant; in particular every plot of a fibre is locally constant, and the fibres are discrete. (ii) qαq_\alpha is a plot that is not locally constant, so TαT_{\alpha} is not discrete. The parametrisation t↦qα(∣t∣)t\mapsto q_\alpha(\sqrt{\lvert t\rvert}) is not a plot: by (iii) a local lift near 00 would be t↦∣t∣+λt\mapsto\sqrt{\lvert t\rvert}+\lambda, which is not smooth. So TαT_{\alpha} is not coarse. ◻

The D-topology of TαT_{\alpha} is indiscrete and its smooth real functions are constant, while its plots are those of a one-dimensional group. By Number theory: the arithmetic of irrational tori the plots determine the tail of the continued fraction of α\alpha.

Half of a line, twice

Let Δ1=R/{±1}\Delta_1=\mathbb{R}/\{\pm1\} with the quotient diffeology, and let H=[0,∞)⊂RH=[0,\infty)\subset\mathbb{R} with the subspace diffeology. The map x↦x2x\mapsto x^2 factors as R  ↠  Δ1  →   sq     H  ↪  R. \mathbb{R}\;\twoheadrightarrow\;\Delta_1\;\xrightarrow{\;\ \mathrm{sq}\ \;}\;H\;\hookrightarrow\;\mathbb{R}.

Proposition 1.11. sq ⁣:Δ1→H\mathrm{sq}\colon\Delta_1\to H is a smooth bijection that is not a diffeomorphism.

Proof. Smoothness and bijectivity are clear. The parametrisation P(r,s)=r2+s2P(r,s)=r^2+s^2 of HH is a plot, being smooth into R\mathbb{R} with values in HH. Suppose sq−1∘P\mathrm{sq}^{-1}\circ P were a plot of Δ1\Delta_1. Then on a disc VV around 00 there would be a smooth Q ⁣:V→RQ\colon V\to\mathbb{R} with Q2=r2+s2Q^2=r^2+s^2. On the connected set V∖{0}V\smallsetminus\{0\} the function QQ has no zero, so it has constant sign and Q=±r2+s2Q=\pm\sqrt{r^2+s^2}, which is not differentiable at the origin. ◻

The same set [0,∞)[0,\infty) carries two diffeologies. The plot on the left belongs to the subspace H⊂RH\subset\mathbb{R} but not to the quotient Δ1=R/{±1}\Delta_1=\mathbb{R}/\{\pm1\}, because lifting it through the squaring map would require smoothing a cone.

So (1) exhibits two different “images” of the squaring map: the quotient of the source and the subspace of the target. A map for which they coincide is called strict in [IZ, art. 1.54]; in The quasitopos \mathsf{Diff} the two images are identified with the two factorisation systems of a quasitopos, and the gap between them is the subject of Chapters Machine learning: differentiable programs and singular hypothesis spaces and System design: state spaces, quotients, clocks.

The cross

Let K={ (x,y)∈R2:xy=0 }K=\{\,(x,y)\in\mathbb{R}^2 : xy=0\,\} with the subspace diffeology, and let R∨R\mathbb{R}\vee\mathbb{R} be the pushout of two lines along their origins, with the final diffeology. The canonical map R∨R→K\mathbb{R}\vee\mathbb{R}\to K is a smooth bijection, and again not a diffeomorphism ([exo:cross]): a smooth curve in KK can cross from one axis to the other at an isolated time, provided all its derivatives vanish there; such a curve is not a plot of R∨R\mathbb{R}\vee\mathbb{R}.

The D-topology

Definition 1.12 ([IZ, art. 2.8]). A subset A⊆XA\subseteq X of a diffeological space is D-open if P−1(A)P^{-1}(A) is open for every plot PP. The D-open sets form the D-topology, the finest topology making all plots continuous.

Smooth maps are D-continuous, so this defines a functor D ⁣:Diff→TopD\colon\mathsf{Diff}\to\mathsf{Top}. For a quotient, A⊆X/∼A\subseteq X/{\sim} is D-open if and only if its preimage in XX is D-open [IZ, art. 2.12]. The D-topology of a manifold is its topology; the D-topology of TαT_{\alpha} is indiscrete. We will see in Proposition 1.6 that DD is a left adjoint, and in Shape that it is the wrong tool for homotopy theory: the homotopy type of D(Tα)D(T_{\alpha}) is a point, while the homotopy type that the plots of TαT_{\alpha} determine is a torus.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Show that for n≥2n\ge 2 the identity of Rn\mathbb{R}^n is not a plot for the wire diffeology of 1.4(c).

Solution.  If it were, then near 00 we could write id=γ∘h\mathrm{id}=\gamma\circ h with h ⁣:V→Rh\colon V\to\mathbb{R} and γ ⁣:R→Rn\gamma\colon\mathbb{R}\to\mathbb{R}^n smooth. By the chain rule the derivative of γ∘h\gamma\circ h at any point has rank at most 11, while the identity has rank n≥2n\ge 2. (The alternative, that id\mathrm{id} is locally constant, is absurd.) Hence the wire diffeology is strictly finer than the standard one, although both contain exactly the same smooth curves. ◀\blacktriangleleft

2 Show that the D-topology of Tα×TαT_{\alpha}\times T_{\alpha} is indiscrete, and that Tα×Tα≅R2/(Λα×Λα)T_{\alpha}\times T_{\alpha}\cong\mathbb{R}^2/(\Lambda_\alpha\times\Lambda_\alpha).

Solution.  By 1.7(i), qα×qα ⁣:R2→Tα×Tαq_\alpha\times q_\alpha\colon\mathbb{R}^2\to T_{\alpha}\times T_{\alpha} is a subduction. Its fibres are the cosets of Λα×Λα\Lambda_\alpha\times\Lambda_\alpha, so the induced bijection R2/(Λα×Λα)→Tα×Tα\mathbb{R}^2/(\Lambda_\alpha\times\Lambda_\alpha)\to T_{\alpha}\times T_{\alpha} is a subduction that is injective, hence a diffeomorphism by 1.7(iii). A D-open subset of the quotient has an open preimage in R2\mathbb{R}^2 that is invariant under the dense subgroup Λα×Λα\Lambda_\alpha\times\Lambda_\alpha; a non-empty open invariant set contains a translate of a ball by every element of a dense subgroup, so it is all of R2\mathbb{R}^2. ◀\blacktriangleleft

2 Let φ(t)=e−1/t\varphi(t)=e^{-1/t} for t>0t>0 and φ(t)=0\varphi(t)=0 for t≤0t\le0. Show that c(t)=(φ(t),φ(−t))c(t)=(\varphi(t),\varphi(-t)) is a plot of the cross KK that does not lift to a plot of R∨R\mathbb{R}\vee\mathbb{R}. Conclude that R∨R→K\mathbb{R}\vee\mathbb{R}\to K is not a diffeomorphism.

Solution.  cc is smooth into R2\mathbb{R}^2 and φ(t)φ(−t)=0\varphi(t)\varphi(-t)=0, so cc is a plot of the subspace KK. A plot of the pushout R∨R\mathbb{R}\vee\mathbb{R} is, near each point, constant or of the form ιj∘Q\iota_j\circ Q with ιj\iota_j one of the two inclusions of R\mathbb{R} (final diffeology, 1.6(ii)); so near each point its image lies in one of the two lines. Every neighbourhood of t=0t=0 contains points t>0t>0 with c(t)c(t) on the first axis minus the origin and points t<0t<0 with c(t)c(t) on the second axis minus the origin. Hence cc is not a plot of R∨R\mathbb{R}\vee\mathbb{R}, the bijection R∨R→K\mathbb{R}\vee\mathbb{R}\to K does not pull plots back to plots, and it is not a diffeomorphism. ◀\blacktriangleleft

3 Prove 1.7.

Solution.  (i) Composition. If f ⁣:X→Yf\colon X\to Y and g ⁣:Y→Zg\colon Y\to Z are subductions, a plot of ZZ lifts locally to YY, and that lift lifts locally to XX. Products. A plot of Y1×Y2Y_1\times Y_2 is a pair (P1,P2)(P_1,P_2) of plots with common domain; near rr lift PiP_i to QiQ_i on Vi∋rV_i\ni r and take (Q1,Q2)(Q_1,Q_2) on V1∩V2V_1\cap V_2. Pullback. Let π ⁣:X→B\pi\colon X\to B be a subduction and f ⁣:B′→Bf\colon B'\to B smooth, and put X′={ (b′,x):f(b′)=π(x) }⊆B′×XX'=\{\,(b',x) : f(b')=\pi(x)\,\}\subseteq B'\times X with the subspace diffeology, which is the pullback by 1.6. The projection X′→B′X'\to B' is surjective because π\pi is. Given a plot PP of B′B', the plot f∘Pf\circ P of BB lifts near rr to a plot QQ of XX with π∘Q=f∘P\pi\circ Q=f\circ P; then (P,Q)(P,Q) takes values in X′X', is a plot of B′×XB'\times X, hence a plot of X′X', and lifts PP.

(ii) Composition is immediate from the characterisation “PP is a plot iff f∘Pf\circ P is”. Products: componentwise. Pullback: let j ⁣:A→Bj\colon A\to B be an induction and f ⁣:B′→Bf\colon B'\to B smooth, A′={ (b′,a):f(b′)=j(a) }A'=\{\,(b',a): f(b')=j(a)\,\}. The projection A′→B′A'\to B' is injective since jj is. If PP is a parametrisation of A′A' with components (P1,P2)(P_1,P_2) such that P1P_1 is a plot of B′B', then j∘P2=f∘P1j\circ P_2=f\circ P_1 is a plot of BB, so P2P_2 is a plot of AA because jj is an induction, and PP is a plot of A′A'.

(iii) A map that is both is bijective; its inverse sends a plot PP of the target to a parametrisation whose composite with ff is the plot PP, hence to a plot, because ff is an induction. ◀\blacktriangleleft

4 Prove 1.9.

Solution.  Write Φ(f)(x)(y)=f(x,y)\Phi(f)(x)(y)=f(x,y).

Step 1: a bijection C∞(A×Y,Z)→C∞(A,C∞(Y,Z))C^{\infty}(A\times Y,Z)\to C^{\infty}(A,C^{\infty}(Y,Z)) for every diffeological space AA. Let f ⁣:A×Y→Zf\colon A\times Y\to Z be smooth. For fixed aa the map f(a,−)f(a,-) is the composite of ff with the smooth map y↦(a,y)y\mapsto(a,y), so Φ(f)(a)∈C∞(Y,Z)\Phi(f)(a)\in C^{\infty}(Y,Z). To see that Φ(f)\Phi(f) is smooth, let P ⁣:U→AP\colon U\to A be a plot; we must show that (r,y)↦f(P(r),y)(r,y)\mapsto f(P(r),y) is smooth on U×YU\times Y. A plot of U×YU\times Y is a pair (ρ,Q)(\rho,Q), and s↦f(P(ρ(s)),Q(s))s\mapsto f(P(\rho(s)),Q(s)) is ff composed with the plot (P∘ρ,Q)(P\circ\rho,Q) of A×YA\times Y. So Φ\Phi is well defined; it is clearly injective. Conversely let g ⁣:A→C∞(Y,Z)g\colon A\to C^{\infty}(Y,Z) be smooth and put f(a,y)=g(a)(y)f(a,y)=g(a)(y). For a plot (P,Q) ⁣:U→A×Y(P,Q)\colon U\to A\times Y, the map g∘Pg\circ P is a plot of C∞(Y,Z)C^{\infty}(Y,Z), that is, (r,y)↦g(P(r))(y)(r,y)\mapsto g(P(r))(y) is smooth on U×YU\times Y; composing with the plot r↦(r,Q(r))r\mapsto(r,Q(r)) of U×YU\times Y shows that r↦f(P(r),Q(r))r\mapsto f(P(r),Q(r)) is a plot of ZZ. So ff is smooth and Φ(f)=g\Phi(f)=g.

Step 2: Φ\Phi is a diffeomorphism. By 1.2 and 1.8, a plot U→C∞(X×Y,Z)U\to C^{\infty}(X\times Y,Z) is the same as a smooth map U×X×Y→ZU\times X\times Y\to Z. By Step 1 with A=U×XA=U\times X this is the same as a smooth map U×X→C∞(Y,Z)U\times X\to C^{\infty}(Y,Z), which by 1.8 is the same as a plot U→C∞(X,C∞(Y,Z))U\to C^{\infty}(X,C^{\infty}(Y,Z)). The composite identification is P↦Φ∘PP\mapsto\Phi\circ P. So Φ\Phi and Φ−1\Phi^{-1} carry plots to plots.

Step 3: evaluation and composition. Evaluation corresponds under Φ\Phi to the identity of C∞(Y,Z)C^{\infty}(Y,Z). Composition C∞(X,Y)×C∞(Y,Z)→C∞(X,Z)C^{\infty}(X,Y)\times C^{\infty}(Y,Z)\to C^{\infty}(X,Z) is smooth if and only if its adjoint C∞(X,Y)×C∞(Y,Z)×X→ZC^{\infty}(X,Y)\times C^{\infty}(Y,Z)\times X\to Z, (f,g,x)↦g(f(x))(f,g,x)\mapsto g(f(x)), is smooth, and this is two evaluations. ◀\blacktriangleleft

Concrete sheaves

By axioms [D1]–[D3], the plots of XX form a sheaf on the site of domains, and this sheaf is determined by its points. We prove the Baez–Hoffnung theorem Diff≃ConcSh(Cart)\mathsf{Diff}\simeq\mathsf{ConcSh}(\mathsf{Cart}), identify concreteness with separatedness for the adjunction Γ⊣coDisc⁡\Gamma\dashv\operatorname{coDisc}, construct the concretisation functor, and introduce the first sheaves that are not diffeological spaces: the classifying sheaves of differential forms.

Source in the book. The axioms of [IZ, art. 1.5]. The dictionary between diffeologies and sheaves is due to Baez and Hoffnung [3], building on Dubuc [17].

The site

Let Dom\mathsf{Dom} be the category of domains and smooth maps, and Cart⊂Dom\mathsf{Cart}\subset\mathsf{Dom} the full subcategory of Cartesian spaces. A family of open embeddings { Ui↪U }\{\,U_i\hookrightarrow U\,\} is covering if it is jointly surjective. This is a coverage on both categories: the preimage of an open cover under a smooth map is an open cover, and every open subset of Rn\mathbb{R}^n is a union of open balls, each diffeomorphic to Rn\mathbb{R}^n. By the same remark, Cart\mathsf{Cart} is a dense subsite of Dom\mathsf{Dom}, so by the comparison lemma [35, C2.2.3] restriction is an equivalence Sh(Dom)  → ≃   Sh(Cart)=:SmoothSet.\mathsf{Sh}(\mathsf{Dom})\;\xrightarrow{\ \simeq\ }\;\mathsf{Sh}(\mathsf{Cart})=:\mathsf{SmoothSet}. Objects of SmoothSet\mathsf{SmoothSet} are called smooth sets. We use Cart\mathsf{Cart} by default because its objects are contractible, which will matter in Cohesion; the reader who prefers the plots of [1] to be defined on arbitrary domains loses nothing.

Both sites have a terminal object, R0=∗\mathbb{R}^0=\ast, and for every object UU the set Hom⁡(∗,U)\operatorname{Hom}(\ast,U) is the underlying set ∣U∣|U|.

The Baez–Hoffnung theorem

Definition 1.1. A presheaf FF on Cart\mathsf{Cart} (or Dom\mathsf{Dom}) is concrete if for every UU the map F(U)⟶Set(∣U∣,F(∗)),s⟼(u↦u∗s),F(U)\longrightarrow\mathsf{Set}\bigl(|U|,F(\ast)\bigr),\qquad s\longmapsto\bigl(u\mapsto u^*s\bigr), is injective. ConcSh(Cart)⊂SmoothSet\mathsf{ConcSh}(\mathsf{Cart})\subset\mathsf{SmoothSet} is the full subcategory of concrete sheaves.

In words: a section over UU is determined by the function ∣U∣→F(∗)|U|\to F(\ast) it induces on points. A section of a concrete sheaf is a function with a property; a section of a general sheaf is a function with extra structure, or no function at all.

Theorem 1.2 (Baez–Hoffnung [3). ]The assignment X↦X‾:=Diff(−,X)X\mapsto\underline X:=\mathsf{Diff}(-,X) is an equivalence of categories Diff  → ≃   ConcSh(Cart),\mathsf{Diff}\;\xrightarrow{\ \simeq\ }\;\mathsf{ConcSh}(\mathsf{Cart}), with inverse F↦(F(∗), images of the maps F(U)→Set(∣U∣,F(∗)))F\mapsto\bigl(F(\ast),\ \text{images of the maps }F(U)\to\mathsf{Set}(|U|,F(\ast))\bigr).

Proof. X‾\underline X is a concrete sheaf. By Remark 1.2, X‾(U)\underline X(U) is the set of plots with source UU. Axiom [D3] makes it a presheaf. It is concrete because a plot is a function and X‾(∗)=X\underline X(\ast)=X by [D1]. It is separated because functions that coincide locally coincide. Given a compatible family of plots Pi ⁣:Ui→XP_i\colon U_i\to X on a cover, compatibility on points of the overlaps means that the PiP_i glue to a function P ⁣:U→XP\colon U\to X, and PP is a plot by [D2].

From a concrete sheaf to a diffeology. Let FF be a concrete sheaf, X=F(∗)X=F(\ast), and let DU⊆Set(∣U∣,X)\mathcal D_U\subseteq\mathsf{Set}(|U|,X) be the image of F(U)F(U). [D1]: for x∈Xx\in X, the pullback of xx along U→∗U\to\ast is a section whose underlying function is constant at xx. [D3]: naturality of F(U)→Set(∣U∣,X)F(U)\to\mathsf{Set}(|U|,X) in UU. [D2]: let P ⁣:∣U∣→XP\colon|U|\to X restrict to elements of DUi\mathcal D_{U_i} on a cover. By concreteness there are unique si∈F(Ui)s_i\in F(U_i) with underlying function P∣UiP|_{U_i}. For any W→UiW\to U_i, W→UjW\to U_j with the same composite to UU, the two restrictions of sis_i and sjs_j to WW have the same underlying function, hence coincide by concreteness. So the sis_i glue to s∈F(U)s\in F(U), whose underlying function coincides with PP on each UiU_i, hence is PP.

Morphisms. A natural transformation φ ⁣:F→G\varphi\colon F\to G of concrete sheaves is determined by φ∗ ⁣:F(∗)→G(∗)\varphi_\ast\colon F(\ast)\to G(\ast), because the square relating φU\varphi_U to post-composition with φ∗\varphi_\ast commutes and G(U)→Set(∣U∣,G(∗))G(U)\to\mathsf{Set}(|U|,G(\ast)) is injective; and by the same square φ∗\varphi_\ast carries plots to plots. Conversely a smooth map induces a natural transformation by composition. The two constructions on objects are mutually inverse by inspection. ◻

Three nested categories of “smooth spaces”. Each hook is full and faithful; the two leftward arrows are left adjoints (reflections). There is no reflection onto Mfd\mathsf{Mfd}, which is why manifolds are closed under so few constructions.

Remark 1.3 (What each axiom is). [D3] is functoriality, [D2] is descent, [D1] is a normalisation that makes the value on the point the underlying set. The only hypothesis of Definition 1.1 with no sheaf-theoretic name is the unstated one: that a plot is a map of sets. That is concreteness.

Concrete sites

The proof of 1.2 used only two properties of the site.

Definition 1.4 ([17, 3). ]A concrete site is a subcanonical site C\mathcal C with a terminal object ∗\ast such that (a) ∣⋅∣=Hom⁡(∗,−) ⁣:C→Set|\cdot|=\operatorname{Hom}(\ast,-)\colon\mathcal C\to\mathsf{Set} is faithful, and (b) covering families are jointly surjective on points.

Concrete sites and their concrete sheaves. Dropping concreteness in the first row gives smooth sets; in the third it gives, up to set-theoretic care, condensed sets. The last row is the semantic basis of higher-order probabilistic programming and reappears in Artificial intelligence: planning, observation, semantics.
concrete site covers concrete sheaves
Cart\mathsf{Cart} or Dom\mathsf{Dom}, smooth maps open covers diffeological spaces [53, 1]
convex subsets of Rn\mathbb{R}^n, smooth maps open covers Chen spaces [10, 3]
compact Hausdorff spaces finite jointly surjective families quasi-topological spaces [17]
standard Borel spaces countable Borel covers quasi-Borel spaces [25]

Every statement in the rest of this chapter holds for an arbitrary concrete site with the same proof.

Points, codiscrete objects, and separatedness

Let Γ ⁣:SmoothSet→Set\Gamma\colon\mathsf{SmoothSet}\to\mathsf{Set} be evaluation at the point, Γ(F)=F(∗)\Gamma(F)=F(\ast). For a set SS define a presheaf coDisc⁡(S)(U)=Set(∣U∣,S).\operatorname{coDisc}(S)(U)=\mathsf{Set}(|U|,S).

Lemma 1.5. coDisc⁡(S)\operatorname{coDisc}(S) is a concrete sheaf — it is the set SS with the coarse diffeology — and Γ⊣coDisc⁡\Gamma\dashv\operatorname{coDisc}. The counit ΓcoDisc⁡(S)→S\Gamma\operatorname{coDisc}(S)\to S is a bijection, so coDisc⁡\operatorname{coDisc} is full and faithful. A sheaf FF is concrete if and only if the unit ηF ⁣:F⟶coDisc⁡ ΓF\eta_F\colon F\longrightarrow\operatorname{coDisc}\,\Gamma F is a monomorphism.

The proof is [exo:coDisc]. The last sentence is a restatement of 1.1, but it changes what kind of condition concreteness is. The pair Γ⊣coDisc⁡\Gamma\dashv\operatorname{coDisc} exhibits Set\mathsf{Set} as a subtopos of SmoothSet\mathsf{SmoothSet} (the inverse image Γ\Gamma preserves all limits), hence corresponds to a Lawvere–Tierney topology jj on SmoothSet\mathsf{SmoothSet}, and an object is jj-separated exactly when the unit to its jj-sheafification is monic [35, A4.4]. So:

Theorem 1.6 (Dubuc [17). ; Baez–Hoffnung [3]; [35, A4.4, C2.2.13]]Diff\mathsf{Diff} is the category of separated objects for the Lawvere–Tierney topology on SmoothSet\mathsf{SmoothSet} whose sheaves are the codiscrete objects. Consequently Diff\mathsf{Diff} is a Grothendieck quasitopos: it is complete, cocomplete and locally Cartesian closed, it has a classifier for strong subobjects, and it is a reflective subcategory of SmoothSet\mathsf{SmoothSet} closed under limits, subobjects, and exponentials GFG^F with GG concrete and FF arbitrary.

Each clause is made explicit in terms of plots in The quasitopos \mathsf{Diff}. Here we only construct the reflection.

Concretisation

Proposition 1.7 (Concretisation). The inclusion Diff↪SmoothSet\mathsf{Diff}\hookrightarrow\mathsf{SmoothSet} has a left adjoint conc⁡(F)=im⁡(ηF ⁣:F→coDisc⁡ ΓF).\operatorname{conc}(F)=\operatorname{im}\bigl(\eta_F\colon F\to\operatorname{coDisc}\,\Gamma F\bigr). Explicitly, conc⁡(F)\operatorname{conc}(F) is the set F(∗)F(\ast) with the diffeology whose plots are the functions ∣U∣→F(∗)|U|\to F(\ast) that are locally the underlying function of a section of FF. The functor conc⁡\operatorname{conc} preserves finite products and epimorphisms, and F→conc⁡FF\to\operatorname{conc}F is an epimorphism of sheaves.

The proof is [exo:conc]. Two consequences are used constantly.

Corollary 1.8. Colimits in Diff\mathsf{Diff} are computed by taking the colimit in SmoothSet\mathsf{SmoothSet} and concretising. Limits in Diff\mathsf{Diff} are computed in SmoothSet\mathsf{SmoothSet}. In particular, for a diffeological group GG acting on a diffeological space XX, X/G  =  conc⁡(sheaf quotient of X by G).X/G\;=\;\operatorname{conc}\bigl(\text{sheaf quotient of }X\text{ by }G\bigr).

Concretisation is an image factorisation: two sections have the same image exactly when they have the same values on points.

Sheaves that are not spaces

The reason to care about SmoothSet∖Diff\mathsf{SmoothSet}\smallsetminus\mathsf{Diff} is that it contains the moduli objects of differential geometry.

Example 1.9 (Differential forms). For k≥0k\ge0 let Ωk(U)\Omega^k(U) be the vector space of smooth differential kk-forms on UU, with pullback as restriction. This is a sheaf on Cart\mathsf{Cart}. For k=0k=0 it is the representable R‾\underline{\mathbb{R}}, hence concrete. For k≥1k\ge1 we have Ωk(∗)=0\Omega^k(\ast)=0, so ΓΩk\Gamma\Omega^k is a single point while Ωk(Rk)\Omega^k(\mathbb{R}^k) is infinite-dimensional: Ωk\Omega^k is as far from concrete as possible, and conc⁡ Ωk=∗\operatorname{conc}\,\Omega^k=\ast. The same holds for the subsheaf Ωclk\Omega^k_{\mathrm{cl}} of closed forms.

Example 1.10 (A quotient that is not a space). Let Rδ\mathbb{R}^{\delta} be the additive group of real numbers with the discrete diffeology, acting on R\mathbb{R} by translation. The diffeological quotient R/Rδ\mathbb{R}/\mathbb{R}^{\delta} is a point. The sheaf quotient is not: the exterior derivative d ⁣:R‾→Ωcl1\mathrm{d}\colon\underline{\mathbb{R}}\to\Omega^1_{\mathrm{cl}} is an epimorphism of sheaves on Cart\mathsf{Cart} by the Poincaré lemma, and two functions have the same differential exactly when they differ by a locally constant function, so R‾ / Rδ  ≅  Ωcl1in SmoothSet.\underline{\mathbb{R}}\,/\,\mathbb{R}^{\delta}\;\cong\;\Omega^1_{\mathrm{cl}}\qquad\text{in }\mathsf{SmoothSet}. The “space of real numbers up to a constant” is the classifying sheaf of closed 11-forms. Its concretisation is a point.

Example 1.11 (An orbit space, before concretisation). Let QQ be the sheaf quotient of R\mathbb{R} by {±1}\{\pm1\}. With φ\varphi as in [exo:cross], the functions f(x)=φ(x)−φ(−x)f(x)=\varphi(x)-\varphi(-x) and g=∣f∣g=\lvert f\rvert are both smooth, and g(x)=±f(x)g(x)=\pm f(x) for every xx, so they define the same plot of Δ1=conc⁡Q\Delta_1=\operatorname{conc}Q. But they are different sections of QQ, because near 00 there is no locally constant sign ε\varepsilon with g=εfg=\varepsilon f. So QQ is not concrete: in Δ1\Delta_1 two parametrised families of orbits are equal as soon as they coincide pointwise, while in QQ equality requires a locally constant sign relating their lifts. A third object appears in Bundles and stacks: the stack R/ ⁣ ⁣/{±1}\mathbb{R}/\!\!/\{\pm1\}, in which the stabiliser of 00 is part of the data.

Remark 1.12 (Summary). A diffeological space is a smooth set with enough points. The classifying objects of geometry typically have too few: a differential form is not a function on points, and a principal bundle is not even a section of a sheaf of sets. In [1] differential forms are obtained by defining them directly on plots [IZ, art. 6.28]; by Forms this definition is Hom⁡SmoothSet(X,Ωk)\operatorname{Hom}_{\mathsf{SmoothSet}}(X,\Omega^k), and the exactness properties of the theory are those of SmoothSet\mathsf{SmoothSet}.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Show that the representable presheaf Rn‾=Cart(−,Rn)\underline{\mathbb{R}^n}=\mathsf{Cart}(-,\mathbb{R}^n) is a concrete sheaf, and identify the diffeological space it corresponds to under 1.2.

Solution.  A smooth map is determined by its values, so Cart(U,Rn)→Set(∣U∣,Rn)\mathsf{Cart}(U,\mathbb{R}^n)\to\mathsf{Set}(|U|,\mathbb{R}^n) is injective. Smoothness is a local condition and smooth maps that coincide on overlaps glue, so Rn‾\underline{\mathbb{R}^n} is a sheaf (the site is subcanonical). Its value on ∗\ast is the set Rn\mathbb{R}^n and its plots are the smooth parametrisations: it is Rn\mathbb{R}^n with the standard diffeology. ◀\blacktriangleleft

2 Show that Hom⁡SmoothSet(Ω1,R‾)=R\operatorname{Hom}_{\mathsf{SmoothSet}}(\Omega^1,\underline{\mathbb{R}})=\mathbb{R} (constant maps only), while Hom⁡SmoothSet(R‾,Ω1)≅C∞(R)\operatorname{Hom}_{\mathsf{SmoothSet}}(\underline{\mathbb{R}},\Omega^1)\cong C^{\infty}(\mathbb{R}).

Solution.  Let φ ⁣:Ω1→R‾\varphi\colon\Omega^1\to\underline{\mathbb{R}} be natural. For ω∈Ω1(U)\omega\in\Omega^1(U) and a point u ⁣:∗→Uu\colon\ast\to U we get φU(ω)(u)=φ∗(u∗ω)=φ∗(0)\varphi_U(\omega)(u)=\varphi_\ast(u^*\omega)=\varphi_\ast(0), because Ω1(∗)=0\Omega^1(\ast)=0. So φU(ω)\varphi_U(\omega) is the constant function with value c=φ∗(0)c=\varphi_\ast(0), for every ω\omega. Conversely each constant is natural. For the second claim, the Yoneda lemma gives Hom⁡(R‾,Ω1)=Ω1(R)={ a(x) dx }≅C∞(R)\operatorname{Hom}(\underline{\mathbb{R}},\Omega^1)=\Omega^1(\mathbb{R})=\{\,a(x)\,\mathrm{d}x\,\}\cong C^{\infty}(\mathbb{R}). So there are many maps from a space to Ω1\Omega^1 and essentially none from Ω1\Omega^1 to a space: Ω1\Omega^1 is a place one maps into. ◀\blacktriangleleft

2 Verify the isomorphism R‾/Rδ≅Ωcl1\underline{\mathbb{R}}/\mathbb{R}^{\delta}\cong\Omega^1_{\mathrm{cl}} of 1.10 by checking that d ⁣:R‾→Ωcl1\mathrm{d}\colon\underline{\mathbb{R}}\to\Omega^1_{\mathrm{cl}} is the coequaliser of the action.

Solution.  In a topos every epimorphism is the coequaliser of its kernel pair. d\mathrm{d} is an epimorphism: on a Cartesian space every closed 11-form is exact, so dU ⁣:C∞(U)→Ωcl1(U)\mathrm{d}_U\colon C^{\infty}(U)\to\Omega^1_{\mathrm{cl}}(U) is already surjective for every U∈CartU\in\mathsf{Cart}. Its kernel pair: sections over UU are pairs (f,g)(f,g) with df=dg\mathrm{d}f=\mathrm{d}g, that is, g=f+cg=f+c with cc constant, UU being connected. That is exactly the image of the map R‾×Rδ→R‾×R‾\underline{\mathbb{R}}\times\mathbb{R}^{\delta}\to\underline{\mathbb{R}}\times\underline{\mathbb{R}}, (f,c)↦(f,f+c)(f,c)\mapsto(f,f+c), since sections of the discrete Rδ\mathbb{R}^{\delta} over a connected UU are constants. So the kernel pair of d\mathrm{d} is the action groupoid, and Ωcl1\Omega^1_{\mathrm{cl}} is its quotient. ◀\blacktriangleleft

3 Prove 1.5 for an arbitrary concrete site.

Solution.  Sheaf. Let RR be a covering sieve on DD and (sg)g∈R(s_g)_{g\in R} a compatible family, sg∈Set(∣E∣,S)s_g\in\mathsf{Set}(|E|,S) for g ⁣:E→Dg\colon E\to D. Define s ⁣:∣D∣→Ss\colon|D|\to S by s(d)=sg(e)s(d)=s_g(e) whenever g(e)=dg(e)=d with g∈Rg\in R; such (g,e)(g,e) exist by axiom (b). It is well defined: the point d ⁣:∗→Dd\colon\ast\to D equals g∘eg\circ e, which lies in the sieve, and compatibility gives sg∘e=e∗sg=sg(e)s_{g\circ e}=e^*s_g=s_g(e), an element of Set(∣∗∣,S)=S\mathsf{Set}(|\ast|,S)=S depending only on dd. By construction g∗s=sgg^*s=s_g, and ss is unique because the g∈Rg\in R are jointly surjective on points. Concrete: coDisc⁡(S)(∗)=S\operatorname{coDisc}(S)(\ast)=S and the comparison map is the identity of Set(∣D∣,S)\mathsf{Set}(|D|,S).

Adjunction. Given φ ⁣:F→coDisc⁡S\varphi\colon F\to\operatorname{coDisc}S, naturality with respect to points d ⁣:∗→Dd\colon\ast\to D forces φD(t)(d)=φ∗(d∗t)\varphi_D(t)(d)=\varphi_\ast(d^*t), so φ\varphi is determined by φ∗ ⁣:F(∗)→S\varphi_\ast\colon F(\ast)\to S; conversely any function F(∗)→SF(\ast)\to S defines a natural transformation by this formula. Hence Hom⁡(F,coDisc⁡S)≅Set(ΓF,S)\operatorname{Hom}(F,\operatorname{coDisc}S)\cong\mathsf{Set}(\Gamma F,S), naturally. The counit at SS is the identity of SS. The unit ηF\eta_F at DD sends tt to d↦d∗td\mapsto d^*t, which is the map of 1.1; a morphism of sheaves is monic iff it is injective on every F(D)F(D). ◀\blacktriangleleft

4 Prove 1.7: the image of ηF\eta_F is a concrete sheaf, F↦im⁡ηFF\mapsto\operatorname{im}\eta_F is left adjoint to the inclusion, and it preserves finite products.

Solution.  Write C=im⁡ηF⊆coDisc⁡ ΓFC=\operatorname{im}\eta_F\subseteq\operatorname{coDisc}\,\Gamma F, the image in the topos SmoothSet\mathsf{SmoothSet}, so that F↠C↪coDisc⁡ ΓFF\twoheadrightarrow C\hookrightarrow\operatorname{coDisc}\,\Gamma F.

CC is concrete. A subsheaf CC of a concrete sheaf GG is concrete: C(U)⊆G(U)↪Set(∣U∣,G(∗))C(U)\subseteq G(U)\hookrightarrow\mathsf{Set}(|U|,G(\ast)), and by naturality the functions so obtained take values in C(∗)C(\ast). Here C(∗)=F(∗)C(\ast)=F(\ast) because evaluation at ∗\ast preserves images and ηF\eta_F is a bijection on points. Since the image sheaf is the sheafification of the presheaf image, C(U)C(U) consists of the functions that are locally underlying functions of sections of FF.

Universal property. Let f ⁣:F→Gf\colon F\to G with GG concrete. By naturality of η\eta, ηG∘f=coDisc⁡Γ(f)∘ηF.\eta_G\circ f=\operatorname{coDisc}\Gamma(f)\circ\eta_F . Let (a,b)(a,b) be a pair of generalised elements of FF with ηFa=ηFb\eta_Fa=\eta_Fb. Then ηGfa=ηGfb\eta_Gfa=\eta_Gfb, and ηG\eta_G is monic, so fa=fbfa=fb. Thus ff coequalises the kernel pair of ηF\eta_F. In a topos the epimorphism F↠CF\twoheadrightarrow C is the coequaliser of that kernel pair, so ff factors uniquely through CC. This is the adjunction Hom⁡Diff(conc⁡F,G)≅Hom⁡SmoothSet(F,G)\operatorname{Hom}_{\mathsf{Diff}}(\operatorname{conc}F,G)\cong\operatorname{Hom}_{\mathsf{SmoothSet}}(F,G).

Finite products. Γ\Gamma and coDisc⁡\operatorname{coDisc} preserve products, so ηF×F′=ηF×ηF′\eta_{F\times F'}=\eta_F\times\eta_{F'}. In a topos a product of two epimorphisms is an epimorphism (pullbacks of epimorphisms are epimorphisms) and a product of monomorphisms is a monomorphism, so F×F′↠C×C′↪coDisc⁡ΓF×coDisc⁡ΓF′F\times F'\twoheadrightarrow C\times C'\hookrightarrow\operatorname{coDisc}\Gamma F\times\operatorname{coDisc}\Gamma F' is the image factorisation of ηF×F′\eta_{F\times F'}. Also conc⁡(∗)=∗\operatorname{conc}(\ast)=\ast.

Epimorphisms. conc⁡\operatorname{conc} is a left adjoint, so it preserves epimorphisms as a functor to Diff\mathsf{Diff}; and F↠conc⁡FF\twoheadrightarrow\operatorname{conc}F is epic in SmoothSet\mathsf{SmoothSet} by construction.

A consequence. For GG concrete and FF arbitrary, GFG^F is concrete: for any sheaf AA, Hom⁡(A,GF)≅Hom⁡(A×F,G)≅Hom⁡(conc⁡(A)×conc⁡(F),G)\operatorname{Hom}(A,G^F)\cong\operatorname{Hom}(A\times F,G)\cong\operatorname{Hom}(\operatorname{conc}(A)\times\operatorname{conc}(F),G) depends on AA only through conc⁡A\operatorname{conc}A. So every map A→GFA\to G^F factors uniquely through A↠conc⁡AA\twoheadrightarrow\operatorname{conc}A; applied to the identity of A=GFA=G^F this splits the epimorphism GF↠conc⁡(GF)G^F\twoheadrightarrow\operatorname{conc}(G^F), which is therefore an isomorphism. ◀\blacktriangleleft

The quasitopos Diff\mathsf{Diff}

We make Theorem 1.6 explicit. Inductions and subductions are the strong monomorphisms and strong epimorphisms; every smooth map has two canonical images; function spaces exist in every slice. We then say precisely what Diff\mathsf{Diff} lacks: equivalence relations are not effective. That one defect is the reason for the next two enlargements, to smooth sets and to smooth ∞\infty-groupoids.

Source in the book. [IZ, art. 1.29–1.65]: inductions, subductions, strict maps, functional diffeology; [IZ, art. 2.8–2.12] for the D-topology.

Four classes of maps

Proposition 1.1. In Diff\mathsf{Diff}:

  1. the monomorphisms are the injective smooth maps, and the epimorphisms are the surjective smooth maps;

  2. the strong monomorphisms are the inductions, and the strong epimorphisms are the subductions.

Proof. (i) Injective maps are monic. Conversely test against maps from the point. Surjective maps are epic. Conversely, if f ⁣:X→Yf\colon X\to Y misses a point y0y_0, the two maps Y→coDisc⁡{0,1}Y\to\operatorname{coDisc}\{0,1\} given by the constant 00 and the indicator of y0y_0 are smooth (every map into a coarse space is) and coincide on f(X)f(X). (ii) is [exo:strongmono] and its dual. ◻

Recall that a monomorphism mm is strong if it is right orthogonal to every epimorphism: in each commutative square with an epimorphism ee on the left and mm on the right there is a unique diagonal filler. In a topos every monomorphism is strong. In Diff\mathsf{Diff} the identity map Rdisc⟶R\mathbb{R}_{\mathrm{disc}}\longrightarrow\mathbb{R} is monic and epic but not an isomorphism, so Diff\mathsf{Diff} is not balanced and is not a topos. The four classes are drawn in 1.1.

Monomorphisms and epimorphisms in Diff\mathsf{Diff}, with their strong subclasses. The marked map lies in both outer regions and in neither inner one. In a topos the inner and outer regions coincide.

Two images

Theorem 1.2 (Two factorisation systems). Every smooth map f ⁣:X→Yf\colon X\to Y factors, uniquely up to unique diffeomorphism, in two ways: image where x∼fx′x\sim_f x' iff f(x)=f(x′)f(x)=f(x'), the quotient carries the quotient diffeology and f(X)subf(X)_{\mathrm{sub}} the subspace diffeology. The comparison κf\kappa_f is a smooth bijection. (Strong epi, mono) and (epi, strong mono) are orthogonal factorisation systems on Diff\mathsf{Diff}, and both left classes are stable under pullback.

Proof. Existence is the universal property of the quotient and of the subspace (Theorem 1.6). Orthogonality of subductions against injections: given a square m∘u=v∘em\circ u=v\circ e with e ⁣:A↠Be\colon A\twoheadrightarrow B a subduction and mm injective, the unique set-theoretic filler d ⁣:B→Xd\colon B\to X satisfies d∘e=ud\circ e=u, so it is smooth because ee is a subduction (final lift). Orthogonality of surjections against inductions is [exo:strongmono]. Uniqueness follows from orthogonality. Pullback stability of subductions is Proposition 1.7; surjections are pullback stable in Set\mathsf{Set}. ◻

Definition 1.3 ([IZ, art. 1.54]). A smooth map ff is strict if κf ⁣:coim⁡f→im⁡f\kappa_f\colon\operatorname{coim}f\to\operatorname{im}f is a diffeomorphism.

In a topos every map is strict. In Diff\mathsf{Diff} strictness is a real condition, and the non-strict maps are where the geometry is (1.1). The reader should think of coim⁡f\operatorname{coim}f as “XX with the identifications induced by ff” and of im⁡f\operatorname{im}f as “the part of YY in the range of ff”; they have the same points, and coim⁡f\operatorname{coim} f has fewer plots.

Coimage and image of some smooth maps. In the second row the Δn\Delta_n are pairwise non-diffeomorphic [IZ, Exercise 50], so infinitely many different coimages have a single image.
map ff coim⁡f\operatorname{coim} f im⁡f\operatorname{im}f strict?
R→R\mathbb{R}\to\mathbb{R}, x↦x2x\mapsto x^2 Δ1=R/{±1}\Delta_1=\mathbb{R}/\{\pm1\} H=[0,∞)subH=[0,\infty)_{\mathrm{sub}} no (Proposition 1.11)
Rn→R\mathbb{R}^n\to\mathbb{R}, x↦∣x∣2x\mapsto\lvert x\rvert^2 Δn=Rn/O⁡(n)\Delta_n=\mathbb{R}^n/\operatorname{O}(n) HH no [IZ, Exercise 50]
R⊔R→R2\mathbb{R}\sqcup\mathbb{R}\to\mathbb{R}^2, the two axes R∨R\mathbb{R}\vee\mathbb{R} the cross KK no ([exo:cross])
(0,2π)→R2(0,2\pi)\to\mathbb{R}^2, figure eight (0,2π)(0,2\pi) figure eightsub_{\mathrm{sub}} no ([exo:eight])
R→T2\mathbb{R}\to T^2, t↦[t,αt]t\mapsto[t,\alpha t] R\mathbb{R} dense leafsub_{\mathrm{sub}} yes [IZ, Exercise 31]
R→Tα\mathbb{R}\to T_{\alpha} TαT_{\alpha} TαT_{\alpha} yes

Subobjects and function spaces

Proposition 1.4 (Strong subobject classifier). Let Ωst=coDisc⁡{0,1}\Omega_{\mathrm{st}}=\operatorname{coDisc}\{0,1\}. For every diffeological space XX, the map A↦χAA\mapsto\chi_A is a bijection between subsets A⊆XA\subseteq X (equivalently, isomorphism classes of inductions into XX) and smooth maps X→ΩstX\to\Omega_{\mathrm{st}}, and Asub↪XA_{\mathrm{sub}}\hookrightarrow X is the pullback of {1}↪Ωst\{1\}\hookrightarrow\Omega_{\mathrm{st}} along χA\chi_A.

Proof. Every function into a coarse space is smooth, so Diff(X,Ωst)=Set(X,{0,1})\mathsf{Diff}(X,\Omega_{\mathrm{st}})=\mathsf{Set}(X,\{0,1\}). The pullback of {1}↪Ωst\{1\}\hookrightarrow\Omega_{\mathrm{st}} along χA\chi_A is the set AA with the initial diffeology for A→XA\to X, the map to the point imposing no condition. ◻

So Diff\mathsf{Diff} classifies the subobjects that carry no information beyond their points, and has no classifier for the others. Function spaces were treated in Theorem 1.9; under Theorem 1.2 the functional diffeology is the exponential of sheaves, which is concrete by Theorem 1.6. The same is true in every slice.

Theorem 1.5 (Local Cartesian closure, [3). ]For every smooth map f ⁣:B′→Bf\colon B'\to B the pullback functor f∗ ⁣:Diff/B→Diff/B′f^*\colon\mathsf{Diff}/B\to\mathsf{Diff}/B' has a right adjoint Πf\Pi_f, as well as its left adjoint Σf\Sigma_f given by composition. Consequently f∗f^* preserves all colimits: colimits in Diff\mathsf{Diff} are universal.

An explicit Πf\Pi_f is constructed in [exo:lcc]. “Colimits are universal” is the abstract form of Proposition 1.7(i), and it is what makes it legitimate to compute with quotients fibrewise: if X→BX\to B is a quotient map, so is its restriction over any plot of BB.

Comparison with topological spaces

For a topological space TT let C(T)C(T) be the set TT with the continuous diffeology, whose plots are the continuous parametrisations.

Proposition 1.6 ([11). ]D ⁣:Diff→TopD\colon\mathsf{Diff}\to\mathsf{Top} is left adjoint to C ⁣:Top→DiffC\colon\mathsf{Top}\to\mathsf{Diff}. The adjunction restricts to an equivalence between the diffeological spaces with X≅CD(X)X\cong CD(X) and the Δ\Delta-generated topological spaces.

The adjunction is [exo:Dadj]. Being a left adjoint, DD preserves colimits; it does not preserve finite products in general [11]. The adjunction is far from an equivalence in both directions: CD(Tα)CD(T_{\alpha}) is coarse, and DC(T)DC(T) is TT with the Δ\Delta-generated refinement of its topology. For the purposes of this monograph the D-topology is a convenience for stating local conditions, and is never the carrier of homotopical information.

What Diff\mathsf{Diff} lacks

A quasitopos is a topos except for one exactness property. In Diff\mathsf{Diff} it fails as follows.

Proposition 1.7 (Equivalence relations are not effective). Let R↪X×XR\hookrightarrow X\times X be an equivalence relation in Diff\mathsf{Diff}, that is, an injective smooth map whose image is an equivalence relation on the set XX. The kernel pair of the quotient X→X/RX\to X/R is the set RR with the subspace diffeology of X×XX\times X. Hence RR is the kernel pair of its quotient if and only if R↪X×XR\hookrightarrow X\times X is an induction.

Proof. The kernel pair is the pullback X×X/RXX\times_{X/R}X, which by Theorem 1.6 is the set of pairs with the same image, with the subspace diffeology of X×XX\times X. ◻

Example 1.8. The orbit relation of Rδ\mathbb{R}^{\delta} acting on R\mathbb{R} is R×Rδ→R×R\mathbb{R}\times\mathbb{R}^{\delta}\to\mathbb{R}\times\mathbb{R}, (x,c)↦(x,x+c)(x,c)\mapsto(x,x+c). It is injective but not an induction: its image is all of R×R\mathbb{R}\times\mathbb{R}, whose subspace diffeology is the standard one. In Diff\mathsf{Diff} the quotient is a point and the relation is forgotten. In SmoothSet\mathsf{SmoothSet} the quotient is Ωcl1\Omega^1_{\mathrm{cl}} (Example 1.10) and the relation is recovered as its kernel pair.

This is the first rung of a ladder (1.2). Passing from Diff\mathsf{Diff} to SmoothSet\mathsf{SmoothSet} makes equivalence relations effective, at the price of including objects that are not determined by their points. But a group action is an equivalence relation only when it is free, and the next defect appears immediately: for a non-free action, the action groupoid is not the kernel pair of anything in SmoothSet\mathsf{SmoothSet}. Passing to the ∞\infty-topos H\mathbf{H} of Cohesion makes all groupoid objects effective, at the price of including objects that are not sets. Theorem 1.8 will make this ladder into a theorem.

The exactness ladder. Each inclusion makes effective a class of quotients that is not effective in the previous category, and each has a left adjoint (conc⁡\operatorname{conc}, respectively π0\pi_0) that computes the cruder quotient from the finer one.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Show directly that id ⁣:Rdisc→R\mathrm{id}\colon\mathbb{R}_{\mathrm{disc}}\to\mathbb{R} is a monomorphism and an epimorphism of Diff\mathsf{Diff} but neither an induction nor a subduction.

Solution.  It is bijective, hence monic and epic by 1.1. It is not an induction: the identity parametrisation of R\mathbb{R} composed with it is a plot of R\mathbb{R}, but is not locally constant. It is not a subduction: the same plot of R\mathbb{R} has no local lift to a locally constant parametrisation. Equivalently, the inverse map is not smooth. ◀\blacktriangleleft

2 Let j ⁣:(0,2π)→R2j\colon(0,2\pi)\to\mathbb{R}^2, j(t)=(sin⁡t,sin⁡2t)j(t)=(\sin t,\sin 2t), with image the figure eight EE. Show that jj is an injective immersion that is not an induction.

Solution.  j′(t)=(cos⁡t,2cos⁡2t)j'(t)=(\cos t,2\cos 2t) never vanishes, and jj is injective on (0,2π)(0,2\pi): the only parameter with j(t)=0j(t)=0 is t=πt=\pi, and elsewhere (sin⁡t,sin⁡2t)(\sin t,\sin 2t) determines (sin⁡t,cos⁡t)(\sin t,\cos t). Now let c(s)=(sin⁡s,sin⁡2s)c(s)=(\sin s,\sin 2s) for ∣s∣<1\lvert s\rvert<1. It is a smooth curve in R2\mathbb{R}^2 with values in EE, hence a plot of EsubE_{\mathrm{sub}}. But j−1∘cj^{-1}\circ c equals ss for s>0s>0, equals π\pi at s=0s=0, and equals s+2πs+2\pi for s<0s<0. It is not continuous, so it is not a plot of (0,2π)(0,2\pi), and jj is not an induction. Here coim⁡j\operatorname{coim}j is an open interval and im⁡j\operatorname{im}j is the figure eight with both branches through the node available to plots. ◀\blacktriangleleft

3 Prove that a monomorphism of Diff\mathsf{Diff} is strong if and only if it is an induction.

Solution.  (⇐\Leftarrow) Let m ⁣:X↪Ym\colon X\hookrightarrow Y be an induction, e ⁣:A→Be\colon A\to B surjective and smooth, and u ⁣:A→Xu\colon A\to X, v ⁣:B→Yv\colon B\to Y smooth with mu=vem u=v e. For b∈Bb\in B choose aa with e(a)=be(a)=b and put d(b)=u(a)d(b)=u(a); this is independent of aa because mm is injective and m(u(a))=v(b)m(u(a))=v(b). Then de=ud e=u and md=vm d=v. Since m∘d=vm\circ d=v is smooth and mm is an induction, dd is smooth. Uniqueness holds since ee is epic.

(⇒\Rightarrow) Let m ⁣:X→Ym\colon X\to Y be a strong monomorphism and factor it as X→m′m(X)sub→iYX\xrightarrow{m'}m(X)_{\mathrm{sub}}\xrightarrow{i}Y. The map m′m' is a smooth bijection, hence an epimorphism. Apply orthogonality to the square m∘idX=i∘m′m\circ\mathrm{id}_X=i\circ m': there is a smooth d ⁣:m(X)sub→Xd\colon m(X)_{\mathrm{sub}}\to X with d∘m′=idXd\circ m'=\mathrm{id}_X. So m′m' is a diffeomorphism and mm is an induction.

The dual statement, that strong epimorphisms are the subductions, is proved in the same way using the factorisation through X/∼fX/{\sim_f}. ◀\blacktriangleleft

3 Prove that D⊣CD\dashv C: for a diffeological space XX and a topological space TT, a map f ⁣:X→Tf\colon X\to T is continuous for the D-topology if and only if it is smooth as a map X→C(T)X\to C(T).

Solution.  f ⁣:X→C(T)f\colon X\to C(T) is smooth iff f∘Pf\circ P is a continuous parametrisation of TT for every plot PP of XX. On the other hand the D-topology is the final topology for the family of all plots, so f ⁣:D(X)→Tf\colon D(X)\to T is continuous iff f∘Pf\circ P is continuous for every plot PP. These are the same condition. Naturality in both variables is clear, so Top(DX,T)≅Diff(X,CT)\mathsf{Top}(D X,T)\cong\mathsf{Diff}(X,C T). ◀\blacktriangleleft

3 Show that the category of finite-dimensional manifolds is not Cartesian closed: there is no manifold EE with natural bijections Mfd(M×R,R)≅Mfd(M,E)\mathsf{Mfd}(M\times\mathbb{R},\mathbb{R})\cong\mathsf{Mfd}(M,E).

Solution.  Suppose EE exists, of dimension dd. Taking M=∗M=\ast identifies the points of EE with C∞(R)C^{\infty}(\mathbb{R}), and by naturality in MM a smooth map M→EM\to E has as underlying function m↦g(m,−)m\mapsto g(m,-) for the corresponding g∈C∞(M×R)g\in C^{\infty}(M\times\mathbb{R}). Take M=RkM=\mathbb{R}^{k} with k>dk>d and g(a,t)=∑i<kaitig(a,t)=\sum_{i<k}a_it^i. The corresponding smooth map ψ ⁣:Rk→E\psi\colon\mathbb{R}^k\to E is injective, because distinct coefficient vectors give distinct polynomial functions. But a smooth map from Rk\mathbb{R}^k to a manifold of dimension d<kd<k is never injective: on the open set where its rank is maximal, the constant rank theorem makes it locally a projection with fibres of positive dimension. In Diff\mathsf{Diff} the same universal property is satisfied by C∞(R,R)C^{\infty}(\mathbb{R},\mathbb{R}) with the functional diffeology. ◀\blacktriangleleft

4 Construct the right adjoint Πf\Pi_f of 1.5.

Solution.  Let f ⁣:B′→Bf\colon B'\to B be smooth and p ⁣:E→B′p\colon E\to B' an object of Diff/B′\mathsf{Diff}/B'. For b∈Bb\in B let Fb=f−1(b)F_b=f^{-1}(b) with the subspace diffeology, and let ΠfE={ (b,s):b∈B, s ⁣:Fb→E smooth, p∘s=idFb }→ π B.\Pi_fE=\{\,(b,s) : b\in B,\ s\colon F_b\to E\ \text{smooth},\ p\circ s=\mathrm{id}_{F_b}\,\}\xrightarrow{\ \pi\ }B . For a parametrisation r↦(br,sr)r\mapsto(b_r,s_r) of ΠfE\Pi_fE with domain UU and r↦brr\mapsto b_r a plot of BB, write U×BB′={ (r,b′):f(b′)=br }U\times_BB'=\{\,(r,b') : f(b')=b_r\,\}, a subspace of U×B′U\times B'. Declare the parametrisation a plot if r↦brr\mapsto b_r is a plot of BB and U×BB′⟶E,(r,b′)⟼sr(b′)U\times_BB'\longrightarrow E,\qquad(r,b')\longmapsto s_r(b') is smooth.

This is a diffeology. [D1]: for a constant parametrisation, U×BB′=U×FbU\times_BB'=U\times F_b and the map is s∘pr2s\circ\mathrm{pr}_2. [D3]: a smooth ϕ ⁣:V→U\phi\colon V\to U induces a smooth map V×BB′→U×BB′V\times_BB'\to U\times_BB'. [D2]: a plot of U×BB′U\times_BB' is a pair (ρ,Q)(\rho,Q), and locally ρ\rho takes values in one member of a given cover of UU; smoothness is tested on plots, hence locally in UU.

The adjunction. Let q ⁣:Z→Bq\colon Z\to B be an object of Diff/B\mathsf{Diff}/B; then f∗Z=Z×BB′f^*Z=Z\times_BB'. Given g ⁣:Z→ΠfEg\colon Z\to\Pi_fE over BB, define g^(z,b′)=g(z)(b′)\hat g(z,b')=g(z)(b'). For a plot (ζ,Q)(\zeta,Q) of Z×BB′Z\times_BB', the composite g∘ζg\circ\zeta is a plot of ΠfE\Pi_fE, so (r,b′)↦g(ζ(r))(b′)(r,b')\mapsto g(\zeta(r))(b') is smooth on U×BB′U\times_BB'; precomposing with the plot r↦(r,Q(r))r\mapsto(r,Q(r)) of U×BB′U\times_BB' shows that g^∘(ζ,Q)\hat g\circ(\zeta,Q) is a plot of EE. So g^\hat g is smooth, and it lies over B′B'. Conversely, given h ⁣:Z×BB′→Eh\colon Z\times_BB'\to E over B′B', put hˇ(z)=(q(z),h(z,−))\check h(z)=(q(z),h(z,-)). Each h(z,−)h(z,-) is a smooth section over Fq(z)F_{q(z)}, and for a plot ζ\zeta of ZZ the map (r,b′)↦h(ζ(r),b′)(r,b')\mapsto h(\zeta(r),b') is the composite of hh with the smooth map ζ×id\zeta\times\mathrm{id} restricted to U×BB′U\times_BB', so hˇ∘ζ\check h\circ\zeta is a plot. The two assignments are inverse to each other and natural in ZZ, so Hom⁡/B(Z,ΠfE)≅Hom⁡/B′(f∗Z,E)\operatorname{Hom}_{/B}(Z,\Pi_fE)\cong\operatorname{Hom}_{/B'}(f^*Z,E).

For B=∗B=\ast this is Theorem 1.9: Πf(B′×Y→B′)=C∞(B′,Y)\Pi_f(B'\times Y\to B')=C^{\infty}(B',Y). ◀\blacktriangleleft

The higher structure

Cohesion

The topos of smooth sets carries four adjoint functors to sets — pieces, discrete, points, codiscrete — and the same is true one level up, for the ∞\infty-topos H\mathbf{H} of smooth ∞\infty-groupoids and the ∞\infty-category of spaces. We set up this structure, locate Diff\mathsf{Diff} inside H\mathbf{H} as the concrete 00-types, and state the theorem that computes the leftmost adjoint, the shape, by smooth singular simplices.

Source in the book. [IZ, art. 5.6–5.9] (components) is the only direct contact. The framework is Lawvere’s axiomatic cohesion [40] and Schreiber’s cohesive ∞\infty-topos of smooth ∞\infty-groupoids [49].

Pieces, discrete, points, codiscrete

We already have Γ⊣coDisc⁡\Gamma\dashv\operatorname{coDisc} from Points, codiscrete objects, and separatedness. There are two more adjoints on the left.

Proposition 1.1 (Cohesion of smooth sets). There is a chain of adjunctions DiagramΠ0⊣Disc⁡⊣Γ⊣coDisc⁡\qquad\Pi_0\dashv\operatorname{Disc}\dashv\Gamma\dashv\operatorname{coDisc} in which:

  1. Disc⁡(S)\operatorname{Disc}(S) is the constant presheaf, i.e. the set SS with the discrete diffeology;

  2. Π0(F)=colim⁡U∈CartopF(U)\Pi_0(F)=\operatorname*{colim}_{U\in\mathsf{Cart}^{\mathrm{op}}}F(U), and for a diffeological space XX this is the set π0(X)\pi_0(X) of smooth path components [IZ, art. 5.6];

  3. Disc⁡\operatorname{Disc} and coDisc⁡\operatorname{coDisc} are full and faithful;

  4. Π0\Pi_0 preserves finite products;

  5. the canonical map ΓF→Π0F\Gamma F\to\Pi_0F is surjective, and Disc⁡S→coDisc⁡S\operatorname{Disc}S\to\operatorname{coDisc}S is a monomorphism.

Proof. (i) Let {Ui↪U}\{U_i\hookrightarrow U\} be a cover of a Cartesian space and si∈Ss_i\in S a family with si=sjs_i=s_j whenever some WW maps to both UiU_i and UjU_j, that is, whenever Ui∩Uj≠∅U_i\cap U_j\ne\varnothing. Since UU is connected, any two members of the cover are joined by a chain of members with non-empty consecutive intersections, so all sis_i are equal: the constant presheaf is a sheaf. Its plots are the constant maps on each Cartesian space, hence the locally constant parametrisations. (ii) Hom⁡(F,Disc⁡S)\operatorname{Hom}(F,\operatorname{Disc}S) is the set of natural transformations from FF to a constant functor, that is Set(colim⁡F,S)\mathsf{Set}(\operatorname*{colim}F,S). For F=X‾F=\underline X the colimit is the set of plots modulo the relation generated by P∼P∘ϕP\sim P\circ\phi; every plot is equivalent to each of its values, and two points are equivalent iff they are joined by a finite chain of plots with connected domains, iff they are joined by a smooth path. (iii) ΓDisc⁡S=S\Gamma\operatorname{Disc}S=S and ΓcoDisc⁡S=S\Gamma\operatorname{coDisc}S=S. (iv) Cart\mathsf{Cart} has finite products, so Cartop\mathsf{Cart}^{\mathrm{op}} is sifted, and sifted colimits commute with finite products in Set\mathsf{Set}. (v) An element of the colimit is represented by some s∈F(U)s\in F(U), which is equivalent to its restriction to any point of UU; and S→Set(∣U∣,S)S\to\mathsf{Set}(|U|,S) is injective because UU is non-empty. ◻

Lawvere calls a topos with such a quadruple, satisfying (iii)–(v), cohesive [40]. The names are meant literally: ΓX\Gamma X is the set of points of XX, Π0X\Pi_0X is the set of pieces into which the points cohere, and Disc⁡\operatorname{Disc} and coDisc⁡\operatorname{coDisc} are the two extreme cohesions on a set. Composing adjacent functors gives three idempotent operations on SmoothSet\mathsf{SmoothSet}, ∫0=Disc⁡Π0,♭=Disc⁡ Γ,♯=coDisc⁡ Γ,∫0⊣♭⊣♯,\mathord{\textstyle\smallint}_0=\operatorname{Disc}\Pi_0,\qquad\flat=\operatorname{Disc}\,\Gamma,\qquad\sharp=\operatorname{coDisc}\,\Gamma,\qquad\mathord{\textstyle\smallint}_0\dashv\flat\dashv\sharp, and Lemma 1.5 becomes: a smooth set XX is a diffeological space iff X→♯XX\to\sharp X is monic.

Smooth ∞\infty-groupoids

Definition 1.2. H=Sh∞(Cart)\mathbf{H}=\mathsf{Sh}_\infty(\mathsf{Cart}) is the ∞\infty-topos of sheaves of spaces on the site Cart\mathsf{Cart}: functors X ⁣:Cartop→SX\colon\mathsf{Cart}^{\mathrm{op}}\to\mathsf{S} to the ∞\infty-category of spaces such that for every covering family {Ui↪U}\{U_i\hookrightarrow U\} the map X(U)→lim⁡[k]∈Δ∏X(Ui0∩⋯∩Uik)X(U)\to\lim_{[k]\in\Delta}\prod X(U_{i_0}\cap\dots\cap U_{i_k}) (with intersections computed in sheaves) is an equivalence. Its objects are smooth ∞\infty-groupoids.

Concretely H\mathbf{H} is presented by simplicial presheaves on Cart\mathsf{Cart} with the local projective model structure; on this site Čech descent and hyperdescent coincide [49]. The 00-truncated objects of H\mathbf{H} are the smooth sets, and the 11-truncated objects are the stacks of groupoids on Cart\mathsf{Cart} [42, §6.4.5]. The truncation functors τ≤n\tau_{\le n} are left adjoint to the inclusions; we write π0=τ≤0\pi_0=\tau_{\le0}.

Theorem 1.3 (Schreiber [49). ]There is a chain of adjoint ∞\infty-functors Π⊣Disc⁡⊣Γ⊣coDisc⁡ ⁣: H⇄S\Pi\dashv\operatorname{Disc}\dashv\Gamma\dashv\operatorname{coDisc}\colon\ \mathbf{H}\rightleftarrows\mathsf{S} with Disc⁡\operatorname{Disc} and coDisc⁡\operatorname{coDisc} full and faithful and Π\Pi preserving finite products. Here Disc⁡K\operatorname{Disc}K is the constant presheaf, ΓX=X(∗)\Gamma X=X(\ast), coDisc⁡K=(U↦K∣U∣)\operatorname{coDisc}K=(U\mapsto K^{|U|}), and ΠX=colim⁡CartopX\Pi X=\operatorname*{colim}_{\mathsf{Cart}^{\mathrm{op}}}X.

Sketch. The key input is that constant presheaves are ∞\infty-sheaves on Cart\mathsf{Cart} ([exo:constant-sheaf]); this uses that Cartesian spaces are contractible and would fail on Dom\mathsf{Dom}. Given that, Map⁡H(X,Disc⁡K)\operatorname{Map}_{\mathbf{H}}(X,\operatorname{Disc}K) is the space of maps of presheaves into a constant presheaf, which is Map⁡(colim⁡X,K)\operatorname{Map}(\operatorname*{colim}X,K). Cartop\mathsf{Cart}^{\mathrm{op}} is sifted, so Π\Pi preserves finite products [42, 5.5.8]. Evaluation at the point preserves limits and colimits of sheaves because the point has only the trivial cover; its right adjoint is as stated because Map⁡(X,K∣−∣)\operatorname{Map}(X,K^{|-|}) is computed pointwise in ∣U∣|U|. Full faithfulness: ΓDisc⁡K=K=ΓcoDisc⁡K\Gamma\operatorname{Disc}K=K=\Gamma\operatorname{coDisc}K. ◻

Definition 1.4. The three modalities of H\mathbf{H} are the idempotent (co)monads ∫=Disc⁡ Π  (shape),♭=Disc⁡ Γ  (flat),♯=coDisc⁡ Γ  (sharp),∫⊣♭⊣♯.\mathord{\textstyle\smallint}=\operatorname{Disc}\,\Pi\ \ (\text{shape}),\qquad\flat=\operatorname{Disc}\,\Gamma\ \ (\text{flat}),\qquad\sharp=\operatorname{coDisc}\,\Gamma\ \ (\text{sharp}),\qquad\mathord{\textstyle\smallint}\dashv\flat\dashv\sharp. For X∈HX\in\mathbf{H} the space ΠX\Pi X, or the discrete object ∫X\mathord{\textstyle\smallint}X, is called the shape or fundamental ∞\infty-groupoid of XX.

The position of diffeological spaces. Each hooked arrow is a full embedding; each arrow on the left is its left adjoint. The composite reflection H→Diff\mathbf{H}\to\mathsf{Diff} is X↦conc⁡ π0XX\mapsto\operatorname{conc}\,\pi_0X.

Theorem 1.5 (Diff\mathsf{Diff} inside H\mathbf{H}). The composite Diff↪SmoothSet↪H\mathsf{Diff}\hookrightarrow\mathsf{SmoothSet}\hookrightarrow\mathbf{H} is full and faithful, preserves limits, and has the left adjoint conc⁡∘π0\operatorname{conc}\circ\pi_0. Its essential image consists of the 00-truncated objects XX for which the unit X→♯XX\to\sharp X is a monomorphism.

Proof. The 00-truncated objects of Sh∞(Cart)\mathsf{Sh}_\infty(\mathsf{Cart}) are the sheaves of sets, and the inclusion is right adjoint to π0\pi_0. On 00-truncated objects ♯\sharp restricts to coDisc⁡ Γ\operatorname{coDisc}\,\Gamma of Points, codiscrete objects, and separatedness, and a map of 00-truncated objects is a monomorphism in H\mathbf{H} iff it is one in SmoothSet\mathsf{SmoothSet}. Now apply Lemma 1.5 and Proposition 1.7. ◻

Reading the modalities

For X∈HX\in\mathbf{H} there are canonical maps ♭X⟶X⟶♯X,X⟶∫X.\flat X\longrightarrow X\longrightarrow\sharp X,\qquad X\longrightarrow\mathord{\textstyle\smallint}X . Here ♭X\flat X consists of the points of XX with the discrete cohesion, ♯X\sharp X of the points with the codiscrete cohesion, and ∫X\mathord{\textstyle\smallint}X is the homotopy type of XX as a discrete object. Their values on the running examples are in 1.1.

The functors of cohesion on examples. Rows 3 and 6 are justified in Shape; note that the one-point sheaf Ωcl1\Omega^1_{\mathrm{cl}} has a non-trivial shape, while Ωk\Omega^k is contractible by the homotopy (ω,t)↦tω(\omega,t)\mapsto t\omega.
XX ΓX\Gamma X ♭X\flat X ♯X\sharp X ΠX\Pi X
Rn\mathbb{R}^n the set Rn\mathbb{R}^n Rn\mathbb{R}^n discrete Rn\mathbb{R}^n coarse ∗\ast
manifold MM the set MM MM discrete MM coarse homotopy type of MM
TαT_{\alpha} R/Λα\mathbb{R}/\Lambda_\alpha discrete coarse BZ2≃T2\mathbf{B}\mathbb{Z}^2\simeq T^2
Δ1=R/{±1}\Delta_1=\mathbb{R}/\{\pm1\} [0,∞)[0,\infty) discrete coarse ∗\ast
Ωk\Omega^k, k≥1k\ge1 ∗\ast ∗\ast ∗\ast ∗\ast
Ωcl1=R/Rδ\Omega^1_{\mathrm{cl}}=\mathbb{R}/\mathbb{R}^{\delta} ∗\ast ∗\ast ∗\ast BRδ=K(R,1)\mathbf{B}\mathbb{R}^{\delta}=K(\mathbb{R},1)
BG\mathbf{B}G, GG a Lie group B(Gδ)\mathbf{B}(G^\delta) B(Gδ)\mathbf{B}(G^\delta) B(♯G)\mathbf{B}(\sharp G) classifying space BGBG

Two entries are used repeatedly. First, a manifold has the shape of its underlying homotopy type: this is the nerve theorem for a good open cover, and is the reason for the name “shape”. Second, ♭BG=Disc⁡ B(Gδ)\flat\mathbf{B}G=\operatorname{Disc}\,\mathbf{B}(G^\delta): maps X→♭BGX\to\flat\mathbf{B}G are principal bundles for the discrete group, that is, flat GG-bundles, whence the name of the modality. By adjunction Map⁡H(X,♭A)  ≃  Map⁡S(ΠX,ΓA), \operatorname{Map}_{\mathbf{H}}(X,\flat A)\;\simeq\;\operatorname{Map}_{\mathsf{S}}(\Pi X,\Gamma A), so cohomology with flat (locally constant) coefficients is ordinary cohomology of the shape. This formula does a great deal of work in Chapters Forms and Number theory: the arithmetic of irrational tori.

Computing the shape

For k≥0k\ge0 let Δek={ x∈Rk+1:∑xi=1 }\Delta^k_e=\{\,x\in\mathbb{R}^{k+1} : \sum x_i=1\,\} be the extended simplex, an affine hyperplane diffeomorphic to Rk\mathbb{R}^k. The Δek\Delta^k_e form a cosimplicial object of Cart\mathsf{Cart}.

The extended simplex.

Theorem 1.6 (Berwick-Evans–Boavida de Brito–Pavlov [5). ; Bunk [8]; Pavlov [47]]For every X∈HX\in\mathbf{H}:

  1. ΠX≃∣[k]↦X(Δek)∣\Pi X\simeq\bigl|[k]\mapsto X(\Delta^k_e)\bigr|, the geometric realisation of the simplicial space of smooth singular simplices;

  2. for every manifold MM,  Π [M,X]≃Map⁡S(ΠM,ΠX)\ \Pi\,[M,X]\simeq\operatorname{Map}_{\mathsf{S}}(\Pi M,\Pi X), where [M,X][M,X] is the internal hom of H\mathbf{H}.

For a diffeological space XX, by part (i) ΠX\Pi X is the smooth singular simplicial set SD(X)k=Diff(Δek,X)S^D(X)_k=\mathsf{Diff}(\Delta^k_e,X) of Christensen and Wu [12], regarded as a space. Part (ii) is the smooth Oka principle: the shape of a mapping space out of a manifold is the mapping space of shapes. It is a genuinely geometric theorem, since Π\Pi is a colimit and [M,−][M,-] is a limit.

Remark 1.7 (Shape versus the D-topology). There are two ways to extract a homotopy type from a diffeological space: the shape ΠX\Pi X, and the weak homotopy type of the topological space D(X)D(X). They coincide for manifolds and differ in general. For TαT_{\alpha} the second is a point and the first is a torus. The first is the right one, in the precise sense that it is computed by a left adjoint that preserves finite products and takes quotients by principal actions to homotopy quotients (Theorem 1.4); the D-topology has none of these properties.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Compute Γ\Gamma, Π0\Pi_0, ♭\flat and ♯\sharp for X=R∖{0}X=\mathbb{R}\smallsetminus\{0\} and describe the maps ♭X→X→♯X\flat X\to X\to\sharp X.

Solution.  ΓX\Gamma X is the underlying set. Π0X={−,+}\Pi_0X=\{-,+\}, the two path components. ♭X\flat X is the set R∖{0}\mathbb{R}\smallsetminus\{0\} with the discrete diffeology and ♭X→X\flat X\to X is the identity on points; it is smooth because locally constant parametrisations are plots, and it is not a diffeomorphism. ♯X\sharp X is the same set with the coarse diffeology and X→♯XX\to\sharp X is again the identity on points. Both maps are bijective, hence monic and epic, and neither is strong (Proposition 1.1). ◀\blacktriangleleft

2 Show that Π0(Ωk)=∗\Pi_0(\Omega^k)=\ast for every kk, and that Π0(X×Y)=Π0(X)×Π0(Y)\Pi_0(X\times Y)=\Pi_0(X)\times\Pi_0(Y) for diffeological spaces, directly from the description by smooth paths.

Solution.  An element of Π0(Ωk)=colim⁡UΩk(U)\Pi_0(\Omega^k)=\operatorname*{colim}_U\Omega^k(U) is represented by a form ω∈Ωk(U)\omega\in\Omega^k(U). On U×RU\times\mathbb{R} consider ω~=t⋅prU∗ω\tilde\omega=t\cdot\mathrm{pr}_U^*\omega, with tt the coordinate on R\mathbb{R}. Its restrictions along u↦(u,1)u\mapsto(u,1) and u↦(u,0)u\mapsto(u,0) are ω\omega and 00, so ω∼ω~∼0\omega\sim\tilde\omega\sim0 in the colimit, and 0∈Ωk(U)0\in\Omega^k(U) is the restriction of 0∈Ωk(∗)0\in\Omega^k(\ast). Hence there is one element. For products: a smooth path in X×YX\times Y is a pair of smooth paths, so two points (x,y)(x,y), (x′,y′)(x',y') are joined by a path iff x,x′x,x' are and y,y′y,y' are; one direction uses the constant path in one factor together with concatenation of stationary paths (Paths, loops and homotopy groups). ◀\blacktriangleleft

2 Show that Π0(Tα)=∗\Pi_0(T_{\alpha})=\ast and that Tα→∫0TαT_{\alpha}\to\mathord{\textstyle\smallint}_0T_{\alpha}, ♭Tα→Tα\flat T_{\alpha}\to T_{\alpha} and Tα→♯TαT_{\alpha}\to\sharp T_{\alpha} are all non-invertible.

Solution.  qα ⁣:R→Tαq_\alpha\colon\mathbb{R}\to T_{\alpha} is surjective and R\mathbb{R} is path connected, so TαT_{\alpha} is; hence ∫0Tα=∗\mathord{\textstyle\smallint}_0T_{\alpha}=\ast and the first map collapses TαT_{\alpha} to a point. ♭Tα\flat T_{\alpha} is the uncountable discrete set R/Λα\mathbb{R}/\Lambda_\alpha and ♯Tα\sharp T_{\alpha} is the same set with the coarse diffeology; by Proposition 1.10(ii) the diffeology of TαT_{\alpha} is neither, so the two identity-on-points maps are not diffeomorphisms. ◀\blacktriangleleft

3 Let FF be a smooth set with ΓF=∗\Gamma F=\ast. Show that Π0F=∗\Pi_0F=\ast. Deduce that a non-empty smooth set with one point is connected, and give an example of one that is not contractible in the sense that its shape is not a point.

Solution.  By 1.1(v) the map ΓF→Π0F\Gamma F\to\Pi_0F is surjective, so Π0F\Pi_0F has at most one element; it is non-empty because ΓF\Gamma F is. So one-point smooth sets are connected: “pieces have points”. For the example take F=Ωcl1F=\Omega^1_{\mathrm{cl}}. By Example 1.10 it is the quotient of R‾\underline{\mathbb{R}} by the free action of the discrete group Rδ\mathbb{R}^{\delta}; such a quotient is the homotopy quotient (Theorem 1.2), Π\Pi preserves homotopy quotients and finite products, and ΠR‾=∗\Pi\underline{\mathbb{R}}=\ast, so Π Ωcl1≃∗/ ⁣ ⁣/Rδ=BRδ\Pi\,\Omega^1_{\mathrm{cl}}\simeq\ast/\!\!/\mathbb{R}^{\delta}=\mathbf{B}\mathbb{R}^{\delta}, an Eilenberg–MacLane space K(R,1)K(\mathbb{R},1) for the discrete group R\mathbb{R}. Its fundamental group is uncountable. (Concretely: a path in Ωcl1\Omega^1_{\mathrm{cl}} is a 11-form a(t) dta(t)\,\mathrm{d}t on the line; it is automatically a loop, since Ωcl1\Omega^1_{\mathrm{cl}} has one point, and its class is ∫01a\int_0^1a.) ◀\blacktriangleleft

4 Let KK be a space. Prove that the constant presheaf with value KK satisfies descent for every good open cover of a Cartesian space, and explain why this fails on Dom\mathsf{Dom}.

Solution.  Let U={Ui}i∈I\mathcal U=\{U_i\}_{i\in I} be a good cover of U≅RnU\cong\mathbb{R}^n: every non-empty finite intersection Ui0…ikU_{i_0\dots i_k} is diffeomorphic to Rn\mathbb{R}^n. Good covers are cofinal among open covers of UU (take geodesically convex balls for a Riemannian metric) and generate the topology of Cart\mathsf{Cart}, so it suffices to verify descent for them. The Čech nerve of U\mathcal U in presheaves has in degree kk the coproduct of the representables Ui0…ikU_{i_0\dots i_k} over those (i0,…,ik)(i_0,\dots,i_k) with non-empty intersection. For the constant presheaf K‾\underline K the descent map is therefore K=K‾(U)⟶lim⁡[k]∈Δ ∏(i0,…,ik)Ui0…ik≠∅K  =  Map⁡(N(U),K),K=\underline K(U)\longrightarrow\lim_{[k]\in\Delta}\ \prod_{\substack{(i_0,\dots,i_k)\\ U_{i_0\dots i_k}\neq\varnothing}}K\;=\;\operatorname{Map}\bigl(N(\mathcal U),K\bigr), where N(U)N(\mathcal U) is the nerve of the cover, the simplicial set whose kk-simplices are the (k+1)(k+1)-tuples with non-empty intersection, and the map is restriction along N(U)→∗N(\mathcal U)\to\ast. By the nerve theorem (Borsuk, Weil) the realisation of N(U)N(\mathcal U) is homotopy equivalent to UU, which is contractible. Hence N(U)→∗N(\mathcal U)\to\ast is a weak equivalence and the descent map is an equivalence.

On Dom\mathsf{Dom} the first step of the argument is invalid: the value of a sheaf on a disconnected or non-simply-connected domain is forced by descent, and for U=R2∖{0}U=\mathbb{R}^2\smallsetminus\{0\} the sheafification of the constant presheaf has value Map⁡(S1,K)\operatorname{Map}(S^1,K), the free loop space, not KK. The constant presheaf is a sheaf exactly on a site whose objects are contractible; this is the technical reason for preferring Cart\mathsf{Cart}. ◀\blacktriangleleft

Shape

The smooth homotopy groups of the book are the homotopy groups of the shape. We explain the comparison, prove that the shape functor turns diffeological fibre bundles into fibre sequences — which gives the long exact sequence of [IZ, art. 8.21] for free — and compute the shapes of the running examples. The irrational torus is a K(Z2,1)K(\mathbb{Z}^2,1), the quotient R/Q\mathbb{R}/\mathbb{Q} is a rational circle, and none of this is determined by the D-topology.

Source in the book. [IZ, Chapter 5] (paths, components, homotopy groups) and [IZ, art. 8.19–8.26] (homotopy of fibre bundles, coverings).

Paths, loops and homotopy groups

Following [IZ, art. 5.1], the space of paths of a diffeological space XX is Paths⁡(X)=C∞(R,X)\operatorname{Paths}(X)=C^{\infty}(\mathbb{R},X) with the functional diffeology; a path γ\gamma starts at γ(0)\gamma(0) and ends at γ(1)\gamma(1). Defining paths on all of R\mathbb{R} keeps the source a domain. The price is that two paths with γ(1)=γ′(0)\gamma(1)=\gamma'(0) cannot be concatenated naively; the remedy is to reparametrise by a smashing function, a smooth non-decreasing λ ⁣:R→[0,1]\lambda\colon\mathbb{R}\to[0,1] equal to 00 near (−∞,0](-\infty,0] and to 11 near [1,∞)[1,\infty) (1.1). The path γ∘λ\gamma\circ\lambda is stationary near its ends, is homotopic to γ\gamma with fixed ends, and stationary paths concatenate smoothly [IZ, art. 5.2–5.5].

A smashing function, and the concatenation of two stationary paths.

Being joined by a path is then an equivalence relation, with quotient π0(X)\pi_0(X). For a base point xx let Loops⁡(X,x)={ ℓ∈Paths⁡(X):ℓ(0)=ℓ(1)=x }\operatorname{Loops}(X,x)=\{\,\ell\in\operatorname{Paths}(X) : \ell(0)=\ell(1)=x\,\} with the subspace diffeology and base point the constant loop x^\hat x. The higher homotopy groups are defined by recursion [IZ, art. 5.15–5.17]: πn(X,x)=πn−1(Loops⁡(X,x),x^)=π0(Loops⁡n(X,x)).\pi_n(X,x)=\pi_{n-1}\bigl(\operatorname{Loops}(X,x),\hat x\bigr)=\pi_0\bigl(\operatorname{Loops}^n(X,x)\bigr). Unwinding with Theorem 1.9, an element of πn(X,x)\pi_n(X,x) is represented by a smooth map σ ⁣:Rn→X\sigma\colon\mathbb{R}^n\to X with σ(t)=x\sigma(t)=x whenever some coordinate tit_i lies in {0,1}\{0,1\}, and two such are identified when they are joined by a smooth one-parameter family of the same kind. A smooth homotopy between f,g ⁣:X→Yf,g\colon X\to Y is a path in C∞(X,Y)C^{\infty}(X,Y), equivalently a smooth H ⁣:X×R→YH\colon X\times\mathbb{R}\to Y with H0=fH_0=f, H1=gH_1=g. A space is smoothly contractible if its identity is homotopic to a constant.

Homotopy groups of the shape

Proposition 1.1 (Π\Pi inverts smooth homotopy). If f,g ⁣:X→Yf,g\colon X\to Y are smoothly homotopic maps of smooth ∞\infty-groupoids, then Πf≃Πg\Pi f\simeq\Pi g. In particular smooth homotopy equivalences induce equivalences of shapes, and a smoothly contractible object has contractible shape.

Proof. Let H ⁣:X×R→YH\colon X\times\mathbb{R}\to Y be the homotopy and i0,i1 ⁣:X→X×Ri_0,i_1\colon X\to X\times\mathbb{R} the inclusions at 00 and 11. Since Π\Pi preserves finite products and Π(R)=∗\Pi(\mathbb{R})=\ast, the projection X×R→XX\times\mathbb{R}\to X induces an equivalence on shapes. Both i0i_0 and i1i_1 are sections of it, so Πi0≃Πi1\Pi i_0\simeq\Pi i_1, and Πf=ΠH∘Πi0≃ΠH∘Πi1=Πg\Pi f=\Pi H\circ\Pi i_0\simeq\Pi H\circ\Pi i_1=\Pi g. ◻

Theorem 1.2 (Christensen–Wu [12). ; Kihara [37]]For every diffeological space XX, every x∈Xx\in X and every n≥0n\ge0 there is a natural isomorphism πn(ΠX,x)  ≅  πn(X,x)\pi_n(\Pi X,x)\;\cong\;\pi_n(X,x) between the homotopy groups of the shape and the smooth homotopy groups of [IZ, art. 5.17].

By Theorem 1.6(i) the left-hand side is πn\pi_n of the smooth singular simplicial set SD(X)=Diff(Δe∙,X)S^D(X)=\mathsf{Diff}(\Delta^\bullet_e,X). For n=0n=0 the statement is Proposition 1.1(ii). Christensen and Wu proved it for those XX whose SD(X)S^D(X) is a Kan complex, a class that contains all diffeological groups and homogeneous spaces; Kihara removed the hypothesis. The content is that horn fillers, which need not exist smoothly, exist after reparametrising by smashing functions — the same device as in 1.1, one dimension at a time.

Remark 1.3 (Why not a model structure on Diff\mathsf{Diff}?). One would like to say that Diff\mathsf{Diff} “is a model for homotopy theory”. The obvious attempt, transferring the Kan–Quillen model structure along SDS^D, fails [47]; Kihara’s model structure [36] uses simplices with a non-standard diffeology. From the present point of view nothing is lost: the homotopy theory is that of H\mathbf{H}, the functor Π\Pi is defined on all of H\mathbf{H}, and Diff\mathsf{Diff} is the full subcategory on which Π\Pi is computable by smooth paths.

Fibre sequences

A diffeological fibre bundle is a smooth surjection π ⁣:T→B\pi\colon T\to B whose pullback along every plot of BB is locally trivial with a fixed fibre FF [IZ, art. 8.9]. This is weaker than local triviality over D-open sets, and it has to be: T2→TαT^2\to T_{\alpha} is a fibre bundle with fibre R\mathbb{R} over a base whose only D-open sets are ∅\varnothing and TαT_{\alpha}. Principal bundles are treated in Bundles and stacks; we use two facts from there. First, a principal GG-bundle P→BP\to B satisfies B≃P/ ⁣ ⁣/GB\simeq P/\!\!/G in H\mathbf{H} (Theorem 1.2). Second, every diffeological fibre bundle with fibre FF is associated to a principal Diff⁡(F)\operatorname{Diff}(F)-bundle [IZ, art. 8.14, 8.16].

Theorem 1.4 (Shape preserves bundle fibre sequences). Let F→T→πBF\to T\xrightarrow{\pi}B be a diffeological fibre bundle. Then ΠF⟶ΠT⟶ΠB\Pi F\longrightarrow\Pi T\longrightarrow\Pi B is a fibre sequence of spaces. Consequently there is a long exact sequence ⋯→πn(F)→πn(T)→πn(B)→πn−1(F)→⋯→π0(T)→π0(B)→∗,\cdots\to\pi_n(F)\to\pi_n(T)\to\pi_n(B)\to\pi_{n-1}(F)\to\cdots\to\pi_0(T)\to\pi_0(B)\to\ast , which by 1.2 is the exact homotopy sequence of [IZ, art. 8.21].

Proof. Principal case. Let P→BP\to B be principal with group GG. Then in H\mathbf{H} B≃P/ ⁣ ⁣/G=colim⁡[k]∈ΔopP×Gk,henceΠB≃colim⁡[k]∈ΔopΠP×(ΠG)k=ΠP/ ⁣ ⁣/ΠG,B\simeq P/\!\!/G=\operatorname*{colim}_{[k]\in\Delta^{\mathrm{op}}}P\times G^k,\qquad\text{hence}\qquad\Pi B\simeq\operatorname*{colim}_{[k]\in\Delta^{\mathrm{op}}}\Pi P\times(\Pi G)^k=\Pi P/\!\!/\Pi G, because Π\Pi preserves colimits, being a left adjoint, and finite products. The right-hand side is the homotopy quotient of the space ΠP\Pi P by the group-like space ΠG\Pi G. In S\mathsf{S}, as in any ∞\infty-topos, the map from an object to its homotopy quotient by a group is a principal bundle with fibre the group [46]; so ΠG→ΠP→ΠB\Pi G\to\Pi P\to\Pi B is a fibre sequence.

General case. Write T≅P×GF=(P×F)/GT\cong P\times_GF=(P\times F)/G with G=Diff⁡(F)G=\operatorname{Diff}(F) and P→BP\to B principal. The diagonal action on P×FP\times F is again principal: if r↦((pr,fr),(prgr,gr−1fr))r\mapsto((p_r,f_r),(p_rg_r,g_r^{-1}f_r)) is a plot of (P×F)2(P\times F)^2, then r↦grr\mapsto g_r is a plot of GG because it is already determined smoothly by (pr,prgr)(p_r,p_rg_r) and the action on PP is principal. Hence T≃(P×F)/ ⁣ ⁣/GT\simeq(P\times F)/\!\!/G and ΠT≃(ΠP×ΠF)/ ⁣ ⁣/ΠG\Pi T\simeq(\Pi P\times\Pi F)/\!\!/\Pi G. The map to ΠB≃ΠP/ ⁣ ⁣/ΠG\Pi B\simeq\Pi P/\!\!/\Pi G is induced by the projection, and its pullback along ΠP→ΠP/ ⁣ ⁣/ΠG\Pi P\to\Pi P/\!\!/\Pi G is ΠP×ΠF→ΠP\Pi P\times\Pi F\to\Pi P, since colimits are universal in S\mathsf{S}. So its fibre is ΠF\Pi F. ◻

The proof uses nothing about paths. In [1] the exact sequence is proved by constructing, for every fibre bundle, an associated bundle of loop spaces [IZ, art. 8.20]; here the sequence is a formal consequence of two properties of the left adjoint Π\Pi and one geometric input, the identification of quotients by principal actions with homotopy quotients.

Shapes of the running examples

Corollary 1.5 (Quotients of Rn\mathbb{R}^n by countable subgroups). Let Γ⊂Rn\Gamma\subset\mathbb{R}^n be a countable subgroup and TΓ=Rn/ΓT_\Gamma=\mathbb{R}^n/\Gamma. Then Rn→TΓ\mathbb{R}^n\to T_\Gamma is a principal Γ\Gamma-bundle with Γ\Gamma discrete, and Π TΓ≃BΓ=K(Γ,1).\Pi\,T_\Gamma\simeq\mathbf{B}\Gamma=K(\Gamma,1). In particular Π Tα≃BZ2≃T2\Pi\,T_{\alpha}\simeq\mathbf{B}\mathbb{Z}^2\simeq T^2, and Π(R/Q)≃K(Q,1)\Pi(\mathbb{R}/\mathbb{Q})\simeq K(\mathbb{Q},1).

Proof. A plot of Rn\mathbb{R}^n with values in the countable set Γ\Gamma is locally constant, so Γ\Gamma is discrete as a subspace. The action map Rn×Γ→Rn×Rn\mathbb{R}^n\times\Gamma\to\mathbb{R}^n\times\mathbb{R}^n, (x,γ)↦(x,x+γ)(x,\gamma)\mapsto(x,x+\gamma), is an induction: if r↦(xr,yr)r\mapsto(x_r,y_r) is a plot with yr−xr∈Γy_r-x_r\in\Gamma, then r↦yr−xrr\mapsto y_r-x_r is smooth with countable image, hence locally constant, hence a plot of Γ\Gamma. So the action is principal (Definition 1.1), and 1.4 gives ΠTΓ≃ΠRn/ ⁣ ⁣/Γ=∗/ ⁣ ⁣/Γ\Pi T_\Gamma\simeq\Pi\mathbb{R}^n/\!\!/\Gamma=\ast/\!\!/\Gamma. ◻

So the irrational torus has the homotopy type of the ordinary 22-torus, in accordance with its name and in contrast with its D-topology. Each of two fibre bundles over it gives the computation (1.2): the universal covering R→Tα\mathbb{R}\to T_{\alpha} with discrete fibre Z2\mathbb{Z}^2, and the Kronecker fibration T2→TαT^2\to T_{\alpha} with contractible fibre R\mathbb{R}. Iglesias-Zemmour recounts in the afterword of [1] that reconciling these two computations is what led to the definition of diffeological fibre bundles. The space R/Q\mathbb{R}/\mathbb{Q} is a one-dimensional diffeological group whose shape is the rationalisation of the circle.

Two diffeological fibre bundles over the irrational torus and the fibre sequences of shapes they induce. Each gives ΠTα≃BZ2\Pi T_{\alpha}\simeq\mathbf{B}\mathbb{Z}^2.
Some shapes. The difference between the third and fourth rows is the difference between a quotient and a homotopy quotient; the first two show that an indiscrete D-topology is compatible with any K(Γ,1)K(\Gamma,1) for countable torsion-free abelian Γ⊂Rn\Gamma\subset\mathbb{R}^n.
XX ΠX\Pi X reason D-topology
TαT_{\alpha} BZ2\mathbf{B}\mathbb{Z}^2 1.5 indiscrete
R/Q\mathbb{R}/\mathbb{Q} K(Q,1)K(\mathbb{Q},1) 1.5 indiscrete
Δn=Rn/O⁡(n)\Delta_n=\mathbb{R}^n/\operatorname{O}(n) ∗\ast radial contraction ([exo:contractible]) half-line
Rn/ ⁣ ⁣/O⁡(n)\mathbb{R}^n/\!\!/\operatorname{O}(n) (stack) BO⁡(n)B\operatorname{O}(n) Π\Pi preserves homotopy quotients —
the cross KK ∗\ast radial contraction cross
any non-empty coarse space ∗\ast [exo:contractible] indiscrete
Ωcl1\Omega^1_{\mathrm{cl}} K(R,1)K(\mathbb{R},1) [exo:pieces-points] —
S∞S^\infty [IZ, art. 4.9] ∗\ast contractible [IZ, art. 4.10]
CP∞=S∞/U(1)\mathbb{C}P^\infty=S^\infty/U(1) [IZ, art. 4.11] K(Z,2)K(\mathbb{Z},2) 1.4

Coverings

A covering is a diffeological fibre bundle with discrete fibre [IZ, art. 8.22]. For connected XX there is a universal covering X~→X\tilde X\to X, simply connected and unique up to isomorphism, which is a principal bundle with structure group π1(X)\pi_1(X) [IZ, art. 8.26]. In H\mathbf{H} this becomes X  ≃  X~/ ⁣ ⁣/π1(X),classified byX⟶Bπ1(X)=τ≤1∫X,X\;\simeq\;\tilde X/\!\!/\pi_1(X),\qquad\text{classified by}\qquad X\longrightarrow\mathbf{B}\pi_1(X)=\tau_{\le1}\mathord{\textstyle\smallint}X , and X~\tilde X is the homotopy fibre of the 11-truncation of the shape unit. The monodromy theorem [IZ, art. 8.25], that a smooth map from a simply connected space lifts through any covering, is the corresponding lifting property. For X=TαX=T_{\alpha} the universal covering is R\mathbb{R}, and for X=TΓX=T_\Gamma it is Rn\mathbb{R}^n.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Construct a smashing function, and show that if γ,γ′\gamma,\gamma' are paths with γ(1)=γ′(0)\gamma(1)=\gamma'(0), both stationary near their ends, then the concatenation γ∨γ′\gamma\vee\gamma', equal to γ(2t)\gamma(2t) for t≤12t\le\tfrac12 and to γ′(2t−1)\gamma'(2t-1) for t≥12t\ge\tfrac12, is a smooth path.

Solution.  Let φ(t)=e−1/t\varphi(t)=e^{-1/t} for t>0t>0 and 00 otherwise, and put ψ(t)=φ(t)/(φ(t)+φ(1−t))\psi(t)=\varphi(t)/(\varphi(t)+\varphi(1-t)). The denominator never vanishes, so ψ\psi is smooth, non-decreasing, 00 on (−∞,0](-\infty,0] and 11 on [1,∞)[1,\infty). Then λ(t)=ψ(3t−1)\lambda(t)=\psi(3t-1) is 00 on (−∞,13](-\infty,\tfrac13] and 11 on [23,∞)[\tfrac23,\infty). For the concatenation: there is ε>0\varepsilon>0 with γ\gamma constant on (1−ε,∞)(1-\varepsilon,\infty) and γ′\gamma' constant on (−∞,ε)(-\infty,\varepsilon). On t<12+ε2t<\tfrac12+\tfrac\varepsilon2 the map γ∨γ′\gamma\vee\gamma' coincides with t↦γ(2t)t\mapsto\gamma(2t), and on t>12−ε2t>\tfrac12-\tfrac\varepsilon2 with t↦γ′(2t−1)t\mapsto\gamma'(2t-1); both are plots, they coincide on the overlap where they are constant at γ(1)\gamma(1), and [D2] applies. By the same argument with parameters, concatenation is smooth as a map from the space of composable pairs of stationary paths to Paths⁡(X)\operatorname{Paths}(X). ◀\blacktriangleleft

2 Show that Δn=Rn/O⁡(n)\Delta_n=\mathbb{R}^n/\operatorname{O}(n) and every non-empty coarse space are smoothly contractible.

Solution.  Let λ\lambda be a smashing function and h ⁣:Rn×R→Rnh\colon\mathbb{R}^n\times\mathbb{R}\to\mathbb{R}^n, h(x,t)=(1−λ(t))xh(x,t)=(1-\lambda(t))x. It is smooth, h0=idh_0=\mathrm{id}, h1=0h_1=0, and each hth_t is O⁡(n)\operatorname{O}(n)-equivariant. So π∘h\pi\circ h is constant on the fibres of the subduction π×id ⁣:Rn×R→Δn×R\pi\times\mathrm{id}\colon\mathbb{R}^n\times\mathbb{R}\to\Delta_n\times\mathbb{R} (Proposition 1.7) and descends to a smooth hˉ ⁣:Δn×R→Δn\bar h\colon\Delta_n\times\mathbb{R}\to\Delta_n from the identity to a constant. For a coarse space XX with a point x0x_0, the map H(x,t)=xH(x,t)=x for t<12t<\tfrac12 and H(x,t)=x0H(x,t)=x_0 for t≥12t\ge\tfrac12 is smooth, since every map into a coarse space is. By 1.1 both have contractible shape. ◀\blacktriangleleft

2 Compute π1(Tα,0)\pi_1(T_{\alpha},0) directly from the definition, by lifting loops to R\mathbb{R}.

Solution.  Let ℓ\ell be a loop at 0=qα(0)0=q_\alpha(0). It is a plot, so it lifts locally through qαq_\alpha, and two local lifts differ by a locally constant element of Λα\Lambda_\alpha (Proposition 1.10). Covering R\mathbb{R} by intervals on which lifts exist and correcting successive lifts by constants, we get a unique smooth ℓ~ ⁣:R→R\tilde\ell\colon\mathbb{R}\to\mathbb{R} with qαℓ~=ℓq_\alpha\tilde\ell=\ell and ℓ~(0)=0\tilde\ell(0)=0. Put w(ℓ)=ℓ~(1)∈Λαw(\ell)=\tilde\ell(1)\in\Lambda_\alpha. A homotopy of loops is a plot h ⁣:R2→Tαh\colon\mathbb{R}^2\to T_{\alpha} with h(s,0)=h(s,1)=0h(s,0)=h(s,1)=0; by the same argument on the simply connected domain R2\mathbb{R}^2 it lifts to h~\tilde h with h~(s,0)=0\tilde h(s,0)=0, and s↦h~(s,1)s\mapsto\tilde h(s,1) is a continuous map into Λα\Lambda_\alpha, hence constant. So ww is well defined on π1\pi_1. It is a homomorphism because the lift of a concatenation is the lift of the first loop followed by the translate of the lift of the second. It is surjective: t↦qα(tμ)t\mapsto q_\alpha(t\mu) is a loop with w=μw=\mu. It is injective: if w(ℓ)=0w(\ell)=0 then ℓ~\tilde\ell is a loop in R\mathbb{R} at 00, and (s,t)↦qα(sℓ~(t))(s,t)\mapsto q_\alpha(s\tilde\ell(t)) contracts ℓ\ell. Hence π1(Tα,0)≅Λα≅Z2\pi_1(T_{\alpha},0)\cong\Lambda_\alpha\cong\mathbb{Z}^2. ◀\blacktriangleleft

3 Show that R/Q\mathbb{R}/\mathbb{Q} is a diffeological Q\mathbb{Q}-vector space with π1(R/Q)≅Q\pi_1(\mathbb{R}/\mathbb{Q})\cong\mathbb{Q} and all higher homotopy groups zero, and that every smooth map R/Q→R/Q\mathbb{R}/\mathbb{Q}\to\mathbb{R}/\mathbb{Q} fixing 00 is multiplication by a rational number.

Solution.  Q\mathbb{Q} is a countable subgroup, so by 1.5 R→R/Q\mathbb{R}\to\mathbb{R}/\mathbb{Q} is a principal Q\mathbb{Q}-bundle with Q\mathbb{Q} discrete and Π(R/Q)≃K(Q,1)\Pi(\mathbb{R}/\mathbb{Q})\simeq K(\mathbb{Q},1); now apply 1.2. Multiplication by a∈Qa\in\mathbb{Q} on R\mathbb{R} preserves Q\mathbb{Q}, so it descends to a smooth map on the quotient, and this makes R/Q\mathbb{R}/\mathbb{Q} a Q\mathbb{Q}-vector space with smooth operations. Let ff be smooth with f(0)=0f(0)=0. As in [exo:pi1-Talpha] the plot f∘qf\circ q lifts to a smooth F ⁣:R→RF\colon\mathbb{R}\to\mathbb{R} with F(0)=0F(0)=0 and F(x+a)−F(x)∈QF(x+a)-F(x)\in\mathbb{Q} for a∈Qa\in\mathbb{Q}. For fixed aa the left side is continuous in xx with values in a countable set, hence a constant ϕ(a)\phi(a). Differentiating, F′(x+a)=F′(x)F'(x+a)=F'(x) for all a∈Qa\in\mathbb{Q}, so the continuous function F′F' is constant on a dense set, hence constant: F(x)=cxF(x)=cx. Finally c=F(1)−F(0)=ϕ(1)∈Qc=F(1)-F(0)=\phi(1)\in\mathbb{Q}. ◀\blacktriangleleft

3 Assuming that S∞S^\infty is contractible and that S∞→CP∞S^\infty\to\mathbb{C}P^\infty is a principal U(1)U(1)-bundle [IZ, art. 4.10–4.11, 8.11], compute Π CP∞\Pi\,\mathbb{C}P^\infty. Do the same for TαT_{\alpha} using the bundle T2→TαT^2\to T_{\alpha}.

Solution.  By 1.4, ΠU(1)→ΠS∞→ΠCP∞\Pi U(1)\to\Pi S^\infty\to\Pi\mathbb{C}P^\infty is a fibre sequence with contractible total space, so Ω ΠCP∞≃ΠU(1)≃S1=K(Z,1)\Omega\,\Pi\mathbb{C}P^\infty\simeq\Pi U(1)\simeq S^1=K(\mathbb{Z},1). CP∞\mathbb{C}P^\infty is connected, hence ΠCP∞≃K(Z,2)\Pi\mathbb{C}P^\infty\simeq K(\mathbb{Z},2). For TαT_{\alpha}: the fibre R\mathbb{R} has contractible shape, so ΠT2→ΠTα\Pi T^2\to\Pi T_{\alpha} has contractible fibres over a connected base and is an equivalence; ΠT2≃T2≃BZ2\Pi T^2\simeq T^2\simeq\mathbf{B}\mathbb{Z}^2 because T2T^2 is a manifold. This is consistent with 1.5. ◀\blacktriangleleft

4 Let Γ⊂Rn\Gamma\subset\mathbb{R}^n be a countable subgroup. Prove directly from the definition of the smooth homotopy groups, without 1.2 or 1.4, that πk(TΓ,0)=0\pi_k(T_\Gamma,0)=0 for all k≥2k\ge2.

Solution.  Let q ⁣:Rn→TΓq\colon\mathbb{R}^n\to T_\Gamma be the projection and Bk={ t∈Rk:ti∈{0,1} for some i }B_k=\{\,t\in\mathbb{R}^k : t_i\in\{0,1\}\text{ for some }i\,\}. A class in πk(TΓ,0)\pi_k(T_\Gamma,0) is represented by a smooth σ ⁣:Rk→TΓ\sigma\colon\mathbb{R}^k\to T_\Gamma with σ(Bk)={0}\sigma(B_k)=\{0\}, and two representatives define the same class when they are joined by a smooth family σs\sigma_s, s∈Rs\in\mathbb{R}, of such maps.

Lifting. σ\sigma is a plot, so every point of Rk\mathbb{R}^k has a neighbourhood on which σ\sigma lifts through qq, and two lifts on a connected open set differ by a constant in Γ\Gamma, because their difference is continuous with values in a countable subset of Rn\mathbb{R}^n. The local lifts therefore form a principal Γ\Gamma-covering of Rk\mathbb{R}^k in the classical sense; it is trivial because Rk\mathbb{R}^k is simply connected. So there is a global smooth lift σ~ ⁣:Rk→Rn\tilde\sigma\colon\mathbb{R}^k\to\mathbb{R}^n with qσ~=σq\tilde\sigma=\sigma, unique up to adding a constant of Γ\Gamma.

Boundary values. σ~\tilde\sigma maps BkB_k into q−1(0)=Γq^{-1}(0)=\Gamma. For k≥2k\ge2 the set BkB_k is connected: it is a union of hyperplanes {ti=c}\{t_i=c\}, c∈{0,1}c\in\{0,1\}, any two of which with different ii intersect, and for k≥2k\ge2 any two of them are linked through a third. A continuous map from a connected set to a countable subset of Rn\mathbb{R}^n is constant, so after subtracting a constant, σ~∣Bk=0\tilde\sigma|_{B_k}=0.

Contraction. Put σs=q∘(s σ~)\sigma_s=q\circ(s\,\tilde\sigma) for s∈Rs\in\mathbb{R}. Then (s,t)↦σs(t)(s,t)\mapsto\sigma_s(t) is smooth, each σs\sigma_s sends BkB_k to 00, σ1=σ\sigma_1=\sigma and σ0\sigma_0 is constant. Hence [σ]=0[\sigma]=0.

For k=1k=1 the argument is not available: B1={0,1}B_1=\{0,1\} is disconnected, σ~(1)−σ~(0)∈Γ\tilde\sigma(1)-\tilde\sigma(0)\in\Gamma is the obstruction, and one recovers π1(TΓ)≅Γ\pi_1(T_\Gamma)\cong\Gamma as in [exo:pi1-Talpha]. ◀\blacktriangleleft

Forms

A differential form on a diffeological space is a map into a classifying sheaf that is not itself a diffeological space. From this one definition we recover the Cartan–de Rham calculus of the book, a two-line proof that forms descend along subductions, and a spectral sequence that measures the failure of de Rham’s theorem. On the irrational torus its E2E_2 page is the Künneth decomposition of the cohomology of S1×S1S^1\times S^1, with the cohomology of one circle represented by forms and that of the other by bundles.

Source in the book. [IZ, Chapter 6], especially art. 6.28–6.39 and 6.73–6.90; [IZ, art. 8.28–8.31, 8.40–8.42] for periods and integration bundles.

Forms are maps into Ωk\Omega^k

Definition 1.1 ([IZ, art. 6.28]). A differential kk-form on a diffeological space XX is a rule α\alpha assigning to each plot P ⁣:U→XP\colon U\to X a smooth form α(P)∈Ωk(U)\alpha(P)\in\Omega^k(U), such that α(P∘F)=F∗α(P)\alpha(P\circ F)=F^*\alpha(P) for every smooth F ⁣:V→UF\colon V\to U. The vector space of such is Ωk(X)\Omega^k(X).

Proposition 1.2. Ωk(X)=Hom⁡SmoothSet(X‾,Ωk)\Omega^k(X)=\operatorname{Hom}_{\mathsf{SmoothSet}}(\underline X,\Omega^k), naturally in XX. For a manifold this is the usual space of kk-forms.

Proof. A natural transformation X‾→Ωk\underline X\to\Omega^k is a family of maps X‾(U)→Ωk(U)\underline X(U)\to\Omega^k(U), natural in UU; that is 1.1, word for word. If X=MX=M is a manifold, a form ω\omega on MM gives P↦P∗ωP\mapsto P^*\omega; conversely the values of α\alpha on the inverses of charts glue to a form on MM by the compatibility condition, and determine α\alpha because every plot factors locally through charts. ◻

A kk-form on XX is a map α ⁣:X→Ωk\alpha\colon X\to\Omega^k of smooth sets. By the Yoneda lemma, a map U→ΩkU\to\Omega^k from a Cartesian space is an ordinary kk-form on UU, and the compatibility condition of 1.1 is the commutativity of the outer triangle.

Everything natural on Cartesian spaces therefore extends to all smooth sets by post-composition. The exterior derivative is a map of sheaves d ⁣:Ωk→Ωk+1\mathrm{d}\colon\Omega^k\to\Omega^{k+1} with d∘d=0\mathrm{d}\circ\mathrm{d}=0; the wedge product is a map Ωk×Ωl→Ωk+l\Omega^k\times\Omega^l\to\Omega^{k+l}; pullback along f ⁣:X→Yf\colon X\to Y is pre-composition. The identities of the Cartan calculus hold on XX because they hold in the target. This is how [IZ, art. 6.32–6.35] proceed, plot by plot.

Remark 1.3 (The space of forms). The internal hom [X,Ωk][X,\Omega^k] of SmoothSet\mathsf{SmoothSet} has Ωk(X)\Omega^k(X) as its set of points, but is not concrete: its sections over UU are the kk-forms on X×UX\times U, including those with components along UU. The functional diffeology on Ωk(X)\Omega^k(X) of [IZ, art. 6.29] is its concretisation.

Descent along subductions

Proposition 1.4 (Forms on quotients, [IZ, art. 6.38]). Let π ⁣:X→B\pi\colon X\to B be a subduction. Then Ωk(B)→ π∗ Ωk(X)⇉Ωk(X×BX)\Omega^k(B)\xrightarrow{\ \pi^*\ }\Omega^k(X)\rightrightarrows\Omega^k(X\times_BX) is an equaliser: a form on XX descends to BB, uniquely, if and only if its two pullbacks to X×BXX\times_BX coincide. Explicitly, β=π∗α\beta=\pi^*\alpha for a unique α\alpha iff β(P)=β(P′)\beta(P)=\beta(P') for all plots P,P′P,P' of XX with π∘P=π∘P′\pi\circ P=\pi\circ P'.

Proof. A subduction is an epimorphism of sheaves, because plots lift locally. In a topos every epimorphism is the coequaliser of its kernel pair, and the kernel pair of π\pi, computed in SmoothSet\mathsf{SmoothSet}, is the diffeological space X×BXX\times_BX (the inclusion Diff↪SmoothSet\mathsf{Diff}\hookrightarrow\mathsf{SmoothSet} preserves limits). Now apply Hom⁡SmoothSet(−,Ωk)\operatorname{Hom}_{\mathsf{SmoothSet}}(-,\Omega^k), which turns coequalisers into equalisers. ◻

The proof never used that the target was Ωk\Omega^k: the same statement holds for maps from BB into any smooth set. Subductions are exactly the maps along which everything descends.

Proposition 1.5 (Forms on the running examples).

  1. Let Γ⊂Rn\Gamma\subset\mathbb{R}^n be a dense countable subgroup. Then Ω∙(Rn/Γ)\Omega^\bullet(\mathbb{R}^n/\Gamma) is the exterior algebra of constant-coefficient forms on Rn\mathbb{R}^n, with zero differential. In particular Ω0(Tα)=R\Omega^0(T_{\alpha})=\mathbb{R}, Ω1(Tα)=R θ\Omega^1(T_{\alpha})=\mathbb{R}\,\theta with qα∗θ=dxq_\alpha^*\theta=\mathrm{d}x, and Ωk(Tα)=0\Omega^k(T_{\alpha})=0 for k≥2k\ge2.

  2. Ω1(Δ1)={ a(x) dx:a odd }\Omega^1(\Delta_1)=\{\,a(x)\,\mathrm{d}x : a\text{ odd}\,\} under pullback to R\mathbb{R}, and every 11-form on Δ1\Delta_1 is exact.

Proof. (i) Two plots P,P′P,P' of Rn\mathbb{R}^n with the same image in the quotient differ by a smooth map into Γ\Gamma, which is locally constant. So the condition of 1.4 is invariance under all translations by γ∈Γ\gamma\in\Gamma. The coefficients of an invariant form are continuous and Γ\Gamma-periodic, hence constant. (ii) Taking P′=−PP'=-P shows aa must be odd. Conversely let aa be odd, so that A(x)=∫0xaA(x)=\int_0^xa is even; by Whitney’s theorem [57] A(x)=B(x2)A(x)=B(x^2) with BB smooth. If P,P′P,P' are plots of R\mathbb{R} with P′=±PP'=\pm P pointwise then P′2=P2P'^2=P^2, and P∗(a dx)=d(B∘P2)=P′∗(a dx)P^*(a\,\mathrm{d}x)=\mathrm{d}(B\circ P^2)=P'^*(a\,\mathrm{d}x). By the same formula, a dx=d(B∘sq)a\,\mathrm{d}x=\mathrm{d}(B\circ\mathrm{sq}) is exact on Δ1\Delta_1. ◻

De Rham cohomology and homotopy invariance

The de Rham cohomology HdR∙(X)H^\bullet_{\mathrm{dR}}(X) of a diffeological space is the cohomology of the complex (Ω∙(X),d)(\Omega^\bullet(X),\mathrm{d}), as in [IZ, art. 6.73]. From 1.5: HdR0(Tα)=R,HdR1(Tα)=R [θ],HdRk(Tα)=0  (k≥2).H^0_{\mathrm{dR}}(T_{\alpha})=\mathbb{R},\qquad H^1_{\mathrm{dR}}(T_{\alpha})=\mathbb{R}\,[\theta],\qquad H^k_{\mathrm{dR}}(T_{\alpha})=0\ \ (k\ge2).

Proposition 1.6 (Homotopy invariance, [IZ, art. 6.88]). Smoothly homotopic maps induce the same map on de Rham cohomology.

Proof. It suffices to construct, naturally in the smooth set XX, an operator K ⁣:Ωk(X×R)→Ωk−1(X)K\colon\Omega^k(X\times\mathbb{R})\to\Omega^{k-1}(X) with dK+Kd=i1∗−i0∗\mathrm{d}K+K\mathrm{d}=i_1^*-i_0^*. For a Cartesian space UU let KUω=∫01ι∂tω dtK_U\omega=\int_0^1\iota_{\partial_t}\omega\,\mathrm{d}t be integration along the fibre of U×[0,1]→UU\times[0,1]\to U. The classical computation gives the homotopy formula on UU, and KUK_U commutes with pullback along smooth maps V→UV\to U. A natural family of maps Ωk(U×R)→Ωk−1(U)\Omega^k(U\times\mathbb{R})\to\Omega^{k-1}(U) is a map of sheaves [R,Ωk]→Ωk−1[\mathbb{R},\Omega^k]\to\Omega^{k-1}, so KK is defined on Hom⁡(X×R,Ωk)=Hom⁡(X,[R,Ωk])\operatorname{Hom}(X\times\mathbb{R},\Omega^k)=\operatorname{Hom}(X,[\mathbb{R},\Omega^k]) by post-composition, and the formula holds because it holds in the target. ◻

The chain-homotopy operator of [IZ, art. 6.83] is the refinement of KK defined on Paths⁡(X)\operatorname{Paths}(X); the argument is the same.

De Rham’s theorem and its obstruction

On a Cartesian space the de Rham complex is exact in positive degrees and its H0H^0 is the constants. As a statement about sheaves:

Lemma 1.7 (Poincaré). 0→♭R→Ω0→dΩ1→dΩ2→⋯0\to\flat\mathbb{R}\to\Omega^0\xrightarrow{\mathrm{d}}\Omega^1\xrightarrow{\mathrm{d}}\Omega^2\to\cdots is an exact sequence of sheaves of abelian groups on Cart\mathsf{Cart}, where ♭R=Disc⁡(R)\flat\mathbb{R}=\operatorname{Disc}(\mathbb{R}) is the constant sheaf. It is already exact on sections over every Cartesian space.

For a sheaf of abelian groups AA on Cart\mathsf{Cart} and X∈HX\in\mathbf{H} write Hq(X;A)=π0Map⁡H(X,BqA)H^q(X;A)=\pi_0\operatorname{Map}_{\mathbf{H}}(X,\mathbf{B}^qA). For A=♭RA=\flat\mathbb{R} the adjunction (2) gives Hq(X;♭R)=Hq(ΠX;R)H^q(X;\flat\mathbb{R})=H^q(\Pi X;\mathbb{R}), the real cohomology of the shape. For q=0q=0 and XX a smooth set, H0(X;Ωp)=Ωp(X)H^0(X;\Omega^p)=\Omega^p(X).

Theorem 1.8 (De Rham’s theorem with obstruction; after [32, 45). ]Let XX be a smooth set, for instance a diffeological space.

  1. There is a first-quadrant spectral sequence E1p,q=Hq(X;Ωp) ⟹ Hp+q(ΠX;R),d1=d∗,E_1^{p,q}=H^q(X;\Omega^p)\ \Longrightarrow\ H^{p+q}(\Pi X;\mathbb{R}),\qquad d_1=\mathrm{d}_*, with E2p,0=HdRp(X)E_2^{p,0}=H^p_{\mathrm{dR}}(X), whose edge maps HdRp(X)→Hp(ΠX;R)H^p_{\mathrm{dR}}(X)\to H^p(\Pi X;\mathbb{R}) are the de Rham homomorphisms.

  2. In low degrees there is an exact sequence 0→HdR1(X)→H1(ΠX;R)→E20,1→HdR2(X)→H2(ΠX;R),0\to H^1_{\mathrm{dR}}(X)\to H^1(\Pi X;\mathbb{R})\to E_2^{0,1}\to H^2_{\mathrm{dR}}(X)\to H^2(\Pi X;\mathbb{R}), where E20,1=ker⁡(d∗ ⁣:H1(X;R)→H1(X;Ω1))E_2^{0,1}=\ker\bigl(\mathrm{d}_*\colon H^1(X;\mathbb{R})\to H^1(X;\Omega^1)\bigr) is a subgroup of the group H1(X;R)H^1(X;\mathbb{R}) of isomorphism classes of principal R\mathbb{R}-bundles over XX.

  3. If XX is a manifold then Hq(X;Ωp)=0H^q(X;\Omega^p)=0 for q>0q>0, and all edge maps are isomorphisms.

Proof. (i) By 1.7 the complex Ω∙\Omega^\bullet is a resolution of ♭R\flat\mathbb{R}, so Bn♭R\mathbf{B}^n\flat\mathbb{R} is the object of H\mathbf{H} associated by the Dold–Kan correspondence to the complex Ω0→⋯→Ωn−1→Ωcln\Omega^0\to\cdots\to\Omega^{n-1}\to\Omega^n_{\mathrm{cl}}, and Hn(ΠX;R)=Hn(X;♭R)H^n(\Pi X;\mathbb{R})=H^n(X;\flat\mathbb{R}) is the hypercohomology Hn(X;Ω∙)\mathbb H^n(X;\Omega^\bullet). Filtering Ω∙\Omega^\bullet by its stupid truncations Ω≥p\Omega^{\ge p} gives a tower in H\mathbf{H} whose layers are Bn−pΩp\mathbf{B}^{n-p}\Omega^p, and mapping XX into the tower gives the spectral sequence with E1p,q=π0Map⁡(X,BqΩp)E_1^{p,q}=\pi_0\operatorname{Map}(X,\mathbf{B}^q\Omega^p). Its bottom row is Ω∙(X)\Omega^\bullet(X) with differential d\mathrm{d}. (ii) is the five-term exact sequence of a first-quadrant spectral sequence, together with Theorem 1.5 for the identification of H1(X;R)H^1(X;\mathbb{R}) with principal R\mathbb{R}-bundles. (iii) Cover a manifold MM by a good open cover; in H\mathbf{H}, MM is the colimit of the Čech nerve, whose terms are coproducts of Cartesian spaces. Since BqΩp\mathbf{B}^q\Omega^p has vanishing higher cohomology on Cartesian spaces, Hq(M;Ωp)H^q(M;\Omega^p) is the Čech cohomology of the cover with coefficients in Ωp\Omega^p, which vanishes for q>0q>0 by a partition of unity. The spectral sequence collapses onto its bottom row. ◻

De Rham’s theorem is thus the statement that the sheaves Ωp\Omega^p are acyclic on XX. On a manifold the reason is partitions of unity. A diffeological space has no partitions of unity in general — TαT_{\alpha} has no non-constant functions at all — and the groups Hq(X;Ωp)H^q(X;\Omega^p) are new invariants. The first of them, H1(X;Ω0)H^1(X;\Omega^0), was introduced by Iglesias-Zemmour as the group Fl⁡(X)\operatorname{Fl}(X) of “flows” or principal R\mathbb{R}-bundles [IZ, art. 8.39]; part (ii) contains his description of the cokernel of the first de Rham homomorphism [IZ, art. 8.30].

Proposition 1.9 (The E2E_2 page of the irrational torus). For X=TαX=T_{\alpha} one has E1p,q=Hq(Λα;Ωp(R))E_1^{p,q}=H^q(\Lambda_\alpha;\Omega^p(\mathbb{R})), group cohomology of Λα≅Z2\Lambda_\alpha\cong\mathbb{Z}^2 acting by translation, and E2p,q={R(p,q)∈{0,1}2,0otherwise,E_2^{p,q}=\begin{cases}\mathbb{R}& (p,q)\in\{0,1\}^2,\\ 0&\text{otherwise,}\end{cases} for every irrational α\alpha. The spectral sequence degenerates at E2E_2 and recovers H∙(T2;R)H^\bullet(T^2;\mathbb{R}). The classes are: 11 and [θ][\theta] in the row q=0q=0; the Kronecker bundle [T2→Tα][T^2\to T_{\alpha}] in E20,1E_2^{0,1}; and a class in E21,1=H1(Tα;Ω1)/dH1(Tα;R)E_2^{1,1}=H^1(T_{\alpha};\Omega^1)/\mathrm{d}H^1(T_{\alpha};\mathbb{R}) that represents the fundamental class of T2T^2.

Proof. Tα≃R/ ⁣ ⁣/ΛαT_{\alpha}\simeq\mathbb{R}/\!\!/\Lambda_\alpha in H\mathbf{H} by Corollary 1.5, so Map⁡(Tα,BqΩp)\operatorname{Map}(T_{\alpha},\mathbf{B}^q\Omega^p) is the space of homotopy fixed points of Λα\Lambda_\alpha on Map⁡(R,BqΩp)≃Bq(Ωp(R))\operatorname{Map}(\mathbb{R},\mathbf{B}^q\Omega^p)\simeq\mathbf{B}^q(\Omega^p(\mathbb{R})), whose π0\pi_0 is Hq(Λα;Ωp(R))H^q(\Lambda_\alpha;\Omega^p(\mathbb{R})). Write Λα=Z⋅1⊕Z⋅α\Lambda_\alpha=\mathbb{Z}\cdot1\oplus\mathbb{Z}\cdot\alpha. By Lemma 1.6 the generator 11 has H1(Z;Ωp(R))=0H^1(\mathbb{Z};\Omega^p(\mathbb{R}))=0 and H0(Z;Ωp(R))=Ωp(S1)H^0(\mathbb{Z};\Omega^p(\mathbb{R}))=\Omega^p(S^1), so the Lyndon–Hochschild–Serre spectral sequence gives Hq(Λα;Ωp(R))=Hq(Z;Ωp(S1))for the rotation ρα,H^q(\Lambda_\alpha;\Omega^p(\mathbb{R}))=H^q\bigl(\mathbb{Z};\Omega^p(S^1)\bigr)\quad\text{for the rotation }\rho_\alpha , which is the invariants for q=0q=0, the coinvariants Ωp(S1)/(ρα∗−1)\Omega^p(S^1)/(\rho_\alpha^*-1) for q=1q=1, and zero for q≥2q\ge2. The differential d1d_1 is induced by d\mathrm{d}, so E2∙,qE_2^{\bullet,q} is the cohomology of the complex Hq(Z;Ω∙(S1))H^q(\mathbb{Z};\Omega^\bullet(S^1)). For q=0q=0 this is the complex of rotation-invariant forms R→0R dx\mathbb{R}\xrightarrow{0}\mathbb{R}\,\mathrm{d}x. For q=1q=1 it is the complex of coinvariants C∞(S1)/(ρα∗−1)→dΩ1(S1)/(ρα∗−1)C^{\infty}(S^1)/(\rho_\alpha^*-1)\xrightarrow{\mathrm{d}}\Omega^1(S^1)/(\rho_\alpha^*-1). Its cokernel is Ω1(S1)/(dC∞(S1)+im⁡(ρα∗−1))=HdR1(S1)=R\Omega^1(S^1)/(\mathrm{d}C^{\infty}(S^1)+\operatorname{im}(\rho_\alpha^*-1))=H^1_{\mathrm{dR}}(S^1)=\mathbb{R}, since a rotation acts trivially on cohomology. Its kernel consists of the classes of gg with g′=h∘ρα−hg'=h\circ\rho_\alpha-h; writing h=c+k′h=c+k' with kk periodic gives g=k∘ρα−k+constg=k\circ\rho_\alpha-k+\text{const}, so the kernel is the line of constants. All differentials drd_r, r≥2r\ge2, vanish for degree reasons except d2 ⁣:E20,1→E22,0=0d_2\colon E_2^{0,1}\to E_2^{2,0}=0. ◻

The de Rham spectral sequence of the irrational torus. The bottom row is the de Rham cohomology HdR∙(Tα)=(R,R,0)H_{\mathrm{dR}}^\bullet(T_{\alpha})=(\mathbb{R},\mathbb{R},0). The top row is the contribution of principal R\mathbb{R}-bundles. Together they are H∙(ΠTα;R)=H∙(T2;R)=(R,R2,R)H^\bullet(\Pi T_{\alpha};\mathbb{R})=H^\bullet(T^2;\mathbb{R})=(\mathbb{R},\mathbb{R}^2,\mathbb{R}).

So the torus T2T^2 has two circles’ worth of cohomology and all of it is present in the cohomology of ΠTα\Pi T_{\alpha}, but only the circle transverse to the foliation is represented by differential forms; the circle along the leaves is represented by the non-trivial R\mathbb{R}-bundle T2→TαT^2\to T_{\alpha}. The E2E_2 page is independent of the arithmetic of α\alpha. The dependence is on E1E_1, in the size of Fl⁡(Tα)\operatorname{Fl}(T_{\alpha}), and is the subject of Theorem 1.7.

Curvature and integration bundles

The same method applies to the next classifying object. Let P⊊RP\subsetneq\mathbb{R} be a proper subgroup and TP=R/PT_P=\mathbb{R}/P; as a subspace of R\mathbb{R}, PP is discrete, since it contains no interval. The differential descends to a map of sheaves d ⁣:TP→Ωcl1\mathrm{d}\colon T_P\to\Omega^1_{\mathrm{cl}}.

Lemma 1.10. The sequence of sheaves 0→♭(R/P)→TP→dΩ1→dΩcl2→00\to\flat(\mathbb{R}/P)\to T_P\xrightarrow{\mathrm{d}}\Omega^1\xrightarrow{\mathrm{d}}\Omega^2_{\mathrm{cl}}\to0 is exact on Cart\mathsf{Cart}.

Proof. Exactness on the right and in the middle is 1.7, together with the fact that R→TP\mathbb{R}\to T_P is an epimorphism. A section of TPT_P over a Cartesian UU with zero differential lifts locally to a function with zero differential, that is, to a constant; so it is a constant map U→R/PU\to\mathbb{R}/P, and conversely. ◻

Define B(TP)conn∈H\mathbf{B}(T_P)_{\mathrm{conn}}\in\mathbf{H} as the stack associated to the two-term complex TP→dΩ1T_P\xrightarrow{\mathrm{d}}\Omega^1: over a Cartesian space its objects are 11-forms AA, and its morphisms A→A′A\to A' are sections gg of TPT_P with A′=A+dgA'=A+\mathrm{d}g. It is the analogue for TPT_P of the moduli stack of principal bundles with a connection 11-form (compare [IZ, art. 8.37]); for P=ZP=\mathbb{Z} it is the usual BU(1)conn\mathbf{B}U(1)_{\mathrm{conn}}. The curvature is the map F ⁣:B(TP)conn→Ωcl2F\colon\mathbf{B}(T_P)_{\mathrm{conn}}\to\Omega^2_{\mathrm{cl}}, A↦dAA\mapsto\mathrm{d}A.

Theorem 1.11 (Integration bundles; after [IZ, art. 8.42]). There is a fibre sequence in H\mathbf{H} B(TP)conn→ F Ωcl2→ c ♭B2(R/P).\mathbf{B}(T_P)_{\mathrm{conn}}\xrightarrow{\ F\ }\Omega^2_{\mathrm{cl}}\xrightarrow{\ c\ }\flat\mathbf{B}^2(\mathbb{R}/P). Consequently a closed 22-form ω\omega on a diffeological space XX is the curvature of a principal TPT_P-bundle with connection if and only if the class c(ω)∈H2(ΠX;R/P)c(\omega)\in H^2(\Pi X;\mathbb{R}/P) vanishes; this class is the reduction modulo PP of the image of ω\omega in H2(ΠX;R)H^2(\Pi X;\mathbb{R}). If XX is simply connected, c(ω)=0c(\omega)=0 if and only if the periods of ω\omega over π2(X)\pi_2(X) lie in PP, and then the bundle with connection is unique up to isomorphism.

Proof. By 1.10 the three-term complex TP→Ω1→Ωcl2T_P\to\Omega^1\to\Omega^2_{\mathrm{cl}} is a resolution of ♭(R/P)\flat(\mathbb{R}/P) placed in degree 22, so it presents ♭B2(R/P)\flat\mathbf{B}^2(\mathbb{R}/P). The inclusion of Ωcl2\Omega^2_{\mathrm{cl}} as its last term is cc, and the homotopy fibre of cc is presented by the truncation TP→Ω1T_P\to\Omega^1, with the map to Ωcl2\Omega^2_{\mathrm{cl}} given by d\mathrm{d}. This is the fibre sequence. A map ω ⁣:X→Ωcl2\omega\colon X\to\Omega^2_{\mathrm{cl}} lifts through the fibre iff c∘ωc\circ\omega is null-homotopic, and π0Map⁡(X,♭B2(R/P))=H2(ΠX;R/P)\pi_0\operatorname{Map}(X,\flat\mathbf{B}^2(\mathbb{R}/P))=H^2(\Pi X;\mathbb{R}/P) by (2). The comparison of resolutions Ω∙→(TP→Ω1→Ωcl2)\Omega^\bullet\to(T_P\to\Omega^1\to\Omega^2_{\mathrm{cl}}) covers R→R/P\mathbb{R}\to\mathbb{R}/P, which identifies c(ω)c(\omega). If ΠX\Pi X is simply connected, the Hurewicz and universal coefficient theorems give H2(ΠX;A)=Hom⁡(π2(ΠX),A)H^2(\Pi X;A)=\operatorname{Hom}(\pi_2(\Pi X),A) for every abelian group AA, and π2(ΠX)=π2(X)\pi_2(\Pi X)=\pi_2(X) by Theorem 1.2. Lifts are a torsor under H1(ΠX;R/P)=Hom⁡(π1(X),R/P)=0H^1(\Pi X;\mathbb{R}/P)=\operatorname{Hom}(\pi_1(X),\mathbb{R}/P)=0. ◻

Remark 1.12 (Prequantisation without integrality). Classically one needs the periods of ω\omega to be integral to build a circle bundle with curvature ω\omega. By 1.11 the integrality condition is an artefact of fixing the structure group R/Z\mathbb{R}/\mathbb{Z}: for any closed 22-form on a simply connected space whose group of periods PωP_\omega is not all of R\mathbb{R}, there is a canonical principal bundle with connection and curvature ω\omega, with structure group the torus of periods TPωT_{P_\omega}, which is an irrational torus as soon as PωP_\omega has rank at least 22. This is the theorem of Iglesias-Zemmour [IZ, art. 8.42], and a good example of a statement that is natural in Diff\mathsf{Diff} and has no formulation in Mfd\mathsf{Mfd}.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Show that Ω0(X)=C∞(X,R)\Omega^0(X)=C^{\infty}(X,\mathbb{R}), and that Ωk(X)=0\Omega^k(X)=0 for k≥1k\ge1 if XX is discrete.

Solution.  Ω0=R‾\Omega^0=\underline{\mathbb{R}} is representable, so Hom⁡SmoothSet(X‾,R‾)=Diff(X,R)\operatorname{Hom}_{\mathsf{SmoothSet}}(\underline X,\underline{\mathbb{R}})=\mathsf{Diff}(X,\mathbb{R}) by Theorem 1.2. If XX is discrete, every plot P ⁣:U→XP\colon U\to X is locally constant, so locally P=x∘cP=x\circ c with c ⁣:V→∗c\colon V\to\ast and x ⁣:∗→Xx\colon\ast\to X. Then α(P)∣V=c∗α(x)\alpha(P)|_V=c^*\alpha(x) and α(x)∈Ωk(∗)=0\alpha(x)\in\Omega^k(\ast)=0. ◀\blacktriangleleft

2 Compute the de Rham homomorphism HdR1(Tα)→H1(ΠTα;R)=Hom⁡(Λα,R)H^1_{\mathrm{dR}}(T_{\alpha})\to H^1(\Pi T_{\alpha};\mathbb{R})=\operatorname{Hom}(\Lambda_\alpha,\mathbb{R}) and its cokernel.

Solution.  HdR1(Tα)=R[θ]H^1_{\mathrm{dR}}(T_{\alpha})=\mathbb{R}[\theta] with qα∗θ=dxq_\alpha^*\theta=\mathrm{d}x. The period of θ\theta on the loop t↦qα(tμ)t\mapsto q_\alpha(t\mu), μ∈Λα\mu\in\Lambda_\alpha, is ∫01μ dt=μ\int_0^1\mu\,\mathrm{d}t=\mu. So [θ][\theta] maps to the inclusion Λα↪R\Lambda_\alpha\hookrightarrow\mathbb{R}, and c[θ]c[\theta] to μ↦cμ\mu\mapsto c\mu. In the basis of Hom⁡(Λα,R)=R2\operatorname{Hom}(\Lambda_\alpha,\mathbb{R})=\mathbb{R}^2 given by the values on 11 and α\alpha, the image is the line spanned by (1,α)(1,\alpha). The cokernel is one-dimensional, spanned for instance by the class of ρ(m+nα)=−n\rho(m+n\alpha)=-n. By 1.8(ii) and 1.9 it is E20,1E_2^{0,1}, and by [exo:kronecker-class] the class of ρ\rho is that of the bundle T2→TαT^2\to T_{\alpha}. ◀\blacktriangleleft

3 Show that a coarse diffeological space has no non-zero differential forms of positive degree.

Solution.  Let XX be coarse, α∈Ωk(X)\alpha\in\Omega^k(X) with k≥1k\ge1, P ⁣:U→XP\colon U\to X a plot (any function) and r0∈Ur_0\in U; we show α(P)r0=0\alpha(P)_{r_0}=0. Choose a diffeomorphism identifying a neighbourhood of r0r_0 with Rn\mathbb{R}^n and r0r_0 with 00; by locality we may assume U=RnU=\mathbb{R}^n. Let F(r)=(r13,…,rn3)F(r)=(r_1^3,\dots,r_n^3), a smooth homeomorphism with non-smooth inverse GG. Since XX is coarse, P∘GP\circ G is a plot, and P=(P∘G)∘FP=(P\circ G)\circ F with FF smooth, so α(P)=F∗α(P∘G)\alpha(P)=F^*\alpha(P\circ G). The derivative of FF at 00 is zero, so the pullback of any form of positive degree by FF vanishes at 00. Hence α(P)\alpha(P) vanishes at every point, for every plot. ◀\blacktriangleleft

3 For a homomorphism ρ ⁣:Λα→R\rho\colon\Lambda_\alpha\to\mathbb{R} let Xρ=(R×R)/ΛαX_\rho=(\mathbb{R}\times\mathbb{R})/\Lambda_\alpha for the action λ⋅(u,t)=(u+λ,t+ρ(λ))\lambda\cdot(u,t)=(u+\lambda,t+\rho(\lambda)), a principal R\mathbb{R}-bundle over TαT_{\alpha} with projection [u,t]↦qα(u)[u,t]\mapsto q_\alpha(u) and action s⋅[u,t]=[u,t+s]s\cdot[u,t]=[u,t+s] [IZ, art. 8.30]. Show that for ρ(m+nα)=−n\rho(m+n\alpha)=-n the bundle XρX_\rho is isomorphic to the Kronecker bundle T2→TαT^2\to T_{\alpha}, [x,y]↦qα(y−αx)[x,y]\mapsto q_\alpha(y-\alpha x), with R\mathbb{R} acting by the flow s⋅[x,y]=[x+s,y+αs]s\cdot[x,y]=[x+s,y+\alpha s].

Solution.  Define Φ ⁣:R×R→T2\Phi\colon\mathbb{R}\times\mathbb{R}\to T^2 by Φ(u,t)=[t, u+αt]\Phi(u,t)=[t,\,u+\alpha t]. It is smooth, it lies over qαq_\alpha because (u+αt)−αt=u(u+\alpha t)-\alpha t=u, and it intertwines translation in tt with the flow. For λ=m+nα\lambda=m+n\alpha we have ρ(λ)=−n\rho(\lambda)=-n and Φ(u+λ, t−n)=[t−n, u+m+nα+αt−αn]=[t−n, u+αt+m]=Φ(u,t),\Phi\bigl(u+\lambda,\ t-n\bigr)=\bigl[t-n,\ u+m+n\alpha+\alpha t-\alpha n\bigr]=\bigl[t-n,\ u+\alpha t+m\bigr]=\Phi(u,t), so Φ\Phi descends to a smooth equivariant map Φˉ ⁣:Xρ→T2\bar\Phi\colon X_\rho\to T^2 over TαT_{\alpha}. It is bijective: if Φ(u,t)=Φ(u′,t′)\Phi(u,t)=\Phi(u',t') then t′=t+kt'=t+k and u′+αt′=u+αt+lu'+\alpha t'=u+\alpha t+l with k,l∈Zk,l\in\mathbb{Z}, so u′=u+λu'=u+\lambda with λ=l−kα\lambda=l-k\alpha and t′=t+ρ(λ)t'=t+\rho(\lambda); and [x,y]=Φ(y−αx,x)[x,y]=\Phi(y-\alpha x,x). The inverse [x,y]↦[y−αx, x][x,y]\mapsto[y-\alpha x,\,x] is well defined by the same computation and smooth because R2→T2\mathbb{R}^2\to T^2 is a subduction. Hence Xρ≅T2X_\rho\cong T^2 as principal R\mathbb{R}-bundles: the Kronecker bundle is the flat bundle with holonomy m+nα↦−nm+n\alpha\mapsto-n, and it spans the cokernel found in [exo:dR-Talpha]. ◀\blacktriangleleft

4 Let XX be a connected diffeological space. Deduce from the short exact sequence of sheaves 0→♭R→R‾→dΩcl1→00\to\flat\mathbb{R}\to\underline{\mathbb{R}}\xrightarrow{\mathrm{d}}\Omega^1_{\mathrm{cl}}\to0 an exact sequence 0→HdR1(X)→Hom⁡(π1(X),R)→ ∂ H1(X;R)→H1(X;Ωcl1),0\to H^1_{\mathrm{dR}}(X)\to\operatorname{Hom}(\pi_1(X),\mathbb{R})\xrightarrow{\ \partial\ }H^1(X;\mathbb{R})\to H^1(X;\Omega^1_{\mathrm{cl}}), and show that ∂(ρ)\partial(\rho) is the class of the bundle Xρ=X~×π1(X)RX_\rho=\tilde X\times_{\pi_1(X)}\mathbb{R} of [IZ, art. 8.30].

Solution.  A short exact sequence of sheaves of abelian groups gives a fibre sequence Bq♭R→BqR‾→BqΩcl1\mathbf{B}^q\flat\mathbb{R}\to\mathbf{B}^q\underline{\mathbb{R}}\to\mathbf{B}^q\Omega^1_{\mathrm{cl}} in H\mathbf{H} for each qq, and these splice into a long fibre sequence. Applying π0Map⁡(X,−)\pi_0\operatorname{Map}(X,-) yields the exact sequence C∞(X)→dΩcl1(X)→H1(X;♭R)→H1(X;R)→H1(X;Ωcl1).C^{\infty}(X)\xrightarrow{\mathrm{d}}\Omega^1_{\mathrm{cl}}(X)\to H^1(X;\flat\mathbb{R})\to H^1(X;\mathbb{R})\to H^1(X;\Omega^1_{\mathrm{cl}}). The cokernel of the first map is HdR1(X)H^1_{\mathrm{dR}}(X), which therefore injects into the next term. By (2), H1(X;♭R)=H1(ΠX;R)H^1(X;\flat\mathbb{R})=H^1(\Pi X;\mathbb{R}), and for a connected space with fundamental group π1\pi_1 this is Hom⁡(π1,R)\operatorname{Hom}(\pi_1,\mathbb{R}); by Theorem 1.2, π1(ΠX)=π1(X)\pi_1(\Pi X)=\pi_1(X). This gives the sequence.

For ∂\partial: it is induced by B♭R=BRδ→BR\mathbf{B}\flat\mathbb{R}=\mathbf{B}\mathbb{R}^{\delta}\to\mathbf{B}\mathbb{R}, which sends a principal Rδ\mathbb{R}^{\delta}-bundle to the principal R\mathbb{R}-bundle obtained by extending the structure group along the smooth homomorphism Rδ→R\mathbb{R}^{\delta}\to\mathbb{R}. Under H1(ΠX;R)=Hom⁡(π1,R)H^1(\Pi X;\mathbb{R})=\operatorname{Hom}(\pi_1,\mathbb{R}) the homomorphism ρ\rho corresponds to the Rδ\mathbb{R}^{\delta}-bundle X~×π1Rδ\tilde X\times_{\pi_1}\mathbb{R}^{\delta} associated to the universal covering, a principal π1\pi_1-bundle (Shape), via ρ\rho. Extending the group gives X~×π1R=Xρ\tilde X\times_{\pi_1}\mathbb{R}=X_\rho.

Exactness at H1(X;R)H^1(X;\mathbb{R}) is now the statement that XρX_\rho is trivial if and only if ρ\rho is the period homomorphism of a closed 11-form. This is the theorem of [IZ, art. 8.30]. Exactness at the next term gives more: a principal R\mathbb{R}-bundle is of the form XρX_\rho, i.e. flat, if and only if its image in H1(X;Ωcl1)H^1(X;\Omega^1_{\mathrm{cl}}) vanishes. ◀\blacktriangleleft

Bundles and stacks

In [1] principal bundles are defined by an induction condition on the action map. We show that this condition holds exactly when the diffeological quotient is the homotopy quotient. It follows that principal bundles are classified by maps to a stack BG\mathbf{B}G, which is not a diffeological space, and that a group action has three quotients — stack, smooth set, diffeological space — which coincide precisely for principal actions.

Source in the book. [IZ, Chapter 7] (groups) and [IZ, art. 8.1–8.19] (groupoids, fibrations, principal and associated bundles).

Diffeological groups

A diffeological group is a group object of Diff\mathsf{Diff}: a group GG with a diffeology for which multiplication and inversion are smooth [IZ, art. 7.1]. Lie groups are examples; so are TαT_{\alpha} and R/Q\mathbb{R}/\mathbb{Q}; so is every subgroup of a diffeological group with the subspace diffeology and every quotient group with the quotient diffeology [IZ, art. 7.2–7.3]; so is Diff⁡(X)\operatorname{Diff}(X) for every diffeological space XX, with the diffeology in which r↦frr\mapsto f_r is a plot when both (r,x)↦fr(x)(r,x)\mapsto f_r(x) and (r,x)↦fr−1(x)(r,x)\mapsto f_r^{-1}(x) are smooth [IZ, art. 1.61]. None of these constructions has hypotheses: there is no closedness condition on subgroups and no properness condition on quotients.

A diffeological group is in particular a group object of H\mathbf{H}, and so has a delooping BG=∗/ ⁣ ⁣/G=colim⁡[k]∈ΔopGk ∈H,Ω BG≃G.\mathbf{B}G=\ast/\!\!/G=\operatorname*{colim}_{[k]\in\Delta^{\mathrm{op}}}G^k\ \in\mathbf{H},\qquad\Omega\,\mathbf{B}G\simeq G . BG\mathbf{B}G is a connected 11-truncated object, a stack. It has one point and that point has automorphism group GG; it is not a smooth set unless GG is trivial.

Principal actions are homotopy quotients

Definition 1.1 ([IZ, art. 8.11]). A smooth right action of a diffeological group GG on a diffeological space XX is principal if the action map a ⁣:X×G⟶X×X,(x,g)⟼(x,xg),a\colon X\times G\longrightarrow X\times X,\qquad(x,g)\longmapsto(x,xg), is an induction. A principal GG-bundle over BB is a space XX with a principal GG-action and a diffeomorphism X/G≅BX/G\cong B.

Injectivity of aa means that the action is free. The induction condition is stronger: whenever two plots r↦xrr\mapsto x_r, r↦xr′r\mapsto x'_r of XX lie pointwise in the same orbit, the unique family grg_r with xr′=xrgrx'_r=x_rg_r is a plot of GG. In [1] this is the hypothesis under which X→X/GX\to X/G is proved to be a fibre bundle. Here is what it means.

Theorem 1.2 (Principal == homotopy quotient; compare [44). ]For a smooth action of a diffeological group GG on a diffeological space XX, with diffeological quotient π ⁣:X→B=X/G\pi\colon X\to B=X/G, the following are equivalent.

  1. The action is principal.

  2. The canonical map X/ ⁣ ⁣/G→BX/\!\!/G\to B is an equivalence in H\mathbf{H}.

  3. For every plot P ⁣:U→BP\colon U\to B, the pullback P∗X→UP^*X\to U is locally isomorphic to U×GU\times G as a space with GG-action.

Proof. (i)⇔\Leftrightarrow(ii). The quotient map π\pi is a subduction, hence an epimorphism of sheaves, hence an effective epimorphism of H\mathbf{H}, since effective epimorphisms are detected on π0\pi_0 [42, 7.2.1.14]. So BB is the colimit of the Čech nerve Cˇ(π)k=X×B⋯×BX\check C(\pi)_k=X\times_B\cdots\times_BX, and these fibre products may be computed in Diff\mathsf{Diff} because the inclusions Diff↪SmoothSet↪H\mathsf{Diff}\hookrightarrow\mathsf{SmoothSet}\hookrightarrow\mathbf{H} preserve limits. On the other hand X/ ⁣ ⁣/GX/\!\!/G is by definition the colimit of the nerve of the action groupoid, Nk=X×GkN_k=X\times G^k. There is a map of simplicial objects Nk=X×Gk⟶Cˇ(π)k,(x,g1,…,gk)⟼(x,xg1,xg1g2,… ),N_k=X\times G^k\longrightarrow\check C(\pi)_k,\qquad(x,g_1,\dots,g_k)\longmapsto(x,xg_1,xg_1g_2,\dots), inducing X/ ⁣ ⁣/G→BX/\!\!/G\to B on colimits (1.1). Both sides are groupoid objects, so the map is an isomorphism in every degree iff it is one in degree 11, where it is the action map aa with target restricted to its image X×BXX\times_BX. The fibres of π\pi are the orbits, so aa is onto X×BXX\times_BX; since X×BXX\times_BX carries the subspace diffeology of X×XX\times X, the map X×G→X×BXX\times G\to X\times_BX is a diffeomorphism iff aa is an induction. Thus (i) implies (ii). Conversely, if X/ ⁣ ⁣/G≃BX/\!\!/G\simeq B then, groupoid objects in an ∞\infty-topos being effective [42, 6.1.0.6], X×G≃X×X/ ⁣ ⁣/GX≃X×BXX\times G\simeq X\times_{X/\!\!/G}X\simeq X\times_BX via aa, which is (i).

(i)⇒\Rightarrow(iii). Since π\pi is a subduction, PP lifts near any r0r_0 to a plot s ⁣:V→Xs\colon V\to X. The map V×G→P∗X∣VV\times G\to P^*X|_V, (r,g)↦(r,s(r)g)(r,g)\mapsto(r,s(r)g), is a smooth equivariant bijection. Its inverse sends (r,x)(r,x) to (r,g)(r,g) where a(s(r),g)=(s(r),x)a(s(r),g)=(s(r),x), and is smooth because aa is an induction.

(iii)⇒\Rightarrow(i). The action is free because each P∗XP^*X is locally V×GV\times G. Let r↦(xr,xr′)r\mapsto(x_r,x'_r) be a plot of X×XX\times X with values in the image of aa, and let P=π∘x=π∘x′P=\pi\circ x=\pi\circ x'. Trivialise P∗XP^*X near r0r_0; the two sections r↦(r,xr)r\mapsto(r,x_r) and r↦(r,xr′)r\mapsto(r,x'_r) become r↦(r,hr)r\mapsto(r,h_r) and r↦(r,hr′)r\mapsto(r,h'_r) with h,h′h,h' plots of GG, and gr=hr−1hr′g_r=h_r^{-1}h'_r is a plot of GG with xr′=xrgrx'_r=x_rg_r. ◻

The nerve of the action groupoid (top) maps to the Čech nerve of the quotient map (bottom). The top row computes the homotopy quotient, the bottom row the diffeological quotient. They coincide exactly when aa is an isomorphism onto X×BXX\times_BX, i.e. an induction.

Corollary 1.3 ([IZ, art. 8.15]). Let HH be any subgroup of a diffeological group GG. Then G→G/HG\to G/H is a principal HH-bundle, G/H≃G/ ⁣ ⁣/HG/H\simeq G/\!\!/H, and there is a fibre sequence H→G→G/H→BH→BGH\to G\to G/H\to\mathbf{B}H\to\mathbf{B}G in H\mathbf{H}.

Proof. If r↦(gr,gr′)r\mapsto(g_r,g'_r) is a plot of G×GG\times G with gr−1gr′∈Hg_r^{-1}g'_r\in H, then r↦gr−1gr′r\mapsto g_r^{-1}g'_r is a plot of GG with values in HH, that is, a plot of HH. So the action is principal. The fibre sequence is the general one for a homomorphism of group objects [46]. ◻

No hypothesis on HH: it may be dense, as Λα⊂R\Lambda_\alpha\subset\mathbb{R}, or non-closed and of positive dimension, as an irrational line in T2T^2. This one corollary contains the fact that T2→TαT^2\to T_{\alpha} and R→Tα\mathbb{R}\to T_{\alpha} are both fibre bundles.

The classifying stack

For a diffeological space XX let Bun⁡G(X)\operatorname{Bun}_G(X) be the groupoid of principal GG-bundles over XX and GG-equivariant smooth maps over XX.

Lemma 1.4.

  1. The pullback of a principal GG-bundle along any smooth map is a principal GG-bundle.

  2. Every morphism of principal GG-bundles over XX is an isomorphism.

  3. ([IZ, art. 8.19]) Every principal GG-bundle over a Cartesian space is trivial. Hence Bun⁡G(U)≃B(C∞(U,G))\operatorname{Bun}_G(U)\simeq\mathbf{B}\bigl(C^{\infty}(U,G)\bigr) for U∈CartU\in\mathsf{Cart}.

(i) and (ii) are [exo:Bun-cart]. (iii) is a real theorem, the diffeological form of the homotopy lifting property, and we quote it. Its meaning here is that the presheaf of groupoids U↦B(C∞(U,G))U\mapsto\mathbf{B}(C^{\infty}(U,G)) on Cart\mathsf{Cart} is already a stack: there is nothing to sheafify.

Theorem 1.5 (Classification; Minichiello [44). , after [54, 38]]For every diffeological group GG and every diffeological space XX there is an equivalence of groupoids, natural in XX, Bun⁡G(X)  ≃  Map⁡H(X,BG),\operatorname{Bun}_G(X)\;\simeq\;\operatorname{Map}_{\mathbf{H}}(X,\mathbf{B}G), under which a bundle E→XE\to X corresponds to a map cEc_E with E≃X×BG∗E\simeq X\times_{\mathbf{B}G}\ast. In particular isomorphism classes of principal GG-bundles are in bijection with H1(X;G):=π0Map⁡H(X,BG)H^1(X;G):=\pi_0\operatorname{Map}_{\mathbf{H}}(X,\mathbf{B}G).

Sketch. Cartesian UU. BG\mathbf{B}G is the stackification of U↦B(C∞(U,G))U\mapsto\mathbf{B}(C^{\infty}(U,G)), which by 1.4(iii) is equivalent to the stack U↦Bun⁡G(U)U\mapsto\operatorname{Bun}_G(U); so BG(U)≃Bun⁡G(U)\mathbf{B}G(U)\simeq\operatorname{Bun}_G(U). General XX. Every sheaf is the colimit of the representables over it, so X≃colim⁡(U→X)UX\simeq\operatorname*{colim}_{(U\to X)}U in H\mathbf{H}, the colimit being over the category of plots, and Map⁡(X,BG)≃lim⁡(U→X)Bun⁡G(U)\operatorname{Map}(X,\mathbf{B}G)\simeq\lim_{(U\to X)}\operatorname{Bun}_G(U). An object of the limit is a principal bundle EP→UE_P\to U for every plot PP, with coherent isomorphisms F∗EP≅EP∘FF^*E_P\cong E_{P\circ F}. Pulling back a bundle on XX along its plots gives such a family. Conversely a family glues: let EE be the disjoint union over x∈Xx\in X of the fibres ExE_x over the point-plots, with the diffeology generated by the maps EP→EE_P\to E; then E→XE\to X is a principal bundle by criterion (iii) of 1.2, and P∗E≅EPP^*E\cong E_P. The two constructions are inverse equivalences. For the last statement, the pullback of ∗→BG\ast\to\mathbf{B}G along cEc_E is a principal bundle with quotient XX, as in any ∞\infty-topos [46]. ◻

Remark 1.6 (There is no classifying space). Christensen and Wu construct a diffeological space BGBG that classifies the bundles that have a smooth partition of unity subordinate to a trivialising D-open cover, and observe that no diffeological space classifies all diffeological principal bundles [13]. The Kronecker bundle exhibits the obstruction. Homotopy classes of maps into a space classify bundles at best up to concordance, and every principal R\mathbb{R}-bundle over TαT_{\alpha} is concordant to the trivial one: if τ\tau is a cocycle for it in the sense of 1.7 below, then (x,s)↦s τ(λ)(x)(x,s)\mapsto s\,\tau(\lambda)(x) is a cocycle for a bundle over Tα×RT_{\alpha}\times\mathbb{R} that restricts to the trivial bundle at s=0s=0 and to the given one at s=1s=1. Over a manifold, concordant bundles are isomorphic. Over TαT_{\alpha} they are not: T2→TαT^2\to T_{\alpha} is concordant to the trivial bundle and not isomorphic to it. For the stack BR\mathbf{B}\mathbb{R} the distinction does not arise, because Map⁡(X,BR)\operatorname{Map}(X,\mathbf{B}\mathbb{R}) is the groupoid of bundles and isomorphisms, not a set of homotopy classes. BR\mathbf{B}\mathbb{R} has contractible shape, Π BR≃B(ΠR)≃∗\Pi\,\mathbf{B}\mathbb{R}\simeq\mathbf{B}(\Pi\mathbb{R})\simeq\ast, and yet Map⁡(Tα,BR)\operatorname{Map}(T_{\alpha},\mathbf{B}\mathbb{R}) has the large set of components Fl⁡(Tα)\operatorname{Fl}(T_{\alpha}) computed in Theorem 1.7. The classifying object of the book’s bundle theory exists, and is not a diffeological space.

Corollary 1.7 (Bundles over quotients of Rn\mathbb{R}^n). Let Γ⊂Rn\Gamma\subset\mathbb{R}^n be a countable subgroup and GG a diffeological group. Then Bun⁡G(Rn/Γ)  ≃  (B C∞(Rn,G))hΓ,\operatorname{Bun}_G(\mathbb{R}^n/\Gamma)\;\simeq\;\bigl(\mathbf{B}\,C^{\infty}(\mathbb{R}^n,G)\bigr)^{h\Gamma}, the homotopy fixed points for the translation action. Its set of components is the non-abelian cohomology set H1(Γ;C∞(Rn,G))H^1(\Gamma;C^{\infty}(\mathbb{R}^n,G)) of crossed homomorphisms τ ⁣:Γ→C∞(Rn,G)\tau\colon\Gamma\to C^{\infty}(\mathbb{R}^n,G), τ(γ+γ′)=(τ(γ)∘Tγ′)⋅τ(γ′)\tau(\gamma+\gamma')=(\tau(\gamma)\circ T_{\gamma'})\cdot\tau(\gamma'), modulo τ∼(σ∘Tγ)⋅τ(γ)⋅σ−1\tau\sim(\sigma\circ T_\gamma)\cdot\tau(\gamma)\cdot\sigma^{-1}.

Proof. Rn/Γ≃Rn/ ⁣ ⁣/Γ\mathbb{R}^n/\Gamma\simeq\mathbb{R}^n/\!\!/\Gamma by Corollary 1.5, and mapping out of a homotopy quotient gives homotopy fixed points: Map⁡(Rn/Γ,BG)≃Map⁡(Rn,BG)hΓ,Map⁡(Rn,BG)≃B C∞(Rn,G),\operatorname{Map}(\mathbb{R}^n/\Gamma,\mathbf{B}G)\simeq\operatorname{Map}(\mathbb{R}^n,\mathbf{B}G)^{h\Gamma},\qquad\operatorname{Map}(\mathbb{R}^n,\mathbf{B}G)\simeq\mathbf{B}\,C^{\infty}(\mathbb{R}^n,G), the second equivalence by 1.4(iii). ◻

For G=RG=\mathbb{R} and n=1n=1 this is the cocycle description of [IZ, art. 8.39], obtained there by hand.

The three quotients

Theorem 1.8 (Trichotomy of quotients; compare [56). ]Let a diffeological group GG act smoothly on a diffeological space XX. In H\mathbf{H} there are canonical maps X/ ⁣ ⁣/G  → u   π0(X/ ⁣ ⁣/G)  → v   conc⁡ π0(X/ ⁣ ⁣/G),X/\!\!/G\;\xrightarrow{\ u\ }\;\pi_0(X/\!\!/G)\;\xrightarrow{\ v\ }\;\operatorname{conc}\,\pi_0(X/\!\!/G), and:

  1. π0(X/ ⁣ ⁣/G)\pi_0(X/\!\!/G) is the quotient of XX by GG in SmoothSet\mathsf{SmoothSet}, and conc⁡ π0(X/ ⁣ ⁣/G)\operatorname{conc}\,\pi_0(X/\!\!/G) is the diffeological quotient X/GX/G;

  2. uu is an equivalence if and only if the action is free;

  3. if the action is free, vv is an isomorphism if and only if the action is principal;

  4. Π(X/ ⁣ ⁣/G)≃ΠX/ ⁣ ⁣/ΠG\Pi(X/\!\!/G)\simeq\Pi X/\!\!/\Pi G in all cases.

In particular X/ ⁣ ⁣/G≃X/GX/\!\!/G\simeq X/G if and only if the action is principal.

Proof. (i) π0\pi_0 and conc⁡\operatorname{conc} are left adjoints (Theorem 1.5), so they carry the colimit X/ ⁣ ⁣/GX/\!\!/G to the corresponding colimits in SmoothSet\mathsf{SmoothSet} and Diff\mathsf{Diff}, which are the coequalisers of the action. (iv) Π\Pi preserves colimits and finite products. (ii) Let q ⁣:X→X/ ⁣ ⁣/Gq\colon X\to X/\!\!/G be the canonical effective epimorphism, with X×X/ ⁣ ⁣/GX≃X×GX\times_{X/\!\!/G}X\simeq X\times G. The object X/ ⁣ ⁣/GX/\!\!/G is 00-truncated iff its diagonal is a monomorphism, and this may be tested after pulling back along the effective epimorphism q×qq\times q, where it becomes the action map a ⁣:X×G→X×Xa\colon X\times G\to X\times X. A map of concrete sheaves is a monomorphism iff it is injective on points. So X/ ⁣ ⁣/GX/\!\!/G is 00-truncated iff aa is injective iff the action is free. (iii) Assume the action free and write S=π0(X/ ⁣ ⁣/G)=X/ ⁣ ⁣/GS=\pi_0(X/\!\!/G)=X/\!\!/G. Both X→SX\to S and X→X/GX\to X/G are epimorphisms of sheaves, and an epimorphism in a topos is determined by its kernel pair. The kernel pair of X→SX\to S is X×GX\times G, embedded by aa; that of X→X/GX\to X/G is X×X/GXX\times_{X/G}X, the image of aa with the subspace diffeology. They coincide as subobjects of X×XX\times X iff aa is an induction. ◻

The three quotients on examples. Reading down the columns: the homotopy quotient retains all the data; in the sheaf quotient the stabilisers are discarded; in the diffeological quotient families that coincide pointwise are moreover identified, whether or not they coincide in germs.
action free principal X/ ⁣ ⁣/GX/\!\!/G π0(X/ ⁣ ⁣/G)\pi_0(X/\!\!/G) X/GX/G
Λα\Lambda_\alpha on R\mathbb{R} yes yes TαT_{\alpha} TαT_{\alpha} TαT_{\alpha}
R\mathbb{R} on T2T^2 (Kronecker) yes yes TαT_{\alpha} TαT_{\alpha} TαT_{\alpha}
Rδ\mathbb{R}^{\delta} on R\mathbb{R} yes no Ωcl1\Omega^1_{\mathrm{cl}} Ωcl1\Omega^1_{\mathrm{cl}} ∗\ast
{±1}\{\pm1\} on R\mathbb{R} no no orbifold, Π=BZ/2\Pi=\mathbf{B}\mathbb{Z}/2 QQ (Example 1.11) Δ1\Delta_1, Π=∗\Pi=\ast
O⁡(n)\operatorname{O}(n) on Rn\mathbb{R}^n no no stack, Π=BO⁡(n)\Pi=B\operatorname{O}(n) non-concrete Δn\Delta_n, Π=∗\Pi=\ast
GG on ∗\ast no no BG\mathbf{B}G ∗\ast ∗\ast

Theorem 1.8 is the precise form of the exactness ladder of [fig:ladder], and it is the one structural statement used in every application chapter. It also accounts for a pattern in [1]: the theorems there with strong conclusions — exact homotopy sequences, classification of bundles over tori, the group of flows — are about principal actions, where the diffeological quotient is the homotopy quotient and nothing is lost; the examples there with unexpected properties — Δn\Delta_n, orbifolds — are about non-free actions, where the diffeological space is the coarse space of a stack. Watts and Wolbert study the coarse space systematically as a “coarse moduli space” functor from stacks to diffeological spaces [56].

Groupoids and the book’s fibrations

In [1] a smooth surjection π ⁣:T→B\pi\colon T\to B is a fibration when its structure groupoid is fibrating [IZ, art. 8.4–8.8]. The structure groupoid K\mathbf K has objects BB and as morphisms b→b′b\to b' the diffeomorphisms Tb→Tb′T_b\to T_{b'}, with a functional diffeology; a diffeological groupoid is fibrating when (src,trg) ⁣:Mor⁡(K)→Ob⁡(K)2(\mathrm{src},\mathrm{trg})\colon\operatorname{Mor}(\mathbf K)\to\operatorname{Ob}(\mathbf K)^2 is a subduction.

Proposition 1.9 (Fibrating groupoids are deloopings). Let K\mathbf K be a fibrating diffeological groupoid with non-empty space of objects, bb an object, and Kb\mathbf K_b its isotropy group. Then the inclusion BKb→∣K∣\mathbf{B}\mathbf K_b\to|\mathbf K| of the one-object full subgroupoid into the stack presented by K\mathbf K is an equivalence in H\mathbf{H}. Consequently the canonical map Ob⁡(K)→∣K∣≃BKb\operatorname{Ob}(\mathbf K)\to|\mathbf K|\simeq\mathbf{B}\mathbf K_b classifies a principal Kb\mathbf K_b-bundle over Ob⁡(K)\operatorname{Ob}(\mathbf K), namely trg ⁣:src−1(b)→Ob⁡(K)\mathrm{trg}\colon\mathrm{src}^{-1}(b)\to\operatorname{Ob}(\mathbf K).

The proof is [exo:fibrating]. Applied to the structure groupoid of π ⁣:T→B\pi\colon T\to B it gives: π\pi is a diffeological fibre bundle with fibre FF if and only if it is classified by a map B→BDiff⁡(F)B\to\mathbf{B}\operatorname{Diff}(F), the principal Diff⁡(F)\operatorname{Diff}(F)-bundle being the bundle of “frames” F→≅TbF\xrightarrow{\cong}T_b [IZ, art. 8.14], and TT being recovered as the associated bundle [IZ, art. 8.16]. The two-step definition of [1] — build a groupoid, require that it be fibrating — is the unpacking, in terms of plots, of “a map to a delooping”.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

2 Verify directly that the Kronecker action s⋅[x,y]=[x+s,y+αs]s\cdot[x,y]=[x+s,y+\alpha s] of R\mathbb{R} on T2T^2 is principal when α\alpha is irrational, and that it is not principal when α\alpha is rational.

Solution.  Let r↦(zr,zr′)r\mapsto(z_r,z'_r) be a plot of T2×T2T^2\times T^2 with zr′z'_r in the orbit of zrz_r. Near r0r_0 lift to smooth (x,y),(x′,y′) ⁣:V→R2(x,y),(x',y')\colon V\to\mathbb{R}^2. For each rr there are s∈Rs\in\mathbb{R} and (m,n)∈Z2(m,n)\in\mathbb{Z}^2 with x′−x=s+mx'-x=s+m and y′−y=αs+ny'-y=\alpha s+n. Then w=(y′−y)−α(x′−x)=n−αmw=(y'-y)-\alpha(x'-x)=n-\alpha m is a smooth function with values in Λα\Lambda_\alpha, hence locally constant; as α\alpha is irrational, ww determines (m,n)(m,n), which are therefore locally constant. So sr=xr′−xr−ms_r=x'_r-x_r-m is smooth, and it is the unique real number with zr′=sr⋅zrz'_r=s_r\cdot z_r because the action is free. Hence the action map is an induction. If α=p/q\alpha=p/q is rational, s=qs=q acts trivially, so the action is not free. ◀\blacktriangleleft

2 For {±1}\{\pm1\} acting on R\mathbb{R}, compute the shapes of R/ ⁣ ⁣/{±1}\mathbb{R}/\!\!/\{\pm1\} and of Δ1\Delta_1, and explain the difference in terms of fibres.

Solution.  By 1.8(iv), Π(R/ ⁣ ⁣/{±1})=∗/ ⁣ ⁣/(Z/2)=BZ/2≃RP∞\Pi(\mathbb{R}/\!\!/\{\pm1\})=\ast/\!\!/(\mathbb{Z}/2)=\mathbf{B}\mathbb{Z}/2\simeq\mathbb{R}P^\infty. By [exo:contractible], ΠΔ1=∗\Pi\Delta_1=\ast. The map R/ ⁣ ⁣/{±1}→Δ1\mathbb{R}/\!\!/\{\pm1\}\to\Delta_1 is an isomorphism over the open half-line and has fibre BZ/2\mathbf{B}\mathbb{Z}/2 over the point [0][0]; collapsing that one fibre changes the homotopy type from RP∞\mathbb{R}P^\infty to a point. The stack retains the stabiliser of 00, and in consequence its shape differs from that of the half-line. ◀\blacktriangleleft

3 Prove 1.4(i) and (ii), and show that the automorphism group of the trivial bundle X×G→XX\times G\to X is C∞(X,G)C^{\infty}(X,G).

Solution.  (i) Let E→XE\to X be principal and f ⁣:X′→Xf\colon X'\to X smooth; f∗E=X′×XEf^*E=X'\times_XE carries the GG-action on the second factor. Let r↦((xr′,er),(xr′,ergr))r\mapsto((x'_r,e_r),(x'_r,e_rg_r)) be a plot of f∗E×f∗Ef^*E\times f^*E in the image of the action map. Then r↦(er,ergr)r\mapsto(e_r,e_rg_r) is a plot of E×EE\times E in the image of the action map of EE, so r↦grr\mapsto g_r is a plot of GG. The quotient f∗E/G→X′f^*E/G\to X' is a bijection, and it is a diffeomorphism because f∗E→X′f^*E\to X' is a subduction (pullback of a subduction).

(ii) Let ϕ ⁣:E→E′\phi\colon E\to E' be equivariant over XX. It is bijective, being a bijection on each fibre (a GG-torsor). To see that ϕ−1\phi^{-1} is smooth, let r↦er′r\mapsto e'_r be a plot of E′E'; near r0r_0 lift its projection to a plot r↦err\mapsto e_r of EE. Then ϕ(er)\phi(e_r) and er′e'_r lie in the same fibre, so er′=ϕ(er)gre'_r=\phi(e_r)g_r with gg a plot of GG by principality of E′E', and ϕ−1(er′)=ergr\phi^{-1}(e'_r)=e_rg_r is a plot.

For the trivial bundle, an equivariant map over XX has the form (x,g)↦(x,σ(x)g)(x,g)\mapsto(x,\sigma(x)g), with σ(x)\sigma(x) the GG-component of the image of (x,1)(x,1); σ\sigma is smooth iff the map is. ◀\blacktriangleleft

3 Classify the principal Z\mathbb{Z}-bundles over TαT_{\alpha} and describe their total spaces.

Solution.  By 1.7, classes are H1(Λα;C∞(R,Z))=H1(Λα;Z)=Hom⁡(Λα,Z)≅Z2H^1(\Lambda_\alpha;C^{\infty}(\mathbb{R},\mathbb{Z}))=H^1(\Lambda_\alpha;\mathbb{Z})=\operatorname{Hom}(\Lambda_\alpha,\mathbb{Z})\cong\mathbb{Z}^2, since a smooth map R→Z\mathbb{R}\to\mathbb{Z} is constant and Λα\Lambda_\alpha acts trivially on constants. For ρ∈Hom⁡(Λα,Z)\rho\in\operatorname{Hom}(\Lambda_\alpha,\mathbb{Z}) the bundle is Eρ=(R×Z)/ΛαE_\rho=(\mathbb{R}\times\mathbb{Z})/\Lambda_\alpha with λ⋅(x,k)=(x+λ,k+ρ(λ))\lambda\cdot(x,k)=(x+\lambda,k+\rho(\lambda)). If ρ=0\rho=0 then Eρ=Tα×ZE_\rho=T_{\alpha}\times\mathbb{Z}. If ρ≠0\rho\neq0, its image is dZd\mathbb{Z} for some d≥1d\ge1 and its kernel is infinite cyclic, generated by some μ∈Λα\mu\in\Lambda_\alpha. The components of EρE_\rho are indexed by Z/d\mathbb{Z}/d, and each is R/ker⁡ρ=R/μZ\mathbb{R}/\ker\rho=\mathbb{R}/\mu\mathbb{Z}, a circle of length ∣μ∣\lvert \mu\rvert. So the connected coverings of TαT_{\alpha} with group Z\mathbb{Z} are the circles R/μZ\mathbb{R}/\mu\mathbb{Z}, μ∈Λα\mu\in\Lambda_\alpha primitive, on which the remaining generator of Λα\Lambda_\alpha acts by an irrational rotation with quotient TαT_{\alpha}. The irrational torus is a circle modulo an irrational rotation in a GL⁡2(Z)\operatorname{GL}_2(\mathbb{Z})-worth of ways. ◀\blacktriangleleft

4 Prove 1.9.

Solution.  Write O=Ob⁡(K)O=\operatorname{Ob}(\mathbf K), M=Mor⁡(K)M=\operatorname{Mor}(\mathbf K), E=src−1(b)⊆ME=\mathrm{src}^{-1}(b)\subseteq M with the subspace diffeology, and G=KbG=\mathbf K_b acting on EE by f⋅g=f∘gf\cdot g=f\circ g.

Step 1: trg ⁣:E→O\mathrm{trg}\colon E\to O is a subduction. EE is the pullback of χ=(src,trg) ⁣:M→O×O\chi=(\mathrm{src},\mathrm{trg})\colon M\to O\times O along O→O×OO\to O\times O, x↦(b,x)x\mapsto(b,x). Since K\mathbf K is fibrating, χ\chi is a subduction, and subductions are stable under pullback (Proposition 1.7).

Step 2: the action of GG on EE is principal with quotient OO. Two arrows f,f′∈Ef,f'\in E have the same target iff f′=f∘gf'=f\circ g with g=f−1∘f′∈Gg=f^{-1}\circ f'\in G, so the fibres of trg∣E\mathrm{trg}|_E are the GG-orbits and the action is free. If r↦(fr,fr′)r\mapsto(f_r,f'_r) is a plot of E×EE\times E with equal targets, then gr=fr−1∘fr′g_r=f_r^{-1}\circ f'_r is a plot of MM, because inversion and composition are smooth in a diffeological groupoid, with values in GG; so it is a plot of GG. Thus the action map is an induction, and O≅E/GO\cong E/G by Step 1 and uniqueness of quotients. By 1.2, O≃E/ ⁣ ⁣/GO\simeq E/\!\!/G in H\mathbf{H}.

Step 3: the equivalence. ∣K∣|\mathbf K| is the colimit of the nerve of K\mathbf K; the canonical map p ⁣:O→∣K∣p\colon O\to|\mathbf K| is an effective epimorphism with O×∣K∣O≃MO\times_{|\mathbf K|}O\simeq M. Consider the composite ∗→bO→p∣K∣\ast\xrightarrow{b}O\xrightarrow{p}|\mathbf K|. Its pullback along pp is ∗×∣K∣O≃src−1(b)=E\ast\times_{|\mathbf K|}O\simeq\mathrm{src}^{-1}(b)=E, mapping to OO by trg\mathrm{trg}, which is an effective epimorphism by Step 1. Effective epimorphisms descend along the effective epimorphism pp, so ∗→∣K∣\ast\to|\mathbf K| is an effective epimorphism. Its Čech nerve has ∗×∣K∣∗≃src−1(b)∩trg−1(b)=G\ast\times_{|\mathbf K|}\ast\simeq\mathrm{src}^{-1}(b)\cap\mathrm{trg}^{-1}(b)=G in degree 11, so it is the nerve of GG, and ∣K∣≃colim⁡Gk=BG|\mathbf K|\simeq\operatorname*{colim}G^k=\mathbf{B}G.

Step 4: the classified bundle. The principal bundle classified by p ⁣:O→∣K∣≃BGp\colon O\to|\mathbf K|\simeq\mathbf{B}G is the pullback of ∗→BG\ast\to\mathbf{B}G along pp, which by Step 3 is E→OE\to O. ◀\blacktriangleleft

Models

Manifolds, manifolds with boundary and corners, orbifolds and quasifolds are all “diffeological spaces locally diffeomorphic to a model”. We review what the diffeology determines in each case, where it is the coarse space of a stack, and how much of it is determined by real-valued functions.

Source in the book. [IZ, Chapter 4], and [IZ, art. 1.78, 2.22] for dimension.

Modelling

A local diffeomorphism between diffeological spaces is a map that is, near each point of its source, a diffeomorphism from a D-open subset onto a D-open subset [IZ, art. 2.5]. Given a class M\mathcal M of diffeological spaces, a space is modelled on M\mathcal M if every point has a D-open neighbourhood diffeomorphic to a D-open subset of a member of M\mathcal M [IZ, art. 4.19].

Classical and less classical geometries as modelled diffeological spaces. Half-spaces and corners carry the subspace diffeology of Rn\mathbb{R}^n; the quotients carry the quotient diffeology.
models M\mathcal M spaces modelled on M\mathcal M reference
Rn\mathbb{R}^n manifolds [IZ, art. 4.1–4.3]
half-spaces Hn=Rn−1×[0,∞)H^n=\mathbb{R}^{n-1}\times[0,\infty) manifolds with boundary [IZ, art. 4.12–4.16]
corners Rn−k×[0,∞)k\mathbb{R}^{n-k}\times[0,\infty)^k manifolds with corners [22]
Rn/Γ\mathbb{R}^n/\Gamma, Γ⊂GL⁡n(R)\Gamma\subset\operatorname{GL}_n(\mathbb{R}) finite orbifolds [IZ, art. 4.17], [30]
Rn/Γ\mathbb{R}^n/\Gamma, Γ\Gamma countable, affine quasifolds [34]
diffeological vector spaces diffeological manifolds, e.g. S∞S^\infty [IZ, art. 4.7–4.9]
Five local models. The first three are subspaces of R2\mathbb{R}^2, the last two are quotients. Only the first is a manifold; all five are diffeological spaces, and each is determined up to diffeomorphism by its plots.

Manifolds, boundaries, corners

A diffeological space is a manifold of dimension nn exactly when it is modelled on Rn\mathbb{R}^n, and smooth maps between manifolds are the usual ones ([exo:manifold-atlas]). For manifolds with boundary there is something to prove, because the model HnH^n is a subspace and its diffeology is defined by plots into it, while the classical notion of a smooth function on it is “restriction of a smooth function on Rn\mathbb{R}^n”.

Theorem 1.1 ([IZ, art. 4.13, 4.16]). A map f ⁣:Hn→Rf\colon H^n\to\mathbb{R} is smooth for the subspace diffeology if and only if it is the restriction of a smooth function on an open neighbourhood of HnH^n in Rn\mathbb{R}^n. Consequently manifolds with boundary, with their classical smooth maps, form a full subcategory of Diff\mathsf{Diff}.

The essential case is n=1n=1 and is [exo:halfline-functions]; it rests on Whitney’s theorem that a smooth even function of tt is a smooth function of t2t^2 [57]. The same holds for corners [22]. In the language of Two images: the classical definition of a manifold with boundary is in terms of its functions, the diffeological one in terms of its plots, and by Whitney’s theorem, for half-spaces the two descriptions determine each other; see 1.4.

Orbifolds and quasifolds

A diffeological orbifold is a space modelled on quotients Rn/Γ\mathbb{R}^n/\Gamma by finite linear groups [30]. A priori the model is only the orbit space. In fact it determines the group.

Theorem 1.2 (Iglesias-Zemmour–Karshon–Zadka [30). ; [IZ, art. 4.18]]Let Γ,Γ′⊂GL⁡n(R)\Gamma,\Gamma'\subset\operatorname{GL}_n(\mathbb{R}) be finite subgroups. Every local diffeomorphism from Rn/Γ\mathbb{R}^n/\Gamma to Rn/Γ′\mathbb{R}^n/\Gamma' sending [0][0] to [0][0] lifts to an equivariant local diffeomorphism of Rn\mathbb{R}^n at 00; in particular Γ\Gamma and Γ′\Gamma' are conjugate in GL⁡n(R)\operatorname{GL}_n(\mathbb{R}). Hence the structure group of an orbifold at a point is a diffeological invariant.

Corollary 1.3. Let Γ⊂GL⁡n(R)\Gamma\subset\operatorname{GL}_n(\mathbb{R}) be a finite subgroup. The point [0]∈Rn/Γ[0]\in\mathbb{R}^n/\Gamma has a neighbourhood diffeomorphic to an open subset of Rn\mathbb{R}^n if and only if Γ\Gamma is trivial.

Note the contrast with topology and with algebraic geometry: R/{±1}\mathbb{R}/\{\pm1\} is homeomorphic to a half-line, and C/{±1}\mathbb{C}/\{\pm1\} is isomorphic to C\mathbb{C} as a variety, but neither quotient is a diffeological manifold near the fixed point ([exo:delta1-singular]).

In the trichotomy of Theorem 1.8, with X=RnX=\mathbb{R}^n and G=ΓG=\Gamma, an orbifold chart has three incarnations: the stack Rn/ ⁣ ⁣/Γ\mathbb{R}^n/\!\!/\Gamma of the Lie-groupoid literature, the sheaf quotient, and the diffeological space Rn/Γ\mathbb{R}^n/\Gamma. By 1.2, for finite linear groups the last determines the first up to equivalence, locally. The determination is not functorial: the map from morphisms of stacks to smooth maps of quotients is neither injective nor, on 22-cells, defined; see [56]. A diffeological orbifold is a stack that is recoverable from its coarse space, in the way a reduced variety is recoverable from its points.

Quasifolds relax “finite” to “countable” [34]. The irrational torus is the basic example, and Theorem 1.1 is the corresponding rigidity statement: the diffeology of Rn/Γ\mathbb{R}^n/\Gamma determines Γ\Gamma up to GL⁡n(R)\operatorname{GL}_n(\mathbb{R}).

Functions versus plots

A diffeology is a “maps in” structure. The older notions of Sikorski and Frölicher are “maps out” structures, given by a ring of real-valued functions. Each determines a candidate for the other: from plots one gets the functions that are smooth along all plots; from functions one gets the parametrisations along which all functions are smooth. A diffeological space is reflexive if it is recovered from its functions in this way. Manifolds, half-spaces and corners are reflexive. The irrational torus is as far from reflexive as possible, since its only smooth functions are constants; and Δ1=R/{±1}\Delta_1=\mathbb{R}/\{\pm1\} is not reflexive either, since it has the same smooth functions as the half-line HH and strictly fewer plots (Proposition 1.11). This is developed as a Galois connection in Theorem 1.4 of Artificial intelligence: planning, observation, semantics, and Theorem 1.5 is the equivalence of reflexive diffeological spaces with Frölicher spaces [4]. The point for now is the slogan of [1]: function-based smooth structures miss the singular quotients, and the reason is that a quotient is a colimit, and maps out of a colimit are easy while maps in are the content.

Infinite dimensions and dimension

On the other side of Mfd\mathsf{Mfd}, the functional diffeology is compatible with the classical infinite-dimensional theories where these exist. Banach manifolds embed fully faithfully in Diff\mathsf{Diff} [IZ, Exercise 72]; so do Fréchet manifolds [41]; and for a compact manifold MM the functional diffeology on C∞(M,N)C^{\infty}(M,N) is the diffeology of its Fréchet manifold structure [39, 54]. In contrast with those theories, in Diff\mathsf{Diff} no topology on a function space is required to define a smooth curve in it: Theorem 1.9 is the definition.

Finally, a diffeological space has a dimension at each point: the smallest dd such that the germ of the diffeology at the point is generated by plots with domains of dimension at most dd [IZ, art. 1.78, 2.22]. It is a local invariant, equal to nn for an nn-manifold, and [IZ, Exercises 50–51] compute dim⁡[0](Rn/O⁡(n))=n,dim⁡0([0,∞)sub)=∞.\dim_{[0]}\bigl(\mathbb{R}^n/\operatorname{O}(n)\bigr)=n,\qquad\dim_0\bigl([0,\infty)_{\mathrm{sub}}\bigr)=\infty . So the spaces Δn\Delta_n, all homeomorphic to a half-line and all with the same ring of smooth functions, are pairwise non-diffeomorphic, and none is diffeomorphic to the half-line HH. We will use this in Chapters Machine learning: differentiable programs and singular hypothesis spaces and System design: state spaces, quotients, clocks as a supply of systems with identical observable behaviour and inequivalent state spaces.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Show that x↦xx\mapsto\sqrt x is a D-continuous function on H=[0,∞)subH=[0,\infty)_{\mathrm{sub}} that is not smooth.

Solution.  It is continuous for the usual topology of HH, and plots of HH are continuous, so it is D-continuous. The parametrisation t↦t2t\mapsto t^2 is a plot of HH, and its composite with the square root is t↦∣t∣t\mapsto\lvert t\rvert, not smooth at 00. ◀\blacktriangleleft

2 Prove the case n=1n=1 of 1.1: f ⁣:H→Rf\colon H\to\mathbb{R} is smooth iff f=g∣Hf=g|_H for some g∈C∞(R)g\in C^{\infty}(\mathbb{R}). Deduce that C∞(Δ1)≅C∞(H)C^{\infty}(\Delta_1)\cong C^{\infty}(H).

Solution.  If gg is smooth on R\mathbb{R} and PP is a plot of HH, then PP is smooth into R\mathbb{R} and g∘Pg\circ P is smooth. Conversely let ff be smooth on HH. The plot t↦t2t\mapsto t^2 gives a smooth even function e(t)=f(t2)e(t)=f(t^2), so by Whitney’s theorem e(t)=g(t2)e(t)=g(t^2) with g∈C∞(R)g\in C^{\infty}(\mathbb{R}), and then f(x)=g(x)f(x)=g(x) for all x≥0x\ge0. For the second claim: a smooth function on Δ1\Delta_1 is the same as a smooth even function on R\mathbb{R} (quotient), hence of the form g(x2)g(x^2), hence g∣H∘sqg|_H\circ\mathrm{sq}; so sq∗ ⁣:C∞(H)→C∞(Δ1)\mathrm{sq}^*\colon C^{\infty}(H)\to C^{\infty}(\Delta_1) is a bijection. The two spaces have the same functions and, by Proposition 1.11, different plots. ◀\blacktriangleleft

3 Show that [0]∈Δ1=R/{±1}[0]\in\Delta_1=\mathbb{R}/\{\pm1\} has no D-open neighbourhood diffeomorphic to an open interval. Deduce that every diffeomorphism of Δ1\Delta_1 fixes [0][0].

Solution.  Suppose ψ ⁣:J→W\psi\colon J\to W is a diffeomorphism from an open interval onto a D-open neighbourhood WW of [0][0], and let ψ(t0)=[0]\psi(t_0)=[0]. As a plot of Δ1\Delta_1, ψ\psi lifts near t0t_0 to a smooth f ⁣:J′→Rf\colon J'\to\mathbb{R} with π∘f=ψ\pi\circ f=\psi and f(t0)=0f(t_0)=0. Since ψ\psi is injective, so is ff; a continuous injective function on an interval is strictly monotone, so f(J′)f(J') is an open interval containing 00, and therefore contains both xx and −x-x for small x≠0x\ne0. But π(x)=π(−x)\pi(x)=\pi(-x), contradicting injectivity of ψ=π∘f\psi=\pi\circ f. Every other point [a][a], a>0a>0, does have such a neighbourhood, namely π((a/2,2a))\pi((a/2,2a)), on which π\pi restricts to a diffeomorphism. A diffeomorphism of Δ1\Delta_1 preserves the set of points with a neighbourhood diffeomorphic to an interval, so it fixes the unique point without one. ◀\blacktriangleleft

3 Let {±1}\{\pm1\} act on R2=C\mathbb{R}^2=\mathbb{C} and let σ ⁣:C→R3\sigma\colon\mathbb{C}\to\mathbb{R}^3, σ(z)=(∣z∣2,Re z2,Im z2)\sigma(z)=(\lvert z\rvert^2,\mathrm{Re}\,z^2,\mathrm{Im}\,z^2), with image the half-cone S={ (u,v,w):u=v2+w2 }S=\{\,(u,v,w) : u=\sqrt{v^2+w^2}\,\}. Show that the induced bijection σˉ ⁣:C/{±1}→Ssub\bar\sigma\colon\mathbb{C}/\{\pm1\}\to S_{\mathrm{sub}} is smooth but not a diffeomorphism.

Solution.  σ\sigma is smooth, invariant, and separates orbits because z2z^2 determines ±z\pm z; so σˉ\bar\sigma is a smooth bijection onto SS. Consider P(r,s)=(∣z∣ e−1/∣z∣2, Re (z e−1/∣z∣2), Im (z e−1/∣z∣2)),z=r+is,P(0)=0.P(r,s)=\bigl(\lvert z\rvert\,e^{-1/\lvert z\rvert^2},\ \mathrm{Re}\,(z\,e^{-1/\lvert z\rvert^2}),\ \mathrm{Im}\,(z\,e^{-1/\lvert z\rvert^2})\bigr),\qquad z=r+is,\quad P(0)=0 . The function e−1/∣z∣2e^{-1/\lvert z\rvert^2} is smooth and flat at 00, and the product of a flat function with ∣z∣\lvert z\rvert is smooth; so PP is a smooth map into R3\mathbb{R}^3, with values in SS: a plot of SsubS_{\mathrm{sub}}. If σˉ−1∘P\bar\sigma^{-1}\circ P were a plot of the quotient, there would be a disc V∋0V\ni0 and a smooth ζ ⁣:V→C\zeta\colon V\to\mathbb{C} with ζ2=z e−1/∣z∣2\zeta^2=z\,e^{-1/\lvert z\rvert^2} on VV. On a small circle around 00 the right-hand side has winding number 11 about the origin, while ζ2\zeta^2 has even winding number. So no continuous ζ\zeta exists even on V∖{0}V\smallsetminus\{0\}. Thus SsubS_{\mathrm{sub}} has a plot that the orbifold C/{±1}\mathbb{C}/\{\pm1\} lacks: the image of the invariant-theoretic embedding has strictly more plots than the orbit space. ◀\blacktriangleleft

4 Let XX be a diffeological space modelled on Rn\mathbb{R}^n. Prove that the local diffeomorphisms from open subsets of Rn\mathbb{R}^n to XX form a smooth atlas in the classical sense, that the diffeology of XX is the diffeology of smooth parametrisations for this atlas, and that a map between two such spaces is smooth iff it is smooth in charts.

Solution.  Call a chart a diffeomorphism ϕ ⁣:U→ϕ(U)\phi\colon U\to\phi(U) from a domain U⊆RnU\subseteq\mathbb{R}^n onto a D-open subset of XX with the subspace diffeology. By hypothesis the images of charts cover XX.

Transition maps. Let ϕ,ψ\phi,\psi be charts and W=ϕ(U)∩ψ(V)W=\phi(U)\cap\psi(V), which is D-open. Then ϕ−1(W)\phi^{-1}(W) and ψ−1(W)\psi^{-1}(W) are open, because charts are plots and plots are D-continuous, and ψ−1∘ϕ ⁣:ϕ−1(W)→ψ−1(W)\psi^{-1}\circ\phi\colon\phi^{-1}(W)\to\psi^{-1}(W) is a composite of smooth maps of diffeological spaces, with inverse ϕ−1∘ψ\phi^{-1}\circ\psi. A smooth map between domains in the diffeological sense is an ordinary smooth map (Remark 1.2). So the transition maps are classical diffeomorphisms between open subsets of Rn\mathbb{R}^n; the charts are homeomorphisms onto their images for the D-topology by the same argument; and we have a classical atlas on the topological space D(X)D(X).

The diffeology. Let P ⁣:O→XP\colon O\to X be a parametrisation. If PP is a plot and r0∈Or_0\in O, choose a chart ϕ\phi around P(r0)P(r_0); P−1(ϕ(U))P^{-1}(\phi(U)) is an open neighbourhood of r0r_0 on which ϕ−1∘P\phi^{-1}\circ P is a plot of UU, i.e. smooth. So PP is smooth in charts. Conversely if PP is continuous and smooth in charts, then locally P=ϕ∘(ϕ−1∘P)P=\phi\circ(\phi^{-1}\circ P) is a plot composed with a smooth map, hence a plot, and PP is a plot by [D2].

Maps. Let f ⁣:X→Yf\colon X\to Y be a map between two such spaces. If ff is smooth then it is D-continuous and, for charts ϕ\phi of XX and ψ\psi of YY, ψ−1∘f∘ϕ\psi^{-1}\circ f\circ\phi is a smooth map of diffeological spaces between domains wherever defined, hence classically smooth. Conversely if ff is continuous and smooth in charts, then for a plot PP of XX the parametrisation f∘Pf\circ P is continuous and smooth in charts of YY, hence a plot by the previous paragraph.

Classical manifolds also require the topology to be Hausdorff and paracompact; these are conditions on D(X)D(X) that are optional in the diffeological definition. ◀\blacktriangleleft

Applications

Number theory: the arithmetic of irrational tori

The diffeological space Tα=R/(Z+αZ)T_{\alpha}=\mathbb{R}/(\mathbb{Z}+\alpha\mathbb{Z}) is a point for topology and for smooth functions. We show that its plots nevertheless read off three layers of the arithmetic of α\alpha: its orbit under GL⁡2(Z)\operatorname{GL}_2(\mathbb{Z}), that is, the tail of its continued fraction; the unit group of the quadratic order it generates, if any; and its Diophantine type. Each layer is a theorem about a different functor on H\mathbf{H} — Hom⁡\operatorname{Hom}, Diff⁡\operatorname{Diff}, and Map⁡(−,BR)\operatorname{Map}(-,\mathbf{B}\mathbb{R}) — applied to the same object.

Source in the book. [IZ, Exercises 4, 5, 105, 119, 134] and [IZ, art. 8.38–8.39]. The classification is due to Donato and Iglesias [16], the number-field generalisation to Iglesias and Lachaud [31], and the theory of flows over TαT_{\alpha} to Iglesias-Zemmour [28, 29, 33].

Rigidity

Throughout, a quasi-torus is a quotient TΓ=Rn/ΓT_\Gamma=\mathbb{R}^n/\Gamma of Rn\mathbb{R}^n by a countable subgroup, with the quotient diffeology. By Corollary 1.5 the projection q ⁣:Rn→TΓq\colon\mathbb{R}^n\to T_\Gamma is the universal covering, a principal bundle for the discrete group Γ\Gamma.

Theorem 1.1 (Linear rigidity of quasi-tori; after [16, 31). ]Let Γ⊂Rn\Gamma\subset\mathbb{R}^n and Γ′⊂Rm\Gamma'\subset\mathbb{R}^m be countable subgroups, and assume that Γ\Gamma spans Rn\mathbb{R}^n. Let f ⁣:TΓ→TΓ′f\colon T_\Gamma\to T_{\Gamma'} be smooth.

  1. There are a smooth F ⁣:Rn→RmF\colon\mathbb{R}^n\to\mathbb{R}^m with q′∘F=f∘qq'\circ F=f\circ q, unique up to a constant in Γ′\Gamma', and a unique linear map A ⁣:Rn→RmA\colon\mathbb{R}^n\to\mathbb{R}^m, such that F(x+γ)=F(x)+Aγ(x∈Rn, γ∈Γ).F(x+\gamma)=F(x)+A\gamma\qquad(x\in\mathbb{R}^n,\ \gamma\in\Gamma). In particular AΓ⊆Γ′A\Gamma\subseteq\Gamma', and F−AF-A is bounded.

  2. If Γ\Gamma is dense in Rn\mathbb{R}^n then FF is affine: F(x)=Ax+cF(x)=Ax+c.

  3. If Γ′\Gamma' spans Rm\mathbb{R}^m and ff is a diffeomorphism, then n=mn=m, A∈GL⁡n(R)A\in\operatorname{GL}_n(\mathbb{R}) and AΓ=Γ′A\Gamma=\Gamma'.

Consequently two quasi-tori with spanning groups are diffeomorphic if and only if the groups are linearly equivalent: Rn/Γ≅Rn/Γ′  ⟺  Γ′=AΓ  for some A∈GL⁡n(R).\mathbb{R}^n/\Gamma\cong\mathbb{R}^n/\Gamma'\iff\Gamma'=A\Gamma\ \text{ for some }A\in\operatorname{GL}_n(\mathbb{R}).

Proof. (a) Lifting. The composite f∘qf\circ q is a plot of TΓ′T_{\Gamma'} with simply connected domain, so it lifts through q′q' to a smooth FF, unique up to a constant of Γ′\Gamma'; this is the argument of [exo:higher-TGamma]. The homomorphism. For γ∈Γ\gamma\in\Gamma, the map x↦F(x+γ)−F(x)x\mapsto F(x+\gamma)-F(x) is continuous with values in the countable set Γ′\Gamma', because both terms lift f∘qf\circ q. So it is a constant ϕ(γ)\phi(\gamma), and ϕ ⁣:Γ→Γ′\phi\colon\Gamma\to\Gamma' is a homomorphism. Linearity. Choose γ1,…,γn∈Γ\gamma_1,\dots,\gamma_n\in\Gamma forming a basis of Rn\mathbb{R}^n and let AA be the linear map with Aγi=ϕ(γi)A\gamma_i=\phi(\gamma_i). The function G=F−AG=F-A is invariant under the lattice L=⨁ZγiL=\bigoplus\mathbb{Z}\gamma_i, hence bounded. For γ∈Γ\gamma\in\Gamma and k∈Zk\in\mathbb{Z}, G(x+kγ)−G(x)=k(ϕ(γ)−Aγ),G(x+k\gamma)-G(x)=k\bigl(\phi(\gamma)-A\gamma\bigr), and the left side is bounded in kk; so ϕ(γ)=Aγ\phi(\gamma)=A\gamma. Uniqueness of AA is clear since Γ\Gamma spans.

(b) G=F−AG=F-A is continuous and invariant under the dense subgroup Γ\Gamma, hence constant.

(c) Apply (a) to f−1f^{-1} to get F′F' and A′A'. Then F′∘FF'\circ F lifts the identity of TΓT_\Gamma, so F′(F(x))=x+γ0F'(F(x))=x+\gamma_0, and comparing the effect of translating xx by γ∈Γ\gamma\in\Gamma gives A′Aγ=γA'A\gamma=\gamma. As Γ\Gamma spans, A′A=idA'A=\mathrm{id}; symmetrically AA′=idAA'=\mathrm{id}. So n=mn=m, and AΓ⊆Γ′A\Gamma\subseteq\Gamma', A′Γ′⊆ΓA'\Gamma'\subseteq\Gamma give AΓ=Γ′A\Gamma=\Gamma'. Conversely a linear isomorphism with AΓ=Γ′A\Gamma=\Gamma' descends to a diffeomorphism, with inverse induced by A−1A^{-1}. ◻

For Γ\Gamma a lattice the theorem recovers the familiar fact that all nn-tori are diffeomorphic, all lattices in Rn\mathbb{R}^n being linearly equivalent. Its force is in rank greater than nn, where the quotient determines the position of Γ\Gamma in Rn\mathbb{R}^n exactly up to GL⁡n(R)\operatorname{GL}_n(\mathbb{R}). In rank 22 and dimension 11:

Corollary 1.2 (Donato–Iglesias [16). ; [IZ, Exercise 4]]Let α,β\alpha,\beta be irrational.

  1. C∞(Tα,Tβ)≅{ λ∈R:λΛα⊆Λβ }×TβC^{\infty}(T_{\alpha},T_\beta)\cong\{\,\lambda\in\mathbb{R}: \lambda\Lambda_\alpha\subseteq\Lambda_\beta\,\}\times T_\beta, a smooth map being [x]↦[λx+c][x]\mapsto[\lambda x+c].

  2. Tα≅TβT_{\alpha}\cong T_\beta if and only if α=aβ+bcβ+d\alpha=\dfrac{a\beta+b}{c\beta+d} for some (abcd)∈GL⁡2(Z)\begin{pmatrix}a&b\\c&d\end{pmatrix}\in\operatorname{GL}_2(\mathbb{Z}).

  3. (Serret; [24, Thm. 175]) Equivalently: the continued fraction expansions of α\alpha and β\beta eventually coincide, up to a shift.

Proof. (i) is 1.1(a),(b) with n=m=1n=m=1. (ii) By (c), Tα≅TβT_{\alpha}\cong T_\beta iff λΛα=Λβ\lambda\Lambda_\alpha=\Lambda_\beta for some λ≠0\lambda\ne0, iff (λ,λα)(\lambda,\lambda\alpha) is a Z\mathbb{Z}-basis of Z+βZ\mathbb{Z}+\beta\mathbb{Z}, iff λ=cβ+d\lambda=c\beta+d and λα=aβ+b\lambda\alpha=a\beta+b with ad−bc=±1ad-bc=\pm1. ◻

Continued fractions as diffeological invariants. Tori whose expansions have a common tail are diffeomorphic (1.2). The last two rows are the two classes with real multiplication by Z[10]\mathbb{Z}[\sqrt{10}], an order of class number 22 ([exo:sqrt10]).

Endomorphisms, units, and real multiplication

For irrational α\alpha put Oα={ λ∈R:λΛα⊆Λα },\mathcal O_\alpha=\{\,\lambda\in\mathbb{R}: \lambda\Lambda_\alpha\subseteq\Lambda_\alpha\,\}, a subring of R\mathbb{R}. By 1.2(i) it is the ring of smooth endomorphisms of the group TαT_{\alpha}, and also the monoid of smooth self-maps fixing 00: on an irrational torus every smooth map is a homomorphism up to translation.

Theorem 1.3 (Endomorphisms and diffeomorphisms; after [16). ]

  1. If α\alpha is not a quadratic irrational, Oα=Z\mathcal O_\alpha=\mathbb{Z}.

  2. If Aα2+Bα+C=0A\alpha^2+B\alpha+C=0 with A,B,CA,B,C coprime integers and D=B2−4ACD=B^2-4AC, then Oα=Z+ZAα\mathcal O_\alpha=\mathbb{Z}+\mathbb{Z}A\alpha is the order of discriminant DD in the real quadratic field Q(D)\mathbb{Q}(\sqrt D).

  3. Diff⁡(Tα)≅Tα⋊Oα×\operatorname{Diff}(T_{\alpha})\cong T_{\alpha}\rtimes\mathcal O_\alpha^\times as diffeological groups, with Oα×\mathcal O_\alpha^\times discrete. Hence the identity component of Diff⁡(Tα)\operatorname{Diff}(T_{\alpha}) is the group of translations and π0Diff⁡(Tα)≅Oα×≅{{±1}α not quadratic,{±1}×Zα quadratic.\pi_0\operatorname{Diff}(T_{\alpha})\cong\mathcal O_\alpha^\times\cong\begin{cases}\{\pm1\}&\alpha\text{ not quadratic,}\\ \{\pm1\}\times\mathbb{Z}&\alpha\text{ quadratic.}\end{cases}

Proof. Let λ∈Oα\lambda\in\mathcal O_\alpha. Then λ=λ⋅1∈Λα\lambda=\lambda\cdot1\in\Lambda_\alpha, say λ=x+yα\lambda=x+y\alpha with x,y∈Zx,y\in\mathbb{Z}, and λα=xα+yα2∈Λα\lambda\alpha=x\alpha+y\alpha^2\in\Lambda_\alpha iff yα2∈Z+Zαy\alpha^2\in\mathbb{Z}+\mathbb{Z}\alpha.

(i) If y≠0y\ne0 this makes α\alpha quadratic. So y=0y=0 and λ∈Z\lambda\in\mathbb{Z}.

(ii) Here yα2=−y(Bα+C)/Ay\alpha^2=-y(B\alpha+C)/A, and since 1,α1,\alpha are linearly independent over Q\mathbb{Q} this lies in Z+Zα\mathbb{Z}+\mathbb{Z}\alpha iff A∣yBA\mid yB and A∣yCA\mid yC, iff A∣ygcd⁡(B,C)A\mid y\gcd(B,C), iff A∣yA\mid y because gcd⁡(A,B,C)=1\gcd(A,B,C)=1. So Oα=Z+ZAα\mathcal O_\alpha=\mathbb{Z}+\mathbb{Z}A\alpha. The number AαA\alpha is a root of t2+Bt+ACt^2+Bt+AC, an algebraic integer of discriminant DD, so Z[Aα]\mathbb{Z}[A\alpha] is the order of discriminant DD.

(iii) By 1.2(i) every smooth self-map is [x]↦[λx+c][x]\mapsto[\lambda x+c] with λ∈Oα\lambda\in\mathcal O_\alpha, and it is invertible iff λ∈Oα×\lambda\in\mathcal O_\alpha^\times. This gives the group isomorphism. For the diffeology, let r↦frr\mapsto f_r be a plot of Diff⁡(Tα)\operatorname{Diff}(T_{\alpha}) on a ball VV. Then (r,x)↦fr(qα(x))(r,x)\mapsto f_r(q_\alpha(x)) is a plot of TαT_{\alpha} on the simply connected V×RV\times\mathbb{R}; it lifts to a smooth F(r,x)=λ(r)x+c(r)F(r,x)=\lambda(r)x+c(r), and λ=∂xF\lambda=\partial_xF is continuous with values in a countable set, hence constant, while cc is smooth. Conversely such families are plots. So Diff⁡(Tα)≅Tα×Oα×\operatorname{Diff}(T_{\alpha})\cong T_{\alpha}\times\mathcal O_\alpha^\times as diffeological spaces with the second factor discrete, and TαT_{\alpha} is connected. Finally the unit group of an order in a real quadratic field is {±εk}\{\pm\varepsilon^k\} for a fundamental unit ε>1\varepsilon>1, by Dirichlet’s unit theorem; equivalently by the solvability of Pell’s equation. ◻

A torus TαT_{\alpha} with α\alpha quadratic is said to have real multiplication by Oα\mathcal O_\alpha, by analogy with complex multiplication of elliptic curves C/Λ\mathbb{C}/\Lambda; the analogy is Manin’s [43], and is developed in Cryptography: real multiplication, class groups, lattices. Geometrically: a quadratic irrational torus has a hyperbolic symmetry — multiplication by ε\varepsilon — not isotopic to ±id\pm\mathrm{id}, and a non-quadratic one has none.

Example 1.4.

  1. α=φ=(1+5)/2\alpha=\varphi=(1+\sqrt5)/2: O=Z[φ]\mathcal O=\mathbb{Z}[\varphi], ε=φ\varepsilon=\varphi. On π1(Tφ)=Z⊕Zφ\pi_1(T_\varphi)=\mathbb{Z}\oplus\mathbb{Z}\varphi multiplication by φ\varphi is the matrix , and φk\varphi^k acts by Fibonacci numbers ([exo:golden]).

  2. α=2\alpha=\sqrt2: O=Z[2]\mathcal O=\mathbb{Z}[\sqrt2], ε=1+2\varepsilon=1+\sqrt2.

  3. α=79\alpha=\sqrt{79}: O=Z[79]\mathcal O=\mathbb{Z}[\sqrt{79}], ε=80+979≈160\varepsilon=80+9\sqrt{79}\approx160. The smallest non-trivial symmetry of T79T_{\sqrt{79}} stretches by a factor of 160160.

  4. α=23\alpha=\sqrt[3]2 or α=π\alpha=\pi: π0Diff⁡(Tα)={±1}\pi_0\operatorname{Diff}(T_{\alpha})=\{\pm1\}.

Proposition 1.5 (Number fields, after [31). ]Let K⊂RK\subset\mathbb{R} be a number field of degree d≥2d\ge2 with r1r_1 real and r2r_2 pairs of complex embeddings, and let O⊂K\mathcal O\subset K be an order. Then TO=R/OT_{\mathcal O}=\mathbb{R}/\mathcal O is a one-dimensional diffeological group with Π TO≃BZd,End⁡(TO)≅O,π0Diff⁡(TO)≅O×≅{±1}×Z r1+r2−1.\Pi\,T_{\mathcal O}\simeq\mathbf{B}\mathbb{Z}^d,\qquad\operatorname{End}(T_{\mathcal O})\cong\mathcal O,\qquad\pi_0\operatorname{Diff}(T_{\mathcal O})\cong\mathcal O^\times\cong\{\pm1\}\times\mathbb{Z}^{\,r_1+r_2-1}.

Proof. O\mathcal O is free of rank d≥2d\ge2, hence dense in R\mathbb{R}, and countable. The shape is Corollary 1.5. By 1.1(b) smooth self-maps are [x]↦[λx+c][x]\mapsto[\lambda x+c] with λO⊆O\lambda\mathcal O\subseteq\mathcal O; since 1∈O1\in\mathcal O this means λ∈O\lambda\in\mathcal O. The argument of 1.3(iii) gives π0Diff⁡=O×\pi_0\operatorname{Diff}=\mathcal O^\times, and Dirichlet’s theorem gives its structure, the only roots of unity in a real field being ±1\pm1. ◻

So the unit rank of a number field with a real place is the rank of the mapping class group of a one-dimensional diffeological space, and the degree of the field is the rank of its fundamental group. Neither is determined by the D-topology or by the smooth real functions of R/O\mathbb{R}/\mathcal O.

Diophantine type and principal R\mathbb{R}-bundles

We now compute the first obstruction group of Theorem 1.8, the group Fl⁡(Tα)=H1(Tα;R)\operatorname{Fl}(T_{\alpha})=H^1(T_{\alpha};\mathbb{R}) of isomorphism classes of principal R\mathbb{R}-bundles. Write ∥t∥\lVert t\rVert for the distance from t∈Rt\in\mathbb{R} to the nearest integer. An irrational α\alpha is Diophantine if there are c>0c>0 and τ≥1\tau\ge1 with ∥nα∥≥c ∣n∣−τ\lVert n\alpha\rVert\ge c\,\lvert n\rvert^{-\tau} for all n≠0n\ne0, and Liouville otherwise. Almost every real number is Diophantine, and so is every algebraic irrational, by Liouville’s theorem.

Lemma 1.6 (The cohomological equation on the line). For every g∈C∞(R)g\in C^{\infty}(\mathbb{R}) there is f∈C∞(R)f\in C^{\infty}(\mathbb{R}) with f(x+1)−f(x)=g(x)f(x+1)-f(x)=g(x), and ff is unique up to a 11-periodic function. The same holds for differential forms on R\mathbb{R}. Hence H1(Z;Ωp(R))=0H^1(\mathbb{Z};\Omega^p(\mathbb{R}))=0 and H0(Z;Ωp(R))=Ωp(S1)H^0(\mathbb{Z};\Omega^p(\mathbb{R}))=\Omega^p(S^1) for the translation action.

Proof. Let χ\chi be smooth with χ=0\chi=0 on (−∞,0](-\infty,0] and χ=1\chi=1 on [1,∞)[1,\infty), and split g=g++g−g=g_++g_- with g+=χgg_+=\chi g supported in [0,∞)[0,\infty) and g−=(1−χ)gg_-=(1-\chi)g supported in (−∞,1](-\infty,1]. Put f+(x)=∑k≥1g+(x−k),f−(x)=−∑k≥0g−(x+k).f_+(x)=\sum_{k\ge1}g_+(x-k),\qquad f_-(x)=-\sum_{k\ge0}g_-(x+k). Both sums are locally finite, so f±f_\pm are smooth, and telescoping gives f±(x+1)−f±(x)=g±(x)f_\pm(x+1)-f_\pm(x)=g_\pm(x). Take f=f++f−f=f_++f_-. Two solutions differ by a periodic function. For a 11-form g dxg\,\mathrm{d}x use f dxf\,\mathrm{d}x. ◻

Theorem 1.7 (Flows over the irrational torus; Iglesias-Zemmour [29, 33). , [IZ, art. 8.39]]Let ρα\rho_\alpha be the rotation x↦x+αx\mapsto x+\alpha of S1=R/ZS^1=\mathbb{R}/\mathbb{Z}. Then Fl⁡(Tα)  ≅  H1(Λα;C∞(R))  ≅  C∞(S1)/(ρα∗−1) C∞(S1)  =  R ⊕ C0∞(S1)(ρα∗−1)C∞(S1),\operatorname{Fl}(T_{\alpha})\;\cong\;H^1\bigl(\Lambda_\alpha;C^{\infty}(\mathbb{R})\bigr)\;\cong\;C^{\infty}(S^1)\big/(\rho_\alpha^*-1)\,C^{\infty}(S^1)\;=\;\mathbb{R}\,\oplus\,\frac{C^{\infty}_0(S^1)}{(\rho_\alpha^*-1)C^{\infty}(S^1)}, where C0∞C^{\infty}_0 denotes functions of mean zero and the summand R\mathbb{R} is the mean. Moreover:

  1. the summand R\mathbb{R} is the group E20,1E_2^{0,1} of flat bundles of Proposition 1.9, and consists of the Kronecker bundle T2→TαT^2\to T_{\alpha} with its flow run at all constant speeds;

  2. the second summand is zero if and only if α\alpha is Diophantine;

  3. if α\alpha is Liouville, the second summand is an infinite-dimensional real vector space.

The automorphism group of every principal R\mathbb{R}-bundle over TαT_{\alpha} is R\mathbb{R}.

Proof. Reduction to group cohomology. By Corollary 1.7 with G=RG=\mathbb{R}, Map⁡(Tα,BR)≃(BC∞(R))hΛα\operatorname{Map}(T_{\alpha},\mathbf{B}\mathbb{R})\simeq(\mathbf{B}C^{\infty}(\mathbb{R}))^{h\Lambda_\alpha}, whose set of components is H1(Λα;C∞(R))H^1(\Lambda_\alpha;C^{\infty}(\mathbb{R})) and whose automorphism groups are H0(Λα;C∞(R))H^0(\Lambda_\alpha;C^{\infty}(\mathbb{R})), the Λα\Lambda_\alpha-periodic smooth functions, which are constant. Splitting Λα=Z⊕Zα\Lambda_\alpha=\mathbb{Z}\oplus\mathbb{Z}\alpha and using 1.6 for the first factor, the Lyndon–Hochschild–Serre sequence collapses to H1(Λα;C∞(R))≅H1(Zα;C∞(S1))=C∞(S1)/(ρα∗−1)H^1(\Lambda_\alpha;C^{\infty}(\mathbb{R}))\cong H^1(\mathbb{Z}\alpha;C^{\infty}(S^1))=C^{\infty}(S^1)/(\rho_\alpha^*-1); an elementary proof is [exo:LHS]. Under this isomorphism a function gg corresponds to the cocycle τ(m+nα)=∑k=0n−1g∘ραk\tau(m+n\alpha)=\sum_{k=0}^{n-1}g\circ\rho_\alpha^k for n≥0n\ge0.

Fourier analysis. Write g=∑ng^ne2πinxg=\sum_n\hat g_ne^{2\pi inx}. Then g=f∘ρα−fg=f\circ\rho_\alpha-f iff g^n=(e2πinα−1)f^n\hat g_n=(e^{2\pi in\alpha}-1)\hat f_n for all nn. So a coboundary has g^0=0\hat g_0=0, and for gg of mean zero the only candidate is f^n=g^ne2πinα−1(n≠0),4∥nα∥≤∣e2πinα−1∣=2∣sin⁡πnα∣≤2π∥nα∥.\hat f_n=\frac{\hat g_n}{e^{2\pi in\alpha}-1}\quad(n\ne0),\qquad 4\lVert n\alpha\rVert\le\lvert e^{2\pi in\alpha}-1\rvert=2\lvert \sin\pi n\alpha\rvert\le2\pi\lVert n\alpha\rVert. (i) The constant g=cg=c gives τ(m+nα)=nc\tau(m+n\alpha)=nc, the flat bundle XρX_\rho with holonomy ρ(m+nα)=nc\rho(m+n\alpha)=nc; for c=−1c=-1 this is the Kronecker bundle by [exo:kronecker-class], and it is not a coboundary since its mean is not zero.

(ii) If ∥nα∥≥c∣n∣−τ\lVert n\alpha\rVert\ge c\lvert n\rvert^{-\tau}, then ∣f^n∣≤∣n∣τ∣g^n∣/4c\lvert \hat f_n\rvert\le\lvert n\rvert^\tau\lvert \hat g_n\rvert/4c is rapidly decreasing whenever g^n\hat g_n is, so every smooth gg of mean zero is a coboundary.

(iii) If α\alpha is Liouville then for each kk there are infinitely many nn with ∥nα∥<n−k\lVert n\alpha\rVert<n^{-k}: otherwise the finitely many exceptions could be absorbed into the constant cc and α\alpha would be Diophantine with exponent kk. Choose n1<n2<⋯n_1<n_2<\cdots with cj:=∥njα∥<nj−jc_j:=\lVert n_j\alpha\rVert<n_j^{-j} and let g(x)=∑j2cjcos⁡(2πnjx).g(x)=\sum_j2c_j\cos(2\pi n_jx). For every kk, njkcj<njk−j→0n_j^kc_j<n_j^{k-j}\to0, so gg is smooth, real, of mean zero. Its formal primitive has ∣f^nj∣≥cj/(2π∥njα∥)=1/2π\lvert \hat f_{n_j}\rvert\ge c_j/(2\pi\lVert n_j\alpha\rVert)=1/2\pi, which does not tend to zero; so there is no smooth ff, indeed no integrable one. Splitting (nj)(n_j) into infinitely many disjoint infinite subsequences gives functions g1,g2,…g_1,g_2,\dots of this kind with disjoint spectra, and any non-trivial finite combination ∑aigi\sum a_ig_i has a formal primitive with coefficients of modulus at least ∣ai∣/2π\lvert a_i\rvert/2\pi along the ii-th subsequence. So the classes [gi][g_i] are linearly independent. ◻

Small divisors. For the golden ratio the successive minima of ∥nα∥\lVert n\alpha\rVert stay within a bounded factor of 1/n1/n: every mean-zero cocycle is a coboundary and Fl⁡(Tα)=R\operatorname{Fl}(T_{\alpha})=\mathbb{R}. For Liouville’s constant the minima drop abruptly at n=10k!n=10^{k!}; Fourier modes placed at those frequencies give principal R\mathbb{R}-bundles over TαT_{\alpha} that are not multiples of the Kronecker bundle. The data are exact computations.

Corollary 1.8. If α\alpha is an algebraic irrational — in particular if TαT_{\alpha} has real multiplication — then Fl⁡(Tα)≅R\operatorname{Fl}(T_{\alpha})\cong\mathbb{R}: every principal R\mathbb{R}-bundle over TαT_{\alpha} is trivial or isomorphic to the Kronecker bundle with a rescaled flow.

Summary of invariants

The irrational torus as an arithmetic object. The first three rows are independent of α\alpha; the rest depend on the smooth structure beyond its shape. Every row is a functor on H\mathbf{H} evaluated at one object.
invariant of TαT_{\alpha} value dependence on α\alpha
D-topology; C∞(Tα,R)C^{\infty}(T_{\alpha},\mathbb{R}) indiscrete; R\mathbb{R} none
shape ΠTα\Pi T_{\alpha} BZ2\mathbf{B}\mathbb{Z}^2 none
HdR∙H^\bullet_{\mathrm{dR}}; E2E_2 page (R,R,0)(\mathbb{R},\mathbb{R},0); H∙(T2)H^\bullet(T^2) none
diffeomorphism type GL⁡2(Z)⋅α\operatorname{GL}_2(\mathbb{Z})\cdot\alpha tail of the continued fraction
End⁡(Tα)\operatorname{End}(T_{\alpha}) Oα\mathcal O_\alpha quadratic or not; the order
π0Diff⁡(Tα)\pi_0\operatorname{Diff}(T_{\alpha}) Oα×\mathcal O_\alpha^\times fundamental unit, regulator
Fl⁡(Tα)=H1(Tα;R)\operatorname{Fl}(T_{\alpha})=H^1(T_{\alpha};\mathbb{R}) C∞(S1)/(ρα∗−1)C^{\infty}(S^1)/(\rho_\alpha^*-1) Diophantine or Liouville
classes with given End⁡\operatorname{End} Pic⁡(O)\operatorname{Pic}(\mathcal O) (Theorem 1.2) class number

The chapter is summarised in 1.1. Continued fractions, Pell’s equation and small divisors are classical; TαT_{\alpha} is a single geometric object of which they are all invariants, in a category where “invariant” has its ordinary meaning. In noncommutative geometry the same foliation has the irrational rotation algebra AαA_\alpha attached to it, and the first row of arithmetic also appears there: AαA_\alpha and AβA_\beta are Morita equivalent exactly when α\alpha and β\beta are GL⁡2(Z)\operatorname{GL}_2(\mathbb{Z})-equivalent [48]. The diffeological proof is a covering space argument.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Let φ=(1+5)/2\varphi=(1+\sqrt5)/2. Compute the action of the diffeomorphism [x]↦[φkx][x]\mapsto[\varphi^kx] of TφT_\varphi on π1(Tφ)\pi_1(T_\varphi) in the basis (1,φ)(1,\varphi).

Solution.  π1(Tφ)=Λφ\pi_1(T_\varphi)=\Lambda_\varphi and the induced map is multiplication by φk\varphi^k. Since φ2=φ+1\varphi^2=\varphi+1, multiplication by φ\varphi sends 1↦φ1\mapsto\varphi and φ↦1+φ\varphi\mapsto1+\varphi, with matrix acting on coordinate columns. By induction φk=Fk−1+Fkφ\varphi^k=F_{k-1}+F_k\varphi with FkF_k the Fibonacci numbers, and , of determinant (−1)k(-1)^k. For odd kk the diffeomorphism reverses the orientation of π1\pi_1 although it preserves that of R\mathbb{R}. ◀\blacktriangleleft

2 Compute Oα\mathcal O_\alpha and a generator of π0Diff⁡(Tα)/{±1}\pi_0\operatorname{Diff}(T_{\alpha})/\{\pm1\} for α=(1+3)/2\alpha=(1+\sqrt3)/2. What is Oα\mathcal O_\alpha for α=23\alpha=\sqrt[3]2?

Solution.  2α−1=32\alpha-1=\sqrt3 gives 2α2−2α−1=02\alpha^2-2\alpha-1=0, so (A,B,C)=(2,−2,−1)(A,B,C)=(2,-2,-1) is primitive with D=4+8=12D=4+8=12, and Oα=Z+Z⋅2α=Z[1+3]=Z[3]\mathcal O_\alpha=\mathbb{Z}+\mathbb{Z}\cdot2\alpha=\mathbb{Z}[1+\sqrt3]=\mathbb{Z}[\sqrt3]. Note that α∉Oα\alpha\notin\mathcal O_\alpha. The fundamental unit of Z[3]\mathbb{Z}[\sqrt3] is 2+32+\sqrt3, of norm 11. One checks directly: (2+3)⋅1=1+2α(2+\sqrt3)\cdot1=1+2\alpha and (2+3)α=(1+2α)α=α+2α2=1+3α(2+\sqrt3)\alpha=(1+2\alpha)\alpha=\alpha+2\alpha^2=1+3\alpha, both in Λα\Lambda_\alpha, with matrix of determinant 1⋅3−2⋅1=11\cdot3-2\cdot1=1. For α=23\alpha=\sqrt[3]2, which is not quadratic, Oα=Z\mathcal O_\alpha=\mathbb{Z} by 1.3(i). ◀\blacktriangleleft

2 Show that T2≅T1+2≅T1/2T_{\sqrt2}\cong T_{1+\sqrt2}\cong T_{1/\sqrt2} and that T2≇T3T_{\sqrt2}\not\cong T_{\sqrt3}.

Solution.  1+21+\sqrt2 and 1/21/\sqrt2 are the images of 2\sqrt2 under and , both in GL⁡2(Z)\operatorname{GL}_2(\mathbb{Z}); apply 1.2. If β=(aα+b)/(cα+d)\beta=(a\alpha+b)/(c\alpha+d) with integer coefficients then Q(β)⊆Q(α)\mathbb{Q}(\beta)\subseteq\mathbb{Q}(\alpha), and symmetrically; so GL⁡2(Z)\operatorname{GL}_2(\mathbb{Z})-equivalent irrationals generate the same field. Since Q(2)≠Q(3)\mathbb{Q}(\sqrt2)\ne\mathbb{Q}(\sqrt3), the tori are not diffeomorphic. (Indeed there is not even a non-constant smooth map between them, by 1.2(i): λ\lambda and λ2\lambda\sqrt2 in Z+Z3\mathbb{Z}+\mathbb{Z}\sqrt3 with λ≠0\lambda\ne0 would give 2∈Q(3)\sqrt2\in\mathbb{Q}(\sqrt3).) ◀\blacktriangleleft

3 Show that T10T_{\sqrt{10}} and T10/2T_{\sqrt{10}/2} have the same endomorphism ring Z[10]\mathbb{Z}[\sqrt{10}] but are not diffeomorphic.

Solution.  For α=10\alpha=\sqrt{10}: (A,B,C)=(1,0,−10)(A,B,C)=(1,0,-10), D=40D=40, Oα=Z[10]\mathcal O_\alpha=\mathbb{Z}[\sqrt{10}]. For β=10/2\beta=\sqrt{10}/2: 2β2−5=02\beta^2-5=0, (A,B,C)=(2,0,−5)(A,B,C)=(2,0,-5), D=40D=40, Oβ=Z+Z⋅2β=Z[10]\mathcal O_\beta=\mathbb{Z}+\mathbb{Z}\cdot2\beta=\mathbb{Z}[\sqrt{10}]. Suppose λΛα=Λβ\lambda\Lambda_\alpha=\Lambda_\beta. Now Λα=Z[10]=O\Lambda_\alpha=\mathbb{Z}[\sqrt{10}]=\mathcal O and 2Λβ=2Z+10Z=:p2\Lambda_\beta=2\mathbb{Z}+\sqrt{10}\mathbb{Z}=:\mathfrak p, an ideal of O\mathcal O of index 22. So p=2λO\mathfrak p=2\lambda\mathcal O would be principal, generated by μ=2λ=x+y10∈O\mu=2\lambda=x+y\sqrt{10}\in\mathcal O with ∣N(μ)∣=[O:p]=2\lvert N(\mu)\rvert=[\mathcal O:\mathfrak p]=2, i.e. x2−10y2=±2x^2-10y^2=\pm2. Reducing modulo 55 gives x2≡±2x^2\equiv\pm2, impossible since the squares modulo 55 are 0,1,40,1,4. Hence no such λ\lambda exists. In terms of 1.2(iii): 10=[3;6‾]\sqrt{10}=[3;\overline6] and 10/2=[1;1,1,2‾]\sqrt{10}/2=[1;\overline{1,1,2}] have different tails. The two tori are related by a smooth homomorphism with kernel of order 22 in each direction, but not by a diffeomorphism. ◀\blacktriangleleft

3 For Liouville’s constant α=∑k≥110−k!\alpha=\sum_{k\ge1}10^{-k!}, write down an explicit smooth function on S1S^1 of mean zero that is not of the form f∘ρα−ff\circ\rho_\alpha-f, and describe the corresponding bundle.

Solution.  Let nj=10j!n_j=10^{j!}. Then njα=integer+∑k>j10j!−k!n_j\alpha=\text{integer}+\sum_{k>j}10^{j!-k!}, so ∥njα∥=∑k>j10j!−k!<2⋅10−j⋅j!=2nj−j\lVert n_j\alpha\rVert=\sum_{k>j}10^{j!-k!}<2\cdot10^{-j\cdot j!}=2n_j^{-j}. Put cj=∥njα∥c_j=\lVert n_j\alpha\rVert and g(x)=∑j2cjcos⁡(2πnjx)g(x)=\sum_j2c_j\cos(2\pi n_jx). As in the proof of 1.7(iii), gg is smooth of mean zero and the Fourier coefficients of a solution ff would have modulus at least 1/2π1/2\pi at the frequencies njn_j, contradicting the Riemann–Lebesgue lemma. The bundle is Yg=(S1×R)/ZY_g=(S^1\times\mathbb{R})/\mathbb{Z} with 1⋅([x],t)=([x+α],t+g(x))1\cdot([x],t)=([x+\alpha],t+g(x)), with its projection to S1/ρα=TαS^1/\rho_\alpha=T_{\alpha} and the R\mathbb{R}-action on tt: a “skew translation” of the cylinder. It has a section iff gg is a coboundary. So Yg→TαY_g\to T_{\alpha} is a non-trivial principal R\mathbb{R}-bundle with zero mean, hence not isomorphic to any rescaling of T2→TαT^2\to T_{\alpha}, and by [exo:IZ830] it is not flat. ◀\blacktriangleleft

4 Prove, without spectral sequences, that H1(Λα;C∞(R))≅C∞(S1)/(ρα∗−1)C∞(S1)H^1(\Lambda_\alpha;C^{\infty}(\mathbb{R}))\cong C^{\infty}(S^1)/(\rho_\alpha^*-1)C^{\infty}(S^1).

Solution.  Write M=C∞(R)M=C^{\infty}(\mathbb{R}) with Λα\Lambda_\alpha acting by (Tλ∗h)(x)=h(x+λ)(T_\lambda^*h)(x)=h(x+\lambda). A 11-cocycle is a map τ ⁣:Λα→M\tau\colon\Lambda_\alpha\to M with τ(λ+λ′)=Tλ′∗τ(λ)+τ(λ′)\tau(\lambda+\lambda')=T_{\lambda'}^*\tau(\lambda)+\tau(\lambda'); coboundaries are δσ(λ)=Tλ∗σ−σ\delta\sigma(\lambda)=T_\lambda^*\sigma-\sigma.

Normalisation. By 1.6 there is σ∈M\sigma\in M with τ(1)=T1∗σ−σ\tau(1)=T_1^*\sigma-\sigma. Replacing τ\tau by τ−δσ\tau-\delta\sigma we may assume τ(1)=0\tau(1)=0; the remaining freedom is to subtract δσ\delta\sigma with T1∗σ=σT_1^*\sigma=\sigma, i.e. σ∈C∞(S1)\sigma\in C^{\infty}(S^1).

The invariant. Computing τ(1+α)\tau(1+\alpha) in the two orders, Tα∗τ(1)+τ(α)=τ(1+α)=T1∗τ(α)+τ(1),T_\alpha^*\tau(1)+\tau(\alpha)=\tau(1+\alpha)=T_1^*\tau(\alpha)+\tau(1), so with τ(1)=0\tau(1)=0 the function g=τ(α)g=\tau(\alpha) is 11-periodic: g∈C∞(S1)g\in C^{\infty}(S^1). The cocycle identity then forces τ(m)=0\tau(m)=0 and τ(m+nα)=τ(nα)=∑k=0n−1Tkα∗g\tau(m+n\alpha)=\tau(n\alpha)=\sum_{k=0}^{n-1}T_{k\alpha}^*g for n≥0n\ge0, with τ(−nα)=−T−nα∗τ(nα)\tau(-n\alpha)=-T_{-n\alpha}^*\tau(n\alpha). So a normalised cocycle is determined by gg.

Existence. Conversely, for any g∈C∞(S1)g\in C^{\infty}(S^1) these formulas define a cocycle: the identity for the subgroup Zα\mathbb{Z}\alpha is the usual telescoping for a Z\mathbb{Z}-cocycle with values in the Zα\mathbb{Z}\alpha-module C∞(S1)C^{\infty}(S^1), and translation by integers acts trivially on the values, so the extension by τ(m+nα)=τ(nα)\tau(m+n\alpha)=\tau(n\alpha) is consistent.

Coboundaries. A normalised τ\tau is changed by an allowed δσ\delta\sigma, σ∈C∞(S1)\sigma\in C^{\infty}(S^1), to one with g′=g−(Tα∗σ−σ)=g−(ρα∗−1)σg'=g-(T_\alpha^*\sigma-\sigma)=g-(\rho_\alpha^*-1)\sigma. So τ↦[g]\tau\mapsto[g] is a well-defined bijection from H1(Λα;M)H^1(\Lambda_\alpha;M) to C∞(S1)/(ρα∗−1)C∞(S1)C^{\infty}(S^1)/(\rho_\alpha^*-1)C^{\infty}(S^1), and it is additive.

Geometrically the normalisation step trivialises the pullback of the bundle to the circle R/Z\mathbb{R}/\mathbb{Z}, which covers TαT_{\alpha} with group Z\mathbb{Z} ([exo:Z-bundles]), and gg is the clutching function of the bundle over Tα=S1/ραT_{\alpha}=S^1/\rho_\alpha. This is the reduction in [IZ, art. 8.39]. ◀\blacktriangleleft

Cryptography: real multiplication, class groups, lattices

Irrational tori are analogues of elliptic curves without a complex structure: they have isogenies, degrees, torsion subgroups and, in the quadratic case, real multiplication. We show that tori with real multiplication by a fixed order form a torsor under its class group, that deciding diffeomorphism between them is the principal ideal problem, and that the infrastructure of a real quadratic field is a circle of marked tori. We then treat lattices proper through their moduli orbifold, where the search and decision forms of the lattice isomorphism problem become the stack and its coarse space.

Source in the book. The geometry used is [IZ, Exercise 4], [IZ, art. 4.17–4.18] and Number theory: the arithmetic of irrational tori. The real-multiplication viewpoint is Manin’s [43].

Isogenies of irrational tori

A pseudolattice is a subgroup Λ⊂R\Lambda\subset\mathbb{R} of rank 22 that is not cyclic, equivalently Λ=Zω1+Zω2\Lambda=\mathbb{Z}\omega_1+\mathbb{Z}\omega_2 with ω1/ω2\omega_1/\omega_2 irrational [43]. Every irrational torus is TΛ=R/ΛT_\Lambda=\mathbb{R}/\Lambda for a pseudolattice, and TΛ≅Tω2/ω1T_\Lambda\cong T_{\omega_2/\omega_1}. An isogeny TΛ→TΛ′T_\Lambda\to T_{\Lambda'} is a non-constant smooth homomorphism.

Proposition 1.1 (Isogenies).

  1. Λ↦TΛ\Lambda\mapsto T_\Lambda is an equivalence from the category of pseudolattices, with morphisms Hom⁡(Λ,Λ′)={ λ∈R:λΛ⊆Λ′ }\operatorname{Hom}(\Lambda,\Lambda')=\{\,\lambda\in\mathbb{R}: \lambda\Lambda\subseteq\Lambda'\,\}, to the category of irrational tori and smooth homomorphisms.

  2. An isogeny λ\lambda is surjective, with finite kernel λ−1Λ′/Λ≅Λ′/λΛ\lambda^{-1}\Lambda'/\Lambda\cong\Lambda'/\lambda\Lambda of order deg⁡λ:=[Λ′:λΛ]\deg\lambda:=[\Lambda':\lambda\Lambda], and it is a covering map. Degrees are multiplicative.

  3. Every isogeny λ\lambda has a dual λ^=deg⁡(λ)/λ ⁣:TΛ′→TΛ\hat\lambda=\deg(\lambda)/\lambda\colon T_{\Lambda'}\to T_\Lambda with λ^λ=[deg⁡λ]\hat\lambda\lambda=[\deg\lambda]. So isogeny is an equivalence relation.

  4. The NN-torsion subgroup is TΛ[N]=1NΛ/Λ≅(Z/N)2T_\Lambda[N]=\tfrac1N\Lambda/\Lambda\cong(\mathbb{Z}/N)^2.

Proof. (i) is Corollary 1.2(i): smooth homomorphisms are multiplications by real numbers preserving the groups. (ii) λΛ\lambda\Lambda and Λ′\Lambda' both have rank 22, so the index is finite; x↦λxx\mapsto\lambda x is onto R\mathbb{R}; the kernel of the induced map is as stated, and it is a principal bundle for this finite group by Corollary 1.3. (iii) deg⁡(λ)⋅Λ′⊆λΛ\deg(\lambda)\cdot\Lambda'\subseteq\lambda\Lambda because a finite abelian group is annihilated by its order, so (deg⁡λ/λ)Λ′⊆Λ(\deg\lambda/\lambda)\Lambda'\subseteq\Lambda. (iv) is the kernel of multiplication by NN. ◻

Complex and real multiplication. The right-hand column is a theorem-by-theorem translation of the left; the differences are in the last rows, and they are what matters for cryptography.
elliptic curve E=C/ΛE=\mathbb{C}/\Lambda irrational torus T=R/ΛT=\mathbb{R}/\Lambda
lattice discrete, rank 22 in C\mathbb{C} dense, rank 22 in R\mathbb{R}
category complex manifolds diffeological spaces
morphisms λ∈C\lambda\in\mathbb{C}, λΛ⊆Λ′\lambda\Lambda\subseteq\Lambda' λ∈R\lambda\in\mathbb{R}, λΛ⊆Λ′\lambda\Lambda\subseteq\Lambda'
NN-torsion (Z/N)2(\mathbb{Z}/N)^2 (Z/N)2(\mathbb{Z}/N)^2
moduli SL⁡2(Z)\H\operatorname{SL}_2(\mathbb{Z})\backslash\mathfrak H GL⁡2(Z)\(R∖Q)\operatorname{GL}_2(\mathbb{Z})\backslash(\mathbb{R}\smallsetminus\mathbb{Q})
extra endomorphisms imaginary quadratic order (CM) real quadratic order (RM)
unit group of the order finite {±1}×Z\{\pm1\}\times\mathbb{Z}
classes with given order torsor under Pic⁡(O)\operatorname{Pic}(\mathcal O) torsor under Pic⁡(O)\operatorname{Pic}(\mathcal O)
shape BZ2\mathbf{B}\mathbb{Z}^2 BZ2\mathbf{B}\mathbb{Z}^2

The class group torsor

Fix a real quadratic field K⊂RK\subset\mathbb{R} and an order O⊂K\mathcal O\subset K of discriminant DD. For a pseudolattice Λ\Lambda write OΛ={ λ∈R:λΛ⊆Λ }=End⁡(TΛ)\mathcal O_\Lambda=\{\,\lambda\in\mathbb{R}:\lambda\Lambda\subseteq\Lambda\,\}=\operatorname{End}(T_\Lambda). Let T(O)\mathcal T(\mathcal O) be the set of diffeomorphism classes of irrational tori TΛT_\Lambda with OΛ=O\mathcal O_\Lambda=\mathcal O, and let Pic⁡(O)\operatorname{Pic}(\mathcal O) be the group of invertible fractional O\mathcal O-ideals modulo principal ones.

Theorem 1.2 (Tori with real multiplication; after [43, 31). ]

  1. Every pseudolattice with OΛ=O\mathcal O_\Lambda=\mathcal O is homothetic to an invertible fractional ideal of O\mathcal O, and Λ↦[Λ]\Lambda\mapsto[\Lambda] induces a bijection T(O)≅Pic⁡(O)\mathcal T(\mathcal O)\cong\operatorname{Pic}(\mathcal O). In particular there are exactly h(O)h(\mathcal O) diffeomorphism classes of irrational tori with real multiplication by O\mathcal O.

  2. Pic⁡(O)\operatorname{Pic}(\mathcal O) acts simply transitively on T(O)\mathcal T(\mathcal O) by [a]⋅[TΛ]=[Ta−1Λ][\mathfrak a]\cdot[T_\Lambda]=[T_{\mathfrak a^{-1}\Lambda}]. For an integral invertible ideal a\mathfrak a the canonical map ϕa ⁣:TΛ⟶Ta−1Λ\phi_{\mathfrak a}\colon T_\Lambda\longrightarrow T_{\mathfrak a^{-1}\Lambda} is an isogeny of degree N(a)N(\mathfrak a) with kernel TΛ[a]={ x:ax=0 }T_\Lambda[\mathfrak a]=\{\,x:\mathfrak a x=0\,\}.

  3. Every isogeny between tori with real multiplication by O\mathcal O is, up to diffeomorphism of its target, some ϕa\phi_{\mathfrak a}.

Proof. (i) Scale Λ\Lambda so that 1∈Λ1\in\Lambda, say Λ=Z+Zα\Lambda=\mathbb{Z}+\mathbb{Z}\alpha. Then OΛ=Oα≠Z\mathcal O_\Lambda=\mathcal O_\alpha\ne\mathbb{Z}, so by Theorem 1.3 α\alpha is quadratic, Q(α)=K\mathbb{Q}(\alpha)=K, and Λ⊂K\Lambda\subset K is a lattice with multiplier ring O\mathcal O. In a quadratic order such a lattice is an invertible fractional ideal ([exo:proper-invertible]). If λΛ=Λ′\lambda\Lambda=\Lambda' with both in KK then λ∈K×\lambda\in K^\times. So homothety classes of pseudolattices with multiplier ring O\mathcal O are classes of invertible ideals modulo K×K^\times, and by Theorem 1.1 homothety classes are diffeomorphism classes. (ii) Multiplication by an invertible ideal preserves the multiplier ring, and the action of a group on itself is simply transitive. If a⊆O\mathfrak a\subseteq\mathcal O then Λ⊆a−1Λ\Lambda\subseteq\mathfrak a^{-1}\Lambda with index N(a)N(\mathfrak a), and the identity of R\mathbb{R} induces ϕa\phi_{\mathfrak a} with kernel a−1Λ/Λ={ x∈R/Λ:ax⊆Λ }\mathfrak a^{-1}\Lambda/\Lambda=\{\,x\in\mathbb{R}/\Lambda:\mathfrak ax\subseteq\Lambda\,\}. (iii) If λΛ⊆Λ′\lambda\Lambda\subseteq\Lambda' then a=λΛ⋅Λ′−1\mathfrak a=\lambda\Lambda\cdot\Lambda'^{-1} is an integral invertible ideal and Λ′=a−1(λΛ)\Lambda'=\mathfrak a^{-1}(\lambda\Lambda); multiplication by λ\lambda is a diffeomorphism TΛ→TλΛT_\Lambda\to T_{\lambda\Lambda}. ◻

This is the exact analogue of the main theorem of complex multiplication for elliptic curves over C\mathbb{C}, with the same proof. The diffeological input is Theorem 1.1, by which the category in which these objects are classified is the ordinary category of smooth spaces.

Example 1.3 (Two small isogeny graphs).

  1. D=5D=5, O=Z[φ]\mathcal O=\mathbb{Z}[\varphi], h=1h=1: the golden torus is the only torus with real multiplication by Z[φ]\mathbb{Z}[\varphi].

  2. D=40D=40, O=Z[10]\mathcal O=\mathbb{Z}[\sqrt{10}], h=2h=2: the two classes are T10T_{\sqrt{10}} and T10/2T_{\sqrt{10}/2} ([exo:sqrt10]). The primes p2=(2,10)\mathfrak p_2=(2,\sqrt{10}) and p3=(3,1+10)\mathfrak p_3=(3,1+\sqrt{10}) are both non-principal, so isogenies of degree 22 and 33 interchange the two tori.

  3. D=316D=316, O=Z[79]\mathcal O=\mathbb{Z}[\sqrt{79}], h=3h=3: the three classes are T79T_{\sqrt{79}}, T(1+79)/3T_{(1+\sqrt{79})/3} and T(−1+79)/3T_{(-1+\sqrt{79})/3}, permuted cyclically by the two primes above 33 (1.1, [exo:79]).

Left: the three irrational tori with real multiplication by Z[79]\mathbb{Z}[\sqrt{79}], with the continued fraction of a representative, and the cyclic action of an ideal of norm 33. Right: the circle of marked tori homothetic to R/O\mathbb{R}/\mathcal O (1.5), with the four reduced principal ideals at their exact positions 00, 0.1190.119, 2.1912.191 and 2.2492.249 (successive ideals differ by the complete quotients of the continued fraction of 8+798+\sqrt{79}).

Diffeomorphism is the principal ideal problem

Present a torus with real multiplication by the primitive integer form (A,B,C)(A,B,C) of discriminant DD with root α=(−B+D)/2A\alpha=(-B+\sqrt D)/2A; this takes O(log⁡D)O(\log D) bits. Then AΛα=AZ+−B+D2ZA\Lambda_\alpha=A\mathbb{Z}+\tfrac{-B+\sqrt D}2\mathbb{Z} is an invertible ideal of OD\mathcal O_D, and every ideal class arises.

Theorem 1.4 (Complexity dictionary). Fix a non-square discriminant D>0D>0 and let RD=log⁡εDR_D=\log\varepsilon_D be the regulator of OD\mathcal O_D.

  1. The problem of deciding whether Tα≅TβT_{\alpha}\cong T_\beta for two tori presented by forms of discriminant DD is equivalent, under linear-time reductions in both directions, to deciding equality of two classes in Pic⁡(OD)\operatorname{Pic}(\mathcal O_D). Finding the diffeomorphism λ\lambda, in the sense of approximating log⁡∣λ∣\log\lvert \lambda\rvert modulo RDR_D, is equivalent to the principal ideal problem for OD\mathcal O_D.

  2. Computing a generator of π0Diff⁡(Tα)/{±1}≅Z\pi_0\operatorname{Diff}(T_{\alpha})/\{\pm1\}\cong\mathbb{Z}, in the sense of approximating its dilation factor, is equivalent to computing RDR_D, that is, to solving Pell’s equation.

  3. Consequently both problems are solvable in quantum polynomial time in log⁡D\log D [23]. The best known classical algorithms are subexponential; and integer factoring reduces to (b) [23].

Proof. (a) By Theorem 1.1 and 1.2, Tα≅TβT_{\alpha}\cong T_\beta iff λΛα=Λβ\lambda\Lambda_\alpha=\Lambda_\beta for some λ∈K×\lambda\in K^\times, iff the ideals AΛαA\Lambda_\alpha and A′ΛβA'\Lambda_\beta are equivalent, and λ\lambda is, up to the rational factor A/A′A/A' and a unit, a generator of the principal ideal A′Λβ(AΛα)−1A'\Lambda_\beta(A\Lambda_\alpha)^{-1}. The translation between forms, tori and ideals is a relabelling of the input. (b) By Theorem 1.3(iii) the generator is multiplication by εD\varepsilon_D. (c) Hallgren’s algorithms compute RDR_D and solve the principal ideal problem in real quadratic orders in quantum polynomial time. ◻

The theorem locates real-quadratic cryptography on the geometric side.

Proposition 1.5 (The infrastructure is a circle of marked tori). Fix a class c∈Pic⁡(O)c\in\operatorname{Pic}(\mathcal O). The set of pseudolattices Λ⊂R\Lambda\subset\mathbb{R} in the class cc, not taken up to homothety, is a torsor under R×/O×  ≅  R>0/εZ  → log⁡  ≅   R/RDZ,\mathbb{R}^\times/\mathcal O^\times\;\cong\;\mathbb{R}_{>0}/\varepsilon^{\mathbb{Z}}\;\xrightarrow[\ \log\ ]{\ \cong\ }\;\mathbb{R}/R_D\mathbb{Z}, a circle of circumference the regulator. Equivalently it is the set of isomorphism classes of marked tori (R→T)(\mathbb{R}\to T) in the diffeomorphism class cc, where a marking is a choice of universal covering by R\mathbb{R} up to translation.

Proof. R×\mathbb{R}^\times acts on lattices by homothety, transitively on a class by definition, and the stabiliser of Λ\Lambda is { λ:λΛ=Λ }=O×={±εk}\{\,\lambda:\lambda\Lambda=\Lambda\,\}=\mathcal O^\times=\{\pm\varepsilon^k\}. A marked torus is the same as the subgroup Λ=ker⁡(R→T)\Lambda=\ker(\mathbb{R}\to T), since translations do not change it. ◻

The finitely many reduced ideals in the class are distinguished points on this circle; Shanks called the circle with these points the infrastructure of the class [51]. Multiplying two reduced ideals and reducing lands near the sum of their positions, so one can take large steps around the circle without knowing its circumference. Buchmann and Williams built a Diffie–Hellman key exchange on this [7]: the parties exchange reduced ideals near positions aδa\delta and bδb\delta and share the one near abδab\delta; an eavesdropper who can compute positions — that is, solve the principal ideal problem — recovers the key. In our terms: the Buchmann–Williams scheme is Diffie–Hellman in the circle group of marked tori diffeomorphic to R/O\mathbb{R}/\mathcal O, with elements represented by nearby tori of small height and the circumference RDR_D kept implicit. Hallgren’s algorithm computes the circumference and the positions, and breaks it.

Lattices

For lattices of full rank, all quotients Rn/L\mathbb{R}^n/L are diffeomorphic by Theorem 1.1. The object of lattice cryptography is the Euclidean structure, and the natural diffeological object is the moduli space of lattices. Let Sn\mathcal S_n be the open cone of positive definite symmetric n×nn\times n matrices, on which GL⁡n(Z)\operatorname{GL}_n(\mathbb{Z}) acts by Q⋅U=UTQUQ\cdot U=U^{\mathsf T}QU; two Gram matrices are in the same orbit iff they come from isometric lattices. The lattice isomorphism problem (LIP) is: given Q,Q′Q,Q', find a UU with Q′=UTQUQ'=U^{\mathsf T}QU [18].

Theorem 1.6 (The orbifold of lattices). Let Ln=Sn/GL⁡n(Z)\mathfrak L_n=\mathcal S_n/\operatorname{GL}_n(\mathbb{Z}) with the quotient diffeology, and Aut⁡(Q)={ U∈GL⁡n(Z):UTQU=Q }\operatorname{Aut}(Q)=\{\,U\in\operatorname{GL}_n(\mathbb{Z}):U^{\mathsf T}QU=Q\,\}.

  1. Ln\mathfrak L_n is a diffeological orbifold of dimension n(n+1)/2n(n+1)/2. Near [Q][Q] it is diffeomorphic to Sym⁡n(R)/ΓˉQ\operatorname{Sym}_n(\mathbb{R})/\bar\Gamma_Q, where ΓˉQ=Aut⁡(Q)/{±1}\bar\Gamma_Q=\operatorname{Aut}(Q)/\{\pm1\} acts linearly by S↦UTSUS\mapsto U^{\mathsf T}SU.

  2. The conjugacy class of the linear group ΓˉQ\bar\Gamma_Q is an invariant of the germ of Ln\mathfrak L_n at [Q][Q]. In particular [Q][Q] is a manifold point of Ln\mathfrak L_n if and only if Aut⁡(Q)={±1}\operatorname{Aut}(Q)=\{\pm1\}.

  3. In H\mathbf{H} there are canonical maps Sn/ ⁣ ⁣/GL⁡n(Z)→Sn/ ⁣ ⁣/PGL⁡n(Z)→Ln\mathcal S_n/\!\!/\operatorname{GL}_n(\mathbb{Z})\to\mathcal S_n/\!\!/\operatorname{PGL}_n(\mathbb{Z})\to\mathfrak L_n. The first is a BZ/2\mathbf{B}\mathbb{Z}/2-bundle, the second is an isomorphism over the manifold points. Decision-LIP is equality of points of Ln\mathfrak L_n; search-LIP is the construction of a 11-morphism Q→Q′Q\to Q' in the stack Sn/ ⁣ ⁣/GL⁡n(Z)\mathcal S_n/\!\!/\operatorname{GL}_n(\mathbb{Z}); and the set of solutions is a torsor under Aut⁡(Q)\operatorname{Aut}(Q).

Proof. (i) The action is properly discontinuous: if QQ and UTQUU^{\mathsf T}QU range over a compact subset of Sn\mathcal S_n then ∥U∥\lVert U\rVert is bounded, so only finitely many integer matrices UU occur. Hence stabilisers are finite and every QQ has an Aut⁡(Q)\operatorname{Aut}(Q)-invariant open neighbourhood WW with W⋅U∩W=∅W\cdot U\cap W=\varnothing for U∉Aut⁡(Q)U\notin\operatorname{Aut}(Q). The saturation of WW is open, so its image is D-open in the quotient and is diffeomorphic to W/Aut⁡(Q)W/\operatorname{Aut}(Q). The action on Sym⁡n(R)⊃Sn\operatorname{Sym}_n(\mathbb{R})\supset\mathcal S_n is linear and fixes QQ; translating by −Q-Q identifies W/Aut⁡(Q)W/\operatorname{Aut}(Q) with a neighbourhood of 00 in Sym⁡n(R)/Aut⁡(Q)\operatorname{Sym}_n(\mathbb{R})/\operatorname{Aut}(Q). The kernel of GL⁡n(Z)→GL⁡(Sym⁡n(R))\operatorname{GL}_n(\mathbb{Z})\to\operatorname{GL}(\operatorname{Sym}_n(\mathbb{R})) is {±1}\{\pm1\}, so the effective group is ΓˉQ\bar\Gamma_Q. (ii) is Theorem 1.2 and Corollary 1.3. (iii) is Theorem 1.8: the action of PGL⁡n(Z)\operatorname{PGL}_n(\mathbb{Z}) is free exactly over the points with ΓˉQ=1\bar\Gamma_Q=1, and Hom⁡(Q,Q′)={ U:Q′=UTQU }\operatorname{Hom}(Q,Q')=\{\,U:Q'=U^{\mathsf T}QU\,\} is a torsor under the automorphism group of QQ when it is non-empty. ◻

In this language a public key in an LIP-based scheme is a point of the stack with a hidden 11-morphism to a distinguished object, and the structure group at that object measures how many secret keys there are. For the lattice Zn\mathbb{Z}^n, used in the signature scheme Hawk [19] in a module form, Aut⁡(In)\operatorname{Aut}(I_n) is the hyperoctahedral group of order 2nn!2^nn!, the most singular kind of point; a generic QQ is a manifold point with Aut⁡(Q)={±1}\operatorname{Aut}(Q)=\{\pm1\}. The distinction between the stack and the orbifold Ln\mathfrak L_n is the distinction between search and decision: equality of points of the coarse space is the existence of an equivalence of forms, and a 11-cell of the stack is a choice of one. The zero-knowledge proofs of [18] are proofs of knowledge of a 11-cell in which only its endpoints are disclosed.

For subgroups of rank larger than the dimension the diffeology of the quotient is again informative.

Corollary 1.7 (Projected lattices). Let B,B′B,B' be real n×Nn\times N matrices of rank nn that are injective on ZN\mathbb{Z}^N. Then Rn/BZN≅Rn/B′ZN  ⟺  B′=ABU  for some A∈GL⁡n(R), U∈GL⁡N(Z)  ⟺  ker⁡B′=U−1ker⁡B  for some U∈GL⁡N(Z).\begin{aligned} \mathbb{R}^n/B\mathbb{Z}^N\cong\mathbb{R}^n/B'\mathbb{Z}^N&\iff B'=ABU\ \text{ for some }A\in\operatorname{GL}_n(\mathbb{R}),\ U\in\operatorname{GL}_N(\mathbb{Z})\\ &\iff\ker B'=U^{-1}\ker B\ \text{ for some }U\in\operatorname{GL}_N(\mathbb{Z}). \end{aligned} So diffeomorphism classes of such quasi-tori correspond to GL⁡N(Z)\operatorname{GL}_N(\mathbb{Z})-orbits of (N−n)(N-n)-dimensional subspaces of RN\mathbb{R}^N meeting ZN\mathbb{Z}^N trivially.

Proof. By Theorem 1.1 the quotients are diffeomorphic iff B′ZN=ABZNB'\mathbb{Z}^N=AB\mathbb{Z}^N for some AA; as B′B' and ABAB are injective on ZN\mathbb{Z}^N with the same image there is a unique U∈GL⁡N(Z)U\in\operatorname{GL}_N(\mathbb{Z}) with B′=ABUB'=ABU. A matrix of rank nn is determined up to left multiplication by GL⁡n(R)\operatorname{GL}_n(\mathbb{R}) by its kernel. ◻

The geometric picture

Three things usually treated separately are here objects of one category: the class group action (isogenies of tori), the infrastructure (marked tori), and the search/decision distinction for isomorphism problems (stack versus coarse space).

Two facts about sizes orient the picture. Isogeny-based schemes such as CSIDH [9] use the action of a large imaginary quadratic class group, of size about ∣D∣\sqrt{\lvert D\rvert}, as a hard homogeneous space [15]. For real quadratic orders it is the product h⋅Rh\cdot R that has this size, and heuristically the class number hh is usually small [14]. So the torsor of 1.2 is small and the bulk of the structure is in the circle of 1.5, which is where period finding applies (1.4). For lattices, the Euclidean geometry used in cryptography is that of Sn\mathcal S_n and of the fibres of Sn→Ln\mathcal S_n\to\mathfrak L_n, and the isomorphism problem is the problem of equality of points of the orbifold Ln\mathfrak L_n.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Show that multiplication by NN on an irrational torus has degree N2N^2, and that for λ∈OΛ\lambda\in\mathcal O_\Lambda the endomorphism λ\lambda of TΛT_\Lambda has degree ∣NK/Q(λ)∣\lvert N_{K/\mathbb{Q}}(\lambda)\rvert when Λ\Lambda has real multiplication.

Solution.  [Λ:NΛ]=N2[\Lambda:N\Lambda]=N^2 since Λ≅Z2\Lambda\cong\mathbb{Z}^2. In general deg⁡λ=[Λ:λΛ]\deg\lambda=[\Lambda:\lambda\Lambda] is the absolute value of the determinant of multiplication by λ\lambda on Λ≅Z2\Lambda\cong\mathbb{Z}^2, which is the norm of λ\lambda as an element of the quadratic field (the determinant of multiplication by λ\lambda on K=Λ⊗QK=\Lambda\otimes\mathbb{Q}). ◀\blacktriangleleft

2 On the golden torus TφT_\varphi, compute the degree and kernel of multiplication by 5=2φ−1\sqrt5=2\varphi-1, and of multiplication by φ\varphi.

Solution.  N(5)=−5N(\sqrt5)=-5, so the degree is 55 and the kernel is 15Z[φ]/Z[φ]≅Z[φ]/(5)≅Z/5\tfrac1{\sqrt5}\mathbb{Z}[\varphi]/\mathbb{Z}[\varphi]\cong\mathbb{Z}[\varphi]/(\sqrt5)\cong\mathbb{Z}/5, generated by the class of 1/51/\sqrt5. N(φ)=−1N(\varphi)=-1, so multiplication by φ\varphi has degree 11: it is the diffeomorphism of [exo:golden]. The prime 55 ramifies in Z[φ]\mathbb{Z}[\varphi], and Tφ[5]T_\varphi[\sqrt5] is the unique subgroup of Tφ[5]≅(Z/5)2T_\varphi[5]\cong(\mathbb{Z}/5)^2 stable under real multiplication. ◀\blacktriangleleft

2 Verify 1.3(c): the ideal p=(3,−1+79)\mathfrak p=(3,-1+\sqrt{79}) of Z[79]\mathbb{Z}[\sqrt{79}] is not principal, and p3\mathfrak p^3 is.

Solution.  N(p)=3N(\mathfrak p)=3. If p=(x+y79)\mathfrak p=(x+y\sqrt{79}) then x2−79y2=±3x^2-79y^2=\pm3. By a theorem of Lagrange, a solution of ∣x2−dy2∣<d\lvert x^2-dy^2\rvert<\sqrt d in coprime integers has x/yx/y a convergent of d\sqrt d. For 79=[8;1,7,1,16‾]\sqrt{79}=[8;\overline{1,7,1,16}] the values p2−79q2p^2-79q^2 along the convergents are periodic and equal to −15,2,−15,1-15,2,-15,1; so ±3\pm3 is not represented. On the other hand 172−79⋅22=−2717^2-79\cdot2^2=-27, so μ=17+279\mu=17+2\sqrt{79} has norm −27-27. The ideal (μ)(\mu) has norm 2727 and is not divisible by (3)=ppˉ(3)=\mathfrak p\bar{\mathfrak p}, because μ/3∉Z[79]\mu/3\notin\mathbb{Z}[\sqrt{79}]; so it is p3\mathfrak p^3 or pˉ3\bar{\mathfrak p}^3, and either way [p]3=1[\mathfrak p]^3=1. Hence [p][\mathfrak p] has order exactly 33. The three ideal classes 1,[p],[p]21,[\mathfrak p],[\mathfrak p]^2 are represented by the pseudolattices Z+79Z\mathbb{Z}+\sqrt{79}\mathbb{Z}, 13p=Z+−1+793Z\tfrac13\mathfrak p=\mathbb{Z}+\tfrac{-1+\sqrt{79}}3\mathbb{Z} and 13pˉ=Z+1+793Z\tfrac13\bar{\mathfrak p}=\mathbb{Z}+\tfrac{1+\sqrt{79}}3\mathbb{Z}, whose continued fractions have three different periods, in accordance with Corollary 1.2(iii). ◀\blacktriangleleft

3 Show that TαT_{\alpha} and TβT_\beta are isogenous if and only if β=(aα+b)/(cα+d)\beta=(a\alpha+b)/(c\alpha+d) for an integer matrix of non-zero determinant. Deduce that the tori with real multiplication fall into one isogeny class for each real quadratic field, and that an isogeny class of tori without real multiplication contains infinitely many diffeomorphism classes.

Solution.  An isogeny is a λ≠0\lambda\ne0 with λΛα⊆Λβ\lambda\Lambda_\alpha\subseteq\Lambda_\beta: λ=c′β+d′\lambda=c'\beta+d' and λα=a′β+b′\lambda\alpha=a'\beta+b' with integers such that a′d′−b′c′≠0a'd'-b'c'\ne0 (otherwise α\alpha would be rational). So α\alpha is the image of β\beta under a matrix in GL⁡2(Q)∩M2(Z)\operatorname{GL}_2(\mathbb{Q})\cap M_2(\mathbb{Z}), and inverting, β\beta is the image of α\alpha under such a matrix. The converse is the same computation backwards. If α\alpha is quadratic, its GL⁡2(Q)\operatorname{GL}_2(\mathbb{Q})-orbit is K∖QK\smallsetminus\mathbb{Q} for K=Q(α)K=\mathbb{Q}(\alpha): any β∈K∖Q\beta\in K\smallsetminus\mathbb{Q} is aα+ba\alpha+b with a≠0a\ne0 rational, hence the image of α\alpha under a matrix with integer entries after clearing denominators. So there is one isogeny class per field, and it contains tori with all the orders of KK as endomorphism rings. If α\alpha is not quadratic, the stabiliser of α\alpha in PGL2(Q)\mathrm{PGL}_2(\mathbb{Q}) is trivial, so the isogeny class is in bijection with PGL2(Q)\mathrm{PGL}_2(\mathbb{Q}) and the diffeomorphism classes in it with PGL⁡2(Z)\PGL2(Q)\operatorname{PGL}_2(\mathbb{Z})\backslash\mathrm{PGL}_2(\mathbb{Q}), which is infinite: for instance the tori TpαT_{p\alpha}, pp prime, are pairwise non-diffeomorphic. ◀\blacktriangleleft

3 Describe the local structure of L2\mathfrak L_2 at the square lattice Q=I2Q=I_2 and at the hexagonal lattice . Is L2\mathfrak L_2 a manifold with corners near [I2][I_2]?

Solution.  Use coordinates on Sym⁡2(R)≅R3\operatorname{Sym}_2(\mathbb{R})\cong\mathbb{R}^3. Aut⁡(I2)\operatorname{Aut}(I_2) is the group of signed permutation matrices, of order 88, so Γˉ=Aut⁡/{±1}\bar\Gamma=\operatorname{Aut}/\{\pm1\} has order 44. It is generated by diag(1,−1)\mathrm{diag}(1,-1), acting as (a,b,c)↦(a,−b,c)(a,b,c)\mapsto(a,-b,c), and the swap, acting as (a,b,c)↦(c,b,a)(a,b,c)\mapsto(c,b,a): two commuting reflections, in the planes b=0b=0 and a=ca=c. So near [I2][I_2], L2≅R×(R/{±1})×(R/{±1})=R×Δ1×Δ1\mathfrak L_2\cong\mathbb{R}\times(\mathbb{R}/\{\pm1\})\times(\mathbb{R}/\{\pm1\})=\mathbb{R}\times\Delta_1\times\Delta_1. For the hexagonal lattice Aut⁡\operatorname{Aut} has order 1212 and Γˉ≅S3\bar\Gamma\cong S_3 of order 66, generated by reflections, with local model R×(R2/S3)\mathbb{R}\times(\mathbb{R}^2/S_3). These are the orbifold points ii and eiπ/3e^{i\pi/3} of the modular curve, times the scale. Topologically a neighbourhood of [I2][I_2] is R\mathbb{R} times a quadrant, but it is not a manifold with corners: Δ1≇[0,∞)sub\Delta_1\not\cong[0,\infty)_{\mathrm{sub}} by Proposition 1.11, and the structure group (Z/2)2(\mathbb{Z}/2)^2 is an invariant by 1.6(ii). So the diffeology of the moduli space determines that the boundary of the quadrant consists of mirror points. ◀\blacktriangleleft

4 Let α\alpha be a quadratic irrational with primitive equation Aα2+Bα+C=0A\alpha^2+B\alpha+C=0, Λ=Z+Zα\Lambda=\mathbb{Z}+\mathbb{Z}\alpha and O=Z+ZAα\mathcal O=\mathbb{Z}+\mathbb{Z}A\alpha. Prove that Λ\Lambda is an invertible fractional O\mathcal O-ideal, and complete the proof of 1.2(i).

Solution.  Let αˉ\bar\alpha be the conjugate and Λˉ=Z+Zαˉ\bar\Lambda=\mathbb{Z}+\mathbb{Z}\bar\alpha; then α+αˉ=−B/A\alpha+\bar\alpha=-B/A and ααˉ=C/A\alpha\bar\alpha=C/A. Λ\Lambda is an O\mathcal O-module by Theorem 1.3(ii), and so is Λˉ\bar\Lambda, as Oˉ=O\bar{\mathcal O}=\mathcal O. Compute the product of lattices: ΛΛˉ=Z+Zα+Zαˉ+Zααˉ=Z+Zα+ZBA+ZCA=1A(AZ+BZ+CZ+ZAα)=1A(Z+ZAα)=1AO,\begin{aligned} \Lambda\bar\Lambda&=\mathbb{Z}+\mathbb{Z}\alpha+\mathbb{Z}\bar\alpha+\mathbb{Z}\alpha\bar\alpha=\mathbb{Z}+\mathbb{Z}\alpha+\mathbb{Z}\tfrac BA+\mathbb{Z}\tfrac CA\\ &=\tfrac1A\bigl(A\mathbb{Z}+B\mathbb{Z}+C\mathbb{Z}+\mathbb{Z}A\alpha\bigr)=\tfrac1A\bigl(\mathbb{Z}+\mathbb{Z}A\alpha\bigr)=\tfrac1A\mathcal O, \end{aligned} using αˉ=−B/A−α\bar\alpha=-B/A-\alpha and gcd⁡(A,B,C)=1\gcd(A,B,C)=1. Hence Λ⋅(AΛˉ)=O\Lambda\cdot(A\bar\Lambda)=\mathcal O and Λ\Lambda is invertible with inverse AΛˉA\bar\Lambda.

Now the bijection. Let Λ′\Lambda' be any pseudolattice with OΛ′=O\mathcal O_{\Lambda'}=\mathcal O. Dividing by a non-zero element we may assume Λ′=Z+Zα′\Lambda'=\mathbb{Z}+\mathbb{Z}\alpha'; then Oα′=O≠Z\mathcal O_{\alpha'}=\mathcal O\neq\mathbb{Z} forces α′\alpha' quadratic with Q(α′)=K\mathbb{Q}(\alpha')=K, and by the computation Λ′\Lambda' is an invertible ideal of Oα′=O\mathcal O_{\alpha'}=\mathcal O. So Λ′↦[Λ′]∈Pic⁡(O)\Lambda'\mapsto[\Lambda']\in\operatorname{Pic}(\mathcal O) is defined on homothety classes. It is injective: if Λ′′=μΛ′\Lambda''=\mu\Lambda' with μ∈K×\mu\in K^\times the lattices are homothetic. It is surjective: an invertible fractional ideal a\mathfrak a is a lattice in K⊂RK\subset\mathbb{R} of rank 22, not cyclic, with multiplier ring exactly O\mathcal O — if λa⊆a\lambda\mathfrak a\subseteq\mathfrak a then λO=λaa−1⊆O\lambda\mathcal O=\lambda\mathfrak a\mathfrak a^{-1}\subseteq\mathcal O. Finally homothety classes are diffeomorphism classes by Theorem 1.1(c), and a real λ\lambda with λΛ′=Λ′′\lambda\Lambda'=\Lambda'', both inside KK, lies in KK. ◀\blacktriangleleft

Machine learning: differentiable programs and singular hypothesis spaces

Three places where machine learning already involves more than manifolds. First, the space of functions computed by a model is a quotient of parameter space and a subspace of a function space, and these are two different smooth spaces. Second, the correctness of automatic differentiation for programs with higher-order functions is a theorem about gluing over Diff\mathsf{Diff}. Third, orbit spaces of data symmetries have no differentiable canonical form at points with isotropy. Each is a statement about the quasitopos structure of The quasitopos \mathsf{Diff}.

Source in the book. Quotients, strict maps and the functional diffeology, [IZ, art. 1.50–1.60], and [IZ, Exercises 50–51]. The theorem on automatic differentiation is due to Huot, Staton and Vákár [27].

Hypothesis spaces

A parametric model is a smooth map f ⁣:Θ×X→Yf\colon\Theta\times X\to Y, where Θ\Theta is a space of parameters and X,YX,Y are the spaces of inputs and outputs; think of manifolds, though nothing below requires it. Its realisation map is ρ ⁣:Θ⟶C∞(X,Y),ρ(θ)=f(θ,−).\rho\colon\Theta\longrightarrow C^{\infty}(X,Y),\qquad\rho(\theta)=f(\theta,-). Two parameters are functionally equivalent, θ∼θ′\theta\sim\theta', if ρ(θ)=ρ(θ′)\rho(\theta)=\rho(\theta'). Applying Theorem 1.2 to ρ\rho gives two hypothesis spaces, Θ  ↠  Hq:=Θ/∼  → κ   Hs:=ρ(Θ)sub  ↪  C∞(X,Y),\Theta\;\twoheadrightarrow\;\mathcal H_q:=\Theta/{\sim}\;\xrightarrow{\ \kappa\ }\;\mathcal H_s:=\rho(\Theta)_{\mathrm{sub}}\;\hookrightarrow\;C^{\infty}(X,Y), the quotient and the subspace hypothesis space. They have the same points: the functions the model can compute.

Theorem 1.1 (Smooth learning objects).

  1. ρ\rho is smooth for the functional diffeology, and κ\kappa is a smooth bijection.

  2. Let Y=RkY=\mathbb{R}^k, let μ\mu be a finite Borel measure with compact support on X×RkX\times\mathbb{R}^k, XX a manifold, and ℓ ⁣:Rk×Rk→R\ell\colon\mathbb{R}^k\times\mathbb{R}^k\to\mathbb{R} smooth. The risk R ⁣:C∞(X,Rk)⟶R,R(h)=∫ℓ(h(x),y) dμ(x,y)\mathcal R\colon C^{\infty}(X,\mathbb{R}^k)\longrightarrow\mathbb{R},\qquad\mathcal R(h)=\int\ell\bigl(h(x),y\bigr)\,\mathrm{d}\mu(x,y) is smooth. Hence the training loss L=R∘ρL=\mathcal R\circ\rho is smooth and descends to smooth functions on Hq\mathcal H_q and on Hs\mathcal H_s.

  3. A map out of Hq\mathcal H_q is smooth iff its composite with Θ→Hq\Theta\to\mathcal H_q is; a map into Hs\mathcal H_s is smooth iff its composite with Hs↪C∞(X,Y)\mathcal H_s\hookrightarrow C^{\infty}(X,Y) is, i.e. iff it is a smooth family of functions.

  4. κ\kappa need not be a diffeomorphism: there are models with smooth families of realisable functions that are not induced, even locally, by any smooth family of parameters.

Proof. (i) and (iii) are Theorem 1.9 and Theorem 1.2. (ii) is [exo:risk]. (iv) Take Θ=X=Y=R\Theta=X=Y=\mathbb{R} and f(θ,x)=θ2xf(\theta,x)=\theta^2x. Then ρ(θ)=θ2⋅id\rho(\theta)=\theta^2\cdot\mathrm{id}, the image of ρ\rho is the half-line { c⋅id:c≥0 }\{\,c\cdot\mathrm{id}:c\ge 0\,\} inside the line of linear functions, which is an induced copy of R\mathbb{R} in C∞(R,R)C^{\infty}(\mathbb{R},\mathbb{R}); so Hs≅H\mathcal H_s\cong H and Hq=R/{±1}=Δ1\mathcal H_q=\mathbb{R}/\{\pm1\}=\Delta_1, and κ=sq\kappa=\mathrm{sq} is not a diffeomorphism by Proposition 1.11. The family (r,s)↦(r2+s2) id(r,s)\mapsto(r^2+s^2)\,\mathrm{id} is a plot of Hs\mathcal H_s that does not lift to parameters near (0,0)(0,0). ◻

The phenomenon in (iv) is the general one at singular parameters, where the fibres of ρ\rho change dimension or symmetry type: deep linear networks at rank-deficient products, neural networks at parameters with vanishing or duplicated units. In singular learning theory [55] these points are studied through the local algebraic geometry of the loss. Theorem 1.1 is a structural remark: before any choice of loss there are two canonical smooth structures on the set of hypotheses; they coincide at regular parameters; and where they differ, the quotient structure Hq\mathcal H_q is the one with a universal property for learning dynamics, since dynamics are defined by maps out of Θ\Theta.

Parameters, the two hypothesis spaces, the function space, and the risk. Every arrow is smooth. κ\kappa is bijective, and is a diffeomorphism exactly when the realisation map is strict.

Proposition 1.2 (Symmetric gradient flow). Let a group GG act on Θ=Rp\Theta=\mathbb{R}^p by linear isometries and let L ⁣:Θ→RL\colon\Theta\to\mathbb{R} be smooth, GG-invariant, with complete gradient flow Φt\Phi_t.

  1. Φt\Phi_t is GG-equivariant and descends to a smooth action of (R,+)(\mathbb{R},+) on Θ/G\Theta/G, that is, to a smooth homomorphism R→Diff⁡(Θ/G)\mathbb{R}\to\operatorname{Diff}(\Theta/G).

  2. Stab⁡(Φtθ)=Stab⁡(θ)\operatorname{Stab}(\Phi_t\theta)=\operatorname{Stab}(\theta) for all tt. Hence every fixed subspace ΘK\Theta^K, K≤GK\le G, is invariant under the flow, and the flow on Θ/G\Theta/G preserves the type of each point.

Proof. For an isometry gg, ∇L(gθ)=g∇L(θ)\nabla L(g\theta)=g\nabla L(\theta), so gΦtg\Phi_t and Φtg\Phi_tg solve the same initial value problem. The map R×Θ→Θ→Θ/G\mathbb{R}\times\Theta\to\Theta\to\Theta/G is constant on orbits in the second variable and R×Θ→R×Θ/G\mathbb{R}\times\Theta\to\mathbb{R}\times\Theta/G is a subduction (Proposition 1.7), so we get a smooth R×Θ/G→Θ/G\mathbb{R}\times\Theta/G\to\Theta/G, an action because Φ\Phi is; its adjoint is smooth by Theorem 1.9. For (ii), gΦtθ=Φtθg\Phi_t\theta=\Phi_t\theta iff Φtgθ=Φtθ\Phi_tg\theta=\Phi_t\theta iff gθ=θg\theta=\theta. ◻

For GG a group of permutations and sign changes of hidden units this is the familiar fact that units which start equal stay equal. In the language of Theorem 1.8, gradient flow is a flow on the stack Θ/ ⁣ ⁣/G\Theta/\!\!/G, and the induced flow on the orbit space preserves the stratification by stabilisers.

Correctness of automatic differentiation

Forward-mode automatic differentiation (AD) is a program transformation: replace every real number by a pair (value, derivative) and every primitive operation by its derivative-propagating version. For first-order straight-line programs its correctness is the chain rule. Real languages have higher-order functions, and then even stating correctness requires a semantics in which a program of type (real→real)→real(\mathtt{real}\to\mathtt{real})\to\mathtt{real} denotes a smooth map on a space of smooth maps. Manifolds cannot provide it ([exo:mfd-not-ccc]). Diff\mathsf{Diff} can.

The language.

Types are τ::=real∣τ×τ∣τ→τ\tau::=\mathtt{real}\mid\tau\times\tau\mid\tau\to\tau. Terms are variables, constants c‾\underline c for c∈Rc\in\mathbb{R}, applications op(t1,…,tk)\mathsf{op}(t_1,\dots,t_k) of primitive operations, pairs, projections, λ\lambda-abstractions and applications, with the usual typing rules. The primitive operations form a set Op=⨆kOpk\mathrm{Op}=\bigsqcup_k\mathrm{Op}_k of smooth functions Rk→R\mathbb{R}^k\to\mathbb{R} containing addition and multiplication and closed under partial derivatives.

Semantics.

Put ⟦real⟧=R\llbracket\mathtt{real}\rrbracket=\mathbb{R}, ⟦τ×σ⟧=⟦τ⟧×⟦σ⟧\llbracket\tau\times\sigma\rrbracket=\llbracket\tau\rrbracket\times\llbracket\sigma\rrbracket and ⟦τ→σ⟧=C∞(⟦τ⟧,⟦σ⟧)\llbracket\tau\to\sigma\rrbracket=C^{\infty}(\llbracket\tau\rrbracket,\llbracket\sigma\rrbracket) with the functional diffeology. By Theorem 1.9, Diff\mathsf{Diff} is Cartesian closed, so every term x1:τ1,…,xn:τn⊢t:τx_1{:}\tau_1,\dots,x_n{:}\tau_n\vdash t:\tau has a denotation, a smooth map ⟦t⟧ ⁣:∏i⟦τi⟧→⟦τ⟧\llbracket t\rrbracket\colon\prod_i\llbracket\tau_i\rrbracket\to\llbracket\tau\rrbracket.

The macro.

On types, D(real)=real×real\mathcal{D}(\mathtt{real})=\mathtt{real}\times\mathtt{real}, and D\mathcal{D} commutes with ×\times and →\to. On terms D\mathcal{D} commutes with variables, pairing, projections, abstraction and application, and D(c‾)=⟨c‾,0‾⟩,D(op(t1,…,tk))=⟨op(u⃗), ∑i∂iop(u⃗)⋅ui′⟩where ⟨ui,ui′⟩=D(ti).\mathcal{D}(\underline c)=\langle\underline c,\underline0\rangle,\qquad \mathcal{D}\bigl(\mathsf{op}(t_1,\dots,t_k)\bigr)=\Bigl\langle\mathsf{op}(\vec u),\ \textstyle\sum_{i}\partial_i\mathsf{op}(\vec u)\cdot u_i'\Bigr\rangle \quad\text{where }\langle u_i,u_i'\rangle=\mathcal{D}(t_i).

Theorem 1.3 (Huot–Staton–Vákár [27). ]Let x1:real,…,xn:real⊢t:realx_1{:}\mathtt{real},\dots,x_n{:}\mathtt{real}\vdash t:\mathtt{real} be a term, possibly using higher-order functions internally, and let f=⟦t⟧ ⁣:Rn→Rf=\llbracket t\rrbracket\colon\mathbb{R}^n\to\mathbb{R} and g=⟦D(t)⟧ ⁣:(R×R)n→R×Rg=\llbracket\mathcal{D}(t)\rrbracket\colon(\mathbb{R}\times\mathbb{R})^n\to\mathbb{R}\times\mathbb{R}. Then for all x,v∈Rnx,v\in\mathbb{R}^n, g((x1,v1),…,(xn,vn))=(f(x), Df(x)⋅v).g\bigl((x_1,v_1),\dots,(x_n,v_n)\bigr)=\bigl(f(x),\ Df(x)\cdot v\bigr).

Proof. Define, by induction on the type τ\tau, a relation Sτ⊆C∞(R,⟦τ⟧)×C∞(R,⟦Dτ⟧)S_\tau\subseteq C^{\infty}(\mathbb{R},\llbracket\tau\rrbracket)\times C^{\infty}(\mathbb{R},\llbracket\mathcal{D}\tau\rrbracket) between smooth curves: Sreal={ (h,(h,h′)):h∈C∞(R,R) },Sτ×σ={ ((a1,a2),(b1,b2)):(a1,b1)∈Sτ, (a2,b2)∈Sσ },Sτ→σ={ (a,b):∀(c,d)∈Sτ, (s↦a(s)(c(s)), s↦b(s)(d(s)))∈Sσ }.\begin{aligned} S_{\mathtt{real}}&=\{\,(h,(h,h')) : h\in C^{\infty}(\mathbb{R},\mathbb{R})\,\},\\ S_{\tau\times\sigma}&=\{\,((a_1,a_2),(b_1,b_2)) : (a_1,b_1)\in S_\tau,\ (a_2,b_2)\in S_\sigma\,\},\\ S_{\tau\to\sigma}&=\{\,(a,b) : \forall(c,d)\in S_\tau,\ \bigl(s\mapsto a(s)(c(s)),\ s\mapsto b(s)(d(s))\bigr)\in S_\sigma\,\}. \end{aligned} The last clause makes sense because a curve in a function space composed pointwise with a curve in its source is the composite of (a,c) ⁣:R→C∞(⟦τ⟧,⟦σ⟧)×⟦τ⟧(a,c)\colon\mathbb{R}\to C^{\infty}(\llbracket\tau\rrbracket,\llbracket\sigma\rrbracket)\times\llbracket\tau\rrbracket with the evaluation map, which is smooth. The fundamental lemma ([exo:fundamental]) states: if x1:τ1,…,xn:τn⊢t:τx_1{:}\tau_1,\dots,x_n{:}\tau_n\vdash t:\tau and (ai,bi)∈Sτi(a_i,b_i)\in S_{\tau_i}, then (⟦t⟧∘(a1,…,an), ⟦Dt⟧∘(b1,…,bn))∈Sτ.\bigl(\llbracket t\rrbracket\circ(a_1,\dots,a_n),\ \llbracket\mathcal{D}t\rrbracket\circ(b_1,\dots,b_n)\bigr)\in S_\tau . Apply it to tt of the theorem with ai(s)=xi+svia_i(s)=x_i+sv_i and bi=(ai,ai′)b_i=(a_i,a_i'), which lie in SrealS_{\mathtt{real}}. The conclusion (f∘a, g∘b)∈Sreal(f\circ a,\ g\circ b)\in S_{\mathtt{real}} means g(b(s))=(f(a(s)),(f∘a)′(s))g(b(s))=\bigl(f(a(s)),(f\circ a)'(s)\bigr); evaluate at s=0s=0. ◻

The proof of 1.3 as a lifting problem. Syn\mathsf{Syn} is the syntactic category of the language. An object of Gl\mathsf{Gl} is a triple (X,X′,S)(X,X',S) with S⊆Diff(R,X)×Diff(R,X′)S\subseteq\mathsf{Diff}(\mathbb{R},X)\times\mathsf{Diff}(\mathbb{R},X'), and a morphism is a pair of smooth maps preserving the relations. Gl\mathsf{Gl} is Cartesian closed and the projection functor preserves that structure; since Syn\mathsf{Syn} is the free Cartesian closed category on the primitives, a lift exists as soon as each primitive operation preserves SS, which is the chain rule.

Three comments. First, the role of diffeology is precise and minimal: the proof takes place in a Cartesian closed category containing R\mathbb{R} and its smooth maps, in which curves in function spaces are defined; Theorem 1.9 is the statement that Diff\mathsf{Diff} is one. Second, the same argument gives correctness for sum types, inductive types and, with more work, reverse mode [27]; coproducts in Diff\mathsf{Diff} are computed as in sets (Theorem 1.6), which is what the extension uses. Third, the relation SτS_\tau is a relation between plots. Logical relations over a concrete site are a general technique, and the choice of site is a parameter: with smooth maps replaced by a class of piecewise analytic maps, the method applies to programs with conditionals and recursion [26].

Symmetries: no differentiable canonical form

Let a compact Lie group GG act linearly and orthogonally on V=RnV=\mathbb{R}^n; for instance the symmetric group permuting the points of a point cloud, or a rotation group acting on coordinates. An invariant model is a function on V/GV/G. A popular way to build one is canonicalisation: choose a map y ⁣:V→Vy\colon V\to V that picks a representative of each orbit, y(gv)=y(v),y(v)∈G⋅v(g∈G, v∈V),y(gv)=y(v),\qquad y(v)\in G\cdot v\qquad(g\in G,\ v\in V), and apply an arbitrary network to y(v)y(v). Sorting is a canonicalisation for the symmetric group acting on Rn\mathbb{R}^n. Dym, Lawrence and Siegel show that for many actions of interest no continuous canonicalisation exists [20]. Sorting is continuous, so continuity is not always the obstruction. Differentiability always is, wherever there is isotropy.

Theorem 1.4 (No differentiable canonicalisation at isotropy). Let W⊆VW\subseteq V be a GG-invariant open set and y ⁣:W→Vy\colon W\to V a canonicalisation. Let v∈Wv\in W, with stabiliser GvG_v and normal space Nv=(Tv(G⋅v))⊥N_v=(T_v(G\cdot v))^\perp to its orbit. If yy is differentiable at vv, then GvG_v acts trivially on NvN_v. Consequently:

  1. if GvG_v acts non-trivially on NvN_v, no canonicalisation defined near vv is differentiable at vv;

  2. if GG is finite and acts faithfully, a canonicalisation is non-differentiable at every point with non-trivial stabiliser;

  3. the quotient map π ⁣:V→V/G\pi\colon V\to V/G has a smooth local section near [v][v] only if GvG_v acts trivially on NvN_v.

Proof. Write y(v)=g0vy(v)=g_0v. Replacing yy by g0−1yg_0^{-1}y, which is again a canonicalisation, we may assume y(v)=vy(v)=v. Let A=Dy(v)A=Dy(v).

AA is injective on NvN_v. Let n∈Nvn\in N_v with An=0An=0. Then y(v+tn)=v+o(t)y(v+tn)=v+o(t). Since y(v+tn)=gt(v+tn)y(v+tn)=g_t(v+tn) for some gt∈Gg_t\in G and GG acts by isometries, ∣(v+tn)−gt−1v∣=o(t)\lvert (v+tn)-g_t^{-1}v\rvert=o(t), so the distance from v+tnv+tn to the orbit G⋅vG\cdot v is o(t)o(t). But the orbit is a compact embedded submanifold and nn is normal to it at vv, so by the tubular neighbourhood theorem the distance from v+tnv+tn to the orbit is t∣n∣t\lvert n\rvert for small t≥0t\ge0. Hence n=0n=0.

AA is GvG_v-invariant. For h∈Gvh\in G_v, y(hw)=y(w)y(hw)=y(w) and hh is linear with hv=vhv=v; differentiating at vv gives Ah=AAh=A.

Conclusion. GvG_v preserves the orbit and fixes vv, so it preserves NvN_v. For n∈Nvn\in N_v and h∈Gvh\in G_v we get A(hn)=A(n)A(hn)=A(n) with hn,n∈Nvhn,n\in N_v, so hn=nhn=n.

(a) is the contrapositive. (b) For finite GG orbits are discrete and Nv=VN_v=V, on which GvG_v acts faithfully. (c) If cc is a smooth section of π\pi on a D-open neighbourhood of [v][v] then y=c∘πy=c\circ\pi is a smooth canonicalisation near vv. ◻

Canonicalisation. Left: for the symmetric group S2S_2 the sorting map is continuous but folds the plane along the diagonal, where the stabiliser acts by −1-1 on the normal line. Right: for rotations any section of the orbit map must select a ray, and its composite with the quotient map, v↦∣v∣ ev\mapsto\lvert v\rvert\,e, has a conical singularity at the fixed point.

Remark 1.5 (The converse, and the meaning). By the slice theorem a neighbourhood of the orbit of vv is G×GvNvG\times_{G_v}N_v, so if GvG_v acts trivially on NvN_v the quotient is locally NvN_v and a smooth local section exists. So 1.4(c) is an equivalence: π\pi has smooth local sections exactly over the points where V/GV/G is locally the quotient by a free action. This is Theorem 1.8 at the level of the orbit space: over those points the diffeological quotient is the stack quotient and π\pi is a principal bundle onto its image; elsewhere the orbit space is the coarse space of a stack with non-trivial isotropy, and a section would trivialise an isotropy group that is not trivial. Frame averaging and weighted frames [20] can be read as replacing a section of V→V/GV\to V/G by a section of an associated bundle of measures, which does exist.

The alternative to canonicalisation is to compute invariant features. Choose generators σ1,…,σm\sigma_1,\dots,\sigma_m of the algebra of invariant polynomials, let σ=(σ1,…,σm) ⁣:V→Rm\sigma=(\sigma_1,\dots,\sigma_m)\colon V\to\mathbb{R}^m, and let σˉ ⁣:V/G→σ(V)\bar\sigma\colon V/G\to\sigma(V) be the induced map.

Proposition 1.6 (Invariant features determine functions, not families).

  1. σˉ ⁣:V/G→σ(V)sub\bar\sigma\colon V/G\to\sigma(V)_{\mathrm{sub}} is a smooth bijection.

  2. (Schwarz [50]) It induces an isomorphism on smooth functions: C∞(V/G)=C∞(V)G=σ∗C∞(Rm)=σˉ∗C∞(σ(V)sub)C^{\infty}(V/G)=C^{\infty}(V)^G=\sigma^*C^{\infty}(\mathbb{R}^m)=\bar\sigma^*C^{\infty}(\sigma(V)_{\mathrm{sub}}).

  3. It is not a diffeomorphism in general. For G={±1}G=\{\pm1\} on R\mathbb{R} and on C\mathbb{C}, and for G=O⁡(n)G=\operatorname{O}(n) on Rn\mathbb{R}^n with σ=∣x∣2\sigma=\lvert x\rvert^2, the space σ(V)sub\sigma(V)_{\mathrm{sub}} has plots that do not lift to VV even locally. Moreover the spaces Rn/O⁡(n)\mathbb{R}^n/\operatorname{O}(n), n≥1n\ge1, are pairwise non-diffeomorphic and all have the same image [0,∞)[0,\infty) and the same ring of smooth functions.

Proof. (i) Invariant polynomials separate the orbits of a compact group. (ii) Schwarz’s theorem is the middle equality; the outer ones are the universal property of the quotient and the fact that a smooth function on σ(V)sub\sigma(V)_{\mathrm{sub}} pulls back to a smooth invariant function on VV. (iii) is Proposition 1.11, [exo:cone-hilbert] and [IZ, Exercises 50–51]. ◻

So an invariant feature map is a faithful encoding of the orbit space for the purpose of defining smooth invariant functions, and an unfaithful one for the purpose of describing smooth families of orbits: the feature space contains smooth curves and surfaces of feature values that are not the features of any smooth family of inputs. A generative model trained in feature space can therefore produce smooth interpolations with no smooth preimage. The orbit space V/GV/G with its quotient diffeology is the object whose plots are exactly the liftable families, and by the last sentence of (iii) it determines the dimension of the data, which the features ∣x∣2\lvert x\rvert^2 do not.

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 For the one-neuron model f((a,w),x)=atanh⁡(wx)f((a,w),x)=a\tanh(wx) with Θ=R2\Theta=\mathbb{R}^2, X=Y=RX=Y=\mathbb{R}, determine the functional equivalence relation and describe Hq\mathcal H_q.

Solution.  Let h(x)=atanh⁡(wx)h(x)=a\tanh(wx). Then h′(0)=awh'(0)=aw and h′′′(0)=−2aw3h'''(0)=-2aw^3. If aw=0aw=0 then h=0h=0. If aw≠0aw\neq0 and atanh⁡(wx)=a′tanh⁡(w′x)a\tanh(wx)=a'\tanh(w'x), then aw=a′w′aw=a'w' and aw3=a′w′3aw^3=a'w'^3, so w′2=w2w'^2=w^2 and (a′,w′)=±(a,w)(a',w')=\pm(a,w); conversely tanh⁡\tanh is odd. So the classes are: the cross {aw=0}\{aw=0\}, which is the fibre over the zero function, and the pairs {±(a,w)}\{\pm(a,w)\} with aw≠0aw\ne0. Hq\mathcal H_q is the plane with the cross collapsed to one point and the remaining four open quadrants identified in antipodal pairs: two open quadrants, each a manifold, glued at a single point through which smooth families can pass only by lifting to curves in the plane that reach the cross. It is a manifold away from that point and not a manifold at it. ◀\blacktriangleleft

2 Apply the macro D\mathcal{D} to x:real⊢times(x,sin(x)):realx{:}\mathtt{real}\vdash\mathsf{times}(x,\mathsf{sin}(x)):\mathtt{real} and to x:real⊢(λf. f(f x)) (λz. times(z,z)):realx{:}\mathtt{real}\vdash(\lambda f.\,f(f\,x))\,(\lambda z.\,\mathsf{times}(z,z)):\mathtt{real}, and check 1.3 on both.

Solution.  Write the input as ⟨x,x′⟩\langle x,x'\rangle. For the first term, D(sin(x))=⟨sin⁡x,cos⁡x⋅x′⟩\mathcal{D}(\mathsf{sin}(x))=\langle\sin x,\cos x\cdot x'\rangle and so D(t)=⟨xsin⁡x, sin⁡x⋅x′+x⋅(cos⁡x⋅x′)⟩,\mathcal{D}(t)=\bigl\langle x\sin x,\ \sin x\cdot x'+x\cdot(\cos x\cdot x')\bigr\rangle , using ∂1times(u1,u2)=u2\partial_1\mathsf{times}(u_1,u_2)=u_2 and ∂2times=u1\partial_2\mathsf{times}=u_1. The second component is (xsin⁡x)′x′(x\sin x)'x'. For the second term, D\mathcal{D} commutes with abstraction and application, so D(t)=(λF. F(F ⟨x,x′⟩)) (λ⟨z,z′⟩. ⟨z2,2zz′⟩)\mathcal{D}(t)=(\lambda F.\,F(F\,\langle x,x'\rangle))\,(\lambda\langle z,z'\rangle.\,\langle z^2,2zz'\rangle), where FF now has type real2→real2\mathtt{real}^2\to\mathtt{real}^2. Evaluating, F⟨x,x′⟩=⟨x2,2xx′⟩F\langle x,x'\rangle=\langle x^2,2xx'\rangle and F(F⟨x,x′⟩)=⟨x4, 2x2⋅2xx′⟩=⟨x4,4x3x′⟩F(F\langle x,x'\rangle)=\langle x^4,\,2x^2\cdot2xx'\rangle=\langle x^4,4x^3x'\rangle. The term denotes x↦x4x\mapsto x^4, with derivative 4x34x^3. The higher-order function λf. f(f x)\lambda f.\,f(f\,x) was never differentiated “as a function of ff”; the macro simply changed the type of its argument. ◀\blacktriangleleft

2 Show that y(a,b)=(min⁡(a,b),max⁡(a,b))y(a,b)=(\min(a,b),\max(a,b)) is a continuous canonicalisation for S2S_2 acting on R2\mathbb{R}^2, and verify the conclusion of 1.4 on the diagonal.

Solution.  min⁡\min and max⁡\max are continuous and symmetric, and y(a,b)y(a,b) is (a,b)(a,b) or (b,a)(b,a). At v=(a,a)v=(a,a) the stabiliser is S2S_2, the orbit is the point vv, and Nv=R2N_v=\mathbb{R}^2. The swap acts on NvN_v with eigenvalues +1+1 on the diagonal direction and −1-1 on the antidiagonal direction (1,−1)(1,-1), so it acts non-trivially and the theorem predicts non-differentiability. Indeed y(a+t,a−t)=(a−∣t∣,a+∣t∣)y(a+t,a-t)=(a-\lvert t\rvert,a+\lvert t\rvert), which is not differentiable at t=0t=0. Away from the diagonal the stabiliser is trivial and yy is locally the identity or the swap, hence smooth. ◀\blacktriangleleft

3 Let a Lie group GG act smoothly on a manifold Θ\Theta and let LL be a smooth GG-invariant function. Show that at every critical point θ\theta of LL the Hessian of LL vanishes on the tangent space to the orbit G⋅θG\cdot\theta. Apply this to the rescaling symmetry (a,w)↦(ca,w/c)(a,w)\mapsto(ca,w/c) of the model f((a,w),x)=a⋅relu(wx)f((a,w),x)=a\cdot\mathrm{relu}(wx) restricted to a,w>0a,w>0.

Solution.  For ξ\xi in the Lie algebra let ξΘ\xi_\Theta be the corresponding vector field on Θ\Theta. Invariance gives dL(ξΘ)=0\mathrm{d}L(\xi_\Theta)=0 identically. Differentiate this function in the direction of a tangent vector uu at a critical point θ\theta, in local coordinates: 0=∂u(∂iL ξΘi)=HessL(u,ξΘ(θ))+∂iL(θ) ∂uξΘi0=\partial_u(\partial_iL\,\xi^i_\Theta)=\mathrm{Hess}L(u,\xi_\Theta(\theta))+\partial_iL(\theta)\,\partial_u\xi^i_\Theta, and the second term vanishes because dL(θ)=0\mathrm{d}L(\theta)=0. Hence HessL(θ)(u,ξΘ(θ))=0\mathrm{Hess}L(\theta)(u,\xi_\Theta(\theta))=0 for all uu. For the rescaling symmetry on {a,w>0}\{a,w>0\}, relu(wx)\mathrm{relu}(wx) is positively homogeneous in ww, so ff and therefore any loss is invariant; the group is (R>0,⋅)(\mathbb{R}_{>0},\cdot) with generating vector field (a,−w)(a,-w). So at every critical point the Hessian has (a,−w)(a,-w) in its kernel: critical points are never isolated and never non-degenerate. In Hq\mathcal H_q the whole orbit is one point, and the degeneracy disappears; this is the practical meaning of the universal property in 1.1(iii). ◀\blacktriangleleft

3 Prove 1.1(ii), and show that evaluation at a point x0x_0 is a smooth map C∞(X,Rk)→RkC^{\infty}(X,\mathbb{R}^k)\to\mathbb{R}^k which is the special case μ=δ\mu=\delta.

Solution.  Let P ⁣:U→C∞(X,Rk)P\colon U\to C^{\infty}(X,\mathbb{R}^k) be a plot. By Definition 1.8 the map (r,x)↦P(r)(x)(r,x)\mapsto P(r)(x) is smooth on U×XU\times X, so F(r,x,y)=ℓ(P(r)(x),y)F(r,x,y)=\ell(P(r)(x),y) is smooth on U×X×RkU\times X\times\mathbb{R}^k. We must show that I(r)=∫F(r,x,y) dμ(x,y)I(r)=\int F(r,x,y)\,\mathrm{d}\mu(x,y) is smooth on UU. Let CC be the compact support of μ\mu and B⊂UB\subset U a compact ball. Every partial derivative ∂rβF\partial_r^\beta F is continuous, hence bounded on B×CB\times C, and μ\mu is finite. By dominated convergence II is continuous on BB, and differentiation under the integral sign is justified for every ∂rβ\partial_r^\beta by the mean value inequality with the bound on ∂rβ+eiF\partial_r^{\beta+e_i}F; induction on ∣β∣\lvert \beta\rvert gives I∈C∞(B)I\in C^{\infty}(B). So R∘P\mathcal R\circ P is smooth for every plot PP, i.e. R\mathcal R is smooth. Then L=R∘ρL=\mathcal R\circ\rho is smooth, it is constant on the fibres of ρ\rho, so it descends to Hq\mathcal H_q by the universal property of the quotient, and to Hs\mathcal H_s as the restriction of R\mathcal R. For the last assertion take μ\mu the Dirac measure at (x0,0)(x_0,0) and ℓ(h,y)=hj\ell(h,y)=h_j; or note directly that evaluation at x0x_0 is the composite of ev ⁣:C∞(X,Rk)×X→Rk\mathrm{ev}\colon C^{\infty}(X,\mathbb{R}^k)\times X\to\mathbb{R}^k with h↦(h,x0)h\mapsto(h,x_0). ◀\blacktriangleleft

4 Prove the fundamental lemma used in the proof of 1.3.

Solution.  We prove by induction on the typing derivation of Γ⊢t:τ\Gamma\vdash t:\tau, with Γ=x1:τ1,…,xn:τn\Gamma=x_1{:}\tau_1,\dots,x_n{:}\tau_n, that for all (ai,bi)∈Sτi(a_i,b_i)\in S_{\tau_i} the pair (⟦t⟧∘a⃗, ⟦Dt⟧∘b⃗)\bigl(\llbracket t\rrbracket\circ\vec a,\ \llbracket\mathcal{D}t\rrbracket\circ\vec b\bigr) lies in SτS_\tau. Here a⃗=(a1,…,an) ⁣:R→⟦Γ⟧\vec a=(a_1,\dots,a_n)\colon\mathbb{R}\to\llbracket\Gamma\rrbracket and b⃗ ⁣:R→⟦DΓ⟧\vec b\colon\mathbb{R}\to\llbracket\mathcal{D}\Gamma\rrbracket; both composites are smooth curves because denotations are smooth maps.

Variable xix_i: the pair is (ai,bi)(a_i,b_i).

Constant c‾\underline c: the pair is (s↦c, s↦(c,0))(s\mapsto c,\ s\mapsto(c,0)), and 00 is the derivative of the constant curve.

Operation op(t1,…,tk)\mathsf{op}(t_1,\dots,t_k): by induction ⟦tj⟧∘a⃗=hj\llbracket t_j\rrbracket\circ\vec a=h_j and ⟦Dtj⟧∘b⃗=(hj,hj′)\llbracket\mathcal{D}t_j\rrbracket\circ\vec b=(h_j,h_j') for smooth hj ⁣:R→Rh_j\colon\mathbb{R}\to\mathbb{R}. By the definition of the macro, ⟦D op(t⃗)⟧∘b⃗=(op(h1,…,hk), ∑j∂jop(h1,…,hk) hj′),\llbracket\mathcal{D}\,\mathsf{op}(\vec t)\rrbracket\circ\vec b=\Bigl(\mathsf{op}(h_1,\dots,h_k),\ \sum_j\partial_j\mathsf{op}(h_1,\dots,h_k)\,h_j'\Bigr), and by the chain rule the second component is the derivative of s↦op(h1(s),…,hk(s))=⟦op(t⃗)⟧(a⃗(s))s\mapsto\mathsf{op}(h_1(s),\dots,h_k(s))=\llbracket\mathsf{op}(\vec t)\rrbracket(\vec a(s)).

Pairing and projections: immediate from the definition of Sτ×σS_{\tau\times\sigma} and the fact that D\mathcal{D} commutes with them.

Application t ut\,u with Γ⊢t:σ→τ\Gamma\vdash t:\sigma\to\tau and Γ⊢u:σ\Gamma\vdash u:\sigma: by induction (a,b)=(⟦t⟧∘a⃗,⟦Dt⟧∘b⃗)∈Sσ→τ(a,b)=(\llbracket t\rrbracket\circ\vec a,\llbracket\mathcal{D}t\rrbracket\circ\vec b)\in S_{\sigma\to\tau} and (c,d)=(⟦u⟧∘a⃗,⟦Du⟧∘b⃗)∈Sσ(c,d)=(\llbracket u\rrbracket\circ\vec a,\llbracket\mathcal{D}u\rrbracket\circ\vec b)\in S_\sigma. By the definition of Sσ→τS_{\sigma\to\tau} the pair (s↦a(s)(c(s)), s↦b(s)(d(s)))(s\mapsto a(s)(c(s)),\ s\mapsto b(s)(d(s))) is in SτS_\tau, and these curves are ⟦t u⟧∘a⃗\llbracket t\,u\rrbracket\circ\vec a and ⟦D(t u)⟧∘b⃗\llbracket\mathcal{D}(t\,u)\rrbracket\circ\vec b because D(t u)=Dt Du\mathcal{D}(t\,u)=\mathcal{D}t\ \mathcal{D}u and application denotes evaluation.

Abstraction λx:σ. t\lambda x{:}\sigma.\,t with Γ,x:σ⊢t:τ\Gamma,x{:}\sigma\vdash t:\tau: we must show that (a,b)=(⟦λx.t⟧∘a⃗, ⟦D(λx.t)⟧∘b⃗)∈Sσ→τ(a,b)=(\llbracket\lambda x.t\rrbracket\circ\vec a,\ \llbracket\mathcal{D}(\lambda x.t)\rrbracket\circ\vec b)\in S_{\sigma\to\tau}. Let (c,d)∈Sσ(c,d)\in S_\sigma. Then a(s)(c(s))=⟦t⟧(a⃗(s),c(s))a(s)(c(s))=\llbracket t\rrbracket(\vec a(s),c(s)) and, since D(λx.t)=λx.Dt\mathcal{D}(\lambda x.t)=\lambda x.\mathcal{D}t, b(s)(d(s))=⟦Dt⟧(b⃗(s),d(s))b(s)(d(s))=\llbracket\mathcal{D}t\rrbracket(\vec b(s),d(s)). The extended tuples (a⃗,c)(\vec a,c) and (b⃗,d)(\vec b,d) are related componentwise, so the induction hypothesis for tt in the context Γ,x:σ\Gamma,x{:}\sigma gives exactly that these two curves are related by SτS_\tau.

This completes the induction. The only case with analytic content is that of the primitive operations; the rest is the statement that the relations SτS_\tau are defined so as to be preserved by the Cartesian closed structure, and smoothness of all curves involved is Theorem 1.9. ◀\blacktriangleleft

Artificial intelligence: planning, observation, semantics

Three questions about agents, answered in Diff\mathsf{Diff}. When can an agent plan motions smoothly in the start and goal? Exactly when its configuration space is smoothly contractible, and for quasi-tori exactly when it is given a homotopy class of route. What can an agent learn about a space from smooth scalar observations alone? Its reflexive hull, and nothing more. In what categories do programs that manipulate functions, probabilities and derivatives have semantics? In categories of concrete sheaves, of which Diff\mathsf{Diff} is the smooth instance.

Source in the book. [IZ, art. 5.1–5.11] (paths, homotopy, contractibility), [IZ, Exercises 79–80] (reflexive spaces), [IZ, art. 1.57–1.60] (functional diffeology).

Smooth motion planning

Let XX be the configuration space of a mechanical system. For rigid robots it is a manifold; for linkages at singular configurations, for identical robots that may be relabelled, for soft bodies whose configurations are embeddings of a curve or a surface, it is not, but it is always a diffeological space. The endpoint map ends ⁣:Paths⁡(X)⟶X×X,γ⟼(γ(0),γ(1))\mathrm{ends}\colon\operatorname{Paths}(X)\longrightarrow X\times X,\qquad\gamma\longmapsto(\gamma(0),\gamma(1)) is smooth. Following Farber [21], a motion planner on A⊆X×XA\subseteq X\times X is a section of ends\mathrm{ends} over AA; we call it smooth if it is smooth as a map Asub→Paths⁡(X)A_{\mathrm{sub}}\to\operatorname{Paths}(X), which by Theorem 1.9 means that the path s(a,b)s(a,b) depends smoothly on (a,b)(a,b) jointly with time. The smooth topological complexity TC⁡D(X)\operatorname{TC}^D(X) is the least number of D-open subsets covering X×XX\times X each of which carries a smooth motion planner, or ∞\infty.

Theorem 1.1 (Smooth planners). Let XX be a non-empty diffeological space.

  1. XX has a smooth motion planner on all of X×XX\times X if and only if XX is smoothly contractible.

  2. If XX is smoothly dominated by YY — there are smooth f ⁣:X→Yf\colon X\to Y and g ⁣:Y→Xg\colon Y\to X with g∘fg\circ f smoothly homotopic to idX\mathrm{id}_X — then TC⁡D(X)≤TC⁡D(Y)\operatorname{TC}^D(X)\le\operatorname{TC}^D(Y). In particular TC⁡D\operatorname{TC}^D is an invariant of smooth homotopy type.

  3. If TC⁡D(X)<∞\operatorname{TC}^D(X)<\infty then XX is connected, and if TC⁡D(X)=1\operatorname{TC}^D(X)=1 then ΠX≃∗\Pi X\simeq\ast.

Proof. (i) Let ss be a smooth planner and fix x0x_0. The map H(x,t)=s(x,x0)(t)H(x,t)=s(x,x_0)(t) is smooth on X×RX\times\mathbb{R} by Theorem 1.9, with H(x,0)=xH(x,0)=x and H(x,1)=x0H(x,1)=x_0: a contraction. Conversely let H ⁣:X×R→XH\colon X\times\mathbb{R}\to X be smooth with H0=idH_0=\mathrm{id} and H1≡x0H_1\equiv x_0, and let λ\lambda be a smashing function ([exo:smash]). Define s(x,y)(t)={H(x,λ(2t))t≤12,H(y,λ(2−2t))t≥12.s(x,y)(t)=\begin{cases}H\bigl(x,\lambda(2t)\bigr)&t\le\tfrac12,\\[0.3ex]H\bigl(y,\lambda(2-2t)\bigr)&t\ge\tfrac12.\end{cases} Both expressions are smooth in (x,y,t)(x,y,t) and both equal x0x_0 for tt near 12\tfrac12, so s ⁣:X×X×R→Xs\colon X\times X\times\mathbb{R}\to X is smooth, i.e. s ⁣:X×X→Paths⁡(X)s\colon X\times X\to\operatorname{Paths}(X) is smooth. And s(x,y)(0)=H(x,0)=xs(x,y)(0)=H(x,0)=x, s(x,y)(1)=H(y,0)=ys(x,y)(1)=H(y,0)=y. (ii) is [exo:TC-invariance]. (iii) A planner on a D-open cover joins any two points by a path. If TC⁡D(X)=1\operatorname{TC}^D(X)=1, apply (i) and Proposition 1.1. ◻

The proof of (i) is Farber’s, and that is the point: in Diff\mathsf{Diff} it holds verbatim for every space, because “a family of paths depending smoothly on its endpoints” and “a smooth map into the path space” are the same thing. For manifolds one usually settles for continuous planners; for the singular and infinite-dimensional configuration spaces listed above there was previously no category in which to say “smooth planner” at all.

Three planning problems. On the circle no single smooth rule works. On the cross, a singular space, one does. On the irrational torus no rule works on any D-open set, but a smooth rule exists once the homotopy class of the route is part of the input (1.2).

Proposition 1.2 (Planning on quasi-tori). Let Γ⊂Rn\Gamma\subset\mathbb{R}^n be a dense countable subgroup and TΓ=Rn/ΓT_\Gamma=\mathbb{R}^n/\Gamma, for instance TαT_{\alpha}.

  1. The only D-open subsets of TΓ×TΓT_\Gamma\times T_\Gamma are ∅\varnothing and the whole space, and TΓT_\Gamma is not contractible if Γ≠0\Gamma\ne0. Hence TC⁡D(TΓ)=∞\operatorname{TC}^D(T_\Gamma)=\infty.

  2. Let Π1(TΓ)=(Rn×Rn)/Γdiag\Pi_1(T_\Gamma)=(\mathbb{R}^n\times\mathbb{R}^n)/\Gamma_{\mathrm{diag}}, the quotient by the diagonal action; it is the space of triples (start, goal, homotopy class of paths between them), and it covers TΓ×TΓT_\Gamma\times T_\Gamma with group Γ\Gamma. The straight-line rule s[x,y](t)=q((1−t)x+ty)s[x,y](t)=q\bigl((1-t)x+ty\bigr) is a well-defined smooth map Π1(TΓ)→Paths⁡(TΓ)\Pi_1(T_\Gamma)\to\operatorname{Paths}(T_\Gamma) lifting the covering: a smooth planner whose input includes a class of route.

  3. No smooth planner defined on TΓ×TΓT_\Gamma\times T_\Gamma, or on any non-empty D-open subset of it, exists; and ss does not descend, because s[x,y]s[x,y] and s[x,y+γ]s[x,y+\gamma] have the same endpoints and are not homotopic for γ≠0\gamma\ne0.

Proof. (i) [exo:Dtop-Talpha] for the D-topology; π1(TΓ)=Γ\pi_1(T_\Gamma)=\Gamma by Corollary 1.5; then 1.1(i). (ii) The diagonal action is principal, so Π1(TΓ)\Pi_1(T_\Gamma) is a diffeological space and R2n→Π1(TΓ)→TΓ2\mathbb{R}^{2n}\to\Pi_1(T_\Gamma)\to T_\Gamma^2 are coverings; a point of Π1(TΓ)\Pi_1(T_\Gamma) over (a,b)(a,b) is a choice of lifts of a,ba,b up to simultaneous translation, which is a homotopy class of paths from aa to bb by [exo:pi1-Talpha]. The map (x,y,t)↦q((1−t)x+ty)(x,y,t)\mapsto q((1-t)x+ty) is smooth and invariant under (x,y)↦(x+γ,y+γ)(x,y)\mapsto(x+\gamma,y+\gamma), since qq is Γ\Gamma-invariant; so it descends along the subduction R2n×R→Π1(TΓ)×R\mathbb{R}^{2n}\times\mathbb{R}\to\Pi_1(T_\Gamma)\times\mathbb{R}. (iii) The first statement is (i). The lifts of s[x,y]s[x,y] and s[x,y+γ]s[x,y+\gamma] starting at xx end at yy and y+γy+\gamma. ◻

For an agent this is a statement about what must be sensed. A system whose state is known only modulo a dense group — two encoders with incommensurable periods, a phase known modulo two incommensurable clocks — cannot be controlled by any smooth law in the quotient state alone, not even locally. It can be controlled smoothly given a lift, that is, with odometry; and the amount of extra state needed is exactly the fundamental group. In stack-theoretic terms, the planner is defined on the atlas of the fundamental groupoid.

Remark 1.3 (Cohomological bounds). A D-open cover {A,B}\{A,B\} of XX is a pushout in SmoothSet\mathsf{SmoothSet}, hence a homotopy pushout in H\mathbf{H}, and Π\Pi preserves it; so Mayer–Vietoris holds for the cohomology of the shape, and the usual lower bound of TC⁡\operatorname{TC} by the zero-divisor cup-length of H∙(ΠX)H^\bullet(\Pi X) holds for TC⁡D\operatorname{TC}^D with the usual proof. For manifolds TC⁡D≥TC⁡\operatorname{TC}^D\ge\operatorname{TC} trivially; whether equality holds is a question about smoothing sections (Coda).

Observation versus intervention

An agent can interrogate an unknown smooth world XX in two ways. It can observe: measure smooth real-valued quantities f ⁣:X→Rf\colon X\to\mathbb{R}. Or it can intervene: run a smoothly parametrised family of experiments P ⁣:U→XP\colon U\to X. A diffeology is a specification of the possible interventions; a Sikorski or Frölicher structure is a specification of the possible observations. For a set XX, a set D\mathcal D of parametrisations and a set F\mathcal F of real functions, define Fun(D)={ f ⁣:X→R:f∘P is smooth for all P∈D },Plot(F)={ P∈Param(X):f∘P is smooth for all f∈F }.\begin{aligned} \mathrm{Fun}(\mathcal D)&=\{\,f\colon X\to\mathbb{R}: f\circ P\text{ is smooth for all }P\in\mathcal D\,\},\\ \mathrm{Plot}(\mathcal F)&=\{\,P\in\mathrm{Param}(X) : f\circ P\text{ is smooth for all }f\in\mathcal F\,\}. \end{aligned}

Theorem 1.4 (The observation–intervention Galois connection).

  1. Fun\mathrm{Fun} and Plot\mathrm{Plot} are order-reversing, D⊆Plot Fun(D)\mathcal D\subseteq\mathrm{Plot}\,\mathrm{Fun}(\mathcal D), F⊆Fun Plot(F)\mathcal F\subseteq\mathrm{Fun}\,\mathrm{Plot}(\mathcal F), and Fun Plot Fun=Fun\mathrm{Fun}\,\mathrm{Plot}\,\mathrm{Fun}=\mathrm{Fun}, Plot Fun Plot=Plot\mathrm{Plot}\,\mathrm{Fun}\,\mathrm{Plot}=\mathrm{Plot}.

  2. Plot(F)\mathrm{Plot}(\mathcal F) is a diffeology for every F\mathcal F. For a diffeology D\mathcal D, the reflexive hull D^=Plot Fun(D)\hat{\mathcal D}=\mathrm{Plot}\,\mathrm{Fun}(\mathcal D) is the largest diffeology on XX with the same smooth real functions as D\mathcal D.

  3. Two diffeologies on XX have the same smooth real functions if and only if they have the same reflexive hull.

  4. X↦X^=(X,D^)X\mapsto\hat X=(X,\hat{\mathcal D}) is a functor, and X→X^X\to\hat X is the universal smooth map from XX to a reflexive space, one with D=D^\mathcal D=\hat{\mathcal D}.

  5. Manifolds, half-spaces and corners are reflexive. The hull of TαT_{\alpha} is the coarse diffeology; the hull of Δ1=R/{±1}\Delta_1=\mathbb{R}/\{\pm1\} is the half-line HH; the hull of the wire diffeology on Rn\mathbb{R}^n is the standard diffeology.

Proof. (i) is formal for any relation: here the relation between PP and ff is “f∘Pf\circ P is smooth”. (ii) Constants, locality and smooth reparametrisation are each preserved by the condition “f∘Pf\circ P smooth”, so Plot(F)\mathrm{Plot}(\mathcal F) satisfies [D1]–[D3]. By (i), Fun(D^)=Fun(D)\mathrm{Fun}(\hat{\mathcal D})=\mathrm{Fun}(\mathcal D), and if D′\mathcal D' is a diffeology with Fun(D′)=Fun(D)\mathrm{Fun}(\mathcal D')=\mathrm{Fun}(\mathcal D) then D′⊆Plot Fun(D′)=D^\mathcal D'\subseteq\mathrm{Plot}\,\mathrm{Fun}(\mathcal D')=\hat{\mathcal D}. (iii) follows. (iv) Let f ⁣:X→Yf\colon X\to Y be smooth and P∈D^XP\in\hat{\mathcal D}_X. For g∈Fun(DY)g\in\mathrm{Fun}(\mathcal D_Y) we have g∘f∈Fun(DX)g\circ f\in\mathrm{Fun}(\mathcal D_X), so g∘f∘Pg\circ f\circ P is smooth; hence f∘P∈D^Yf\circ P\in\hat{\mathcal D}_Y. So f ⁣:X^→Y^f\colon\hat X\to\hat Y is smooth, and if YY is reflexive ff factors through X→X^X\to\hat X, uniquely since that map is the identity on points. (v) For a manifold MM, let PP be a parametrisation along which all smooth functions are smooth. Testing against bump functions shows PP is continuous, and testing against coordinate functions cut off by bump functions shows PP is smooth in charts. Half-spaces and corners: the same argument with Theorem 1.1. For TαT_{\alpha}, Fun\mathrm{Fun} is the constants (Proposition 1.10) and every parametrisation is smooth along constants. For Δ1\Delta_1, Fun\mathrm{Fun} is { g∘sq:g∈C∞(R) }\{\,g\circ\mathrm{sq}:g\in C^{\infty}(\mathbb{R})\,\} by [exo:halfline-functions], and a parametrisation PP of [0,∞)[0,\infty) with g∘Pg\circ P smooth for all smooth gg is a smooth map into R\mathbb{R} with values in [0,∞)[0,\infty): a plot of HH. For the wire diffeology, Fun\mathrm{Fun} consists of the functions smooth along all smooth curves, which by Boman’s theorem [6] are the smooth functions; then Plot\mathrm{Plot} of those is the standard diffeology by the manifold case. ◻

The Galois connection between interventions and observations. Its closed elements on the left are the reflexive diffeologies.

Theorem 1.5 ([4). ; [IZ, Exercises 79–80]]The full subcategory of reflexive diffeological spaces is isomorphic to the category of Frölicher spaces, and it is a reflective subcategory of Diff\mathsf{Diff} with reflector X↦X^X\mapsto\hat X.

Together these make a precise epistemic statement. An agent restricted to smooth scalar observations can identify a smooth world only up to its reflexive hull. It cannot tell the irrational torus from a structureless set, the orbifold R/{±1}\mathbb{R}/\{\pm1\} from a half-line, or a plane in which only one-dimensional motions are possible from an ordinary plane. Each pair is separated by an intervention: a plot of one that is not a plot of the other. The hull is a closure operator, so there is a canonical “most permissive world consistent with all observations”, and by the theorem observation-based learning of smooth structure converges, at best, to that world. This is the differential-geometric version of the familiar gap between observational and interventional data, and the reason is the one given in Functions versus plots: observations are maps out, quotients are colimits, and the maps out of a colimit do not determine the diagram of which it is the colimit.

Semantic universes for programs

Theorem 1.3 used one property of Diff\mathsf{Diff}: it is a Cartesian closed category of spaces defined by plots. The same construction over other sites gives the semantic categories used for probabilistic and differentiable programming, and the theorem that makes them work is the same.

Theorem 1.6 (Cartesian closure for concrete sheaves; [17, 3). ]Let C\mathcal C be a concrete site with finite products, preserved by the functor of points. Then ConcSh(C)\mathsf{ConcSh}(\mathcal C) is Cartesian closed: for concrete sheaves X,YX,Y, the set Hom⁡(X,Y)\operatorname{Hom}(X,Y) with plots { P ⁣:∣U∣→Hom⁡(X,Y):(u,x)↦P(u)(x) is a morphism U×X→Y }\{\,P\colon|U|\to\operatorname{Hom}(X,Y) : (u,x)\mapsto P(u)(x)\text{ is a morphism }U\times X\to Y\,\} is a concrete sheaf YXY^X, and Hom⁡(Z×X,Y)≅Hom⁡(Z,YX)\operatorname{Hom}(Z\times X,Y)\cong\operatorname{Hom}(Z,Y^X) naturally.

Proof. The proof of Theorem 1.9 in [exo:ccc] used three facts: a plot is a morphism from a representable, products of representables are representable, and a pair of plots is a plot of the product. All hold here. It remains to see that YXY^X satisfies the sheaf condition. Let P ⁣:∣U∣→Hom⁡(X,Y)P\colon|U|\to\operatorname{Hom}(X,Y) restrict to plots on a covering family {Ui→U}\{U_i\to U\}. A plot of U×XU\times X is a pair (ρ,Q) ⁣:V→U×X(\rho,Q)\colon V\to U\times X; the pullback of the cover along ρ\rho is refined by a cover {Vj→V}\{V_j\to V\} on each member of which ρ\rho factors through some UiU_i, so v↦P(ρ(v))(Q(v))v\mapsto P(\rho(v))(Q(v)) is a plot of YY on each VjV_j, hence a plot of YY because YY is a sheaf. ◻

Corollary 1.7 (Quasi-Borel spaces; Heunen–Kammar–Staton–Yang [25). ]A quasi-Borel space is a set XX with a set MXM_X of functions R→X\mathbb{R}\to X containing the constants, closed under precomposition with Borel maps R→R\mathbb{R}\to\mathbb{R}, and closed under gluing along countable Borel partitions of R\mathbb{R}. These are the concrete sheaves on the site of standard Borel spaces with countable Borel covers, and they form a Cartesian closed category, whereas the category of measurable spaces is not Cartesian closed [2].

The three axioms of a quasi-Borel space are [D1], [D3] and [D2] with “smooth” replaced by “Borel” and open covers by countable Borel partitions. The parallel is exact (1.1): in each row a classical category of spaces lacks function spaces, and the category of concrete sheaves on its site of parameter spaces has them. For artificial intelligence the relevance is that a probabilistic program which takes a likelihood function as an argument, or a differentiable program which takes a loss function as an argument, has a denotation only in the right-hand column.

Three instances of one theorem. The second column is why semantics cannot be given in the first; the third is 1.6.
classical spaces defect concrete sheaves used for
manifolds no C∞(M,N)C^{\infty}(M,N), no quotients diffeological spaces differentiable programming [27]
measurable spaces no measurable YXY^X [2] quasi-Borel spaces probabilistic programming [25]
piecewise analytic maps as above, plus recursion ω\omegaPAP spaces AD with control flow [26]

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Write down a global smooth motion planner on a star-shaped open subset of Rn\mathbb{R}^n and on the cross K={ xy=0 }⊂R2K=\{\,xy=0\,\}\subset\mathbb{R}^2.

Solution.  Let XX be star-shaped about x0x_0, or X=KX=K with x0=0x_0=0. In both cases H(x,t)=x0+(1−λ(t))(x−x0)H(x,t)=x_0+(1-\lambda(t))(x-x_0) is a smooth contraction with values in XX: for the cross, scaling preserves { xy=0 }\{\,xy=0\,\}, and HH is smooth into R2\mathbb{R}^2 with values in KK, hence smooth into KsubK_{\mathrm{sub}}. The planner of 1.1(i) assigns the path that runs from xx to x0x_0 along the segment, is stationary near x0x_0, and runs on to yy. On a convex set the simpler rule s(x,y)(t)=(1−t)x+tys(x,y)(t)=(1-t)x+ty also works; on the cross it does not, since the segment between points on different arms is not contained in KK. ◀\blacktriangleleft

2 Show that TC⁡D(S1)=2\operatorname{TC}^D(S^1)=2.

Solution.  S1S^1 is not contractible (π1=Z\pi_1=\mathbb{Z}), so TC⁡D(S1)≥2\operatorname{TC}^D(S^1)\ge2 by 1.1(i). Write points as eiθe^{i\theta}. On A1={ (a,b):b≠−a }A_1=\{\,(a,b):b\ne-a\,\} there is a unique ϕ∈(−π,π)\phi\in(-\pi,\pi) with b=aeiϕb=ae^{i\phi}, depending smoothly on (a,b)(a,b); put s1(a,b)(t)=aeiλ(t)ϕs_1(a,b)(t)=ae^{i\lambda(t)\phi}, the shortest arc. On A2={ (a,b):b≠a }A_2=\{\,(a,b):b\ne a\,\} there is a unique ψ∈(0,2π)\psi\in(0,2\pi) with b=aeiψb=ae^{i\psi}, depending smoothly on (a,b)(a,b); put s2(a,b)(t)=aeiλ(t)ψs_2(a,b)(t)=ae^{i\lambda(t)\psi}, the anticlockwise arc. Both are smooth sections of the endpoint map over open sets, and A1∪A2=S1×S1A_1\cup A_2=S^1\times S^1. ◀\blacktriangleleft

2 The configuration space of two indistinguishable points on a line is C=R2/S2C=\mathbb{R}^2/S_2. Show that it has a global smooth motion planner, although (Theorem 1.4) there is no smooth way to label the two points.

Solution.  In the coordinates u=a+bu=a+b, w=a−bw=a-b the swap is (u,w)↦(u,−w)(u,w)\mapsto(u,-w), so C≅R×Δ1C\cong\mathbb{R}\times\Delta_1. Both factors are smoothly contractible ([exo:contractible]), hence so is the product, and 1.1(i) gives a planner. Explicitly, the contraction h((a,b),t)=(1−λ(t))(a,b)h((a,b),t)=(1-\lambda(t))(a,b) of R2\mathbb{R}^2 is S2S_2-equivariant and descends: the planner moves both points to the origin and out again. A smooth labelling would be a smooth section of R2→C\mathbb{R}^2\to C near the diagonal, which does not exist by [exo:sort] and Theorem 1.4. Planning and labelling are different tasks: the planner is a map out of C×CC\times C, the labelling a map out of CC into the covering space. ◀\blacktriangleleft

3 Let XX be R2\mathbb{R}^2 with the wire diffeology and X′X' the set R2\mathbb{R}^2 with the diffeology D′\mathcal D' generated by the lines parallel to the two axes. Determine Fun\mathrm{Fun} for both. Show that an observer cannot distinguish XX from the standard plane, can distinguish X′X' from it, and that X′X' is nevertheless not reflexive.

Solution.  XX. By 1.4(v) the hull of the wire diffeology is the standard one: same observables as the plane. The identity R2→R2\mathbb{R}^2\to\mathbb{R}^2 is an intervention available in the plane and not in XX ([exo:wire]).

X′X'. A plot is locally constant or locally of the form r↦(h(r),c)r\mapsto(h(r),c) or r↦(c,h(r))r\mapsto(c,h(r)) with hh smooth. So Fun(D′)\mathrm{Fun}(\mathcal D') is the set of separately smooth functions: f(⋅,c)f(\cdot,c) and f(c,⋅)f(c,\cdot) smooth for every cc. It is strictly larger than C∞(R2)C^{\infty}(\mathbb{R}^2): f(x,y)=xy/(x2+y2)f(x,y)=xy/(x^2+y^2), f(0,0)=0f(0,0)=0, is separately smooth and discontinuous. So an observer who finds ff among the observables knows the world is not the standard plane.

The hull of X′X' excludes diagonal motion. The curve c(t)=(t,t)c(t)=(t,t) is not in Plot Fun(D′)\mathrm{Plot}\,\mathrm{Fun}(\mathcal D'), since f∘cf\circ c takes the value 00 at t=0t=0 and 12\tfrac12 elsewhere. More generally, if PP is in the hull then PP is smooth, the coordinates being observables, and at every point rr one of dP1(r)\mathrm{d}P_1(r), dP2(r)\mathrm{d}P_2(r) vanishes: otherwise some direction vv has dP1(v)≠0≠dP2(v)\mathrm{d}P_1(v)\ne0\ne\mathrm{d}P_2(v), and the translate of ff to P(r)P(r) is discontinuous along t↦P(r+tv)t\mapsto P(r+tv).

The hull of X′X' is larger than D′\mathcal D'. With φ\varphi as in [exo:cross], let P(t)=(φ(−t),φ(t))P(t)=(\varphi(-t),\varphi(t)), the curve that turns the corner at the origin. For a separately smooth ff put g=f(⋅,0)g=f(\cdot,0) and k=f(0,⋅)k=f(0,\cdot), both smooth. Then f(P(t))=g(φ(−t))+k(φ(t))−f(0,0)f(P(t))=g(\varphi(-t))+k(\varphi(t))-f(0,0) for all tt, a smooth function. So PP is in the hull. But PP is not a plot of D′\mathcal D': near t=0t=0 it lies in no single line. Hence D′⊊D′^\mathcal D'\subsetneq\hat{\mathcal D'} and X′X' is not reflexive.

So the wire plane is observationally a plane; the grid plane is observationally not a plane, but an observer still overestimates what can be done in it, crediting it with motions that turn corners. Only interventions settle either question. ◀\blacktriangleleft

3 Show that the reflexive hull does not commute with quotients: exhibit a subduction π ⁣:X→B\pi\colon X\to B with XX reflexive for which X^→B^\hat X\to\hat B is not a subduction.

Solution.  Take π=qα ⁣:R→Tα\pi=q_\alpha\colon\mathbb{R}\to T_{\alpha}. R\mathbb{R} is reflexive, so R^=R\hat{\mathbb{R}}=\mathbb{R}, and Tα^\hat{T_{\alpha}} is the set R/Λα\mathbb{R}/\Lambda_\alpha with the coarse diffeology. The map R→Tα^\mathbb{R}\to\hat{T_{\alpha}} is smooth and surjective, but a parametrisation of Tα^\hat{T_{\alpha}} that is not locally liftable, such as t↦qα(∣t∣)t\mapsto q_\alpha(\sqrt{\lvert t\rvert}) (Proposition 1.10), is a plot of the target with no local lift. So the hull of the quotient is not the quotient of the hull. Equivalently: the reflector X↦X^X\mapsto\hat X is a left adjoint and so preserves colimits computed in the category of reflexive spaces, where the quotient of R\mathbb{R} by Λα\Lambda_\alpha is the coarse space; the category of Frölicher spaces has quotients, and they are the wrong ones. ◀\blacktriangleleft

4 Prove 1.1(ii).

Solution.  Let f ⁣:X→Yf\colon X\to Y, g ⁣:Y→Xg\colon Y\to X be smooth and h ⁣:X×R→Xh\colon X\times\mathbb{R}\to X a smooth homotopy with h0=g∘fh_0=g\circ f and h1=idXh_1=\mathrm{id}_X. Let V1,…,VkV_1,\dots,V_k be D-open sets covering Y×YY\times Y with smooth planners σj ⁣:Vj→Paths⁡(Y)\sigma_j\colon V_j\to\operatorname{Paths}(Y). Put Uj=(f×f)−1(Vj)U_j=(f\times f)^{-1}(V_j); these are D-open, because smooth maps are D-continuous, and they cover X×XX\times X. We construct a smooth planner on UjU_j.

Three paths. For (x,x′)∈Uj(x,x')\in U_j consider γ1(t)=h(x,1−λ(t))from x to gf(x),γ2(t)=g(σj(f(x),f(x′))(λ(t)))from gf(x) to gf(x′),γ3(t)=h(x′,λ(t))from gf(x′) to x′,\begin{aligned} \gamma_1(t)&=h\bigl(x,1-\lambda(t)\bigr)&&\text{from }x\text{ to }g f(x),\\ \gamma_2(t)&=g\bigl(\sigma_j(f(x),f(x'))(\lambda(t))\bigr)&&\text{from }gf(x)\text{ to }gf(x'),\\ \gamma_3(t)&=h\bigl(x',\lambda(t)\bigr)&&\text{from }gf(x')\text{ to }x', \end{aligned} where λ\lambda is a smashing function. Each is stationary near t≤0t\le0 and t≥1t\ge1, each depends smoothly on (x,x′,t)(x,x',t): for γ2\gamma_2 this is the smoothness of σj∘(f×f) ⁣:Uj→Paths⁡(Y)\sigma_j\circ(f\times f)\colon U_j\to\operatorname{Paths}(Y) together with Theorem 1.9.

Concatenation. Define sj(x,x′)(t)s_j(x,x')(t) to be γ1(3t)\gamma_1(3t) for t≤13t\le\tfrac13, γ2(3t−1)\gamma_2(3t-1) for 13≤t≤23\tfrac13\le t\le\tfrac23 and γ3(3t−2)\gamma_3(3t-2) for t≥23t\ge\tfrac23. Because λ\lambda is constant near 00 and near 11, there is a fixed ε>0\varepsilon>0, independent of (x,x′)(x,x'), such that on ∣t−13∣<ε\lvert t-\tfrac 13\rvert<\varepsilon the first two expressions are both equal to gf(x)gf(x), and on ∣t−23∣<ε\lvert t-\tfrac 23\rvert<\varepsilon the last two are both equal to gf(x′)gf(x'). So on the three overlapping open sets t<13+εt<\tfrac13+\varepsilon, 13−ε<t<23+ε\tfrac13-\varepsilon<t<\tfrac23+\varepsilon, t>23−εt>\tfrac23-\varepsilon of Uj×RU_j\times\mathbb{R} the map (x,x′,t)↦sj(x,x′)(t)(x,x',t)\mapsto s_j(x,x')(t) coincides with a smooth map, and by locality [D2] applied to its composites with plots it is smooth. Hence sj ⁣:Uj→Paths⁡(X)s_j\colon U_j\to\operatorname{Paths}(X) is smooth, with sj(x,x′)(0)=h(x,1)=xs_j(x,x')(0)=h(x,1)=x and sj(x,x′)(1)=h(x′,1)=x′s_j(x,x')(1)=h(x',1)=x'.

So X×XX\times X is covered by kk D-open sets with smooth planners, and TC⁡D(X)≤TC⁡D(Y)\operatorname{TC}^D(X)\le\operatorname{TC}^D(Y). If XX and YY are smoothly homotopy equivalent each dominates the other and the two numbers coincide. ◀\blacktriangleleft

System design: state spaces, quotients, clocks

A designer of systems with continuous state composes state spaces, abstracts them, and identifies states that should not be distinguished. We prove three results about doing so smoothly. Every smooth machine has two minimal realisations, a quotient and a subspace of the space of behaviours, which differ in general. A system of incommensurable clocks is classified, up to re-gearing, by a quasi-torus on which no conserved quantity exists. And reduction by a symmetry group is lossless exactly when the action is principal, in which case equivariant components upstairs are the same as components downstairs.

Source in the book. [IZ, art. 1.46–1.60] (subductions, quotients, strict maps, functional diffeology), [IZ, art. 8.11–8.16] (principal and associated bundles), [IZ, art. 8.38] (Kronecker flows).

A design rule

State spaces are built from other state spaces by a small number of operations, and each is a universal construction (1.1). The category of manifolds has the first row conditionally and the others not at all, which is why continuous-state design is usually done in coordinates with the structure maintained by hand. Diff\mathsf{Diff} has all of them unconditionally (Theorem 1.6, Theorem 1.9, Theorem 1.5), with one refinement that this chapter is about: the quotient in Diff\mathsf{Diff} is a quotient of points, and when the identifications themselves carry information the right object is the quotient in SmoothSet\mathsf{SmoothSet} or in H\mathbf{H} (Theorem 1.8).

Design operations and the universal constructions that implement them in Diff\mathsf{Diff}.
design operation construction smoothness means
compose subsystems product, pullback families are pairs of families
impose an invariant subspace (induction) a family is smooth iff smooth in the ambient space
abstract, deduplicate quotient (subduction) every family of abstract states lifts locally
switch between modes sum, pushout a family stays locally in one mode
pass a component as data function space a family of components is a component with a parameter
depend on a parameter slice, Πf\Pi_f fibrewise function spaces

Two minimal realisations

Fix diffeological spaces II of inputs and OO of outputs. A smooth machine is a diffeological space SS of states with smooth maps δ ⁣:S×I→S,out ⁣:S→O,\delta\colon S\times I\to S,\qquad\mathrm{out}\colon S\to O , and a morphism of machines is a smooth map of state spaces commuting with δ\delta and out\mathrm{out}. Write δ∗(s;i1,…,in)\delta^*(s;i_1,\dots,i_n) for the state reached from ss on the input word i1⋯ini_1\cdots i_n. The space of behaviours is B=∏n≥0C∞(In,O),B=\prod_{n\ge0}C^{\infty}(I^n,O), a machine with outB(b)=b0\mathrm{out}_B(b)=b_0 and δB(b,i)n(i1,…,in)=bn+1(i,i1,…,in)\delta_B(b,i)_n(i_1,\dots,i_n)=b_{n+1}(i,i_1,\dots,i_n). The behaviour of a state ss of a machine MM is βM(s)=((i1,…,in)↦out(δ∗(s;i1,…,in)))n≥0\beta_M(s)=\bigl((i_1,\dots,i_n)\mapsto\mathrm{out}(\delta^*(s;i_1,\dots,i_n))\bigr)_{n\ge0}.

Theorem 1.1 (Two minimal realisations). Let M=(S,δ,out)M=(S,\delta,\mathrm{out}) be a smooth machine.

  1. BB is a terminal object in the category of smooth machines: βM ⁣:M→B\beta_M\colon M\to B is the unique morphism.

  2. The coimage Mq=S/∼M_q=S/{\sim}, where s∼s′s\sim s' iff βM(s)=βM(s′)\beta_M(s)=\beta_M(s'), and the image Ms=βM(S)subM_s=\beta_M(S)_{\mathrm{sub}} carry unique machine structures making M  ↠  Mq  → κ   Ms  ↪  BM\;\twoheadrightarrow\;M_q\;\xrightarrow{\ \kappa\ }\;M_s\;\hookrightarrow\;B morphisms of machines. κ\kappa is a bijection.

  3. (Universal properties.) Every morphism M→M′M\to M' that is a subduction is followed by a unique morphism M′→MqM'\to M_q under MM: MqM_q is the smallest quotient of MM. Every morphism from MM to a machine whose behaviour map is an induction factors uniquely through M→MsM\to M_s: MsM_s is the reflection of MM into extensional machines.

  4. κ\kappa is an isomorphism if and only if βM\beta_M is strict. It is not always: for S=RS=\mathbb{R}, I=∗I=\ast, δ=id\delta=\mathrm{id}, out(s)=s2\mathrm{out}(s)=s^2 one gets Mq=R/{±1}M_q=\mathbb{R}/\{\pm1\} and Ms=[0,∞)subM_s=[0,\infty)_{\mathrm{sub}}.

  5. Machines with the same set of behaviours have the same MsM_s, but can have non-diffeomorphic MqM_q: for Sn=RnS_n=\mathbb{R}^n, I=∗I=\ast, δ=id\delta=\mathrm{id}, out(s)=∣s∣2\mathrm{out}(s)=\lvert s\rvert^2, all MsM_s coincide and the Mq=Rn/O⁡(n)M_q=\mathbb{R}^n/\operatorname{O}(n) are pairwise non-diffeomorphic.

Proof. (i) The nn-th component of βM\beta_M is the adjoint of the smooth map S×In→OS\times I^n\to O, (s,ı⃗)↦out(δ∗(s;ı⃗))(s,\vec\imath)\mapsto\mathrm{out}(\delta^*(s;\vec\imath)), so it is smooth by Theorem 1.9, and a map into a product is smooth iff its components are. δB\delta_B is smooth because partial evaluation C∞(In+1,O)×I→C∞(In,O)C^{\infty}(I^{n+1},O)\times I\to C^{\infty}(I^n,O) is. The identities outBβM=out\mathrm{out}_B\beta_M=\mathrm{out} and βMδ=δB(βM×id)\beta_M\delta=\delta_B(\beta_M\times\mathrm{id}) are immediate. If h ⁣:M→Bh\colon M\to B is any morphism then h(s)n(ı⃗)=outB(δB∗(h(s);ı⃗))=outB(h(δ∗(s;ı⃗)))=out(δ∗(s;ı⃗))h(s)_n(\vec\imath)=\mathrm{out}_B(\delta_B^*(h(s);\vec\imath))=\mathrm{out}_B(h(\delta^*(s;\vec\imath)))=\mathrm{out}(\delta^*(s;\vec\imath)).

(ii) δ\delta is compatible with ∼\sim, because βM(δ(s,i))=δB(βM(s),i)\beta_M(\delta(s,i))=\delta_B(\beta_M(s),i). The map S×I→Mq×IS\times I\to M_q\times I is a subduction (Proposition 1.7), so δ\delta descends to a smooth δq ⁣:Mq×I→Mq\delta_q\colon M_q\times I\to M_q; and out\mathrm{out} descends. The image βM(S)\beta_M(S) is closed under δB\delta_B, and restrictions of smooth maps to subspaces, with values in subspaces, are smooth. Uniqueness is clear since S→MqS\to M_q is onto and Ms→BM_s\to B is injective. κ\kappa is the comparison map of Theorem 1.2.

(iii) If h ⁣:M→M′h\colon M\to M' is a morphism then βM′h=βM\beta_{M'}h=\beta_M by (i), so hh identifies only ∼\sim-equivalent states; if hh is a subduction, S→MqS\to M_q factors uniquely and smoothly through it, and the factor is a morphism because hh is onto. If h ⁣:M→Nh\colon M\to N with βN\beta_N an induction, then βN\beta_N identifies NN with a subspace of BB containing βM(S)\beta_M(S), and the inclusion Ms↪βN(N)sub≅NM_s\hookrightarrow\beta_N(N)_{\mathrm{sub}}\cong N is the required factor.

(iv) is the definition of strict, and Proposition 1.11. (v) All these machines have β(S)={ (c,c,… ):c≥0 }\beta(S)=\{\,(c,c,\dots):c\ge 0\,\}, a copy of [0,∞)sub[0,\infty)_{\mathrm{sub}} in B=RNB=\mathbb{R}^{\mathbb{N}}; the classes of ∼\sim are the spheres, so Mq=Rn/O⁡(n)M_q=\mathbb{R}^n/\operatorname{O}(n), and [IZ, Exercise 50]. ◻

The two minimal realisations of a smooth machine. In classical automata theory they coincide (Myhill–Nerode); for manifolds neither exists in general; in Diff\mathsf{Diff} both exist, and the map between them is a smooth bijection that is a diffeomorphism exactly for strict behaviour maps.

For design this separates two meanings of the word “state”. MsM_s is the state space of the specification: it depends only on the observable behaviour, and a smooth family in it is a smooth family of behaviours, which is the kind of object over which a test suite or a contract quantifies. MqM_q is the state space of the implementation up to observation: a smooth family in it is one that some smooth family of internal states realises. By part (iv) a specification can have smooth families of behaviours that no smooth family of implementation states realises — the family (r,s)↦r2+s2(r,s)\mapsto r^2+s^2 in the example — and by part (v) two implementations of one specification can have observational quotients of different local dimension. Neither phenomenon can be stated for manifolds, because neither quotient is one.

Clocks

Consider N≥2N\ge2 periodic components with frequencies ω=(ω1,…,ωN)∈RN\omega=(\omega_1,\dots,\omega_N)\in\mathbb{R}^N: counters, oscillators, tasks released periodically. Their joint phase is a point of the torus TN=RN/ZNT^N=\mathbb{R}^N/\mathbb{Z}^N and evolves by the linear flow x↦x+tωx\mapsto x+t\omega. Call ω\omega non-resonant if k⋅ω≠0k\cdot\omega\ne0 for all k∈ZN∖{0}k\in\mathbb{Z}^N\smallsetminus\{0\}: no integer combination of the clocks is stationary. The space of phase relations of the system is the leaf space Qω=TN/R,Q_\omega=T^N/\mathbb{R}, whose points are the possible trajectories of the joint phase. Two initial conditions have the same long-run behaviour, up to a time shift, exactly when they define the same point of QωQ_\omega.

Theorem 1.2 (Multi-clock systems). Let ω,ω′∈RN\omega,\omega'\in\mathbb{R}^N be non-resonant, N≥2N\ge2.

  1. Qω≅RN−1/ΓωQ_\omega\cong\mathbb{R}^{N-1}/\Gamma_\omega is a quasi-torus, where Γω≅ZN\Gamma_\omega\cong\mathbb{Z}^N is the image of ZN\mathbb{Z}^N in RN/Rω\mathbb{R}^N/\mathbb{R}\omega, a dense subgroup. The projection TN→QωT^N\to Q_\omega is a principal R\mathbb{R}-bundle, and Π Qω≃BZN≃TN\Pi\,Q_\omega\simeq\mathbf{B}\mathbb{Z}^N\simeq T^N.

  2. Every D-continuous function on QωQ_\omega is constant: the system has no non-trivial continuous conserved quantity.

  3. Qω≅Qω′Q_\omega\cong Q_{\omega'} if and only if ω′=c Uω\omega'=c\,U\omega for some U∈GL⁡N(Z)U\in\operatorname{GL}_N(\mathbb{Z}) and c∈R×c\in\mathbb{R}^\times.

  4. Diff⁡(Qω)≅Qω⋊Σω\operatorname{Diff}(Q_\omega)\cong Q_\omega\rtimes\Sigma_\omega, where Σω={ U∈GL⁡N(Z):Uω∈Rω }\Sigma_\omega=\{\,U\in\operatorname{GL}_N(\mathbb{Z}):U\omega\in\mathbb{R}\omega\,\} is the discrete group of unimodular integer matrices with eigenvector ω\omega.

Proof. (i) Let p ⁣:RN→V=RN/Rωp\colon\mathbb{R}^N\to V=\mathbb{R}^N/\mathbb{R}\omega and Γω=p(ZN)\Gamma_\omega=p(\mathbb{Z}^N). Both QωQ_\omega and V/ΓωV/\Gamma_\omega are the quotient of RN\mathbb{R}^N by the subgroup ZN+Rω\mathbb{Z}^N+\mathbb{R}\omega, so they are diffeomorphic. If cω∈ZNc\omega\in\mathbb{Z}^N with c≠0c\neq0, any non-zero integer vector orthogonal to cωc\omega would violate non-resonance; so Rω∩ZN=0\mathbb{R}\omega\cap\mathbb{Z}^N=0 and pp is injective on ZN\mathbb{Z}^N. By Kronecker’s theorem non-resonance is equivalent to density of every orbit of the flow in TNT^N, that is, to density of ZN+Rω\mathbb{Z}^N+\mathbb{R}\omega in RN\mathbb{R}^N, that is, to density of Γω\Gamma_\omega in VV. The flow is the action of a subgroup of the diffeological group TNT^N, so the quotient map is principal by Corollary 1.3; the subgroup is diffeomorphic to R\mathbb{R} as in [IZ, Exercise 31]. The shape is Corollary 1.5. (ii) A D-open set of V/ΓωV/\Gamma_\omega has an open preimage invariant under a dense group of translations. (iii) By Theorem 1.1(c), Qω≅Qω′Q_\omega\cong Q_{\omega'} iff there is a linear isomorphism A ⁣:V→V′A\colon V\to V' with AΓω=Γω′A\Gamma_\omega=\Gamma_{\omega'}. Given such AA, there is a unique bijection UU of ZN\mathbb{Z}^N with p′U=App'U=Ap on ZN\mathbb{Z}^N, because p′p' is injective on ZN\mathbb{Z}^N; it is additive, so U∈GL⁡N(Z)U\in\operatorname{GL}_N(\mathbb{Z}), and p′U=App'U=Ap on RN\mathbb{R}^N by linearity. Hence U(ker⁡p)=ker⁡p′U(\ker p)=\ker p', i.e. Uω∈Rω′U\omega\in\mathbb{R}\omega'. Conversely such a UU induces AA. (iv) By Theorem 1.1(b) every smooth self-map is affine, and its linear part corresponds to UU as in (iii); the diffeology is treated as in Theorem 1.3(iii). ◻

Two clocks with period ratio the golden ratio. There is no hyperperiod and no continuous function of the joint phase is conserved, but the space of phase relations is the diffeological group TφT_\varphi, with a self-similarity: the frequencies ω=(1,1/φ)\omega=(1,1/\varphi) satisfy Uω=φ ωU\omega=\varphi\,\omega for , so replacing the counters (c1,c2)(c_1,c_2) by (c1+c2,c1)(c_1+c_2,c_1) gives the same system run φ\varphi times faster.

In design terms, (ii) means that there is nothing to synchronise on. A system of rate-monotonic periodic tasks with rational period ratios has a hyperperiod, a circle of phase relations, and schedules can be tabulated over it; with incommensurable periods the corresponding object exists but is a quasi-torus, and no table indexed by a continuous invariant of the phase can exist. (iii) is a normal form theorem: two multi-rate systems are the same up to re-gearing — replacing the counters by unimodular integer combinations of themselves and rescaling time — exactly when their leaf spaces are diffeomorphic. For N=2N=2 this is Corollary 1.2 with α=ω2/ω1\alpha=\omega_2/\omega_1, and the invariant is the tail of the continued fraction of the rate ratio. (iv) gives the non-trivial re-gearing self-equivalences of a system: Σω\Sigma_\omega is {±1}\{\pm1\} for generic rates, and it is the unit group Z[θ]×\mathbb{Z}[\theta]^\times, of rank r1+r2−1r_1+r_2-1 by Dirichlet’s theorem, when ω=(1,θ,…,θN−1)\omega=(1,\theta,\dots,\theta^{N-1}) for an algebraic integer θ\theta of degree NN ([exo:three-clocks]; compare Proposition 1.5). Finally, for N=2N=2, the principal R\mathbb{R}-bundles over QωQ_\omega are computed in Theorem 1.7; they are the ways of attaching to the phase relation a real-valued accumulated quantity defined up to a flow. They depend on the Diophantine type of the rate ratio: for Diophantine ratios the only such quantity is elapsed time, up to scale, and for Liouville ratios there are others.

Lossless reduction

Let a diffeological group GG act on a state space XX by symmetries: relabellings of identical replicas, changes of frame, gauge freedoms of a representation. One wants to work with the reduced state space B=X/GB=X/G. When is nothing lost? Write DiffG/X\mathsf{Diff}_G/X for the category of diffeological spaces with GG-action and an equivariant smooth map to XX; think of its objects as components attached to the system whose state transforms with the symmetry.

Theorem 1.3 (Lossless symmetry reduction). Let π ⁣:X→B=X/G\pi\colon X\to B=X/G be the quotient map.

  1. The following are equivalent: the action is principal; X≃B×BG∗X\simeq B\times_{\mathbf{B}G}\ast in H\mathbf{H}, compatibly with the action and the projection, for a map c ⁣:B→BGc\colon B\to\mathbf{B}G; along every plot of BB the state space is locally a product of reduced state and gauge, P∗X≅locU×GP^*X\cong_{\mathrm{loc}}U\times G.

  2. If the action is principal, then pulling back along π\pi is an equivalence of categories π∗ ⁣:Diff/B  → ≃   DiffG/X,with inverse E↦E/G.\pi^*\colon\mathsf{Diff}/B\;\xrightarrow{\ \simeq\ }\;\mathsf{Diff}_G/X,\qquad\text{with inverse }E\mapsto E/G .

  3. In general H/(X/ ⁣ ⁣/G)\mathbf{H}/(X/\!\!/G) is equivalent to the ∞\infty-category of objects of H\mathbf{H} with GG-action and an equivariant map to XX, and the functor of (ii) is the restriction of this equivalence along X/ ⁣ ⁣/G→BX/\!\!/G\to B, which is an equivalence exactly in the principal case.

Proof. (i) is Theorem 1.2 and Theorem 1.5. (ii) is [exo:descent]. (iii) is the general fact that objects over a homotopy quotient are equivariant objects [46], together with Theorem 1.8. ◻

So for a principal symmetry one may store only the reduced state, and every equivariant observer, controller or attached data structure is equivalently a component over the reduced state space: the reduction is an equivalence of design spaces, not merely a projection. When the action is not principal the same statement holds verbatim for the stack X/ ⁣ ⁣/GX/\!\!/G and fails for the space X/GX/G; the space X/GX/G lacks the isotropy groups, and a component over X/GX/G carries no action of the isotropy group at a state with symmetry. The three levels at which states can be identified in a design are listed in 1.2.

Three levels of identification, from Theorem 1.8. Moving down the table increases the stored data and improves compositionality: only the last row satisfies 1.3(iii) unconditionally.
level object two states are identified… engineering analogue
points X/G∈DiffX/G\in\mathsf{Diff} if some symmetry relates them canonical form, deduplicated key
germs π0(X/ ⁣ ⁣/G)∈SmoothSet\pi_0(X/\!\!/G)\in\mathsf{SmoothSet} by a symmetry varying smoothly with the family equivalence with a locally consistent reason
witnesses X/ ⁣ ⁣/G∈HX/\!\!/G\in\mathbf{H} by a recorded symmetry keep the isomorphism: migration, merge witness, version vector

Solved exercises

Ratings: warm-up, computation, argument, proof-level. Every exercise is followed by a complete solution.

1 Compute the space of phase relations QωQ_\omega for two clocks with ω=(2,3)\omega=(2,3), and more generally for ω=(p,q)\omega=(p,q) with p,qp,q coprime integers.

Solution.  Qω=R2/(Z2+Rω)Q_\omega=\mathbb{R}^2/(\mathbb{Z}^2+\mathbb{R}\omega). The linear form ℓ(x,y)=qx−py\ell(x,y)=qx-py has kernel Rω\mathbb{R}\omega, so it identifies R2/Rω\mathbb{R}^2/\mathbb{R}\omega with R\mathbb{R} and carries Z2\mathbb{Z}^2 onto qZ+pZ=Zq\mathbb{Z}+p\mathbb{Z}=\mathbb{Z}. Hence Qω≅R/ZQ_\omega\cong\mathbb{R}/\mathbb{Z}, a circle: the flow on T2T^2 is periodic and the phase relation is the conserved quantity qx−py mod 1qx-py\bmod1. The hyperperiod is the period of the flow, t=1t=1 in these units. The contrast with 1.2 is entirely in whether ℓ(Z2)\ell(\mathbb{Z}^2) is discrete or dense. ◀\blacktriangleleft

2 Let I=RI=\mathbb{R}, O=RO=\mathbb{R}. Let M1M_1 have S=RS=\mathbb{R}, δ(s,θ)=s\delta(s,\theta)=s, out(s)=s2\mathrm{out}(s)=s^2, and let M2M_2 have S=R2S=\mathbb{R}^2, δ(s,θ)\delta(s,\theta) the rotation of ss by the angle θ\theta, out(s)=∣s∣2\mathrm{out}(s)=\lvert s\rvert^2. Show that M1M_1 and M2M_2 have the same specification MsM_s and non-isomorphic observational quotients.

Solution.  In both machines the output along any input word is constant: β(s)n(θ⃗)=s2\beta(s)_n(\vec\theta)=s^2, respectively ∣s∣2\lvert s\rvert^2. So both images in BB are the set of constant behaviours with value c≥0c\ge0. The map c↦(constc)nc\mapsto(\text{const}_c)_n from R\mathbb{R} to BB is an induction, since each component R→C∞(Rn,R)\mathbb{R}\to C^{\infty}(\mathbb{R}^n,\mathbb{R}) is; so Ms≅[0,∞)subM_s\cong[0,\infty)_{\mathrm{sub}} for both, with trivial transition and output cc. The observational quotients are R/{±1}=Δ1\mathbb{R}/\{\pm1\}=\Delta_1 and R2/ ⁣∼\mathbb{R}^2/\!\sim with classes the circles, which is Δ2=R2/O⁡(2)\Delta_2=\mathbb{R}^2/\operatorname{O}(2). These are not diffeomorphic [IZ, Exercise 50]; indeed no machine isomorphism can exist since the underlying spaces differ. An observer cannot tell M1M_1 from M2M_2; a designer who can run smooth two-parameter families of initial states can. ◀\blacktriangleleft

2 Determine Σω\Sigma_\omega for ω=(1,2,3)\omega=(1,\sqrt2,\sqrt3) and exhibit an element of infinite order in Σω\Sigma_\omega for ω=(1,θ,θ2)\omega=(1,\theta,\theta^2) with θ3=θ+1\theta^3=\theta+1.

Solution.  Both are non-resonant, the entries being linearly independent over Q\mathbb{Q}. Let Uω=cωU\omega=c\omega and M=Zω1+Zω2+Zω3⊂RM=\mathbb{Z}\omega_1+\mathbb{Z}\omega_2+\mathbb{Z}\omega_3\subset\mathbb{R}; then cM⊆McM\subseteq M. For the first ω\omega: c=c⋅1∈Mc=c\cdot1\in M, say c=a+b2+d3c=a+b\sqrt2+d\sqrt3. Then c2=2b+a2+d6∈Mc\sqrt2=2b+a\sqrt2+d\sqrt6\in M forces d=0d=0 and c3=a3+b6∈Mc\sqrt3=a\sqrt3+b\sqrt6\in M forces b=0b=0. So c=a∈Zc=a\in\mathbb{Z}, the integer matrix U−cU-c annihilates ω\omega, hence is zero by non-resonance, and U=c=±1U=c=\pm1: Σω={±1}\Sigma_\omega=\{\pm1\}. For the second, multiplication by θ\theta preserves M=Z[θ]M=\mathbb{Z}[\theta]: θ⋅1=θ\theta\cdot1=\theta, θ⋅θ=θ2\theta\cdot\theta=\theta^2, θ⋅θ2=1+θ\theta\cdot\theta^2=1+\theta. So satisfies Uω=θωU\omega=\theta\omega, det⁡U=1\det U=1, and it has infinite order because θ>1\theta>1. Three clocks with rates 1:θ:θ21:\theta:\theta^2 are re-gearing equivalent to themselves under (c1,c2,c3)↦(c2,c3,c1+c2)(c_1,c_2,c_3)\mapsto(c_2,c_3,c_1+c_2) with time rescaled by θ\theta. ◀\blacktriangleleft

3 Let X=R2X=\mathbb{R}^2 with the flow of x˙=−∇L\dot x=-\nabla L, L(x)=(∣x∣2−1)2L(x)=(\lvert x\rvert^2-1)^2, and G=SO(2)G=\mathrm{SO}(2). Describe the reduced dynamics on X/GX/G, say where the reduction is lossless in the sense of 1.3, and compute the shape of X/ ⁣ ⁣/GX/\!\!/G and of X/GX/G.

Solution.  LL is invariant and its flow is complete in forward time, so by the argument of Proposition 1.2 it descends to X/G=R2/SO(2)=Δ2X/G=\mathbb{R}^2/\mathrm{SO}(2)=\Delta_2 (the orbits of SO(2)\mathrm{SO}(2) and O⁡(2)\operatorname{O}(2) coincide). In the coordinate u=∣x∣2∈[0,∞)u=\lvert x\rvert^2\in[0,\infty), u˙=2x⋅x˙=−8u(u−1)\dot u=2x\cdot\dot x=-8u(u-1): the point u=0u=0 is an unstable equilibrium, u=1u=1 a stable one, and every other trajectory tends to u=1u=1. On X∘=R2∖{0}X^\circ=\mathbb{R}^2\smallsetminus\{0\} the action is free and proper, hence principal, with quotient the manifold (0,∞)(0,\infty); there the state is (radius, angle), the angle is pure gauge, and by 1.3(ii) equivariant components over X∘X^\circ are the same as components over (0,∞)(0,\infty). At the origin the stabiliser is all of GG and the reduction is lossy. Shapes: Π(X/ ⁣ ⁣/G)=∗/ ⁣ ⁣/S1=BS1=CP∞\Pi(X/\!\!/G)=\ast/\!\!/S^1=\mathbf{B}S^1=\mathbb{C}P^\infty, while Π(X/G)=∗\Pi(X/G)=\ast ([exo:contractible]). The entire difference is the isotropy of one state. ◀\blacktriangleleft

4 Prove 1.3(ii).

Solution.  Let π ⁣:X→B\pi\colon X\to B be a principal GG-bundle.

The functor π∗\pi^*. For E→BE\to B put π∗E=X×BE\pi^*E=X\times_BE, with GG acting on the first factor and the projection to XX. It is an object of DiffG/X\mathsf{Diff}_G/X, functorially in EE.

The functor QQ. For p ⁣:E→Xp\colon E\to X in DiffG/X\mathsf{Diff}_G/X put Q(E)=E/GQ(E)=E/G with the map to BB induced by π∘p\pi\circ p, which is GG-invariant.

The action on EE is principal. Let r↦(er,ergr)r\mapsto(e_r,e_rg_r) be a plot of E×EE\times E. Applying pp gives the plot r↦(p(er),p(er)gr)r\mapsto(p(e_r),p(e_r)g_r) of X×XX\times X, and since the action on XX is principal r↦grr\mapsto g_r is a plot of GG. In particular the action on EE is free and E→E/GE\to E/G is a principal bundle.

π∗Q≅id\pi^*Q\cong\mathrm{id}. For EE in DiffG/X\mathsf{Diff}_G/X consider ϕ ⁣:E→X×BE/G\phi\colon E\to X\times_BE/G, ϕ(e)=(p(e),[e])\phi(e)=(p(e),[e]). It is smooth, GG-equivariant, and lies over E/GE/G. Now X×B(E/G)→E/GX\times_B(E/G)\to E/G is a principal GG-bundle, being the pullback of π\pi along E/G→BE/G\to B (Lemma 1.4(i)), and E→E/GE\to E/G is a principal GG-bundle by the previous step. A morphism of principal bundles over the same base is an isomorphism (Lemma 1.4(ii)); so ϕ\phi is a diffeomorphism, natural in EE, and it commutes with the maps to XX.

Qπ∗≅idQ\pi^*\cong\mathrm{id}. For E→BE\to B, the projection X×BE→EX\times_BE\to E is a subduction, as the pullback of the subduction π\pi, and its fibres are the GG-orbits. So it induces a bijective subduction (X×BE)/G→E(X\times_BE)/G\to E, which is a diffeomorphism (Proposition 1.7(iii)), natural in EE and compatible with the maps to BB.

Morphisms. Both constructions are functorial and the two natural isomorphisms exhibit them as inverse equivalences.

The argument used principality twice: to make E→E/GE\to E/G a bundle, and to make X×B(E/G)X\times_B(E/G) one. For a free action that is not principal the statement fails. Let Rδ\mathbb{R}^{\delta} act on X=RX=\mathbb{R}, so that B=∗B=\ast, and take E=X×GE=X\times G with the diagonal action and the first projection. Then E/G≅RE/G\cong\mathbb{R} via (x,h)↦x−h(x,h)\mapsto x-h, so π∗Q(E)=R×R\pi^*Q(E)=\mathbb{R}\times\mathbb{R}, which is not diffeomorphic to E=R×RδE=\mathbb{R}\times\mathbb{R}^{\delta}. ◀\blacktriangleleft

Coda

A summary of the argument, open questions, and the strata in which the statements will be formalised.

The argument in one page

A diffeology is a concrete sheaf on Cartesian spaces (Theorem 1.2). Concreteness is separatedness for the adjunction “points ⊣\dashv codiscrete” (Lemma 1.5), so Diff\mathsf{Diff} is a quasitopos (Theorem 1.6): it has every limit, colimit and function space, two kinds of image (Theorem 1.2), and one defect, non-effective equivalence relations (Proposition 1.7). Repairing the defect twice leads to the topos SmoothSet\mathsf{SmoothSet} and the ∞\infty-topos H\mathbf{H} (Theorem 1.5), and the quotient of a space by a group then has three values, which coincide exactly for the principal actions of the book (Theorem 1.2, Theorem 1.8). In H\mathbf{H} the book’s main constructions become representable: forms by the smooth sets Ωk\Omega^k (Proposition 1.2), principal bundles by the stacks BG\mathbf{B}G (Theorem 1.5), homotopy groups by the shape Π\Pi (Theorem 1.2). Formal properties of Π\Pi give the exact homotopy sequence (Theorem 1.4); the Poincaré lemma for sheaves gives de Rham’s theorem with its obstruction (Theorem 1.8) and the integration bundles (Theorem 1.11).

Every statement can be checked on the irrational torus. It is R/ ⁣ ⁣/Z2\mathbb{R}/\!\!/\mathbb{Z}^2, so its shape is a torus; its forms account for half of the torus’ cohomology and its R\mathbb{R}-bundles for the other half (Proposition 1.9); its maps are affine (Theorem 1.1), so its symmetries are units (Theorem 1.3), its isomorphism classes are ideal classes (Theorem 1.2), and its bundles are solutions of a cohomological equation with small divisors (Theorem 1.7).

The applications use the quasitopos more than the ∞\infty-topos. Because a map has two images, hypothesis spaces (Theorem 1.1), invariant features (Proposition 1.6) and minimal realisations (Theorem 1.1) each come in two versions. By Cartesian closure, automatic differentiation (Theorem 1.3) and motion planning (Theorem 1.1) are one-line arguments. The distinction between a quotient and a homotopy quotient is the reason that canonical forms fail at symmetric points (Theorem 1.4) and the criterion for symmetry reduction to be lossless (Theorem 1.3).

Open questions

  1. Strictness of realisation maps. For which architectures is ρ ⁣:Θ→C∞(X,Y)\rho\colon\Theta\to C^{\infty}(X,Y) strict, so that the two hypothesis spaces of Theorem 1.1 coincide? For deep linear networks the question is whether every smooth family of matrices of rank at most kk factors locally and smoothly through kk dimensions.

  2. Higher obstruction groups. Compute Hq(TΓ;Ωp)H^q(T_\Gamma;\Omega^p) for quasi-tori of rank N>2N>2. The answer should be governed by simultaneous Diophantine conditions on Γ\Gamma, generalising Theorem 1.7; the E2E_2 page should again be the cohomology of TNT^N.

  3. The smooth Oka principle beyond manifolds. Theorem 1.6(ii) holds for manifolds, and by Remark 1.6 Π[Tα,BR]≃∗\Pi[T_{\alpha},\mathbf{B}\mathbb{R}]\simeq\ast is consistent with it even though Map⁡(Tα,BR)\operatorname{Map}(T_{\alpha},\mathbf{B}\mathbb{R}) is large. For which diffeological spaces XX is Π[X,A]≃Map⁡(ΠX,ΠA)\Pi[X,A]\simeq\operatorname{Map}(\Pi X,\Pi A) for all AA?

  4. Smooth versus continuous planning. Is TC⁡D(M)=TC⁡(M)\operatorname{TC}^D(M)=\operatorname{TC}(M) for every closed manifold MM?

  5. Arithmetic beyond the class group. In complex multiplication the torsor of Theorem 1.2 carries a Galois action and generates class fields. Manin’s question [43] is whether real multiplication has an analogue. Diffeology provides the objects and their isogenies; the invariants are the open part.

  6. Reverse mode and stacks. Is there a version of Theorem 1.3 for programs whose types denote stacks, for instance programs manipulating data up to a symmetry?

Formalisation: what is ready

Formalisation is the subject of a sequel. The statements of this monograph fall into three strata by the infrastructure required (1.1). The first stratum is elementary: sets, plots and real analysis. The second requires sheaves on a site. The third requires an ∞\infty-topos, and the natural target is not a model but an axiomatisation: cohesive homotopy type theory, in which ∫\mathord{\textstyle\smallint}, ♭\flat and ♯\sharp are primitive modalities [52], and in which Theorem 1.8, Theorem 1.4 and Theorem 1.8 are statements about types.

Strata for formalisation. Everything in stratum A is provable from the definition of a diffeology in Definition 1.1 with no category theory.
stratum requires statements
A: plots sets, smooth maps on Rn\mathbb{R}^n, Fourier series Theorem 1.6, Theorem 1.9, Theorem 1.2, Theorem 1.5; Theorem 1.1, Corollary 1.2, Theorem 1.3; Lemma 1.6 and the analytic part of Theorem 1.7; Theorem 1.4, Theorem 1.1, Theorem 1.4, Theorem 1.1, Theorem 1.2; Theorem 1.3
B: sheaves a Grothendieck topos, image factorisation Theorem 1.2, Proposition 1.7, Proposition 1.1, Proposition 1.4, Theorem 1.6
C: ∞\infty-sheaves effective groupoids, shape, descent Theorem 1.2, Theorem 1.5, Theorem 1.8, Theorem 1.4, Theorem 1.8, Theorem 1.11, Theorem 1.3

The quoted theorems on which the results depend, and which would have to be formalised or assumed, are four: Whitney’s theorem on even functions (Theorem 1.1), the triviality of diffeological bundles over Cartesian spaces [IZ, art. 8.19] (Lemma 1.4), the comparison of smooth homotopy groups with the shape (Theorem 1.2), and the structure-group theorem for orbifolds (Theorem 1.2).

A dictionary

In the table the vocabulary of [1] is set beside the categorical vocabulary used here; the book is cited by article in the left column.

in Diffeology here where
domain; parametrisation (1.1–1.3) object of the site Dom\mathsf{Dom}; element of a presheaf Concrete sheaves
axioms D1–D3 (1.5) normalisation, descent, functoriality Theorem 1.2
diffeological space concrete sheaf on Cart\mathsf{Cart}; 00-truncated object of H\mathbf{H} with X↪♯XX\hookrightarrow\sharp X Theorem 1.2, Theorem 1.5
discrete, coarse diffeology (1.20–1.21) Disc⁡\operatorname{Disc}, coDisc⁡\operatorname{coDisc}; the modalities ♭\flat, ♯\sharp Proposition 1.1
pullback, pushforward (1.26, 1.43) initial and final lifts along Diff→Set\mathsf{Diff}\to\mathsf{Set} Theorem 1.6
induction (1.29) strong monomorphism Proposition 1.1
subduction (1.46) strong epimorphism; effective epimorphism of H\mathbf{H} Proposition 1.1, Theorem 1.2
strict map (1.54) coim⁡f≅im⁡f\operatorname{coim}f\cong\operatorname{im}f Theorem 1.2
functional diffeology (1.57) internal hom; exponential ideal Theorem 1.9, Theorem 1.6
generating family (1.66) covering sieve; presentation as a colimit of representables Theorem 1.5
quotient (1.50) conc⁡ π0\operatorname{conc}\,\pi_0 of the homotopy quotient Theorem 1.8
D-topology (2.8) left adjoint D ⁣:Diff→TopD\colon\mathsf{Diff}\to\mathsf{Top}; not the shape Proposition 1.6, Remark 1.7
manifold, orbifold (4.1, 4.17) modelled space; coarse space of an étale stack Models
components π0\pi_0 (5.7) Π0\Pi_0, left adjoint to Disc⁡\operatorname{Disc} Proposition 1.1
homotopy groups πn\pi_n (5.17) homotopy groups of the shape ΠX\Pi X Theorem 1.2
differential form (6.28) map X→ΩkX\to\Omega^k in SmoothSet\mathsf{SmoothSet} Proposition 1.2
pushing forms onto quotients (6.38) Hom⁡(−,Ωk)\operatorname{Hom}(-,\Omega^k) turns coequalisers into equalisers Proposition 1.4
De Rham homomorphism (6.74) edge map of the Poincaré spectral sequence Theorem 1.8
diffeological group (7.1) 00-truncated concrete group object of H\mathbf{H}; has a delooping BG\mathbf{B}G Bundles and stacks
fibrating groupoid (8.4) groupoid Morita equivalent to a group: ∣K∣≃BKb|\mathbf K|\simeq\mathbf{B}\mathbf K_b Proposition 1.9
fibration, local triviality along plots (8.8–8.9) map classified by B→BDiff⁡(F)B\to\mathbf{B}\operatorname{Diff}(F) Proposition 1.9
principal action (8.11) X/G≃X/ ⁣ ⁣/GX/G\simeq X/\!\!/G Theorem 1.2
principal bundle map X→BGX\to\mathbf{B}G Theorem 1.5
associated bundle (8.16) (P×F)/ ⁣ ⁣/G(P\times F)/\!\!/G Theorem 1.4
exact homotopy sequence (8.21) Π\Pi preserves homotopy quotients Theorem 1.4
universal covering (8.26) fibre of X→τ≤1∫XX\to\tau_{\le1}\mathord{\textstyle\smallint}X Shape
cokernel of the first De Rham homomorphism (8.30) E20,1E_2^{0,1}; flat R\mathbb{R}-bundles Theorem 1.8, exo:IZ830
group of flows Fl⁡(X)\operatorname{Fl}(X) (8.39) H1(X;R)=π0Map⁡(X,BR)H^1(X;\mathbb{R})=\pi_0\operatorname{Map}(X,\mathbf{B}\mathbb{R}) Theorem 1.7
integration bundle of a closed 2-form (8.42) lift of X→Ωcl2X\to\Omega^2_{\mathrm{cl}} through B(TP)conn\mathbf{B}(T_P)_{\mathrm{conn}} Theorem 1.11

Notation

Dom\mathsf{Dom}, Cart\mathsf{Cart} domains; Cartesian spaces, with smooth maps and open covers
Diff\mathsf{Diff}, SmoothSet\mathsf{SmoothSet}, H\mathbf{H} diffeological spaces; sheaves on Cart\mathsf{Cart}; ∞\infty-sheaves on Cart\mathsf{Cart}
X‾\underline X the sheaf of plots of XX
Γ,Disc⁡,coDisc⁡,Π0\Gamma,\operatorname{Disc},\operatorname{coDisc},\Pi_0 points, discrete, codiscrete, connected components
Π\Pi, ∫\mathord{\textstyle\smallint}, ♭\flat, ♯\sharp shape; the shape, flat and sharp modalities
conc⁡\operatorname{conc}, π0\pi_0, τ≤n\tau_{\le n} concretisation; 00-truncation; nn-truncation
X/GX/G, X/ ⁣ ⁣/GX/\!\!/G diffeological quotient; homotopy quotient
BG\mathbf{B}G, Bun⁡G(X)\operatorname{Bun}_G(X) delooping of a group object; groupoid of principal GG-bundles
Ωk\Omega^k, Ωclk\Omega^k_{\mathrm{cl}} sheaves of kk-forms and closed kk-forms on Cart\mathsf{Cart}
Hq(X;A)H^q(X;A) π0Map⁡H(X,BqA)\pi_0\operatorname{Map}_{\mathbf{H}}(X,\mathbf{B}^qA)
R\mathbb{R}, Rδ\mathbb{R}^{\delta} the smooth additive group; the same group with the discrete diffeology
Λα\Lambda_\alpha, TαT_{\alpha}, qαq_\alpha Z+αZ\mathbb{Z}+\alpha\mathbb{Z}; the irrational torus R/Λα\mathbb{R}/\Lambda_\alpha; the projection R→Tα\mathbb{R}\to T_{\alpha}
TΓT_\Gamma the quasi-torus Rn/Γ\mathbb{R}^n/\Gamma
Δn\Delta_n, HH Rn/O⁡(n)\mathbb{R}^n/\operatorname{O}(n) with the quotient diffeology; [0,∞)[0,\infty) with the subspace diffeology
Oα\mathcal O_\alpha, Pic⁡(O)\operatorname{Pic}(\mathcal O), RDR_D endomorphism ring of TαT_{\alpha}; class group; regulator
Fl⁡(X)\operatorname{Fl}(X) group of isomorphism classes of principal R\mathbb{R}-bundles over XX
∥t∥\lVert t\rVert distance from tt to the nearest integer

References

  1. P. Iglesias-Zemmour, Diffeology, Mathematical Surveys and Monographs 185, American Mathematical Society, Providence, 2013.

  2. R. J. Aumann, Borel structures for function spaces, Illinois J. Math. 5 (1961), 614–630.

  3. J. C. Baez and A. E. Hoffnung, Convenient categories of smooth spaces, Trans. Amer. Math. Soc. 363 (2011), 5789–5825.

  4. A. Batubenge, P. Iglesias-Zemmour, Y. Karshon and J. Watts, Diffeological, Frölicher, and differential spaces, preprint, arXiv:1712.04576.

  5. D. Berwick-Evans, P. Boavida de Brito and D. Pavlov, Classifying spaces of infinity-sheaves, Algebr. Geom. Topol. 24 (2024), 4891–4937.

  6. J. Boman, Differentiability of a function and of its compositions with functions of one variable, Math. Scand. 20 (1967), 249–268.

  7. J. Buchmann and H. C. Williams, A key exchange system based on real quadratic fields, in Advances in Cryptology – CRYPTO ’89, Lecture Notes in Comput. Sci. 435, Springer, 1990, 335–343.

  8. S. Bunk, The R\mathbb R-local homotopy theory of smooth spaces, J. Homotopy Relat. Struct. 17 (2022).

  9. W. Castryck, T. Lange, C. Martindale, L. Panny and J. Renes, CSIDH: an efficient post-quantum commutative group action, in Advances in Cryptology – ASIACRYPT 2018, Lecture Notes in Comput. Sci. 11274, Springer, 2018, 395–427.

  10. K.-T. Chen, Iterated path integrals, Bull. Amer. Math. Soc. 83 (1977), 831–879.

  11. J. D. Christensen, G. Sinnamon and E. Wu, The DD-topology for diffeological spaces, Pacific J. Math. 272 (2014), 87–110.

  12. J. D. Christensen and E. Wu, The homotopy theory of diffeological spaces, New York J. Math. 20 (2014), 1269–1303.

  13. J. D. Christensen and E. Wu, Smooth classifying spaces, Israel J. Math. 241 (2021); arXiv:1709.10517.

  14. H. Cohen, A Course in Computational Algebraic Number Theory, Graduate Texts in Mathematics 138, Springer, 1993.

  15. J.-M. Couveignes, Hard homogeneous spaces, IACR Cryptology ePrint Archive, Report 2006/291.

  16. P. Donato and P. Iglesias, Exemples de groupes difféologiques: flots irrationnels sur le tore, C. R. Acad. Sci. Paris Sér. I Math. 301 (1985), 127–130.

  17. E. J. Dubuc, Concrete quasitopoi, in Applications of Sheaves, Lecture Notes in Math. 753, Springer, 1979, 239–254.

  18. L. Ducas and W. van Woerden, On the lattice isomorphism problem, quadratic forms, remarkable lattices, and cryptography, in Advances in Cryptology – EUROCRYPT 2022, Lecture Notes in Comput. Sci. 13277, Springer, 2022.

  19. L. Ducas, E. W. Postlethwaite, L. N. Pulles and W. van Woerden, Hawk: module LIP makes lattice signatures fast, compact and simple, in Advances in Cryptology – ASIACRYPT 2022, Springer, 2022.

  20. N. Dym, H. Lawrence and J. W. Siegel, Equivariant frames and the impossibility of continuous canonicalization, in Proc. 41st Int. Conf. on Machine Learning, PMLR 235 (2024), 12228–12267.

  21. M. Farber, Topological complexity of motion planning, Discrete Comput. Geom. 29 (2003), 211–221.

  22. S. Gürer and P. Iglesias-Zemmour, Differential forms on manifolds with boundary and corners, Indag. Math. 30 (2019), 920–929.

  23. S. Hallgren, Polynomial-time quantum algorithms for Pell’s equation and the principal ideal problem, J. ACM 54 (2007), no. 1, Art. 4.

  24. G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford University Press, 1979.

  25. C. Heunen, O. Kammar, S. Staton and H. Yang, A convenient category for higher-order probability theory, in Proc. 32nd ACM/IEEE Symp. on Logic in Computer Science (LICS), 2017.

  26. M. Huot, A. K. Lew, V. K. Mansinghka and S. Staton, ω\omegaPAP spaces: reasoning denotationally about higher-order, recursive probabilistic and differentiable programs, in Proc. 38th ACM/IEEE Symp. on Logic in Computer Science (LICS), 2023.

  27. M. Huot, S. Staton and M. Vákár, Correctness of automatic differentiation via diffeologies and categorical gluing, in Foundations of Software Science and Computation Structures (FoSSaCS 2020), Lecture Notes in Comput. Sci. 12077, Springer, 2020, 319–338.

  28. P. Iglesias, Fibrations difféologiques et homotopie, Thèse d’État, Université de Provence, Marseille, 1985.

  29. P. Iglesias, Difféologie d’espace singulier et petits diviseurs, C. R. Acad. Sci. Paris Sér. I Math. 302 (1986), 519–522.

  30. P. Iglesias, Y. Karshon and M. Zadka, Orbifolds as diffeologies, Trans. Amer. Math. Soc. 362 (2010), 2811–2831.

  31. P. Iglesias and G. Lachaud, Espaces différentiables singuliers et corps de nombres algébriques, Ann. Inst. Fourier (Grenoble) 40 (1990), 723–737.

  32. P. Iglesias-Zemmour, Čech–de Rham bicomplex in diffeology, Israel J. Math. 259 (2024), 239–276.

  33. P. Iglesias-Zemmour, Diffeology and arithmetic of irrational tori, preprint, arXiv:2508.07460.

  34. P. Iglesias-Zemmour and E. Prato, Quasifolds, diffeology and noncommutative geometry, J. Noncommut. Geom. 15 (2021), 735–759.

  35. P. T. Johnstone, Sketches of an Elephant: A Topos Theory Compendium, Oxford Logic Guides 43–44, Oxford University Press, 2002.

  36. H. Kihara, Model category of diffeological spaces, J. Homotopy Relat. Struct. 14 (2019), 51–90.

  37. H. Kihara, Smooth singular complexes and diffeological principal bundles, preprint, arXiv:2202.00131.

  38. D. Krepski, J. Watts and S. Wolbert, Sheaves, principal bundles, and Čech cohomology for diffeological spaces, preprint, arXiv:2111.01032.

  39. A. Kriegl and P. W. Michor, The Convenient Setting of Global Analysis, Mathematical Surveys and Monographs 53, American Mathematical Society, 1997.

  40. F. W. Lawvere, Axiomatic cohesion, Theory Appl. Categ. 19 (2007), 41–49.

  41. M. V. Losik, Fréchet manifolds as diffeological spaces, Izv. Vyssh. Uchebn. Zaved. Mat. (1992), no. 5, 36–42.

  42. J. Lurie, Higher Topos Theory, Annals of Mathematics Studies 170, Princeton University Press, 2009.

  43. Yu. I. Manin, Real multiplication and noncommutative geometry (ein Alterstraum), in The Legacy of Niels Henrik Abel, Springer, 2004, 685–727.

  44. E. Minichiello, Diffeological principal bundles and principal infinity bundles, preprint, arXiv:2202.11023.

  45. E. Minichiello, The diffeological Čech–de Rham obstruction, preprint, arXiv:2401.09400.

  46. T. Nikolaus, U. Schreiber and D. Stevenson, Principal ∞\infty-bundles: general theory, J. Homotopy Relat. Struct. 10 (2015), 749–801.

  47. D. Pavlov, Projective model structures on diffeological spaces and smooth sets and the smooth Oka principle, preprint, arXiv:2210.12845.

  48. M. A. Rieffel, C∗C^*-algebras associated with irrational rotations, Pacific J. Math. 93 (1981), 415–429.

  49. U. Schreiber, Differential cohomology in a cohesive ∞\infty-topos, preprint, arXiv:1310.7930.

  50. G. W. Schwarz, Smooth functions invariant under the action of a compact Lie group, Topology 14 (1975), 63–68.

  51. D. Shanks, The infrastructure of a real quadratic field and its applications, in Proc. 1972 Number Theory Conference, University of Colorado, Boulder, 1972, 217–224.

  52. M. Shulman, Brouwer’s fixed-point theorem in real-cohesive homotopy type theory, Math. Structures Comput. Sci. 28 (2018), 856–941.

  53. J.-M. Souriau, Groupes différentiels, in Differential Geometrical Methods in Mathematical Physics, Lecture Notes in Math. 836, Springer, 1980, 91–128.

  54. K. Waldorf, Transgression to loop spaces and its inverse, I: Diffeological bundles and fusion maps, Cah. Topol. Géom. Différ. Catég. 53 (2012), 162–210.

  55. S. Watanabe, Algebraic Geometry and Statistical Learning Theory, Cambridge University Press, 2009.

  56. J. Watts and S. Wolbert, Diffeological coarse moduli spaces of stacks over manifolds, preprint, arXiv:1406.1392.

  57. H. Whitney, Differentiable even functions, Duke Math. J. 10 (1943), 159–160.

Complete flattened LaTeX source
\documentclass[11pt,oneside,letterpaper]{book}

\usepackage[T1]{fontenc}

\usepackage[utf8]{inputenc}

\usepackage[sc]{mathpazo}

\linespread{1.045}
\usepackage{microtype}

\usepackage[letterpaper,inner=1.2in,outer=1.2in,top=1.1in,bottom=1.15in,headheight=14pt]{geometry}

\usepackage{amsmath,amssymb,amsthm,mathtools,mathrsfs,stmaryrd,bm}

\usepackage{enumitem,booktabs,array,multicol,longtable}

\usepackage[dvipsnames]{xcolor}

\usepackage{tikz,tikz-cd,pgfplots}

\usetikzlibrary{arrows.meta,calc,decorations.markings,decorations.pathmorphing,positioning,patterns,shapes.geometric,fit,backgrounds}
\pgfplotsset{compat=1.18}
\usepackage[most]{tcolorbox}

\usepackage{titlesec,fancyhdr,caption}

\usepackage[colorlinks=true,linkcolor=hcsteal,citecolor=hcsrust,urlcolor=hcsteal,bookmarksnumbered=true,
  pdftitle={Diffeology in Higher Categories},pdfsubject={Higher Categorical Semantics monograph}]{hyperref}

\usepackage[nameinlink,capitalise,noabbrev]{cleveref}


\definecolor{hcsteal}{HTML}{0F5C63}
\definecolor{hcsrust}{HTML}{A4491F}
\definecolor{hcsink}{HTML}{1E2630}
\definecolor{hcssand}{HTML}{F5EFE2}
\definecolor{hcsmist}{HTML}{E6F0F0}
\definecolor{hcsgold}{HTML}{C8912B}
\definecolor{hcsgrey}{HTML}{7A8792}
\definecolor{hcsplum}{HTML}{6B3F6E}
\color{hcsink}

\titleformat{\chapter}[display]
  {\normalfont\bfseries\color{hcsteal}}
  {\large\scshape\MakeLowercase{\chaptertitlename}\ \thechapter}{0.6ex}
  {\Huge\color{hcsink}\raggedright}[\vspace{0.6ex}{\color{hcsgold}\titlerule[1.2pt]}]
\titlespacing*{\chapter}{0pt}{0pt}{3.2ex}
\titleformat{\section}{\normalfont\Large\bfseries\color{hcsteal}}{\thesection}{0.8em}{}
\titleformat{\subsection}{\normalfont\large\bfseries\color{hcsink}}{\thesubsection}{0.7em}{}
\titleformat{\part}[display]{\normalfont\Huge\bfseries\color{hcsteal}\centering}{\Large\scshape\MakeLowercase{Part}\ \thepart}{1ex}{}

\pagestyle{fancy}
\fancyhf{}
\fancyhead[L]{\small\scshape\color{hcsgrey}\nouppercase{\leftmark}}
\fancyhead[R]{\small\color{hcsgrey}\thepage}
\renewcommand{\headrulewidth}{0.3pt}
\renewcommand{\headrule}{\color{hcsgrey}\hrule height 0.3pt}
\fancypagestyle{plain}{\fancyhf{}\fancyfoot[C]{\small\color{hcsgrey}\thepage}\renewcommand{\headrulewidth}{0pt}\renewcommand{\headrule}{}}
\renewcommand{\chaptermark}[1]{\markboth{\thechapter.\ #1}{}}
\captionsetup{font=small,labelfont={bf,color=hcsteal},margin=1.5em}
\setlist{itemsep=0.2ex,topsep=0.6ex}
\setlength{\parskip}{0.25ex plus 0.3ex}

\newtheoremstyle{hcs}{0.4ex}{0.4ex}{\itshape}{}{\bfseries\color{hcsteal}}{.}{0.6em}{}
\newtheoremstyle{hcsdef}{0.4ex}{0.4ex}{\normalfont}{}{\bfseries\color{hcsteal}}{.}{0.6em}{}
\newtheoremstyle{hcsrem}{0.9ex}{0.9ex}{\normalfont}{}{\itshape\color{hcsteal}}{.}{0.6em}{}
\theoremstyle{hcs}
\newtheorem{theorem}{Theorem}[chapter]
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{corollary}[theorem]{Corollary}
\theoremstyle{hcsdef}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{example}[theorem]{Example}
\newtheorem{construction}[theorem]{Construction}
\theoremstyle{hcsrem}
\newtheorem{remark}[theorem]{Remark}
\newtheorem{warning}[theorem]{Warning}

\tcbset{hcsbox/.style={enhanced,breakable,boxrule=0pt,frame hidden,sharp corners,
  left=9pt,right=8pt,top=5pt,bottom=5pt,before skip=1.6ex plus 0.4ex,after skip=1.6ex plus 0.4ex}}
\tcolorboxenvironment{theorem}{hcsbox,colback=hcsmist,borderline west={2.2pt}{0pt}{hcsteal}}
\tcolorboxenvironment{proposition}{hcsbox,colback=hcsmist,borderline west={2.2pt}{0pt}{hcsteal}}
\tcolorboxenvironment{lemma}{hcsbox,colback=hcsmist!55,borderline west={1.2pt}{0pt}{hcsteal}}
\tcolorboxenvironment{corollary}{hcsbox,colback=hcsmist!55,borderline west={1.2pt}{0pt}{hcsteal}}
\tcolorboxenvironment{definition}{hcsbox,colback=hcssand,borderline west={2.2pt}{0pt}{hcsgold}}
\tcolorboxenvironment{construction}{hcsbox,colback=hcssand,borderline west={2.2pt}{0pt}{hcsgold}}

\newcommand{\hcsstar}{\raisebox{0.05ex}{\scalebox{0.72}{$\bigstar$}}}
\newcommand{\lvl}[1]{  \ifcase#1\or{\color{hcsgold}\hcsstar}{\color{hcsgrey!45}\hcsstar\hcsstar\hcsstar}  \or{\color{hcsgold}\hcsstar\hcsstar}{\color{hcsgrey!45}\hcsstar\hcsstar}  \or{\color{hcsgold}\hcsstar\hcsstar\hcsstar}{\color{hcsgrey!45}\hcsstar}  \or{\color{hcsgold}\hcsstar\hcsstar\hcsstar\hcsstar}\fi}
\newcommand{\lvlname}[1]{\ifcase#1\or warm-up\or computation\or argument\or proof\fi}
\newtcolorbox[auto counter,number within=chapter,crefname={Exercise}{Exercises}]{exercise}[2][]{enhanced,breakable,sharp corners,
  colback=white,colframe=hcsrust,boxrule=0.5pt,left=8pt,right=8pt,top=5pt,bottom=5pt,
  before skip=2.2ex,after skip=0.8ex,
  fonttitle=\bfseries\small,coltitle=white,colbacktitle=hcsrust,
  title={Exercise \thetcbcounter\hfill \lvl{#2}\ \ {\normalfont\itshape\lvlname{#2}}},#1}
\newenvironment{solution}{\begin{tcolorbox}[hcsbox,colback=white,borderline west={1.2pt}{0pt}{hcsrust!60},
  before skip=0.6ex,after skip=2.2ex]\small\textsc{\color{hcsrust}Solution.}\ }{\hfill{\color{hcsrust}$\blacktriangleleft$}\end{tcolorbox}}

\newcommand{\exercisesheading}{\section*{Solved exercises}\addcontentsline{toc}{section}{Solved exercises}  {\small\itshape\color{hcsgrey} Ratings: \lvl{1} warm-up, \lvl{2} computation, \lvl{3} argument, \lvl{4} proof-level.
  Every exercise is followed by a complete solution.}\par\medskip}

\newenvironment{chapabstract}{\begin{quote}\small\itshape\color{hcsink!85}}{\end{quote}\medskip}
\newcommand{\source}[1]{{\small\noindent\textsc{\color{hcsrust}Source in the book.}\ #1\par}\medskip}

\newcommand{\R}{\mathbb{R}}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\Q}{\mathbb{Q}}
\newcommand{\N}{\mathbb{N}}
\newcommand{\C}{\mathbb{C}}
\newcommand{\T}{\mathbb{T}}
\newcommand{\cat}[1]{\mathsf{#1}}
\newcommand{\Diff}{\cat{Diff}}
\newcommand{\Dom}{\cat{Dom}}
\newcommand{\Cart}{\cat{Cart}}
\newcommand{\Mfd}{\cat{Mfd}}
\newcommand{\Set}{\cat{Set}}
\newcommand{\Top}{\cat{Top}}
\newcommand{\Sh}{\cat{Sh}}
\newcommand{\PSh}{\cat{PSh}}
\newcommand{\ConcSh}{\cat{ConcSh}}
\newcommand{\SmSet}{\cat{SmoothSet}}
\newcommand{\Hh}{\mathbf{H}}
\newcommand{\Spc}{\cat{S}}
\newcommand{\Grpd}{\cat{Grpd}}
\newcommand{\Disc}{\operatorname{Disc}}
\newcommand{\coDisc}{\operatorname{coDisc}}
\newcommand{\conc}{\operatorname{conc}}
\newcommand{\shp}{\mathord{\textstyle\smallint}}
\newcommand{\fl}{\flat}
\newcommand{\shr}{\sharp}
\newcommand{\cinf}{C^{\infty}}
\newcommand{\Paths}{\operatorname{Paths}}
\newcommand{\Loops}{\operatorname{Loops}}
\newcommand{\Hom}{\operatorname{Hom}}
\newcommand{\Map}{\operatorname{Map}}
\newcommand{\End}{\operatorname{End}}
\newcommand{\Aut}{\operatorname{Aut}}
\newcommand{\Dif}{\operatorname{Diff}}
\newcommand{\GL}{\operatorname{GL}}
\newcommand{\SL}{\operatorname{SL}}
\newcommand{\PGL}{\operatorname{PGL}}
\newcommand{\Ort}{\operatorname{O}}
\newcommand{\Pic}{\operatorname{Pic}}
\newcommand{\Fl}{\operatorname{Fl}}
\newcommand{\Bun}{\operatorname{Bun}}
\newcommand{\B}{\mathbf{B}}
\newcommand{\Om}{\Omega}
\newcommand{\dR}{\mathrm{dR}}
\newcommand{\colim}{\operatorname*{colim}}
\newcommand{\holim}{\operatorname*{holim}}
\newcommand{\hocolim}{\operatorname*{hocolim}}
\newcommand{\im}{\operatorname{im}}
\newcommand{\coker}{\operatorname{coker}}
\newcommand{\id}{\mathrm{id}}
\newcommand{\ev}{\mathrm{ev}}
\newcommand{\pr}{\mathrm{pr}}
\newcommand{\op}{\mathrm{op}}
\newcommand{\Lam}{\Lambda}
\newcommand{\Tal}{T_{\alpha}}
\newcommand{\Rd}{\R^{\delta}}
\newcommand{\dd}{\mathrm{d}}
\newcommand{\norm}[1]{\lVert #1\rVert}
\newcommand{\abs}[1]{\lvert #1\rvert}
\newcommand{\set}[1]{\{\,#1\,\}}
\newcommand{\hquot}{/\!\!/}
\newcommand{\IZ}[1]{\textup{[IZ,\,#1]}}
\newcommand{\defn}[1]{\textbf{\color{hcsink}#1}}
\newcommand{\Sub}{\mathrm{sub}}
\newcommand{\xto}[1]{\xrightarrow{\;#1\;}}
\newcommand{\into}{\hookrightarrow}
\newcommand{\onto}{\twoheadrightarrow}
\newcommand{\dten}{\Delta}
\newcommand{\Ob}{\operatorname{Ob}}
\newcommand{\Mor}{\operatorname{Mor}}
\newcommand{\rk}{\operatorname{rk}}
\newcommand{\Sym}{\operatorname{Sym}}
\newcommand{\TC}{\operatorname{TC}}
\newcommand{\AD}{\mathcal{D}}

\tikzset{>={Stealth[length=5pt]},
  hookr/.style={{Hooks[right,length=3pt,width=6pt]}->},
  hcsnode/.style={draw=hcsteal,fill=hcsmist,rounded corners=2pt,inner sep=4pt,font=\small},
  hcsnodeb/.style={draw=hcsgold,fill=hcssand,rounded corners=2pt,inner sep=4pt,font=\small},
  hcsnoder/.style={draw=hcsrust,fill=white,rounded corners=2pt,inner sep=4pt,font=\small},
  every picture/.style={line cap=round,line join=round}}



\newcommand{\hcsauthor}{Anonymous submission}
\newcommand{\hcsvenue}{higher-categorical-semantics.pages.dev}
\newcommand{\hcsdate}{27 November 2026}

\begin{document}
\frontmatter

\begin{titlepage}
\thispagestyle{empty}
\begin{center}
{\small\scshape\color{hcsgrey} Higher Categorical Semantics \textperiodcentered\ Monograph}\par
\vspace{2.2cm}
{\fontsize{34}{40}\selectfont\bfseries\color{hcsteal} Diffeology in\\[0.35ex] Higher Categories\par}
\vspace{0.9cm}
{\Large\color{hcsink} Concrete sheaves, cohesive shape, and stacks\\[0.3ex]
behind Iglesias-Zemmour's \emph{Diffeology}\par}
\vspace{0.5cm}
{\large\itshape\color{hcsrust} with applications to arithmetic, cryptography,\\ machine learning, artificial intelligence, and system design\par}
\vspace{1.3cm}
\begin{tikzpicture}[scale=5.2]
  \def\gold{0.6180339}
  \fill[hcsmist] (0,0) rectangle (1,1);
  \begin{scope}
    \clip (0,0) rectangle (1,1);
    \foreach \n in {0,...,33}{
      \pgfmathsetmacro{\c}{\n*\gold-floor(\n*\gold)}
      \pgfmathsetmacro{\op}{0.25+0.75*(34-\n)/34}
      \draw[hcsteal,line width=0.45pt,opacity=\op] (0,\c) -- (1,\c+\gold);
      \draw[hcsteal,line width=0.45pt,opacity=\op] (0,\c-1) -- (1,\c-1+\gold);
    }
  \end{scope}
  \draw[hcsink,line width=0.9pt] (0,0) rectangle (1,1);
  \draw[hcsgold,line width=1.3pt,->] (0,0) -- (0.34,0.34*\gold);
  \foreach \p in {(0.5,0),(0.5,1)} \draw[hcsink,line width=0.9pt] \p ++(-0.012,-0.02) -- ++(0.024,0.02) -- ++(-0.024,0.02);
  \foreach \p in {(0,0.5),(1,0.5)} {\draw[hcsink,line width=0.9pt] \p ++(-0.02,-0.02) -- ++(0.02,0.024) -- ++(0.02,-0.024);
     \draw[hcsink,line width=0.9pt] \p ++(-0.02,0.004) -- ++(0.02,0.024) -- ++(0.02,-0.024);}
\end{tikzpicture}\par
\vspace{0.35cm}
{\footnotesize\color{hcsgrey} One leaf of the Kronecker foliation of slope $\alpha=(\sqrt5-1)/2$ on $T^2$.\\
Its leaf space $T_\alpha=\R/(\Z+\alpha\Z)$ is a point for topology, a group for diffeology, and $\B\Z^2$ for homotopy.\par}
\vfill
{\large \hcsauthor\par}
\vspace{0.4ex}
{\small\color{hcsgrey} Prepared for \texttt{\hcsvenue}\ \textperiodcentered\ \hcsdate\par}
\end{center}
\end{titlepage}

\chapter*{Abstract}
\thispagestyle{plain}
In \emph{Diffeology} \cite{IZ}, Patrick Iglesias-Zemmour develops differential geometry on sets equipped
with a family of ``plots'', and proves that this datum suffices for homotopy theory, Cartan calculus,
fibre bundles and symplectic geometry far outside the category of manifolds. The arguments there are carried out directly with sets
and maps. Here the categorical language is added, and the theory is then raised one categorical level.

\medskip\noindent
\textbf{Part I.} The three axioms of a diffeology are the sheaf condition on a concrete site, and
the structural theorems of the book (limits, colimits, function spaces, inductions and subductions) follow from the fact that
$\Diff$ is the quasitopos of concrete sheaves on Cartesian spaces (Baez--Hoffnung, Dubuc).
\textbf{Part II.} $\Diff$ embeds in the cohesive $\infty$-topos $\Hh=\Sh_\infty(\Cart)$ of smooth
$\infty$-groupoids. There the book's smooth homotopy groups are the homotopy groups of the \emph{shape} $\shp X$;
its differential forms are maps into the non-concrete classifying sheaves $\Om^k$; its fibre bundles are maps
into classifying stacks $\B G$ that are not diffeological spaces; and the failure of de~Rham's theorem on the
irrational torus becomes a spectral sequence whose first obstruction group is the group of principal
$\R$-bundles. The organising statement is a trichotomy of quotients,
\[
X\hquot G\;\longrightarrow\;\pi_0(X\hquot G)\;\longrightarrow\;\conc\,\pi_0(X\hquot G)=X/G ,
\]
stack, smooth set, diffeological space, with exact criteria for when each arrow is an equivalence.

\medskip\noindent
\textbf{Part III} consists of applications. In number theory, the irrational torus $T_\alpha$ realises
$\GL_2(\Z)$-equivalence, real quadratic units and Diophantine type as diffeological invariants. In
cryptography, tori with real multiplication form a torsor under the class group of a real quadratic order, and
deciding diffeomorphism is the principal ideal problem. In machine learning we prove correctness of forward-mode
automatic differentiation by gluing over $\Diff$, and that orbit spaces have no differentiable canonicalisation at
points with isotropy. In artificial intelligence, a global smooth motion planner exists exactly on smoothly
contractible spaces, and an agent restricted to smooth scalar observations can determine a space only up to its reflexive hull. In system design we
give a minimal-realisation theorem with two inequivalent quotients, and classify multi-clock systems by their
frequency module. Each of these chapters contains at least three theorems with proofs; every chapter ends with
solved exercises graded from warm-up to proof.

\medskip\noindent
{\small\color{hcsgrey}\textbf{Keywords.} Diffeological space; concrete sheaf; quasitopos; cohesive $\infty$-topos; shape;
smooth stack; irrational torus; de~Rham obstruction; real multiplication; automatic differentiation; motion planning.\\
\textbf{MSC 2020.} 58A40, 18F10, 18N60, 18B25, 55P60, 57R18, 11R11, 11J70, 68T07, 94A60.}

\tableofcontents

\chapter*{Preface}
\addcontentsline{toc}{chapter}{Preface}
\markboth{Preface}{}

\section*{What this is}
A \emph{companion} to the source text, a 450-page treatise whose method is to stay as close to the sets and the maps as
possible. That method is a strength: the reader of \cite{IZ} never needs a universe, a model structure or a coherence
theorem. Three of the book's central objects, however, are not objects of the category of diffeological spaces:
\begin{enumerate}[label=(\roman*)]
\item the object that classifies differential $k$-forms, $\Om^k$, is a sheaf with exactly one point;
\item the object that classifies principal $G$-bundles, $\B G$, is a stack;
\item the homotopy type $\shp X$ is an $\infty$-groupoid.
\end{enumerate}
In \cite{IZ} each of these is treated by an explicit construction on plots. We put all three in one ambient
$\infty$-topos, where the constructions become representability statements.

\section*{Attribution}
A Theorem, Proposition or Lemma with a name or a reference in its heading is taken from the literature, and is given with that
reference and, when it is short, a proof. Every other numbered statement is proved in the text. Formalisation in a proof
assistant is the subject of a sequel; in \cref{ch:coda} the statements are sorted by the infrastructure required.

\section*{How to read}
Parts I and II are cumulative. The application chapters depend on them as follows.

\begin{center}
\begin{tikzpicture}[font=\small]
  \node[hcsnode] (c1) at (0,0) {1 Plots};
  \node[hcsnode] (c2) at (3.1,0) {2 Concrete sheaves};
  \node[hcsnode] (c3) at (6.5,0) {3 Quasitopos};
  \node[hcsnode] (c4) at (9.6,0) {4 Cohesion};
  \node[hcsnode] (c5) at (0,-1.25) {5 Shape};
  \node[hcsnode] (c6) at (3.1,-1.25) {6 Forms};
  \node[hcsnode] (c7) at (6.5,-1.25) {7 Bundles and stacks};
  \node[hcsnode] (c8) at (9.6,-1.25) {8 Models};
  \draw[->] (c1)--(c2); \draw[->] (c2)--(c3); \draw[->] (c3)--(c4);
  \draw[->,rounded corners=3pt] (c4.south) -- ++(0,-0.3) -| (c5.north);
  \draw[->] (c5)--(c6); \draw[->] (c6)--(c7); \draw[->] (c7)--(c8);
\end{tikzpicture}

\medskip
{\small
\begin{tabular}{@{}ll@{}}\toprule
application chapter & draws on\\\midrule
9\ \ Number theory & Chapters 1, 5, 6, 7\\
10\ \ Cryptography & Chapter 9; Chapter 8 for orbifolds\\
11\ \ Machine learning & Chapters 1--3 and 8\\
12\ \ Artificial intelligence & Chapters 1--3, 5 and 8\\
13\ \ System design & Chapters 3, 7 and 9\\\bottomrule
\end{tabular}}
\end{center}

\section*{Conventions}
A \emph{domain} is an open subset of some $\R^n$, $n\ge 0$; a \emph{Cartesian space} is a domain diffeomorphic to $\R^n$.
$\Dom$ and $\Cart$ are the corresponding categories with smooth maps. We cite the source as \IZ{art.~$x.y$} for its numbered
articles and \IZ{Exercise~$n$} for its exercises. ``Smooth'' means $\cinf$. All $\infty$-categorical statements are about
$(\infty,1)$-categories in the sense of \cite{HTT}; limits and colimits in $\Hh$ are homotopy limits and colimits.
$\R$ denotes the smooth additive group and $\Rd$ the same group with the discrete diffeology. For a group $G$ acting on $X$ we
write $X/G$ for the diffeological quotient and $X\hquot G$ for the homotopy quotient in $\Hh$; much of what follows is
about the difference.


\mainmatter
\part{Diffeology as a category of sheaves}

\chapter{Plots}\label{ch:plots}

\begin{chapabstract}
A diffeology is a choice of which parametrisations of a set are smooth. We recall the axioms, the two transport operations
(pullback and pushforward), and the two distinguished classes of maps (inductions and subductions), organised around one
fact: the underlying-set functor $\Diff\to\Set$ is topological. Three examples introduced here --- the irrational torus, the
orbit space $\R/\{\pm1\}$ and the cross --- are the test cases for every later construction.
\end{chapabstract}
\source{\IZ{Chapter~1} and the D-topology of \IZ{Chapter~2}.}

\section{The axioms}

A \defn{parametrisation} of a set $X$ is a map $P\colon U\to X$ whose source is a domain. We write $\mathrm{Param}(X)$ for
the set of all of them.

\begin{definition}[\IZ{art.~1.5}]\label{def:diffeology}
A \defn{diffeology} on a set $X$ is a subset $\mathcal D\subseteq\mathrm{Param}(X)$, whose elements are called \defn{plots}, such that
\begin{enumerate}[label=\textup{(D\arabic*)}]
\item\label{D1} \emph{covering:} every constant parametrisation is a plot;
\item\label{D2} \emph{locality:} if $P\colon U\to X$ restricts to a plot on each member of an open cover of $U$, then $P$ is a plot;
\item\label{D3} \emph{smooth compatibility:} if $P\colon U\to X$ is a plot and $F\colon V\to U$ is a smooth map between domains, then $P\circ F$ is a plot.
\end{enumerate}
A \defn{diffeological space} is a set with a diffeology. A map $f\colon X\to X'$ is \defn{smooth} if $f\circ P$ is a plot of
$X'$ for every plot $P$ of $X$. Diffeological spaces and smooth maps form the category $\Diff$; its isomorphisms are called
\defn{diffeomorphisms}.
\end{definition}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \draw[fill=hcssand,draw=hcsgold,line width=0.8pt] plot[smooth cycle,tension=0.8]
     coordinates {(5.2,0.2) (6.6,-0.5) (8.3,0.1) (8.6,1.6) (7.3,2.5) (5.6,2.0)};
  \node at (8.85,2.35) {$X$};
  \draw[fill=hcsmist,draw=hcsteal] (0.2,1.25) ellipse (1.15 and 0.7);
  \node at (0.2,1.25) {$U\subseteq\R^2$};
  \draw[hcsteal,line width=1.3pt] (-0.7,-0.9) -- (1.1,-0.9);
  \node[below] at (0.2,-0.95) {$V\subseteq\R$};
  \draw[fill=hcsteal!22,draw=hcsteal] (6.95,1.2) ellipse (0.95 and 0.55);
  \draw[hcsrust,line width=1.1pt] plot[smooth] coordinates {(6.3,1.0) (6.8,1.35) (7.3,1.1) (7.7,1.4)};
  \draw[->] (1.45,1.35) to[bend left=12] node[above]{$P$} (5.9,1.45);
  \draw[->] (1.2,-0.8) to[bend right=14] node[below]{$P\circ F$} (6.35,0.85);
  \draw[->] (0.2,-0.75) -- node[left]{$F$} (0.2,0.45);
\end{tikzpicture}
\caption{A diffeology is a family of maps into a set from domains of every dimension. By axiom \ref{D3} the family is closed under smooth
reparametrisation; by axiom \ref{D2} membership in the family is a local property of the source. No structure on $X$ itself is required.}
\label{fig:plots}
\end{figure}

Two observations set the tone for everything that follows.

\begin{remark}[Plots are the smooth maps from domains]\label{rem:yoneda}
Give a domain $U$ the diffeology of all smooth parametrisations. Then by \ref{D3} a parametrisation $P\colon U\to X$ is a plot
if and only if it is a smooth map $U\to X$. So $\mathcal D(U)=\Diff(U,X)$: a diffeological space \emph{is} the functor it
represents on $\Dom$. This is made precise in \cref{ch:concrete}.
\end{remark}

\begin{remark}[No condition on $X$]
A manifold is a set that is locally \emph{modelled on} $\R^n$. A diffeological space is a set that domains can be \emph{mapped
into}. The first is a condition on the object; the second is the choice of a structure. This is why every construction
below exists without hypotheses.
\end{remark}

\begin{example}\label{ex:first}
\begin{enumerate}[label=(\alph*)]
\item A domain, or more generally a smooth manifold $M$, carries the \defn{standard} diffeology of smooth parametrisations.
A map between manifolds is smooth in the sense of \cref{def:diffeology} exactly when it is smooth in the usual sense, so
$\Mfd\into\Diff$ is full and faithful.
\item The \defn{discrete} diffeology on a set consists of the locally constant parametrisations; the \defn{coarse} diffeology
consists of all parametrisations.
\item The \defn{wire} diffeology on $\R^n$ consists of the parametrisations that are, near each point, either constant or of the
form $\gamma\circ h$ with $h\colon V\to\R$ and $\gamma\colon\R\to\R^n$ smooth \IZ{art.~1.10}. For $n\ge2$ it is strictly finer than the
standard one (\cref{exo:wire}).
\end{enumerate}
\end{example}

\section{The underlying-set functor is topological}

The diffeologies on a fixed set $X$ are ordered by inclusion: $\mathcal D$ is \defn{finer} than $\mathcal D'$ if
$\mathcal D\subseteq\mathcal D'$. Arbitrary intersections of diffeologies are diffeologies, so they form a complete lattice with
the discrete diffeology at the bottom and the coarse one at the top. A subset $\mathcal F\subseteq\mathrm{Param}(X)$
\defn{generates} the smallest diffeology $\langle\mathcal F\rangle$ containing it; explicitly, $P\in\langle\mathcal F\rangle$ if and
only if near each point $P$ is constant or of the form $Q\circ F$ with $Q\in\mathcal F$ and $F$ smooth \IZ{art.~1.66--1.68}.

\begin{definition}\label{def:pullpush}
Let $f\colon X\to X'$ be a map of sets.
\begin{enumerate}[label=(\alph*)]
\item If $X'$ is diffeological, the \defn{pullback} $f^*(\mathcal D')$ is the set of parametrisations $P$ of $X$ with $f\circ P\in\mathcal D'$.
It is the coarsest diffeology on $X$ making $f$ smooth.
\item If $X$ is diffeological, the \defn{pushforward} $f_*(\mathcal D)$ is the diffeology on $X'$ generated by $\set{f\circ P : P\in\mathcal D}$.
It is the finest diffeology on $X'$ making $f$ smooth.
\end{enumerate}
A smooth map $f\colon X\to X'$ is an \defn{induction} if it is injective and $\mathcal D=f^*(\mathcal D')$; it is a
\defn{subduction} if it is surjective and $\mathcal D'=f_*(\mathcal D)$.
\end{definition}

Unwinding, $f$ is a subduction exactly when it is surjective and \emph{plots of $X'$ lift locally}: for every plot
$P\colon U\to X'$ and every $r\in U$ there are an open $V\ni r$ and a plot $Q\colon V\to X$ with $f\circ Q=P|_V$
\IZ{art.~1.48}. Dually, $f$ is an induction exactly when it is injective and a parametrisation of $X$ is a plot as soon as its
composite with $f$ is one \IZ{art.~1.31}.

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \node (V) at (0,0) {$V$}; \node (X) at (2.2,1.5) {$X$}; \node (U) at (0,-1.3) {$U$}; \node (Y) at (2.2,-1.3) {$X'$};
  \draw[->,dashed,hcsrust] (V) -- node[above left]{$\exists\,Q$} (X);
  \draw[hookr] (V) -- (U);
  \draw[->>] (X) -- node[right]{$f$} (Y);
  \draw[->] (U) -- node[below]{$P$} (Y);
  \node[font=\footnotesize,hcsgrey] at (1.1,-2.0) {subduction: plots lift locally};
 \end{scope}
 \begin{scope}[xshift=6.2cm]
  \node (U) at (0,0.1) {$U$}; \node (X) at (2.4,0.1) {$X$}; \node (Y) at (2.4,-1.3) {$X'$};
  \draw[->,dashed,hcsrust] (U) -- node[above]{$P$ is a plot} (X);
  \draw[hookr] (X) -- node[right]{$f$} (Y);
  \draw[->] (U) -- node[below left]{$f\circ P$ plot} (Y);
  \node[font=\footnotesize,hcsgrey] at (1.2,-2.0) {induction: plots are detected in the target};
 \end{scope}
\end{tikzpicture}
\caption{The two distinguished classes of smooth maps. In \cref{ch:quasitopos} they become the strong epimorphisms and the strong
monomorphisms of $\Diff$.}\label{fig:ind-sub}
\end{figure}

The whole of \IZ{Chapter~1} can be compressed into one categorical statement.

\begin{theorem}[The underlying-set functor is topological]\label{thm:topological}
Let $|\cdot|\colon\Diff\to\Set$ be the underlying-set functor.
\begin{enumerate}[label=\textup{(\roman*)}]
\item \textup{(Initial lifts.)} For every family of maps $f_i\colon X\to |X_i|$ into diffeological spaces there is a unique diffeology on $X$
such that a map $g\colon Z\to X$ from a diffeological space is smooth if and only if every $f_i\circ g$ is smooth. It is
$\bigcap_i f_i^*(\mathcal D_i)$.
\item \textup{(Final lifts.)} For every family of maps $g_i\colon |X_i|\to X$ there is a unique diffeology on $X$ such that
a map $h\colon X\to Z$ is smooth if and only if every $h\circ g_i$ is smooth. It is generated by $\bigcup_i\set{g_i\circ P : P\in\mathcal D_i}$.
\end{enumerate}
Consequently $\Diff$ is complete and cocomplete, $|\cdot|$ preserves limits and colimits, and $|\cdot|$ has a left adjoint
(discrete diffeology) and a right adjoint (coarse diffeology).
\end{theorem}

\begin{proof}
(i) An intersection of diffeologies is a diffeology, and $P\in\bigcap_i f_i^*(\mathcal D_i)$ means that each $f_i\circ P$ is a plot.
If $g\colon Z\to X$ and all $f_i\circ g$ are smooth, then for a plot $Q$ of $Z$ each $f_i\circ g\circ Q$ is a plot, so $g\circ Q$
is a plot of $X$; the converse is composition. Uniqueness: two diffeologies with the property make the identity smooth in both directions.
(ii) Let $\mathcal D$ be the generated diffeology. If every $h\circ g_i$ is smooth and $P\in\mathcal D$, then locally $P$ is
constant or $P=g_i\circ Q\circ F$, so $h\circ P$ is locally a plot of $Z$, hence a plot by \ref{D2}. The rest is as in (i).
For the consequences: a limit of a diagram $(X_j)$ is the limit of the underlying sets with the initial diffeology for the
projections; a colimit is the colimit of sets with the final diffeology for the coprojections. The adjoints are the initial and
final lifts of the empty family.
\end{proof}

Specialising \cref{thm:topological} gives the constructions of the book with their universal properties attached:

\begin{center}\small
\begin{tabular}{@{}lll@{}}\toprule
construction & diffeology & reference\\\midrule
subspace $A\subseteq X$ & initial for $A\into X$ (plots of $X$ with values in $A$) & \IZ{art.~1.33}\\
product $\prod_i X_i$ & initial for the projections (componentwise plots) & \IZ{art.~1.55}\\
quotient $X/{\sim}$ & final for $X\to X/{\sim}$ (plots lift locally) & \IZ{art.~1.50}\\
sum $\coprod_i X_i$ & final for the injections (plots locally in one summand) & \IZ{art.~1.39}\\
\bottomrule\end{tabular}
\end{center}

\begin{proposition}[Stability]\label{prop:stability}
\begin{enumerate}[label=\textup{(\roman*)}]
\item Subductions are closed under composition, under products, and under pullback along arbitrary smooth maps.
\item Inductions are closed under composition, under products, and under pullback along arbitrary smooth maps.
\item A map that is both an induction and a subduction is a diffeomorphism.
\end{enumerate}
\end{proposition}
\noindent The proof is \cref{exo:stability}. Part (i) is false in $\Top$ for quotient maps, and is the first respect in which $\Diff$ has
better exactness properties than $\Top$.

\section{Function spaces}

\begin{definition}[\IZ{art.~1.57}]\label{def:functional}
For diffeological spaces $X,Y$, the \defn{functional diffeology} on $\cinf(X,Y)$ consists of the parametrisations
$P\colon U\to\cinf(X,Y)$ whose adjoint $(r,x)\mapsto P(r)(x)$ is a smooth map $U\times X\to Y$.
\end{definition}

\begin{theorem}[Cartesian closure, \IZ{art.~1.60}]\label{thm:ccc}
For diffeological spaces $X,Y,Z$, currying is a diffeomorphism
\[
\cinf(X\times Y,Z)\;\cong\;\cinf\bigl(X,\cinf(Y,Z)\bigr),\qquad f\longmapsto\bigl(x\mapsto f(x,-)\bigr).
\]
In particular evaluation $\ev\colon\cinf(Y,Z)\times Y\to Z$ and composition
$\cinf(X,Y)\times\cinf(Y,Z)\to\cinf(X,Z)$ are smooth.
\end{theorem}
\noindent The proof is \cref{exo:ccc}. Two consequences: \emph{paths in a function space are the same thing as homotopies}, and
a smooth family of smooth maps is the same thing as a smooth map out of a product. Both are false for manifolds, where the
function space does not exist, and both will be used without comment from \cref{ch:homotopy} on.

\section{Three running examples}\label{sec:running}

\subsection{The irrational torus}
Fix $\alpha\in\R\smallsetminus\Q$, let $\Lam_\alpha=\Z+\alpha\Z\subset\R$, and let
\[
q_\alpha\colon\R\longrightarrow \Tal:=\R/\Lam_\alpha
\]
carry the quotient diffeology. Since $\Lam_\alpha$ is dense in $\R$, the quotient topology on $\Tal$ is indiscrete.
Equivalently $\Tal$ is the space of leaves of the linear foliation of slope $\alpha$ on $T^2=\R^2/\Z^2$: the map
$(x,y)\mapsto y-\alpha x$ descends to a bijection $T^2/\R\to\Tal$, which is a diffeomorphism for the quotient diffeologies.
The two descriptions are drawn in \cref{fig:cutproject}.

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}[scale=3.1]
  \def\gold{0.6180339}
  \fill[hcsmist] (0,0) rectangle (1,1);
  \begin{scope}\clip (0,0) rectangle (1,1);
   \foreach \n in {0,...,12}{
     \pgfmathsetmacro{\c}{\n*\gold-floor(\n*\gold)}
     \draw[hcsteal,line width=0.5pt] (0,\c) -- (1,\c+\gold);
     \draw[hcsteal,line width=0.5pt] (0,\c-1) -- (1,\c-1+\gold);}
  \end{scope}
  \draw[line width=0.8pt] (0,0) rectangle (1,1);
  \node[below] at (0.5,0) {$T^2=\R^2/\Z^2$};
  \draw[hcsgold,line width=1.2pt,->] (0,0)--(0.4,0.4*\gold);
  \node[font=\footnotesize,fill=hcsmist,inner sep=1.2pt] at (0.72,0.2) {slope $\alpha$};
 \end{scope}
 \draw[->>,line width=0.6pt] (3.4,1.55) -- node[above]{leaves} (4.6,1.55);
 \node[hcsnode] at (5.2,1.55) {$\Tal$};
 \draw[<<-,line width=0.6pt] (5.8,1.55) -- node[above]{$q_\alpha$} (6.8,1.55);
 \begin{scope}[xshift=9.5cm,yshift=1.45cm,scale=0.66]
  \def\gold{0.6180339}
  \draw[->,hcsgrey] (-3.6,0)--(3.9,0) node[right,hcsink]{$\R$};
  \foreach \m in {-2,...,2}\foreach \n in {-2,...,2}{
     \pgfmathsetmacro{\x}{\m+\n*\gold}
     \draw[hcsgrey,dashed,line width=0.35pt] (\m,\n) -- (\x,0);
     \fill[hcsink] (\m,\n) circle (2.2pt);
     \fill[hcsrust] (\x,0) circle (1.9pt);}
  \node[font=\footnotesize] at (0.6,-2.75) {$\Z^2\ni(m,n)\mapsto m+n\alpha\in\Lam_\alpha$};
 \end{scope}
\end{tikzpicture}
\caption{Two pictures of the irrational torus. Left: the leaf space of the Kronecker foliation. Right: the quotient of $\R$ by the
dense subgroup $\Lam_\alpha$, itself the image of $\Z^2$ under a linear projection (the ``cut and project'' description of a
one-dimensional quasicrystal).}\label{fig:cutproject}
\end{figure}

\begin{proposition}\label{prop:Talpha-basic}
\begin{enumerate}[label=\textup{(\roman*)}]
\item Every smooth map from $\Tal$ to a manifold is constant; in particular $\cinf(\Tal,\R)=\R$.
\item The diffeology of $\Tal$ is neither discrete nor coarse.
\item $q_\alpha$ is a subduction with discrete fibres, and any two local lifts of a plot differ by a locally constant element of $\Lam_\alpha$.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) If $f\colon\Tal\to M$ is smooth then $f\circ q_\alpha\colon\R\to M$ is continuous and $\Lam_\alpha$-invariant, hence constant on a dense
set, hence constant. (iii) $q_\alpha$ is a subduction by definition. If $Q,Q'\colon V\to\R$ lift the same plot then $Q-Q'$ is a continuous
map into the countable set $\Lam_\alpha$, so it is locally constant; in particular every plot of a fibre is locally constant, and the fibres are discrete.
(ii) $q_\alpha$ is a plot that is not locally constant, so $\Tal$ is not discrete. The parametrisation $t\mapsto q_\alpha(\sqrt{\abs t})$ is not a
plot: by (iii) a local lift near $0$ would be $t\mapsto\sqrt{\abs t}+\lambda$, which is not smooth. So $\Tal$ is not coarse.
\end{proof}

The D-topology of $\Tal$ is indiscrete and its smooth real functions are constant, while its plots are those of a one-dimensional group. By \cref{ch:number-theory} the plots determine the tail of the
continued fraction of $\alpha$.

\subsection{Half of a line, twice}
Let $\dten_1=\R/\{\pm1\}$ with the quotient diffeology, and let $H=[0,\infty)\subset\R$ with the subspace diffeology. The map
$x\mapsto x^2$ factors as
\begin{equation}\label{eq:delta1}
\R\;\onto\;\dten_1\;\xto{\ \mathrm{sq}\ }\;H\;\into\;\R .
\end{equation}

\begin{proposition}\label{prop:delta1}
$\mathrm{sq}\colon\dten_1\to H$ is a smooth bijection that is not a diffeomorphism.
\end{proposition}
\begin{proof}
Smoothness and bijectivity are clear. The parametrisation $P(r,s)=r^2+s^2$ of $H$ is a plot, being smooth into $\R$ with values in $H$.
Suppose $\mathrm{sq}^{-1}\circ P$ were a plot of $\dten_1$. Then on a disc $V$ around $0$ there would be a smooth $Q\colon V\to\R$ with
$Q^2=r^2+s^2$. On the connected set $V\smallsetminus\{0\}$ the function $Q$ has no zero, so it has constant sign and $Q=\pm\sqrt{r^2+s^2}$,
which is not differentiable at the origin.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \draw[hcsteal,line width=0.9pt] (0,1.8) ellipse (1.25 and 0.3);
  \draw[hcsteal,line width=0.9pt] plot[domain=-1.25:1.25,samples=40] (\x,{1.15*\x*\x});
  \draw[hcsgrey,->] (-1.7,0)--(1.7,0); \draw[hcsgrey,->] (0,-0.2)--(0,2.5) node[above,hcsink]{$H$};
  \node[font=\footnotesize] at (0,-0.55) {plot $P=r^2+s^2$ of $H$: smooth};
 \end{scope}
 \begin{scope}[xshift=5.4cm]
  \draw[hcsrust,line width=0.9pt] (0,1.8) ellipse (1.25 and 0.3);
  \draw[hcsrust,line width=0.9pt] (-1.25,1.8)--(0,0)--(1.25,1.8);
  \draw[hcsgrey,->] (-1.7,0)--(1.7,0); \draw[hcsgrey,->] (0,-0.2)--(0,2.5) node[above,hcsink]{$\R$};
  \node[font=\footnotesize] at (0,-0.55) {its only lifts $\pm\sqrt{r^2+s^2}$: a cone};
 \end{scope}
 \draw[->,dashed] (3.9,1.0) -- node[above,font=\footnotesize]{$x\mapsto x^2$} (1.9,1.0);
\end{tikzpicture}
\caption{The same set $[0,\infty)$ carries two diffeologies. The plot on the left belongs to the subspace $H\subset\R$ but not to the
quotient $\dten_1=\R/\{\pm1\}$, because lifting it through the squaring map would require smoothing a cone.}\label{fig:cone}
\end{figure}

So \eqref{eq:delta1} exhibits two different ``images'' of the squaring map: the quotient of the source and the subspace of the
target. A map for which they coincide is called \emph{strict} in \IZ{art.~1.54}; in \cref{ch:quasitopos} the two images are identified with
the two factorisation systems of a quasitopos, and the gap between them is the subject of Chapters~\ref{ch:ml} and~\ref{ch:systems}.

\subsection{The cross}
Let $K=\set{(x,y)\in\R^2 : xy=0}$ with the subspace diffeology, and let $\R\vee\R$ be the pushout of two lines along their origins,
with the final diffeology. The canonical map $\R\vee\R\to K$ is a smooth bijection, and again not a diffeomorphism
(\cref{exo:cross}): a smooth curve in $K$ can cross from one axis to the other at an isolated time, provided all its derivatives vanish there; such a curve is not a plot of
$\R\vee\R$.

\section{The D-topology}

\begin{definition}[\IZ{art.~2.8}]
A subset $A\subseteq X$ of a diffeological space is \defn{D-open} if $P^{-1}(A)$ is open for every plot $P$. The D-open sets form
the \defn{D-topology}, the finest topology making all plots continuous.
\end{definition}

Smooth maps are D-continuous, so this defines a functor $D\colon\Diff\to\Top$. For a quotient, $A\subseteq X/{\sim}$ is D-open
if and only if its preimage in $X$ is D-open \IZ{art.~2.12}. The D-topology of a manifold is its topology; the D-topology of
$\Tal$ is indiscrete. We will see in \cref{prop:Dadj} that $D$ is a left adjoint, and in \cref{ch:homotopy} that it is the wrong
tool for homotopy theory: the homotopy type of $D(\Tal)$ is a point, while the homotopy type that the plots of $\Tal$ determine is
a torus.

\exercisesheading

\begin{exercise}[label=exo:wire]{1}
Show that for $n\ge 2$ the identity of $\R^n$ is not a plot for the wire diffeology of \cref{ex:first}(c).
\end{exercise}
\begin{solution}
If it were, then near $0$ we could write $\id=\gamma\circ h$ with $h\colon V\to\R$ and $\gamma\colon\R\to\R^n$ smooth. By the chain
rule the derivative of $\gamma\circ h$ at any point has rank at most $1$, while the identity has rank $n\ge 2$. (The alternative,
that $\id$ is locally constant, is absurd.) Hence the wire diffeology is strictly finer than the standard one, although both
contain exactly the same smooth curves.
\end{solution}

\begin{exercise}[label=exo:Dtop-Talpha]{2}
Show that the D-topology of $\Tal\times\Tal$ is indiscrete, and that $\Tal\times\Tal\cong\R^2/(\Lam_\alpha\times\Lam_\alpha)$.
\end{exercise}
\begin{solution}
By \cref{prop:stability}(i), $q_\alpha\times q_\alpha\colon\R^2\to\Tal\times\Tal$ is a subduction. Its fibres are the cosets of
$\Lam_\alpha\times\Lam_\alpha$, so the induced bijection $\R^2/(\Lam_\alpha\times\Lam_\alpha)\to\Tal\times\Tal$ is a subduction that is injective,
hence a diffeomorphism by \cref{prop:stability}(iii). A D-open subset of the quotient has an open preimage in $\R^2$ that is invariant
under the dense subgroup $\Lam_\alpha\times\Lam_\alpha$; a non-empty open invariant set contains a translate of a ball by every element of a dense
subgroup, so it is all of $\R^2$.
\end{solution}

\begin{exercise}[label=exo:cross]{2}
Let $\varphi(t)=e^{-1/t}$ for $t>0$ and $\varphi(t)=0$ for $t\le0$. Show that $c(t)=(\varphi(t),\varphi(-t))$ is a plot of the cross $K$
that does not lift to a plot of $\R\vee\R$. Conclude that $\R\vee\R\to K$ is not a diffeomorphism.
\end{exercise}
\begin{solution}
$c$ is smooth into $\R^2$ and $\varphi(t)\varphi(-t)=0$, so $c$ is a plot of the subspace $K$. A plot of the pushout $\R\vee\R$ is, near
each point, constant or of the form $\iota_j\circ Q$ with $\iota_j$ one of the two inclusions of $\R$ (final diffeology,
\cref{thm:topological}(ii)); so near each point its image lies in one of the two lines. Every neighbourhood of $t=0$ contains points
$t>0$ with $c(t)$ on the first axis minus the origin and points $t<0$ with $c(t)$ on the second axis minus the origin. Hence $c$ is
not a plot of $\R\vee\R$, the bijection $\R\vee\R\to K$ does not pull plots back to plots, and it is not a diffeomorphism.
\end{solution}

\begin{exercise}[label=exo:stability]{3}
Prove \cref{prop:stability}.
\end{exercise}
\begin{solution}
(i) \emph{Composition.} If $f\colon X\to Y$ and $g\colon Y\to Z$ are subductions, a plot of $Z$ lifts locally to $Y$, and that lift lifts
locally to $X$. \emph{Products.} A plot of $Y_1\times Y_2$ is a pair $(P_1,P_2)$ of plots with common domain; near $r$ lift $P_i$ to $Q_i$
on $V_i\ni r$ and take $(Q_1,Q_2)$ on $V_1\cap V_2$. \emph{Pullback.} Let $\pi\colon X\to B$ be a subduction and $f\colon B'\to B$ smooth,
and put $X'=\set{(b',x) : f(b')=\pi(x)}\subseteq B'\times X$ with the subspace diffeology, which is the pullback by
\cref{thm:topological}. The projection $X'\to B'$ is surjective because $\pi$ is. Given a plot $P$ of $B'$, the plot $f\circ P$ of $B$
lifts near $r$ to a plot $Q$ of $X$ with $\pi\circ Q=f\circ P$; then $(P,Q)$ takes values in $X'$, is a plot of $B'\times X$, hence a plot
of $X'$, and lifts $P$.

(ii) \emph{Composition} is immediate from the characterisation ``$P$ is a plot iff $f\circ P$ is''. \emph{Products}: componentwise.
\emph{Pullback}: let $j\colon A\to B$ be an induction and $f\colon B'\to B$ smooth, $A'=\set{(b',a): f(b')=j(a)}$. The projection
$A'\to B'$ is injective since $j$ is. If $P$ is a parametrisation of $A'$ with components $(P_1,P_2)$ such that $P_1$ is a plot of $B'$,
then $j\circ P_2=f\circ P_1$ is a plot of $B$, so $P_2$ is a plot of $A$ because $j$ is an induction, and $P$ is a plot of $A'$.

(iii) A map that is both is bijective; its inverse sends a plot $P$ of the target to a parametrisation whose composite with $f$ is the
plot $P$, hence to a plot, because $f$ is an induction.
\end{solution}

\begin{exercise}[label=exo:ccc]{4}
Prove \cref{thm:ccc}.
\end{exercise}
\begin{solution}
Write $\Phi(f)(x)(y)=f(x,y)$.

\emph{Step 1: a bijection $\cinf(A\times Y,Z)\to\cinf(A,\cinf(Y,Z))$ for every diffeological space $A$.}
Let $f\colon A\times Y\to Z$ be smooth. For fixed $a$ the map $f(a,-)$ is the composite of $f$ with the smooth map $y\mapsto(a,y)$, so
$\Phi(f)(a)\in\cinf(Y,Z)$. To see that $\Phi(f)$ is smooth, let $P\colon U\to A$ be a plot; we must show that
$(r,y)\mapsto f(P(r),y)$ is smooth on $U\times Y$. A plot of $U\times Y$ is a pair $(\rho,Q)$, and
$s\mapsto f(P(\rho(s)),Q(s))$ is $f$ composed with the plot $(P\circ\rho,Q)$ of $A\times Y$. So $\Phi$ is well defined; it is clearly
injective. Conversely let $g\colon A\to\cinf(Y,Z)$ be smooth and put $f(a,y)=g(a)(y)$. For a plot $(P,Q)\colon U\to A\times Y$, the map
$g\circ P$ is a plot of $\cinf(Y,Z)$, that is, $(r,y)\mapsto g(P(r))(y)$ is smooth on $U\times Y$; composing with the plot
$r\mapsto(r,Q(r))$ of $U\times Y$ shows that $r\mapsto f(P(r),Q(r))$ is a plot of $Z$. So $f$ is smooth and $\Phi(f)=g$.

\emph{Step 2: $\Phi$ is a diffeomorphism.} By \cref{rem:yoneda} and \cref{def:functional}, a plot $U\to\cinf(X\times Y,Z)$ is the same
as a smooth map $U\times X\times Y\to Z$. By Step~1 with $A=U\times X$ this is the same as a smooth map $U\times X\to\cinf(Y,Z)$, which by
\cref{def:functional} is the same as a plot $U\to\cinf(X,\cinf(Y,Z))$. The composite identification is $P\mapsto\Phi\circ P$. So $\Phi$
and $\Phi^{-1}$ carry plots to plots.

\emph{Step 3: evaluation and composition.} Evaluation corresponds under $\Phi$ to the identity of $\cinf(Y,Z)$. Composition
$\cinf(X,Y)\times\cinf(Y,Z)\to\cinf(X,Z)$ is smooth if and only if its adjoint
$\cinf(X,Y)\times\cinf(Y,Z)\times X\to Z$, $(f,g,x)\mapsto g(f(x))$, is smooth, and this is two evaluations.
\end{solution}



\chapter{Concrete sheaves}\label{ch:concrete}

\begin{chapabstract}
By axioms \ref{D1}--\ref{D3}, the plots of $X$ form a sheaf on the site of domains, and this sheaf is determined by
its points. We prove the Baez--Hoffnung theorem $\Diff\simeq\ConcSh(\Cart)$, identify concreteness with separatedness for the
adjunction $\Gamma\dashv\coDisc$, construct the concretisation functor, and introduce the first sheaves that are \emph{not}
diffeological spaces: the classifying sheaves of differential forms.
\end{chapabstract}
\source{The axioms of \IZ{art.~1.5}. The dictionary between diffeologies and sheaves is due to Baez and Hoffnung \cite{BaezHoffnung},
building on Dubuc \cite{Dubuc}.}

\section{The site}

Let $\Dom$ be the category of domains and smooth maps, and $\Cart\subset\Dom$ the full subcategory of Cartesian spaces. A family
of open embeddings $\set{U_i\into U}$ is \defn{covering} if it is jointly surjective. This is a coverage on both categories: the
preimage of an open cover under a smooth map is an open cover, and every open subset of $\R^n$ is a union of open balls, each
diffeomorphic to $\R^n$. By the same remark, $\Cart$ is a dense subsite of $\Dom$, so by the comparison lemma
\cite[C2.2.3]{Elephant} restriction is an equivalence
\[
\Sh(\Dom)\;\xrightarrow{\ \simeq\ }\;\Sh(\Cart)=:\SmSet .
\]
Objects of $\SmSet$ are called \defn{smooth sets}. We use $\Cart$ by default because its objects are contractible, which will
matter in \cref{ch:cohesion}; the reader who prefers the plots of \cite{IZ} to be defined on arbitrary domains loses nothing.

Both sites have a terminal object, $\R^0=\ast$, and for every object $U$ the set $\Hom(\ast,U)$ is the underlying set $|U|$.

\section{The Baez--Hoffnung theorem}

\begin{definition}\label{def:concrete-sheaf}
A presheaf $F$ on $\Cart$ (or $\Dom$) is \defn{concrete} if for every $U$ the map
\[
F(U)\longrightarrow\Set\bigl(|U|,F(\ast)\bigr),\qquad s\longmapsto\bigl(u\mapsto u^*s\bigr),
\]
is injective. $\ConcSh(\Cart)\subset\SmSet$ is the full subcategory of concrete sheaves.
\end{definition}

In words: a section over $U$ is determined by the function $|U|\to F(\ast)$ it induces on points. A section of a concrete
sheaf is a function with a property; a section of a general sheaf is a function with extra structure, or no function at all.

\begin{theorem}[Baez--Hoffnung \cite{BaezHoffnung}]\label{thm:BH}
The assignment $X\mapsto\underline X:=\Diff(-,X)$ is an equivalence of categories
\[
\Diff\;\xrightarrow{\ \simeq\ }\;\ConcSh(\Cart),
\]
with inverse $F\mapsto\bigl(F(\ast),\ \text{images of the maps }F(U)\to\Set(|U|,F(\ast))\bigr)$.
\end{theorem}

\begin{proof}
\emph{$\underline X$ is a concrete sheaf.} By \cref{rem:yoneda}, $\underline X(U)$ is the set of plots with source $U$. Axiom
\ref{D3} makes it a presheaf. It is concrete because a plot is a function and $\underline X(\ast)=X$ by \ref{D1}. It is separated
because functions that coincide locally coincide. Given a compatible family of plots $P_i\colon U_i\to X$ on a cover, compatibility on
points of the overlaps means that the $P_i$ glue to a function $P\colon U\to X$, and $P$ is a plot by \ref{D2}.

\emph{From a concrete sheaf to a diffeology.} Let $F$ be a concrete sheaf, $X=F(\ast)$, and let $\mathcal D_U\subseteq\Set(|U|,X)$ be
the image of $F(U)$. \ref{D1}: for $x\in X$, the pullback of $x$ along $U\to\ast$ is a section whose underlying function is constant
at $x$. \ref{D3}: naturality of $F(U)\to\Set(|U|,X)$ in $U$. \ref{D2}: let $P\colon|U|\to X$ restrict to elements of $\mathcal D_{U_i}$ on
a cover. By concreteness there are unique $s_i\in F(U_i)$ with underlying function $P|_{U_i}$. For any $W\to U_i$, $W\to U_j$ with the
same composite to $U$, the two restrictions of $s_i$ and $s_j$ to $W$ have the same underlying function, hence coincide by concreteness.
So the $s_i$ glue to $s\in F(U)$, whose underlying function coincides with $P$ on each $U_i$, hence is $P$.

\emph{Morphisms.} A natural transformation $\varphi\colon F\to G$ of concrete sheaves is determined by $\varphi_\ast\colon F(\ast)\to G(\ast)$,
because the square relating $\varphi_U$ to post-composition with $\varphi_\ast$ commutes and $G(U)\to\Set(|U|,G(\ast))$ is injective; and by the
same square $\varphi_\ast$ carries plots to plots. Conversely a smooth map induces a natural transformation by composition. The
two constructions on objects are mutually inverse by inspection.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzcd}[column sep=3.6em,row sep=2.6em]
\Mfd \arrow[r,hook] & \Diff\simeq\ConcSh(\Cart) \arrow[r,hook,shift right=1.2ex] &
\SmSet=\Sh(\Cart) \arrow[l,shift right=1.2ex,"\conc"'] \arrow[r,hook,shift right=1.2ex] &
\PSh(\Cart) \arrow[l,shift right=1.2ex,"\text{sheafify}"']
\end{tikzcd}
\caption{Three nested categories of ``smooth spaces''. Each hook is full and faithful; the two leftward arrows are left adjoints
(reflections). There is no reflection onto $\Mfd$, which is why manifolds are closed under so few constructions.}\label{fig:tower1}
\end{figure}

\begin{remark}[What each axiom is]
\ref{D3} is functoriality, \ref{D2} is descent, \ref{D1} is a normalisation that makes the value on the point the underlying set. The
only hypothesis of \cref{def:diffeology} with no sheaf-theoretic name is the unstated one: that a plot is a \emph{map of sets}. That is concreteness.
\end{remark}

\section{Concrete sites}

The proof of \cref{thm:BH} used only two properties of the site.

\begin{definition}[\cite{Dubuc,BaezHoffnung}]\label{def:concrete-site}
A \defn{concrete site} is a subcanonical site $\mathcal C$ with a terminal object $\ast$ such that
\textup{(a)} $|\cdot|=\Hom(\ast,-)\colon\mathcal C\to\Set$ is faithful, and
\textup{(b)} covering families are jointly surjective on points.
\end{definition}

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{4.6cm}p{3.6cm}p{5.2cm}@{}}\toprule
concrete site & covers & concrete sheaves\\\midrule
$\Cart$ or $\Dom$, smooth maps & open covers & diffeological spaces \cite{Souriau,IZ}\\
convex subsets of $\R^n$, smooth maps & open covers & Chen spaces \cite{Chen,BaezHoffnung}\\
compact Hausdorff spaces & finite jointly surjective families & quasi-topological spaces \cite{Dubuc}\\
standard Borel spaces & countable Borel covers & quasi-Borel spaces \cite{HKSY}\\\bottomrule
\end{tabular}
\caption{Concrete sites and their concrete sheaves. Dropping concreteness in the first row gives smooth sets; in the third it gives,
up to set-theoretic care, condensed sets. The last row is the semantic basis of higher-order probabilistic programming and reappears in
\cref{ch:ai}.}\label{tab:sites}
\end{table}

Every statement in the rest of this chapter holds for an arbitrary concrete site with the same proof.

\section{Points, codiscrete objects, and separatedness}\label{sec:coDisc}

Let $\Gamma\colon\SmSet\to\Set$ be evaluation at the point, $\Gamma(F)=F(\ast)$. For a set $S$ define a presheaf
\[
\coDisc(S)(U)=\Set(|U|,S).
\]

\begin{lemma}\label{lem:coDisc}
$\coDisc(S)$ is a concrete sheaf --- it is the set $S$ with the coarse diffeology --- and $\Gamma\dashv\coDisc$. The counit
$\Gamma\coDisc(S)\to S$ is a bijection, so $\coDisc$ is full and faithful. A sheaf $F$ is concrete if and only if the unit
\[
\eta_F\colon F\longrightarrow\coDisc\,\Gamma F
\]
is a monomorphism.
\end{lemma}
\noindent The proof is \cref{exo:coDisc}. The last sentence is a restatement of \cref{def:concrete-sheaf}, but it changes what kind of
condition concreteness is. The pair $\Gamma\dashv\coDisc$ exhibits $\Set$ as a subtopos of $\SmSet$ (the inverse image $\Gamma$ preserves
all limits), hence corresponds to a Lawvere--Tierney topology $j$ on $\SmSet$, and an object is \emph{$j$-separated} exactly when the unit
to its $j$-sheafification is monic \cite[A4.4]{Elephant}. So:

\begin{theorem}[Dubuc \cite{Dubuc}; Baez--Hoffnung \cite{BaezHoffnung}; {\cite[A4.4, C2.2.13]{Elephant}}]\label{thm:quasitopos-abstract}
$\Diff$ is the category of separated objects for the Lawvere--Tierney topology on $\SmSet$ whose sheaves are the codiscrete objects.
Consequently $\Diff$ is a Grothendieck quasitopos: it is complete, cocomplete and locally Cartesian closed, it has a classifier for strong
subobjects, and it is a reflective subcategory of $\SmSet$ closed under limits, subobjects, and exponentials $G^F$ with $G$ concrete and
$F$ arbitrary.
\end{theorem}

Each clause is made explicit in terms of plots in \cref{ch:quasitopos}. Here we only construct the reflection.

\section{Concretisation}

\begin{proposition}[Concretisation]\label{prop:conc}
The inclusion $\Diff\into\SmSet$ has a left adjoint
\[
\conc(F)=\im\bigl(\eta_F\colon F\to\coDisc\,\Gamma F\bigr).
\]
Explicitly, $\conc(F)$ is the set $F(\ast)$ with the diffeology whose plots are the functions $|U|\to F(\ast)$ that are \emph{locally}
the underlying function of a section of $F$. The functor $\conc$ preserves finite products and epimorphisms, and $F\to\conc F$ is an epimorphism of sheaves.
\end{proposition}
\noindent The proof is \cref{exo:conc}. Two consequences are used constantly.

\begin{corollary}\label{cor:colimits-conc}
Colimits in $\Diff$ are computed by taking the colimit in $\SmSet$ and concretising. Limits in $\Diff$ are computed in $\SmSet$.
In particular, for a diffeological group $G$ acting on a diffeological space $X$,
\[
X/G\;=\;\conc\bigl(\text{sheaf quotient of }X\text{ by }G\bigr).
\]
\end{corollary}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \node[hcsnodeb] (F) at (0,0) {$F$};
  \node[hcsnode] (C) at (3.4,-1.5) {$\conc F$};
  \node[hcsnode] (S) at (6.8,0) {$\coDisc\,\Gamma F$};
  \draw[->] (F) -- node[above]{$\eta_F$} (S);
  \draw[->>] (F) -- node[below left]{epi} (C);
  \draw[hookr] (C) -- node[below right]{mono} (S);
  \node[font=\footnotesize,align=center,text width=4.6cm] at (0,0.85) {all sections of $F$:\\ ``functions with structure''};
  \node[font=\footnotesize,align=center,text width=4.6cm] at (6.8,0.85) {all functions on points:\\ the coarse diffeology};
  \node[font=\footnotesize,align=center,text width=5.2cm] at (3.4,-2.45) {functions that locally underlie a section};
\end{tikzpicture}
\caption{Concretisation is an image factorisation: two sections have the same image exactly when they have the same values on points.}\label{fig:conc}
\end{figure}

\section{Sheaves that are not spaces}\label{sec:nonconcrete}

The reason to care about $\SmSet\smallsetminus\Diff$ is that it contains the moduli objects of differential geometry.

\begin{example}[Differential forms]\label{ex:Omega}
For $k\ge0$ let $\Om^k(U)$ be the vector space of smooth differential $k$-forms on $U$, with pullback as restriction. This is a sheaf on
$\Cart$. For $k=0$ it is the representable $\underline\R$, hence concrete. For $k\ge1$ we have $\Om^k(\ast)=0$, so
$\Gamma\Om^k$ is a single point while $\Om^k(\R^k)$ is infinite-dimensional: $\Om^k$ is as far from concrete as possible, and
$\conc\,\Om^k=\ast$. The same holds for the subsheaf $\Om^k_{\mathrm{cl}}$ of closed forms.
\end{example}

\begin{example}[A quotient that is not a space]\label{ex:RmodRd}
Let $\Rd$ be the additive group of real numbers with the discrete diffeology, acting on $\R$ by translation. The diffeological quotient
$\R/\Rd$ is a point. The sheaf quotient is not: the exterior derivative $\dd\colon\underline\R\to\Om^1_{\mathrm{cl}}$ is an
epimorphism of sheaves on $\Cart$ by the Poincar\'e lemma, and two functions have the same differential exactly when they differ by a
locally constant function, so
\[
\underline\R\,/\,\Rd\;\cong\;\Om^1_{\mathrm{cl}}\qquad\text{in }\SmSet .
\]
The ``space of real numbers up to a constant'' is the classifying sheaf of closed $1$-forms. Its concretisation is a point.
\end{example}

\begin{example}[An orbit space, before concretisation]\label{ex:Rpm-sheaf}
Let $Q$ be the sheaf quotient of $\R$ by $\{\pm1\}$. With $\varphi$ as in \cref{exo:cross}, the functions $f(x)=\varphi(x)-\varphi(-x)$ and
$g=\abs f$ are both smooth, and $g(x)=\pm f(x)$ for every $x$, so they define the same plot of $\dten_1=\conc Q$. But they are different
sections of $Q$, because near $0$ there is no \emph{locally constant} sign $\varepsilon$ with $g=\varepsilon f$. So $Q$ is not concrete:
in $\dten_1$ two parametrised families of orbits are equal as soon as they coincide pointwise, while in $Q$ equality requires a locally constant sign relating their lifts.
A third object appears in \cref{ch:bundles}: the stack $\R\hquot\{\pm1\}$, in which the stabiliser of $0$ is part of the data.
\end{example}

\begin{remark}[Summary]
A diffeological space is a smooth set with enough points. The classifying objects of geometry typically have too few: a differential
form is not a function on points, and a principal bundle is not even a section of a sheaf of sets. In \cite{IZ} differential forms are obtained by
defining them directly on plots \IZ{art.~6.28}; by \cref{ch:forms} this definition is $\Hom_{\SmSet}(X,\Om^k)$, and
the exactness properties of the theory are those of $\SmSet$.
\end{remark}

\exercisesheading

\begin{exercise}[label=exo:repr]{1}
Show that the representable presheaf $\underline{\R^n}=\Cart(-,\R^n)$ is a concrete sheaf, and identify the diffeological space it corresponds to
under \cref{thm:BH}.
\end{exercise}
\begin{solution}
A smooth map is determined by its values, so $\Cart(U,\R^n)\to\Set(|U|,\R^n)$ is injective. Smoothness is a local condition and smooth maps
that coincide on overlaps glue, so $\underline{\R^n}$ is a sheaf (the site is subcanonical). Its value on $\ast$ is the set $\R^n$ and its
plots are the smooth parametrisations: it is $\R^n$ with the standard diffeology.
\end{solution}

\begin{exercise}[label=exo:Omega1]{2}
Show that $\Hom_{\SmSet}(\Om^1,\underline{\R})=\R$ (constant maps only), while $\Hom_{\SmSet}(\underline\R,\Om^1)\cong\cinf(\R)$.
\end{exercise}
\begin{solution}
Let $\varphi\colon\Om^1\to\underline\R$ be natural. For $\omega\in\Om^1(U)$ and a point $u\colon\ast\to U$ we get
$\varphi_U(\omega)(u)=\varphi_\ast(u^*\omega)=\varphi_\ast(0)$, because $\Om^1(\ast)=0$. So $\varphi_U(\omega)$ is the constant function with value
$c=\varphi_\ast(0)$, for every $\omega$. Conversely each constant is natural. For the second claim, the Yoneda lemma gives
$\Hom(\underline\R,\Om^1)=\Om^1(\R)=\set{a(x)\,\dd x}\cong\cinf(\R)$. So there are many maps from a space to $\Om^1$ and essentially none
from $\Om^1$ to a space: $\Om^1$ is a place one maps \emph{into}.
\end{solution}

\begin{exercise}[label=exo:RmodRd]{2}
Verify the isomorphism $\underline\R/\Rd\cong\Om^1_{\mathrm{cl}}$ of \cref{ex:RmodRd} by checking that
$\dd\colon\underline\R\to\Om^1_{\mathrm{cl}}$ is the coequaliser of the action.
\end{exercise}
\begin{solution}
In a topos every epimorphism is the coequaliser of its kernel pair. \emph{$\dd$ is an epimorphism:} on a Cartesian space every closed $1$-form
is exact, so $\dd_U\colon\cinf(U)\to\Om^1_{\mathrm{cl}}(U)$ is already surjective for every $U\in\Cart$. \emph{Its kernel pair:} sections over
$U$ are pairs $(f,g)$ with $\dd f=\dd g$, that is, $g=f+c$ with $c$ constant, $U$ being connected. That is exactly the image of the map
$\underline\R\times\Rd\to\underline\R\times\underline\R$, $(f,c)\mapsto(f,f+c)$, since sections of the discrete $\Rd$ over a connected $U$ are
constants. So the kernel pair of $\dd$ is the action groupoid, and $\Om^1_{\mathrm{cl}}$ is its quotient.
\end{solution}

\begin{exercise}[label=exo:coDisc]{3}
Prove \cref{lem:coDisc} for an arbitrary concrete site.
\end{exercise}
\begin{solution}
\emph{Sheaf.} Let $R$ be a covering sieve on $D$ and $(s_g)_{g\in R}$ a compatible family, $s_g\in\Set(|E|,S)$ for $g\colon E\to D$. Define
$s\colon|D|\to S$ by $s(d)=s_g(e)$ whenever $g(e)=d$ with $g\in R$; such $(g,e)$ exist by axiom (b). It is well defined: the point
$d\colon\ast\to D$ equals $g\circ e$, which lies in the sieve, and compatibility gives $s_{g\circ e}=e^*s_g=s_g(e)$, an element of
$\Set(|\ast|,S)=S$ depending only on $d$. By construction $g^*s=s_g$, and $s$ is unique because the $g\in R$ are jointly surjective on points.
\emph{Concrete:} $\coDisc(S)(\ast)=S$ and the comparison map is the identity of $\Set(|D|,S)$.

\emph{Adjunction.} Given $\varphi\colon F\to\coDisc S$, naturality with respect to points $d\colon\ast\to D$ forces
$\varphi_D(t)(d)=\varphi_\ast(d^*t)$, so $\varphi$ is determined by $\varphi_\ast\colon F(\ast)\to S$; conversely any function
$F(\ast)\to S$ defines a natural transformation by this formula. Hence $\Hom(F,\coDisc S)\cong\Set(\Gamma F,S)$, naturally. The counit at $S$ is
the identity of $S$. The unit $\eta_F$ at $D$ sends $t$ to $d\mapsto d^*t$, which is the map of \cref{def:concrete-sheaf}; a morphism of sheaves is
monic iff it is injective on every $F(D)$.
\end{solution}

\begin{exercise}[label=exo:conc]{4}
Prove \cref{prop:conc}: the image of $\eta_F$ is a concrete sheaf, $F\mapsto\im\eta_F$ is left adjoint to the inclusion, and it preserves
finite products.
\end{exercise}
\begin{solution}
Write $C=\im\eta_F\subseteq\coDisc\,\Gamma F$, the image in the topos $\SmSet$, so that $F\onto C\into\coDisc\,\Gamma F$.

\emph{$C$ is concrete.} A subsheaf $C$ of a concrete sheaf $G$ is concrete: $C(U)\subseteq G(U)\into\Set(|U|,G(\ast))$, and by naturality the
functions so obtained take values in $C(\ast)$. Here $C(\ast)=F(\ast)$ because evaluation at $\ast$ preserves images and $\eta_F$ is a bijection
on points. Since the image sheaf is the sheafification of the presheaf image, $C(U)$ consists of the functions that are locally underlying
functions of sections of $F$.

\emph{Universal property.} Let $f\colon F\to G$ with $G$ concrete. By naturality of $\eta$,
\[
\eta_G\circ f=\coDisc\Gamma(f)\circ\eta_F .
\]
Let $(a,b)$ be a pair of generalised elements of $F$ with $\eta_Fa=\eta_Fb$. Then $\eta_Gfa=\eta_Gfb$, and $\eta_G$ is monic, so $fa=fb$. Thus
$f$ coequalises the kernel pair of $\eta_F$. In a topos the epimorphism $F\onto C$ is the coequaliser of that kernel pair, so $f$ factors
uniquely through $C$. This is the adjunction $\Hom_{\Diff}(\conc F,G)\cong\Hom_{\SmSet}(F,G)$.

\emph{Finite products.} $\Gamma$ and $\coDisc$ preserve products, so $\eta_{F\times F'}=\eta_F\times\eta_{F'}$. In a topos a product of two
epimorphisms is an epimorphism (pullbacks of epimorphisms are epimorphisms) and a product of monomorphisms is a monomorphism, so
$F\times F'\onto C\times C'\into\coDisc\Gamma F\times\coDisc\Gamma F'$ is the image factorisation of $\eta_{F\times F'}$. Also
$\conc(\ast)=\ast$.

\emph{Epimorphisms.} $\conc$ is a left adjoint, so it preserves epimorphisms as a functor to $\Diff$; and $F\onto\conc F$ is epic in
$\SmSet$ by construction.

\emph{A consequence.} For $G$ concrete and $F$ arbitrary, $G^F$ is concrete: for any sheaf $A$,
$\Hom(A,G^F)\cong\Hom(A\times F,G)\cong\Hom(\conc(A)\times\conc(F),G)$ depends on $A$ only through $\conc A$. So every map
$A\to G^F$ factors uniquely through $A\onto\conc A$; applied to the identity of $A=G^F$ this splits the epimorphism
$G^F\onto\conc(G^F)$, which is therefore an isomorphism.
\end{solution}



\chapter{The quasitopos \texorpdfstring{$\Diff$}{Diff}}\label{ch:quasitopos}

\begin{chapabstract}
We make \cref{thm:quasitopos-abstract} explicit. Inductions and subductions are the strong monomorphisms and strong epimorphisms; every
smooth map has two canonical images; function spaces exist in every slice. We then say precisely what $\Diff$ lacks: equivalence relations
are not effective. That one defect is the reason for the next two enlargements, to smooth sets and to smooth $\infty$-groupoids.
\end{chapabstract}
\source{\IZ{art.~1.29--1.65}: inductions, subductions, strict maps, functional diffeology; \IZ{art.~2.8--2.12} for the D-topology.}

\section{Four classes of maps}

\begin{proposition}\label{prop:monoepi}
In $\Diff$:
\begin{enumerate}[label=\textup{(\roman*)}]
\item the monomorphisms are the injective smooth maps, and the epimorphisms are the surjective smooth maps;
\item the strong monomorphisms are the inductions, and the strong epimorphisms are the subductions.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) Injective maps are monic. Conversely test against maps from the point. Surjective maps are epic. Conversely, if $f\colon X\to Y$ misses
a point $y_0$, the two maps $Y\to\coDisc\{0,1\}$ given by the constant $0$ and the indicator of $y_0$ are smooth (every map into a coarse
space is) and coincide on $f(X)$. (ii) is \cref{exo:strongmono} and its dual.
\end{proof}

Recall that a monomorphism $m$ is \emph{strong} if it is right orthogonal to every epimorphism: in each commutative square with an epimorphism
$e$ on the left and $m$ on the right there is a unique diagonal filler. In a topos every monomorphism is strong. In $\Diff$ the identity map
\[
\R_{\mathrm{disc}}\longrightarrow\R
\]
is monic and epic but not an isomorphism, so $\Diff$ is not balanced and is not a topos. The four classes are drawn in \cref{fig:classes}.

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \draw[hcsteal,fill=hcsmist,line width=0.7pt] (0,0) ellipse (3.3 and 1.75);
  \draw[hcsteal,fill=hcsteal!28,line width=0.7pt] (-1.0,-0.25) ellipse (1.75 and 0.95);
  \node at (0,2.05) {injective smooth maps = monos};
  \node[align=center] at (-1.0,-0.25) {inductions\\= strong monos};
  \node[font=\footnotesize,hcsrust] at (2.05,-0.55) {$\R_{\mathrm{disc}}\!\to\!\R$};
  \fill[hcsrust] (2.05,-0.25) circle (1.5pt);
  \begin{scope}[xshift=7.6cm]
  \draw[hcsgold,fill=hcssand,line width=0.7pt] (0,0) ellipse (3.3 and 1.75);
  \draw[hcsgold,fill=hcsgold!35,line width=0.7pt] (-1.0,-0.25) ellipse (1.75 and 0.95);
  \node at (0,2.05) {surjective smooth maps = epis};
  \node[align=center] at (-1.0,-0.25) {subductions\\= strong epis};
  \node[font=\footnotesize,hcsrust] at (2.05,-0.55) {$\R_{\mathrm{disc}}\!\to\!\R$};
  \fill[hcsrust] (2.05,-0.25) circle (1.5pt);
  \end{scope}
\end{tikzpicture}
\caption{Monomorphisms and epimorphisms in $\Diff$, with their strong subclasses. The marked map lies in both outer regions and in
neither inner one. In a topos the inner and outer regions coincide.}\label{fig:classes}
\end{figure}

\section{Two images}\label{sec:two-images}

\begin{theorem}[Two factorisation systems]\label{thm:factorisations}
Every smooth map $f\colon X\to Y$ factors, uniquely up to unique diffeomorphism, in two ways:
\[
\begin{tikzcd}[column sep=3.2em,row sep=2.2em]
X \arrow[r,two heads,"\text{subduction}"] \arrow[d,two heads,"\text{surjection}"'] & \operatorname{coim}f=X/{\sim_f} \arrow[d,hook,"\text{injection}"] \arrow[dl,"\kappa_f"description]\\
\im f=f(X)_{\Sub} \arrow[r,hook,"\text{induction}"'] & Y
\end{tikzcd}
\]
where $x\sim_f x'$ iff $f(x)=f(x')$, the quotient carries the quotient diffeology and $f(X)_{\Sub}$ the subspace diffeology. The comparison
$\kappa_f$ is a smooth bijection. \textup{(Strong epi, mono)} and \textup{(epi, strong mono)} are orthogonal factorisation systems on $\Diff$, and
both left classes are stable under pullback.
\end{theorem}
\begin{proof}
Existence is the universal property of the quotient and of the subspace (\cref{thm:topological}). Orthogonality of subductions against
injections: given a square $m\circ u=v\circ e$ with $e\colon A\onto B$ a subduction and $m$ injective, the unique set-theoretic filler
$d\colon B\to X$ satisfies $d\circ e=u$, so it is smooth because $e$ is a subduction (final lift). Orthogonality of surjections against inductions
is \cref{exo:strongmono}. Uniqueness follows from orthogonality. Pullback stability of subductions is \cref{prop:stability}; surjections are
pullback stable in $\Set$.
\end{proof}

\begin{definition}[\IZ{art.~1.54}]
A smooth map $f$ is \defn{strict} if $\kappa_f\colon\operatorname{coim}f\to\im f$ is a diffeomorphism.
\end{definition}

In a topos every map is strict. In $\Diff$ strictness is a real condition, and the non-strict maps are where the geometry is
(\cref{tab:strict}). The reader should think of $\operatorname{coim}f$ as ``$X$ with the identifications induced by $f$'' and of $\im f$ as
``the part of $Y$ in the range of $f$''; they have the same points, and $\operatorname{coim} f$ has fewer plots.

\begin{table}[t]\centering\small
\begin{tabular}{@{}llll@{}}\toprule
map $f$ & $\operatorname{coim} f$ & $\im f$ & strict?\\\midrule
$\R\to\R$, $x\mapsto x^2$ & $\dten_1=\R/\{\pm1\}$ & $H=[0,\infty)_{\Sub}$ & no (\cref{prop:delta1})\\
$\R^n\to\R$, $x\mapsto\abs{x}^2$ & $\dten_n=\R^n/\Ort(n)$ & $H$ & no \IZ{Exercise~50}\\
$\R\sqcup\R\to\R^2$, the two axes & $\R\vee\R$ & the cross $K$ & no (\cref{exo:cross})\\
$(0,2\pi)\to\R^2$, figure eight & $(0,2\pi)$ & figure eight$_{\Sub}$ & no (\cref{exo:eight})\\
$\R\to T^2$, $t\mapsto[t,\alpha t]$ & $\R$ & dense leaf$_{\Sub}$ & yes \IZ{Exercise~31}\\
$\R\to\Tal$ & $\Tal$ & $\Tal$ & yes\\\bottomrule
\end{tabular}
\caption{Coimage and image of some smooth maps. In the second row the $\dten_n$ are pairwise non-diffeomorphic \IZ{Exercise~50}, so infinitely many different
coimages have a single image.}\label{tab:strict}
\end{table}

\section{Subobjects and function spaces}

\begin{proposition}[Strong subobject classifier]\label{prop:Omega}
Let $\Om_{\mathrm{st}}=\coDisc\{0,1\}$. For every diffeological space $X$, the map $A\mapsto\chi_A$ is a bijection between subsets
$A\subseteq X$ (equivalently, isomorphism classes of inductions into $X$) and smooth maps $X\to\Om_{\mathrm{st}}$, and
$A_{\Sub}\into X$ is the pullback of $\{1\}\into\Om_{\mathrm{st}}$ along $\chi_A$.
\end{proposition}
\begin{proof}
Every function into a coarse space is smooth, so $\Diff(X,\Om_{\mathrm{st}})=\Set(X,\{0,1\})$. The pullback of $\{1\}\into\Om_{\mathrm{st}}$
along $\chi_A$ is the set $A$ with the initial diffeology for $A\to X$, the map to the point imposing no condition.
\end{proof}

So $\Diff$ classifies the subobjects that carry no information beyond their points, and has no classifier for the others. Function spaces
were treated in \cref{thm:ccc}; under \cref{thm:BH} the functional diffeology is the exponential of sheaves, which is concrete by
\cref{thm:quasitopos-abstract}. The same is true in every slice.

\begin{theorem}[Local Cartesian closure, \cite{BaezHoffnung}]\label{thm:lcc}
For every smooth map $f\colon B'\to B$ the pullback functor $f^*\colon\Diff/B\to\Diff/B'$ has a right adjoint $\Pi_f$, as well as its left
adjoint $\Sigma_f$ given by composition. Consequently $f^*$ preserves all colimits: colimits in $\Diff$ are universal.
\end{theorem}
\noindent An explicit $\Pi_f$ is constructed in \cref{exo:lcc}. ``Colimits are universal'' is the abstract form of
\cref{prop:stability}(i), and it is what makes it legitimate to compute with quotients fibrewise: if $X\to B$ is a quotient map, so is its
restriction over any plot of $B$.

\section{Comparison with topological spaces}

For a topological space $T$ let $C(T)$ be the set $T$ with the \defn{continuous diffeology}, whose plots are the continuous parametrisations.

\begin{proposition}[\cite{ChristensenSinnamonWu}]\label{prop:Dadj}
$D\colon\Diff\to\Top$ is left adjoint to $C\colon\Top\to\Diff$. The adjunction restricts to an equivalence between the diffeological
spaces with $X\cong CD(X)$ and the $\Delta$-generated topological spaces.
\end{proposition}
\noindent The adjunction is \cref{exo:Dadj}. Being a left adjoint, $D$ preserves colimits; it does not preserve finite products in general
\cite{ChristensenSinnamonWu}. The adjunction is far from an equivalence in both directions: $CD(\Tal)$ is coarse, and $DC(T)$ is $T$ with the
$\Delta$-generated refinement of its topology. For the purposes of this monograph the D-topology is a convenience for stating local
conditions, and is never the carrier of homotopical information.

\section{What \texorpdfstring{$\Diff$}{Diff} lacks}\label{sec:lacks}

A quasitopos is a topos except for one exactness property. In $\Diff$ it fails as follows.

\begin{proposition}[Equivalence relations are not effective]\label{prop:noneffective}
Let $R\into X\times X$ be an equivalence relation in $\Diff$, that is, an injective smooth map whose image is an equivalence relation on the set $X$.
The kernel pair of the quotient $X\to X/R$ is the set $R$ with the \emph{subspace} diffeology of $X\times X$. Hence $R$ is the kernel
pair of its quotient if and only if $R\into X\times X$ is an induction.
\end{proposition}
\begin{proof}
The kernel pair is the pullback $X\times_{X/R}X$, which by \cref{thm:topological} is the set of pairs with the same image, with the
subspace diffeology of $X\times X$.
\end{proof}

\begin{example}\label{ex:noneffective}
The orbit relation of $\Rd$ acting on $\R$ is $\R\times\Rd\to\R\times\R$, $(x,c)\mapsto(x,x+c)$. It is injective but not an induction: its
image is all of $\R\times\R$, whose subspace diffeology is the standard one. In $\Diff$ the quotient is a point and the relation is forgotten.
In $\SmSet$ the quotient is $\Om^1_{\mathrm{cl}}$ (\cref{ex:RmodRd}) and the relation is recovered as its kernel pair.
\end{example}

This is the first rung of a ladder (\cref{fig:ladder}). Passing from $\Diff$ to $\SmSet$ makes equivalence relations effective, at the price of
including objects that are not determined by their points. But a group action is an equivalence relation only when it is free, and the next
defect appears immediately: for a non-free action, the action \emph{groupoid} is not the kernel pair of anything in $\SmSet$. Passing to the
$\infty$-topos $\Hh$ of \cref{ch:cohesion} makes all groupoid objects effective, at the price of including objects that are not sets.
\Cref{thm:three-quotients} will make this ladder into a theorem.

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \node[hcsnode,minimum width=3.3cm,minimum height=1.0cm,align=center] (a) at (0,0) {$\Diff$\\[-0.2ex]\footnotesize quasitopos};
  \node[hcsnode,minimum width=3.3cm,minimum height=1.0cm,align=center] (b) at (5,0) {$\SmSet$\\[-0.2ex]\footnotesize topos};
  \node[hcsnode,minimum width=3.3cm,minimum height=1.0cm,align=center] (c) at (10,0) {$\Hh=\Sh_\infty(\Cart)$\\[-0.2ex]\footnotesize $\infty$-topos};
  \draw[hookr] (a)--(b); \draw[hookr] (b)--(c);
  \node[font=\footnotesize,align=center,text width=3.6cm] at (0,-1.25) {effective: quotient maps that are subductions};
  \node[font=\footnotesize,align=center,text width=3.6cm] at (5,-1.25) {effective: all equivalence relations};
  \node[font=\footnotesize,align=center,text width=3.6cm] at (10,-1.25) {effective: all groupoid objects};
  \node[font=\footnotesize,hcsrust] at (2.5,0.75) {free actions};
  \node[font=\footnotesize,hcsrust] at (7.5,0.75) {all actions};
\end{tikzpicture}
\caption{The exactness ladder. Each inclusion makes effective a class of quotients that is not effective in the previous category, and each has a left adjoint
($\conc$, respectively $\pi_0$) that computes the cruder quotient from the finer one.}\label{fig:ladder}
\end{figure}

\exercisesheading

\begin{exercise}[label=exo:notbalanced]{1}
Show directly that $\id\colon\R_{\mathrm{disc}}\to\R$ is a monomorphism and an epimorphism of $\Diff$ but neither an induction nor a subduction.
\end{exercise}
\begin{solution}
It is bijective, hence monic and epic by \cref{prop:monoepi}. It is not an induction: the identity parametrisation of $\R$ composed with it
is a plot of $\R$, but is not locally constant. It is not a subduction: the same plot of $\R$ has no local lift to a locally constant
parametrisation. Equivalently, the inverse map is not smooth.
\end{solution}

\begin{exercise}[label=exo:eight]{2}
Let $j\colon(0,2\pi)\to\R^2$, $j(t)=(\sin t,\sin 2t)$, with image the figure eight $E$. Show that $j$ is an injective immersion that is not an induction.
\end{exercise}
\begin{solution}
$j'(t)=(\cos t,2\cos 2t)$ never vanishes, and $j$ is injective on $(0,2\pi)$: the only parameter with $j(t)=0$ is $t=\pi$, and elsewhere
$(\sin t,\sin 2t)$ determines $(\sin t,\cos t)$. Now let $c(s)=(\sin s,\sin 2s)$ for $\abs s<1$. It is a smooth curve in $\R^2$ with values
in $E$, hence a plot of $E_{\Sub}$. But $j^{-1}\circ c$ equals $s$ for $s>0$, equals $\pi$ at $s=0$, and equals $s+2\pi$ for $s<0$. It is
not continuous, so it is not a plot of $(0,2\pi)$, and $j$ is not an induction. Here $\operatorname{coim}j$ is an open interval and $\im j$ is
the figure eight with both branches through the node available to plots.
\end{solution}

\begin{exercise}[label=exo:strongmono]{3}
Prove that a monomorphism of $\Diff$ is strong if and only if it is an induction.
\end{exercise}
\begin{solution}
($\Leftarrow$) Let $m\colon X\into Y$ be an induction, $e\colon A\to B$ surjective and smooth, and $u\colon A\to X$, $v\colon B\to Y$ smooth
with $m u=v e$. For $b\in B$ choose $a$ with $e(a)=b$ and put $d(b)=u(a)$; this is independent of $a$ because $m$ is injective and
$m(u(a))=v(b)$. Then $d e=u$ and $m d=v$. Since $m\circ d=v$ is smooth and $m$ is an induction, $d$ is smooth. Uniqueness holds since $e$ is epic.

($\Rightarrow$) Let $m\colon X\to Y$ be a strong monomorphism and factor it as $X\xrightarrow{m'}m(X)_{\Sub}\xrightarrow{i}Y$. The map
$m'$ is a smooth bijection, hence an epimorphism. Apply orthogonality to the square $m\circ\id_X=i\circ m'$: there is a smooth
$d\colon m(X)_{\Sub}\to X$ with $d\circ m'=\id_X$. So $m'$ is a diffeomorphism and $m$ is an induction.

The dual statement, that strong epimorphisms are the subductions, is proved in the same way using the factorisation through $X/{\sim_f}$.
\end{solution}

\begin{exercise}[label=exo:Dadj]{3}
Prove that $D\dashv C$: for a diffeological space $X$ and a topological space $T$, a map $f\colon X\to T$ is continuous for the D-topology if
and only if it is smooth as a map $X\to C(T)$.
\end{exercise}
\begin{solution}
$f\colon X\to C(T)$ is smooth iff $f\circ P$ is a continuous parametrisation of $T$ for every plot $P$ of $X$. On the other hand the
D-topology is the final topology for the family of all plots, so $f\colon D(X)\to T$ is continuous iff $f\circ P$ is continuous for every
plot $P$. These are the same condition. Naturality in both variables is clear, so $\Top(D X,T)\cong\Diff(X,C T)$.
\end{solution}

\begin{exercise}[label=exo:mfd-not-ccc]{3}
Show that the category of finite-dimensional manifolds is not Cartesian closed: there is no manifold $E$ with natural bijections
$\Mfd(M\times\R,\R)\cong\Mfd(M,E)$.
\end{exercise}
\begin{solution}
Suppose $E$ exists, of dimension $d$. Taking $M=\ast$ identifies the points of $E$ with $\cinf(\R)$, and by naturality in $M$ a smooth
map $M\to E$ has as underlying function $m\mapsto g(m,-)$ for the corresponding $g\in\cinf(M\times\R)$. Take $M=\R^{k}$ with $k>d$ and
$g(a,t)=\sum_{i<k}a_it^i$. The corresponding smooth map $\psi\colon\R^k\to E$ is injective, because distinct coefficient vectors give
distinct polynomial functions. But a smooth map from $\R^k$ to a manifold of dimension $d<k$ is never injective: on the open set where its
rank is maximal, the constant rank theorem makes it locally a projection with fibres of positive dimension. In $\Diff$ the same universal
property is satisfied by $\cinf(\R,\R)$ with the functional diffeology.
\end{solution}

\begin{exercise}[label=exo:lcc]{4}
Construct the right adjoint $\Pi_f$ of \cref{thm:lcc}.
\end{exercise}
\begin{solution}
Let $f\colon B'\to B$ be smooth and $p\colon E\to B'$ an object of $\Diff/B'$. For $b\in B$ let $F_b=f^{-1}(b)$ with the subspace diffeology, and let
\[
\Pi_fE=\set{(b,s) : b\in B,\ s\colon F_b\to E\ \text{smooth},\ p\circ s=\id_{F_b}}\xrightarrow{\ \pi\ }B .
\]
For a parametrisation $r\mapsto(b_r,s_r)$ of $\Pi_fE$ with domain $U$ and $r\mapsto b_r$ a plot of $B$, write
$U\times_BB'=\set{(r,b') : f(b')=b_r}$, a subspace of $U\times B'$. Declare the parametrisation a plot if $r\mapsto b_r$ is a plot of $B$ and
\[
U\times_BB'\longrightarrow E,\qquad(r,b')\longmapsto s_r(b')
\]
is smooth.

\emph{This is a diffeology.} \ref{D1}: for a constant parametrisation, $U\times_BB'=U\times F_b$ and the map is $s\circ\pr_2$. \ref{D3}: a smooth
$\phi\colon V\to U$ induces a smooth map $V\times_BB'\to U\times_BB'$. \ref{D2}: a plot of $U\times_BB'$ is a pair $(\rho,Q)$, and locally $\rho$
takes values in one member of a given cover of $U$; smoothness is tested on plots, hence locally in $U$.

\emph{The adjunction.} Let $q\colon Z\to B$ be an object of $\Diff/B$; then $f^*Z=Z\times_BB'$. Given $g\colon Z\to\Pi_fE$ over $B$, define
$\hat g(z,b')=g(z)(b')$. For a plot $(\zeta,Q)$ of $Z\times_BB'$, the composite $g\circ\zeta$ is a plot of $\Pi_fE$, so
$(r,b')\mapsto g(\zeta(r))(b')$ is smooth on $U\times_BB'$; precomposing with the plot $r\mapsto(r,Q(r))$ of $U\times_BB'$ shows that
$\hat g\circ(\zeta,Q)$ is a plot of $E$. So $\hat g$ is smooth, and it lies over $B'$. Conversely, given $h\colon Z\times_BB'\to E$ over $B'$, put
$\check h(z)=(q(z),h(z,-))$. Each $h(z,-)$ is a smooth section over $F_{q(z)}$, and for a plot $\zeta$ of $Z$ the map
$(r,b')\mapsto h(\zeta(r),b')$ is the composite of $h$ with the smooth map $\zeta\times\id$ restricted to $U\times_BB'$, so $\check h\circ\zeta$ is a plot.
The two assignments are inverse to each other and natural in $Z$, so $\Hom_{/B}(Z,\Pi_fE)\cong\Hom_{/B'}(f^*Z,E)$.

For $B=\ast$ this is \cref{thm:ccc}: $\Pi_f(B'\times Y\to B')=\cinf(B',Y)$.
\end{solution}


\part{The higher structure}

\chapter{Cohesion}\label{ch:cohesion}

\begin{chapabstract}
The topos of smooth sets carries four adjoint functors to sets --- pieces, discrete, points, codiscrete --- and the same is true one level up,
for the $\infty$-topos $\Hh$ of smooth $\infty$-groupoids and the $\infty$-category of spaces. We set up this structure, locate $\Diff$
inside $\Hh$ as the concrete $0$-types, and state the theorem that computes the leftmost adjoint, the \emph{shape}, by smooth singular simplices.
\end{chapabstract}
\source{\IZ{art.~5.6--5.9} (components) is the only direct contact. The framework is Lawvere's axiomatic cohesion \cite{Lawvere} and
Schreiber's cohesive $\infty$-topos of smooth $\infty$-groupoids \cite{Schreiber}.}

\section{Pieces, discrete, points, codiscrete}

We already have $\Gamma\dashv\coDisc$ from \cref{sec:coDisc}. There are two more adjoints on the left.

\begin{proposition}[Cohesion of smooth sets]\label{prop:cohesion1}
There is a chain of adjunctions
\[
\begin{tikzcd}[column sep=5.5em]
\SmSet \arrow[r,shift left=4.5ex,"\Pi_0"] \arrow[r,shift right=1.5ex,"\Gamma"description]
& \Set \arrow[l,shift right=1.5ex,"\Disc"description] \arrow[l,shift left=4.5ex,"\coDisc"]
\end{tikzcd}
\qquad\Pi_0\dashv\Disc\dashv\Gamma\dashv\coDisc
\]
in which:
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\Disc(S)$ is the constant presheaf, i.e.\ the set $S$ with the discrete diffeology;
\item $\Pi_0(F)=\colim_{U\in\Cart^{\op}}F(U)$, and for a diffeological space $X$ this is the set $\pi_0(X)$ of smooth path components \IZ{art.~5.6};
\item $\Disc$ and $\coDisc$ are full and faithful;
\item $\Pi_0$ preserves finite products;
\item the canonical map $\Gamma F\to\Pi_0F$ is surjective, and $\Disc S\to\coDisc S$ is a monomorphism.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) Let $\{U_i\into U\}$ be a cover of a Cartesian space and $s_i\in S$ a family with $s_i=s_j$ whenever some $W$ maps to both $U_i$ and $U_j$,
that is, whenever $U_i\cap U_j\ne\varnothing$. Since $U$ is connected, any two members of the cover are joined by a chain of members with
non-empty consecutive intersections, so all $s_i$ are equal: the constant presheaf is a sheaf. Its plots are the constant maps on each
Cartesian space, hence the locally constant parametrisations. (ii) $\Hom(F,\Disc S)$ is the set of natural transformations from $F$ to a constant
functor, that is $\Set(\colim F,S)$. For $F=\underline X$ the colimit is the set of plots modulo the relation generated by $P\sim P\circ\phi$; every
plot is equivalent to each of its values, and two points are equivalent iff they are joined by a finite chain of plots with connected domains, iff they are joined by a smooth path.
(iii) $\Gamma\Disc S=S$ and $\Gamma\coDisc S=S$. (iv) $\Cart$ has finite products, so $\Cart^{\op}$ is sifted, and sifted colimits commute
with finite products in $\Set$. (v) An element of the colimit is represented by some $s\in F(U)$, which is equivalent to its restriction to
any point of $U$; and $S\to\Set(|U|,S)$ is injective because $U$ is non-empty.
\end{proof}

Lawvere calls a topos with such a quadruple, satisfying (iii)--(v), \emph{cohesive} \cite{Lawvere}. The names are meant literally: $\Gamma X$
is the set of points of $X$, $\Pi_0X$ is the set of pieces into which the points cohere, and $\Disc$ and $\coDisc$ are the two extreme cohesions on a set. Composing
adjacent functors gives three idempotent operations on $\SmSet$,
\[
\shp_0=\Disc\Pi_0,\qquad\fl=\Disc\,\Gamma,\qquad\shr=\coDisc\,\Gamma,\qquad\shp_0\dashv\fl\dashv\shr ,
\]
and \cref{lem:coDisc} becomes: \emph{a smooth set $X$ is a diffeological space iff $X\to\shr X$ is monic.}

\section{Smooth \texorpdfstring{$\infty$}{infinity}-groupoids}

\begin{definition}\label{def:H}
$\Hh=\Sh_\infty(\Cart)$ is the $\infty$-topos of sheaves of spaces on the site $\Cart$: functors $X\colon\Cart^{\op}\to\Spc$ to the
$\infty$-category of spaces such that for every covering family $\{U_i\into U\}$ the map $X(U)\to\lim_{[k]\in\Delta}\prod X(U_{i_0}\cap\dots\cap U_{i_k})$
(with intersections computed in sheaves) is an equivalence. Its objects are \defn{smooth $\infty$-groupoids}.
\end{definition}

Concretely $\Hh$ is presented by simplicial presheaves on $\Cart$ with the local projective model structure; on this site \v{C}ech descent
and hyperdescent coincide \cite{Schreiber}. The $0$-truncated objects of $\Hh$ are the smooth sets, and the $1$-truncated objects are the stacks
of groupoids on $\Cart$ \cite[\S6.4.5]{HTT}. The truncation functors $\tau_{\le n}$ are left adjoint to the inclusions; we write $\pi_0=\tau_{\le0}$.

\begin{theorem}[Schreiber \cite{Schreiber}]\label{thm:cohesive}
There is a chain of adjoint $\infty$-functors
\[
\Pi\dashv\Disc\dashv\Gamma\dashv\coDisc\colon\ \Hh\rightleftarrows\Spc
\]
with $\Disc$ and $\coDisc$ full and faithful and $\Pi$ preserving finite products. Here $\Disc K$ is the constant presheaf, $\Gamma X=X(\ast)$,
$\coDisc K=(U\mapsto K^{|U|})$, and $\Pi X=\colim_{\Cart^{\op}}X$.
\end{theorem}
\begin{proof}[Sketch]
The key input is that constant presheaves are $\infty$-sheaves on $\Cart$ (\cref{exo:constant-sheaf}); this uses that Cartesian spaces are
contractible and would fail on $\Dom$. Given that, $\Map_{\Hh}(X,\Disc K)$ is the space of maps of presheaves into a constant presheaf, which is
$\Map(\colim X,K)$. $\Cart^{\op}$ is sifted, so $\Pi$ preserves finite products \cite[5.5.8]{HTT}. Evaluation at the point preserves limits
and colimits of sheaves because the point has only the trivial cover; its right adjoint is as stated because $\Map(X,K^{|-|})$ is computed
pointwise in $|U|$. Full faithfulness: $\Gamma\Disc K=K=\Gamma\coDisc K$.
\end{proof}

\begin{definition}
The three \defn{modalities} of $\Hh$ are the idempotent (co)monads
\[
\shp=\Disc\,\Pi\ \ (\text{shape}),\qquad\fl=\Disc\,\Gamma\ \ (\text{flat}),\qquad\shr=\coDisc\,\Gamma\ \ (\text{sharp}),\qquad\shp\dashv\fl\dashv\shr .
\]
For $X\in\Hh$ the space $\Pi X$, or the discrete object $\shp X$, is called the \defn{shape} or \defn{fundamental $\infty$-groupoid} of $X$.
\end{definition}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \node[hcsnode,minimum width=2.6cm] (H) at (0,0) {$\Hh$};
  \node[hcsnode,minimum width=2.6cm] (S1) at (0,-1.5) {smooth stacks};
  \node[hcsnode,minimum width=2.6cm] (S0) at (0,-3.0) {$\SmSet$};
  \node[hcsnodeb,minimum width=2.6cm] (D) at (0,-4.5) {$\Diff$};
  \node[hcsnoder,minimum width=2.6cm] (M) at (0,-6.0) {$\Mfd$};
  \draw[hookr] (S1.north east) to[bend right=30] (H.south east);
  \draw[hookr] (S0.north east) to[bend right=30] (S1.south east);
  \draw[hookr] (D.north east) to[bend right=30] (S0.south east);
  \draw[hookr] (M.north east) to[bend right=30] (D.south east);
  \draw[->] (H.south west) to[bend right=30] node[left]{$\tau_{\le1}$} (S1.north west);
  \draw[->] (S1.south west) to[bend right=30] node[left]{$\pi_0$} (S0.north west);
  \draw[->] (S0.south west) to[bend right=30] node[left]{$\conc$} (D.north west);
  \node[align=left,text width=7.4cm,font=\footnotesize] at (6.4,0) {all smooth $\infty$-groupoids: $\B^nG$, $\shp X$, moduli of bundles with connection};
  \node[align=left,text width=7.4cm,font=\footnotesize] at (6.4,-1.5) {$1$-truncated: $\B G$, orbifolds, $X\hquot G$};
  \node[align=left,text width=7.4cm,font=\footnotesize] at (6.4,-3.0) {$0$-truncated: $\Om^k$, $\Om^k_{\mathrm{cl}}$, sheaf quotients};
  \node[align=left,text width=7.4cm,font=\footnotesize] at (6.4,-4.5) {$0$-truncated and $X\into\shr X$: $\Tal$, $\cinf(X,Y)$, $\Dif(X)$, orbit spaces};
  \node[align=left,text width=7.4cm,font=\footnotesize] at (6.4,-6.0) {locally $\R^n$: no reflection, no quotients, no function spaces};
\end{tikzpicture}
\caption{The position of diffeological spaces. Each hooked arrow is a full embedding; each arrow on the left is its left adjoint. The composite
reflection $\Hh\to\Diff$ is $X\mapsto\conc\,\pi_0X$.}\label{fig:tower}
\end{figure}

\begin{theorem}[$\Diff$ inside $\Hh$]\label{thm:DiffinH}
The composite $\Diff\into\SmSet\into\Hh$ is full and faithful, preserves limits, and has the left adjoint $\conc\circ\pi_0$. Its essential
image consists of the $0$-truncated objects $X$ for which the unit $X\to\shr X$ is a monomorphism.
\end{theorem}
\begin{proof}
The $0$-truncated objects of $\Sh_\infty(\Cart)$ are the sheaves of sets, and the inclusion is right adjoint to $\pi_0$. On $0$-truncated
objects $\shr$ restricts to $\coDisc\,\Gamma$ of \cref{sec:coDisc}, and a map of $0$-truncated objects is a monomorphism in $\Hh$ iff it is one
in $\SmSet$. Now apply \cref{lem:coDisc} and \cref{prop:conc}.
\end{proof}

\section{Reading the modalities}

For $X\in\Hh$ there are canonical maps
\[
\fl X\longrightarrow X\longrightarrow\shr X,\qquad X\longrightarrow\shp X .
\]
Here $\fl X$ consists of the points of $X$ with the discrete cohesion, $\shr X$ of the points with the codiscrete cohesion, and $\shp X$ is the
homotopy type of $X$ as a discrete object. Their values on the running examples are in \cref{tab:modalities}.

\begin{table}[t]\centering\small
\begin{tabular}{@{}lllll@{}}\toprule
$X$ & $\Gamma X$ & $\fl X$ & $\shr X$ & $\Pi X$\\\midrule
$\R^n$ & the set $\R^n$ & $\R^n$ discrete & $\R^n$ coarse & $\ast$\\
manifold $M$ & the set $M$ & $M$ discrete & $M$ coarse & homotopy type of $M$\\
$\Tal$ & $\R/\Lam_\alpha$ & discrete & coarse & $\B\Z^2\simeq T^2$\\
$\dten_1=\R/\{\pm1\}$ & $[0,\infty)$ & discrete & coarse & $\ast$\\
$\Om^k$, $k\ge1$ & $\ast$ & $\ast$ & $\ast$ & $\ast$\\
$\Om^1_{\mathrm{cl}}=\R/\Rd$ & $\ast$ & $\ast$ & $\ast$ & $\B\Rd=K(\R,1)$\\
$\B G$, $G$ a Lie group & $\B(G^\delta)$ & $\B(G^\delta)$ & $\B(\shr G)$ & classifying space $BG$\\\bottomrule
\end{tabular}
\caption{The functors of cohesion on examples. Rows 3 and 6 are justified in \cref{ch:homotopy}; note that the one-point sheaf
$\Om^1_{\mathrm{cl}}$ has a non-trivial shape, while $\Om^k$ is contractible by the homotopy $(\omega,t)\mapsto t\omega$.}\label{tab:modalities}
\end{table}

Two entries are used repeatedly. First, a manifold has the shape of its underlying homotopy type: this is the nerve theorem for a good open
cover, and is the reason for the name ``shape''. Second, $\fl\B G=\Disc\,\B(G^\delta)$: maps $X\to\fl\B G$ are principal bundles for the
discrete group, that is, \emph{flat} $G$-bundles, whence the name of the modality. By adjunction
\begin{equation}\label{eq:flat-adjunction}
\Map_{\Hh}(X,\fl A)\;\simeq\;\Map_{\Spc}(\Pi X,\Gamma A),
\end{equation}
so cohomology with flat (locally constant) coefficients is ordinary cohomology of the shape. This formula does a great deal of work in
Chapters~\ref{ch:forms} and~\ref{ch:number-theory}.

\section{Computing the shape}

For $k\ge0$ let $\Delta^k_e=\set{x\in\R^{k+1} : \sum x_i=1}$ be the \defn{extended simplex}, an affine hyperplane diffeomorphic to $\R^k$. The
$\Delta^k_e$ form a cosimplicial object of $\Cart$.

\begin{figure}[t]
\centering
\begin{tikzpicture}[scale=1.0,font=\small]
  \fill[hcsmist] (-1.6,-0.9) -- (3.4,-0.9) -- (4.4,1.9) -- (-0.6,1.9) -- cycle;
  \draw[hcsteal] (-1.6,-0.9) -- (3.4,-0.9) -- (4.4,1.9) -- (-0.6,1.9) -- cycle;
  \fill[hcsgold!45] (0,0) -- (2.4,0) -- (1.5,1.5) -- cycle;
  \draw[hcsink,line width=0.9pt] (0,0) -- (2.4,0) -- (1.5,1.5) -- cycle;
  \foreach \p/\l/\a in {(0,0)/$e_0$/below left,(2.4,0)/$e_1$/below right,(1.5,1.5)/$e_2$/above}{\fill \p circle (1.6pt); \node[\a] at \p {\l};}
  \node at (1.3,0.5) {$\Delta^2$};
  \node[hcsteal] at (3.4,1.5) {$\Delta^2_e\cong\R^2$};
  \node[align=left,text width=6.0cm,font=\footnotesize] at (8.2,0.6) {A smooth singular simplex of $X$ is a plot $\Delta^k_e\to X$. Using the whole
  affine plane, not the closed triangle, keeps the probes inside $\Cart$ and makes face and degeneracy maps smooth.};
\end{tikzpicture}
\caption{The extended simplex.}\label{fig:extsimplex}
\end{figure}

\begin{theorem}[Berwick-Evans--Boavida de Brito--Pavlov \cite{BBP}; Bunk \cite{Bunk}; Pavlov \cite{Pavlov}]\label{thm:shape}
For every $X\in\Hh$:
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\Pi X\simeq\bigl|[k]\mapsto X(\Delta^k_e)\bigr|$, the geometric realisation of the simplicial space of smooth singular simplices;
\item for every manifold $M$, $\ \Pi\,[M,X]\simeq\Map_{\Spc}(\Pi M,\Pi X)$, where $[M,X]$ is the internal hom of $\Hh$.
\end{enumerate}
\end{theorem}

For a diffeological space $X$, by part (i) $\Pi X$ is the smooth singular simplicial set $S^D(X)_k=\Diff(\Delta^k_e,X)$ of Christensen
and Wu \cite{ChristensenWu}, regarded as a space. Part (ii) is the \emph{smooth Oka principle}: the shape of a mapping space out of a manifold
is the mapping space of shapes. It is a genuinely geometric theorem, since $\Pi$ is a colimit and $[M,-]$ is a limit.

\begin{remark}[Shape versus the D-topology]\label{rem:shape-vs-D}
There are two ways to extract a homotopy type from a diffeological space: the shape $\Pi X$, and the weak homotopy type of the topological space
$D(X)$. They coincide for manifolds and differ in general. For $\Tal$ the second is a point and the first is a torus. The first is the right
one, in the precise sense that it is computed by a left adjoint that preserves finite products and takes quotients by principal actions to
homotopy quotients (\cref{thm:fibre-seq}); the D-topology has none of these properties.
\end{remark}

\exercisesheading

\begin{exercise}[label=exo:four-functors]{1}
Compute $\Gamma$, $\Pi_0$, $\fl$ and $\shr$ for $X=\R\smallsetminus\{0\}$ and describe the maps $\fl X\to X\to\shr X$.
\end{exercise}
\begin{solution}
$\Gamma X$ is the underlying set. $\Pi_0X=\{-,+\}$, the two path components. $\fl X$ is the set $\R\smallsetminus\{0\}$ with the discrete
diffeology and $\fl X\to X$ is the identity on points; it is smooth because locally constant parametrisations are plots, and it is not a
diffeomorphism. $\shr X$ is the same set with the coarse diffeology and $X\to\shr X$ is again the identity on points. Both maps are
bijective, hence monic and epic, and neither is strong (\cref{prop:monoepi}).
\end{solution}

\begin{exercise}[label=exo:Pi0-forms]{2}
Show that $\Pi_0(\Om^k)=\ast$ for every $k$, and that $\Pi_0(X\times Y)=\Pi_0(X)\times\Pi_0(Y)$ for diffeological spaces, directly from the
description by smooth paths.
\end{exercise}
\begin{solution}
An element of $\Pi_0(\Om^k)=\colim_U\Om^k(U)$ is represented by a form $\omega\in\Om^k(U)$. On $U\times\R$ consider $\tilde\omega=t\cdot\pr_U^*\omega$,
with $t$ the coordinate on $\R$. Its restrictions along $u\mapsto(u,1)$ and $u\mapsto(u,0)$ are $\omega$ and $0$, so $\omega\sim\tilde\omega\sim0$ in the
colimit, and $0\in\Om^k(U)$ is the restriction of $0\in\Om^k(\ast)$. Hence there is one element. For products: a smooth path in $X\times Y$ is a
pair of smooth paths, so two points $(x,y)$, $(x',y')$ are joined by a path iff $x,x'$ are and $y,y'$ are; one direction uses the constant path
in one factor together with concatenation of stationary paths (\cref{sec:paths}).
\end{solution}

\begin{exercise}[label=exo:Talpha-modal]{2}
Show that $\Pi_0(\Tal)=\ast$ and that $\Tal\to\shp_0\Tal$, $\fl\Tal\to\Tal$ and $\Tal\to\shr\Tal$ are all non-invertible.
\end{exercise}
\begin{solution}
$q_\alpha\colon\R\to\Tal$ is surjective and $\R$ is path connected, so $\Tal$ is; hence $\shp_0\Tal=\ast$ and the first map collapses $\Tal$ to a
point. $\fl\Tal$ is the uncountable discrete set $\R/\Lam_\alpha$ and $\shr\Tal$ is the same set with the coarse diffeology; by
\cref{prop:Talpha-basic}(ii) the diffeology of $\Tal$ is neither, so the two identity-on-points maps are not diffeomorphisms.
\end{solution}

\begin{exercise}[label=exo:pieces-points]{3}
Let $F$ be a smooth set with $\Gamma F=\ast$. Show that $\Pi_0F=\ast$. Deduce that a non-empty smooth set with one point is connected, and
give an example of one that is not contractible in the sense that its shape is not a point.
\end{exercise}
\begin{solution}
By \cref{prop:cohesion1}(v) the map $\Gamma F\to\Pi_0F$ is surjective, so $\Pi_0F$ has at most one element; it is non-empty because
$\Gamma F$ is. So one-point smooth sets are connected: ``pieces have points''. For the example take $F=\Om^1_{\mathrm{cl}}$. By
\cref{ex:RmodRd} it is the quotient of $\underline\R$ by the free action of the discrete group $\Rd$; such a quotient is the homotopy quotient
(\cref{thm:principal}), $\Pi$ preserves homotopy quotients and finite products, and $\Pi\underline\R=\ast$, so
$\Pi\,\Om^1_{\mathrm{cl}}\simeq\ast\hquot\Rd=\B\Rd$, an Eilenberg--MacLane space $K(\R,1)$ for the discrete group $\R$. Its fundamental group
is uncountable. (Concretely: a path in $\Om^1_{\mathrm{cl}}$ is a $1$-form $a(t)\,\dd t$ on the line; it is automatically a loop, since $\Om^1_{\mathrm{cl}}$ has one point, and its class is $\int_0^1a$.)
\end{solution}

\begin{exercise}[label=exo:constant-sheaf]{4}
Let $K$ be a space. Prove that the constant presheaf with value $K$ satisfies descent for every good open cover of a Cartesian space, and explain
why this fails on $\Dom$.
\end{exercise}
\begin{solution}
Let $\mathcal U=\{U_i\}_{i\in I}$ be a \emph{good} cover of $U\cong\R^n$: every non-empty finite intersection $U_{i_0\dots i_k}$ is diffeomorphic to
$\R^n$. Good covers are cofinal among open covers of $U$ (take geodesically convex balls for a Riemannian metric) and generate the topology of
$\Cart$, so it suffices to verify descent for them. The \v{C}ech nerve of $\mathcal U$ in presheaves has in degree $k$ the coproduct of the
representables $U_{i_0\dots i_k}$ over those $(i_0,\dots,i_k)$ with non-empty intersection. For the constant presheaf $\underline K$ the descent
map is therefore
\[
K=\underline K(U)\longrightarrow\lim_{[k]\in\Delta}\ \prod_{\substack{(i_0,\dots,i_k)\\ U_{i_0\dots i_k}\neq\varnothing}}K\;=\;\Map\bigl(N(\mathcal U),K\bigr),
\]
where $N(\mathcal U)$ is the nerve of the cover, the simplicial set whose $k$-simplices are the $(k+1)$-tuples with non-empty intersection, and the
map is restriction along $N(\mathcal U)\to\ast$. By the nerve theorem (Borsuk, Weil) the realisation of $N(\mathcal U)$ is homotopy equivalent to
$U$, which is contractible. Hence $N(\mathcal U)\to\ast$ is a weak equivalence and the descent map is an equivalence.

On $\Dom$ the first step of the argument is invalid: the value of a sheaf on a disconnected or non-simply-connected domain is forced by descent, and
for $U=\R^2\smallsetminus\{0\}$ the sheafification of the constant presheaf has value $\Map(S^1,K)$, the free loop space, not $K$. The constant
presheaf is a sheaf exactly on a site whose objects are contractible; this is the technical reason for preferring $\Cart$.
\end{solution}



\chapter{Shape}\label{ch:homotopy}

\begin{chapabstract}
The smooth homotopy groups of the book are the homotopy groups of the shape. We explain the comparison, prove that the shape functor
turns diffeological fibre bundles into fibre sequences --- which gives the long exact sequence of \IZ{art.~8.21} for free --- and compute the
shapes of the running examples. The irrational torus is a $K(\Z^2,1)$, the quotient $\R/\Q$ is a rational circle, and none of this is
determined by the D-topology.
\end{chapabstract}
\source{\IZ{Chapter~5} (paths, components, homotopy groups) and \IZ{art.~8.19--8.26} (homotopy of fibre bundles, coverings).}

\section{Paths, loops and homotopy groups}\label{sec:paths}

Following \IZ{art.~5.1}, the space of \defn{paths} of a diffeological space $X$ is $\Paths(X)=\cinf(\R,X)$ with the functional
diffeology; a path $\gamma$ starts at $\gamma(0)$ and ends at $\gamma(1)$. Defining paths on all of $\R$ keeps the source a domain. The price is
that two paths with $\gamma(1)=\gamma'(0)$ cannot be concatenated naively; the remedy is to reparametrise by a \defn{smashing function}, a
smooth non-decreasing $\lambda\colon\R\to[0,1]$ equal to $0$ near $(-\infty,0]$ and to $1$ near $[1,\infty)$ (\cref{fig:smashing}). The path
$\gamma\circ\lambda$ is \defn{stationary} near its ends, is homotopic to $\gamma$ with fixed ends, and stationary paths concatenate smoothly
\IZ{art.~5.2--5.5}.

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \draw[->,hcsgrey] (-0.8,0)--(4.6,0) node[right,hcsink]{$t$};
  \draw[->,hcsgrey] (0,-0.3)--(0,2.2);
  \draw[hcsgrey,dashed] (-0.8,1.6)--(4.6,1.6);
  \draw[hcsteal,line width=1.1pt] (-0.8,0)--(0.5,0) .. controls (1.6,0) and (1.6,1.6) .. (2.7,1.6)--(4.6,1.6);
  \node[below] at (0,-0.3) {$0$}; \node[below] at (3.2,0) {$1$}; \draw (3.2,-0.06)--(3.2,0.06);
  \node[left] at (0,1.6) {$1$};
  \node[hcsteal] at (2.2,0.6) {$\lambda$};
 \end{scope}
 \begin{scope}[xshift=6.6cm,yshift=0.2cm]
  \draw[hcsteal,line width=1pt] plot[smooth] coordinates {(0,0) (0.8,0.9) (1.8,0.7) (2.4,1.5)};
  \draw[hcsrust,line width=1pt] plot[smooth] coordinates {(2.4,1.5) (3.2,1.9) (4.0,1.0) (4.9,1.3)};
  \fill (0,0) circle (1.5pt) node[left]{$\gamma(0)$};
  \fill (2.4,1.5) circle (1.8pt) node[above left]{$\gamma(1)=\gamma'(0)$};
  \fill (4.9,1.3) circle (1.5pt) node[right]{$\gamma'(1)$};
  \node[font=\footnotesize,align=center] at (3.2,-0.35) {both paths are stationary near the junction,\\ so the concatenation is smooth};
 \end{scope}
\end{tikzpicture}
\caption{A smashing function, and the concatenation of two stationary paths.}\label{fig:smashing}
\end{figure}

Being joined by a path is then an equivalence relation, with quotient $\pi_0(X)$. For a base point $x$ let
$\Loops(X,x)=\set{\ell\in\Paths(X) : \ell(0)=\ell(1)=x}$ with the subspace diffeology and base point the constant loop $\hat x$. The
higher homotopy groups are defined by recursion \IZ{art.~5.15--5.17}:
\[
\pi_n(X,x)=\pi_{n-1}\bigl(\Loops(X,x),\hat x\bigr)=\pi_0\bigl(\Loops^n(X,x)\bigr).
\]
Unwinding with \cref{thm:ccc}, an element of $\pi_n(X,x)$ is represented by a smooth map $\sigma\colon\R^n\to X$ with $\sigma(t)=x$ whenever some
coordinate $t_i$ lies in $\{0,1\}$, and two such are identified when they are joined by a smooth one-parameter family of the same kind.
A \defn{smooth homotopy} between $f,g\colon X\to Y$ is a path in $\cinf(X,Y)$, equivalently a smooth $H\colon X\times\R\to Y$ with $H_0=f$,
$H_1=g$. A space is \defn{smoothly contractible} if its identity is homotopic to a constant.

\section{Homotopy groups of the shape}

\begin{proposition}[$\Pi$ inverts smooth homotopy]\label{prop:Pi-homotopy}
If $f,g\colon X\to Y$ are smoothly homotopic maps of smooth $\infty$-groupoids, then $\Pi f\simeq\Pi g$. In particular smooth homotopy
equivalences induce equivalences of shapes, and a smoothly contractible object has contractible shape.
\end{proposition}
\begin{proof}
Let $H\colon X\times\R\to Y$ be the homotopy and $i_0,i_1\colon X\to X\times\R$ the inclusions at $0$ and $1$. Since $\Pi$ preserves finite
products and $\Pi(\R)=\ast$, the projection $X\times\R\to X$ induces an equivalence on shapes. Both $i_0$ and $i_1$ are sections of it, so
$\Pi i_0\simeq\Pi i_1$, and $\Pi f=\Pi H\circ\Pi i_0\simeq\Pi H\circ\Pi i_1=\Pi g$.
\end{proof}

\begin{theorem}[Christensen--Wu \cite{ChristensenWu}; Kihara \cite{KiharaSing}]\label{thm:pin}
For every diffeological space $X$, every $x\in X$ and every $n\ge0$ there is a natural isomorphism
\[
\pi_n(\Pi X,x)\;\cong\;\pi_n(X,x)
\]
between the homotopy groups of the shape and the smooth homotopy groups of \IZ{art.~5.17}.
\end{theorem}

By \cref{thm:shape}(i) the left-hand side is $\pi_n$ of the smooth singular simplicial set $S^D(X)=\Diff(\Delta^\bullet_e,X)$. For $n=0$
the statement is \cref{prop:cohesion1}(ii). Christensen and Wu proved it for those $X$ whose $S^D(X)$ is a Kan complex, a class that contains
all diffeological groups and homogeneous spaces; Kihara removed the hypothesis. The content is that horn fillers, which need not exist smoothly,
exist after reparametrising by smashing functions --- the same device as in \cref{fig:smashing}, one dimension at a time.

\begin{remark}[Why not a model structure on $\Diff$?]
One would like to say that $\Diff$ ``is a model for homotopy theory''. The obvious attempt, transferring the Kan--Quillen model structure along
$S^D$, fails \cite{Pavlov}; Kihara's model structure \cite{KiharaModel} uses simplices with a non-standard diffeology. From the present point of view
nothing is lost: the homotopy theory is that of $\Hh$, the functor $\Pi$ is defined on all of $\Hh$, and $\Diff$ is the full subcategory on which
$\Pi$ is computable by smooth paths.
\end{remark}

\section{Fibre sequences}

A \defn{diffeological fibre bundle} is a smooth surjection $\pi\colon T\to B$ whose pullback along every plot of $B$ is locally trivial with a
fixed fibre $F$ \IZ{art.~8.9}. This is weaker than local triviality over D-open sets, and it has to be: $T^2\to\Tal$ is a fibre bundle with fibre
$\R$ over a base whose only D-open sets are $\varnothing$ and $\Tal$. Principal bundles are treated in \cref{ch:bundles}; we use two facts from there.
First, a principal $G$-bundle $P\to B$ satisfies $B\simeq P\hquot G$ in $\Hh$ (\cref{thm:principal}). Second, every diffeological fibre bundle with
fibre $F$ is associated to a principal $\Dif(F)$-bundle \IZ{art.~8.14, 8.16}.

\begin{theorem}[Shape preserves bundle fibre sequences]\label{thm:fibre-seq}
Let $F\to T\xrightarrow{\pi}B$ be a diffeological fibre bundle. Then
\[
\Pi F\longrightarrow\Pi T\longrightarrow\Pi B
\]
is a fibre sequence of spaces. Consequently there is a long exact sequence
\[
\cdots\to\pi_n(F)\to\pi_n(T)\to\pi_n(B)\to\pi_{n-1}(F)\to\cdots\to\pi_0(T)\to\pi_0(B)\to\ast ,
\]
which by \cref{thm:pin} is the exact homotopy sequence of \IZ{art.~8.21}.
\end{theorem}
\begin{proof}
\emph{Principal case.} Let $P\to B$ be principal with group $G$. Then in $\Hh$
\[
B\simeq P\hquot G=\colim_{[k]\in\Delta^{\op}}P\times G^k,\qquad\text{hence}\qquad\Pi B\simeq\colim_{[k]\in\Delta^{\op}}\Pi P\times(\Pi G)^k=\Pi P\hquot\Pi G,
\]
because $\Pi$ preserves colimits, being a left adjoint, and finite products. The right-hand side is the homotopy quotient of the space $\Pi P$ by the group-like space $\Pi G$. In $\Spc$, as in any $\infty$-topos, the map from an object to its
homotopy quotient by a group is a principal bundle with fibre the group \cite{NSS}; so $\Pi G\to\Pi P\to\Pi B$ is a fibre sequence.

\emph{General case.} Write $T\cong P\times_GF=(P\times F)/G$ with $G=\Dif(F)$ and $P\to B$ principal. The diagonal action on $P\times F$ is again
principal: if $r\mapsto((p_r,f_r),(p_rg_r,g_r^{-1}f_r))$ is a plot of $(P\times F)^2$, then $r\mapsto g_r$ is a plot of $G$ because it is already
determined smoothly by $(p_r,p_rg_r)$ and the action on $P$ is principal. Hence $T\simeq(P\times F)\hquot G$ and
$\Pi T\simeq(\Pi P\times\Pi F)\hquot\Pi G$. The map to $\Pi B\simeq\Pi P\hquot\Pi G$ is induced by the projection, and its pullback along
$\Pi P\to\Pi P\hquot\Pi G$ is $\Pi P\times\Pi F\to\Pi P$, since colimits are universal in $\Spc$. So its fibre is $\Pi F$.
\end{proof}

The proof uses nothing about paths. In \cite{IZ} the exact sequence is proved by constructing, for every fibre bundle, an associated bundle of loop
spaces \IZ{art.~8.20}; here the sequence is a formal consequence of two properties of the left adjoint $\Pi$ and one geometric input, the
identification of quotients by principal actions with homotopy quotients.

\section{Shapes of the running examples}

\begin{corollary}[Quotients of $\R^n$ by countable subgroups]\label{cor:TGamma}
Let $\Gamma\subset\R^n$ be a countable subgroup and $T_\Gamma=\R^n/\Gamma$. Then $\R^n\to T_\Gamma$ is a principal $\Gamma$-bundle with $\Gamma$
discrete, and
\[
\Pi\,T_\Gamma\simeq\B\Gamma=K(\Gamma,1).
\]
In particular $\Pi\,\Tal\simeq\B\Z^2\simeq T^2$, and $\Pi(\R/\Q)\simeq K(\Q,1)$.
\end{corollary}
\begin{proof}
A plot of $\R^n$ with values in the countable set $\Gamma$ is locally constant, so $\Gamma$ is discrete as a subspace. The action map
$\R^n\times\Gamma\to\R^n\times\R^n$, $(x,\gamma)\mapsto(x,x+\gamma)$, is an induction: if $r\mapsto(x_r,y_r)$ is a plot with $y_r-x_r\in\Gamma$,
then $r\mapsto y_r-x_r$ is smooth with countable image, hence locally constant, hence a plot of $\Gamma$. So the action is principal
(\cref{def:principal}), and \cref{thm:fibre-seq} gives $\Pi T_\Gamma\simeq\Pi\R^n\hquot\Gamma=\ast\hquot\Gamma$.
\end{proof}

So the irrational torus has the homotopy type of the ordinary $2$-torus, in accordance with its name and in contrast with its D-topology. Each of two
fibre bundles over it gives the computation (\cref{fig:two-fibrations}): the universal covering $\R\to\Tal$ with discrete fibre $\Z^2$, and the
Kronecker fibration $T^2\to\Tal$ with contractible fibre $\R$. Iglesias-Zemmour recounts in the afterword of \cite{IZ} that reconciling these two
computations is what led to the definition of diffeological fibre bundles. The space $\R/\Q$ is a one-dimensional diffeological group whose shape
is the rationalisation of the circle.

\begin{figure}[t]
\centering
\begin{tikzcd}[column sep=3.4em,row sep=2.0em]
\Lam_\alpha\cong\Z^2 \arrow[r] & \R \arrow[r,two heads,"q_\alpha"] & \Tal & & \Z^2 \arrow[r] & \ast \arrow[r] & \B\Z^2\\
\R \arrow[r] & T^2 \arrow[r,two heads] & \Tal & & \ast \arrow[r] & T^2 \arrow[r,"\simeq"] & \B\Z^2
\arrow[from=1-3,to=1-5,phantom,"\overset{\Pi}{\longmapsto}"]
\arrow[from=2-3,to=2-5,phantom,"\overset{\Pi}{\longmapsto}"]
\end{tikzcd}
\caption{Two diffeological fibre bundles over the irrational torus and the fibre sequences of shapes they induce. Each gives
$\Pi\Tal\simeq\B\Z^2$.}\label{fig:two-fibrations}
\end{figure}

\begin{table}[t]\centering\small
\begin{tabular}{@{}llll@{}}\toprule
$X$ & $\Pi X$ & reason & D-topology\\\midrule
$\Tal$ & $\B\Z^2$ & \cref{cor:TGamma} & indiscrete\\
$\R/\Q$ & $K(\Q,1)$ & \cref{cor:TGamma} & indiscrete\\
$\dten_n=\R^n/\Ort(n)$ & $\ast$ & radial contraction (\cref{exo:contractible}) & half-line\\
$\R^n\hquot\Ort(n)$ (stack) & $B\Ort(n)$ & $\Pi$ preserves homotopy quotients & ---\\
the cross $K$ & $\ast$ & radial contraction & cross\\
any non-empty coarse space & $\ast$ & \cref{exo:contractible} & indiscrete\\
$\Om^1_{\mathrm{cl}}$ & $K(\R,1)$ & \cref{exo:pieces-points} & ---\\
$S^\infty$ \IZ{art.~4.9} & $\ast$ & contractible \IZ{art.~4.10} & \\
$\C P^\infty=S^\infty/U(1)$ \IZ{art.~4.11} & $K(\Z,2)$ & \cref{thm:fibre-seq} & \\\bottomrule
\end{tabular}
\caption{Some shapes. The difference between the third and fourth rows is the difference between a quotient and a homotopy quotient; the first two show that an
indiscrete D-topology is compatible with any $K(\Gamma,1)$ for countable torsion-free abelian $\Gamma\subset\R^n$.}\label{tab:shapes}
\end{table}

\section{Coverings}

A \defn{covering} is a diffeological fibre bundle with discrete fibre \IZ{art.~8.22}. For connected $X$ there is a \emph{universal}
covering $\tilde X\to X$, simply connected and unique up to isomorphism, which is a principal bundle with structure group $\pi_1(X)$
\IZ{art.~8.26}. In $\Hh$ this becomes
\[
X\;\simeq\;\tilde X\hquot\pi_1(X),\qquad\text{classified by}\qquad X\longrightarrow\B\pi_1(X)=\tau_{\le1}\shp X ,
\]
and $\tilde X$ is the homotopy fibre of the $1$-truncation of the shape unit. The monodromy theorem \IZ{art.~8.25}, that a smooth map from a
simply connected space lifts through any covering, is the corresponding lifting property. For $X=\Tal$ the universal covering is $\R$, and for
$X=T_\Gamma$ it is $\R^n$.

\exercisesheading

\begin{exercise}[label=exo:smash]{1}
Construct a smashing function, and show that if $\gamma,\gamma'$ are paths with $\gamma(1)=\gamma'(0)$, both stationary near their ends, then the
concatenation $\gamma\vee\gamma'$, equal to $\gamma(2t)$ for $t\le\tfrac12$ and to $\gamma'(2t-1)$ for $t\ge\tfrac12$, is a smooth path.
\end{exercise}
\begin{solution}
Let $\varphi(t)=e^{-1/t}$ for $t>0$ and $0$ otherwise, and put $\psi(t)=\varphi(t)/(\varphi(t)+\varphi(1-t))$. The denominator never vanishes, so
$\psi$ is smooth, non-decreasing, $0$ on $(-\infty,0]$ and $1$ on $[1,\infty)$. Then $\lambda(t)=\psi(3t-1)$ is $0$ on $(-\infty,\tfrac13]$ and $1$ on
$[\tfrac23,\infty)$. For the concatenation: there is $\varepsilon>0$ with $\gamma$ constant on $(1-\varepsilon,\infty)$ and $\gamma'$ constant on
$(-\infty,\varepsilon)$. On $t<\tfrac12+\tfrac\varepsilon2$ the map $\gamma\vee\gamma'$ coincides with $t\mapsto\gamma(2t)$, and on
$t>\tfrac12-\tfrac\varepsilon2$ with $t\mapsto\gamma'(2t-1)$; both are plots, they coincide on the overlap where they are constant at $\gamma(1)$, and
\ref{D2} applies. By the same argument with parameters, concatenation is smooth as a map from the space of composable pairs of
stationary paths to $\Paths(X)$.
\end{solution}

\begin{exercise}[label=exo:contractible]{2}
Show that $\dten_n=\R^n/\Ort(n)$ and every non-empty coarse space are smoothly contractible.
\end{exercise}
\begin{solution}
Let $\lambda$ be a smashing function and $h\colon\R^n\times\R\to\R^n$, $h(x,t)=(1-\lambda(t))x$. It is smooth, $h_0=\id$, $h_1=0$, and each $h_t$
is $\Ort(n)$-equivariant. So $\pi\circ h$ is constant on the fibres of the subduction $\pi\times\id\colon\R^n\times\R\to\dten_n\times\R$
(\cref{prop:stability}) and descends to a smooth $\bar h\colon\dten_n\times\R\to\dten_n$ from the identity to a constant. For a coarse space
$X$ with a point $x_0$, the map $H(x,t)=x$ for $t<\tfrac12$ and $H(x,t)=x_0$ for $t\ge\tfrac12$ is smooth, since every map into a coarse space
is. By \cref{prop:Pi-homotopy} both have contractible shape.
\end{solution}

\begin{exercise}[label=exo:pi1-Talpha]{2}
Compute $\pi_1(\Tal,0)$ directly from the definition, by lifting loops to $\R$.
\end{exercise}
\begin{solution}
Let $\ell$ be a loop at $0=q_\alpha(0)$. It is a plot, so it lifts locally through $q_\alpha$, and two local lifts differ by a locally constant
element of $\Lam_\alpha$ (\cref{prop:Talpha-basic}). Covering $\R$ by intervals on which lifts exist and correcting successive lifts by constants,
we get a unique smooth $\tilde\ell\colon\R\to\R$ with $q_\alpha\tilde\ell=\ell$ and $\tilde\ell(0)=0$. Put $w(\ell)=\tilde\ell(1)\in\Lam_\alpha$. A
homotopy of loops is a plot $h\colon\R^2\to\Tal$ with $h(s,0)=h(s,1)=0$; by the same argument on the simply connected domain $\R^2$ it lifts to
$\tilde h$ with $\tilde h(s,0)=0$, and $s\mapsto\tilde h(s,1)$ is a continuous map into $\Lam_\alpha$, hence constant. So $w$ is well defined on
$\pi_1$. It is a homomorphism because the lift of a concatenation is the lift of the first loop followed by the translate of the lift of the second.
It is surjective: $t\mapsto q_\alpha(t\mu)$ is a loop with $w=\mu$. It is injective: if $w(\ell)=0$ then $\tilde\ell$ is a loop in $\R$ at $0$, and
$(s,t)\mapsto q_\alpha(s\tilde\ell(t))$ contracts $\ell$. Hence $\pi_1(\Tal,0)\cong\Lam_\alpha\cong\Z^2$.
\end{solution}

\begin{exercise}[label=exo:RmodQ]{3}
Show that $\R/\Q$ is a diffeological $\Q$-vector space with $\pi_1(\R/\Q)\cong\Q$ and all higher homotopy groups zero, and that every smooth map
$\R/\Q\to\R/\Q$ fixing $0$ is multiplication by a rational number.
\end{exercise}
\begin{solution}
$\Q$ is a countable subgroup, so by \cref{cor:TGamma} $\R\to\R/\Q$ is a principal $\Q$-bundle with $\Q$ discrete and $\Pi(\R/\Q)\simeq K(\Q,1)$;
now apply \cref{thm:pin}. Multiplication by $a\in\Q$ on $\R$ preserves $\Q$, so it descends to a smooth map on the quotient, and this makes
$\R/\Q$ a $\Q$-vector space with smooth operations. Let $f$ be smooth with $f(0)=0$. As in \cref{exo:pi1-Talpha} the plot $f\circ q$ lifts to a
smooth $F\colon\R\to\R$ with $F(0)=0$ and $F(x+a)-F(x)\in\Q$ for $a\in\Q$. For fixed $a$ the left side is continuous in $x$ with values in a
countable set, hence a constant $\phi(a)$. Differentiating, $F'(x+a)=F'(x)$ for all $a\in\Q$, so the continuous function $F'$ is constant on a
dense set, hence constant: $F(x)=cx$. Finally $c=F(1)-F(0)=\phi(1)\in\Q$.
\end{solution}

\begin{exercise}[label=exo:CPinfty]{3}
Assuming that $S^\infty$ is contractible and that $S^\infty\to\C P^\infty$ is a principal $U(1)$-bundle \IZ{art.~4.10--4.11, 8.11}, compute
$\Pi\,\C P^\infty$. Do the same for $\Tal$ using the bundle $T^2\to\Tal$.
\end{exercise}
\begin{solution}
By \cref{thm:fibre-seq}, $\Pi U(1)\to\Pi S^\infty\to\Pi\C P^\infty$ is a fibre sequence with contractible total space, so
$\Omega\,\Pi\C P^\infty\simeq\Pi U(1)\simeq S^1=K(\Z,1)$. $\C P^\infty$ is connected, hence $\Pi\C P^\infty\simeq K(\Z,2)$. For $\Tal$: the fibre $\R$
has contractible shape, so $\Pi T^2\to\Pi\Tal$ has contractible fibres over a connected base and is an equivalence;
$\Pi T^2\simeq T^2\simeq\B\Z^2$ because $T^2$ is a manifold. This is consistent with \cref{cor:TGamma}.
\end{solution}

\begin{exercise}[label=exo:higher-TGamma]{4}
Let $\Gamma\subset\R^n$ be a countable subgroup. Prove directly from the definition of the smooth homotopy groups, without \cref{thm:pin} or
\cref{thm:fibre-seq}, that $\pi_k(T_\Gamma,0)=0$ for all $k\ge2$.
\end{exercise}
\begin{solution}
Let $q\colon\R^n\to T_\Gamma$ be the projection and $B_k=\set{t\in\R^k : t_i\in\{0,1\}\text{ for some }i}$. A class in $\pi_k(T_\Gamma,0)$ is
represented by a smooth $\sigma\colon\R^k\to T_\Gamma$ with $\sigma(B_k)=\{0\}$, and two representatives define the same class when they are joined
by a smooth family $\sigma_s$, $s\in\R$, of such maps.

\emph{Lifting.} $\sigma$ is a plot, so every point of $\R^k$ has a neighbourhood on which $\sigma$ lifts through $q$, and two lifts on a
connected open set differ by a constant in $\Gamma$, because their difference is continuous with values in a countable subset of $\R^n$. The
local lifts therefore form a principal $\Gamma$-covering of $\R^k$ in the classical sense; it is trivial because $\R^k$ is simply connected. So there
is a global smooth lift $\tilde\sigma\colon\R^k\to\R^n$ with $q\tilde\sigma=\sigma$, unique up to adding a constant of $\Gamma$.

\emph{Boundary values.} $\tilde\sigma$ maps $B_k$ into $q^{-1}(0)=\Gamma$. For $k\ge2$ the set $B_k$ is connected: it is a union of hyperplanes
$\{t_i=c\}$, $c\in\{0,1\}$, any two of which with different $i$ intersect, and for $k\ge2$ any two of them are linked through a third.
A continuous map from a connected set to a countable subset of $\R^n$ is constant, so after subtracting a constant, $\tilde\sigma|_{B_k}=0$.

\emph{Contraction.} Put $\sigma_s=q\circ(s\,\tilde\sigma)$ for $s\in\R$. Then $(s,t)\mapsto\sigma_s(t)$ is smooth, each $\sigma_s$ sends $B_k$ to
$0$, $\sigma_1=\sigma$ and $\sigma_0$ is constant. Hence $[\sigma]=0$.

For $k=1$ the argument is not available: $B_1=\{0,1\}$ is disconnected, $\tilde\sigma(1)-\tilde\sigma(0)\in\Gamma$ is the obstruction,
and one recovers $\pi_1(T_\Gamma)\cong\Gamma$ as in \cref{exo:pi1-Talpha}.
\end{solution}



\chapter{Forms}\label{ch:forms}

\begin{chapabstract}
A differential form on a diffeological space is a map into a classifying sheaf that is not itself a diffeological space. From this one
definition we recover the Cartan--de~Rham calculus of the book, a two-line proof that forms descend along subductions, and a spectral sequence
that measures the failure of de~Rham's theorem. On the irrational torus its $E_2$ page is the K\"unneth decomposition of the cohomology of
$S^1\times S^1$, with the cohomology of one circle represented by forms and that of the other by bundles.
\end{chapabstract}
\source{\IZ{Chapter~6}, especially art.~6.28--6.39 and 6.73--6.90; \IZ{art.~8.28--8.31, 8.40--8.42} for periods and integration bundles.}

\section{Forms are maps into \texorpdfstring{$\Om^k$}{Omega k}}

\begin{definition}[\IZ{art.~6.28}]\label{def:form}
A \defn{differential $k$-form} on a diffeological space $X$ is a rule $\alpha$ assigning to each plot $P\colon U\to X$ a smooth form
$\alpha(P)\in\Om^k(U)$, such that $\alpha(P\circ F)=F^*\alpha(P)$ for every smooth $F\colon V\to U$. The vector space of such is $\Om^k(X)$.
\end{definition}

\begin{proposition}\label{prop:forms-yoneda}
$\Om^k(X)=\Hom_{\SmSet}(\underline X,\Om^k)$, naturally in $X$. For a manifold this is the usual space of $k$-forms.
\end{proposition}
\begin{proof}
A natural transformation $\underline X\to\Om^k$ is a family of maps $\underline X(U)\to\Om^k(U)$, natural in $U$; that is
\cref{def:form}, word for word. If $X=M$ is a manifold, a form $\omega$ on $M$ gives $P\mapsto P^*\omega$; conversely the values of $\alpha$ on
the inverses of charts glue to a form on $M$ by the compatibility condition, and determine $\alpha$ because every plot factors locally through charts.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzcd}[column sep=3.2em,row sep=2.2em]
V \arrow[r,"F"] \arrow[rr,bend left=32,"P\circ F"] \arrow[drr,bend right=18,"F^*\alpha(P)"'] & U \arrow[r,"P"] \arrow[dr,"\alpha(P)"description] & X \arrow[d,"\alpha"]\\
 & & \Om^k
\end{tikzcd}
\caption{A $k$-form on $X$ is a map $\alpha\colon X\to\Om^k$ of smooth sets. By the Yoneda lemma, a map $U\to\Om^k$ from a Cartesian space is
an ordinary $k$-form on $U$, and the compatibility condition of \cref{def:form} is the commutativity of the outer triangle.}\label{fig:form}
\end{figure}

Everything natural on Cartesian spaces therefore extends to all smooth sets by post-composition. The exterior derivative is a map of sheaves
$\dd\colon\Om^k\to\Om^{k+1}$ with $\dd\circ\dd=0$; the wedge product is a map $\Om^k\times\Om^l\to\Om^{k+l}$; pullback along $f\colon X\to Y$ is
pre-composition. The identities of the Cartan calculus hold on $X$ because they hold in the target. This is how
\IZ{art.~6.32--6.35} proceed, plot by plot.

\begin{remark}[The space of forms]
The internal hom $[X,\Om^k]$ of $\SmSet$ has $\Om^k(X)$ as its set of points, but is not concrete: its sections over $U$ are the $k$-forms on
$X\times U$, including those with components along $U$. The functional diffeology on $\Om^k(X)$ of \IZ{art.~6.29} is its concretisation.
\end{remark}

\section{Descent along subductions}

\begin{proposition}[Forms on quotients, \IZ{art.~6.38}]\label{prop:forms-descent}
Let $\pi\colon X\to B$ be a subduction. Then
\[
\Om^k(B)\xrightarrow{\ \pi^*\ }\Om^k(X)\rightrightarrows\Om^k(X\times_BX)
\]
is an equaliser: a form on $X$ descends to $B$, uniquely, if and only if its two pullbacks to $X\times_BX$ coincide. Explicitly,
$\beta=\pi^*\alpha$ for a unique $\alpha$ iff $\beta(P)=\beta(P')$ for all plots $P,P'$ of $X$ with $\pi\circ P=\pi\circ P'$.
\end{proposition}
\begin{proof}
A subduction is an epimorphism of sheaves, because plots lift locally. In a topos every epimorphism is the coequaliser of its kernel pair, and
the kernel pair of $\pi$, computed in $\SmSet$, is the diffeological space $X\times_BX$ (the inclusion $\Diff\into\SmSet$ preserves limits). Now
apply $\Hom_{\SmSet}(-,\Om^k)$, which turns coequalisers into equalisers.
\end{proof}

The proof never used that the target was $\Om^k$: the same statement holds for maps from $B$ into \emph{any} smooth set. Subductions are
exactly the maps along which everything descends.

\begin{proposition}[Forms on the running examples]\label{prop:forms-examples}
\begin{enumerate}[label=\textup{(\roman*)}]
\item Let $\Gamma\subset\R^n$ be a dense countable subgroup. Then $\Om^\bullet(\R^n/\Gamma)$ is the exterior algebra of constant-coefficient forms on
$\R^n$, with zero differential. In particular $\Om^0(\Tal)=\R$, $\Om^1(\Tal)=\R\,\theta$ with $q_\alpha^*\theta=\dd x$, and $\Om^k(\Tal)=0$ for $k\ge2$.
\item $\Om^1(\dten_1)=\set{a(x)\,\dd x : a\text{ odd}}$ under pullback to $\R$, and every $1$-form on $\dten_1$ is exact.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) Two plots $P,P'$ of $\R^n$ with the same image in the quotient differ by a smooth map into $\Gamma$, which is locally constant. So the
condition of \cref{prop:forms-descent} is invariance under all translations by $\gamma\in\Gamma$. The coefficients of an invariant form are
continuous and $\Gamma$-periodic, hence constant. (ii) Taking $P'=-P$ shows $a$ must be odd. Conversely let $a$ be odd, so that $A(x)=\int_0^xa$ is
even; by Whitney's theorem \cite{Whitney} $A(x)=B(x^2)$ with $B$ smooth. If $P,P'$ are plots of $\R$ with $P'=\pm P$ pointwise then
$P'^2=P^2$, and $P^*(a\,\dd x)=\dd(B\circ P^2)=P'^*(a\,\dd x)$. By the same formula, $a\,\dd x=\dd(B\circ\mathrm{sq})$ is exact on $\dten_1$.
\end{proof}

\section{De~Rham cohomology and homotopy invariance}

The \defn{de~Rham cohomology} $H^\bullet_{\dR}(X)$ of a diffeological space is the cohomology of the complex $(\Om^\bullet(X),\dd)$, as in
\IZ{art.~6.73}. From \cref{prop:forms-examples}:
\[
H^0_{\dR}(\Tal)=\R,\qquad H^1_{\dR}(\Tal)=\R\,[\theta],\qquad H^k_{\dR}(\Tal)=0\ \ (k\ge2).
\]

\begin{proposition}[Homotopy invariance, \IZ{art.~6.88}]\label{prop:dR-homotopy}
Smoothly homotopic maps induce the same map on de~Rham cohomology.
\end{proposition}
\begin{proof}
It suffices to construct, naturally in the smooth set $X$, an operator $K\colon\Om^k(X\times\R)\to\Om^{k-1}(X)$ with
$\dd K+K\dd=i_1^*-i_0^*$. For a Cartesian space $U$ let $K_U\omega=\int_0^1\iota_{\partial_t}\omega\,\dd t$ be integration along the fibre of
$U\times[0,1]\to U$. The classical computation gives the homotopy formula on $U$, and $K_U$ commutes with pullback along smooth maps $V\to U$.
A natural family of maps $\Om^k(U\times\R)\to\Om^{k-1}(U)$ is a map of sheaves $[\R,\Om^k]\to\Om^{k-1}$, so $K$ is defined on
$\Hom(X\times\R,\Om^k)=\Hom(X,[\R,\Om^k])$ by post-composition, and the formula holds because it holds in the target.
\end{proof}

The chain-homotopy operator of \IZ{art.~6.83} is the refinement of $K$ defined on $\Paths(X)$; the argument is the same.

\section{De~Rham's theorem and its obstruction}\label{sec:dR-obstruction}

On a Cartesian space the de~Rham complex is exact in positive degrees and its $H^0$ is the constants. As a statement about sheaves:

\begin{lemma}[Poincar\'e]\label{lem:poincare}
$0\to\fl\R\to\Om^0\xrightarrow{\dd}\Om^1\xrightarrow{\dd}\Om^2\to\cdots$ is an exact sequence of sheaves of abelian groups on $\Cart$, where
$\fl\R=\Disc(\R)$ is the constant sheaf. It is already exact on sections over every Cartesian space.
\end{lemma}

For a sheaf of abelian groups $A$ on $\Cart$ and $X\in\Hh$ write $H^q(X;A)=\pi_0\Map_{\Hh}(X,\B^qA)$. For $A=\fl\R$ the adjunction
\eqref{eq:flat-adjunction} gives $H^q(X;\fl\R)=H^q(\Pi X;\R)$, the real cohomology of the shape. For $q=0$ and $X$ a smooth set,
$H^0(X;\Om^p)=\Om^p(X)$.

\begin{theorem}[De~Rham's theorem with obstruction; after \cite{IZCech,MinichielloObs}]\label{thm:dR-obstruction}
Let $X$ be a smooth set, for instance a diffeological space.
\begin{enumerate}[label=\textup{(\roman*)}]
\item There is a first-quadrant spectral sequence
\[
E_1^{p,q}=H^q(X;\Om^p)\ \Longrightarrow\ H^{p+q}(\Pi X;\R),\qquad d_1=\dd_*,
\]
with $E_2^{p,0}=H^p_{\dR}(X)$, whose edge maps $H^p_{\dR}(X)\to H^p(\Pi X;\R)$ are the de~Rham homomorphisms.
\item In low degrees there is an exact sequence
\[
0\to H^1_{\dR}(X)\to H^1(\Pi X;\R)\to E_2^{0,1}\to H^2_{\dR}(X)\to H^2(\Pi X;\R),
\]
where $E_2^{0,1}=\ker\bigl(\dd_*\colon H^1(X;\R)\to H^1(X;\Om^1)\bigr)$ is a subgroup of the group $H^1(X;\R)$ of isomorphism classes of
principal $\R$-bundles over $X$.
\item If $X$ is a manifold then $H^q(X;\Om^p)=0$ for $q>0$, and all edge maps are isomorphisms.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) By \cref{lem:poincare} the complex $\Om^\bullet$ is a resolution of $\fl\R$, so $\B^n\fl\R$ is the object of $\Hh$ associated by the
Dold--Kan correspondence to the complex $\Om^0\to\cdots\to\Om^{n-1}\to\Om^n_{\mathrm{cl}}$, and
$H^n(\Pi X;\R)=H^n(X;\fl\R)$ is the hypercohomology $\mathbb H^n(X;\Om^\bullet)$. Filtering $\Om^\bullet$ by its stupid truncations
$\Om^{\ge p}$ gives a tower in $\Hh$ whose layers are $\B^{n-p}\Om^p$, and mapping $X$ into the tower gives the spectral sequence with
$E_1^{p,q}=\pi_0\Map(X,\B^q\Om^p)$. Its bottom row is $\Om^\bullet(X)$ with differential $\dd$.
(ii) is the five-term exact sequence of a first-quadrant spectral sequence, together with \cref{thm:classification} for the identification of
$H^1(X;\R)$ with principal $\R$-bundles.
(iii) Cover a manifold $M$ by a good open cover; in $\Hh$, $M$ is the colimit of the \v{C}ech nerve, whose terms are coproducts of Cartesian
spaces. Since $\B^q\Om^p$ has vanishing higher cohomology on Cartesian spaces, $H^q(M;\Om^p)$ is the \v{C}ech cohomology of the cover with
coefficients in $\Om^p$, which vanishes for $q>0$ by a partition of unity. The spectral sequence collapses onto its bottom row.
\end{proof}

De~Rham's theorem is thus the statement that the sheaves $\Om^p$ are acyclic on $X$. On a manifold the reason is partitions of unity. A
diffeological space has no partitions of unity in general --- $\Tal$ has no non-constant functions at all --- and the groups $H^q(X;\Om^p)$ are
new invariants. The first of them, $H^1(X;\Om^0)$, was introduced by Iglesias-Zemmour as the group $\Fl(X)$ of ``flows'' or principal
$\R$-bundles \IZ{art.~8.39}; part (ii) contains his description of the cokernel of the first de~Rham homomorphism \IZ{art.~8.30}.

\begin{proposition}[The $E_2$ page of the irrational torus]\label{prop:E2-Talpha}
For $X=\Tal$ one has $E_1^{p,q}=H^q(\Lam_\alpha;\Om^p(\R))$, group cohomology of $\Lam_\alpha\cong\Z^2$ acting by translation, and
\[
E_2^{p,q}=\begin{cases}\R & (p,q)\in\{0,1\}^2,\\ 0&\text{otherwise,}\end{cases}
\]
for every irrational $\alpha$. The spectral sequence degenerates at $E_2$ and recovers $H^\bullet(T^2;\R)$. The classes are: $1$ and $[\theta]$ in the
row $q=0$; the Kronecker bundle $[T^2\to\Tal]$ in $E_2^{0,1}$; and a class in $E_2^{1,1}=H^1(\Tal;\Om^1)/\dd H^1(\Tal;\R)$ that
represents the fundamental class of $T^2$.
\end{proposition}
\begin{proof}
$\Tal\simeq\R\hquot\Lam_\alpha$ in $\Hh$ by \cref{cor:TGamma}, so $\Map(\Tal,\B^q\Om^p)$ is the space of homotopy fixed points of $\Lam_\alpha$ on
$\Map(\R,\B^q\Om^p)\simeq\B^q(\Om^p(\R))$, whose $\pi_0$ is $H^q(\Lam_\alpha;\Om^p(\R))$. Write $\Lam_\alpha=\Z\cdot1\oplus\Z\cdot\alpha$. By
\cref{lem:coboundary-line} the generator $1$ has $H^1(\Z;\Om^p(\R))=0$ and $H^0(\Z;\Om^p(\R))=\Om^p(S^1)$, so the Lyndon--Hochschild--Serre
spectral sequence gives
\[
H^q(\Lam_\alpha;\Om^p(\R))=H^q\bigl(\Z;\Om^p(S^1)\bigr)\quad\text{for the rotation }\rho_\alpha ,
\]
which is the invariants for $q=0$, the coinvariants $\Om^p(S^1)/(\rho_\alpha^*-1)$ for $q=1$, and zero for $q\ge2$. The differential $d_1$ is induced
by $\dd$, so $E_2^{\bullet,q}$ is the cohomology of the complex $H^q(\Z;\Om^\bullet(S^1))$. For $q=0$ this is the complex of
rotation-invariant forms $\R\xrightarrow{0}\R\,\dd x$. For $q=1$ it is the complex of coinvariants
$\cinf(S^1)/(\rho_\alpha^*-1)\xrightarrow{\dd}\Om^1(S^1)/(\rho_\alpha^*-1)$. Its cokernel is $\Om^1(S^1)/(\dd\cinf(S^1)+\im(\rho_\alpha^*-1))=H^1_{\dR}(S^1)=\R$,
since a rotation acts trivially on cohomology. Its kernel consists of the classes of $g$ with $g'=h\circ\rho_\alpha-h$; writing $h=c+k'$ with $k$
periodic gives $g=k\circ\rho_\alpha-k+\text{const}$, so the kernel is the line of constants. All differentials $d_r$, $r\ge2$, vanish for degree
reasons except $d_2\colon E_2^{0,1}\to E_2^{2,0}=0$.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \draw[->,hcsgrey] (-0.3,0)--(6.6,0) node[right,hcsink]{$p$};
  \draw[->,hcsgrey] (0,-0.3)--(0,3.0) node[above,hcsink]{$q$};
  \foreach \x/\l in {1.2/0,3.7/1,5.8/2} \node[below,hcsgrey] at (\x,-0.05) {\l};
  \foreach \y/\l in {0.7/0,2.0/1} \node[left,hcsgrey] at (-0.05,\y) {\l};
  \node[hcsnode] (a) at (1.2,0.7) {$\R$}; \node[hcsnode] (b) at (3.7,0.7) {$\R\,\theta$}; \node at (5.8,0.7) {$0$};
  \node[hcsnodeb] (c) at (1.2,2.0) {$\Fl(\Tal)$}; \node[hcsnodeb] (d) at (3.7,2.0) {$\Om^1(S^1)/(\rho^*_\alpha-1)$}; \node at (5.8,2.0) {$0$};
  \draw[->] (a)--node[above,font=\scriptsize]{$0$}(b); \draw[->] (c)--node[above,font=\scriptsize]{$\dd$}(d);
  \node[font=\footnotesize,align=center] at (3.2,-1.05) {$E_1^{p,q}=H^q(\Tal;\Om^p)$:\\ depends on the arithmetic of $\alpha$};
 \end{scope}
 \begin{scope}[xshift=8.6cm]
  \draw[->,hcsgrey] (-0.3,0)--(4.6,0) node[right,hcsink]{$p$};
  \draw[->,hcsgrey] (0,-0.3)--(0,3.0) node[above,hcsink]{$q$};
  \foreach \x/\l in {1.2/0,2.7/1,3.9/2} \node[below,hcsgrey] at (\x,-0.05) {\l};
  \foreach \y/\l in {0.7/0,2.0/1} \node[left,hcsgrey] at (-0.05,\y) {\l};
  \node[hcsnode] at (1.2,0.7) {$\R$}; \node[hcsnode] at (2.7,0.7) {$\R$}; \node at (3.9,0.7) {$0$};
  \node[hcsnodeb] at (1.2,2.0) {$\R$}; \node[hcsnodeb] at (2.7,2.0) {$\R$}; \node at (3.9,2.0) {$0$};
  \node[font=\scriptsize,hcsrust] at (1.2,2.55) {Kronecker}; \node[font=\scriptsize,hcsrust] at (2.7,2.55) {$[T^2]$};
  \node[font=\scriptsize,hcsteal] at (1.2,1.2) {$1$}; \node[font=\scriptsize,hcsteal] at (2.7,1.2) {$[\theta]$};
  \node[font=\footnotesize,align=center] at (2.2,-1.05) {$E_2=E_\infty$: the cohomology\\ of $S^1\times S^1$, for every $\alpha$};
 \end{scope}
\end{tikzpicture}
\caption{The de~Rham spectral sequence of the irrational torus. The bottom row is the de~Rham cohomology $H_{\dR}^\bullet(\Tal)=(\R,\R,0)$. The top row is
the contribution of principal $\R$-bundles. Together they are $H^\bullet(\Pi\Tal;\R)=H^\bullet(T^2;\R)=(\R,\R^2,\R)$.}\label{fig:E2}
\end{figure}

So the torus $T^2$ has two circles' worth of cohomology and all of it is present in the cohomology of $\Pi\Tal$, but only the circle transverse to the
foliation is represented by differential forms; the circle along the leaves is represented by the non-trivial $\R$-bundle $T^2\to\Tal$. The $E_2$ page is independent of the arithmetic of
$\alpha$. The dependence is on $E_1$, in the size of $\Fl(\Tal)$, and is the subject of \cref{thm:Fl}.

\section{Curvature and integration bundles}

The same method applies to the next classifying object. Let $P\subsetneq\R$ be a proper subgroup and $T_P=\R/P$; as a subspace of $\R$, $P$ is
discrete, since it contains no interval. The differential descends to a map of sheaves $\dd\colon T_P\to\Om^1_{\mathrm{cl}}$.

\begin{lemma}\label{lem:TP-complex}
The sequence of sheaves $0\to\fl(\R/P)\to T_P\xrightarrow{\dd}\Om^1\xrightarrow{\dd}\Om^2_{\mathrm{cl}}\to0$ is exact on $\Cart$.
\end{lemma}
\begin{proof}
Exactness on the right and in the middle is \cref{lem:poincare}, together with the fact that $\R\to T_P$ is an epimorphism. A section of $T_P$
over a Cartesian $U$ with zero differential lifts locally to a function with zero differential, that is, to a constant; so it is a constant map
$U\to\R/P$, and conversely.
\end{proof}

Define $\B(T_P)_{\mathrm{conn}}\in\Hh$ as the stack associated to the two-term complex $T_P\xrightarrow{\dd}\Om^1$: over a Cartesian space its
objects are $1$-forms $A$, and its morphisms $A\to A'$ are sections $g$ of $T_P$ with $A'=A+\dd g$. It is the analogue for $T_P$ of the moduli stack of principal
bundles with a connection $1$-form (compare \IZ{art.~8.37}); for $P=\Z$ it is the usual $\B U(1)_{\mathrm{conn}}$. The
\defn{curvature} is the map $F\colon\B(T_P)_{\mathrm{conn}}\to\Om^2_{\mathrm{cl}}$, $A\mapsto\dd A$.

\begin{theorem}[Integration bundles; after \IZ{art.~8.42}]\label{thm:integration}
There is a fibre sequence in $\Hh$
\[
\B(T_P)_{\mathrm{conn}}\xrightarrow{\ F\ }\Om^2_{\mathrm{cl}}\xrightarrow{\ c\ }\fl\B^2(\R/P).
\]
Consequently a closed $2$-form $\omega$ on a diffeological space $X$ is the curvature of a principal $T_P$-bundle with connection if and only
if the class $c(\omega)\in H^2(\Pi X;\R/P)$ vanishes; this class is the reduction modulo $P$ of the image of $\omega$ in $H^2(\Pi X;\R)$. If $X$ is
simply connected, $c(\omega)=0$ if and only if the periods of $\omega$ over $\pi_2(X)$ lie in $P$, and then the bundle with connection is unique
up to isomorphism.
\end{theorem}
\begin{proof}
By \cref{lem:TP-complex} the three-term complex $T_P\to\Om^1\to\Om^2_{\mathrm{cl}}$ is a resolution of $\fl(\R/P)$ placed in degree $2$, so it
presents $\fl\B^2(\R/P)$. The inclusion of $\Om^2_{\mathrm{cl}}$ as its last term is $c$, and the homotopy fibre of $c$ is presented by the
truncation $T_P\to\Om^1$, with the map to $\Om^2_{\mathrm{cl}}$ given by $\dd$. This is the fibre sequence. A map $\omega\colon X\to\Om^2_{\mathrm{cl}}$
lifts through the fibre iff $c\circ\omega$ is null-homotopic, and $\pi_0\Map(X,\fl\B^2(\R/P))=H^2(\Pi X;\R/P)$ by \eqref{eq:flat-adjunction}. The
comparison of resolutions $\Om^\bullet\to(T_P\to\Om^1\to\Om^2_{\mathrm{cl}})$ covers $\R\to\R/P$, which identifies $c(\omega)$. If $\Pi X$ is simply
connected, the Hurewicz and universal coefficient theorems give $H^2(\Pi X;A)=\Hom(\pi_2(\Pi X),A)$ for every abelian group $A$, and
$\pi_2(\Pi X)=\pi_2(X)$ by \cref{thm:pin}. Lifts are a torsor under $H^1(\Pi X;\R/P)=\Hom(\pi_1(X),\R/P)=0$.
\end{proof}

\begin{remark}[Prequantisation without integrality]
Classically one needs the periods of $\omega$ to be integral to build a circle bundle with curvature $\omega$. By \cref{thm:integration} the
integrality condition is an artefact of fixing the structure group $\R/\Z$: for \emph{any} closed $2$-form on a simply connected space
whose group of periods $P_\omega$ is not all of $\R$, there is a canonical principal bundle with connection and curvature $\omega$, with structure
group the torus of periods $T_{P_\omega}$, which is an irrational torus as soon as $P_\omega$ has rank at least $2$. This is the theorem of
Iglesias-Zemmour \IZ{art.~8.42}, and a good example of a statement that is natural in $\Diff$ and has no formulation in $\Mfd$.
\end{remark}

\exercisesheading

\begin{exercise}[label=exo:forms-discrete]{1}
Show that $\Om^0(X)=\cinf(X,\R)$, and that $\Om^k(X)=0$ for $k\ge1$ if $X$ is discrete.
\end{exercise}
\begin{solution}
$\Om^0=\underline\R$ is representable, so $\Hom_{\SmSet}(\underline X,\underline\R)=\Diff(X,\R)$ by \cref{thm:BH}. If $X$ is discrete, every plot
$P\colon U\to X$ is locally constant, so locally $P=x\circ c$ with $c\colon V\to\ast$ and $x\colon\ast\to X$. Then
$\alpha(P)|_V=c^*\alpha(x)$ and $\alpha(x)\in\Om^k(\ast)=0$.
\end{solution}

\begin{exercise}[label=exo:dR-Talpha]{2}
Compute the de~Rham homomorphism $H^1_{\dR}(\Tal)\to H^1(\Pi\Tal;\R)=\Hom(\Lam_\alpha,\R)$ and its cokernel.
\end{exercise}
\begin{solution}
$H^1_{\dR}(\Tal)=\R[\theta]$ with $q_\alpha^*\theta=\dd x$. The period of $\theta$ on the loop $t\mapsto q_\alpha(t\mu)$, $\mu\in\Lam_\alpha$, is
$\int_0^1\mu\,\dd t=\mu$. So $[\theta]$ maps to the inclusion $\Lam_\alpha\into\R$, and $c[\theta]$ to $\mu\mapsto c\mu$. In the basis of
$\Hom(\Lam_\alpha,\R)=\R^2$ given by the values on $1$ and $\alpha$, the image is the line spanned by $(1,\alpha)$. The cokernel is one-dimensional,
spanned for instance by the class of $\rho(m+n\alpha)=-n$. By \cref{thm:dR-obstruction}(ii) and \cref{prop:E2-Talpha} it is $E_2^{0,1}$, and by
\cref{exo:kronecker-class} the class of $\rho$ is that of the bundle $T^2\to\Tal$.
\end{solution}

\begin{exercise}[label=exo:forms-coarse]{3}
Show that a coarse diffeological space has no non-zero differential forms of positive degree.
\end{exercise}
\begin{solution}
Let $X$ be coarse, $\alpha\in\Om^k(X)$ with $k\ge1$, $P\colon U\to X$ a plot (any function) and $r_0\in U$; we show $\alpha(P)_{r_0}=0$. Choose
a diffeomorphism identifying a neighbourhood of $r_0$ with $\R^n$ and $r_0$ with $0$; by locality we may assume $U=\R^n$. Let
$F(r)=(r_1^3,\dots,r_n^3)$, a smooth homeomorphism with non-smooth inverse $G$. Since $X$ is coarse, $P\circ G$ is a plot, and
$P=(P\circ G)\circ F$ with $F$ smooth, so $\alpha(P)=F^*\alpha(P\circ G)$. The derivative of $F$ at $0$ is zero, so the pullback of any form of
positive degree by $F$ vanishes at $0$. Hence $\alpha(P)$ vanishes at every point, for every plot.
\end{solution}

\begin{exercise}[label=exo:kronecker-class]{3}
For a homomorphism $\rho\colon\Lam_\alpha\to\R$ let $X_\rho=(\R\times\R)/\Lam_\alpha$ for the action $\lambda\cdot(u,t)=(u+\lambda,t+\rho(\lambda))$, a
principal $\R$-bundle over $\Tal$ with projection $[u,t]\mapsto q_\alpha(u)$ and action $s\cdot[u,t]=[u,t+s]$ \IZ{art.~8.30}. Show that for
$\rho(m+n\alpha)=-n$ the bundle $X_\rho$ is isomorphic to the Kronecker bundle $T^2\to\Tal$, $[x,y]\mapsto q_\alpha(y-\alpha x)$, with $\R$ acting by
the flow $s\cdot[x,y]=[x+s,y+\alpha s]$.
\end{exercise}
\begin{solution}
Define $\Phi\colon\R\times\R\to T^2$ by $\Phi(u,t)=[t,\,u+\alpha t]$. It is smooth, it lies over $q_\alpha$ because $(u+\alpha t)-\alpha t=u$, and it
intertwines translation in $t$ with the flow. For $\lambda=m+n\alpha$ we have $\rho(\lambda)=-n$ and
\[
\Phi\bigl(u+\lambda,\ t-n\bigr)=\bigl[t-n,\ u+m+n\alpha+\alpha t-\alpha n\bigr]=\bigl[t-n,\ u+\alpha t+m\bigr]=\Phi(u,t),
\]
so $\Phi$ descends to a smooth equivariant map $\bar\Phi\colon X_\rho\to T^2$ over $\Tal$. It is bijective: if $\Phi(u,t)=\Phi(u',t')$ then
$t'=t+k$ and $u'+\alpha t'=u+\alpha t+l$ with $k,l\in\Z$, so $u'=u+\lambda$ with $\lambda=l-k\alpha$ and $t'=t+\rho(\lambda)$; and
$[x,y]=\Phi(y-\alpha x,x)$. The inverse $[x,y]\mapsto[y-\alpha x,\,x]$ is well defined by the same computation and smooth because
$\R^2\to T^2$ is a subduction. Hence $X_\rho\cong T^2$ as principal $\R$-bundles: the Kronecker bundle is the flat bundle with holonomy
$m+n\alpha\mapsto-n$, and it spans the cokernel found in \cref{exo:dR-Talpha}.
\end{solution}

\begin{exercise}[label=exo:IZ830]{4}
Let $X$ be a connected diffeological space. Deduce from the short exact sequence of sheaves $0\to\fl\R\to\underline\R\xrightarrow{\dd}\Om^1_{\mathrm{cl}}\to0$
an exact sequence
\[
0\to H^1_{\dR}(X)\to\Hom(\pi_1(X),\R)\xrightarrow{\ \partial\ }H^1(X;\R)\to H^1(X;\Om^1_{\mathrm{cl}}),
\]
and show that $\partial(\rho)$ is the class of the bundle $X_\rho=\tilde X\times_{\pi_1(X)}\R$ of \IZ{art.~8.30}.
\end{exercise}
\begin{solution}
A short exact sequence of sheaves of abelian groups gives a fibre sequence $\B^q\fl\R\to\B^q\underline\R\to\B^q\Om^1_{\mathrm{cl}}$ in $\Hh$ for
each $q$, and these splice into a long fibre sequence. Applying $\pi_0\Map(X,-)$ yields the exact sequence
\[
\cinf(X)\xrightarrow{\dd}\Om^1_{\mathrm{cl}}(X)\to H^1(X;\fl\R)\to H^1(X;\R)\to H^1(X;\Om^1_{\mathrm{cl}}).
\]
The cokernel of the first map is $H^1_{\dR}(X)$, which therefore injects into the next term. By \eqref{eq:flat-adjunction},
$H^1(X;\fl\R)=H^1(\Pi X;\R)$, and for a connected space with fundamental group $\pi_1$ this is $\Hom(\pi_1,\R)$; by \cref{thm:pin},
$\pi_1(\Pi X)=\pi_1(X)$. This gives the sequence.

For $\partial$: it is induced by $\B\fl\R=\B\Rd\to\B\R$, which sends a principal $\Rd$-bundle to the principal $\R$-bundle obtained by extending
the structure group along the smooth homomorphism $\Rd\to\R$. Under $H^1(\Pi X;\R)=\Hom(\pi_1,\R)$ the homomorphism $\rho$ corresponds to the
$\Rd$-bundle $\tilde X\times_{\pi_1}\Rd$ associated to the universal covering, a principal $\pi_1$-bundle (\cref{ch:homotopy}), via $\rho$.
Extending the group gives $\tilde X\times_{\pi_1}\R=X_\rho$.

Exactness at $H^1(X;\R)$ is now the statement that $X_\rho$ is trivial if and only if $\rho$ is the period homomorphism of a closed $1$-form. This is the
theorem of \IZ{art.~8.30}. Exactness at the next term gives more: a principal $\R$-bundle is of the form $X_\rho$, i.e.\ flat, if and
only if its image in $H^1(X;\Om^1_{\mathrm{cl}})$ vanishes.
\end{solution}



\chapter{Bundles and stacks}\label{ch:bundles}

\begin{chapabstract}
In \cite{IZ} principal bundles are defined by an induction condition on the action map. We show that this condition holds exactly when the
diffeological quotient is the homotopy quotient. It follows that principal bundles are classified by maps to a stack $\B G$, which is not a
diffeological space, and that a group action has three quotients --- stack, smooth set, diffeological space --- which coincide precisely for
principal actions.
\end{chapabstract}
\source{\IZ{Chapter~7} (groups) and \IZ{art.~8.1--8.19} (groupoids, fibrations, principal and associated bundles).}

\section{Diffeological groups}

A \defn{diffeological group} is a group object of $\Diff$: a group $G$ with a diffeology for which multiplication and inversion are smooth
\IZ{art.~7.1}. Lie groups are examples; so are $\Tal$ and $\R/\Q$; so is every subgroup of a diffeological group with the subspace diffeology
and every quotient group with the quotient diffeology \IZ{art.~7.2--7.3}; so is $\Dif(X)$ for every diffeological space $X$, with the
diffeology in which $r\mapsto f_r$ is a plot when both $(r,x)\mapsto f_r(x)$ and $(r,x)\mapsto f_r^{-1}(x)$ are smooth \IZ{art.~1.61}. None of
these constructions has hypotheses: there is no closedness condition on subgroups and no properness condition on quotients.

A diffeological group is in particular a group object of $\Hh$, and so has a \defn{delooping}
\[
\B G=\ast\hquot G=\colim_{[k]\in\Delta^{\op}}G^k\ \in\Hh,\qquad\Omega\,\B G\simeq G .
\]
$\B G$ is a connected $1$-truncated object, a stack. It has one point and that point has automorphism group $G$; it is not a
smooth set unless $G$ is trivial.

\section{Principal actions are homotopy quotients}

\begin{definition}[\IZ{art.~8.11}]\label{def:principal}
A smooth right action of a diffeological group $G$ on a diffeological space $X$ is \defn{principal} if the action map
\[
a\colon X\times G\longrightarrow X\times X,\qquad(x,g)\longmapsto(x,xg),
\]
is an induction. A \defn{principal $G$-bundle} over $B$ is a space $X$ with a principal $G$-action and a diffeomorphism $X/G\cong B$.
\end{definition}

Injectivity of $a$ means that the action is free. The induction condition is stronger: whenever two plots $r\mapsto x_r$, $r\mapsto x'_r$ of $X$ lie
pointwise in the same orbit, the unique family $g_r$ with $x'_r=x_rg_r$ is a plot of $G$. In \cite{IZ} this is the hypothesis under which
$X\to X/G$ is proved to be a fibre bundle. Here is what it means.

\begin{theorem}[Principal $=$ homotopy quotient; compare \cite{MinichielloBun}]\label{thm:principal}
For a smooth action of a diffeological group $G$ on a diffeological space $X$, with diffeological quotient $\pi\colon X\to B=X/G$, the following
are equivalent.
\begin{enumerate}[label=\textup{(\roman*)}]
\item The action is principal.
\item The canonical map $X\hquot G\to B$ is an equivalence in $\Hh$.
\item For every plot $P\colon U\to B$, the pullback $P^*X\to U$ is locally isomorphic to $U\times G$ as a space with $G$-action.
\end{enumerate}
\end{theorem}
\begin{proof}
\emph{(i)$\Leftrightarrow$(ii).} The quotient map $\pi$ is a subduction, hence an epimorphism of sheaves, hence an effective epimorphism of
$\Hh$, since effective epimorphisms are detected on $\pi_0$ \cite[7.2.1.14]{HTT}. So $B$ is the colimit of the \v{C}ech nerve
$\check C(\pi)_k=X\times_B\cdots\times_BX$, and these fibre products may be computed in $\Diff$ because the inclusions $\Diff\into\SmSet\into\Hh$
preserve limits. On the other hand $X\hquot G$ is by definition the colimit of the nerve of the action groupoid, $N_k=X\times G^k$. There is a
map of simplicial objects
\[
N_k=X\times G^k\longrightarrow\check C(\pi)_k,\qquad(x,g_1,\dots,g_k)\longmapsto(x,xg_1,xg_1g_2,\dots),
\]
inducing $X\hquot G\to B$ on colimits (\cref{fig:nerves}). Both sides are groupoid objects, so the map is an isomorphism in every degree iff it is
one in degree $1$, where it is the action map $a$ with target restricted to its image $X\times_BX$. The fibres of $\pi$ are the orbits, so
$a$ is onto $X\times_BX$; since $X\times_BX$ carries the subspace diffeology of $X\times X$, the map $X\times G\to X\times_BX$ is a
diffeomorphism iff $a$ is an induction. Thus (i) implies (ii). Conversely, if $X\hquot G\simeq B$ then, groupoid objects in an $\infty$-topos being
effective \cite[6.1.0.6]{HTT}, $X\times G\simeq X\times_{X\hquot G}X\simeq X\times_BX$ via $a$, which is (i).

\emph{(i)$\Rightarrow$(iii).} Since $\pi$ is a subduction, $P$ lifts near any $r_0$ to a plot $s\colon V\to X$. The map
$V\times G\to P^*X|_V$, $(r,g)\mapsto(r,s(r)g)$, is a smooth equivariant bijection. Its inverse sends $(r,x)$ to $(r,g)$ where
$a(s(r),g)=(s(r),x)$, and is smooth because $a$ is an induction.

\emph{(iii)$\Rightarrow$(i).} The action is free because each $P^*X$ is locally $V\times G$. Let $r\mapsto(x_r,x'_r)$ be a plot of $X\times X$
with values in the image of $a$, and let $P=\pi\circ x=\pi\circ x'$. Trivialise $P^*X$ near $r_0$; the two sections $r\mapsto(r,x_r)$ and
$r\mapsto(r,x'_r)$ become $r\mapsto(r,h_r)$ and $r\mapsto(r,h'_r)$ with $h,h'$ plots of $G$, and $g_r=h_r^{-1}h'_r$ is a plot of $G$ with
$x'_r=x_rg_r$.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzcd}[column sep=2.8em,row sep=2.4em]
\cdots \arrow[r,shift left=1.6ex] \arrow[r,shift left=0.55ex] \arrow[r,shift right=0.55ex] \arrow[r,shift right=1.6ex] &
X\times G^2 \arrow[r,shift left=1.1ex] \arrow[r] \arrow[r,shift right=1.1ex] \arrow[d] &
X\times G \arrow[r,shift left=0.6ex] \arrow[r,shift right=0.6ex] \arrow[d,"a"] & X \arrow[r,two heads] \arrow[d,equal] & X\hquot G \arrow[d]\\
\cdots \arrow[r,shift left=1.6ex] \arrow[r,shift left=0.55ex] \arrow[r,shift right=0.55ex] \arrow[r,shift right=1.6ex] &
X\times_BX\times_BX \arrow[r,shift left=1.1ex] \arrow[r] \arrow[r,shift right=1.1ex] &
X\times_BX \arrow[r,shift left=0.6ex] \arrow[r,shift right=0.6ex] & X \arrow[r,two heads,"\pi"] & B=X/G
\end{tikzcd}
\caption{The nerve of the action groupoid (top) maps to the \v{C}ech nerve of the quotient map (bottom). The top row computes the homotopy
quotient, the bottom row the diffeological quotient. They coincide exactly when $a$ is an isomorphism onto $X\times_BX$, i.e.\ an induction.}\label{fig:nerves}
\end{figure}

\begin{corollary}[\IZ{art.~8.15}]\label{cor:GmodH}
Let $H$ be any subgroup of a diffeological group $G$. Then $G\to G/H$ is a principal $H$-bundle, $G/H\simeq G\hquot H$, and there is a
fibre sequence $H\to G\to G/H\to\B H\to\B G$ in $\Hh$.
\end{corollary}
\begin{proof}
If $r\mapsto(g_r,g'_r)$ is a plot of $G\times G$ with $g_r^{-1}g'_r\in H$, then $r\mapsto g_r^{-1}g'_r$ is a plot of $G$ with values in $H$,
that is, a plot of $H$. So the action is principal. The fibre sequence is the general one for a homomorphism of group objects \cite{NSS}.
\end{proof}

No hypothesis on $H$: it may be dense, as $\Lam_\alpha\subset\R$, or non-closed and of positive dimension, as an irrational line in $T^2$. This one
corollary contains the fact that $T^2\to\Tal$ and $\R\to\Tal$ are both fibre bundles.

\section{The classifying stack}

For a diffeological space $X$ let $\Bun_G(X)$ be the groupoid of principal $G$-bundles over $X$ and $G$-equivariant smooth maps over $X$.

\begin{lemma}\label{lem:Bun-basic}
\begin{enumerate}[label=\textup{(\roman*)}]
\item The pullback of a principal $G$-bundle along any smooth map is a principal $G$-bundle.
\item Every morphism of principal $G$-bundles over $X$ is an isomorphism.
\item \textup{(\IZ{art.~8.19})} Every principal $G$-bundle over a Cartesian space is trivial. Hence
$\Bun_G(U)\simeq\B\bigl(\cinf(U,G)\bigr)$ for $U\in\Cart$.
\end{enumerate}
\end{lemma}
\noindent (i) and (ii) are \cref{exo:Bun-cart}. (iii) is a real theorem, the diffeological form of the homotopy lifting property, and we quote
it. Its meaning here is that the presheaf of groupoids $U\mapsto\B(\cinf(U,G))$ on $\Cart$ is already a stack: there is nothing to sheafify.

\begin{theorem}[Classification; Minichiello \cite{MinichielloBun}, after \cite{Waldorf,KWW}]\label{thm:classification}
For every diffeological group $G$ and every diffeological space $X$ there is an equivalence of groupoids, natural in $X$,
\[
\Bun_G(X)\;\simeq\;\Map_{\Hh}(X,\B G),
\]
under which a bundle $E\to X$ corresponds to a map $c_E$ with $E\simeq X\times_{\B G}\ast$. In particular isomorphism classes of principal
$G$-bundles are in bijection with $H^1(X;G):=\pi_0\Map_{\Hh}(X,\B G)$.
\end{theorem}
\begin{proof}[Sketch]
\emph{Cartesian $U$.} $\B G$ is the stackification of $U\mapsto\B(\cinf(U,G))$, which by \cref{lem:Bun-basic}(iii) is equivalent to the stack
$U\mapsto\Bun_G(U)$; so $\B G(U)\simeq\Bun_G(U)$. \emph{General $X$.} Every sheaf is the colimit of the representables over it, so
$X\simeq\colim_{(U\to X)}U$ in $\Hh$, the colimit being over the category of plots, and $\Map(X,\B G)\simeq\lim_{(U\to X)}\Bun_G(U)$. An object
of the limit is a principal bundle $E_P\to U$ for every plot $P$, with coherent isomorphisms $F^*E_P\cong E_{P\circ F}$. Pulling back a bundle
on $X$ along its plots gives such a family. Conversely a family glues: let $E$ be the disjoint union over $x\in X$ of the fibres $E_x$ over the
point-plots, with the diffeology generated by the maps $E_P\to E$; then $E\to X$ is a principal bundle by criterion (iii) of
\cref{thm:principal}, and $P^*E\cong E_P$. The two constructions are inverse equivalences. For the last statement, the pullback of $\ast\to\B G$
along $c_E$ is a principal bundle with quotient $X$, as in any $\infty$-topos \cite{NSS}.
\end{proof}

\begin{remark}[There is no classifying \emph{space}]\label{rem:no-BG-space}
Christensen and Wu construct a diffeological space $BG$ that classifies the bundles that have a smooth partition of unity subordinate to a
trivialising D-open cover, and observe that no diffeological space classifies all diffeological principal bundles \cite{ChristensenWuBG}. The
Kronecker bundle exhibits the obstruction. Homotopy classes of maps into a space classify bundles at best up to \emph{concordance}, and every
principal $\R$-bundle over $\Tal$ is concordant to the trivial one: if $\tau$ is a cocycle for it in the sense of \cref{cor:bundles-TGamma}
below, then $(x,s)\mapsto s\,\tau(\lambda)(x)$ is a cocycle for a bundle over $\Tal\times\R$ that restricts to the trivial bundle at $s=0$ and to
the given one at $s=1$. Over a manifold, concordant bundles are isomorphic. Over $\Tal$ they are not: $T^2\to\Tal$ is concordant to the trivial
bundle and not isomorphic to it. For the stack $\B\R$ the distinction does not arise, because $\Map(X,\B\R)$ is the groupoid of bundles and
\emph{isomorphisms}, not a set of homotopy classes. $\B\R$ has contractible shape, $\Pi\,\B\R\simeq\B(\Pi\R)\simeq\ast$, and yet
$\Map(\Tal,\B\R)$ has the large set of components $\Fl(\Tal)$ computed in \cref{thm:Fl}. The classifying object of the book's bundle theory
exists, and is not a diffeological space.
\end{remark}

\begin{corollary}[Bundles over quotients of $\R^n$]\label{cor:bundles-TGamma}
Let $\Gamma\subset\R^n$ be a countable subgroup and $G$ a diffeological group. Then
\[
\Bun_G(\R^n/\Gamma)\;\simeq\;\bigl(\B\,\cinf(\R^n,G)\bigr)^{h\Gamma},
\]
the homotopy fixed points for the translation action. Its set of components is the non-abelian cohomology set $H^1(\Gamma;\cinf(\R^n,G))$ of
crossed homomorphisms $\tau\colon\Gamma\to\cinf(\R^n,G)$, $\tau(\gamma+\gamma')=(\tau(\gamma)\circ T_{\gamma'})\cdot\tau(\gamma')$, modulo
$\tau\sim(\sigma\circ T_\gamma)\cdot\tau(\gamma)\cdot\sigma^{-1}$.
\end{corollary}
\begin{proof}
$\R^n/\Gamma\simeq\R^n\hquot\Gamma$ by \cref{cor:TGamma}, and mapping out of a homotopy quotient gives homotopy fixed points:
\[
\Map(\R^n/\Gamma,\B G)\simeq\Map(\R^n,\B G)^{h\Gamma},\qquad\Map(\R^n,\B G)\simeq\B\,\cinf(\R^n,G),
\]
the second equivalence by \cref{lem:Bun-basic}(iii).
\end{proof}
\noindent For $G=\R$ and $n=1$ this is the cocycle description of \IZ{art.~8.39}, obtained there by hand.

\section{The three quotients}

\begin{theorem}[Trichotomy of quotients; compare \cite{WattsWolbert}]\label{thm:three-quotients}
Let a diffeological group $G$ act smoothly on a diffeological space $X$. In $\Hh$ there are canonical maps
\[
X\hquot G\;\xrightarrow{\ u\ }\;\pi_0(X\hquot G)\;\xrightarrow{\ v\ }\;\conc\,\pi_0(X\hquot G),
\]
and:
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\pi_0(X\hquot G)$ is the quotient of $X$ by $G$ in $\SmSet$, and $\conc\,\pi_0(X\hquot G)$ is the diffeological quotient $X/G$;
\item $u$ is an equivalence if and only if the action is free;
\item if the action is free, $v$ is an isomorphism if and only if the action is principal;
\item $\Pi(X\hquot G)\simeq\Pi X\hquot\Pi G$ in all cases.
\end{enumerate}
In particular $X\hquot G\simeq X/G$ if and only if the action is principal.
\end{theorem}
\begin{proof}
(i) $\pi_0$ and $\conc$ are left adjoints (\cref{thm:DiffinH}), so they carry the colimit $X\hquot G$ to the corresponding colimits in $\SmSet$
and $\Diff$, which are the coequalisers of the action. (iv) $\Pi$ preserves colimits and finite products.
(ii) Let $q\colon X\to X\hquot G$ be the canonical effective epimorphism, with $X\times_{X\hquot G}X\simeq X\times G$. The object $X\hquot G$ is
$0$-truncated iff its diagonal is a monomorphism, and this may be tested after pulling back along the effective epimorphism $q\times q$, where it
becomes the action map $a\colon X\times G\to X\times X$. A map of concrete sheaves is a monomorphism iff it is injective on points. So $X\hquot G$ is
$0$-truncated iff $a$ is injective iff the action is free.
(iii) Assume the action free and write $S=\pi_0(X\hquot G)=X\hquot G$. Both $X\to S$ and $X\to X/G$ are epimorphisms of sheaves, and an epimorphism
in a topos is determined by its kernel pair. The kernel pair of $X\to S$ is $X\times G$, embedded by $a$; that of $X\to X/G$ is $X\times_{X/G}X$,
the image of $a$ with the subspace diffeology. They coincide as subobjects of $X\times X$ iff $a$ is an induction.
\end{proof}

\begin{table}[t]\centering\small
\begin{tabular}{@{}llllll@{}}\toprule
action & free & principal & $X\hquot G$ & $\pi_0(X\hquot G)$ & $X/G$\\\midrule
$\Lam_\alpha$ on $\R$ & yes & yes & $\Tal$ & $\Tal$ & $\Tal$\\
$\R$ on $T^2$ (Kronecker) & yes & yes & $\Tal$ & $\Tal$ & $\Tal$\\
$\Rd$ on $\R$ & yes & no & $\Om^1_{\mathrm{cl}}$ & $\Om^1_{\mathrm{cl}}$ & $\ast$\\
$\{\pm1\}$ on $\R$ & no & no & orbifold, $\Pi=\B\Z/2$ & $Q$ (\cref{ex:Rpm-sheaf}) & $\dten_1$, $\Pi=\ast$\\
$\Ort(n)$ on $\R^n$ & no & no & stack, $\Pi=B\Ort(n)$ & non-concrete & $\dten_n$, $\Pi=\ast$\\
$G$ on $\ast$ & no & no & $\B G$ & $\ast$ & $\ast$\\\bottomrule
\end{tabular}
\caption{The three quotients on examples. Reading down the columns: the homotopy quotient retains all the data; in the sheaf quotient the
stabilisers are discarded; in the diffeological quotient families that coincide pointwise are moreover identified, whether or not they coincide in germs.}
\label{tab:three}
\end{table}

\Cref{thm:three-quotients} is the precise form of the exactness ladder of \cref{fig:ladder}, and it is the one structural statement used
in every application chapter. It also accounts for a pattern in \cite{IZ}: the theorems there with strong conclusions --- exact homotopy
sequences, classification of bundles over tori, the group of flows --- are about principal actions, where the diffeological quotient is the
homotopy quotient and nothing is lost; the examples there with unexpected properties --- $\dten_n$, orbifolds --- are about non-free actions, where
the diffeological space is the coarse space of a stack. Watts and Wolbert study the coarse space systematically as a ``coarse moduli space'' functor from
stacks to diffeological spaces \cite{WattsWolbert}.

\section{Groupoids and the book's fibrations}

In \cite{IZ} a smooth surjection $\pi\colon T\to B$ is a \emph{fibration} when its \emph{structure groupoid} is \emph{fibrating}
\IZ{art.~8.4--8.8}. The structure groupoid $\mathbf K$ has objects $B$ and as morphisms $b\to b'$ the diffeomorphisms $T_b\to T_{b'}$, with a
functional diffeology; a diffeological groupoid is fibrating when $(\mathrm{src},\mathrm{trg})\colon\Mor(\mathbf K)\to\Ob(\mathbf K)^2$ is a subduction.

\begin{proposition}[Fibrating groupoids are deloopings]\label{prop:fibrating}
Let $\mathbf K$ be a fibrating diffeological groupoid with non-empty space of objects, $b$ an object, and $\mathbf K_b$ its isotropy group. Then the
inclusion $\B\mathbf K_b\to|\mathbf K|$ of the one-object full subgroupoid into the stack presented by $\mathbf K$ is an equivalence in $\Hh$.
Consequently the canonical map $\Ob(\mathbf K)\to|\mathbf K|\simeq\B\mathbf K_b$ classifies a principal $\mathbf K_b$-bundle over $\Ob(\mathbf K)$,
namely $\mathrm{trg}\colon\mathrm{src}^{-1}(b)\to\Ob(\mathbf K)$.
\end{proposition}
\noindent The proof is \cref{exo:fibrating}. Applied to the structure groupoid of $\pi\colon T\to B$ it gives: $\pi$ is a diffeological fibre bundle
with fibre $F$ if and only if it is classified by a map $B\to\B\Dif(F)$, the principal $\Dif(F)$-bundle being the bundle of ``frames''
$F\xrightarrow{\cong}T_b$ \IZ{art.~8.14}, and $T$ being recovered as the associated bundle \IZ{art.~8.16}. The two-step definition of \cite{IZ} ---
build a groupoid, require that it be fibrating --- is the unpacking, in terms of plots, of ``a map to a delooping''.

\exercisesheading

\begin{exercise}[label=exo:Kronecker-principal]{2}
Verify directly that the Kronecker action $s\cdot[x,y]=[x+s,y+\alpha s]$ of $\R$ on $T^2$ is principal when $\alpha$ is irrational, and that it is
not principal when $\alpha$ is rational.
\end{exercise}
\begin{solution}
Let $r\mapsto(z_r,z'_r)$ be a plot of $T^2\times T^2$ with $z'_r$ in the orbit of $z_r$. Near $r_0$ lift to smooth $(x,y),(x',y')\colon V\to\R^2$.
For each $r$ there are $s\in\R$ and $(m,n)\in\Z^2$ with $x'-x=s+m$ and $y'-y=\alpha s+n$. Then $w=(y'-y)-\alpha(x'-x)=n-\alpha m$ is a smooth
function with values in $\Lam_\alpha$, hence locally constant; as $\alpha$ is irrational, $w$ determines $(m,n)$, which are therefore locally constant.
So $s_r=x'_r-x_r-m$ is smooth, and it is the unique real number with $z'_r=s_r\cdot z_r$ because the action is free. Hence the action map is an
induction. If $\alpha=p/q$ is rational, $s=q$ acts trivially, so the action is not free.
\end{solution}

\begin{exercise}[label=exo:three-pm]{2}
For $\{\pm1\}$ acting on $\R$, compute the shapes of $\R\hquot\{\pm1\}$ and of $\dten_1$, and explain the difference in terms of fibres.
\end{exercise}
\begin{solution}
By \cref{thm:three-quotients}(iv), $\Pi(\R\hquot\{\pm1\})=\ast\hquot(\Z/2)=\B\Z/2\simeq\R P^\infty$. By \cref{exo:contractible},
$\Pi\dten_1=\ast$. The map $\R\hquot\{\pm1\}\to\dten_1$ is an isomorphism over the open half-line and has fibre $\B\Z/2$ over the point $[0]$;
collapsing that one fibre changes the homotopy type from $\R P^\infty$ to a point. The stack retains the stabiliser of $0$, and in consequence
its shape differs from that of the half-line.
\end{solution}

\begin{exercise}[label=exo:Bun-cart]{3}
Prove \cref{lem:Bun-basic}(i) and (ii), and show that the automorphism group of the trivial bundle $X\times G\to X$ is $\cinf(X,G)$.
\end{exercise}
\begin{solution}
(i) Let $E\to X$ be principal and $f\colon X'\to X$ smooth; $f^*E=X'\times_XE$ carries the $G$-action on the second factor. Let
$r\mapsto((x'_r,e_r),(x'_r,e_rg_r))$ be a plot of $f^*E\times f^*E$ in the image of the action map. Then $r\mapsto(e_r,e_rg_r)$ is a plot of
$E\times E$ in the image of the action map of $E$, so $r\mapsto g_r$ is a plot of $G$. The quotient $f^*E/G\to X'$ is a bijection, and it is a
diffeomorphism because $f^*E\to X'$ is a subduction (pullback of a subduction).

(ii) Let $\phi\colon E\to E'$ be equivariant over $X$. It is bijective, being a bijection on each fibre (a $G$-torsor). To see that $\phi^{-1}$ is
smooth, let $r\mapsto e'_r$ be a plot of $E'$; near $r_0$ lift its projection to a plot $r\mapsto e_r$ of $E$. Then $\phi(e_r)$ and $e'_r$ lie in
the same fibre, so $e'_r=\phi(e_r)g_r$ with $g$ a plot of $G$ by principality of $E'$, and $\phi^{-1}(e'_r)=e_rg_r$ is a plot.

For the trivial bundle, an equivariant map over $X$ has the form $(x,g)\mapsto(x,\sigma(x)g)$, with $\sigma(x)$ the $G$-component of the image of
$(x,1)$; $\sigma$ is smooth iff the map is.
\end{solution}

\begin{exercise}[label=exo:Z-bundles]{3}
Classify the principal $\Z$-bundles over $\Tal$ and describe their total spaces.
\end{exercise}
\begin{solution}
By \cref{cor:bundles-TGamma}, classes are $H^1(\Lam_\alpha;\cinf(\R,\Z))=H^1(\Lam_\alpha;\Z)=\Hom(\Lam_\alpha,\Z)\cong\Z^2$, since a smooth map
$\R\to\Z$ is constant and $\Lam_\alpha$ acts trivially on constants. For $\rho\in\Hom(\Lam_\alpha,\Z)$ the bundle is
$E_\rho=(\R\times\Z)/\Lam_\alpha$ with $\lambda\cdot(x,k)=(x+\lambda,k+\rho(\lambda))$. If $\rho=0$ then $E_\rho=\Tal\times\Z$. If $\rho\neq0$,
its image is $d\Z$ for some $d\ge1$ and its kernel is infinite cyclic, generated by some $\mu\in\Lam_\alpha$. The components of $E_\rho$ are indexed
by $\Z/d$, and each is $\R/\ker\rho=\R/\mu\Z$, a circle of length $\abs\mu$. So the connected coverings of $\Tal$ with group $\Z$ are the
circles $\R/\mu\Z$, $\mu\in\Lam_\alpha$ primitive, on which the remaining generator of $\Lam_\alpha$ acts by an irrational rotation with quotient
$\Tal$. The irrational torus is a circle modulo an irrational rotation in a $\GL_2(\Z)$-worth of ways.
\end{solution}

\begin{exercise}[label=exo:fibrating]{4}
Prove \cref{prop:fibrating}.
\end{exercise}
\begin{solution}
Write $O=\Ob(\mathbf K)$, $M=\Mor(\mathbf K)$, $E=\mathrm{src}^{-1}(b)\subseteq M$ with the subspace diffeology, and $G=\mathbf K_b$ acting on $E$ by
$f\cdot g=f\circ g$.

\emph{Step 1: $\mathrm{trg}\colon E\to O$ is a subduction.} $E$ is the pullback of $\chi=(\mathrm{src},\mathrm{trg})\colon M\to O\times O$ along
$O\to O\times O$, $x\mapsto(b,x)$. Since $\mathbf K$ is fibrating, $\chi$ is a subduction, and subductions are stable under pullback
(\cref{prop:stability}).

\emph{Step 2: the action of $G$ on $E$ is principal with quotient $O$.} Two arrows $f,f'\in E$ have the same target iff $f'=f\circ g$ with
$g=f^{-1}\circ f'\in G$, so the fibres of $\mathrm{trg}|_E$ are the $G$-orbits and the action is free. If $r\mapsto(f_r,f'_r)$ is a plot of
$E\times E$ with equal targets, then $g_r=f_r^{-1}\circ f'_r$ is a plot of $M$, because inversion and composition are smooth in a diffeological
groupoid, with values in $G$; so it is a plot of $G$. Thus the action map is an induction, and $O\cong E/G$ by Step~1 and uniqueness of
quotients. By \cref{thm:principal}, $O\simeq E\hquot G$ in $\Hh$.

\emph{Step 3: the equivalence.} $|\mathbf K|$ is the colimit of the nerve of $\mathbf K$; the canonical map $p\colon O\to|\mathbf K|$ is an effective
epimorphism with $O\times_{|\mathbf K|}O\simeq M$. Consider the composite $\ast\xrightarrow{b}O\xrightarrow{p}|\mathbf K|$. Its pullback along $p$ is
$\ast\times_{|\mathbf K|}O\simeq\mathrm{src}^{-1}(b)=E$, mapping to $O$ by $\mathrm{trg}$, which is an effective epimorphism by Step~1. Effective
epimorphisms descend along the effective epimorphism $p$, so $\ast\to|\mathbf K|$ is an effective epimorphism. Its \v{C}ech nerve has
$\ast\times_{|\mathbf K|}\ast\simeq\mathrm{src}^{-1}(b)\cap\mathrm{trg}^{-1}(b)=G$ in degree $1$, so it is the nerve of $G$, and
$|\mathbf K|\simeq\colim G^k=\B G$.

\emph{Step 4: the classified bundle.} The principal bundle classified by $p\colon O\to|\mathbf K|\simeq\B G$ is the pullback of $\ast\to\B G$
along $p$, which by Step~3 is $E\to O$.
\end{solution}



\chapter{Models}\label{ch:models}

\begin{chapabstract}
Manifolds, manifolds with boundary and corners, orbifolds and quasifolds are all ``diffeological spaces locally diffeomorphic to a model''. We
review what the diffeology determines in each case, where it is the coarse space of a stack, and how much of it is determined by real-valued functions.
\end{chapabstract}
\source{\IZ{Chapter~4}, and \IZ{art.~1.78, 2.22} for dimension.}

\section{Modelling}

A \defn{local diffeomorphism} between diffeological spaces is a map that is, near each point of its source, a diffeomorphism from a D-open
subset onto a D-open subset \IZ{art.~2.5}. Given a class $\mathcal M$ of diffeological spaces, a space is \defn{modelled on $\mathcal M$} if every
point has a D-open neighbourhood diffeomorphic to a D-open subset of a member of $\mathcal M$ \IZ{art.~4.19}.

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{4.9cm}p{4.3cm}p{4.2cm}@{}}\toprule
models $\mathcal M$ & spaces modelled on $\mathcal M$ & reference\\\midrule
$\R^n$ & manifolds & \IZ{art.~4.1--4.3}\\
half-spaces $H^n=\R^{n-1}\times[0,\infty)$ & manifolds with boundary & \IZ{art.~4.12--4.16}\\
corners $\R^{n-k}\times[0,\infty)^k$ & manifolds with corners & \cite{GurerIZ}\\
$\R^n/\Gamma$, $\Gamma\subset\GL_n(\R)$ finite & orbifolds & \IZ{art.~4.17}, \cite{IKZ}\\
$\R^n/\Gamma$, $\Gamma$ countable, affine & quasifolds & \cite{IglesiasPrato}\\
diffeological vector spaces & diffeological manifolds, e.g.\ $S^\infty$ & \IZ{art.~4.7--4.9}\\\bottomrule
\end{tabular}
\caption{Classical and less classical geometries as modelled diffeological spaces. Half-spaces and corners carry the subspace diffeology of
$\R^n$; the quotients carry the quotient diffeology.}\label{tab:models}
\end{table}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\footnotesize]
  \begin{scope}
  \fill[hcsmist] (-0.9,-0.6) rectangle (0.9,0.6); \draw[hcsteal,dashed] (-0.9,-0.6) rectangle (0.9,0.6);
  \fill (0,0) circle (1.3pt); \node at (0,-1.0) {$\R^2$};
 \end{scope}
  \begin{scope}[xshift=2.6cm]
  \fill[hcsmist] (-0.9,0) rectangle (0.9,0.9); \draw[hcsteal,dashed] (-0.9,0)--(-0.9,0.9)--(0.9,0.9)--(0.9,0);
  \draw[hcsink,line width=1pt] (-0.9,0)--(0.9,0); \fill (0,0) circle (1.3pt); \node at (0,-1.0) {$H^2$};
 \end{scope}
  \begin{scope}[xshift=5.2cm]
  \fill[hcsmist] (-0.4,-0.4) rectangle (0.9,0.9); \draw[hcsteal,dashed] (-0.4,0.9)--(0.9,0.9)--(0.9,-0.4);
  \draw[hcsink,line width=1pt] (-0.4,0.9)--(-0.4,-0.4)--(0.9,-0.4); \fill (-0.4,-0.4) circle (1.3pt); \node at (0.2,-1.0) {corner};
 \end{scope}
  \begin{scope}[xshift=7.8cm]
  \fill[hcssand] (0,-0.55) -- (-0.8,0.6) arc (180:360:0.8 and 0.2) -- cycle;
  \draw[hcsgold] (0,-0.55) -- (-0.8,0.6); \draw[hcsgold] (0,-0.55) -- (0.8,0.6);
  \draw[hcsgold] (0,0.6) ellipse (0.8 and 0.2);
  \fill (0,-0.55) circle (1.3pt); \node at (0,-1.0) {$\R^2/\Z_n$};
 \end{scope}
  \begin{scope}[xshift=10.5cm]
  \draw[hcsgrey] (-1.0,0)--(1.0,0);
  \foreach \x in {-0.95,-0.81,-0.62,-0.47,-0.38,-0.19,-0.05,0.09,0.24,0.33,0.52,0.67,0.76,0.95} \fill[hcsrust] (\x,0) circle (1pt);
  \draw[hcsrust,->] (0,0.5) -- (0,0.12); \node[hcsrust] at (0,0.7) {dense orbit};
  \node at (0,-1.0) {$\R/\Lam_\alpha$};
 \end{scope}
\end{tikzpicture}
\caption{Five local models. The first three are subspaces of $\R^2$, the last two are quotients. Only the first is a manifold; all five are
diffeological spaces, and each is determined up to diffeomorphism by its plots.}\label{fig:models}
\end{figure}

\section{Manifolds, boundaries, corners}

A diffeological space is a manifold of dimension $n$ exactly when it is modelled on $\R^n$, and smooth maps between manifolds are the usual ones
(\cref{exo:manifold-atlas}). For manifolds with boundary there is something to prove, because the model $H^n$ is a subspace and its diffeology is
defined by plots \emph{into} it, while the classical notion of a smooth function \emph{on} it is ``restriction of a smooth function on $\R^n$''.

\begin{theorem}[\IZ{art.~4.13, 4.16}]\label{thm:halfspace}
A map $f\colon H^n\to\R$ is smooth for the subspace diffeology if and only if it is the restriction of a smooth function on an open neighbourhood
of $H^n$ in $\R^n$. Consequently manifolds with boundary, with their classical smooth maps, form a full subcategory of $\Diff$.
\end{theorem}
\noindent The essential case is $n=1$ and is \cref{exo:halfline-functions}; it rests on Whitney's theorem that a smooth even function of $t$ is a
smooth function of $t^2$ \cite{Whitney}. The same holds for corners \cite{GurerIZ}. In the language of \cref{sec:two-images}: the classical
definition of a manifold with boundary is in terms of its functions, the diffeological one in terms of its plots, and by Whitney's theorem, for
half-spaces the two descriptions determine each other; see \cref{sec:fn-vs-plots}.

\section{Orbifolds and quasifolds}

A diffeological \defn{orbifold} is a space modelled on quotients $\R^n/\Gamma$ by finite linear groups \cite{IKZ}. A priori the model is
only the orbit space. In fact it determines the group.

\begin{theorem}[Iglesias-Zemmour--Karshon--Zadka \cite{IKZ}; \IZ{art.~4.18}]\label{thm:IKZ}
Let $\Gamma,\Gamma'\subset\GL_n(\R)$ be finite subgroups. Every local diffeomorphism from $\R^n/\Gamma$ to $\R^n/\Gamma'$ sending $[0]$ to $[0]$ lifts to an
equivariant local diffeomorphism of $\R^n$ at $0$; in particular $\Gamma$ and $\Gamma'$ are conjugate in $\GL_n(\R)$. Hence the \defn{structure group} of
an orbifold at a point is a diffeological invariant.
\end{theorem}

\begin{corollary}\label{cor:manifold-point}
Let $\Gamma\subset\GL_n(\R)$ be a finite subgroup. The point $[0]\in\R^n/\Gamma$ has a neighbourhood diffeomorphic to an open subset of $\R^n$ if and only
if $\Gamma$ is trivial.
\end{corollary}

Note the contrast with topology and with algebraic geometry: $\R/\{\pm1\}$ is homeomorphic to a half-line, and $\C/\{\pm1\}$ is isomorphic to
$\C$ as a variety, but neither quotient is a diffeological manifold near the fixed point (\cref{exo:delta1-singular}).

In the trichotomy of \cref{thm:three-quotients}, with $X=\R^n$ and $G=\Gamma$, an orbifold chart has three incarnations: the stack
$\R^n\hquot\Gamma$ of the Lie-groupoid literature, the sheaf quotient, and the diffeological space $\R^n/\Gamma$. By \cref{thm:IKZ}, for
finite linear groups the last determines the first up to equivalence, locally. The determination is not functorial: the map from morphisms of
stacks to smooth maps of quotients is neither injective nor, on $2$-cells, defined; see \cite{WattsWolbert}. A diffeological
orbifold is a stack that is recoverable from its coarse space, in the way a reduced variety is recoverable from its points.

\defn{Quasifolds} relax ``finite'' to ``countable'' \cite{IglesiasPrato}. The irrational torus is the basic example, and
\cref{thm:linear-rigidity} is the corresponding rigidity statement: the diffeology of $\R^n/\Gamma$ determines $\Gamma$ up to $\GL_n(\R)$.

\section{Functions versus plots}\label{sec:fn-vs-plots}

A diffeology is a ``maps in'' structure. The older notions of Sikorski and Fr\"olicher are ``maps out'' structures, given by a ring of
real-valued functions. Each determines a candidate for the other: from plots one gets the functions that are smooth along all plots; from
functions one gets the parametrisations along which all functions are smooth. A diffeological space is \defn{reflexive} if it is recovered from its
functions in this way. Manifolds, half-spaces and corners are reflexive. The irrational torus is as far from reflexive as possible, since its only
smooth functions are constants; and $\dten_1=\R/\{\pm1\}$ is not reflexive either, since it has the same smooth functions as the half-line $H$ and
strictly fewer plots (\cref{prop:delta1}). This is developed as a Galois connection in \cref{thm:galois} of \cref{ch:ai}, and \cref{thm:reflexive} is the
equivalence of reflexive diffeological spaces with Fr\"olicher spaces \cite{BIKW}. The point for now is the slogan of \cite{IZ}: \emph{function-based
smooth structures miss the singular quotients}, and the reason is that a quotient is a colimit, and maps \emph{out} of a colimit are easy while maps
\emph{in} are the content.

\section{Infinite dimensions and dimension}

On the other side of $\Mfd$, the functional diffeology is compatible with the classical infinite-dimensional theories where these exist. Banach
manifolds embed fully faithfully in $\Diff$ \IZ{Exercise~72}; so do Fr\'echet manifolds \cite{Losik}; and for a compact manifold $M$ the
functional diffeology on $\cinf(M,N)$ is the diffeology of its Fr\'echet manifold structure \cite{KrieglMichor,Waldorf}. In contrast with those theories,
in $\Diff$ no topology on a function space is required to define a smooth curve in it: \cref{thm:ccc} is the definition.

Finally, a diffeological space has a \defn{dimension} at each point: the smallest $d$ such that the germ of the diffeology at the point is
generated by plots with domains of dimension at most $d$ \IZ{art.~1.78, 2.22}. It is a local invariant, equal to $n$ for an $n$-manifold, and
\IZ{Exercises~50--51} compute
\[
\dim_{[0]}\bigl(\R^n/\Ort(n)\bigr)=n,\qquad\dim_0\bigl([0,\infty)_{\Sub}\bigr)=\infty .
\]
So the spaces $\dten_n$, all homeomorphic to a half-line and all with the same ring of smooth functions, are pairwise non-diffeomorphic, and none
is diffeomorphic to the half-line $H$. We will use this in Chapters~\ref{ch:ml} and~\ref{ch:systems} as a supply of systems with identical observable
behaviour and inequivalent state spaces.

\exercisesheading

\begin{exercise}[label=exo:sqrt]{1}
Show that $x\mapsto\sqrt x$ is a D-continuous function on $H=[0,\infty)_{\Sub}$ that is not smooth.
\end{exercise}
\begin{solution}
It is continuous for the usual topology of $H$, and plots of $H$ are continuous, so it is D-continuous. The parametrisation $t\mapsto t^2$ is a plot
of $H$, and its composite with the square root is $t\mapsto\abs t$, not smooth at $0$.
\end{solution}

\begin{exercise}[label=exo:halfline-functions]{2}
Prove the case $n=1$ of \cref{thm:halfspace}: $f\colon H\to\R$ is smooth iff $f=g|_H$ for some $g\in\cinf(\R)$. Deduce that $\cinf(\dten_1)\cong\cinf(H)$.
\end{exercise}
\begin{solution}
If $g$ is smooth on $\R$ and $P$ is a plot of $H$, then $P$ is smooth into $\R$ and $g\circ P$ is smooth. Conversely let $f$ be smooth on $H$. The plot
$t\mapsto t^2$ gives a smooth even function $e(t)=f(t^2)$, so by Whitney's theorem $e(t)=g(t^2)$ with $g\in\cinf(\R)$, and then $f(x)=g(x)$ for all
$x\ge0$. For the second claim: a smooth function on $\dten_1$ is the same as a smooth even function on $\R$ (quotient), hence of the form
$g(x^2)$, hence $g|_H\circ\mathrm{sq}$; so $\mathrm{sq}^*\colon\cinf(H)\to\cinf(\dten_1)$ is a bijection. The two spaces have the same functions and, by
\cref{prop:delta1}, different plots.
\end{solution}

\begin{exercise}[label=exo:delta1-singular]{3}
Show that $[0]\in\dten_1=\R/\{\pm1\}$ has no D-open neighbourhood diffeomorphic to an open interval. Deduce that every diffeomorphism of $\dten_1$
fixes $[0]$.
\end{exercise}
\begin{solution}
Suppose $\psi\colon J\to W$ is a diffeomorphism from an open interval onto a D-open neighbourhood $W$ of $[0]$, and let $\psi(t_0)=[0]$. As a plot of
$\dten_1$, $\psi$ lifts near $t_0$ to a smooth $f\colon J'\to\R$ with $\pi\circ f=\psi$ and $f(t_0)=0$. Since $\psi$ is injective, so is $f$; a
continuous injective function on an interval is strictly monotone, so $f(J')$ is an open interval containing $0$, and therefore contains both
$x$ and $-x$ for small $x\ne0$. But $\pi(x)=\pi(-x)$, contradicting injectivity of $\psi=\pi\circ f$. Every other point $[a]$, $a>0$, does have
such a neighbourhood, namely $\pi((a/2,2a))$, on which $\pi$ restricts to a diffeomorphism. A diffeomorphism of $\dten_1$ preserves the set of
points with a neighbourhood diffeomorphic to an interval, so it fixes the unique point without one.
\end{solution}

\begin{exercise}[label=exo:cone-hilbert]{3}
Let $\{\pm1\}$ act on $\R^2=\C$ and let $\sigma\colon\C\to\R^3$, $\sigma(z)=(\abs z^2,\mathrm{Re}\,z^2,\mathrm{Im}\,z^2)$, with image the half-cone
$S=\set{(u,v,w) : u=\sqrt{v^2+w^2}}$. Show that the induced bijection $\bar\sigma\colon\C/\{\pm1\}\to S_{\Sub}$ is smooth but not a diffeomorphism.
\end{exercise}
\begin{solution}
$\sigma$ is smooth, invariant, and separates orbits because $z^2$ determines $\pm z$; so $\bar\sigma$ is a smooth bijection onto $S$. Consider
\[
P(r,s)=\bigl(\abs z\,e^{-1/\abs z^2},\ \mathrm{Re}\,(z\,e^{-1/\abs z^2}),\ \mathrm{Im}\,(z\,e^{-1/\abs z^2})\bigr),\qquad z=r+is,\quad P(0)=0 .
\]
The function $e^{-1/\abs z^2}$ is smooth and flat at $0$, and the product of a flat function with $\abs z$ is smooth; so $P$ is a smooth map into
$\R^3$, with values in $S$: a plot of $S_{\Sub}$. If $\bar\sigma^{-1}\circ P$ were a plot of the quotient, there would be a disc $V\ni0$ and a smooth
$\zeta\colon V\to\C$ with $\zeta^2=z\,e^{-1/\abs z^2}$ on $V$. On a small circle around $0$ the right-hand side has winding number $1$ about the
origin, while $\zeta^2$ has even winding number. So no continuous $\zeta$ exists even on $V\smallsetminus\{0\}$. Thus $S_{\Sub}$ has a plot that the
orbifold $\C/\{\pm1\}$ lacks: the image of the invariant-theoretic embedding has strictly more plots than the orbit space.
\end{solution}

\begin{exercise}[label=exo:manifold-atlas]{4}
Let $X$ be a diffeological space modelled on $\R^n$. Prove that the local diffeomorphisms from open subsets of $\R^n$ to $X$ form a smooth atlas
in the classical sense, that the diffeology of $X$ is the diffeology of smooth parametrisations for this atlas, and that a map between two such
spaces is smooth iff it is smooth in charts.
\end{exercise}
\begin{solution}
Call a \emph{chart} a diffeomorphism $\phi\colon U\to\phi(U)$ from a domain $U\subseteq\R^n$ onto a D-open subset of $X$ with the subspace diffeology.
By hypothesis the images of charts cover $X$.

\emph{Transition maps.} Let $\phi,\psi$ be charts and $W=\phi(U)\cap\psi(V)$, which is D-open. Then $\phi^{-1}(W)$ and $\psi^{-1}(W)$ are open, because
charts are plots and plots are D-continuous, and $\psi^{-1}\circ\phi\colon\phi^{-1}(W)\to\psi^{-1}(W)$ is a composite of smooth maps of diffeological
spaces, with inverse $\phi^{-1}\circ\psi$. A smooth map between domains in the diffeological sense is an ordinary smooth map (\cref{rem:yoneda}). So the
transition maps are classical diffeomorphisms between open subsets of $\R^n$; the charts are homeomorphisms onto their images for the D-topology by the
same argument; and we have a classical atlas on the topological space $D(X)$.

\emph{The diffeology.} Let $P\colon O\to X$ be a parametrisation. If $P$ is a plot and $r_0\in O$, choose a chart $\phi$ around $P(r_0)$;
$P^{-1}(\phi(U))$ is an open neighbourhood of $r_0$ on which $\phi^{-1}\circ P$ is a plot of $U$, i.e.\ smooth. So $P$ is smooth in charts.
Conversely if $P$ is continuous and smooth in charts, then locally $P=\phi\circ(\phi^{-1}\circ P)$ is a plot composed with a smooth map, hence a plot,
and $P$ is a plot by \ref{D2}.

\emph{Maps.} Let $f\colon X\to Y$ be a map between two such spaces. If $f$ is smooth then it is D-continuous and, for charts $\phi$ of $X$ and $\psi$ of
$Y$, $\psi^{-1}\circ f\circ\phi$ is a smooth map of diffeological spaces between domains wherever defined, hence classically smooth. Conversely if
$f$ is continuous and smooth in charts, then for a plot $P$ of $X$ the parametrisation $f\circ P$ is continuous and smooth in charts of $Y$, hence a plot by the
previous paragraph.

Classical manifolds also require the topology to be Hausdorff and paracompact; these are conditions on $D(X)$ that are
optional in the diffeological definition.
\end{solution}


\part{Applications}

\chapter{Number theory: the arithmetic of irrational tori}\label{ch:number-theory}
\chaptermark{Number theory}

\begin{chapabstract}
The diffeological space $\Tal=\R/(\Z+\alpha\Z)$ is a point for topology and for smooth functions. We show that its plots nevertheless read off
three layers of the arithmetic of $\alpha$: its orbit under $\GL_2(\Z)$, that is, the tail of its continued fraction; the unit group of the
quadratic order it generates, if any; and its Diophantine type. Each layer is a theorem about a different functor on $\Hh$ --- $\Hom$, $\Dif$, and
$\Map(-,\B\R)$ --- applied to the same object.
\end{chapabstract}
\source{\IZ{Exercises~4, 5, 105, 119, 134} and \IZ{art.~8.38--8.39}. The classification is due to Donato and Iglesias \cite{DonatoIglesias}, the
number-field generalisation to Iglesias and Lachaud \cite{IglesiasLachaud}, and the theory of flows over $\Tal$ to Iglesias-Zemmour
\cite{IZthesis,IZsmall,IZarith}.}

\section{Rigidity}

Throughout, a \defn{quasi-torus} is a quotient $T_\Gamma=\R^n/\Gamma$ of $\R^n$ by a countable subgroup, with the quotient diffeology. By
\cref{cor:TGamma} the projection $q\colon\R^n\to T_\Gamma$ is the universal covering, a principal bundle for the discrete group $\Gamma$.

\begin{theorem}[Linear rigidity of quasi-tori; after \cite{DonatoIglesias,IglesiasLachaud}]\label{thm:linear-rigidity}
Let $\Gamma\subset\R^n$ and $\Gamma'\subset\R^m$ be countable subgroups, and assume that $\Gamma$ spans $\R^n$. Let $f\colon T_\Gamma\to T_{\Gamma'}$ be smooth.
\begin{enumerate}[label=\textup{(\alph*)}]
\item There are a smooth $F\colon\R^n\to\R^m$ with $q'\circ F=f\circ q$, unique up to a constant in $\Gamma'$, and a unique linear map
$A\colon\R^n\to\R^m$, such that
\[
F(x+\gamma)=F(x)+A\gamma\qquad(x\in\R^n,\ \gamma\in\Gamma).
\]
In particular $A\Gamma\subseteq\Gamma'$, and $F-A$ is bounded.
\item If $\Gamma$ is dense in $\R^n$ then $F$ is affine: $F(x)=Ax+c$.
\item If $\Gamma'$ spans $\R^m$ and $f$ is a diffeomorphism, then $n=m$, $A\in\GL_n(\R)$ and $A\Gamma=\Gamma'$.
\end{enumerate}
Consequently two quasi-tori with spanning groups are diffeomorphic if and only if the groups are linearly equivalent:
\[
\R^n/\Gamma\cong\R^n/\Gamma'\iff\Gamma'=A\Gamma\ \text{ for some }A\in\GL_n(\R).
\]
\end{theorem}
\begin{proof}
(a) \emph{Lifting.} The composite $f\circ q$ is a plot of $T_{\Gamma'}$ with simply connected domain, so it lifts through $q'$ to a smooth $F$, unique
up to a constant of $\Gamma'$; this is the argument of \cref{exo:higher-TGamma}. \emph{The homomorphism.} For $\gamma\in\Gamma$, the map
$x\mapsto F(x+\gamma)-F(x)$ is continuous with values in the countable set $\Gamma'$, because both terms lift $f\circ q$. So it is a constant
$\phi(\gamma)$, and $\phi\colon\Gamma\to\Gamma'$ is a homomorphism. \emph{Linearity.} Choose $\gamma_1,\dots,\gamma_n\in\Gamma$ forming a basis of
$\R^n$ and let $A$ be the linear map with $A\gamma_i=\phi(\gamma_i)$. The function $G=F-A$ is invariant under the lattice
$L=\bigoplus\Z\gamma_i$, hence bounded. For $\gamma\in\Gamma$ and $k\in\Z$,
\[
G(x+k\gamma)-G(x)=k\bigl(\phi(\gamma)-A\gamma\bigr),
\]
and the left side is bounded in $k$; so $\phi(\gamma)=A\gamma$. Uniqueness of $A$ is clear since $\Gamma$ spans.

(b) $G=F-A$ is continuous and invariant under the dense subgroup $\Gamma$, hence constant.

(c) Apply (a) to $f^{-1}$ to get $F'$ and $A'$. Then $F'\circ F$ lifts the identity of $T_\Gamma$, so $F'(F(x))=x+\gamma_0$, and comparing the
effect of translating $x$ by $\gamma\in\Gamma$ gives $A'A\gamma=\gamma$. As $\Gamma$ spans, $A'A=\id$; symmetrically $AA'=\id$. So $n=m$, and
$A\Gamma\subseteq\Gamma'$, $A'\Gamma'\subseteq\Gamma$ give $A\Gamma=\Gamma'$. Conversely a linear isomorphism with $A\Gamma=\Gamma'$ descends to a
diffeomorphism, with inverse induced by $A^{-1}$.
\end{proof}

For $\Gamma$ a lattice the theorem recovers the familiar fact that all $n$-tori are diffeomorphic, all lattices in $\R^n$ being linearly
equivalent. Its force is in rank greater than $n$, where the quotient determines the position of $\Gamma$ in $\R^n$ exactly up to
$\GL_n(\R)$. In rank $2$ and dimension $1$:

\begin{corollary}[Donato--Iglesias \cite{DonatoIglesias}; \IZ{Exercise~4}]\label{cor:DI}
Let $\alpha,\beta$ be irrational.
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\cinf(\Tal,T_\beta)\cong\set{\lambda\in\R : \lambda\Lam_\alpha\subseteq\Lam_\beta}\times T_\beta$, a smooth map being $[x]\mapsto[\lambda x+c]$.
\item $\Tal\cong T_\beta$ if and only if $\alpha=\dfrac{a\beta+b}{c\beta+d}$ for some $\begin{pmatrix}a&b\\c&d\end{pmatrix}\in\GL_2(\Z)$.
\item \textup{(Serret; \cite[Thm.~175]{HardyWright})} Equivalently: the continued fraction expansions of $\alpha$ and $\beta$ eventually coincide, up to a shift.
\end{enumerate}
\end{corollary}
\begin{proof}
(i) is \cref{thm:linear-rigidity}(a),(b) with $n=m=1$. (ii) By (c), $\Tal\cong T_\beta$ iff $\lambda\Lam_\alpha=\Lam_\beta$ for some
$\lambda\ne0$, iff $(\lambda,\lambda\alpha)$ is a $\Z$-basis of $\Z+\beta\Z$, iff $\lambda=c\beta+d$ and $\lambda\alpha=a\beta+b$ with
$ad-bc=\pm1$.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small,
  cf/.style={draw=hcsteal,fill=hcsmist,minimum width=5.2mm,minimum height=5.2mm,inner sep=0pt,font=\footnotesize},
  pre/.style={draw=hcsgrey,fill=white,minimum width=5.2mm,minimum height=5.2mm,inner sep=0pt,font=\footnotesize},
  alt/.style={draw=hcsgold,fill=hcssand,minimum width=5.2mm,minimum height=5.2mm,inner sep=0pt,font=\footnotesize}]
  \node[anchor=east] at (-0.2,0) {$\sqrt2$}; \node[pre] at (0.3,0) {1}; \foreach \i in {1,...,7} \node[cf] at (0.3+0.55*\i,0) {2};
  \node[anchor=east] at (-0.2,-0.7) {$1+\sqrt2$}; \foreach \i in {0,...,7} \node[cf] at (0.3+0.55*\i,-0.7) {2};
  \node[anchor=east] at (-0.2,-1.4) {$1/\sqrt2$}; \node[pre] at (0.3,-1.4) {0}; \node[pre] at (0.85,-1.4) {1}; \foreach \i in {2,...,7} \node[cf] at (0.3+0.55*\i,-1.4) {2};
  \node[anchor=west,hcsteal,font=\footnotesize] at (4.7,-0.7) {one diffeomorphism class};
  \node[anchor=east] at (-0.2,-2.4) {$\sqrt{10}$}; \node[pre] at (0.3,-2.4) {3}; \foreach \i in {1,...,7} \node[cf] at (0.3+0.55*\i,-2.4) {6};
  \node[anchor=east] at (-0.2,-3.1) {$\sqrt{10}/2$}; \node[pre] at (0.3,-3.1) {1};
     \foreach \i/\v in {1/1,2/1,3/2,4/1,5/1,6/2,7/1} \node[alt] at (0.3+0.55*\i,-3.1) {\v};
  \node[anchor=west,hcsrust,font=\footnotesize,align=left] at (4.7,-2.75) {two classes, same field,\\ same endomorphism ring};
\end{tikzpicture}
\caption{Continued fractions as diffeological invariants. Tori whose expansions have a common tail are diffeomorphic (\cref{cor:DI}). The last two rows
are the two classes with real multiplication by $\Z[\sqrt{10}]$, an order of class number~$2$ (\cref{exo:sqrt10}).}\label{fig:cf}
\end{figure}

\section{Endomorphisms, units, and real multiplication}

For irrational $\alpha$ put
\[
\mathcal O_\alpha=\set{\lambda\in\R : \lambda\Lam_\alpha\subseteq\Lam_\alpha},
\]
a subring of $\R$. By \cref{cor:DI}(i) it is the ring of smooth endomorphisms of the group $\Tal$, and also the monoid of smooth self-maps
fixing $0$: on an irrational torus every smooth map is a homomorphism up to translation.

\begin{theorem}[Endomorphisms and diffeomorphisms; after \cite{DonatoIglesias}]\label{thm:units}
\begin{enumerate}[label=\textup{(\roman*)}]
\item If $\alpha$ is not a quadratic irrational, $\mathcal O_\alpha=\Z$.
\item If $A\alpha^2+B\alpha+C=0$ with $A,B,C$ coprime integers and $D=B^2-4AC$, then $\mathcal O_\alpha=\Z+\Z A\alpha$ is the order of discriminant
$D$ in the real quadratic field $\Q(\sqrt D)$.
\item $\Dif(\Tal)\cong\Tal\rtimes\mathcal O_\alpha^\times$ as diffeological groups, with $\mathcal O_\alpha^\times$ discrete. Hence the identity
component of $\Dif(\Tal)$ is the group of translations and
\[
\pi_0\Dif(\Tal)\cong\mathcal O_\alpha^\times\cong\begin{cases}\{\pm1\}&\alpha\text{ not quadratic,}\\ \{\pm1\}\times\Z&\alpha\text{ quadratic.}\end{cases}
\]
\end{enumerate}
\end{theorem}
\begin{proof}
Let $\lambda\in\mathcal O_\alpha$. Then $\lambda=\lambda\cdot1\in\Lam_\alpha$, say $\lambda=x+y\alpha$ with $x,y\in\Z$, and
$\lambda\alpha=x\alpha+y\alpha^2\in\Lam_\alpha$ iff $y\alpha^2\in\Z+\Z\alpha$.

(i) If $y\ne0$ this makes $\alpha$ quadratic. So $y=0$ and $\lambda\in\Z$.

(ii) Here $y\alpha^2=-y(B\alpha+C)/A$, and since $1,\alpha$ are linearly independent over $\Q$ this lies in $\Z+\Z\alpha$ iff $A\mid yB$ and
$A\mid yC$, iff $A\mid y\gcd(B,C)$, iff $A\mid y$ because $\gcd(A,B,C)=1$. So $\mathcal O_\alpha=\Z+\Z A\alpha$. The number $A\alpha$ is a root of
$t^2+Bt+AC$, an algebraic integer of discriminant $D$, so $\Z[A\alpha]$ is the order of discriminant $D$.

(iii) By \cref{cor:DI}(i) every smooth self-map is $[x]\mapsto[\lambda x+c]$ with $\lambda\in\mathcal O_\alpha$, and it is invertible iff
$\lambda\in\mathcal O_\alpha^\times$. This gives the group isomorphism. For the diffeology, let $r\mapsto f_r$ be a plot of $\Dif(\Tal)$ on a ball
$V$. Then $(r,x)\mapsto f_r(q_\alpha(x))$ is a plot of $\Tal$ on the simply connected $V\times\R$; it lifts to a smooth
$F(r,x)=\lambda(r)x+c(r)$, and $\lambda=\partial_xF$ is continuous with values in a countable set, hence constant, while $c$ is smooth.
Conversely such families are plots. So $\Dif(\Tal)\cong\Tal\times\mathcal O_\alpha^\times$ as diffeological spaces with the second factor
discrete, and $\Tal$ is connected. Finally the unit group of an order in a real quadratic field is $\{\pm\varepsilon^k\}$ for a fundamental unit
$\varepsilon>1$, by Dirichlet's unit theorem; equivalently by the solvability of Pell's equation.
\end{proof}

A torus $\Tal$ with $\alpha$ quadratic is said to have \defn{real multiplication} by $\mathcal O_\alpha$, by analogy with complex multiplication of
elliptic curves $\C/\Lam$; the analogy is Manin's \cite{Manin}, and is developed in \cref{ch:crypto}. Geometrically: a quadratic
irrational torus has a hyperbolic symmetry --- multiplication by $\varepsilon$ --- not isotopic to $\pm\id$, and a non-quadratic one has none.

\begin{example}\label{ex:units}
\begin{enumerate}[label=(\alph*)]
\item $\alpha=\varphi=(1+\sqrt5)/2$: $\mathcal O=\Z[\varphi]$, $\varepsilon=\varphi$. On $\pi_1(T_\varphi)=\Z\oplus\Z\varphi$ multiplication by $\varphi$ is
the matrix $\begin{psmallmatrix}0&1\\1&1\end{psmallmatrix}$, and $\varphi^k$ acts by Fibonacci numbers (\cref{exo:golden}).
\item $\alpha=\sqrt2$: $\mathcal O=\Z[\sqrt2]$, $\varepsilon=1+\sqrt2$.
\item $\alpha=\sqrt{79}$: $\mathcal O=\Z[\sqrt{79}]$, $\varepsilon=80+9\sqrt{79}\approx160$. The smallest non-trivial symmetry of $T_{\sqrt{79}}$
stretches by a factor of $160$.
\item $\alpha=\sqrt[3]2$ or $\alpha=\pi$: $\pi_0\Dif(\Tal)=\{\pm1\}$.
\end{enumerate}
\end{example}

\begin{proposition}[Number fields, after \cite{IglesiasLachaud}]\label{prop:number-fields}
Let $K\subset\R$ be a number field of degree $d\ge2$ with $r_1$ real and $r_2$ pairs of complex embeddings, and let $\mathcal O\subset K$ be an order.
Then $T_{\mathcal O}=\R/\mathcal O$ is a one-dimensional diffeological group with
\[
\Pi\,T_{\mathcal O}\simeq\B\Z^d,\qquad\End(T_{\mathcal O})\cong\mathcal O,\qquad\pi_0\Dif(T_{\mathcal O})\cong\mathcal O^\times\cong\{\pm1\}\times\Z^{\,r_1+r_2-1}.
\]
\end{proposition}
\begin{proof}
$\mathcal O$ is free of rank $d\ge2$, hence dense in $\R$, and countable. The shape is \cref{cor:TGamma}. By \cref{thm:linear-rigidity}(b) smooth
self-maps are $[x]\mapsto[\lambda x+c]$ with $\lambda\mathcal O\subseteq\mathcal O$; since $1\in\mathcal O$ this means $\lambda\in\mathcal O$. The
argument of \cref{thm:units}(iii) gives $\pi_0\Dif=\mathcal O^\times$, and Dirichlet's theorem gives its structure, the only roots of unity in a
real field being $\pm1$.
\end{proof}

So the unit rank of a number field with a real place is the rank of the mapping class group of a one-dimensional diffeological space, and the
degree of the field is the rank of its fundamental group. Neither is determined by the D-topology or by the smooth real functions of $\R/\mathcal O$.

\section{Diophantine type and principal \texorpdfstring{$\R$}{R}-bundles}\label{sec:Fl}

We now compute the first obstruction group of \cref{thm:dR-obstruction}, the group $\Fl(\Tal)=H^1(\Tal;\R)$ of isomorphism classes of principal
$\R$-bundles. Write $\norm t$ for the distance from $t\in\R$ to the nearest integer. An irrational $\alpha$ is \defn{Diophantine} if there are
$c>0$ and $\tau\ge1$ with $\norm{n\alpha}\ge c\,\abs n^{-\tau}$ for all $n\ne0$, and \defn{Liouville} otherwise. Almost every real number is
Diophantine, and so is every algebraic irrational, by Liouville's theorem.

\begin{lemma}[The cohomological equation on the line]\label{lem:coboundary-line}
For every $g\in\cinf(\R)$ there is $f\in\cinf(\R)$ with $f(x+1)-f(x)=g(x)$, and $f$ is unique up to a $1$-periodic function. The same holds for
differential forms on $\R$. Hence $H^1(\Z;\Om^p(\R))=0$ and $H^0(\Z;\Om^p(\R))=\Om^p(S^1)$ for the translation action.
\end{lemma}
\begin{proof}
Let $\chi$ be smooth with $\chi=0$ on $(-\infty,0]$ and $\chi=1$ on $[1,\infty)$, and split $g=g_++g_-$ with $g_+=\chi g$ supported in
$[0,\infty)$ and $g_-=(1-\chi)g$ supported in $(-\infty,1]$. Put
\[
f_+(x)=\sum_{k\ge1}g_+(x-k),\qquad f_-(x)=-\sum_{k\ge0}g_-(x+k).
\]
Both sums are locally finite, so $f_\pm$ are smooth, and telescoping gives $f_\pm(x+1)-f_\pm(x)=g_\pm(x)$. Take $f=f_++f_-$. Two solutions differ by
a periodic function. For a $1$-form $g\,\dd x$ use $f\,\dd x$.
\end{proof}

\begin{theorem}[Flows over the irrational torus; Iglesias-Zemmour \cite{IZsmall,IZarith}, \IZ{art.~8.39}]\label{thm:Fl}
Let $\rho_\alpha$ be the rotation $x\mapsto x+\alpha$ of $S^1=\R/\Z$. Then
\[
\Fl(\Tal)\;\cong\;H^1\bigl(\Lam_\alpha;\cinf(\R)\bigr)\;\cong\;\cinf(S^1)\big/(\rho_\alpha^*-1)\,\cinf(S^1)\;=\;\R\,\oplus\,\frac{\cinf_0(S^1)}{(\rho_\alpha^*-1)\cinf(S^1)},
\]
where $\cinf_0$ denotes functions of mean zero and the summand $\R$ is the mean. Moreover:
\begin{enumerate}[label=\textup{(\roman*)}]
\item the summand $\R$ is the group $E_2^{0,1}$ of flat bundles of \cref{prop:E2-Talpha}, and consists of the Kronecker bundle $T^2\to\Tal$ with its
flow run at all constant speeds;
\item the second summand is zero if and only if $\alpha$ is Diophantine;
\item if $\alpha$ is Liouville, the second summand is an infinite-dimensional real vector space.
\end{enumerate}
The automorphism group of every principal $\R$-bundle over $\Tal$ is $\R$.
\end{theorem}
\begin{proof}
\emph{Reduction to group cohomology.} By \cref{cor:bundles-TGamma} with $G=\R$, $\Map(\Tal,\B\R)\simeq(\B\cinf(\R))^{h\Lam_\alpha}$, whose set of
components is $H^1(\Lam_\alpha;\cinf(\R))$ and whose automorphism groups are $H^0(\Lam_\alpha;\cinf(\R))$, the $\Lam_\alpha$-periodic smooth functions,
which are constant. Splitting $\Lam_\alpha=\Z\oplus\Z\alpha$ and using \cref{lem:coboundary-line} for the first factor, the
Lyndon--Hochschild--Serre sequence collapses to $H^1(\Lam_\alpha;\cinf(\R))\cong H^1(\Z\alpha;\cinf(S^1))=\cinf(S^1)/(\rho_\alpha^*-1)$; an elementary
proof is \cref{exo:LHS}. Under this isomorphism a function $g$ corresponds to the cocycle $\tau(m+n\alpha)=\sum_{k=0}^{n-1}g\circ\rho_\alpha^k$ for
$n\ge0$.

\emph{Fourier analysis.} Write $g=\sum_n\hat g_ne^{2\pi inx}$. Then $g=f\circ\rho_\alpha-f$ iff $\hat g_n=(e^{2\pi in\alpha}-1)\hat f_n$ for all $n$. So
a coboundary has $\hat g_0=0$, and for $g$ of mean zero the only candidate is
\[
\hat f_n=\frac{\hat g_n}{e^{2\pi in\alpha}-1}\quad(n\ne0),\qquad 4\norm{n\alpha}\le\abs{e^{2\pi in\alpha}-1}=2\abs{\sin\pi n\alpha}\le2\pi\norm{n\alpha}.
\]
(i) The constant $g=c$ gives $\tau(m+n\alpha)=nc$, the flat bundle $X_\rho$ with holonomy $\rho(m+n\alpha)=nc$; for $c=-1$ this is the Kronecker
bundle by \cref{exo:kronecker-class}, and it is not a coboundary since its mean is not zero.

(ii) If $\norm{n\alpha}\ge c\abs n^{-\tau}$, then $\abs{\hat f_n}\le\abs n^\tau\abs{\hat g_n}/4c$ is rapidly decreasing whenever $\hat g_n$ is, so
every smooth $g$ of mean zero is a coboundary.

(iii) If $\alpha$ is Liouville then for each $k$ there are infinitely many $n$ with $\norm{n\alpha}<n^{-k}$: otherwise the finitely many exceptions
could be absorbed into the constant $c$ and $\alpha$ would be Diophantine with exponent $k$. Choose $n_1<n_2<\cdots$ with
$c_j:=\norm{n_j\alpha}<n_j^{-j}$ and let
\[
g(x)=\sum_j2c_j\cos(2\pi n_jx).
\]
For every $k$, $n_j^kc_j<n_j^{k-j}\to0$, so $g$ is smooth, real, of mean zero. Its formal primitive has
$\abs{\hat f_{n_j}}\ge c_j/(2\pi\norm{n_j\alpha})=1/2\pi$, which does not tend to zero; so there is no smooth $f$, indeed no integrable one.
Splitting $(n_j)$ into infinitely many disjoint infinite subsequences gives functions $g_1,g_2,\dots$ of this kind with disjoint spectra, and any
non-trivial finite combination $\sum a_ig_i$ has a formal primitive with coefficients of modulus at least $\abs{a_i}/2\pi$ along the $i$-th
subsequence. So the classes $[g_i]$ are linearly independent.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}
\begin{loglogaxis}[width=11.2cm,height=6.0cm,xmin=0.7,xmax=3e6,ymin=1e-19,ymax=3,
   xlabel={$n$},ylabel={$\norm{n\alpha}$},tick label style={font=\footnotesize},label style={font=\small},
   legend style={font=\footnotesize,at={(0.5,-0.24)},anchor=north,draw=hcsgrey},legend cell align=left,
   axis line style={hcsgrey},grid=major,grid style={hcsgrey!25}]
 \addplot[hcsteal,mark=*,mark size=1.3pt,line width=0.6pt] coordinates {(1,3.820e-01) (2,2.361e-01) (3,1.459e-01) (5,9.017e-02) (8,5.573e-02)
  (13,3.444e-02) (21,2.129e-02) (34,1.316e-02) (55,8.131e-03) (89,5.025e-03) (144,3.106e-03) (233,1.919e-03) (377,1.186e-03) (610,7.331e-04)
  (987,4.531e-04) (1597,2.800e-04) (2584,1.731e-04) (4181,1.070e-04) (6765,6.611e-05) (10946,4.086e-05) (17711,2.525e-05) (28657,1.561e-05)
  (46368,9.645e-06) (75025,5.961e-06) (121393,3.684e-06) (196418,2.277e-06) (317811,1.407e-06) (514229,8.697e-07) (832040,5.375e-07)};
 \addlegendentry{$\alpha=(1+\sqrt5)/2$: successive minima, $\norm{n\alpha}\sim1/(\sqrt5\,n)$}
 \addplot[hcsrust,mark=square*,mark size=1.6pt,line width=0.6pt] coordinates {(1,0.110001) (9,0.009991) (100,1e-4) (9909,9.1e-5) (10009,9e-6) (109999,1e-6) (1000000,1e-18)};
 \addlegendentry{$\alpha=\sum_k10^{-k!}$: successive minima}
 \addplot[hcsgrey,dashed,domain=1:2e6,samples=2] {1/x};
 \addlegendentry{$1/n$}
\end{loglogaxis}
\end{tikzpicture}
\caption{Small divisors. For the golden ratio the successive minima of $\norm{n\alpha}$ stay within a bounded factor of $1/n$: every mean-zero cocycle is a coboundary
and $\Fl(\Tal)=\R$. For Liouville's constant the minima drop abruptly at $n=10^{k!}$; Fourier modes placed at those frequencies give principal
$\R$-bundles over $\Tal$ that are not multiples of the Kronecker bundle. The data are exact computations.}\label{fig:small-divisors}
\end{figure}

\begin{corollary}\label{cor:Fl-algebraic}
If $\alpha$ is an algebraic irrational --- in particular if $\Tal$ has real multiplication --- then $\Fl(\Tal)\cong\R$: every principal $\R$-bundle over
$\Tal$ is trivial or isomorphic to the Kronecker bundle with a rescaled flow.
\end{corollary}

\section{Summary of invariants}

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{4.3cm}p{4.9cm}p{4.2cm}@{}}\toprule
invariant of $\Tal$ & value & dependence on $\alpha$\\\midrule
D-topology; $\cinf(\Tal,\R)$ & indiscrete; $\R$ & none\\
shape $\Pi\Tal$ & $\B\Z^2$ & none\\
$H^\bullet_{\dR}$; $E_2$ page & $(\R,\R,0)$; $H^\bullet(T^2)$ & none\\
diffeomorphism type & $\GL_2(\Z)\cdot\alpha$ & tail of the continued fraction\\
$\End(\Tal)$ & $\mathcal O_\alpha$ & quadratic or not; the order\\
$\pi_0\Dif(\Tal)$ & $\mathcal O_\alpha^\times$ & fundamental unit, regulator\\
$\Fl(\Tal)=H^1(\Tal;\R)$ & $\cinf(S^1)/(\rho_\alpha^*-1)$ & Diophantine or Liouville\\
classes with given $\End$ & $\Pic(\mathcal O)$ (\cref{thm:class-torsor}) & class number\\\bottomrule
\end{tabular}
\caption{The irrational torus as an arithmetic object. The first three rows are independent of $\alpha$; the rest depend on the smooth structure
beyond its shape. Every row is a functor on $\Hh$ evaluated at one object.}\label{tab:invariants}
\end{table}

The chapter is summarised in \cref{tab:invariants}. Continued fractions, Pell's equation and small divisors are classical; $\Tal$ is a single
geometric object of which they are all invariants, in a category where ``invariant'' has its ordinary meaning. In noncommutative geometry the same foliation has the irrational rotation
algebra $A_\alpha$ attached to it, and the first row of arithmetic also appears there: $A_\alpha$ and $A_\beta$ are Morita equivalent exactly when
$\alpha$ and $\beta$ are $\GL_2(\Z)$-equivalent \cite{Rieffel}. The diffeological proof is a covering space argument.

\exercisesheading

\begin{exercise}[label=exo:golden]{1}
Let $\varphi=(1+\sqrt5)/2$. Compute the action of the diffeomorphism $[x]\mapsto[\varphi^kx]$ of $T_\varphi$ on $\pi_1(T_\varphi)$ in the basis $(1,\varphi)$.
\end{exercise}
\begin{solution}
$\pi_1(T_\varphi)=\Lam_\varphi$ and the induced map is multiplication by $\varphi^k$. Since $\varphi^2=\varphi+1$, multiplication by $\varphi$
sends $1\mapsto\varphi$ and $\varphi\mapsto1+\varphi$, with matrix $M=\begin{psmallmatrix}0&1\\1&1\end{psmallmatrix}$ acting on coordinate
columns. By induction $\varphi^k=F_{k-1}+F_k\varphi$ with $F_k$ the Fibonacci numbers, and
$M^k=\begin{psmallmatrix}F_{k-1}&F_k\\F_k&F_{k+1}\end{psmallmatrix}$, of determinant $(-1)^k$. For odd $k$ the diffeomorphism reverses the
orientation of $\pi_1$ although it preserves that of $\R$.
\end{solution}

\begin{exercise}[label=exo:orders]{2}
Compute $\mathcal O_\alpha$ and a generator of $\pi_0\Dif(\Tal)/\{\pm1\}$ for $\alpha=(1+\sqrt3)/2$. What is $\mathcal O_\alpha$ for $\alpha=\sqrt[3]2$?
\end{exercise}
\begin{solution}
$2\alpha-1=\sqrt3$ gives $2\alpha^2-2\alpha-1=0$, so $(A,B,C)=(2,-2,-1)$ is primitive with $D=4+8=12$, and
$\mathcal O_\alpha=\Z+\Z\cdot2\alpha=\Z[1+\sqrt3]=\Z[\sqrt3]$. Note that $\alpha\notin\mathcal O_\alpha$. The fundamental unit of $\Z[\sqrt3]$ is
$2+\sqrt3$, of norm $1$. One checks directly: $(2+\sqrt3)\cdot1=1+2\alpha$ and
$(2+\sqrt3)\alpha=(1+2\alpha)\alpha=\alpha+2\alpha^2=1+3\alpha$, both in $\Lam_\alpha$, with matrix of determinant $1\cdot3-2\cdot1=1$. For
$\alpha=\sqrt[3]2$, which is not quadratic, $\mathcal O_\alpha=\Z$ by \cref{thm:units}(i).
\end{solution}

\begin{exercise}[label=exo:fields]{2}
Show that $T_{\sqrt2}\cong T_{1+\sqrt2}\cong T_{1/\sqrt2}$ and that $T_{\sqrt2}\not\cong T_{\sqrt3}$.
\end{exercise}
\begin{solution}
$1+\sqrt2$ and $1/\sqrt2$ are the images of $\sqrt2$ under $\begin{psmallmatrix}1&1\\0&1\end{psmallmatrix}$ and
$\begin{psmallmatrix}0&1\\1&0\end{psmallmatrix}$, both in $\GL_2(\Z)$; apply \cref{cor:DI}. If $\beta=(a\alpha+b)/(c\alpha+d)$ with integer
coefficients then $\Q(\beta)\subseteq\Q(\alpha)$, and symmetrically; so $\GL_2(\Z)$-equivalent irrationals generate the same field. Since
$\Q(\sqrt2)\ne\Q(\sqrt3)$, the tori are not diffeomorphic. (Indeed there is not even a non-constant smooth map between them, by \cref{cor:DI}(i):
$\lambda$ and $\lambda\sqrt2$ in $\Z+\Z\sqrt3$ with $\lambda\ne0$ would give $\sqrt2\in\Q(\sqrt3)$.)
\end{solution}

\begin{exercise}[label=exo:sqrt10]{3}
Show that $T_{\sqrt{10}}$ and $T_{\sqrt{10}/2}$ have the same endomorphism ring $\Z[\sqrt{10}]$ but are not diffeomorphic.
\end{exercise}
\begin{solution}
For $\alpha=\sqrt{10}$: $(A,B,C)=(1,0,-10)$, $D=40$, $\mathcal O_\alpha=\Z[\sqrt{10}]$. For $\beta=\sqrt{10}/2$: $2\beta^2-5=0$, $(A,B,C)=(2,0,-5)$,
$D=40$, $\mathcal O_\beta=\Z+\Z\cdot2\beta=\Z[\sqrt{10}]$. Suppose $\lambda\Lam_\alpha=\Lam_\beta$. Now $\Lam_\alpha=\Z[\sqrt{10}]=\mathcal O$ and
$2\Lam_\beta=2\Z+\sqrt{10}\Z=:\mathfrak p$, an ideal of $\mathcal O$ of index $2$. So $\mathfrak p=2\lambda\mathcal O$ would be principal, generated by
$\mu=2\lambda=x+y\sqrt{10}\in\mathcal O$ with $\abs{N(\mu)}=[\mathcal O:\mathfrak p]=2$, i.e.\ $x^2-10y^2=\pm2$. Reducing modulo $5$ gives
$x^2\equiv\pm2$, impossible since the squares modulo $5$ are $0,1,4$. Hence no such $\lambda$ exists. In terms of \cref{cor:DI}(iii):
$\sqrt{10}=[3;\overline6]$ and $\sqrt{10}/2=[1;\overline{1,1,2}]$ have different tails. The two tori are related by a smooth homomorphism with
kernel of order $2$ in each direction, but not by a diffeomorphism.
\end{solution}

\begin{exercise}[label=exo:liouville]{3}
For Liouville's constant $\alpha=\sum_{k\ge1}10^{-k!}$, write down an explicit smooth function on $S^1$ of mean zero that is not of the form
$f\circ\rho_\alpha-f$, and describe the corresponding bundle.
\end{exercise}
\begin{solution}
Let $n_j=10^{j!}$. Then $n_j\alpha=\text{integer}+\sum_{k>j}10^{j!-k!}$, so
$\norm{n_j\alpha}=\sum_{k>j}10^{j!-k!}<2\cdot10^{-j\cdot j!}=2n_j^{-j}$. Put $c_j=\norm{n_j\alpha}$ and $g(x)=\sum_j2c_j\cos(2\pi n_jx)$. As in the
proof of \cref{thm:Fl}(iii), $g$ is smooth of mean zero and the Fourier coefficients of a solution $f$ would have modulus at least $1/2\pi$ at the
frequencies $n_j$, contradicting the Riemann--Lebesgue lemma. The bundle is $Y_g=(S^1\times\R)/\Z$ with $1\cdot([x],t)=([x+\alpha],t+g(x))$, with its
projection to $S^1/\rho_\alpha=\Tal$ and the $\R$-action on $t$: a ``skew translation'' of the cylinder. It has a section iff $g$ is a coboundary.
So $Y_g\to\Tal$ is a non-trivial principal $\R$-bundle with zero mean, hence not isomorphic to any rescaling of $T^2\to\Tal$, and by
\cref{exo:IZ830} it is not flat.
\end{solution}

\begin{exercise}[label=exo:LHS]{4}
Prove, without spectral sequences, that $H^1(\Lam_\alpha;\cinf(\R))\cong\cinf(S^1)/(\rho_\alpha^*-1)\cinf(S^1)$.
\end{exercise}
\begin{solution}
Write $M=\cinf(\R)$ with $\Lam_\alpha$ acting by $(T_\lambda^*h)(x)=h(x+\lambda)$. A $1$-cocycle is a map $\tau\colon\Lam_\alpha\to M$ with
$\tau(\lambda+\lambda')=T_{\lambda'}^*\tau(\lambda)+\tau(\lambda')$; coboundaries are $\delta\sigma(\lambda)=T_\lambda^*\sigma-\sigma$.

\emph{Normalisation.} By \cref{lem:coboundary-line} there is $\sigma\in M$ with $\tau(1)=T_1^*\sigma-\sigma$. Replacing $\tau$ by $\tau-\delta\sigma$
we may assume $\tau(1)=0$; the remaining freedom is to subtract $\delta\sigma$ with $T_1^*\sigma=\sigma$, i.e.\ $\sigma\in\cinf(S^1)$.

\emph{The invariant.} Computing $\tau(1+\alpha)$ in the two orders,
\[
T_\alpha^*\tau(1)+\tau(\alpha)=\tau(1+\alpha)=T_1^*\tau(\alpha)+\tau(1),
\]
so with $\tau(1)=0$ the function $g=\tau(\alpha)$ is $1$-periodic: $g\in\cinf(S^1)$. The cocycle identity then forces $\tau(m)=0$ and
$\tau(m+n\alpha)=\tau(n\alpha)=\sum_{k=0}^{n-1}T_{k\alpha}^*g$ for $n\ge0$, with $\tau(-n\alpha)=-T_{-n\alpha}^*\tau(n\alpha)$. So a normalised
cocycle is determined by $g$.

\emph{Existence.} Conversely, for any $g\in\cinf(S^1)$ these formulas define a cocycle: the identity for the subgroup $\Z\alpha$ is the usual
telescoping for a $\Z$-cocycle with values in the $\Z\alpha$-module $\cinf(S^1)$, and translation by integers acts trivially on the values, so the
extension by $\tau(m+n\alpha)=\tau(n\alpha)$ is consistent.

\emph{Coboundaries.} A normalised $\tau$ is changed by an allowed $\delta\sigma$, $\sigma\in\cinf(S^1)$, to one with
$g'=g-(T_\alpha^*\sigma-\sigma)=g-(\rho_\alpha^*-1)\sigma$. So $\tau\mapsto[g]$ is a well-defined bijection from $H^1(\Lam_\alpha;M)$ to
$\cinf(S^1)/(\rho_\alpha^*-1)\cinf(S^1)$, and it is additive.

Geometrically the normalisation step trivialises the pullback of the bundle to the circle $\R/\Z$, which covers $\Tal$ with group $\Z$
(\cref{exo:Z-bundles}), and $g$ is the clutching function of the bundle over $\Tal=S^1/\rho_\alpha$. This is the reduction in \IZ{art.~8.39}.
\end{solution}



\chapter{Cryptography: real multiplication, class groups, lattices}\label{ch:crypto}
\chaptermark{Cryptography}

\begin{chapabstract}
Irrational tori are analogues of elliptic curves without a complex structure: they have isogenies, degrees, torsion subgroups and, in the quadratic
case, real multiplication. We show that tori with real multiplication by a fixed order form a torsor under its class group, that deciding
diffeomorphism between them is the principal ideal problem, and that the infrastructure of a real quadratic field is a circle of marked tori. We
then treat lattices proper through their moduli orbifold, where the search and decision forms of the lattice isomorphism problem become the
stack and its coarse space.
\end{chapabstract}
\source{The geometry used is \IZ{Exercise~4}, \IZ{art.~4.17--4.18} and \cref{ch:number-theory}. The real-multiplication viewpoint is
Manin's \cite{Manin}.}

\section{Isogenies of irrational tori}

A \defn{pseudolattice} is a subgroup $\Lam\subset\R$ of rank $2$ that is not cyclic, equivalently $\Lam=\Z\omega_1+\Z\omega_2$ with
$\omega_1/\omega_2$ irrational \cite{Manin}. Every irrational torus is $T_\Lam=\R/\Lam$ for a pseudolattice, and $T_\Lam\cong T_{\omega_2/\omega_1}$. An
\defn{isogeny} $T_\Lam\to T_{\Lam'}$ is a non-constant smooth homomorphism.

\begin{proposition}[Isogenies]\label{prop:isogenies}
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\Lam\mapsto T_\Lam$ is an equivalence from the category of pseudolattices, with morphisms $\Hom(\Lam,\Lam')=\set{\lambda\in\R : \lambda\Lam\subseteq\Lam'}$,
to the category of irrational tori and smooth homomorphisms.
\item An isogeny $\lambda$ is surjective, with finite kernel $\lambda^{-1}\Lam'/\Lam\cong\Lam'/\lambda\Lam$ of order $\deg\lambda:=[\Lam':\lambda\Lam]$,
and it is a covering map. Degrees are multiplicative.
\item Every isogeny $\lambda$ has a dual $\hat\lambda=\deg(\lambda)/\lambda\colon T_{\Lam'}\to T_\Lam$ with $\hat\lambda\lambda=[\deg\lambda]$. So
isogeny is an equivalence relation.
\item The $N$-torsion subgroup is $T_\Lam[N]=\tfrac1N\Lam/\Lam\cong(\Z/N)^2$.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) is \cref{cor:DI}(i): smooth homomorphisms are multiplications by real numbers preserving the groups. (ii) $\lambda\Lam$ and $\Lam'$ both have rank
$2$, so the index is finite; $x\mapsto\lambda x$ is onto $\R$; the kernel of the induced map is as stated, and it is a principal bundle for this finite
group by \cref{cor:GmodH}. (iii) $\deg(\lambda)\cdot\Lam'\subseteq\lambda\Lam$ because a finite abelian group is annihilated by its order, so
$(\deg\lambda/\lambda)\Lam'\subseteq\Lam$. (iv) is the kernel of multiplication by $N$.
\end{proof}

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{3.6cm}p{4.9cm}p{4.9cm}@{}}\toprule
 & elliptic curve $E=\C/\Lam$ & irrational torus $T=\R/\Lam$\\\midrule
lattice & discrete, rank $2$ in $\C$ & dense, rank $2$ in $\R$\\
category & complex manifolds & diffeological spaces\\
morphisms & $\lambda\in\C$, $\lambda\Lam\subseteq\Lam'$ & $\lambda\in\R$, $\lambda\Lam\subseteq\Lam'$\\
$N$-torsion & $(\Z/N)^2$ & $(\Z/N)^2$\\
moduli & $\SL_2(\Z)\backslash\mathfrak H$ & $\GL_2(\Z)\backslash(\R\smallsetminus\Q)$\\
extra endomorphisms & imaginary quadratic order (CM) & real quadratic order (RM)\\
unit group of the order & finite & $\{\pm1\}\times\Z$\\
classes with given order & torsor under $\Pic(\mathcal O)$ & torsor under $\Pic(\mathcal O)$\\
shape & $\B\Z^2$ & $\B\Z^2$\\\bottomrule
\end{tabular}
\caption{Complex and real multiplication. The right-hand column is a theorem-by-theorem translation of the left; the differences are in the last
rows, and they are what matters for cryptography.}\label{tab:CMRM}
\end{table}

\section{The class group torsor}

Fix a real quadratic field $K\subset\R$ and an order $\mathcal O\subset K$ of discriminant $D$. For a pseudolattice $\Lam$ write
$\mathcal O_\Lam=\set{\lambda\in\R:\lambda\Lam\subseteq\Lam}=\End(T_\Lam)$. Let $\mathcal T(\mathcal O)$ be the set of diffeomorphism classes of
irrational tori $T_\Lam$ with $\mathcal O_\Lam=\mathcal O$, and let $\Pic(\mathcal O)$ be the group of invertible fractional $\mathcal O$-ideals modulo
principal ones.

\begin{theorem}[Tori with real multiplication; after \cite{Manin,IglesiasLachaud}]\label{thm:class-torsor}
\begin{enumerate}[label=\textup{(\roman*)}]
\item Every pseudolattice with $\mathcal O_\Lam=\mathcal O$ is homothetic to an invertible fractional ideal of $\mathcal O$, and
$\Lam\mapsto[\Lam]$ induces a bijection $\mathcal T(\mathcal O)\cong\Pic(\mathcal O)$. In particular there are exactly $h(\mathcal O)$ diffeomorphism
classes of irrational tori with real multiplication by $\mathcal O$.
\item $\Pic(\mathcal O)$ acts simply transitively on $\mathcal T(\mathcal O)$ by $[\mathfrak a]\cdot[T_\Lam]=[T_{\mathfrak a^{-1}\Lam}]$. For an integral
invertible ideal $\mathfrak a$ the canonical map
\[
\phi_{\mathfrak a}\colon T_\Lam\longrightarrow T_{\mathfrak a^{-1}\Lam}
\]
is an isogeny of degree $N(\mathfrak a)$ with kernel $T_\Lam[\mathfrak a]=\set{x:\mathfrak a x=0}$.
\item Every isogeny between tori with real multiplication by $\mathcal O$ is, up to diffeomorphism of its target, some $\phi_{\mathfrak a}$.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) Scale $\Lam$ so that $1\in\Lam$, say $\Lam=\Z+\Z\alpha$. Then $\mathcal O_\Lam=\mathcal O_\alpha\ne\Z$, so by \cref{thm:units} $\alpha$ is
quadratic, $\Q(\alpha)=K$, and $\Lam\subset K$ is a lattice with multiplier ring $\mathcal O$. In a quadratic order such a lattice is an invertible
fractional ideal (\cref{exo:proper-invertible}). If $\lambda\Lam=\Lam'$ with both in $K$ then $\lambda\in K^\times$. So homothety classes of
pseudolattices with multiplier ring $\mathcal O$ are classes of invertible ideals modulo $K^\times$, and by \cref{thm:linear-rigidity} homothety classes
are diffeomorphism classes. (ii) Multiplication by an invertible ideal preserves the multiplier ring, and the action of a group on itself is simply
transitive. If $\mathfrak a\subseteq\mathcal O$ then $\Lam\subseteq\mathfrak a^{-1}\Lam$ with index $N(\mathfrak a)$, and the identity of $\R$ induces
$\phi_{\mathfrak a}$ with kernel $\mathfrak a^{-1}\Lam/\Lam=\set{x\in\R/\Lam:\mathfrak ax\subseteq\Lam}$. (iii) If $\lambda\Lam\subseteq\Lam'$ then
$\mathfrak a=\lambda\Lam\cdot\Lam'^{-1}$ is an integral invertible ideal and $\Lam'=\mathfrak a^{-1}(\lambda\Lam)$; multiplication by $\lambda$ is a
diffeomorphism $T_\Lam\to T_{\lambda\Lam}$.
\end{proof}

This is the exact analogue of the main theorem of complex multiplication for elliptic curves over $\C$, with the same proof. The diffeological
input is \cref{thm:linear-rigidity}, by which the category in which these objects are classified is the ordinary category of smooth
spaces.

\begin{example}[Two small isogeny graphs]\label{ex:isogeny-graphs}
\begin{enumerate}[label=(\alph*)]
\item $D=5$, $\mathcal O=\Z[\varphi]$, $h=1$: the golden torus is the only torus with real multiplication by $\Z[\varphi]$.
\item $D=40$, $\mathcal O=\Z[\sqrt{10}]$, $h=2$: the two classes are $T_{\sqrt{10}}$ and $T_{\sqrt{10}/2}$ (\cref{exo:sqrt10}). The primes
$\mathfrak p_2=(2,\sqrt{10})$ and $\mathfrak p_3=(3,1+\sqrt{10})$ are both non-principal, so isogenies of degree $2$ and $3$ interchange the two tori.
\item $D=316$, $\mathcal O=\Z[\sqrt{79}]$, $h=3$: the three classes are $T_{\sqrt{79}}$, $T_{(1+\sqrt{79})/3}$ and $T_{(-1+\sqrt{79})/3}$, permuted
cyclically by the two primes above $3$ (\cref{fig:isogeny}, \cref{exo:79}).
\end{enumerate}
\end{example}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \node[hcsnode,align=center] (a) at (90:2.0) {$T_{\sqrt{79}}$\\[-0.3ex]\scriptsize $[8;\overline{1,7,1,16}]$};
  \node[hcsnode,align=center] (b) at (210:2.3) {$T_{(1+\sqrt{79})/3}$\\[-0.3ex]\scriptsize $[3;\overline{3,2,1,1,1,5}]$};
  \node[hcsnode,align=center] (c) at (330:2.3) {$T_{(-1+\sqrt{79})/3}$\\[-0.3ex]\scriptsize $[2;\overline{1,1,1,2,3,5}]$};
  \draw[->,hcsrust,line width=0.7pt] (a) to[bend right=14] node[left,font=\footnotesize]{$\phi_{\mathfrak p}$} (b);
  \draw[->,hcsrust,line width=0.7pt] (b) to[bend right=14] node[below,font=\footnotesize]{$\phi_{\mathfrak p}$} (c);
  \draw[->,hcsrust,line width=0.7pt] (c) to[bend right=14] node[right,font=\footnotesize]{$\phi_{\mathfrak p}$} (a);
  \node[font=\footnotesize,align=center] at (0,-2.55) {$3$-isogeny graph, $\mathfrak p=(3,-1+\sqrt{79})$, $[\mathfrak p]^3=1$};
 \end{scope}
 \begin{scope}[xshift=8.9cm]
  \draw[hcsteal,line width=0.9pt] (0,0) circle (1.75);
  \foreach \ang in {0,8.4,155.4,159.5}{\fill[hcsrust] (\ang:1.75) circle (2.0pt);}
  \node[right] at (-2:1.85) {$\mathcal O$};
  \node[right,font=\footnotesize] at (11:1.85) {$\alpha_1\mathcal O$};
  \node[left,font=\footnotesize] at (157.5:1.85) {two reduced ideals};
  \draw[->,hcsgrey] (25:1.35) arc (25:140:1.35);
  \node[font=\footnotesize,hcsgrey] at (0,0.35) {$\log\abs\lambda$};
  \node[font=\footnotesize,align=center] at (0,-2.55) {infrastructure of $\Z[\sqrt{79}]$:\\ circumference $R=\log(80+9\sqrt{79})\approx5.075$};
 \end{scope}
\end{tikzpicture}
\caption{Left: the three irrational tori with real multiplication by $\Z[\sqrt{79}]$, with the continued fraction of a representative, and the
cyclic action of an ideal of norm $3$. Right: the circle of marked tori homothetic to $\R/\mathcal O$ (\cref{prop:infrastructure}), with the four
reduced principal ideals at their exact positions $0$, $0.119$, $2.191$ and $2.249$ (successive ideals differ by the complete quotients of the
continued fraction of $8+\sqrt{79}$).}\label{fig:isogeny}
\end{figure}

\section{Diffeomorphism is the principal ideal problem}

Present a torus with real multiplication by the primitive integer form $(A,B,C)$ of discriminant $D$ with root $\alpha=(-B+\sqrt D)/2A$; this takes
$O(\log D)$ bits. Then $A\Lam_\alpha=A\Z+\tfrac{-B+\sqrt D}2\Z$ is an invertible ideal of $\mathcal O_D$, and every ideal class arises.

\begin{theorem}[Complexity dictionary]\label{thm:complexity}
Fix a non-square discriminant $D>0$ and let $R_D=\log\varepsilon_D$ be the regulator of $\mathcal O_D$.
\begin{enumerate}[label=\textup{(\alph*)}]
\item The problem of deciding whether $\Tal\cong T_\beta$ for two tori presented by forms of discriminant $D$ is equivalent, under linear-time
reductions in both directions, to deciding equality of two classes in $\Pic(\mathcal O_D)$. Finding the diffeomorphism $\lambda$, in the sense
of approximating $\log\abs\lambda$ modulo $R_D$, is equivalent to the principal ideal problem for $\mathcal O_D$.
\item Computing a generator of $\pi_0\Dif(\Tal)/\{\pm1\}\cong\Z$, in the sense of approximating its dilation factor, is equivalent to computing
$R_D$, that is, to solving Pell's equation.
\item Consequently both problems are solvable in quantum polynomial time in $\log D$ \cite{Hallgren}. The best known classical algorithms are
subexponential; and integer factoring reduces to \textup{(b)} \cite{Hallgren}.
\end{enumerate}
\end{theorem}
\begin{proof}
(a) By \cref{thm:linear-rigidity} and \cref{thm:class-torsor}, $\Tal\cong T_\beta$ iff $\lambda\Lam_\alpha=\Lam_\beta$ for some $\lambda\in K^\times$, iff the
ideals $A\Lam_\alpha$ and $A'\Lam_\beta$ are equivalent, and $\lambda$ is, up to the rational factor $A/A'$ and a unit, a generator of the principal
ideal $A'\Lam_\beta(A\Lam_\alpha)^{-1}$. The translation between forms, tori and ideals is a relabelling of the input. (b) By
\cref{thm:units}(iii) the generator is multiplication by $\varepsilon_D$. (c) Hallgren's algorithms compute $R_D$ and solve the principal ideal
problem in real quadratic orders in quantum polynomial time.
\end{proof}

The theorem locates real-quadratic cryptography on the geometric side.

\begin{proposition}[The infrastructure is a circle of marked tori]\label{prop:infrastructure}
Fix a class $c\in\Pic(\mathcal O)$. The set of pseudolattices $\Lam\subset\R$ in the class $c$, not taken up to homothety, is a torsor under
\[
\R^\times/\mathcal O^\times\;\cong\;\R_{>0}/\varepsilon^{\Z}\;\xrightarrow[\ \log\ ]{\ \cong\ }\;\R/R_D\Z ,
\]
a circle of circumference the regulator. Equivalently it is the set of isomorphism classes of \emph{marked} tori $(\R\to T)$ in the
diffeomorphism class $c$, where a marking is a choice of universal covering by $\R$ up to translation.
\end{proposition}
\begin{proof}
$\R^\times$ acts on lattices by homothety, transitively on a class by definition, and the stabiliser of $\Lam$ is $\set{\lambda:\lambda\Lam=\Lam}=\mathcal O^\times=\{\pm\varepsilon^k\}$.
A marked torus is the same as the subgroup $\Lam=\ker(\R\to T)$, since translations do not change it.
\end{proof}

The finitely many \emph{reduced} ideals in the class are distinguished points on this circle; Shanks called the circle with these points the
\emph{infrastructure} of the class \cite{Shanks}. Multiplying two reduced ideals and reducing lands near the sum of their positions, so one can
take large steps around the circle without knowing its circumference. Buchmann and Williams built a Diffie--Hellman key exchange on this
\cite{BuchmannWilliams}: the parties exchange reduced ideals near positions $a\delta$ and $b\delta$ and share the one near $ab\delta$; an
eavesdropper who can compute positions --- that is, solve the principal ideal problem --- recovers the key. In our terms: \emph{the
Buchmann--Williams scheme is Diffie--Hellman in the circle group of marked tori diffeomorphic to $\R/\mathcal O$, with elements represented by
nearby tori of small height and the circumference $R_D$ kept implicit.} Hallgren's algorithm computes the circumference and the positions, and
breaks it.

\section{Lattices}

For lattices of full rank, all quotients $\R^n/L$ are diffeomorphic by \cref{thm:linear-rigidity}. The object of lattice cryptography is the
Euclidean structure, and the natural diffeological object is the moduli space of lattices. Let $\mathcal S_n$ be the open cone of positive definite symmetric $n\times n$ matrices, on which $\GL_n(\Z)$
acts by $Q\cdot U=U^{\mathsf T}QU$; two Gram matrices are in the same orbit iff they come from isometric lattices. The \emph{lattice isomorphism problem}
(LIP) is: given $Q,Q'$, find a $U$ with $Q'=U^{\mathsf T}QU$ \cite{DucasVanWoerden}.

\begin{theorem}[The orbifold of lattices]\label{thm:lattice-orbifold}
Let $\mathfrak L_n=\mathcal S_n/\GL_n(\Z)$ with the quotient diffeology, and $\Aut(Q)=\set{U\in\GL_n(\Z):U^{\mathsf T}QU=Q}$.
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\mathfrak L_n$ is a diffeological orbifold of dimension $n(n+1)/2$. Near $[Q]$ it is diffeomorphic to $\Sym_n(\R)/\bar\Gamma_Q$, where
$\bar\Gamma_Q=\Aut(Q)/\{\pm1\}$ acts linearly by $S\mapsto U^{\mathsf T}SU$.
\item The conjugacy class of the linear group $\bar\Gamma_Q$ is an invariant of the germ of $\mathfrak L_n$ at $[Q]$. In particular $[Q]$ is a
manifold point of $\mathfrak L_n$ if and only if $\Aut(Q)=\{\pm1\}$.
\item In $\Hh$ there are canonical maps $\mathcal S_n\hquot\GL_n(\Z)\to\mathcal S_n\hquot\PGL_n(\Z)\to\mathfrak L_n$. The first is a
$\B\Z/2$-bundle, the second is an isomorphism over the manifold points. Decision-LIP is equality of points of $\mathfrak L_n$; search-LIP is the
construction of a $1$-morphism $Q\to Q'$ in the stack $\mathcal S_n\hquot\GL_n(\Z)$; and the set of solutions is a torsor under $\Aut(Q)$.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) The action is properly discontinuous: if $Q$ and $U^{\mathsf T}QU$ range over a compact subset of $\mathcal S_n$ then $\norm U$ is bounded, so only
finitely many integer matrices $U$ occur. Hence stabilisers are finite and every $Q$ has an $\Aut(Q)$-invariant open neighbourhood $W$ with
$W\cdot U\cap W=\varnothing$ for $U\notin\Aut(Q)$. The saturation of $W$ is open, so its image is D-open in the quotient and is diffeomorphic to
$W/\Aut(Q)$. The action on $\Sym_n(\R)\supset\mathcal S_n$ is linear and fixes $Q$; translating by $-Q$ identifies $W/\Aut(Q)$ with a neighbourhood of
$0$ in $\Sym_n(\R)/\Aut(Q)$. The kernel of $\GL_n(\Z)\to\GL(\Sym_n(\R))$ is $\{\pm1\}$, so the effective group is $\bar\Gamma_Q$.
(ii) is \cref{thm:IKZ} and \cref{cor:manifold-point}. (iii) is \cref{thm:three-quotients}: the action of $\PGL_n(\Z)$ is free exactly over the points with
$\bar\Gamma_Q=1$, and $\Hom(Q,Q')=\set{U:Q'=U^{\mathsf T}QU}$ is a torsor under the automorphism group of $Q$ when it is non-empty.
\end{proof}

In this language a public key in an LIP-based scheme is a point of the stack with a hidden $1$-morphism to a distinguished object, and the
structure group at that object measures how many secret keys there are. For the lattice $\Z^n$, used in the signature scheme \textsc{Hawk}
\cite{Hawk} in a module form, $\Aut(I_n)$ is the hyperoctahedral group of order $2^nn!$, the most singular kind of point; a generic $Q$ is a manifold
point with $\Aut(Q)=\{\pm1\}$. The distinction between the stack and the orbifold $\mathfrak L_n$ is the distinction between search and decision:
equality of points of the coarse space is the \emph{existence} of an equivalence of forms, and a $1$-cell of the stack is a \emph{choice} of one. The zero-knowledge proofs of \cite{DucasVanWoerden} are
proofs of knowledge of a $1$-cell in which only its endpoints are disclosed.

For subgroups of rank larger than the dimension the diffeology of the quotient is again informative.

\begin{corollary}[Projected lattices]\label{cor:projected}
Let $B,B'$ be real $n\times N$ matrices of rank $n$ that are injective on $\Z^N$. Then
\begin{align*}
\R^n/B\Z^N\cong\R^n/B'\Z^N&\iff B'=ABU\ \text{ for some }A\in\GL_n(\R),\ U\in\GL_N(\Z)\\
&\iff\ker B'=U^{-1}\ker B\ \text{ for some }U\in\GL_N(\Z).
\end{align*}
So diffeomorphism classes of such quasi-tori correspond to $\GL_N(\Z)$-orbits of $(N-n)$-dimensional subspaces of $\R^N$ meeting $\Z^N$ trivially.
\end{corollary}
\begin{proof}
By \cref{thm:linear-rigidity} the quotients are diffeomorphic iff $B'\Z^N=AB\Z^N$ for some $A$; as $B'$ and $AB$ are injective on $\Z^N$ with the
same image there is a unique $U\in\GL_N(\Z)$ with $B'=ABU$. A matrix of rank $n$ is determined up to left multiplication by $\GL_n(\R)$ by its kernel.
\end{proof}

\section{The geometric picture}\label{sec:crypto-picture}

Three things usually treated separately are here objects of one category: the class group action (isogenies of tori), the
infrastructure (marked tori), and the search/decision distinction for isomorphism problems (stack versus coarse space).

Two facts about sizes orient the picture. Isogeny-based schemes such as CSIDH \cite{CSIDH} use the action of a large imaginary quadratic class
group, of size about $\sqrt{\abs D}$, as a hard homogeneous space \cite{Couveignes}. For real quadratic orders it is the product $h\cdot R$ that
has this size, and heuristically the class number $h$ is usually small \cite{Cohen}. So the torsor of \cref{thm:class-torsor} is small and the
bulk of the structure is in the circle of \cref{prop:infrastructure}, which is where period finding applies (\cref{thm:complexity}). For
lattices, the Euclidean geometry used in cryptography is that of $\mathcal S_n$ and of the fibres of $\mathcal S_n\to\mathfrak L_n$, and the
isomorphism problem is the problem of equality of points of the orbifold $\mathfrak L_n$.

\exercisesheading

\begin{exercise}[label=exo:torsion]{1}
Show that multiplication by $N$ on an irrational torus has degree $N^2$, and that for $\lambda\in\mathcal O_\Lam$ the endomorphism $\lambda$ of
$T_\Lam$ has degree $\abs{N_{K/\Q}(\lambda)}$ when $\Lam$ has real multiplication.
\end{exercise}
\begin{solution}
$[\Lam:N\Lam]=N^2$ since $\Lam\cong\Z^2$. In general $\deg\lambda=[\Lam:\lambda\Lam]$ is the absolute value of the determinant of multiplication by
$\lambda$ on $\Lam\cong\Z^2$, which is the norm of $\lambda$ as an element of the quadratic field (the determinant of multiplication by $\lambda$
on $K=\Lam\otimes\Q$).
\end{solution}

\begin{exercise}[label=exo:sqrt5]{2}
On the golden torus $T_\varphi$, compute the degree and kernel of multiplication by $\sqrt5=2\varphi-1$, and of multiplication by $\varphi$.
\end{exercise}
\begin{solution}
$N(\sqrt5)=-5$, so the degree is $5$ and the kernel is $\tfrac1{\sqrt5}\Z[\varphi]/\Z[\varphi]\cong\Z[\varphi]/(\sqrt5)\cong\Z/5$, generated by
the class of $1/\sqrt5$. $N(\varphi)=-1$, so multiplication by $\varphi$ has degree $1$: it is the diffeomorphism of \cref{exo:golden}. The prime $5$
ramifies in $\Z[\varphi]$, and $T_\varphi[\sqrt5]$ is the unique subgroup of $T_\varphi[5]\cong(\Z/5)^2$ stable under real multiplication.
\end{solution}

\begin{exercise}[label=exo:79]{2}
Verify \cref{ex:isogeny-graphs}(c): the ideal $\mathfrak p=(3,-1+\sqrt{79})$ of $\Z[\sqrt{79}]$ is not principal, and $\mathfrak p^3$ is.
\end{exercise}
\begin{solution}
$N(\mathfrak p)=3$. If $\mathfrak p=(x+y\sqrt{79})$ then $x^2-79y^2=\pm3$. By a theorem of Lagrange, a solution of $\abs{x^2-dy^2}<\sqrt d$ in coprime
integers has $x/y$ a convergent of $\sqrt d$. For $\sqrt{79}=[8;\overline{1,7,1,16}]$ the values $p^2-79q^2$ along the convergents are periodic and
equal to $-15,2,-15,1$; so $\pm3$ is not represented. On the other hand $17^2-79\cdot2^2=-27$, so $\mu=17+2\sqrt{79}$ has norm $-27$. The ideal
$(\mu)$ has norm $27$ and is not divisible by $(3)=\mathfrak p\bar{\mathfrak p}$, because $\mu/3\notin\Z[\sqrt{79}]$; so it is $\mathfrak p^3$ or
$\bar{\mathfrak p}^3$, and either way $[\mathfrak p]^3=1$. Hence $[\mathfrak p]$ has order exactly $3$. The three ideal classes $1,[\mathfrak p],[\mathfrak p]^2$
are represented by the pseudolattices $\Z+\sqrt{79}\Z$, $\tfrac13\mathfrak p=\Z+\tfrac{-1+\sqrt{79}}3\Z$ and $\tfrac13\bar{\mathfrak p}=\Z+\tfrac{1+\sqrt{79}}3\Z$,
whose continued fractions have three different periods, in accordance with \cref{cor:DI}(iii).
\end{solution}

\begin{exercise}[label=exo:isogeny-classes]{3}
Show that $\Tal$ and $T_\beta$ are isogenous if and only if $\beta=(a\alpha+b)/(c\alpha+d)$ for an integer matrix of non-zero determinant. Deduce
that the tori with real multiplication fall into one isogeny class for each real quadratic field, and that an isogeny class of tori without real
multiplication contains infinitely many diffeomorphism classes.
\end{exercise}
\begin{solution}
An isogeny is a $\lambda\ne0$ with $\lambda\Lam_\alpha\subseteq\Lam_\beta$: $\lambda=c'\beta+d'$ and $\lambda\alpha=a'\beta+b'$ with integers such
that $a'd'-b'c'\ne0$ (otherwise $\alpha$ would be rational). So $\alpha$ is the image of $\beta$ under a matrix in $\GL_2(\Q)\cap M_2(\Z)$, and
inverting, $\beta$ is the image of $\alpha$ under such a matrix. The converse is the same computation backwards. If $\alpha$ is quadratic, its
$\GL_2(\Q)$-orbit is $K\smallsetminus\Q$ for $K=\Q(\alpha)$: any $\beta\in K\smallsetminus\Q$ is $a\alpha+b$ with $a\ne0$ rational, hence the image
of $\alpha$ under a matrix with integer entries after clearing denominators. So there is one isogeny class per field, and it contains tori with all the orders of $K$ as
endomorphism rings. If $\alpha$ is not quadratic, the stabiliser of $\alpha$ in $\mathrm{PGL}_2(\Q)$ is trivial, so the isogeny class is in
bijection with $\mathrm{PGL}_2(\Q)$ and the diffeomorphism classes in it with $\PGL_2(\Z)\backslash\mathrm{PGL}_2(\Q)$, which is infinite: for
instance the tori $T_{p\alpha}$, $p$ prime, are pairwise non-diffeomorphic.
\end{solution}

\begin{exercise}[label=exo:L2]{3}
Describe the local structure of $\mathfrak L_2$ at the square lattice $Q=I_2$ and at the hexagonal lattice $Q=\begin{psmallmatrix}2&1\\1&2\end{psmallmatrix}$.
Is $\mathfrak L_2$ a manifold with corners near $[I_2]$?
\end{exercise}
\begin{solution}
Use coordinates $S=\begin{psmallmatrix}a&b\\b&c\end{psmallmatrix}$ on $\Sym_2(\R)\cong\R^3$. $\Aut(I_2)$ is the group of signed permutation
matrices, of order $8$, so $\bar\Gamma=\Aut/\{\pm1\}$ has order $4$. It is generated by $\mathrm{diag}(1,-1)$, acting as $(a,b,c)\mapsto(a,-b,c)$, and the
swap, acting as $(a,b,c)\mapsto(c,b,a)$: two commuting reflections, in the planes $b=0$ and $a=c$. So near $[I_2]$,
$\mathfrak L_2\cong\R\times(\R/\{\pm1\})\times(\R/\{\pm1\})=\R\times\dten_1\times\dten_1$. For the hexagonal lattice $\Aut$ has order $12$ and
$\bar\Gamma\cong S_3$ of order $6$, generated by reflections, with local model $\R\times(\R^2/S_3)$. These are the orbifold points $i$ and
$e^{i\pi/3}$ of the modular curve, times the scale. Topologically a neighbourhood of $[I_2]$ is $\R$ times a quadrant, but it is not a manifold
with corners: $\dten_1\not\cong[0,\infty)_{\Sub}$ by \cref{prop:delta1}, and the structure group $(\Z/2)^2$ is an invariant by
\cref{thm:lattice-orbifold}(ii). So the diffeology of the moduli space determines that the boundary of the quadrant consists of mirror points.
\end{solution}

\begin{exercise}[label=exo:proper-invertible]{4}
Let $\alpha$ be a quadratic irrational with primitive equation $A\alpha^2+B\alpha+C=0$, $\Lam=\Z+\Z\alpha$ and $\mathcal O=\Z+\Z A\alpha$. Prove that
$\Lam$ is an invertible fractional $\mathcal O$-ideal, and complete the proof of \cref{thm:class-torsor}(i).
\end{exercise}
\begin{solution}
Let $\bar\alpha$ be the conjugate and $\bar\Lam=\Z+\Z\bar\alpha$; then $\alpha+\bar\alpha=-B/A$ and $\alpha\bar\alpha=C/A$. $\Lam$ is an
$\mathcal O$-module by \cref{thm:units}(ii), and so is $\bar\Lam$, as $\bar{\mathcal O}=\mathcal O$. Compute the product of lattices:
\begin{align*}
\Lam\bar\Lam&=\Z+\Z\alpha+\Z\bar\alpha+\Z\alpha\bar\alpha=\Z+\Z\alpha+\Z\tfrac BA+\Z\tfrac CA\\
&=\tfrac1A\bigl(A\Z+B\Z+C\Z+\Z A\alpha\bigr)=\tfrac1A\bigl(\Z+\Z A\alpha\bigr)=\tfrac1A\mathcal O,
\end{align*}
using $\bar\alpha=-B/A-\alpha$ and $\gcd(A,B,C)=1$. Hence $\Lam\cdot(A\bar\Lam)=\mathcal O$ and $\Lam$ is invertible with inverse $A\bar\Lam$.

Now the bijection. Let $\Lam'$ be any pseudolattice with $\mathcal O_{\Lam'}=\mathcal O$. Dividing by a non-zero element we may assume
$\Lam'=\Z+\Z\alpha'$; then $\mathcal O_{\alpha'}=\mathcal O\neq\Z$ forces $\alpha'$ quadratic with $\Q(\alpha')=K$, and by the computation $\Lam'$ is
an invertible ideal of $\mathcal O_{\alpha'}=\mathcal O$. So $\Lam'\mapsto[\Lam']\in\Pic(\mathcal O)$ is defined on homothety classes. It is
injective: if $\Lam''=\mu\Lam'$ with $\mu\in K^\times$ the lattices are homothetic. It is surjective: an invertible fractional ideal $\mathfrak a$ is a
lattice in $K\subset\R$ of rank $2$, not cyclic, with multiplier ring exactly $\mathcal O$ --- if $\lambda\mathfrak a\subseteq\mathfrak a$ then
$\lambda\mathcal O=\lambda\mathfrak a\mathfrak a^{-1}\subseteq\mathcal O$. Finally homothety classes are diffeomorphism classes by
\cref{thm:linear-rigidity}(c), and a real $\lambda$ with $\lambda\Lam'=\Lam''$, both inside $K$, lies in $K$.
\end{solution}



\chapter{Machine learning: differentiable programs and singular hypothesis spaces}\label{ch:ml}
\chaptermark{Machine learning}

\begin{chapabstract}
Three places where machine learning already involves more than manifolds. First, the space of functions computed by a model is a quotient of
parameter space and a subspace of a function space, and these are two different smooth spaces. Second, the correctness of automatic
differentiation for programs with higher-order functions is a theorem about gluing over $\Diff$. Third, orbit spaces of data symmetries have no
differentiable canonical form at points with isotropy. Each is a statement about the quasitopos structure of \cref{ch:quasitopos}.
\end{chapabstract}
\source{Quotients, strict maps and the functional diffeology, \IZ{art.~1.50--1.60}, and \IZ{Exercises~50--51}. The theorem on automatic
differentiation is due to Huot, Staton and V\'ak\'ar \cite{HSV}.}

\section{Hypothesis spaces}

A \defn{parametric model} is a smooth map $f\colon\Theta\times X\to Y$, where $\Theta$ is a space of parameters and $X,Y$ are the spaces of inputs
and outputs; think of manifolds, though nothing below requires it. Its \defn{realisation map} is
\[
\rho\colon\Theta\longrightarrow\cinf(X,Y),\qquad\rho(\theta)=f(\theta,-).
\]
Two parameters are \defn{functionally equivalent}, $\theta\sim\theta'$, if $\rho(\theta)=\rho(\theta')$. Applying \cref{thm:factorisations} to $\rho$
gives two hypothesis spaces,
\[
\Theta\;\onto\;\mathcal H_q:=\Theta/{\sim}\;\xrightarrow{\ \kappa\ }\;\mathcal H_s:=\rho(\Theta)_{\Sub}\;\into\;\cinf(X,Y),
\]
the \emph{quotient} and the \emph{subspace} hypothesis space. They have the same points: the functions the model can compute.

\begin{theorem}[Smooth learning objects]\label{thm:learning}
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\rho$ is smooth for the functional diffeology, and $\kappa$ is a smooth bijection.
\item Let $Y=\R^k$, let $\mu$ be a finite Borel measure with compact support on $X\times\R^k$, $X$ a manifold, and $\ell\colon\R^k\times\R^k\to\R$ smooth.
The risk
\[
\mathcal R\colon\cinf(X,\R^k)\longrightarrow\R,\qquad\mathcal R(h)=\int\ell\bigl(h(x),y\bigr)\,\dd\mu(x,y)
\]
is smooth. Hence the training loss $L=\mathcal R\circ\rho$ is smooth and descends to smooth functions on $\mathcal H_q$ and on $\mathcal H_s$.
\item A map out of $\mathcal H_q$ is smooth iff its composite with $\Theta\to\mathcal H_q$ is; a map into $\mathcal H_s$ is smooth iff its composite with
$\mathcal H_s\into\cinf(X,Y)$ is, i.e.\ iff it is a smooth family of functions.
\item $\kappa$ need not be a diffeomorphism: there are models with smooth families of realisable functions that are not induced, even locally, by
any smooth family of parameters.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) and (iii) are \cref{thm:ccc} and \cref{thm:factorisations}. (ii) is \cref{exo:risk}. (iv) Take $\Theta=X=Y=\R$ and $f(\theta,x)=\theta^2x$. Then
$\rho(\theta)=\theta^2\cdot\id$, the image of $\rho$ is the half-line $\set{c\cdot\id:c\ge0}$ inside the line of linear functions, which is an induced
copy of $\R$ in $\cinf(\R,\R)$; so $\mathcal H_s\cong H$ and $\mathcal H_q=\R/\{\pm1\}=\dten_1$, and $\kappa=\mathrm{sq}$ is not a diffeomorphism by
\cref{prop:delta1}. The family $(r,s)\mapsto(r^2+s^2)\,\id$ is a plot of $\mathcal H_s$ that does not lift to parameters near $(0,0)$.
\end{proof}

The phenomenon in (iv) is the general one at \emph{singular} parameters, where the fibres of $\rho$ change dimension or
symmetry type: deep linear networks at rank-deficient products, neural networks at parameters with vanishing or duplicated units. In
singular learning theory \cite{Watanabe} these points are studied through the local algebraic geometry of the loss. \Cref{thm:learning} is a
structural remark: before any choice of loss there are two canonical smooth structures on the set of hypotheses; they coincide at regular
parameters; and where they differ, the quotient structure $\mathcal H_q$ is the one with a universal property for learning dynamics, since
dynamics are defined by maps out of $\Theta$.

\begin{figure}[t]
\centering
\begin{tikzcd}[column sep=3.0em,row sep=2.4em]
\Theta \arrow[r,two heads] \arrow[drrr,bend right=14,"L"'] & \mathcal H_q=\Theta/{\sim} \arrow[r,"\kappa"] & \mathcal H_s \arrow[r,hook] & \cinf(X,Y) \arrow[d,"\mathcal R"]\\
 & & & \R
\end{tikzcd}
\caption{Parameters, the two hypothesis spaces, the function space, and the risk. Every arrow is smooth. $\kappa$ is bijective, and is a diffeomorphism
exactly when the realisation map is strict.}\label{fig:hypothesis}
\end{figure}

\begin{proposition}[Symmetric gradient flow]\label{prop:gradflow}
Let a group $G$ act on $\Theta=\R^p$ by linear isometries and let $L\colon\Theta\to\R$ be smooth, $G$-invariant, with complete gradient flow $\Phi_t$.
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\Phi_t$ is $G$-equivariant and descends to a smooth action of $(\R,+)$ on $\Theta/G$, that is, to a smooth homomorphism $\R\to\Dif(\Theta/G)$.
\item $\operatorname{Stab}(\Phi_t\theta)=\operatorname{Stab}(\theta)$ for all $t$. Hence every fixed subspace $\Theta^K$, $K\le G$, is invariant under the flow, and the flow on
$\Theta/G$ preserves the type of each point.
\end{enumerate}
\end{proposition}
\begin{proof}
For an isometry $g$, $\nabla L(g\theta)=g\nabla L(\theta)$, so $g\Phi_t$ and $\Phi_tg$ solve the same initial value problem. The map
$\R\times\Theta\to\Theta\to\Theta/G$ is constant on orbits in the second variable and $\R\times\Theta\to\R\times\Theta/G$ is a subduction
(\cref{prop:stability}), so we get a smooth $\R\times\Theta/G\to\Theta/G$, an action because $\Phi$ is; its adjoint is smooth by \cref{thm:ccc}. For
(ii), $g\Phi_t\theta=\Phi_t\theta$ iff $\Phi_tg\theta=\Phi_t\theta$ iff $g\theta=\theta$.
\end{proof}
\noindent For $G$ a group of permutations and sign changes of hidden units this is the familiar fact that units which start equal stay equal. In the
language of \cref{thm:three-quotients}, gradient flow is a flow on the stack $\Theta\hquot G$, and the induced flow on the orbit space preserves the
stratification by stabilisers.

\section{Correctness of automatic differentiation}

Forward-mode automatic differentiation (AD) is a program transformation: replace every real number by a pair (value, derivative) and every
primitive operation by its derivative-propagating version. For first-order straight-line programs its correctness is the chain rule. Real
languages have higher-order functions, and then even stating correctness requires a semantics in which a program of type
$(\mathtt{real}\to\mathtt{real})\to\mathtt{real}$ denotes a smooth map on a space of smooth maps. Manifolds cannot provide it
(\cref{exo:mfd-not-ccc}). $\Diff$ can.

\paragraph{The language.} Types are $\tau::=\mathtt{real}\mid\tau\times\tau\mid\tau\to\tau$. Terms are variables, constants $\underline c$ for $c\in\R$,
applications $\mathsf{op}(t_1,\dots,t_k)$ of primitive operations, pairs, projections, $\lambda$-abstractions and applications, with the usual typing
rules. The primitive operations form a set $\mathrm{Op}=\bigsqcup_k\mathrm{Op}_k$ of smooth functions $\R^k\to\R$ containing addition and multiplication
and closed under partial derivatives.

\paragraph{Semantics.} Put $\llbracket\mathtt{real}\rrbracket=\R$, $\llbracket\tau\times\sigma\rrbracket=\llbracket\tau\rrbracket\times\llbracket\sigma\rrbracket$ and
$\llbracket\tau\to\sigma\rrbracket=\cinf(\llbracket\tau\rrbracket,\llbracket\sigma\rrbracket)$ with the functional diffeology. By \cref{thm:ccc}, $\Diff$ is
Cartesian closed, so every term $x_1{:}\tau_1,\dots,x_n{:}\tau_n\vdash t:\tau$ has a denotation, a smooth map
$\llbracket t\rrbracket\colon\prod_i\llbracket\tau_i\rrbracket\to\llbracket\tau\rrbracket$.

\paragraph{The macro.} On types, $\AD(\mathtt{real})=\mathtt{real}\times\mathtt{real}$, and $\AD$ commutes with $\times$ and $\to$. On terms $\AD$
commutes with variables, pairing, projections, abstraction and application, and
\[
\AD(\underline c)=\langle\underline c,\underline0\rangle,\qquad
\AD\bigl(\mathsf{op}(t_1,\dots,t_k)\bigr)=\Bigl\langle\mathsf{op}(\vec u),\ \textstyle\sum_{i}\partial_i\mathsf{op}(\vec u)\cdot u_i'\Bigr\rangle
\quad\text{where }\langle u_i,u_i'\rangle=\AD(t_i).
\]

\begin{theorem}[Huot--Staton--V\'ak\'ar \cite{HSV}]\label{thm:AD}
Let $x_1{:}\mathtt{real},\dots,x_n{:}\mathtt{real}\vdash t:\mathtt{real}$ be a term, possibly using higher-order functions internally, and let
$f=\llbracket t\rrbracket\colon\R^n\to\R$ and $g=\llbracket\AD(t)\rrbracket\colon(\R\times\R)^n\to\R\times\R$. Then for all $x,v\in\R^n$,
\[
g\bigl((x_1,v_1),\dots,(x_n,v_n)\bigr)=\bigl(f(x),\ Df(x)\cdot v\bigr).
\]
\end{theorem}

\begin{proof}
Define, by induction on the type $\tau$, a relation $S_\tau\subseteq\cinf(\R,\llbracket\tau\rrbracket)\times\cinf(\R,\llbracket\AD\tau\rrbracket)$ between
smooth curves:
\begin{align*}
S_{\mathtt{real}}&=\set{(h,(h,h')) : h\in\cinf(\R,\R)},\\
S_{\tau\times\sigma}&=\set{((a_1,a_2),(b_1,b_2)) : (a_1,b_1)\in S_\tau,\ (a_2,b_2)\in S_\sigma},\\
S_{\tau\to\sigma}&=\set{(a,b) : \forall(c,d)\in S_\tau,\ \bigl(s\mapsto a(s)(c(s)),\ s\mapsto b(s)(d(s))\bigr)\in S_\sigma}.
\end{align*}
The last clause makes sense because a curve in a function space composed pointwise with a curve in its source is the composite of
$(a,c)\colon\R\to\cinf(\llbracket\tau\rrbracket,\llbracket\sigma\rrbracket)\times\llbracket\tau\rrbracket$ with the evaluation map, which is smooth.
The \emph{fundamental lemma} (\cref{exo:fundamental}) states: if $x_1{:}\tau_1,\dots,x_n{:}\tau_n\vdash t:\tau$ and $(a_i,b_i)\in S_{\tau_i}$, then
\[
\bigl(\llbracket t\rrbracket\circ(a_1,\dots,a_n),\ \llbracket\AD t\rrbracket\circ(b_1,\dots,b_n)\bigr)\in S_\tau .
\]
Apply it to $t$ of the theorem with $a_i(s)=x_i+sv_i$ and $b_i=(a_i,a_i')$, which lie in $S_{\mathtt{real}}$. The conclusion
$(f\circ a,\ g\circ b)\in S_{\mathtt{real}}$ means $g(b(s))=\bigl(f(a(s)),(f\circ a)'(s)\bigr)$; evaluate at $s=0$.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzcd}[column sep=4.2em,row sep=2.6em]
 & \mathsf{Gl} \arrow[d,"\text{projection}"]\\
\mathsf{Syn} \arrow[ur,dashed,"\text{fundamental lemma}"] \arrow[r,"{(\llbracket-\rrbracket,\ \llbracket\AD(-)\rrbracket)}"'] & \Diff\times\Diff
\end{tikzcd}
\caption{The proof of \cref{thm:AD} as a lifting problem. $\mathsf{Syn}$ is the syntactic category of the language. An object of $\mathsf{Gl}$ is a
triple $(X,X',S)$ with $S\subseteq\Diff(\R,X)\times\Diff(\R,X')$, and a morphism is a pair of smooth maps preserving the relations. $\mathsf{Gl}$ is
Cartesian closed and the projection functor preserves that structure; since $\mathsf{Syn}$ is the free Cartesian closed category on the primitives, a
lift exists as soon as each primitive operation preserves $S$, which is the chain rule.}\label{fig:gluing}
\end{figure}

Three comments. First, the role of diffeology is precise and minimal: the proof takes place in a Cartesian closed category containing $\R$ and its smooth
maps, in which \emph{curves in function spaces} are defined; \cref{thm:ccc} is the statement that $\Diff$ is one. Second, the same argument gives
correctness for sum types, inductive types and, with more work, reverse mode \cite{HSV}; coproducts in $\Diff$ are computed as in sets
(\cref{thm:topological}), which is what the extension uses. Third, the relation $S_\tau$ is a relation between plots. Logical relations over a
concrete site are a general technique, and the choice of site is a parameter: with smooth maps replaced by a class of piecewise analytic maps, the method applies to
programs with conditionals and recursion \cite{omegaPAP}.

\section{Symmetries: no differentiable canonical form}

Let a compact Lie group $G$ act linearly and orthogonally on $V=\R^n$; for instance the symmetric group permuting the points of a point cloud, or a
rotation group acting on coordinates. An invariant model is a function on $V/G$. A popular way to build one is \defn{canonicalisation}: choose a map
$y\colon V\to V$ that picks a representative of each orbit,
\[
y(gv)=y(v),\qquad y(v)\in G\cdot v\qquad(g\in G,\ v\in V),
\]
and apply an arbitrary network to $y(v)$. Sorting is a canonicalisation for the symmetric group acting on $\R^n$. Dym, Lawrence and Siegel show that
for many actions of interest no \emph{continuous} canonicalisation exists \cite{DymLawrenceSiegel}. Sorting is continuous, so continuity is not always
the obstruction. Differentiability always is, wherever there is isotropy.

\begin{theorem}[No differentiable canonicalisation at isotropy]\label{thm:no-canon}
Let $W\subseteq V$ be a $G$-invariant open set and $y\colon W\to V$ a canonicalisation. Let $v\in W$, with stabiliser $G_v$ and normal space
$N_v=(T_v(G\cdot v))^\perp$ to its orbit. If $y$ is differentiable at $v$, then $G_v$ acts trivially on $N_v$. Consequently:
\begin{enumerate}[label=\textup{(\alph*)}]
\item if $G_v$ acts non-trivially on $N_v$, no canonicalisation defined near $v$ is differentiable at $v$;
\item if $G$ is finite and acts faithfully, a canonicalisation is non-differentiable at every point with non-trivial stabiliser;
\item the quotient map $\pi\colon V\to V/G$ has a smooth local section near $[v]$ only if $G_v$ acts trivially on $N_v$.
\end{enumerate}
\end{theorem}
\begin{proof}
Write $y(v)=g_0v$. Replacing $y$ by $g_0^{-1}y$, which is again a canonicalisation, we may assume $y(v)=v$. Let $A=Dy(v)$.

\emph{$A$ is injective on $N_v$.} Let $n\in N_v$ with $An=0$. Then $y(v+tn)=v+o(t)$. Since $y(v+tn)=g_t(v+tn)$ for some $g_t\in G$ and $G$ acts by
isometries, $\abs{(v+tn)-g_t^{-1}v}=o(t)$, so the distance from $v+tn$ to the orbit $G\cdot v$ is $o(t)$. But the orbit is a compact embedded
submanifold and $n$ is normal to it at $v$, so by the tubular neighbourhood theorem the distance from $v+tn$ to the orbit is $t\abs n$ for small
$t\ge0$. Hence $n=0$.

\emph{$A$ is $G_v$-invariant.} For $h\in G_v$, $y(hw)=y(w)$ and $h$ is linear with $hv=v$; differentiating at $v$ gives $Ah=A$.

\emph{Conclusion.} $G_v$ preserves the orbit and fixes $v$, so it preserves $N_v$. For $n\in N_v$ and $h\in G_v$ we get $A(hn)=A(n)$ with
$hn,n\in N_v$, so $hn=n$.

(a) is the contrapositive. (b) For finite $G$ orbits are discrete and $N_v=V$, on which $G_v$ acts faithfully. (c) If $c$ is a smooth section of
$\pi$ on a D-open neighbourhood of $[v]$ then $y=c\circ\pi$ is a smooth canonicalisation near $v$.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \fill[hcsmist] (-1.9,-1.9) rectangle (1.9,1.9);
  \fill[hcsteal!25] (-1.9,-1.9) -- (1.9,1.9) -- (-1.9,1.9) -- cycle;
  \draw[hcsteal,line width=0.9pt] (-1.9,-1.9) -- (1.9,1.9);
  \draw[->,hcsgrey] (-2.1,0)--(2.2,0) node[right,hcsink]{$a$}; \draw[->,hcsgrey] (0,-2.1)--(0,2.2) node[above,hcsink]{$b$};
  \fill[hcsrust] (1.2,0.4) circle (1.6pt) node[below right]{$(a,b)$};
  \fill[hcsrust] (0.4,1.2) circle (1.6pt) node[above left]{$y(a,b)$};
  \draw[->,hcsrust,dashed] (1.15,0.47) -- (0.47,1.15);
  \fill[hcsink] (0.9,0.9) circle (1.6pt) node[below right,font=\footnotesize]{isotropy};
  \node[font=\footnotesize,align=center] at (0,-2.6) {sorting $\R^2\to\{a\le b\}$: a fold along the diagonal};
 \end{scope}
 \begin{scope}[xshift=7.3cm]
  \foreach \r in {0.45,0.9,1.35,1.8} \draw[hcsteal] (0,0) circle (\r);
  \fill[hcsink] (0,0) circle (1.8pt);
  \draw[hcsrust,line width=1pt] (0,0) -- (1.9,0);
  \draw[hcsrust,line width=1pt,dashed] (0,0) -- (-1.6,0.9);
  \node[font=\footnotesize,hcsrust] at (1.2,0.25) {section};
  \node[font=\footnotesize,align=center] at (0,-2.6) {$\Ort(2)$ on $\R^2$: a ray is a continuous section,\\ and no section is differentiable at the centre};
 \end{scope}
\end{tikzpicture}
\caption{Canonicalisation. Left: for the symmetric group $S_2$ the sorting map is continuous but folds the plane along the diagonal, where the
stabiliser acts by $-1$ on the normal line. Right: for rotations any section of the orbit map must select a ray, and its composite with the
quotient map, $v\mapsto\abs v\,e$, has a conical singularity at the fixed point.}\label{fig:canon}
\end{figure}

\begin{remark}[The converse, and the meaning]
By the slice theorem a neighbourhood of the orbit of $v$ is $G\times_{G_v}N_v$, so if $G_v$ acts trivially on $N_v$ the quotient is locally $N_v$
and a smooth local section exists. So \cref{thm:no-canon}(c) is an equivalence: \emph{$\pi$ has smooth local sections exactly over the points where
$V/G$ is locally the quotient by a free action}. This is \cref{thm:three-quotients} at the level of the orbit space: over those points the diffeological quotient
is the stack quotient and $\pi$ is a principal bundle onto its image; elsewhere the orbit space is the coarse space of a stack with non-trivial isotropy,
and a section would trivialise an isotropy group that is not trivial. Frame averaging and weighted frames \cite{DymLawrenceSiegel} can be read as
replacing a section of $V\to V/G$ by a section of an associated bundle of measures, which does exist.
\end{remark}

The alternative to canonicalisation is to compute invariant features. Choose generators $\sigma_1,\dots,\sigma_m$ of the algebra of invariant
polynomials, let $\sigma=(\sigma_1,\dots,\sigma_m)\colon V\to\R^m$, and let $\bar\sigma\colon V/G\to\sigma(V)$ be the induced map.

\begin{proposition}[Invariant features determine functions, not families]\label{prop:features}
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\bar\sigma\colon V/G\to\sigma(V)_{\Sub}$ is a smooth bijection.
\item \textup{(Schwarz \cite{Schwarz})} It induces an isomorphism on smooth functions: $\cinf(V/G)=\cinf(V)^G=\sigma^*\cinf(\R^m)=\bar\sigma^*\cinf(\sigma(V)_{\Sub})$.
\item It is not a diffeomorphism in general. For $G=\{\pm1\}$ on $\R$ and on $\C$, and for $G=\Ort(n)$ on $\R^n$ with $\sigma=\abs x^2$, the space
$\sigma(V)_{\Sub}$ has plots that do not lift to $V$ even locally. Moreover the spaces $\R^n/\Ort(n)$, $n\ge1$, are pairwise non-diffeomorphic and all
have the same image $[0,\infty)$ and the same ring of smooth functions.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) Invariant polynomials separate the orbits of a compact group. (ii) Schwarz's theorem is the middle equality; the outer ones are the universal
property of the quotient and the fact that a smooth function on $\sigma(V)_{\Sub}$ pulls back to a smooth invariant function on $V$. (iii) is
\cref{prop:delta1}, \cref{exo:cone-hilbert} and \IZ{Exercises~50--51}.
\end{proof}

So an invariant feature map is a faithful encoding of the orbit space for the purpose of defining smooth invariant \emph{functions}, and an unfaithful
one for the purpose of describing smooth \emph{families} of orbits: the feature space contains smooth curves and surfaces of feature values that are
not the features of any smooth family of inputs. A generative model trained in feature space can therefore produce smooth interpolations with no
smooth preimage. The orbit space $V/G$ with its quotient diffeology is the object whose plots are exactly the liftable families, and by the last sentence of (iii)
it determines the dimension of the data, which the features $\abs x^2$ do not.

\exercisesheading

\begin{exercise}[label=exo:one-neuron]{1}
For the one-neuron model $f((a,w),x)=a\tanh(wx)$ with $\Theta=\R^2$, $X=Y=\R$, determine the functional equivalence relation and describe $\mathcal H_q$.
\end{exercise}
\begin{solution}
Let $h(x)=a\tanh(wx)$. Then $h'(0)=aw$ and $h'''(0)=-2aw^3$. If $aw=0$ then $h=0$. If $aw\neq0$ and $a\tanh(wx)=a'\tanh(w'x)$, then $aw=a'w'$ and
$aw^3=a'w'^3$, so $w'^2=w^2$ and $(a',w')=\pm(a,w)$; conversely $\tanh$ is odd. So the classes are: the cross $\{aw=0\}$, which is the fibre over the
zero function, and the pairs $\{\pm(a,w)\}$ with $aw\ne0$. $\mathcal H_q$ is the plane with the cross collapsed to one point and the remaining four
open quadrants identified in antipodal pairs: two open quadrants, each a manifold, glued at a single point through which smooth families can pass
only by lifting to curves in the plane that reach the cross. It is a manifold away from that point and not a manifold at it.
\end{solution}

\begin{exercise}[label=exo:AD-example]{2}
Apply the macro $\AD$ to $x{:}\mathtt{real}\vdash\mathsf{times}(x,\mathsf{sin}(x)):\mathtt{real}$ and to
$x{:}\mathtt{real}\vdash(\lambda f.\,f(f\,x))\,(\lambda z.\,\mathsf{times}(z,z)):\mathtt{real}$, and check \cref{thm:AD} on both.
\end{exercise}
\begin{solution}
Write the input as $\langle x,x'\rangle$. For the first term, $\AD(\mathsf{sin}(x))=\langle\sin x,\cos x\cdot x'\rangle$ and so
\[
\AD(t)=\bigl\langle x\sin x,\ \sin x\cdot x'+x\cdot(\cos x\cdot x')\bigr\rangle ,
\]
using $\partial_1\mathsf{times}(u_1,u_2)=u_2$ and $\partial_2\mathsf{times}=u_1$. The second component is $(x\sin x)'x'$. For the second term,
$\AD$ commutes with abstraction and application, so $\AD(t)=(\lambda F.\,F(F\,\langle x,x'\rangle))\,(\lambda\langle z,z'\rangle.\,\langle z^2,2zz'\rangle)$,
where $F$ now has type $\mathtt{real}^2\to\mathtt{real}^2$. Evaluating, $F\langle x,x'\rangle=\langle x^2,2xx'\rangle$ and
$F(F\langle x,x'\rangle)=\langle x^4,\,2x^2\cdot2xx'\rangle=\langle x^4,4x^3x'\rangle$. The term denotes $x\mapsto x^4$, with derivative $4x^3$. The
higher-order function $\lambda f.\,f(f\,x)$ was never differentiated ``as a function of $f$''; the macro simply changed the type of its argument.
\end{solution}

\begin{exercise}[label=exo:sort]{2}
Show that $y(a,b)=(\min(a,b),\max(a,b))$ is a continuous canonicalisation for $S_2$ acting on $\R^2$, and verify the conclusion of \cref{thm:no-canon}
on the diagonal.
\end{exercise}
\begin{solution}
$\min$ and $\max$ are continuous and symmetric, and $y(a,b)$ is $(a,b)$ or $(b,a)$. At $v=(a,a)$ the stabiliser is $S_2$, the orbit is the point $v$,
and $N_v=\R^2$. The swap acts on $N_v$ with eigenvalues $+1$ on the diagonal direction and $-1$ on the antidiagonal direction $(1,-1)$, so it acts
non-trivially and the theorem predicts non-differentiability. Indeed $y(a+t,a-t)=(a-\abs t,a+\abs t)$, which is not differentiable at $t=0$. Away from
the diagonal the stabiliser is trivial and $y$ is locally the identity or the swap, hence smooth.
\end{solution}

\begin{exercise}[label=exo:hessian]{3}
Let a Lie group $G$ act smoothly on a manifold $\Theta$ and let $L$ be a smooth $G$-invariant function. Show that at every critical point $\theta$
of $L$ the Hessian of $L$ vanishes on the tangent space to the orbit $G\cdot\theta$. Apply this to the rescaling symmetry
$(a,w)\mapsto(ca,w/c)$ of the model $f((a,w),x)=a\cdot\mathrm{relu}(wx)$ restricted to $a,w>0$.
\end{exercise}
\begin{solution}
For $\xi$ in the Lie algebra let $\xi_\Theta$ be the corresponding vector field on $\Theta$. Invariance gives $\dd L(\xi_\Theta)=0$ identically.
Differentiate this function in the direction of a tangent vector $u$ at a critical point $\theta$, in local coordinates:
$0=\partial_u(\partial_iL\,\xi^i_\Theta)=\mathrm{Hess}L(u,\xi_\Theta(\theta))+\partial_iL(\theta)\,\partial_u\xi^i_\Theta$, and the second term vanishes
because $\dd L(\theta)=0$. Hence $\mathrm{Hess}L(\theta)(u,\xi_\Theta(\theta))=0$ for all $u$. For the rescaling symmetry on $\{a,w>0\}$, $\mathrm{relu}(wx)$
is positively homogeneous in $w$, so $f$ and therefore any loss is invariant; the group is $(\R_{>0},\cdot)$ with generating vector field $(a,-w)$. So
at every critical point the Hessian has $(a,-w)$ in its kernel: critical points are never isolated and never non-degenerate. In $\mathcal H_q$ the
whole orbit is one point, and the degeneracy disappears; this is the practical meaning of the universal property in \cref{thm:learning}(iii).
\end{solution}

\begin{exercise}[label=exo:risk]{3}
Prove \cref{thm:learning}(ii), and show that evaluation at a point $x_0$ is a smooth map $\cinf(X,\R^k)\to\R^k$ which is the special case $\mu=\delta$.
\end{exercise}
\begin{solution}
Let $P\colon U\to\cinf(X,\R^k)$ be a plot. By \cref{def:functional} the map $(r,x)\mapsto P(r)(x)$ is smooth on $U\times X$, so
$F(r,x,y)=\ell(P(r)(x),y)$ is smooth on $U\times X\times\R^k$. We must show that $I(r)=\int F(r,x,y)\,\dd\mu(x,y)$ is smooth on $U$. Let $C$ be the
compact support of $\mu$ and $B\subset U$ a compact ball. Every partial derivative $\partial_r^\beta F$ is continuous, hence bounded on $B\times C$, and
$\mu$ is finite. By dominated convergence $I$ is continuous on $B$, and differentiation under the integral sign is justified for every
$\partial_r^\beta$ by the mean value inequality with the bound on $\partial_r^{\beta+e_i}F$; induction on $\abs\beta$ gives $I\in\cinf(B)$. So
$\mathcal R\circ P$ is smooth for every plot $P$, i.e.\ $\mathcal R$ is smooth. Then $L=\mathcal R\circ\rho$ is smooth, it is constant on the fibres of
$\rho$, so it descends to $\mathcal H_q$ by the universal property of the quotient, and to $\mathcal H_s$ as the restriction of $\mathcal R$. For the
last assertion take $\mu$ the Dirac measure at $(x_0,0)$ and $\ell(h,y)=h_j$; or note directly that evaluation at $x_0$ is the composite of
$\ev\colon\cinf(X,\R^k)\times X\to\R^k$ with $h\mapsto(h,x_0)$.
\end{solution}

\begin{exercise}[label=exo:fundamental]{4}
Prove the fundamental lemma used in the proof of \cref{thm:AD}.
\end{exercise}
\begin{solution}
We prove by induction on the typing derivation of $\Gamma\vdash t:\tau$, with $\Gamma=x_1{:}\tau_1,\dots,x_n{:}\tau_n$, that for all
$(a_i,b_i)\in S_{\tau_i}$ the pair $\bigl(\llbracket t\rrbracket\circ\vec a,\ \llbracket\AD t\rrbracket\circ\vec b\bigr)$ lies in $S_\tau$. Here
$\vec a=(a_1,\dots,a_n)\colon\R\to\llbracket\Gamma\rrbracket$ and $\vec b\colon\R\to\llbracket\AD\Gamma\rrbracket$; both composites are smooth curves
because denotations are smooth maps.

\emph{Variable} $x_i$: the pair is $(a_i,b_i)$.

\emph{Constant} $\underline c$: the pair is $(s\mapsto c,\ s\mapsto(c,0))$, and $0$ is the derivative of the constant curve.

\emph{Operation} $\mathsf{op}(t_1,\dots,t_k)$: by induction $\llbracket t_j\rrbracket\circ\vec a=h_j$ and $\llbracket\AD t_j\rrbracket\circ\vec b=(h_j,h_j')$ for
smooth $h_j\colon\R\to\R$. By the definition of the macro,
\[
\llbracket\AD\,\mathsf{op}(\vec t)\rrbracket\circ\vec b=\Bigl(\mathsf{op}(h_1,\dots,h_k),\ \sum_j\partial_j\mathsf{op}(h_1,\dots,h_k)\,h_j'\Bigr),
\]
and by the chain rule the second component is the derivative of $s\mapsto\mathsf{op}(h_1(s),\dots,h_k(s))=\llbracket\mathsf{op}(\vec t)\rrbracket(\vec a(s))$.

\emph{Pairing and projections}: immediate from the definition of $S_{\tau\times\sigma}$ and the fact that $\AD$ commutes with them.

\emph{Application} $t\,u$ with $\Gamma\vdash t:\sigma\to\tau$ and $\Gamma\vdash u:\sigma$: by induction
$(a,b)=(\llbracket t\rrbracket\circ\vec a,\llbracket\AD t\rrbracket\circ\vec b)\in S_{\sigma\to\tau}$ and
$(c,d)=(\llbracket u\rrbracket\circ\vec a,\llbracket\AD u\rrbracket\circ\vec b)\in S_\sigma$. By the definition of $S_{\sigma\to\tau}$ the pair
$(s\mapsto a(s)(c(s)),\ s\mapsto b(s)(d(s)))$ is in $S_\tau$, and these curves are $\llbracket t\,u\rrbracket\circ\vec a$ and
$\llbracket\AD(t\,u)\rrbracket\circ\vec b$ because $\AD(t\,u)=\AD t\ \AD u$ and application denotes evaluation.

\emph{Abstraction} $\lambda x{:}\sigma.\,t$ with $\Gamma,x{:}\sigma\vdash t:\tau$: we must show that
$(a,b)=(\llbracket\lambda x.t\rrbracket\circ\vec a,\ \llbracket\AD(\lambda x.t)\rrbracket\circ\vec b)\in S_{\sigma\to\tau}$. Let $(c,d)\in S_\sigma$. Then
$a(s)(c(s))=\llbracket t\rrbracket(\vec a(s),c(s))$ and, since $\AD(\lambda x.t)=\lambda x.\AD t$,
$b(s)(d(s))=\llbracket\AD t\rrbracket(\vec b(s),d(s))$. The extended tuples $(\vec a,c)$ and $(\vec b,d)$ are related componentwise, so the induction
hypothesis for $t$ in the context $\Gamma,x{:}\sigma$ gives exactly that these two curves are related by $S_\tau$.

This completes the induction. The only case with analytic content is that of the primitive operations; the rest is the statement that the
relations $S_\tau$ are defined so as to be preserved by the Cartesian closed structure, and smoothness of all curves involved is \cref{thm:ccc}.
\end{solution}



\chapter{Artificial intelligence: planning, observation, semantics}\label{ch:ai}
\chaptermark{Artificial intelligence}

\begin{chapabstract}
Three questions about agents, answered in $\Diff$. When can an agent plan motions smoothly in the start and goal? Exactly when its configuration
space is smoothly contractible, and for quasi-tori exactly when it is given a homotopy class of route. What can an agent learn about a space from
smooth scalar observations alone? Its reflexive hull, and nothing more. In what categories do programs that manipulate functions,
probabilities and derivatives have semantics? In categories of concrete sheaves, of which $\Diff$ is the smooth instance.
\end{chapabstract}
\source{\IZ{art.~5.1--5.11} (paths, homotopy, contractibility), \IZ{Exercises~79--80} (reflexive spaces), \IZ{art.~1.57--1.60} (functional diffeology).}

\section{Smooth motion planning}

Let $X$ be the configuration space of a mechanical system. For rigid robots it is a manifold; for linkages at singular configurations, for
identical robots that may be relabelled, for soft bodies whose configurations are embeddings of a curve or a surface, it is not, but it is always a
diffeological space. The \defn{endpoint map}
\[
\mathrm{ends}\colon\Paths(X)\longrightarrow X\times X,\qquad\gamma\longmapsto(\gamma(0),\gamma(1))
\]
is smooth. Following Farber \cite{Farber}, a \defn{motion planner} on $A\subseteq X\times X$ is a section of $\mathrm{ends}$ over $A$; we call it
\emph{smooth} if it is smooth as a map $A_{\Sub}\to\Paths(X)$, which by \cref{thm:ccc} means that the path $s(a,b)$ depends smoothly on $(a,b)$ jointly
with time. The \defn{smooth topological complexity} $\TC^D(X)$ is the least number of D-open subsets covering $X\times X$ each of which carries a
smooth motion planner, or $\infty$.

\begin{theorem}[Smooth planners]\label{thm:planner}
Let $X$ be a non-empty diffeological space.
\begin{enumerate}[label=\textup{(\roman*)}]
\item $X$ has a smooth motion planner on all of $X\times X$ if and only if $X$ is smoothly contractible.
\item If $X$ is smoothly dominated by $Y$ --- there are smooth $f\colon X\to Y$ and $g\colon Y\to X$ with $g\circ f$ smoothly homotopic to
$\id_X$ --- then $\TC^D(X)\le\TC^D(Y)$. In particular $\TC^D$ is an invariant of smooth homotopy type.
\item If $\TC^D(X)<\infty$ then $X$ is connected, and if $\TC^D(X)=1$ then $\Pi X\simeq\ast$.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) Let $s$ be a smooth planner and fix $x_0$. The map $H(x,t)=s(x,x_0)(t)$ is smooth on $X\times\R$ by \cref{thm:ccc}, with $H(x,0)=x$ and
$H(x,1)=x_0$: a contraction. Conversely let $H\colon X\times\R\to X$ be smooth with $H_0=\id$ and $H_1\equiv x_0$, and let $\lambda$ be a smashing
function (\cref{exo:smash}). Define
\[
s(x,y)(t)=\begin{cases}H\bigl(x,\lambda(2t)\bigr)&t\le\tfrac12,\\[0.3ex]H\bigl(y,\lambda(2-2t)\bigr)&t\ge\tfrac12.\end{cases}
\]
Both expressions are smooth in $(x,y,t)$ and both equal $x_0$ for $t$ near $\tfrac12$, so $s\colon X\times X\times\R\to X$ is smooth, i.e.\
$s\colon X\times X\to\Paths(X)$ is smooth. And $s(x,y)(0)=H(x,0)=x$, $s(x,y)(1)=H(y,0)=y$. (ii) is \cref{exo:TC-invariance}. (iii) A planner on
a D-open cover joins any two points by a path. If $\TC^D(X)=1$, apply (i) and \cref{prop:Pi-homotopy}.
\end{proof}

The proof of (i) is Farber's, and that is the point: in $\Diff$ it holds verbatim for every space, because ``a family of paths depending
smoothly on its endpoints'' and ``a smooth map into the path space'' are the same thing. For manifolds one usually settles for continuous planners;
for the singular and infinite-dimensional configuration spaces listed above there was previously no category in which to say ``smooth planner''
at all.

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
 \begin{scope}
  \draw[hcsteal,line width=0.9pt] (0,0) circle (1.3);
  \fill[hcsink] (150:1.3) circle (1.7pt) node[left=3pt]{$a$};
  \fill[hcsink] (20:1.3) circle (1.7pt) node[right=3pt]{$b$};
  \draw[hcsrust,line width=1.3pt,->] (150:1.45) arc (150:20:1.45);
  \draw[hcsgold,line width=1.3pt,->,dashed] (150:1.15) arc (150:380:1.15);
  \node[font=\footnotesize,align=center,text width=4.4cm] at (0,-2.15) {$S^1$: shortest arc (solid) or always anticlockwise (dashed), each on an open set; $\TC^D(S^1)=2$};
 \end{scope}
 \begin{scope}[xshift=5.0cm]
  \draw[hcsteal,line width=0.9pt] (-1.4,0)--(1.4,0); \draw[hcsteal,line width=0.9pt] (0,-1.4)--(0,1.4);
  \fill[hcsink] (1.0,0) circle (1.7pt) node[above]{$a$}; \fill[hcsink] (0,-0.9) circle (1.7pt) node[left]{$b$};
  \draw[hcsrust,line width=1.3pt,->] (1.0,-0.12) -- (0.12,-0.12) -- (0.12,-0.9);
  \fill[hcsgold] (0,0) circle (2.2pt);
  \node[font=\footnotesize,align=center,text width=4.0cm] at (0,-2.15) {the cross: contract to the node; one global smooth planner};
 \end{scope}
 \begin{scope}[xshift=9.9cm]
  \fill[hcsmist] (-1.5,-1.3) rectangle (1.5,1.3);
  \begin{scope}\clip (-1.5,-1.3) rectangle (1.5,1.3);
   \foreach \c in {-1.5,-0.9,-0.3,0.9,1.5} \draw[hcsgrey!70,dashed] (-1.6,-1.6+\c) -- (1.6,1.6+\c);
   \draw[hcsrust,line width=0.8pt] (-1.6,-1.3) -- (1.6,1.9);
  \end{scope}
  \fill[hcsink] (-0.8,-0.5) circle (1.7pt) node[below right,font=\footnotesize]{$(x,y)$};
  \fill[hcsink] (0.1,0.4) circle (1.7pt) node[above left,font=\footnotesize]{$(x{+}\lambda,y{+}\lambda)$};
  \node[font=\footnotesize,align=center,text width=4.0cm] at (0,-2.15) {$\Tal$: plan on $\R^2/\Lam_{\mathrm{diag}}$, i.e.\ given a class of route};
 \end{scope}
\end{tikzpicture}
\caption{Three planning problems. On the circle no single smooth rule works. On the cross, a singular space, one does. On the irrational torus no
rule works on any D-open set, but a smooth rule exists once the homotopy class of the route is part of the input (\cref{prop:planner-torus}).}\label{fig:planners}
\end{figure}

\begin{proposition}[Planning on quasi-tori]\label{prop:planner-torus}
Let $\Gamma\subset\R^n$ be a dense countable subgroup and $T_\Gamma=\R^n/\Gamma$, for instance $\Tal$.
\begin{enumerate}[label=\textup{(\roman*)}]
\item The only D-open subsets of $T_\Gamma\times T_\Gamma$ are $\varnothing$ and the whole space, and $T_\Gamma$ is not contractible if
$\Gamma\ne0$. Hence $\TC^D(T_\Gamma)=\infty$.
\item Let $\Pi_1(T_\Gamma)=(\R^n\times\R^n)/\Gamma_{\mathrm{diag}}$, the quotient by the diagonal action; it is the space of triples (start, goal,
homotopy class of paths between them), and it covers $T_\Gamma\times T_\Gamma$ with group $\Gamma$. The straight-line rule
\[
s[x,y](t)=q\bigl((1-t)x+ty\bigr)
\]
is a well-defined smooth map $\Pi_1(T_\Gamma)\to\Paths(T_\Gamma)$ lifting the covering: a smooth planner whose input includes a class of route.
\item No smooth planner defined on $T_\Gamma\times T_\Gamma$, or on any non-empty D-open subset of it, exists; and $s$ does not descend, because
$s[x,y]$ and $s[x,y+\gamma]$ have the same endpoints and are not homotopic for $\gamma\ne0$.
\end{enumerate}
\end{proposition}
\begin{proof}
(i) \cref{exo:Dtop-Talpha} for the D-topology; $\pi_1(T_\Gamma)=\Gamma$ by \cref{cor:TGamma}; then \cref{thm:planner}(i). (ii) The diagonal action is
principal, so $\Pi_1(T_\Gamma)$ is a diffeological space and $\R^{2n}\to\Pi_1(T_\Gamma)\to T_\Gamma^2$ are coverings; a point of $\Pi_1(T_\Gamma)$ over
$(a,b)$ is a choice of lifts of $a,b$ up to simultaneous translation, which is a homotopy class of paths from $a$ to $b$ by \cref{exo:pi1-Talpha}. The
map $(x,y,t)\mapsto q((1-t)x+ty)$ is smooth and invariant under $(x,y)\mapsto(x+\gamma,y+\gamma)$, since $q$ is $\Gamma$-invariant; so it descends along
the subduction $\R^{2n}\times\R\to\Pi_1(T_\Gamma)\times\R$. (iii) The first statement is (i). The lifts of $s[x,y]$ and $s[x,y+\gamma]$ starting at $x$
end at $y$ and $y+\gamma$.
\end{proof}

For an agent this is a statement about what must be sensed. A system whose state is known only modulo a dense group --- two encoders with
incommensurable periods, a phase known modulo two incommensurable clocks --- cannot be controlled by any smooth law in the quotient state alone, not
even locally. It can be controlled smoothly given a lift, that is, with odometry; and the amount of extra state needed is exactly the fundamental
group. In stack-theoretic terms, the planner is defined on the atlas of the fundamental groupoid.

\begin{remark}[Cohomological bounds]
A D-open cover $\{A,B\}$ of $X$ is a pushout in $\SmSet$, hence a homotopy pushout in $\Hh$, and $\Pi$ preserves it; so Mayer--Vietoris holds for the
cohomology of the shape, and the usual lower bound of $\TC$ by the zero-divisor cup-length of $H^\bullet(\Pi X)$ holds for $\TC^D$ with the usual proof.
For manifolds $\TC^D\ge\TC$ trivially; whether equality holds is a question about smoothing sections (\cref{ch:coda}).
\end{remark}

\section{Observation versus intervention}

An agent can interrogate an unknown smooth world $X$ in two ways. It can \emph{observe}: measure smooth real-valued quantities $f\colon X\to\R$. Or it
can \emph{intervene}: run a smoothly parametrised family of experiments $P\colon U\to X$. A diffeology is a specification of the possible
interventions; a Sikorski or Fr\"olicher structure is a specification of the possible observations. For a set $X$, a set $\mathcal D$ of
parametrisations and a set $\mathcal F$ of real functions, define
\begin{align*}
\mathrm{Fun}(\mathcal D)&=\set{f\colon X\to\R : f\circ P\text{ is smooth for all }P\in\mathcal D},\\
\mathrm{Plot}(\mathcal F)&=\set{P\in\mathrm{Param}(X) : f\circ P\text{ is smooth for all }f\in\mathcal F}.
\end{align*}

\begin{theorem}[The observation--intervention Galois connection]\label{thm:galois}
\begin{enumerate}[label=\textup{(\roman*)}]
\item $\mathrm{Fun}$ and $\mathrm{Plot}$ are order-reversing, $\mathcal D\subseteq\mathrm{Plot}\,\mathrm{Fun}(\mathcal D)$,
$\mathcal F\subseteq\mathrm{Fun}\,\mathrm{Plot}(\mathcal F)$, and $\mathrm{Fun}\,\mathrm{Plot}\,\mathrm{Fun}=\mathrm{Fun}$,
$\mathrm{Plot}\,\mathrm{Fun}\,\mathrm{Plot}=\mathrm{Plot}$.
\item $\mathrm{Plot}(\mathcal F)$ is a diffeology for every $\mathcal F$. For a diffeology $\mathcal D$, the \defn{reflexive hull}
$\hat{\mathcal D}=\mathrm{Plot}\,\mathrm{Fun}(\mathcal D)$ is the largest diffeology on $X$ with the same smooth real functions as $\mathcal D$.
\item Two diffeologies on $X$ have the same smooth real functions if and only if they have the same reflexive hull.
\item $X\mapsto\hat X=(X,\hat{\mathcal D})$ is a functor, and $X\to\hat X$ is the universal smooth map from $X$ to a \defn{reflexive} space, one with
$\mathcal D=\hat{\mathcal D}$.
\item Manifolds, half-spaces and corners are reflexive. The hull of $\Tal$ is the coarse diffeology; the hull of $\dten_1=\R/\{\pm1\}$ is the
half-line $H$; the hull of the wire diffeology on $\R^n$ is the standard diffeology.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) is formal for any relation: here the relation between $P$ and $f$ is ``$f\circ P$ is smooth''. (ii) Constants, locality and smooth
reparametrisation are each preserved by the condition ``$f\circ P$ smooth'', so $\mathrm{Plot}(\mathcal F)$ satisfies \ref{D1}--\ref{D3}. By (i),
$\mathrm{Fun}(\hat{\mathcal D})=\mathrm{Fun}(\mathcal D)$, and if $\mathcal D'$ is a diffeology with $\mathrm{Fun}(\mathcal D')=\mathrm{Fun}(\mathcal D)$
then $\mathcal D'\subseteq\mathrm{Plot}\,\mathrm{Fun}(\mathcal D')=\hat{\mathcal D}$. (iii) follows. (iv) Let $f\colon X\to Y$ be smooth and
$P\in\hat{\mathcal D}_X$. For $g\in\mathrm{Fun}(\mathcal D_Y)$ we have $g\circ f\in\mathrm{Fun}(\mathcal D_X)$, so $g\circ f\circ P$ is smooth; hence
$f\circ P\in\hat{\mathcal D}_Y$. So $f\colon\hat X\to\hat Y$ is smooth, and if $Y$ is reflexive $f$ factors through $X\to\hat X$, uniquely since that
map is the identity on points. (v) For a manifold $M$, let $P$ be a parametrisation along which all smooth functions are smooth. Testing against bump
functions shows $P$ is continuous, and testing against coordinate functions cut off by bump functions shows $P$ is smooth in charts. Half-spaces and
corners: the same argument with \cref{thm:halfspace}. For $\Tal$, $\mathrm{Fun}$ is the constants (\cref{prop:Talpha-basic}) and every parametrisation is
smooth along constants. For $\dten_1$, $\mathrm{Fun}$ is $\set{g\circ\mathrm{sq}:g\in\cinf(\R)}$ by \cref{exo:halfline-functions}, and a parametrisation
$P$ of $[0,\infty)$ with $g\circ P$ smooth for all smooth $g$ is a smooth map into $\R$ with values in $[0,\infty)$: a plot of $H$. For the wire
diffeology, $\mathrm{Fun}$ consists of the functions smooth along all smooth curves, which by Boman's theorem \cite{Boman} are the smooth functions; then
$\mathrm{Plot}$ of those is the standard diffeology by the manifold case.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \node[hcsnode,minimum width=3.9cm,minimum height=2.6cm,align=center] (D) at (0,0) {};
  \node[hcsnodeb,minimum width=3.9cm,minimum height=2.6cm,align=center] (F) at (7.4,0) {};
  \node at (0,1.6) {diffeologies on $X$ (interventions)};
  \node at (7.4,1.6) {function sets on $X$ (observations)};
  \node (d1) at (-0.9,0.65) {$\mathcal D$}; \node (d2) at (0.9,-0.65) {$\hat{\mathcal D}$};
  \node (f1) at (7.4,0) {$\mathrm{Fun}(\mathcal D)=\mathrm{Fun}(\hat{\mathcal D})$};
  \draw[->] (d1) to[bend left=12] node[above,font=\footnotesize]{$\mathrm{Fun}$} (f1);
  \draw[->] (f1) to[bend left=12] node[below,font=\footnotesize]{$\mathrm{Plot}$} (d2);
  \draw[hookr,hcsrust] (d1) -- node[left,font=\footnotesize]{$\subseteq$} (d2);
  \node[font=\footnotesize,align=center] at (3.7,-1.9) {an observer sees $\mathcal D$ only through $\hat{\mathcal D}$: $\Tal\rightsquigarrow$ coarse,
  \ $\R/\{\pm1\}\rightsquigarrow[0,\infty)$, \ wire $\R^2\rightsquigarrow\R^2$};
\end{tikzpicture}
\caption{The Galois connection between interventions and observations. Its closed elements on the left are the reflexive diffeologies.}\label{fig:galois}
\end{figure}

\begin{theorem}[\cite{BIKW}; \IZ{Exercises~79--80}]\label{thm:reflexive}
The full subcategory of reflexive diffeological spaces is isomorphic to the category of Fr\"olicher spaces, and it is a reflective subcategory of
$\Diff$ with reflector $X\mapsto\hat X$.
\end{theorem}

Together these make a precise epistemic statement. \emph{An agent restricted to smooth scalar observations can identify a smooth world only up to
its reflexive hull.} It cannot tell the irrational torus from a structureless set, the orbifold $\R/\{\pm1\}$ from a half-line, or a plane in which
only one-dimensional motions are possible from an ordinary plane. Each pair is separated by an intervention: a plot of one that is not a plot of the
other. The hull is a closure operator, so there is a canonical ``most permissive world consistent with all observations'', and by the theorem
observation-based learning of smooth structure converges, at best, to that world. This is the differential-geometric version of the familiar
gap between observational and interventional data, and the reason is the one given in \cref{sec:fn-vs-plots}: observations are maps out, quotients
are colimits, and the maps out of a colimit do not determine the diagram of which it is the colimit.

\section{Semantic universes for programs}

\Cref{thm:AD} used one property of $\Diff$: it is a Cartesian closed category of spaces defined by plots. The same construction over other sites gives
the semantic categories used for probabilistic and differentiable programming, and the theorem that makes them work is the same.

\begin{theorem}[Cartesian closure for concrete sheaves; \cite{Dubuc,BaezHoffnung}]\label{thm:ccc-general}
Let $\mathcal C$ be a concrete site with finite products, preserved by the functor of points. Then $\ConcSh(\mathcal C)$ is Cartesian closed: for
concrete sheaves $X,Y$, the set $\Hom(X,Y)$ with plots
\[
\set{P\colon|U|\to\Hom(X,Y) : (u,x)\mapsto P(u)(x)\text{ is a morphism }U\times X\to Y}
\]
is a concrete sheaf $Y^X$, and $\Hom(Z\times X,Y)\cong\Hom(Z,Y^X)$ naturally.
\end{theorem}
\begin{proof}
The proof of \cref{thm:ccc} in \cref{exo:ccc} used three facts: a plot is a morphism from a representable, products of representables are
representable, and a pair of plots is a plot of the product. All hold here. It remains to see that $Y^X$ satisfies the sheaf condition. Let
$P\colon|U|\to\Hom(X,Y)$ restrict to plots on a covering family $\{U_i\to U\}$. A plot of $U\times X$ is a pair $(\rho,Q)\colon V\to U\times X$; the
pullback of the cover along $\rho$ is refined by a cover $\{V_j\to V\}$ on each member of which $\rho$ factors through some $U_i$, so
$v\mapsto P(\rho(v))(Q(v))$ is a plot of $Y$ on each $V_j$, hence a plot of $Y$ because $Y$ is a sheaf.
\end{proof}

\begin{corollary}[Quasi-Borel spaces; Heunen--Kammar--Staton--Yang \cite{HKSY}]\label{cor:qbs}
A \emph{quasi-Borel space} is a set $X$ with a set $M_X$ of functions $\R\to X$ containing the constants, closed under precomposition with Borel
maps $\R\to\R$, and closed under gluing along countable Borel partitions of $\R$. These are the concrete sheaves on the site of standard Borel
spaces with countable Borel covers, and they form a Cartesian closed category, whereas the category of measurable spaces is not Cartesian closed
\cite{Aumann}.
\end{corollary}

The three axioms of a quasi-Borel space are \ref{D1}, \ref{D3} and \ref{D2} with ``smooth'' replaced by ``Borel'' and open covers by countable Borel
partitions. The parallel is exact (\cref{tab:semantics}): in each row a classical category of spaces lacks function spaces, and the category of concrete
sheaves on its site of parameter spaces has them. For artificial intelligence the relevance is that a probabilistic program which
takes a likelihood function as an argument, or a differentiable program which takes a loss function as an argument, has a denotation only in the
right-hand column.

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{3.1cm}p{3.5cm}p{3.6cm}p{3.1cm}@{}}\toprule
classical spaces & defect & concrete sheaves & used for\\\midrule
manifolds & no $\cinf(M,N)$, no quotients & diffeological spaces & differentiable programming \cite{HSV}\\
measurable spaces & no measurable $Y^X$ \cite{Aumann} & quasi-Borel spaces & probabilistic programming \cite{HKSY}\\
piecewise analytic maps & as above, plus recursion & $\omega$PAP spaces & AD with control flow \cite{omegaPAP}\\\bottomrule
\end{tabular}
\caption{Three instances of one theorem. The second column is why semantics cannot be given in the first; the third is \cref{thm:ccc-general}.}\label{tab:semantics}
\end{table}

\exercisesheading

\begin{exercise}[label=exo:planner-star]{1}
Write down a global smooth motion planner on a star-shaped open subset of $\R^n$ and on the cross $K=\set{xy=0}\subset\R^2$.
\end{exercise}
\begin{solution}
Let $X$ be star-shaped about $x_0$, or $X=K$ with $x_0=0$. In both cases $H(x,t)=x_0+(1-\lambda(t))(x-x_0)$ is a smooth contraction with values in
$X$: for the cross, scaling preserves $\set{xy=0}$, and $H$ is smooth into $\R^2$ with values in $K$, hence smooth into $K_{\Sub}$. The planner of
\cref{thm:planner}(i) assigns the path that runs from $x$ to $x_0$ along the segment, is stationary near $x_0$, and runs on to $y$. On a convex set the simpler rule
$s(x,y)(t)=(1-t)x+ty$ also works; on the cross it does not, since the segment between points on different arms is not contained in $K$.
\end{solution}

\begin{exercise}[label=exo:TC-circle]{2}
Show that $\TC^D(S^1)=2$.
\end{exercise}
\begin{solution}
$S^1$ is not contractible ($\pi_1=\Z$), so $\TC^D(S^1)\ge2$ by \cref{thm:planner}(i). Write points as $e^{i\theta}$. On
$A_1=\set{(a,b):b\ne-a}$ there is a unique $\phi\in(-\pi,\pi)$ with $b=ae^{i\phi}$, depending smoothly on $(a,b)$; put
$s_1(a,b)(t)=ae^{i\lambda(t)\phi}$, the shortest arc. On $A_2=\set{(a,b):b\ne a}$ there is a unique $\psi\in(0,2\pi)$ with $b=ae^{i\psi}$, depending
smoothly on $(a,b)$; put $s_2(a,b)(t)=ae^{i\lambda(t)\psi}$, the anticlockwise arc. Both are smooth sections of the endpoint map over open sets, and
$A_1\cup A_2=S^1\times S^1$.
\end{solution}

\begin{exercise}[label=exo:unlabelled]{2}
The configuration space of two indistinguishable points on a line is $C=\R^2/S_2$. Show that it has a global smooth motion planner, although
(\cref{thm:no-canon}) there is no smooth way to label the two points.
\end{exercise}
\begin{solution}
In the coordinates $u=a+b$, $w=a-b$ the swap is $(u,w)\mapsto(u,-w)$, so $C\cong\R\times\dten_1$. Both factors are smoothly contractible
(\cref{exo:contractible}), hence so is the product, and \cref{thm:planner}(i) gives a planner. Explicitly, the contraction
$h((a,b),t)=(1-\lambda(t))(a,b)$ of $\R^2$ is $S_2$-equivariant and descends: the planner moves both points to the origin and out again. A smooth labelling
would be a smooth section of $\R^2\to C$ near the diagonal, which does not exist by \cref{exo:sort} and \cref{thm:no-canon}. Planning and labelling are
different tasks: the planner is a map out of $C\times C$, the labelling a map out of $C$ into the covering space.
\end{solution}

\begin{exercise}[label=exo:hull-wire]{3}
Let $X$ be $\R^2$ with the wire diffeology and $X'$ the set $\R^2$ with the diffeology $\mathcal D'$ generated by the lines parallel to the two axes.
Determine $\mathrm{Fun}$ for both. Show that an observer cannot distinguish $X$ from the standard plane, can distinguish $X'$ from it, and that
$X'$ is nevertheless not reflexive.
\end{exercise}
\begin{solution}
\emph{$X$.} By \cref{thm:galois}(v) the hull of the wire diffeology is the standard one: same observables as the plane. The identity
$\R^2\to\R^2$ is an intervention available in the plane and not in $X$ (\cref{exo:wire}).

\emph{$X'$.} A plot is locally constant or locally of the form $r\mapsto(h(r),c)$ or $r\mapsto(c,h(r))$ with $h$ smooth. So
$\mathrm{Fun}(\mathcal D')$ is the set of \emph{separately} smooth functions: $f(\cdot,c)$ and $f(c,\cdot)$ smooth for every $c$. It is strictly larger
than $\cinf(\R^2)$: $f(x,y)=xy/(x^2+y^2)$, $f(0,0)=0$, is separately smooth and discontinuous. So an observer who finds $f$ among the observables knows
the world is not the standard plane.

\emph{The hull of $X'$ excludes diagonal motion.} The curve $c(t)=(t,t)$ is not in $\mathrm{Plot}\,\mathrm{Fun}(\mathcal D')$, since $f\circ c$ takes the value
$0$ at $t=0$ and $\tfrac12$ elsewhere. More generally, if $P$ is in the hull then $P$ is smooth, the coordinates being observables, and at every point $r$ one of
$\dd P_1(r)$, $\dd P_2(r)$ vanishes: otherwise some direction $v$ has $\dd P_1(v)\ne0\ne\dd P_2(v)$, and the translate of $f$ to $P(r)$ is
discontinuous along $t\mapsto P(r+tv)$.

\emph{The hull of $X'$ is larger than $\mathcal D'$.} With $\varphi$ as in \cref{exo:cross}, let $P(t)=(\varphi(-t),\varphi(t))$, the curve that turns
the corner at the origin. For a separately smooth $f$ put $g=f(\cdot,0)$ and $k=f(0,\cdot)$, both smooth. Then
$f(P(t))=g(\varphi(-t))+k(\varphi(t))-f(0,0)$ for all $t$, a smooth function. So $P$ is in the hull. But $P$ is not a plot of $\mathcal D'$: near
$t=0$ it lies in no single line. Hence $\mathcal D'\subsetneq\hat{\mathcal D'}$ and $X'$ is not reflexive.

So the wire plane is observationally a plane; the grid plane is observationally not a plane, but an observer still overestimates what can be done in
it, crediting it with motions that turn corners. Only interventions settle either question.
\end{solution}

\begin{exercise}[label=exo:hull-functor]{3}
Show that the reflexive hull does not commute with quotients: exhibit a subduction $\pi\colon X\to B$ with $X$ reflexive for which
$\hat X\to\hat B$ is not a subduction.
\end{exercise}
\begin{solution}
Take $\pi=q_\alpha\colon\R\to\Tal$. $\R$ is reflexive, so $\hat\R=\R$, and $\hat{\Tal}$ is the set $\R/\Lam_\alpha$ with the coarse diffeology.
The map $\R\to\hat{\Tal}$ is smooth and surjective, but a parametrisation of $\hat{\Tal}$ that is not locally liftable, such as
$t\mapsto q_\alpha(\sqrt{\abs t})$ (\cref{prop:Talpha-basic}), is a plot of the target with no local lift. So the hull of the quotient is not the quotient of
the hull. Equivalently: the reflector $X\mapsto\hat X$ is a left adjoint and so preserves colimits \emph{computed in the category of reflexive spaces},
where the quotient of $\R$ by $\Lam_\alpha$ is the coarse space; the category of Fr\"olicher spaces has quotients, and they are the wrong ones.
\end{solution}

\begin{exercise}[label=exo:TC-invariance]{4}
Prove \cref{thm:planner}(ii).
\end{exercise}
\begin{solution}
Let $f\colon X\to Y$, $g\colon Y\to X$ be smooth and $h\colon X\times\R\to X$ a smooth homotopy with $h_0=g\circ f$ and $h_1=\id_X$. Let
$V_1,\dots,V_k$ be D-open sets covering $Y\times Y$ with smooth planners $\sigma_j\colon V_j\to\Paths(Y)$. Put $U_j=(f\times f)^{-1}(V_j)$; these are
D-open, because smooth maps are D-continuous, and they cover $X\times X$. We construct a smooth planner on $U_j$.

\emph{Three paths.} For $(x,x')\in U_j$ consider
\begin{align*}
\gamma_1(t)&=h\bigl(x,1-\lambda(t)\bigr)&&\text{from }x\text{ to }g f(x),\\
\gamma_2(t)&=g\bigl(\sigma_j(f(x),f(x'))(\lambda(t))\bigr)&&\text{from }gf(x)\text{ to }gf(x'),\\
\gamma_3(t)&=h\bigl(x',\lambda(t)\bigr)&&\text{from }gf(x')\text{ to }x',
\end{align*}
where $\lambda$ is a smashing function. Each is stationary near $t\le0$ and $t\ge1$, each depends smoothly on $(x,x',t)$: for $\gamma_2$ this is
the smoothness of $\sigma_j\circ(f\times f)\colon U_j\to\Paths(Y)$ together with \cref{thm:ccc}.

\emph{Concatenation.} Define $s_j(x,x')(t)$ to be $\gamma_1(3t)$ for $t\le\tfrac13$, $\gamma_2(3t-1)$ for $\tfrac13\le t\le\tfrac23$ and
$\gamma_3(3t-2)$ for $t\ge\tfrac23$. Because $\lambda$ is constant near $0$ and near $1$, there is a fixed $\varepsilon>0$, independent of $(x,x')$,
such that on $\abs{t-\tfrac13}<\varepsilon$ the first two expressions are both equal to $gf(x)$, and on $\abs{t-\tfrac23}<\varepsilon$ the last two
are both equal to $gf(x')$. So on the three overlapping open sets $t<\tfrac13+\varepsilon$, $\tfrac13-\varepsilon<t<\tfrac23+\varepsilon$,
$t>\tfrac23-\varepsilon$ of $U_j\times\R$ the map $(x,x',t)\mapsto s_j(x,x')(t)$ coincides with a smooth map, and by locality \ref{D2} applied to its
composites with plots it is smooth. Hence $s_j\colon U_j\to\Paths(X)$ is smooth, with $s_j(x,x')(0)=h(x,1)=x$ and $s_j(x,x')(1)=h(x',1)=x'$.

So $X\times X$ is covered by $k$ D-open sets with smooth planners, and $\TC^D(X)\le\TC^D(Y)$. If $X$ and $Y$ are smoothly homotopy equivalent each
dominates the other and the two numbers coincide.
\end{solution}



\chapter{System design: state spaces, quotients, clocks}\label{ch:systems}
\chaptermark{System design}

\begin{chapabstract}
A designer of systems with continuous state composes state spaces, abstracts them, and identifies states that should not be distinguished. We
prove three results about doing so smoothly. Every smooth machine has two minimal realisations, a quotient and a subspace of the space of
behaviours, which differ in general. A system of incommensurable clocks is classified, up to re-gearing, by a quasi-torus on which no conserved
quantity exists. And reduction by a symmetry group is lossless exactly when the action is principal, in which case equivariant components upstairs
are the same as components downstairs.
\end{chapabstract}
\source{\IZ{art.~1.46--1.60} (subductions, quotients, strict maps, functional diffeology), \IZ{art.~8.11--8.16} (principal and associated bundles),
\IZ{art.~8.38} (Kronecker flows).}

\section{A design rule}

State spaces are built from other state spaces by a small number of operations, and each is a universal construction (\cref{tab:design}). The
category of manifolds has the first row conditionally and the others not at all, which is why continuous-state design is usually done in
coordinates with the structure maintained by hand. $\Diff$ has all of them unconditionally (\cref{thm:topological}, \cref{thm:ccc},
\cref{thm:lcc}), with one refinement that this chapter is about: the quotient in $\Diff$ is a quotient of \emph{points}, and when the identifications
themselves carry information the right object is the quotient in $\SmSet$ or in $\Hh$ (\cref{thm:three-quotients}).

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{3.4cm}p{3.1cm}p{6.7cm}@{}}\toprule
design operation & construction & smoothness means\\\midrule
compose subsystems & product, pullback & families are pairs of families\\
impose an invariant & subspace (induction) & a family is smooth iff smooth in the ambient space\\
abstract, deduplicate & quotient (subduction) & every family of abstract states lifts locally\\
switch between modes & sum, pushout & a family stays locally in one mode\\
pass a component as data & function space & a family of components is a component with a parameter\\
depend on a parameter & slice, $\Pi_f$ & fibrewise function spaces\\\bottomrule
\end{tabular}
\caption{Design operations and the universal constructions that implement them in $\Diff$.}\label{tab:design}
\end{table}

\section{Two minimal realisations}

Fix diffeological spaces $I$ of inputs and $O$ of outputs. A \defn{smooth machine} is a diffeological space $S$ of states with smooth maps
\[
\delta\colon S\times I\to S,\qquad\mathrm{out}\colon S\to O ,
\]
and a morphism of machines is a smooth map of state spaces commuting with $\delta$ and $\mathrm{out}$. Write $\delta^*(s;i_1,\dots,i_n)$ for the
state reached from $s$ on the input word $i_1\cdots i_n$. The \defn{space of behaviours} is
\[
B=\prod_{n\ge0}\cinf(I^n,O),
\]
a machine with $\mathrm{out}_B(b)=b_0$ and $\delta_B(b,i)_n(i_1,\dots,i_n)=b_{n+1}(i,i_1,\dots,i_n)$. The \defn{behaviour} of a state $s$ of a machine $M$ is
$\beta_M(s)=\bigl((i_1,\dots,i_n)\mapsto\mathrm{out}(\delta^*(s;i_1,\dots,i_n))\bigr)_{n\ge0}$.

\begin{theorem}[Two minimal realisations]\label{thm:realisation}
Let $M=(S,\delta,\mathrm{out})$ be a smooth machine.
\begin{enumerate}[label=\textup{(\roman*)}]
\item $B$ is a terminal object in the category of smooth machines: $\beta_M\colon M\to B$ is the unique morphism.
\item The coimage $M_q=S/{\sim}$, where $s\sim s'$ iff $\beta_M(s)=\beta_M(s')$, and the image $M_s=\beta_M(S)_{\Sub}$ carry unique machine structures
making
\[
M\;\onto\;M_q\;\xrightarrow{\ \kappa\ }\;M_s\;\into\;B
\]
morphisms of machines. $\kappa$ is a bijection.
\item \textup{(Universal properties.)} Every morphism $M\to M'$ that is a subduction is followed by a unique morphism $M'\to M_q$ under $M$: $M_q$ is the
smallest quotient of $M$. Every morphism from $M$ to a machine whose behaviour map is an induction factors uniquely through $M\to M_s$: $M_s$ is the
reflection of $M$ into extensional machines.
\item $\kappa$ is an isomorphism if and only if $\beta_M$ is strict. It is not always: for $S=\R$, $I=\ast$, $\delta=\id$, $\mathrm{out}(s)=s^2$ one
gets $M_q=\R/\{\pm1\}$ and $M_s=[0,\infty)_{\Sub}$.
\item Machines with the same set of behaviours have the same $M_s$, but can have non-diffeomorphic $M_q$: for $S_n=\R^n$, $I=\ast$, $\delta=\id$,
$\mathrm{out}(s)=\abs s^2$, all $M_s$ coincide and the $M_q=\R^n/\Ort(n)$ are pairwise non-diffeomorphic.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) The $n$-th component of $\beta_M$ is the adjoint of the smooth map $S\times I^n\to O$, $(s,\vec\imath)\mapsto\mathrm{out}(\delta^*(s;\vec\imath))$,
so it is smooth by \cref{thm:ccc}, and a map into a product is smooth iff its components are. $\delta_B$ is smooth because partial evaluation
$\cinf(I^{n+1},O)\times I\to\cinf(I^n,O)$ is. The identities $\mathrm{out}_B\beta_M=\mathrm{out}$ and $\beta_M\delta=\delta_B(\beta_M\times\id)$ are
immediate. If $h\colon M\to B$ is any morphism then $h(s)_n(\vec\imath)=\mathrm{out}_B(\delta_B^*(h(s);\vec\imath))=\mathrm{out}_B(h(\delta^*(s;\vec\imath)))=\mathrm{out}(\delta^*(s;\vec\imath))$.

(ii) $\delta$ is compatible with $\sim$, because $\beta_M(\delta(s,i))=\delta_B(\beta_M(s),i)$. The map $S\times I\to M_q\times I$ is a subduction
(\cref{prop:stability}), so $\delta$ descends to a smooth $\delta_q\colon M_q\times I\to M_q$; and $\mathrm{out}$ descends. The image $\beta_M(S)$ is closed
under $\delta_B$, and restrictions of smooth maps to subspaces, with values in subspaces, are smooth. Uniqueness is clear since $S\to M_q$ is onto and
$M_s\to B$ is injective. $\kappa$ is the comparison map of \cref{thm:factorisations}.

(iii) If $h\colon M\to M'$ is a morphism then $\beta_{M'}h=\beta_M$ by (i), so $h$ identifies only $\sim$-equivalent states; if $h$ is a subduction,
$S\to M_q$ factors uniquely and smoothly through it, and the factor is a morphism because $h$ is onto. If $h\colon M\to N$ with $\beta_N$ an
induction, then $\beta_N$ identifies $N$ with a subspace of $B$ containing $\beta_M(S)$, and the inclusion $M_s\into\beta_N(N)_{\Sub}\cong N$ is the
required factor.

(iv) is the definition of strict, and \cref{prop:delta1}. (v) All these machines have $\beta(S)=\set{(c,c,\dots):c\ge0}$, a copy of $[0,\infty)_{\Sub}$ in
$B=\R^{\N}$; the classes of $\sim$ are the spheres, so $M_q=\R^n/\Ort(n)$, and \IZ{Exercise~50}.
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \node[hcsnode] (S) at (0,0) {$S$};
  \node[hcsnodeb] (Q) at (3.4,0) {$M_q=S/{\sim}$};
  \node[hcsnodeb] (I) at (7.6,0) {$M_s=\beta(S)_{\Sub}$};
  \node[hcsnode] (B) at (11.2,0) {$B$};
  \draw[->>] (S)--(Q); \draw[->] (Q)-- node[above]{$\kappa$} (I); \draw[hookr] (I)--(B);
  \draw[->] (S) to[bend right=22] node[below]{$\beta_M$} (B);
  \node[font=\footnotesize,align=center,text width=4.0cm] at (3.4,1.15) {states up to observational equivalence: families come from families of states};
  \node[font=\footnotesize,align=center,text width=4.0cm] at (7.6,1.15) {realisable behaviours: families are smooth families of behaviours};
\end{tikzpicture}
\caption{The two minimal realisations of a smooth machine. In classical automata theory they coincide (Myhill--Nerode); for manifolds neither
exists in general; in $\Diff$ both exist, and the map between them is a smooth bijection that is a diffeomorphism exactly for strict behaviour
maps.}\label{fig:realisation}
\end{figure}

For design this separates two meanings of the word ``state''. $M_s$ is the state space of the \emph{specification}: it depends only on
the observable behaviour, and a smooth family in it is a smooth family of behaviours, which is the kind of object over which a test suite or a contract quantifies.
$M_q$ is the state space of the \emph{implementation up to observation}: a smooth family in it is one that some smooth family of internal states
realises. By part (iv) a specification can have smooth families of behaviours that no smooth family of implementation states realises ---
the family $(r,s)\mapsto r^2+s^2$ in the example --- and by part (v) two implementations of one specification can have observational
quotients of different local dimension. Neither phenomenon can be stated for manifolds, because neither quotient is one.

\section{Clocks}

Consider $N\ge2$ periodic components with frequencies $\omega=(\omega_1,\dots,\omega_N)\in\R^N$: counters, oscillators, tasks released
periodically. Their joint phase is a point of the torus $T^N=\R^N/\Z^N$ and evolves by the linear flow $x\mapsto x+t\omega$. Call $\omega$
\defn{non-resonant} if $k\cdot\omega\ne0$ for all $k\in\Z^N\smallsetminus\{0\}$: no integer combination of the clocks is stationary. The space of
\emph{phase relations} of the system is the leaf space
\[
Q_\omega=T^N/\R ,
\]
whose points are the possible trajectories of the joint phase. Two initial conditions have the same long-run behaviour, up to a time shift, exactly
when they define the same point of $Q_\omega$.

\begin{theorem}[Multi-clock systems]\label{thm:clocks}
Let $\omega,\omega'\in\R^N$ be non-resonant, $N\ge2$.
\begin{enumerate}[label=\textup{(\roman*)}]
\item $Q_\omega\cong\R^{N-1}/\Gamma_\omega$ is a quasi-torus, where $\Gamma_\omega\cong\Z^N$ is the image of $\Z^N$ in $\R^N/\R\omega$, a dense subgroup. The
projection $T^N\to Q_\omega$ is a principal $\R$-bundle, and $\Pi\,Q_\omega\simeq\B\Z^N\simeq T^N$.
\item Every D-continuous function on $Q_\omega$ is constant: the system has no non-trivial continuous conserved quantity.
\item $Q_\omega\cong Q_{\omega'}$ if and only if $\omega'=c\,U\omega$ for some $U\in\GL_N(\Z)$ and $c\in\R^\times$.
\item $\Dif(Q_\omega)\cong Q_\omega\rtimes\Sigma_\omega$, where $\Sigma_\omega=\set{U\in\GL_N(\Z):U\omega\in\R\omega}$ is the discrete group of unimodular
integer matrices with eigenvector $\omega$.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) Let $p\colon\R^N\to V=\R^N/\R\omega$ and $\Gamma_\omega=p(\Z^N)$. Both $Q_\omega$ and $V/\Gamma_\omega$ are the quotient of $\R^N$ by the subgroup
$\Z^N+\R\omega$, so they are diffeomorphic. If $c\omega\in\Z^N$ with $c\neq0$, any non-zero integer vector orthogonal to $c\omega$ would violate
non-resonance; so $\R\omega\cap\Z^N=0$ and $p$ is injective on $\Z^N$. By Kronecker's theorem non-resonance is equivalent to density of every orbit of the
flow in $T^N$, that is, to density of $\Z^N+\R\omega$ in $\R^N$, that is, to density of $\Gamma_\omega$ in $V$. The flow is the action of a subgroup of the
diffeological group $T^N$, so the quotient map is principal by \cref{cor:GmodH}; the subgroup is diffeomorphic to $\R$ as in \IZ{Exercise~31}. The shape
is \cref{cor:TGamma}. (ii) A D-open set of $V/\Gamma_\omega$ has an open preimage invariant under a dense group of translations. (iii) By
\cref{thm:linear-rigidity}(c), $Q_\omega\cong Q_{\omega'}$ iff there is a linear isomorphism $A\colon V\to V'$ with $A\Gamma_\omega=\Gamma_{\omega'}$. Given such
$A$, there is a unique bijection $U$ of $\Z^N$ with $p'U=Ap$ on $\Z^N$, because $p'$ is injective on $\Z^N$; it is additive, so $U\in\GL_N(\Z)$, and
$p'U=Ap$ on $\R^N$ by linearity. Hence $U(\ker p)=\ker p'$, i.e.\ $U\omega\in\R\omega'$. Conversely such a $U$ induces $A$. (iv) By
\cref{thm:linear-rigidity}(b) every smooth self-map is affine, and its linear part corresponds to $U$ as in (iii); the diffeology is treated as in
\cref{thm:units}(iii).
\end{proof}

\begin{figure}[t]
\centering
\begin{tikzpicture}[font=\small]
  \def\gold{1.6180339}
  \draw[->,hcsgrey] (0,0.55)--(12.4,0.55) node[right,hcsink]{$t$};
  \draw[->,hcsgrey] (0,-0.55)--(12.4,-0.55);
  \node[left] at (0,0.55) {clock 1}; \node[left] at (0,-0.55) {clock 2};
  \foreach \k in {0,...,12} \draw[hcsteal,line width=1pt] (0.95*\k,0.4)--(0.95*\k,0.7);
  \foreach \k in {0,...,7} \draw[hcsrust,line width=1pt] (0.95*\gold*\k,-0.7)--(0.95*\gold*\k,-0.4);
  \foreach \k in {0,...,12} \draw[hcsteal!50,line width=0.4pt,dashed] (0.95*\k,0.4)--(0.95*\k,-1.25);
  \foreach \k in {0,...,7} \draw[hcsrust!50,line width=0.4pt,dashed] (0.95*\gold*\k,-0.7)--(0.95*\gold*\k,-1.25);
  \draw[hcsgrey] (0,-1.25)--(12.4,-1.25);
  \node[font=\footnotesize] at (6.2,-1.75) {merged tick sequence: never periodic; the order in which the two clocks tick is a Sturmian word};
\end{tikzpicture}
\caption{Two clocks with period ratio the golden ratio. There is no hyperperiod and no continuous function of the joint phase is conserved, but the
space of phase relations is the diffeological group $T_\varphi$, with a self-similarity: the frequencies $\omega=(1,1/\varphi)$ satisfy
$U\omega=\varphi\,\omega$ for $U=\begin{psmallmatrix}1&1\\1&0\end{psmallmatrix}$, so replacing the counters $(c_1,c_2)$ by $(c_1+c_2,c_1)$ gives the same
system run $\varphi$ times faster.}\label{fig:clocks}
\end{figure}

In design terms, (ii) means that there is nothing to synchronise on. A system of rate-monotonic periodic tasks with rational period ratios has a
hyperperiod, a circle of phase relations, and schedules can be tabulated over it; with incommensurable periods the corresponding object exists but is
a quasi-torus, and no table indexed by a continuous invariant of the phase can exist. (iii) is a normal form theorem: two multi-rate systems are
the same up to \emph{re-gearing} --- replacing the counters by unimodular integer combinations of themselves and rescaling time --- exactly when
their leaf spaces are diffeomorphic. For $N=2$ this is \cref{cor:DI} with $\alpha=\omega_2/\omega_1$, and the invariant is the tail of the continued
fraction of the rate ratio. (iv) gives the non-trivial re-gearing self-equivalences of a system: $\Sigma_\omega$ is $\{\pm1\}$ for generic rates,
and it is the unit group $\Z[\theta]^\times$, of rank $r_1+r_2-1$ by Dirichlet's theorem, when $\omega=(1,\theta,\dots,\theta^{N-1})$ for an
algebraic integer $\theta$ of degree $N$ (\cref{exo:three-clocks}; compare \cref{prop:number-fields}). Finally, for $N=2$, the principal $\R$-bundles over $Q_\omega$ are computed in \cref{thm:Fl}; they are the ways of attaching to the phase relation a real-valued
accumulated quantity defined up to a flow. They depend on the Diophantine type of the rate ratio: for Diophantine ratios the only such quantity is
elapsed time, up to scale, and for Liouville ratios there are others.

\section{Lossless reduction}

Let a diffeological group $G$ act on a state space $X$ by symmetries: relabellings of identical replicas, changes of frame, gauge freedoms of a
representation. One wants to work with the reduced state space $B=X/G$. When is nothing lost? Write $\Diff_G/X$ for the category of diffeological
spaces with $G$-action and an equivariant smooth map to $X$; think of its objects as components attached to the system whose state transforms
with the symmetry.

\begin{theorem}[Lossless symmetry reduction]\label{thm:reduction}
Let $\pi\colon X\to B=X/G$ be the quotient map.
\begin{enumerate}[label=\textup{(\roman*)}]
\item The following are equivalent: the action is principal; $X\simeq B\times_{\B G}\ast$ in $\Hh$, compatibly with the action and the projection, for a map $c\colon B\to\B G$; along every plot of
$B$ the state space is locally a product of reduced state and gauge, $P^*X\cong_{\mathrm{loc}}U\times G$.
\item If the action is principal, then pulling back along $\pi$ is an equivalence of categories
\[
\pi^*\colon\Diff/B\;\xrightarrow{\ \simeq\ }\;\Diff_G/X,\qquad\text{with inverse }E\mapsto E/G .
\]
\item In general $\Hh/(X\hquot G)$ is equivalent to the $\infty$-category of objects of $\Hh$ with $G$-action and an equivariant map to $X$, and the
functor of \textup{(ii)} is the restriction of this equivalence along $X\hquot G\to B$, which is an equivalence exactly in the principal case.
\end{enumerate}
\end{theorem}
\begin{proof}
(i) is \cref{thm:principal} and \cref{thm:classification}. (ii) is \cref{exo:descent}. (iii) is the general fact that objects over a homotopy quotient
are equivariant objects \cite{NSS}, together with \cref{thm:three-quotients}.
\end{proof}

So for a principal symmetry one may store only the reduced state, and every equivariant observer, controller or attached data structure is
equivalently a component over the reduced state space: the reduction is an equivalence of design spaces, not merely a projection. When the action is
not principal the same statement holds verbatim for the stack $X\hquot G$ and fails for the space $X/G$; the space $X/G$ lacks the isotropy groups, and a
component over $X/G$ carries no action of the isotropy group at a state with symmetry. The three levels at which states can be identified in a design
are listed in \cref{tab:identity}.

\begin{table}[t]\centering\small
\begin{tabular}{@{}p{2.7cm}p{3.2cm}p{3.9cm}p{3.6cm}@{}}\toprule
level & object & two states are identified\dots & engineering analogue\\\midrule
points & $X/G\in\Diff$ & if some symmetry relates them & canonical form, deduplicated key\\
germs & $\pi_0(X\hquot G)\in\SmSet$ & by a symmetry varying smoothly with the family & equivalence with a locally consistent reason\\
witnesses & $X\hquot G\in\Hh$ & by a recorded symmetry & keep the isomorphism: migration, merge witness, version vector\\\bottomrule
\end{tabular}
\caption{Three levels of identification, from \cref{thm:three-quotients}. Moving down the table increases the stored data and improves compositionality: only the
last row satisfies \cref{thm:reduction}(iii) unconditionally.}\label{tab:identity}
\end{table}

\exercisesheading

\begin{exercise}[label=exo:rational-clocks]{1}
Compute the space of phase relations $Q_\omega$ for two clocks with $\omega=(2,3)$, and more generally for $\omega=(p,q)$ with $p,q$ coprime integers.
\end{exercise}
\begin{solution}
$Q_\omega=\R^2/(\Z^2+\R\omega)$. The linear form $\ell(x,y)=qx-py$ has kernel $\R\omega$, so it identifies $\R^2/\R\omega$ with $\R$ and carries $\Z^2$
onto $q\Z+p\Z=\Z$. Hence $Q_\omega\cong\R/\Z$, a circle: the flow on $T^2$ is periodic and the phase relation is the conserved quantity
$qx-py\bmod1$. The hyperperiod is the period of the flow, $t=1$ in these units. The contrast with \cref{thm:clocks} is entirely in whether
$\ell(\Z^2)$ is discrete or dense.
\end{solution}

\begin{exercise}[label=exo:machines]{2}
Let $I=\R$, $O=\R$. Let $M_1$ have $S=\R$, $\delta(s,\theta)=s$, $\mathrm{out}(s)=s^2$, and let $M_2$ have $S=\R^2$, $\delta(s,\theta)$ the rotation of $s$
by the angle $\theta$, $\mathrm{out}(s)=\abs s^2$. Show that $M_1$ and $M_2$ have the same specification $M_s$ and non-isomorphic observational quotients.
\end{exercise}
\begin{solution}
In both machines the output along any input word is constant: $\beta(s)_n(\vec\theta)=s^2$, respectively $\abs s^2$. So both images in $B$ are the set of
constant behaviours with value $c\ge0$. The map $c\mapsto(\text{const}_c)_n$ from $\R$ to $B$ is an induction, since each component
$\R\to\cinf(\R^n,\R)$ is; so $M_s\cong[0,\infty)_{\Sub}$ for both, with trivial transition and output $c$. The observational quotients are
$\R/\{\pm1\}=\dten_1$ and $\R^2/\!\sim$ with classes the circles, which is $\dten_2=\R^2/\Ort(2)$. These are not diffeomorphic
\IZ{Exercise~50}; indeed no machine isomorphism can exist since the underlying spaces differ. An observer cannot tell $M_1$ from $M_2$; a designer
who can run smooth two-parameter families of initial states can.
\end{solution}

\begin{exercise}[label=exo:three-clocks]{2}
Determine $\Sigma_\omega$ for $\omega=(1,\sqrt2,\sqrt3)$ and exhibit an element of infinite order in $\Sigma_\omega$ for $\omega=(1,\theta,\theta^2)$ with
$\theta^3=\theta+1$.
\end{exercise}
\begin{solution}
Both are non-resonant, the entries being linearly independent over $\Q$. Let $U\omega=c\omega$ and $M=\Z\omega_1+\Z\omega_2+\Z\omega_3\subset\R$; then
$cM\subseteq M$. For the first $\omega$: $c=c\cdot1\in M$, say $c=a+b\sqrt2+d\sqrt3$. Then $c\sqrt2=2b+a\sqrt2+d\sqrt6\in M$ forces $d=0$ and
$c\sqrt3=a\sqrt3+b\sqrt6\in M$ forces $b=0$. So $c=a\in\Z$, the integer matrix $U-c$ annihilates $\omega$, hence is zero by non-resonance, and $U=c=\pm1$:
$\Sigma_\omega=\{\pm1\}$. For the second, multiplication by $\theta$ preserves $M=\Z[\theta]$: $\theta\cdot1=\theta$, $\theta\cdot\theta=\theta^2$,
$\theta\cdot\theta^2=1+\theta$. So $U=\begin{psmallmatrix}0&1&0\\0&0&1\\1&1&0\end{psmallmatrix}$ satisfies $U\omega=\theta\omega$, $\det U=1$, and it has
infinite order because $\theta>1$. Three clocks with rates $1:\theta:\theta^2$ are re-gearing equivalent to themselves under
$(c_1,c_2,c_3)\mapsto(c_2,c_3,c_1+c_2)$ with time rescaled by $\theta$.
\end{solution}

\begin{exercise}[label=exo:reduce-rotation]{3}
Let $X=\R^2$ with the flow of $\dot x=-\nabla L$, $L(x)=(\abs x^2-1)^2$, and $G=\mathrm{SO}(2)$. Describe the reduced dynamics on $X/G$, say where the
reduction is lossless in the sense of \cref{thm:reduction}, and compute the shape of $X\hquot G$ and of $X/G$.
\end{exercise}
\begin{solution}
$L$ is invariant and its flow is complete in forward time, so by the argument of \cref{prop:gradflow} it descends to $X/G=\R^2/\mathrm{SO}(2)=\dten_2$ (the orbits of $\mathrm{SO}(2)$ and
$\Ort(2)$ coincide). In the coordinate $u=\abs x^2\in[0,\infty)$, $\dot u=2x\cdot\dot x=-8u(u-1)$: the point $u=0$ is an unstable equilibrium, $u=1$ a
stable one, and every other trajectory tends to $u=1$. On $X^\circ=\R^2\smallsetminus\{0\}$ the action is free and proper, hence principal, with
quotient the manifold $(0,\infty)$; there the state is (radius, angle), the angle is pure gauge, and by \cref{thm:reduction}(ii) equivariant components
over $X^\circ$ are the same as components over $(0,\infty)$. At the origin the stabiliser is all of $G$ and the reduction is lossy. Shapes:
$\Pi(X\hquot G)=\ast\hquot S^1=\B S^1=\C P^\infty$, while $\Pi(X/G)=\ast$ (\cref{exo:contractible}). The entire difference is the isotropy of one state.
\end{solution}

\begin{exercise}[label=exo:descent]{4}
Prove \cref{thm:reduction}(ii).
\end{exercise}
\begin{solution}
Let $\pi\colon X\to B$ be a principal $G$-bundle.

\emph{The functor $\pi^*$.} For $E\to B$ put $\pi^*E=X\times_BE$, with $G$ acting on the first factor and the projection to $X$. It is an object of
$\Diff_G/X$, functorially in $E$.

\emph{The functor $Q$.} For $p\colon E\to X$ in $\Diff_G/X$ put $Q(E)=E/G$ with the map to $B$ induced by $\pi\circ p$, which is $G$-invariant.

\emph{The action on $E$ is principal.} Let $r\mapsto(e_r,e_rg_r)$ be a plot of $E\times E$. Applying $p$ gives the plot
$r\mapsto(p(e_r),p(e_r)g_r)$ of $X\times X$, and since the action on $X$ is principal $r\mapsto g_r$ is a plot of $G$. In particular the action on $E$
is free and $E\to E/G$ is a principal bundle.

\emph{$\pi^*Q\cong\id$.} For $E$ in $\Diff_G/X$ consider $\phi\colon E\to X\times_BE/G$, $\phi(e)=(p(e),[e])$. It is smooth, $G$-equivariant, and lies
over $E/G$. Now $X\times_B(E/G)\to E/G$ is a principal $G$-bundle, being the pullback of $\pi$ along $E/G\to B$ (\cref{lem:Bun-basic}(i)), and
$E\to E/G$ is a principal $G$-bundle by the previous step. A morphism of principal bundles over the same base is an isomorphism
(\cref{lem:Bun-basic}(ii)); so $\phi$ is a diffeomorphism, natural in $E$, and it commutes with the maps to $X$.

\emph{$Q\pi^*\cong\id$.} For $E\to B$, the projection $X\times_BE\to E$ is a subduction, as the pullback of the subduction $\pi$, and its fibres are the
$G$-orbits. So it induces a bijective subduction $(X\times_BE)/G\to E$, which is a diffeomorphism (\cref{prop:stability}(iii)), natural in $E$ and
compatible with the maps to $B$.

\emph{Morphisms.} Both constructions are functorial and the two natural isomorphisms exhibit them as inverse equivalences.

The argument used principality twice: to make $E\to E/G$ a bundle, and to make $X\times_B(E/G)$ one. For a free action that is not principal the
statement fails. Let $\Rd$ act on $X=\R$, so that $B=\ast$, and take $E=X\times G$ with the diagonal action and the first projection. Then
$E/G\cong\R$ via $(x,h)\mapsto x-h$, so $\pi^*Q(E)=\R\times\R$, which is not diffeomorphic to $E=\R\times\Rd$.
\end{solution}



\chapter{Coda}\label{ch:coda}

\begin{chapabstract}
A summary of the argument, open questions, and the strata in which the statements will be formalised.
\end{chapabstract}

\section{The argument in one page}

A diffeology is a concrete sheaf on Cartesian spaces (\cref{thm:BH}). Concreteness is separatedness for the adjunction ``points $\dashv$
codiscrete'' (\cref{lem:coDisc}), so $\Diff$ is a quasitopos (\cref{thm:quasitopos-abstract}): it has every limit, colimit and function space, two
kinds of image (\cref{thm:factorisations}), and one defect, non-effective equivalence relations (\cref{prop:noneffective}). Repairing the defect
twice leads to the topos $\SmSet$ and the $\infty$-topos $\Hh$ (\cref{thm:DiffinH}), and the quotient of a space by a group then has three values,
which coincide exactly for the principal actions of the book (\cref{thm:principal}, \cref{thm:three-quotients}). In $\Hh$ the book's main constructions
become representable: forms by the smooth sets $\Om^k$ (\cref{prop:forms-yoneda}), principal bundles by the stacks $\B G$
(\cref{thm:classification}), homotopy groups by the shape $\Pi$ (\cref{thm:pin}). Formal properties of $\Pi$ give the exact homotopy sequence
(\cref{thm:fibre-seq}); the Poincar\'e lemma for sheaves gives de~Rham's theorem with its obstruction (\cref{thm:dR-obstruction}) and the integration
bundles (\cref{thm:integration}).

Every statement can be checked on the irrational torus. It is $\R\hquot\Z^2$, so its shape is a torus; its forms account for half of the torus' cohomology and its
$\R$-bundles for the other half (\cref{prop:E2-Talpha}); its maps are affine (\cref{thm:linear-rigidity}), so its symmetries are units
(\cref{thm:units}), its isomorphism classes are ideal classes (\cref{thm:class-torsor}), and its bundles are solutions of a cohomological equation
with small divisors (\cref{thm:Fl}).

The applications use the quasitopos more than the $\infty$-topos. Because a map has two images, hypothesis spaces
(\cref{thm:learning}), invariant features (\cref{prop:features}) and minimal realisations (\cref{thm:realisation}) each come in two versions.
By Cartesian closure, automatic differentiation (\cref{thm:AD}) and motion planning (\cref{thm:planner}) are one-line arguments. The
distinction between a quotient and a homotopy quotient is the reason that canonical forms fail at symmetric points (\cref{thm:no-canon}) and the criterion for symmetry
reduction to be lossless (\cref{thm:reduction}).

\section{Open questions}

\begin{enumerate}[label=\arabic*.]
\item \emph{Strictness of realisation maps.} For which architectures is $\rho\colon\Theta\to\cinf(X,Y)$ strict, so that the two hypothesis spaces of
\cref{thm:learning} coincide? For deep linear networks the question is whether every smooth family of matrices of rank at most $k$ factors locally and smoothly
through $k$ dimensions.
\item \emph{Higher obstruction groups.} Compute $H^q(T_\Gamma;\Om^p)$ for quasi-tori of rank $N>2$. The answer should be governed by simultaneous
Diophantine conditions on $\Gamma$, generalising \cref{thm:Fl}; the $E_2$ page should again be the cohomology of $T^N$.
\item \emph{The smooth Oka principle beyond manifolds.} \Cref{thm:shape}(ii) holds for manifolds, and by \cref{rem:no-BG-space}
$\Pi[\Tal,\B\R]\simeq\ast$ is consistent with it even though $\Map(\Tal,\B\R)$ is large. For which diffeological spaces $X$ is
$\Pi[X,A]\simeq\Map(\Pi X,\Pi A)$ for all $A$?
\item \emph{Smooth versus continuous planning.} Is $\TC^D(M)=\TC(M)$ for every closed manifold $M$?
\item \emph{Arithmetic beyond the class group.} In complex multiplication the torsor of \cref{thm:class-torsor} carries a Galois action and generates
class fields. Manin's question \cite{Manin} is whether real multiplication has an analogue. Diffeology provides the objects and their
isogenies; the invariants are the open part.
\item \emph{Reverse mode and stacks.} Is there a version of \cref{thm:AD} for programs whose types denote stacks, for instance programs
manipulating data up to a symmetry?
\end{enumerate}

\section{Formalisation: what is ready}\label{sec:formal}

Formalisation is the subject of a sequel. The statements of this monograph fall into three strata by the infrastructure required (\cref{tab:formal}).
The first stratum is elementary: sets, plots and real analysis. The second requires sheaves on a site. The third requires an $\infty$-topos, and the
natural target is not a model but an axiomatisation: cohesive homotopy type theory, in which $\shp$, $\fl$ and $\shr$ are primitive modalities
\cite{Shulman}, and in which \cref{thm:three-quotients}, \cref{thm:fibre-seq} and \cref{thm:dR-obstruction} are statements about types.

\begin{table}[h]\centering\small
\begin{tabular}{@{}p{2.4cm}p{5.3cm}p{5.6cm}@{}}\toprule
stratum & requires & statements\\\midrule
A: plots & sets, smooth maps on $\R^n$, Fourier series & \cref{thm:topological,thm:ccc,thm:factorisations,thm:lcc}; \cref{thm:linear-rigidity,cor:DI,thm:units};
\cref{lem:coboundary-line} and the analytic part of \cref{thm:Fl}; \cref{thm:no-canon,thm:planner,thm:galois,thm:realisation,thm:clocks}; \cref{thm:AD}\\
B: sheaves & a Grothendieck topos, image factorisation & \cref{thm:BH,prop:conc,prop:cohesion1,prop:forms-descent,thm:ccc-general}\\
C: $\infty$-sheaves & effective groupoids, shape, descent & \cref{thm:principal,thm:classification,thm:three-quotients,thm:fibre-seq,thm:dR-obstruction,thm:integration,thm:reduction}\\\bottomrule
\end{tabular}
\caption{Strata for formalisation. Everything in stratum A is provable from the definition of a diffeology in \cref{def:diffeology} with no category theory.}
\label{tab:formal}
\end{table}

The quoted theorems on which the results depend, and which would have to be formalised or assumed, are four: Whitney's theorem on even functions
(\cref{thm:halfspace}), the triviality of diffeological bundles over Cartesian spaces \IZ{art.~8.19} (\cref{lem:Bun-basic}), the comparison of smooth
homotopy groups with the shape (\cref{thm:pin}), and the structure-group theorem for orbifolds (\cref{thm:IKZ}).


\appendix

\chapter{A dictionary}\label{ch:dictionary}

In the table the vocabulary of \cite{IZ} is set beside the categorical vocabulary used here; the book is cited by article in the left column.

{\small
\begin{longtable}{@{}p{4.7cm}p{5.6cm}p{3.1cm}@{}}
\toprule
in \emph{Diffeology} & here & where\\\midrule\endhead
\bottomrule\endfoot
domain; parametrisation (1.1--1.3) & object of the site $\Dom$; element of a presheaf & \cref{ch:concrete}\\
axioms D1--D3 (1.5) & normalisation, descent, functoriality & \cref{thm:BH}\\
diffeological space & concrete sheaf on $\Cart$; $0$-truncated object of $\Hh$ with $X\into\shr X$ & \cref{thm:BH,thm:DiffinH}\\
discrete, coarse diffeology (1.20--1.21) & $\Disc$, $\coDisc$; the modalities $\fl$, $\shr$ & \cref{prop:cohesion1}\\
pullback, pushforward (1.26, 1.43) & initial and final lifts along $\Diff\to\Set$ & \cref{thm:topological}\\
induction (1.29) & strong monomorphism & \cref{prop:monoepi}\\
subduction (1.46) & strong epimorphism; effective epimorphism of $\Hh$ & \cref{prop:monoepi,thm:principal}\\
strict map (1.54) & $\operatorname{coim}f\cong\im f$ & \cref{thm:factorisations}\\
functional diffeology (1.57) & internal hom; exponential ideal & \cref{thm:ccc,thm:quasitopos-abstract}\\
generating family (1.66) & covering sieve; presentation as a colimit of representables & \cref{thm:classification}\\
quotient (1.50) & $\conc\,\pi_0$ of the homotopy quotient & \cref{thm:three-quotients}\\
D-topology (2.8) & left adjoint $D\colon\Diff\to\Top$; not the shape & \cref{prop:Dadj,rem:shape-vs-D}\\
manifold, orbifold (4.1, 4.17) & modelled space; coarse space of an \'etale stack & \cref{ch:models}\\
components $\pi_0$ (5.7) & $\Pi_0$, left adjoint to $\Disc$ & \cref{prop:cohesion1}\\
homotopy groups $\pi_n$ (5.17) & homotopy groups of the shape $\Pi X$ & \cref{thm:pin}\\
differential form (6.28) & map $X\to\Om^k$ in $\SmSet$ & \cref{prop:forms-yoneda}\\
pushing forms onto quotients (6.38) & $\Hom(-,\Om^k)$ turns coequalisers into equalisers & \cref{prop:forms-descent}\\
De~Rham homomorphism (6.74) & edge map of the Poincar\'e spectral sequence & \cref{thm:dR-obstruction}\\
diffeological group (7.1) & $0$-truncated concrete group object of $\Hh$; has a delooping $\B G$ & \cref{ch:bundles}\\
fibrating groupoid (8.4) & groupoid Morita equivalent to a group: $|\mathbf K|\simeq\B\mathbf K_b$ & \cref{prop:fibrating}\\
fibration, local triviality along plots (8.8--8.9) & map classified by $B\to\B\Dif(F)$ & \cref{prop:fibrating}\\
principal action (8.11) & $X/G\simeq X\hquot G$ & \cref{thm:principal}\\
principal bundle & map $X\to\B G$ & \cref{thm:classification}\\
associated bundle (8.16) & $(P\times F)\hquot G$ & \cref{thm:fibre-seq}\\
exact homotopy sequence (8.21) & $\Pi$ preserves homotopy quotients & \cref{thm:fibre-seq}\\
universal covering (8.26) & fibre of $X\to\tau_{\le1}\shp X$ & \cref{ch:homotopy}\\
cokernel of the first De~Rham homomorphism (8.30) & $E_2^{0,1}$; flat $\R$-bundles & \cref{thm:dR-obstruction,exo:IZ830}\\
group of flows $\Fl(X)$ (8.39) & $H^1(X;\R)=\pi_0\Map(X,\B\R)$ & \cref{thm:Fl}\\
integration bundle of a closed 2-form (8.42) & lift of $X\to\Om^2_{\mathrm{cl}}$ through $\B(T_P)_{\mathrm{conn}}$ & \cref{thm:integration}\\
\end{longtable}}

\section*{Notation}
\addcontentsline{toc}{section}{Notation}
{\small
\begin{tabular}{@{}p{3.2cm}p{10.4cm}@{}}
$\Dom$, $\Cart$ & domains; Cartesian spaces, with smooth maps and open covers\\
$\Diff$, $\SmSet$, $\Hh$ & diffeological spaces; sheaves on $\Cart$; $\infty$-sheaves on $\Cart$\\
$\underline X$ & the sheaf of plots of $X$\\
$\Gamma,\Disc,\coDisc,\Pi_0$ & points, discrete, codiscrete, connected components\\
$\Pi$, $\shp$, $\fl$, $\shr$ & shape; the shape, flat and sharp modalities\\
$\conc$, $\pi_0$, $\tau_{\le n}$ & concretisation; $0$-truncation; $n$-truncation\\
$X/G$, $X\hquot G$ & diffeological quotient; homotopy quotient\\
$\B G$, $\Bun_G(X)$ & delooping of a group object; groupoid of principal $G$-bundles\\
$\Om^k$, $\Om^k_{\mathrm{cl}}$ & sheaves of $k$-forms and closed $k$-forms on $\Cart$\\
$H^q(X;A)$ & $\pi_0\Map_{\Hh}(X,\B^qA)$\\
$\R$, $\Rd$ & the smooth additive group; the same group with the discrete diffeology\\
$\Lam_\alpha$, $\Tal$, $q_\alpha$ & $\Z+\alpha\Z$; the irrational torus $\R/\Lam_\alpha$; the projection $\R\to\Tal$\\
$T_\Gamma$ & the quasi-torus $\R^n/\Gamma$\\
$\dten_n$, $H$ & $\R^n/\Ort(n)$ with the quotient diffeology; $[0,\infty)$ with the subspace diffeology\\
$\mathcal O_\alpha$, $\Pic(\mathcal O)$, $R_D$ & endomorphism ring of $\Tal$; class group; regulator\\
$\Fl(X)$ & group of isomorphism classes of principal $\R$-bundles over $X$\\
$\norm t$ & distance from $t$ to the nearest integer\\
\end{tabular}}


\backmatter

\begin{thebibliography}{99}
\addcontentsline{toc}{chapter}{Bibliography}
\small

\bibitem{IZ} P. Iglesias-Zemmour, \emph{Diffeology}, Mathematical Surveys and Monographs 185, American Mathematical Society, Providence, 2013.

\bibitem{Aumann} R. J. Aumann, Borel structures for function spaces, \emph{Illinois J. Math.} 5 (1961), 614--630.

\bibitem{BaezHoffnung} J. C. Baez and A. E. Hoffnung, Convenient categories of smooth spaces, \emph{Trans. Amer. Math. Soc.} 363 (2011), 5789--5825.

\bibitem{BIKW} A. Batubenge, P. Iglesias-Zemmour, Y. Karshon and J. Watts, Diffeological, Fr\"olicher, and differential spaces, preprint, arXiv:1712.04576.

\bibitem{BBP} D. Berwick-Evans, P. Boavida de Brito and D. Pavlov, Classifying spaces of infinity-sheaves, \emph{Algebr. Geom. Topol.} 24 (2024), 4891--4937.

\bibitem{Boman} J. Boman, Differentiability of a function and of its compositions with functions of one variable, \emph{Math. Scand.} 20 (1967), 249--268.

\bibitem{BuchmannWilliams} J. Buchmann and H. C. Williams, A key exchange system based on real quadratic fields, in \emph{Advances in Cryptology -- CRYPTO '89}, Lecture Notes in Comput. Sci. 435, Springer, 1990, 335--343.

\bibitem{Bunk} S. Bunk, The $\mathbb R$-local homotopy theory of smooth spaces, \emph{J. Homotopy Relat. Struct.} 17 (2022).

\bibitem{CSIDH} W. Castryck, T. Lange, C. Martindale, L. Panny and J. Renes, CSIDH: an efficient post-quantum commutative group action, in \emph{Advances in Cryptology -- ASIACRYPT 2018}, Lecture Notes in Comput. Sci. 11274, Springer, 2018, 395--427.

\bibitem{Chen} K.-T. Chen, Iterated path integrals, \emph{Bull. Amer. Math. Soc.} 83 (1977), 831--879.

\bibitem{ChristensenSinnamonWu} J. D. Christensen, G. Sinnamon and E. Wu, The $D$-topology for diffeological spaces, \emph{Pacific J. Math.} 272 (2014), 87--110.

\bibitem{ChristensenWu} J. D. Christensen and E. Wu, The homotopy theory of diffeological spaces, \emph{New York J. Math.} 20 (2014), 1269--1303.

\bibitem{ChristensenWuBG} J. D. Christensen and E. Wu, Smooth classifying spaces, \emph{Israel J. Math.} 241 (2021); arXiv:1709.10517.

\bibitem{Cohen} H. Cohen, \emph{A Course in Computational Algebraic Number Theory}, Graduate Texts in Mathematics 138, Springer, 1993.

\bibitem{Couveignes} J.-M. Couveignes, Hard homogeneous spaces, IACR Cryptology ePrint Archive, Report 2006/291.

\bibitem{DonatoIglesias} P. Donato and P. Iglesias, Exemples de groupes diff\'eologiques: flots irrationnels sur le tore, \emph{C. R. Acad. Sci. Paris S\'er. I Math.} 301 (1985), 127--130.

\bibitem{Dubuc} E. J. Dubuc, Concrete quasitopoi, in \emph{Applications of Sheaves}, Lecture Notes in Math. 753, Springer, 1979, 239--254.

\bibitem{DucasVanWoerden} L. Ducas and W. van Woerden, On the lattice isomorphism problem, quadratic forms, remarkable lattices, and cryptography, in \emph{Advances in Cryptology -- EUROCRYPT 2022}, Lecture Notes in Comput. Sci. 13277, Springer, 2022.

\bibitem{Hawk} L. Ducas, E. W. Postlethwaite, L. N. Pulles and W. van Woerden, Hawk: module LIP makes lattice signatures fast, compact and simple, in \emph{Advances in Cryptology -- ASIACRYPT 2022}, Springer, 2022.

\bibitem{DymLawrenceSiegel} N. Dym, H. Lawrence and J. W. Siegel, Equivariant frames and the impossibility of continuous canonicalization, in \emph{Proc. 41st Int. Conf. on Machine Learning}, PMLR 235 (2024), 12228--12267.

\bibitem{Farber} M. Farber, Topological complexity of motion planning, \emph{Discrete Comput. Geom.} 29 (2003), 211--221.

\bibitem{GurerIZ} S. G\"urer and P. Iglesias-Zemmour, Differential forms on manifolds with boundary and corners, \emph{Indag. Math.} 30 (2019), 920--929.

\bibitem{Hallgren} S. Hallgren, Polynomial-time quantum algorithms for Pell's equation and the principal ideal problem, \emph{J. ACM} 54 (2007), no.~1, Art.~4.

\bibitem{HardyWright} G. H. Hardy and E. M. Wright, \emph{An Introduction to the Theory of Numbers}, 5th ed., Oxford University Press, 1979.

\bibitem{HKSY} C. Heunen, O. Kammar, S. Staton and H. Yang, A convenient category for higher-order probability theory, in \emph{Proc. 32nd ACM/IEEE Symp. on Logic in Computer Science (LICS)}, 2017.

\bibitem{omegaPAP} M. Huot, A. K. Lew, V. K. Mansinghka and S. Staton, $\omega$PAP spaces: reasoning denotationally about higher-order, recursive probabilistic and differentiable programs, in \emph{Proc. 38th ACM/IEEE Symp. on Logic in Computer Science (LICS)}, 2023.

\bibitem{HSV} M. Huot, S. Staton and M. V\'ak\'ar, Correctness of automatic differentiation via diffeologies and categorical gluing, in \emph{Foundations of Software Science and Computation Structures (FoSSaCS 2020)}, Lecture Notes in Comput. Sci. 12077, Springer, 2020, 319--338.

\bibitem{IZthesis} P. Iglesias, \emph{Fibrations diff\'eologiques et homotopie}, Th\`ese d'\'Etat, Universit\'e de Provence, Marseille, 1985.

\bibitem{IZsmall} P. Iglesias, Diff\'eologie d'espace singulier et petits diviseurs, \emph{C. R. Acad. Sci. Paris S\'er. I Math.} 302 (1986), 519--522.

\bibitem{IKZ} P. Iglesias, Y. Karshon and M. Zadka, Orbifolds as diffeologies, \emph{Trans. Amer. Math. Soc.} 362 (2010), 2811--2831.

\bibitem{IglesiasLachaud} P. Iglesias and G. Lachaud, Espaces diff\'erentiables singuliers et corps de nombres alg\'ebriques, \emph{Ann. Inst. Fourier (Grenoble)} 40 (1990), 723--737.

\bibitem{IZCech} P. Iglesias-Zemmour, \v{C}ech--de~Rham bicomplex in diffeology, \emph{Israel J. Math.} 259 (2024), 239--276.

\bibitem{IZarith} P. Iglesias-Zemmour, Diffeology and arithmetic of irrational tori, preprint, arXiv:2508.07460.

\bibitem{IglesiasPrato} P. Iglesias-Zemmour and E. Prato, Quasifolds, diffeology and noncommutative geometry, \emph{J. Noncommut. Geom.} 15 (2021), 735--759.

\bibitem{Elephant} P. T. Johnstone, \emph{Sketches of an Elephant: A Topos Theory Compendium}, Oxford Logic Guides 43--44, Oxford University Press, 2002.

\bibitem{KiharaModel} H. Kihara, Model category of diffeological spaces, \emph{J. Homotopy Relat. Struct.} 14 (2019), 51--90.

\bibitem{KiharaSing} H. Kihara, Smooth singular complexes and diffeological principal bundles, preprint, arXiv:2202.00131.

\bibitem{KWW} D. Krepski, J. Watts and S. Wolbert, Sheaves, principal bundles, and \v{C}ech cohomology for diffeological spaces, preprint, arXiv:2111.01032.

\bibitem{KrieglMichor} A. Kriegl and P. W. Michor, \emph{The Convenient Setting of Global Analysis}, Mathematical Surveys and Monographs 53, American Mathematical Society, 1997.

\bibitem{Lawvere} F. W. Lawvere, Axiomatic cohesion, \emph{Theory Appl. Categ.} 19 (2007), 41--49.

\bibitem{Losik} M. V. Losik, Fr\'echet manifolds as diffeological spaces, \emph{Izv. Vyssh. Uchebn. Zaved. Mat.} (1992), no.~5, 36--42.

\bibitem{HTT} J. Lurie, \emph{Higher Topos Theory}, Annals of Mathematics Studies 170, Princeton University Press, 2009.

\bibitem{Manin} Yu. I. Manin, Real multiplication and noncommutative geometry (ein Alterstraum), in \emph{The Legacy of Niels Henrik Abel}, Springer, 2004, 685--727.

\bibitem{MinichielloBun} E. Minichiello, Diffeological principal bundles and principal infinity bundles, preprint, arXiv:2202.11023.

\bibitem{MinichielloObs} E. Minichiello, The diffeological \v{C}ech--de~Rham obstruction, preprint, arXiv:2401.09400.

\bibitem{NSS} T. Nikolaus, U. Schreiber and D. Stevenson, Principal $\infty$-bundles: general theory, \emph{J. Homotopy Relat. Struct.} 10 (2015), 749--801.

\bibitem{Pavlov} D. Pavlov, Projective model structures on diffeological spaces and smooth sets and the smooth Oka principle, preprint, arXiv:2210.12845.

\bibitem{Rieffel} M. A. Rieffel, $C^*$-algebras associated with irrational rotations, \emph{Pacific J. Math.} 93 (1981), 415--429.

\bibitem{Schreiber} U. Schreiber, Differential cohomology in a cohesive $\infty$-topos, preprint, arXiv:1310.7930.

\bibitem{Schwarz} G. W. Schwarz, Smooth functions invariant under the action of a compact Lie group, \emph{Topology} 14 (1975), 63--68.

\bibitem{Shanks} D. Shanks, The infrastructure of a real quadratic field and its applications, in \emph{Proc. 1972 Number Theory Conference}, University of Colorado, Boulder, 1972, 217--224.

\bibitem{Shulman} M. Shulman, Brouwer's fixed-point theorem in real-cohesive homotopy type theory, \emph{Math. Structures Comput. Sci.} 28 (2018), 856--941.

\bibitem{Souriau} J.-M. Souriau, Groupes diff\'erentiels, in \emph{Differential Geometrical Methods in Mathematical Physics}, Lecture Notes in Math. 836, Springer, 1980, 91--128.

\bibitem{Waldorf} K. Waldorf, Transgression to loop spaces and its inverse, I: Diffeological bundles and fusion maps, \emph{Cah. Topol. G\'eom. Diff\'er. Cat\'eg.} 53 (2012), 162--210.

\bibitem{Watanabe} S. Watanabe, \emph{Algebraic Geometry and Statistical Learning Theory}, Cambridge University Press, 2009.

\bibitem{WattsWolbert} J. Watts and S. Wolbert, Diffeological coarse moduli spaces of stacks over manifolds, preprint, arXiv:1406.1392.

\bibitem{Whitney} H. Whitney, Differentiable even functions, \emph{Duke Math. J.} 10 (1943), 159--160.

\end{thebibliography}


\end{document}

End of manuscript · Back to top ↑