This paper was converted on www.awesomepapers.org from LaTeX by an anonymous user.
Want to know more? Visit the Converter page.

\college

Lady Margaret Hall \degreeMSc Mathematical Sciences \degreedateTrinity 2024

Synthetic Homotopy Theory

Yuhang Wei

Abstract

The goal of this dissertation is to present results from synthetic homotopy theory based on homotopy type theory (HoTT). After an introduction to Martin-Löf’s dependent type theory and homotopy type theory, key results include a synthetic construction of the Hopf fibration, a proof of the Blakers–Massey theorem, and a derivation of the Freudenthal suspension theorem, with calculations of some homotopy groups of nn-spheres.

Keywords: homotopy type theory, homotopy theory, algebraic topology, type theory, constructive mathematics

Acknowledgements

I would like to thank my dissertation supervisor, Prof. Kobi Kremnitzer, for his invaluable guidance, inspirations and encouragement during this journey. His expertise and support have been instrumental in the completion of this work.

My gratitude also goes to my college supervisor, Dr. Rolf Suabedissen, for providing insightful advice on the structure and direction of this dissertation.

I am profoundly grateful to my parents for their unconditional and unwavering support in my academic pursuits and, indeed, all aspects of my life. Their efforts in their own field of research and teaching have been a constant source of motivation for me.

Finally, special thanks are due to all of my friends who helped me decide my academic path in pure mathematics or supported me in different ways during the writing of this dissertation. An incomplete list of their names follows: Qixuan Fang, Franz Miltz, Samuel Knutsen, Quanwen Chen, Sifei Li, Phemmatad Tansoontorn, Hao Chen and Haoyang Liu. This dissertation would not have been possible without each and every one of them.

Note

A slightly abridged version of this dissertation, originally written in Typst, was submitted in fulfillment of the requirements for the degree of MSc Mathematical Sciences at University of Oxford. That version was awarded the Departmental Dissertation Prize by the Mathematical Institute, University of Oxford. The current version has been extended and reformatted in .

{romanpages}

Chapter 1 Introduction

The goal of this dissertation is to present results in synthetic homotopy theory based on homotopy type theory (HoTT, also known as univalent foundations), including the Hopf fibration and Blakers–Massey theorem.

Compared to set theory, type theory is often considered as a better foundation for constructive mathematics and mechanised reasoning [Hou17, Section 1.2]. Martin-Löf’s intuitionistic type theory (ITT, also known as dependent type theory) was first proposed in the 1970s [ML75]. In ITT, any mathematical object is seen as inherently a term of some type. In particular, ITT follows the Curry–Howard correspondence, or the paradigm of propositions-as-types, where any proposition is regarded as a type and proving it is equivalent to constructing a term of that type. Since all terms of types can be seen as computer programmes and be executed, proof assistants, e.g. Coq, Agda and Lean, have been developed to ensure the correctness of proofs through type-checking [Bru16, Introduction].

HoTT is based on the intensional version of ITT, where a term of any identity type (i.e., the proposition that two terms of a type are equal) is not necessarily unique. This seemingly counterintuitive situation is addressed by interpreting types as topological spaces and identities as paths between points. The link between homotopy theory and type theory was first discovered in 2006 independently by Voevodsky and by Awodey and Warren [AW09]. In 2009, Voevodsky proposed the univalence axiom (UA), which formalises the idea that ‘isomorphic structures have the same properties’. In 2011, the concept of higher inductive types (HIT) emerged [Lum11], which allows the use of path constructors in addition to point constructors, so that many fundamental topological spaces can be elegantly constructed. In summary, the components of HoTT are

 HoTT = ITT + UA + HIT.\text{ HoTT }=\text{ ITT }+\text{ UA }+\text{ HIT}.

HoTT and \infty-topoi form a syntax-semantics duality, and all results proven in HoTT hold in the \infty-category of homotopy types [Car22]. This lays the foundation for our synthetic approach to homotopy theory, where all constructions are invariant under homotopy equivalences. Unlike in classical (or analytical) homotopy theory, notions such as spaces, points, continuous functions, and continuous paths are not based on set-theoretic constructions but are axiomatised as primitive ones, showing the formal abstraction provided by type theory [Hou17, Section 1.2].

Many results of synthetic homotopy theory, including the Hopf fibration, Freudenthal suspension theorem, and the van Kampen theorem, can be found in [Uni13, Section 8]. More recent efforts in this field include π4(𝕊3)/2\pi_{4}\left({\mathbb{S}}^{3}\right)\simeq{\mathbb{Z}}/2{\mathbb{Z}} [Bru16], the Blakers–Massey theorem [HFLL16], the Cayley–Dickson construction [BR16], the construction of the real projective spaces [BR17], and the long exact sequence of homotopy nn-groups [BR21]. Additionally, synthetic (co)homology theory has been investigated by [Cav15], [BH18] and [Gra18].

This dissertation begins with a brief summary of dependent type theory in Chapter 2 and an overview of HoTT in Chapter 3. Chapter 4 mainly discusses homotopy nn-types and nn-connected types. Chapter 5 develops the fibre sequence, Hopf construction and Hopf fibration. Chapter 6 proves the Blakers–Massey theorem. Along the journey, we will calculate the homotopy groups of nn-spheres in Table 1.1.

Table 1.1: Homotopy groups of nn-spheres calculated in this dissertation.
𝕊1\mathbb{S}^{1} 𝕊2\mathbb{S}^{2} 𝕊3\mathbb{S}^{3} 𝕊n4\mathbb{S}^{n\geq 4}
π1\pi_{1} \mathbb{Z} 0 0 πk<n(𝕊n)0\pi_{k<n}(\mathbb{S}^{n})\simeq 0
π2\pi_{2} 0 \mathbb{Z} 0
π3\pi_{3} 0 \mathbb{Z} \mathbb{Z}
πk4\pi_{k\geq 4} 0 πk(𝕊2)πk(𝕊3)\pi_{k}(\mathbb{S}^{2})\simeq\pi_{k}(\mathbb{S}^{3}) πn(𝕊n)\pi_{n}(\mathbb{S}^{n})\simeq\mathbb{Z}

Although no result is essentially new, calculations and discussions original to this dissertation are marked with a red square ( \blacksquare ). For instance, Chapter 4 contains discussions on path inductions, Corollary 4.4 and Corollary 4.6, and novel examples, Example 4.2 and Example 4.25. Most noticeably, Chapter 6 ‘informalises’ a mechanised Blakers–Massey theorem proof [HFLL16] by integrating details from a Freudenthal suspension theorem proof [Uni13, Section 8.6], before explicitly deriving the Freudenthal suspension theorem as a corollary. Additionally, visualisation diagrams are plotted for certain definitions and theorems to aid understanding.

Chapter 2 Dependent type theory

Dependent type theory is a formal system that organises all mathematical objects, structures and knowledge by expressing them as types or terms of types [Rij22, p. 1]. A type is defined by rules specifying its own formation and the construction of its terms. Types resemble sets; however, a major difference is that membership in a type is not a predicate but is part of the inherent nature of its term.

We write a:Aa:A if aa is a term of type AA, where we also say that type AA is inhabited and aa is an inhabitant of AA. All types are considered terms of a special type, 𝚃𝚢𝚙𝚎\mathtt{Type}, and we denote A:𝚃𝚢𝚙𝚎A:\mathtt{Type} if AA is a type111We suppress the underlying universe level (see [Uni13, Section 1.3]).. If A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and a,b:Aa,b:A, we write aba\equiv b to indicate that aa and bb are judgementally equal, meaning that aa and bb are only symbolically different. When defining a new term b:Ab:A from a:Aa:A, we use the notation b:ab:\equiv a. Judgemental equalities are to be contrasted with propositional equalities introduced in Section 2.3.

We shall briefly sketch the fundamentals of dependent type theory, based on [Rij22, Chapter I] and [Uni13, Chapter 1]. Importantly, these constructions all bear interpretations in logic and topology in Table 2.1.

Table 2.1: Interpretations of type theory in logic and topology.
Type theory Logic Topology
A:𝚃𝚢𝚙𝚎A:\mathtt{Type} a proposition AA a topological space AA
a:Aa:A a proof aa of the proposition AA a point aa in the space AA
ABA\to B if AA then BB a continuous map ABA\to B
P:A𝚃𝚢𝚙𝚎P:A\to\mathtt{Type} a predicate P(x)P(x) for each x:Ax:A a fibration PP over AA with fibre P(x)P(x) for each x:Ax:A
(x:A)P(x)(x:A)\to P(x) for all x:Ax:A, P(x)P(x) a continuous section of fibration PP
x:AP(x)\sum_{x:A}P(x) there exists x:Ax:A, P(x)P(x)222This type carries more information than merely a ’true or false’ judgement of the existence, since a term of this type provides a concrete a:Aa:A as well as a term b:P(a)b:P(a), i.e., a proof for P(a)P(a). the total space of fibration PP
A×BA\times B AA and BB the product space A×BA\times B
A+BA+B AA or BB333A term of A+BA+B also carries the information ’which one of AA and BB is true’. the disjoint union ABA\sqcup B
𝟙\mathbb{1} True the contractible space
𝟘\mathbb{0} False the empty space
p:u=Avp:u=_{A}v pp is a proof of the equality of uu and vv pp is a continuous path from uu to vv
𝚛𝚎𝚏𝚕a:a=Aa\mathtt{refl}_{a}:a=_{A}a the reflexivity of equality at aa the constant path at aa

2.1 Function types

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}. A dependent type (or a family of types) P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type} over AA assigns a type P(x):𝚃𝚢𝚙𝚎P(x):\mathtt{Type} to each term x:Ax:A.

A dependent function is a function whose output types may vary depending on its input. The dependent function type, also known as Π\Pi-type, is specified by:

  1. (1)

    The formation rule: Given a type AA and a dependent type P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, the dependent function type (x:A)P(x)(x:A)\rightarrow P(x) can be formed.

  2. (2)

    The introduction rule: To introduce a dependent function of type (x:A)P(x)(x:A)\rightarrow P(x), a term b(x):P(x)b(x):P(x) is needed for each x:Ax:A. This dependent function is then denoted by λx.b(x)\lambda x.b(x).

  3. (3)

    The elimination rule: Given a dependent function f:(x:A)P(x)f:(x:A)\rightarrow P(x) and a term a:Aa:A, a term f(a):P(a)f(a):P(a) is obtained by evaluating ff at aa.

  4. (4)

    The computation rule: Combining the introduction and elimination rules, (λx.b(x))(a):b(a)\left(\lambda x.b(x)\right)(a):\equiv b(a).

In particular, when PP is a constant type family assigning the same type BB to every a:Aa:A, we obtain the (non-dependent) function type ABA\rightarrow B.

2.2 Inductive types

A wide range of constructions are based on inductive types. An inductive type AA is specified by the following:

  1. (1)

    The constructors (or construction rules) of AA state the ways to construct a term of AA.

  2. (2)

    The induction principle states the necessary data to construct a dependent function (x:A)P(x)(x:A)\rightarrow P(x) for a given dependent type P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}. Particularly, the recursion principle is the induction principle when PP is a constant type.

  3. (3)

    The computation rule states how the dependent function produced by the induction principle acts on the constructors.

2.2.1 Σ\Sigma-types

Given a type AA and a dependent type P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, we can form the Σ\Sigma-type, written as x:AP(x),\sum_{x:A}P(x), whose terms are called dependent pairs.

  1. (1)

    The construction rule states that given a:Aa:A and b:P(a)b:P(a), we can construct the dependent pair (a,b):x:AP(x)(a,b):\sum_{x:A}P(x).

  2. (2)

    The induction principle states that given

    • a dependent type C:x:AP(x)𝚃𝚢𝚙𝚎C:\sum_{x:A}P(x)\rightarrow\mathtt{Type} and

    • a function g:(a:A)(b:P(a))C(a,b)g:(a:A)\rightarrow\left(b:P(a)\right)\rightarrow C(a,b)444Arrows \rightarrow are right-associative.,

    there is a dependent function f:(p:x:AP(x))C(p)f:\left(p:\sum_{x:A}P(x)\right)\rightarrow C(p).

  3. (3)

    The computation rule states that the above ff satisfies f(a,b):g(a)(b)f(a,b):\equiv g(a)(b).

The function gg above is the curried form of ff and ff is the uncurried form of gg, and they can be used interchangeably. Unlike the convention in [Uni13], we use the notation that reflects the actual curriedness of a function, i.e., g(a)(b)g(a)(b) is not written as g(a,b)g(a,b).

Using the induction principle, we define the first projection function 𝚙𝚛1:x:AP(x)A\mathtt{pr}_{1}:\sum_{x:A}P(x)\rightarrow A by λa.λb.a:(a:A)(b:P(a))A\lambda a.\lambda b.a:(a:A)\rightarrow\left(b:P(a)\right)\rightarrow A and the second projection function 𝚙𝚛2:(p:x:AP(x))P(𝚙𝚛1(p))\mathtt{pr}_{2}:\left(p:\sum_{x:A}P(x)\right)\rightarrow P\left(\mathtt{pr}_{1}(p)\right) by λa.λb.b:(a:A)(b:P(a))P(a)\lambda a.\lambda b.b:(a:A)\rightarrow\left(b:P(a)\right)\rightarrow P(a).

The case when PP is a constant type BB gives the cartesian product A×BA\times B. In this case, we write 𝚏𝚜𝚝\mathtt{fst} and 𝚜𝚗𝚍\mathtt{snd} for the projection maps onto AA and BB, respectively.

2.2.2 Other inductive types

Some other inductive types are specified as follows based on [Esc22, Section 2].

  • The empty type 𝟘\mathbb{0} has no construction rule. The induction principle states that given (P:𝟘𝚃𝚢𝚙𝚎)(P:\mathbb{0}\to\mathtt{Type}), there is a dependent function ((x:𝟘)P(x))((x:\mathbb{0})\to P(x)). In particular, the recursion principle states that for any A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, we can define a function f:𝟘Af:\mathbb{0}\to A, which can be logically interpreted as the principle of explosion, or ex falso quodlibet. There is also no computation rule for 𝟘\mathbb{0}. For any type AA, ¬A\neg A is defined as the function type A𝟘A\to\mathbb{0}.

  • The unit type 𝟙\mathbb{1} has a single constructor :𝟙\star:\mathbb{1}. The induction principle for 𝟙\mathbb{1} states that given a dependent type P:𝟙𝚃𝚢𝚙𝚎P:\mathbb{1}\to\mathtt{Type} and a term p:P()p:P(\star), there is a dependent function f:(x:𝟙)P(x)f:(x:\mathbb{1})\to P(x). The computation rule555Henceforth, we may concisely state the computation rule as a part of the induction principle. states that such constructed ff satisfies f():pf(\star):\equiv p.

  • Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}. The disjoint sum A+BA+B of AA and BB has construction rules 𝚒𝚗𝚕:AA+B\mathtt{inl}:A\to A+B and 𝚒𝚗𝚛:BA+B\mathtt{inr}:B\to A+B. The induction principle states that given

    • a dependent type P:(A+B)𝚃𝚢𝚙𝚎P:(A+B)\to\mathtt{Type},

    • two dependent functions f𝚒𝚗𝚕:(a:A)P(𝚒𝚗𝚕(a))f_{\mathtt{inl}}:(a:A)\to P(\mathtt{inl}(a)) and

    • f𝚒𝚗𝚛:(b:B)P(𝚒𝚗𝚛(b))f_{\mathtt{inr}}:(b:B)\to P(\mathtt{inr}(b)),

    there is a dependent function f:((x:A+B)P(x))f:((x:A+B)\to P(x)) such that f(𝚒𝚗𝚕(a)):f𝚒𝚗𝚕(a)f(\mathtt{inl}(a)):\equiv f_{\mathtt{inl}}(a) and f(𝚒𝚗𝚛(b)):f𝚒𝚗𝚛(b)f(\mathtt{inr}(b)):\equiv f_{\mathtt{inr}}(b).

  • The boolean type 𝟚\mathbb{2} is defined as 𝟚𝟙+𝟙\mathbb{2}\equiv\mathbb{1}+\mathbb{1}, and its two constructors are written as 𝚃𝚛𝚞𝚎\mathtt{True} and 𝙵𝚊𝚕𝚜𝚎\mathtt{False}.

  • The type of natural numbers \mathbb{N} has construction rules 0:0:\mathbb{N} and 𝚜𝚞𝚌𝚌:\mathtt{succ}:\mathbb{N}\to\mathbb{N}. The induction principle states that given

    • a dependent type P:𝚃𝚢𝚙𝚎P:\mathbb{N}\to\mathtt{Type},

    • a term f0:P(0)f_{0}:P(0), and

    • a dependent function f𝚜𝚞𝚌𝚌:(n:)P(n)P(𝚜𝚞𝚌𝚌(n))f_{\mathtt{succ}}:(n:\mathbb{N})\to P(n)\to P(\mathtt{succ}(n)),

    there is a dependent function f:((n:)P(n))f:((n:\mathbb{N})\to P(n)) such that f(0):f0f(0):\equiv f_{0} and f(𝚜𝚞𝚌𝚌(n)):f𝚜𝚞𝚌𝚌(n)(f(n))f(\mathtt{succ}(n)):\equiv f_{\mathtt{succ}}(n)(f(n)).

  • The type of integers \mathbb{Z} has three constructors, representing zero, the positive and negative numbers, and its induction principle and computation rules are similar to \mathbb{N} [Bru16, Section 1.3].

2.3 Identity types

Given a type AA and two terms u:Au:A and v:Av:A, we can form the identity type u=Avu=_{A}v, whose terms are called (propositional) equalities or paths. The constructor for a family of identity types (a=Aa)\left(a=_{A}a\right) indexed by a:Aa:A is given by a dependent function

𝚛𝚎𝚏𝚕:(a:A)(a=Aa).\mathtt{refl}:(a:A)\rightarrow\left(a=_{A}a\right).

However, Axiom K, the assumption that p=𝚛𝚎𝚏𝚕ap=\mathtt{refl}_{a} for any p:(a=Aa)p:\left(a=_{A}a\right), does not hold in general.

For a fixed a:Aa:A, the induction principle (called the path induction) for a family of identity types (a=Ax)\left(a=_{A}x\right) indexed by x:Ax:A states that given

  • a dependent type P:(x:A)(a=Ax)𝚃𝚢𝚙𝚎P:(x:A)\rightarrow\left(a=_{A}x\right)\rightarrow\mathtt{Type} and

  • a term d:P(a)(𝚛𝚎𝚏𝚕a)d:P(a)\left(\mathtt{refl}_{a}\right),

there is a dependent function

JP(d):(x:A)(p:(a=Ax))P(x)(p),J_{P}(d):(x:A)\rightarrow\left(p:\left(a=_{A}x\right)\right)\rightarrow P(x)(p),

such that JP(d)(a)(𝚛𝚎𝚏𝚕a):dJ_{P}(d)(a)\left(\mathtt{refl}_{a}\right):\equiv d. The path induction implies that to construct a dependent function for a path pp from a fixed endpoint aa to a free xx, it suffices to assume that xx is aa and pp is 𝚛𝚎𝚏𝚕a\mathtt{refl}_{a}. Importantly, one endpoint xx should be free, since otherwise we would have Axiom K. Intuitively, the path induction reflects the fact that the space of all paths starting from a fixed point is contractible. We shall revisit this idea in Proposition 4.3.

The reader is advised to review Table 2.1 at this point.

Chapter 3 Homotopy type theory

The implications of the identity type are profound, especially when it interacts with other types. In Section 3.1, the identity type equips each type with an \infty-groupoid structure. In Section 3.2, we explore how equalities can be passed along by non-dependent and dependent functions. The notions of ‘equivalence’ between functions and between types are subtle ones treated in Section 3.3, and their relationship with paths in function types or in 𝚃𝚢𝚙𝚎\mathtt{Type} is handled in Section 3.4 by function extensionality and univalence axiom. In Section 3.5, we introduce higher inductive types that allow path constructors. Together, these form the basic components of HoTT.

3.1 The \infty-groupoid structure of types

In classical mathematics, equalities are reflexive, symmetric and transitive. While reflexivity is expressed as the 𝚛𝚎𝚏𝚕\mathtt{refl} constructor for identity types, symmetry and transitivity appear in the form of path inversion and concatenation.

Lemma 3.1 ([Uni13, Lemma 2.1.1]).

For every type AA and x,y:Ax,y:A, there is a function (x=Ay)(y=Ax)\left(x=_{A}y\right)\rightarrow\left(y=_{A}x\right), denoted pp1p\mapsto p^{-1}, such that (𝚛𝚎𝚏𝚕x)1:𝚛𝚎𝚏𝚕x\left(\mathtt{refl}_{x}\right)^{-1}:\equiv\mathtt{refl}_{x}, where p1p^{-1} is called the inverse of pp.

Remark 3.2.

By the paradigm of propositions-as-types, this lemma is equivalent to the type

(A:𝚃𝚢𝚙𝚎)(x:A)(y:A)(p:(x=Ay))(y=Ax).\left(A:\mathtt{Type}\right)\rightarrow(x:A)\rightarrow(y:A)\rightarrow\left(p:\left(x=_{A}y\right)\right)\rightarrow\left(y=_{A}x\right).

The proof shows how we construct a term of this type.

Proof.

Fix A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and x:Ax:A. By path induction, it suffices to assume yy is xx and p:(x=Ay)p:\left(x=_{A}y\right) is 𝚛𝚎𝚏𝚕x\mathtt{refl}_{x}. Then it suffices to give a term of x=Axx=_{A}x, which is fulfilled by 𝚛𝚎𝚏𝚕x\mathtt{refl}_{x}. We thus have (𝚛𝚎𝚏𝚕x)1:𝚛𝚎𝚏𝚕x\left(\mathtt{refl}_{x}\right)^{-1}:\equiv\mathtt{refl}_{x}. ∎

Lemma 3.3 ([Uni13, Lemma 2.1.2]).

For every type AA and x,y,z:Ax,y,z:A, there is a function (x=Ay)(y=Az)(z=Ax)\left(x=_{A}y\right)\rightarrow\left(y=_{A}z\right)\rightarrow\left(z=_{A}x\right), denoted pqpqp\mapsto q\mapsto p{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ q, such that 𝚛𝚎𝚏𝚕x𝚛𝚎𝚏𝚕x:𝚛𝚎𝚏𝚕x\mathtt{refl}_{x}{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ \mathtt{refl}_{x}:\equiv\mathtt{refl}_{x}, where pqp{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ q is called the concatenation of pp and qq.

Proof.

By path induction twice.∎

Lemma 3.4 ([Uni13, Lemma 2.1.4]).

Path concatenation is associative, i.e., for any x,y,z,w:Ax,y,z,w:A, p:x=Ayp:x=_{A}y, q:y=Azq:y=_{A}z, and r:z=Awr:z=_{A}w, there is a 22-dimensional path p(qr)=(pq)rp{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ \left(q{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ r\right)=\left(p{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ q\right){\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ r.

Proof.

By path induction, we assume p,q,rp,q,r are all 𝚛𝚎𝚏𝚕x\mathtt{refl}_{x}. Then 𝚛𝚎𝚏𝚕x(𝚛𝚎𝚏𝚕x𝚛𝚎𝚏𝚕x)𝚛𝚎𝚏𝚕x(𝚛𝚎𝚏𝚕x𝚛𝚎𝚏𝚕x)𝚛𝚎𝚏𝚕x\mathtt{refl}_{x}{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ \left(\mathtt{refl}_{x}{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ \mathtt{refl}_{x}\right)\equiv\mathtt{refl}_{x}\equiv\left(\mathtt{refl}_{x}{\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ \mathtt{refl}_{x}\right){\ \mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\ }\ \mathtt{refl}_{x} by Lemma 3.3, so we give 𝚛𝚎𝚏𝚕𝚛𝚎𝚏𝚕x\mathtt{refl}_{\mathtt{refl}_{x}}. ∎

We similarly can show that path concatenation satisfies inverse and identity laws [Uni13, Lemma 2.1.4]. The above are all examples of coherence operations on paths or higher-dimensional paths. We omit further discussions and direct to [Uni13, Section 2.1] or [Bru16, Section 1.4] for details. Henceforth, we shall omit proofs which only require path inductions.

We then observe that the identity types can be constructed recursively: for any type AA, we can form x=Ayx=_{A}y, p=x=Ayqp=_{x=_{A}y}q, and r=p=x=Ayqsr=_{p=_{x=_{A}y}q}s, etc. This observation, combined with the next definition, pointed types, gives rise to the notion of loop spaces.

Definition 3.5.

The type of pointed types is defined as A:𝚃𝚢𝚙𝚎A\sum_{A:\mathtt{Type}}A. Alternatively, a pointed type is a dependent pair (A,A)\left(A,\star_{A}\right) where A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and A:A\star_{A}:A, and A\star_{A} is called the basepoint of this pointed type. We often leave the basepoint implicit.

Example 3.6.

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, then define a pointed type A+:(A+𝟙,𝚒𝚗𝚛())A_{+}:\equiv\left(A+\mathbb{1},\mathtt{inr}(\star)\right). This is called adjoining a disjoint basepoint.

Definition 3.7.

The loop space of a pointed type (A,A)\left(A,\star_{A}\right) is defined as the pointed type

Ω(A,A):((A=AA),𝚛𝚎𝚏𝚕A).\Omega\left(A,\star_{A}\right):\equiv\left(\left(\star_{A}=_{A}\star_{A}\right),\mathtt{refl}_{\star_{A}}\right).

Then for n:n:{\mathbb{N}}, define the nn-th loop space of (A,A)\left(A,\star_{A}\right) by Ω0A:A\Omega^{0}A:\equiv A and Ωn+1A:Ω(ΩnA)\Omega^{n+1}A:\equiv\Omega\left(\Omega^{n}A\right) (basepoints implicit).

In summary, coherence operations and loop spaces demonstrate that the identity type equips each pointed type with a (weak) \infty-groupoid structure (see [Bru16, Appendix A] for a formal definition).

3.2 Dependent paths

In classical mathematics, for any function between sets f:ABf:A\rightarrow B and x,yAx,y\in A, x=yx=y implies f(x)=f(y)f(x)=f(y). The analogue in HoTT is expressed as a path f(x)=f(y)f(x)=f(y) induced by the path x=yx=y, demonstrating the proof relevance feature of type theory.

Lemma 3.8 ([Uni13, Lemma 2.2.1]).

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}, f:ABf:A\rightarrow B, x,y:Ax,y:A and p:x=Ayp:x=_{A}y. Then there is a path 𝚊𝚙f(p):f(x)=Bf(y)\mathtt{ap}_{f}(p):f(x)=_{B}f(y), such that 𝚊𝚙f(𝚛𝚎𝚏𝚕x):𝚛𝚎𝚏𝚕f(x)\mathtt{ap}_{f}\left(\mathtt{refl}_{x}\right):\equiv\mathtt{refl}_{f(x)}.

However, for a dependent function f:(x:A)P(x)f:(x:A)\rightarrow P(x), there is not necessarily a path from f(x)f(x) to f(y)f(y), which generally belong to different types P(x)P(x) and P(y)P(y), even when there is p:x=Ayp:x=_{A}y. We have to ‘transport’ f(x)f(x) from P(x)P(x) to P(y)P(y) ‘along’ pp first, shown by the following two lemmas, visualised in Figure 3.1.

Lemma 3.9 ([Uni13, Lemma 2.3.1]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, x,y:Ax,y:A and p:x=Ayp:x=_{A}y. Then there is a function p𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p):P(x)P(y)p_{\ast}\equiv\mathtt{transport}^{P}(p):P(x)\rightarrow P(y), such that (𝚛𝚎𝚏𝚕x):idP(x)\left(\mathtt{refl}_{x}\right)_{\ast}:\equiv\operatorname{id}\limits_{P(x)}.

Lemma 3.10 ([Uni13, Lemma 2.3.4]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, f:(a:A)P(a)f:(a:A)\rightarrow P(a), x,y:Ax,y:A and p:x=Ayp:x=_{A}y. Then there is a dependent path 𝚊𝚙𝚍f(p):f(x)=pPf(y)\mathtt{apd}_{f}(p):f(x)=_{p}^{P}f(y) such that 𝚊𝚙𝚍f(𝚛𝚎𝚏𝚕x):𝚛𝚎𝚏𝚕f(x)\mathtt{apd}_{f}\left(\mathtt{refl}_{x}\right):\equiv\mathtt{refl}_{f(x)}, where we define the type

(u=pPv):(𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p)(u)=P(y)v)\left(u=_{p}^{P}v\right):\equiv\left(\mathtt{transport}^{P}(p)(u)=_{P(y)}v\right)

for any u:P(x)u:P(x) and v:P(y)v:P(y).

xxyyf(x)f(x)f(y)f(y)p(f(x))p_{*}(f(x))pp𝚊𝚙𝚍f(p)\mathtt{apd}_{f}(p)p𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p)p_{*}\equiv\mathtt{transport}^{P}(p)AAP(x)P(x)P(y)P(y)
Figure 3.1: Diagram for Lemma 3.9 and Lemma 3.10.
In this and following diagrams, a type is represented as a grey solid circle or ellipse, a term as a black solid dot, a path as a arrow, and a non-dependent function as a arrow.

The next lemma relates the dependent and non-dependent cases, visualised in Figure 3.2.

Lemma 3.11 ([Uni13, Lemma 2.3.5, Lemma 2.3.8]).

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}, x,y:Ax,y:A, and p:x=Ayp:x=_{A}y. Let P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type} be a constant family of types given by λa.B\lambda a.B. Then for any b:Bb:B, there is a path

𝚝𝚛-𝚌𝚘𝚗𝚜𝚝pB(b):𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p)(b)=Bb.\mathtt{tr\text{-}const}_{p}^{B}(b):\mathtt{transport}^{P}(p)(b)=_{B}b.

Let f:ABf:A\rightarrow B, then 𝚊𝚙𝚍f(p)=𝚝𝚛-𝚌𝚘𝚗𝚜𝚝pB(f(x))𝚊𝚙f(p)\mathtt{apd}_{f}(p)=\mathtt{tr\text{-}const}_{p}^{B}\left(f(x)\right)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{ap}_{f}(p).

xxyyf(x)f(x)p(f(x))p_{*}(f(x))f(y)f(y)pp𝚊𝚙f(p)\mathtt{ap}_{f}(p)𝚝𝚛-𝚌𝚘𝚗𝚜𝚝pB(f(x))\mathtt{tr\text{-}const}^{B}_{p}(f(x))𝚊𝚙𝚍f(p)\mathtt{apd}_{f}(p)ffpp_{*}AABB
Figure 3.2: Diagram for Lemma 3.11.

The next result shows the functoriality of 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝\mathtt{transport}.

Proposition 3.12 ([Uni13, Lemma 2.3.9]).

Let P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, p:x=Ayp:x=_{A}y and q:y=Azq:y=_{A}z. Then 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(pq)=𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(q)𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p).\mathtt{transport}^{P}(p\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}q)=\mathtt{transport}^{P}(q)\circ\mathtt{transport}^{P}(p).

It is helpful to characterise 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝\mathtt{transport} when the dependent type P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type} is of particular forms, as in the following lemmas, visualised in Figure 3.3, Figure 3.4 and Figure 3.5.

Lemma 3.13.

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}, f,g:ABf,g:A\rightarrow B, x,y:Ax,y:A, p:x=Ayp:x=_{A}y and u:f(x)=Bg(x)u:f(x)=_{B}g(x). Let P:λa.(f(a)=Bg(a)):A𝚃𝚢𝚙𝚎P:\equiv\lambda a.\left(f(a)=_{B}g(a)\right):A\rightarrow\mathtt{Type}. Then

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p)(u)=f(y)=Bg(y)(𝚊𝚙f(p))1u𝚊𝚙g(p).\mathtt{transport}^{P}(p)(u)=_{f(y)=_{B}g(y)}\left(\mathtt{ap}_{f}(p)\right)^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}u\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{ap}_{g}(p).
xxyyf(x)f(x)f(y)f(y)g(x)g(x)g(y)g(y)pp𝚊𝚙f(p)\mathtt{ap}_{f}(p)𝚊𝚙g(p)\mathtt{ap}_{g}(p)uup(u)p_{*}(u)AABB
Figure 3.3: Diagram for Lemma 3.13.
The two dashed ellipses represent identity types f(x)=g(x)f(x)=g(x) and f(y)=g(y)f(y)=g(y).
Lemma 3.14 ([Uni13, (2.9.4)]).

Let X:𝚃𝚢𝚙𝚎X:\mathtt{Type} and A,B:X𝚃𝚢𝚙𝚎A,B:X\rightarrow\mathtt{Type}. Let P:λx.A(x)B(x):X𝚃𝚢𝚙𝚎P:\equiv\lambda x.A(x)\rightarrow B(x):X\rightarrow\mathtt{Type}. Let x1,x2:Xx_{1},x_{2}:X, p:x1=Xx2p:x_{1}=_{X}x_{2}. Let f:P(x1)(A(x1)B(x1))f:P\left(x_{1}\right)\equiv\left(A\left(x_{1}\right)\rightarrow B\left(x_{1}\right)\right). Then

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p)(f)=P(x2)𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝B(p)f𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝A(p1).\mathtt{transport}^{P}(p)(f)=_{P\left(x_{2}\right)}\mathtt{transport}^{B}(p)\circ f\circ\mathtt{transport}^{A}\left(p^{-1}\right).
x1x_{1}x2x_{2}pp𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝A(p)\mathtt{transport}^{A}(p)𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝B(p)\mathtt{transport}^{B}(p)ffp(f)p_{*}(f)XXA(x1)A(x_{1})A(x2)A(x_{2})B(x1)B(x_{1})B(x2)B(x_{2})
Figure 3.4: Diagram for Lemma 3.14.
The two dashed ellipses represent the function types A(x1)B(x1)A\left(x_{1}\right)\rightarrow B\left(x_{1}\right) and A(x2)B(x2)A\left(x_{2}\right)\rightarrow B\left(x_{2}\right).
Lemma 3.15 ([Uni13, Lemma 2.11.2]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, a,x1,x2:Aa,x_{1},x_{2}:A and p:x1=Ax2p:x_{1}=_{A}x_{2}. Then

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝x(a=x)(p)(q1)\displaystyle\mathtt{transport}^{x\mapsto(a=x)}(p)(q_{1}) =q1p\displaystyle=q_{1}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,p\quad for q1:a=x1,\displaystyle\text{for }q_{1}:a=x_{1},
𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝x(x=a)(p)(q2)\displaystyle\mathtt{transport}^{x\mapsto(x=a)}(p)(q_{2}) =p1q2\displaystyle=p^{-1}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,q_{2}\quad for q2:x1=a,\displaystyle\text{for }q_{2}:x_{1}=a,
𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝x(x=x)(p)(q3)\displaystyle\mathtt{transport}^{x\mapsto(x=x)}(p)(q_{3}) =p1q3p\displaystyle=p^{-1}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,q_{3}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,p\quad for q3:x1=x1.\displaystyle\text{for }q_{3}:x_{1}=x_{1}.
x1x_{1}x2x_{2}aappq1q_{1}p(q1)p_{*}(q_{1})AA
Figure 3.5: Diagram for the first case of Lemma 3.15.
The two dashed ellipses represent identity types a=x1a=x_{1} and a=x2a=x_{2}.

3.3 Homotopies and equivalences

The next problem is how to construct equalities between functions and between types. In this section, we shall present two constructions, function homotopy and type equivalence, based on the identity types.

Definition 3.16.

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, B:A𝚃𝚢𝚙𝚎B:A\rightarrow\mathtt{Type} and f,g:(a:A)B(a)f,g:(a:A)\rightarrow B(a). A (function) homotopy from ff to gg is a dependent function of type

(fg):(a:A)(f(a)=B(a)g(a)),(f\sim g):\equiv(a:A)\rightarrow\left(f(a)=_{B(a)}g(a)\right),

i.e., a family of pointwise equalities.

Definition 3.17.

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}, f:ABf:A\rightarrow B. A quasi-inverse of ff is a triple (g,α,β)(g,\alpha,\beta), where g:BAg:B\rightarrow A, α:fgidB\alpha:f\circ g\sim\operatorname{id}\limits_{B} and β:gfidA\beta:g\circ f\sim\operatorname{id}\limits_{A}.

Proposition 3.18 ([Uni13, Section 2.4]).

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type} and f:ABf:A\rightarrow B. Define type

𝚒𝚜𝚎𝚚𝚞𝚒𝚟(f):(g:BA(gfidA))×(h:BA(fhidB)).\mathtt{isequiv}(f):\equiv\left(\sum_{g:B\rightarrow A}\left(g\circ f\sim\operatorname{id}\limits_{A}\right)\right)\times\left(\sum_{h:B\rightarrow A}\left(f\circ h\sim\operatorname{id}\limits_{B}\right)\right).

We say ‘ff is an equivalence’ if 𝚒𝚜𝚎𝚚𝚞𝚒𝚟(f)\mathtt{isequiv}(f) is inhabited. Then

  1. (1)

    ff is an equivalence if and only if ff has a quasi-inverse;

  2. (2)

    Given any p,q:𝚒𝚜𝚎𝚚𝚞𝚒𝚟(f)p,q:\mathtt{isequiv}(f), there is a path p=𝚒𝚜𝚎𝚚𝚞𝚒𝚟(f)qp=_{\mathtt{isequiv}(f)}q.

In the language of Section 4.2, (2) states that 𝚒𝚜𝚎𝚚𝚞𝚒𝚟(f)\mathtt{isequiv}(f) is a mere proposition. In practice, to prove that a function ff is an equivalence, by (1), we only have to find a quasi-equivalence of ff. An example follows.

Lemma 3.19 ([Uni13, Example 2.4.9]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, x,y:Ax,y:A and p:x=Ayp:x=_{A}y. Then 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p):P(x)P(y)\mathtt{transport}^{P}(p):P(x)\rightarrow P(y) is an equivalence.

Proof.

By Proposition 3.12, 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p1)\mathtt{transport}^{P}\left(p^{-1}\right) forms a quasi-inverse with 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P(p)\mathtt{transport}^{P}(p).∎

Definition 3.20.

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}. Then we define the type of equivalences between AA and BB as

(AB):f:AB𝚒𝚜𝚎𝚚𝚞𝚒𝚟(f).(A\simeq B):\equiv\sum_{f:A\rightarrow B}\mathtt{isequiv}(f).

We now characterise the identity type in certain types using the language of equivalence:

Proposition 3.21 ([Bru16, Proposition 1.6.8]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, B:A𝚃𝚢𝚙𝚎B:A\rightarrow\mathtt{Type} and two terms (a,b),(a,b):x:AB(x)(a,b),(a^{\prime},b^{\prime}):\sum_{x:A}B(x), then there is an equivalence of types

((a,b)=x:AB(x)(a,b))(p:a=Aab=pBb).\left((a,b)=_{\sum_{x:A}B(x)}(a^{\prime},b^{\prime})\right)\simeq\left(\sum_{p:a=_{A}a^{\prime}}b=_{p}^{B}b^{\prime}\right).

The function from right to left is written as 𝚙𝚊𝚒𝚛=\mathtt{pair}^{=}, i.e., given p:a=Aap:a=_{A}a^{\prime} and :b=pBb\ell:b=_{p}^{B}b^{\prime}, there is a path 𝚙𝚊𝚒𝚛=(p,):(a,b)=(a,b)\mathtt{pair}^{=}(p,\ell):(a,b)=(a^{\prime},b^{\prime}).

3.4 Univalence axiom and function extensionality

Given A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}, it is natural to wonder what is the relationship between type equality A=𝚃𝚢𝚙𝚎BA=_{\mathtt{Type}}B and type equivalence ABA\simeq B. It turns out that we can derive the latter from the former:

Proposition 3.22 ([Uni13, Lemma 2.10.1]).

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}. Then there is a function 𝚒𝚍𝚝𝚘𝚎𝚚𝚟:(A=𝚃𝚢𝚙𝚎B)(AB)\mathtt{idtoeqv}:\left(A=_{\mathtt{Type}}B\right)\rightarrow(A\simeq B).

Proof.

Let p:A=𝚃𝚢𝚙𝚎Bp:A=_{\mathtt{Type}}B. The identity function id𝚃𝚢𝚙𝚎λX.X:𝚃𝚢𝚙𝚎𝚃𝚢𝚙𝚎\operatorname{id}\limits_{\mathtt{Type}}\equiv\lambda X.X:\mathtt{Type}\rightarrow\mathtt{Type} can be regarded as a dependent type, so by Lemma 3.9, we have a function 𝚒𝚍𝚝𝚘𝚎𝚚𝚟(p):𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝id𝚃𝚢𝚙𝚎(p):AB\mathtt{idtoeqv}(p):\equiv\mathtt{transport}^{\operatorname{id}\limits_{\mathtt{Type}}}(p):A\rightarrow B, which is an equivalence by Lemma 3.19. ∎

Desirable as it is, we however cannot go the other way around with what we currently have. Our wish is instead formulated as an axiom:

Axiom 3.23 (Univalence).

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}. Then 𝚒𝚍𝚝𝚘𝚎𝚚𝚟:(A=𝚃𝚢𝚙𝚎B)(AB)\mathtt{idtoeqv}:\left(A=_{\mathtt{Type}}B\right)\rightarrow(A\simeq B) is an equivalence.

Remark 3.24.

The axiom means that we assume the type 𝚒𝚜𝚎𝚚𝚞𝚒𝚟(𝚒𝚍𝚝𝚘𝚎𝚚𝚟)\mathtt{isequiv}(\mathtt{idtoeqv}) is inhabited without constructing its term.

In particular, this implies that there is a function

𝚞𝚊:(AB)(A=𝚃𝚢𝚙𝚎B),\mathtt{ua}:(A\simeq B)\rightarrow\left(A=_{\mathtt{Type}}B\right),

which forms a quasi-inverse of 𝚒𝚍𝚝𝚘𝚎𝚚𝚟\mathtt{idtoeqv}. By abuse of notation, we write 𝚞𝚊(f):(A=𝚃𝚢𝚙𝚎B)\mathtt{ua}(f):\left(A=_{\mathtt{Type}}B\right) if f:ABf:A\rightarrow B is an equivalence. In practice, to find a path between two types AA and BB, it suffices to give a function f:ABf:A\rightarrow B and show that ff is an equivalence.

A similar situation arises with function equality and function homotopy.

Proposition 3.25.

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, B:A𝚃𝚢𝚙𝚎B:A\rightarrow\mathtt{Type} and f,g:(a:A)B(a)f,g:(a:A)\rightarrow B(a). Then there is a function 𝚑𝚊𝚙𝚙𝚕𝚢:(f=(a:A)B(a)g)(fg)\mathtt{happly}:\left(f=_{(a:A)\rightarrow B(a)}g\right)\rightarrow(f\sim g).

Proof.

Let p:(f=(a:A)B(a)g)p:\left(f=_{(a:A)\rightarrow B(a)}g\right). For any a:Aa:A, the evaluation function λh.h(a):((a:A)B(a))B(a)\lambda h.h(a):\left((a:A)\rightarrow B(a)\right)\rightarrow B(a) is a non-dependent one, so we can apply Lemma 3.8 and get 𝚑𝚊𝚙𝚙𝚕𝚢(p)(a):𝚊𝚙λh.h(a)(p):(f(a)=B(a)g(a)).\mathtt{happly}(p)(a):\equiv\mathtt{ap}_{\lambda h.h(a)}(p):\left(f(a)=_{B(a)}g(a)\right).

The next theorem can be proved with univalence [Uni13, Section 4.9].

Theorem 3.26 (Function extensionality).

The function 𝚑𝚊𝚙𝚙𝚕𝚢\mathtt{happly} is an equivalence.

This implies that there is a function

𝚏𝚞𝚗𝚎𝚡𝚝:((a:A)(f(a)=B(a)g(a)))(f=(a:A)B(a)g),\mathtt{funext}:\left((a:A)\rightarrow\left(f(a)=_{B(a)}g(a)\right)\right)\rightarrow\left(f=_{(a:A)\rightarrow B(a)}g\right),

which forms a quasi-inverse of 𝚑𝚊𝚙𝚙𝚕𝚢\mathtt{happly}. In practice, to give an equality between two functions ff and gg, it suffices to give a family of pointwise equalities.

3.5 Higher inductive types

In classical dependent type theory, any constructor for an inductive type AA should produce a term of AA. This is not the case for higher inductive types (HIT), where path constructors are allowed which produce paths, or ‘customised equalities’, between points of AA. We now introduce two HITs, the circle and pushouts.

3.5.1 Circle

The circle 𝕊1{\mathbb{S}}^{1} is the HIT generated by a (point) constructor 𝚋𝚊𝚜𝚎:𝕊1\mathtt{base}:{\mathbb{S}}^{1} and a path constructor 𝚕𝚘𝚘𝚙:𝚋𝚊𝚜𝚎=𝕊1𝚋𝚊𝚜𝚎\mathtt{loop}:\mathtt{base}=_{{\mathbb{S}}^{1}}\mathtt{base}. The wording here is ‘generated’, in the sense that by coherence operations, from the constructor 𝚕𝚘𝚘𝚙\mathtt{loop} we automatically obtain paths such as 𝚕𝚘𝚘𝚙1\mathtt{loop}^{-1} and 𝚕𝚘𝚘𝚙𝚕𝚘𝚘𝚙𝚕𝚘𝚘𝚙\mathtt{loop}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{loop}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{loop}. Note that 𝕊1{\mathbb{S}}^{1} is non-trivial, in the sense that 𝚕𝚘𝚘𝚙𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎\mathtt{loop}\neq\mathtt{refl}_{\mathtt{base}} 111Note that this means the type (𝚕𝚘𝚘𝚙=𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎)𝟘(\mathtt{loop}=\mathtt{refl}_{\mathtt{base}})\to\mathbb{0} is inhabited.[Uni13, Lemma 6.4.1].

The induction principle states that given

  • a dependent type P:𝕊1𝚃𝚢𝚙𝚎P:{\mathbb{S}}^{1}\rightarrow\mathtt{Type},

  • a term b:P(𝚋𝚊𝚜𝚎)b:P\left(\mathtt{base}\right) and

  • a dependent path :b=𝚕𝚘𝚘𝚙Pb\ell:b=_{\mathtt{loop}}^{P}b,

there is a dependent function f:(x:𝕊1)P(x)f:\left(x:{\mathbb{S}}^{1}\right)\rightarrow P(x) such that f(𝚋𝚊𝚜𝚎):bf\left(\mathtt{base}\right):\equiv b and 𝚊𝚙𝚍f(𝚕𝚘𝚘𝚙):=\mathtt{apd}_{f}\left(\mathtt{loop}\right):=\ell 222Here the computation rule for the path is a propositional equality instead of a judgemental one; see [Uni13, Section 6.2]..

Remark 3.27 ([Uni13, Remark 6.2.4]).

When informally applying circle induction on x:𝕊1x:{\mathbb{S}}^{1} given P:𝕊1𝚃𝚢𝚙𝚎P:{\mathbb{S}}^{1}\rightarrow\mathtt{Type}, we may use expressions ‘when xx is 𝚋𝚊𝚜𝚎\mathtt{base}’ and ‘when xx varies along 𝚕𝚘𝚘𝚙\mathtt{loop}’ to introduce the constructions of bb and \ell as above.

The recursion principle states that given

  • B:𝚃𝚢𝚙𝚎B:\mathtt{Type},

  • b:Bb:B and

  • p:b=Bbp:b=_{B}b,

there is a function f:𝕊1Bf:{\mathbb{S}}^{1}\rightarrow B such that f(𝚋𝚊𝚜𝚎):bf\left(\mathtt{base}\right):\equiv b and 𝚊𝚙f(𝚕𝚘𝚘𝚙):=p\mathtt{ap}_{f}\left(\mathtt{loop}\right):=p [Uni13, Lemma 6.2.5].

3.5.2 Pushouts

Let A,B,C:𝚃𝚢𝚙𝚎A,B,C:\mathtt{Type}, f:CAf:C\rightarrow A and g:CBg:C\rightarrow B. Then we get a diagram A𝑓C𝑔BA\overset{f}{\leftarrow}C\overset{g}{\rightarrow}B, which we call a span. The pushout ACBA\sqcup^{C}B of this span is the HIT generated by two point constructors 𝚒𝚗𝚕:AACB\mathtt{inl}:A\rightarrow A\sqcup^{C}B and 𝚒𝚗𝚛:BACB\mathtt{inr}:B\rightarrow A\sqcup^{C}B and a path constructor

𝚐𝚕𝚞𝚎:(c:C)(𝚒𝚗𝚕(f(c))=ACB𝚒𝚗𝚛(g(c))),\mathtt{glue}:(c:C)\rightarrow\left(\mathtt{inl}(f(c))=_{A\sqcup^{C}B}\mathtt{inr}(g(c))\right),

as visualised by Figure 3.6.

The induction principle states that given

  • a dependent type P:ACB𝚃𝚢𝚙𝚎P:A\sqcup^{C}B\rightarrow\mathtt{Type},

  • two dependent functions h𝚒𝚗𝚕:(a:A)P(𝚒𝚗𝚕(a))h_{\mathtt{inl}}:(a:A)\rightarrow P\left(\mathtt{inl}(a)\right) and

  • h𝚒𝚗𝚛:(b:B)P(𝚒𝚗𝚛(b))h_{\mathtt{inr}}:(b:B)\rightarrow P\left(\mathtt{inr}(b)\right), and

  • a family of dependent paths

    h𝚐𝚕𝚞𝚎:(c:C)(h𝚒𝚗𝚕(f(c))=𝚐𝚕𝚞𝚎(c)Ph𝚒𝚗𝚛(g(c))),h_{\mathtt{glue}}:(c:C)\rightarrow\left(h_{\mathtt{inl}}\left(f(c)\right)=_{\mathtt{glue}(c)}^{P}h_{\mathtt{inr}}\left(g(c)\right)\right),

there is a dependent function h:(x:ACB)P(x)h:\left(x:A\sqcup^{C}B\right)\rightarrow P(x) such that h(𝚒𝚗𝚕(a)):h𝚒𝚗𝚕(a)h\left(\mathtt{inl}(a)\right):\equiv h_{\mathtt{inl}}(a), h(𝚒𝚗𝚛(b)):h𝚒𝚗𝚛(b)h\left(\mathtt{inr}(b)\right):\equiv h_{\mathtt{inr}}(b) and 𝚊𝚙𝚍h(𝚐𝚕𝚞𝚎(c)):=h𝚐𝚕𝚞𝚎(c)\mathtt{apd}_{h}\left(\mathtt{glue}(c)\right):=h_{\mathtt{glue}}(c).

ccf(c)f(c)g(c)g(c)𝚒𝚗𝚕(f(c))\mathtt{inl}(f(c))𝚒𝚗𝚛(g(c))\mathtt{inr}(g(c))𝚐𝚕𝚞𝚎(c)\mathtt{glue}(c)ffgg𝚒𝚗𝚕\mathtt{inl}𝚒𝚗𝚛\mathtt{inr}𝚐𝚕𝚞𝚎\mathtt{glue}AACCBBACBA\sqcup^{C}B
Figure 3.6: Diagram for the pushout ACBA\sqcup^{C}B.
The two dashed circles represent the ‘image’ of AA and BB under 𝚒𝚗𝚕\mathtt{inl} and 𝚒𝚗𝚛\mathtt{inr}, respectively.

By specialising the span, we can obtain many interesting constructions from the pushout.

  1. (1)

    Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}. The suspension ΣA\Sigma A of AA is the pushout of

    𝟙NA𝟙S.\mathbb{1}_{N}\leftarrow A\rightarrow\mathbb{1}_{S}.

    We denote 𝚗𝚘𝚛𝚝𝚑:𝚒𝚗𝚕(N)\mathtt{north}:\equiv\mathtt{inl}(\star_{N}), 𝚜𝚘𝚞𝚝𝚑:𝚒𝚗𝚛(S)\mathtt{south}:\equiv\mathtt{inr}(\star_{S}), and for any a:Aa:A, 𝚖𝚎𝚛𝚒𝚍(a):𝚐𝚕𝚞𝚎(a):𝚗𝚘𝚛𝚝𝚑=ΣA𝚜𝚘𝚞𝚝𝚑\mathtt{merid}(a):\equiv\mathtt{glue}(a):\mathtt{north}=_{\Sigma A}\mathtt{south}. ΣA\Sigma A can be seen as two points (’north and south poles’) connected by a family of paths (’meridians’) indexed by the terms of AA.

  2. (2)

    Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}. The join ABA\ast B of AA and BB is the pushout of

    A𝚏𝚜𝚝A×B𝚜𝚗𝚍B.A\overset{\mathtt{fst}}{\leftarrow}A\times B\overset{\mathtt{snd}}{\rightarrow}B.
  3. (3)

    Let (A,A)\left(A,\star_{A}\right) and (B,B)\left(B,\star_{B}\right) be two pointed types. The wedge sum ABA\vee B of AA and BB is the pushout of

    AA𝟙BB.A\overset{\star_{A}}{\leftarrow}\mathbb{1}\overset{\star_{B}}{\rightarrow}B.

With suspension, we define the nn-sphere 𝕊n{\mathbb{S}}^{n} by induction on n0n\geq 0: 𝕊0:𝟚{\mathbb{S}}^{0}:\equiv\mathbb{2} and 𝕊n+1:Σ𝕊n{\mathbb{S}}^{n+1}:\equiv\Sigma{\mathbb{S}}^{n}. Note that 𝕊1Σ𝟚{\mathbb{S}}^{1}\simeq\Sigma\mathbb{2} [Uni13, Lemma 6.5.1], where 𝕊1{\mathbb{S}}^{1} is in the sense of Section 3.5.1.

For any type XX, we define its pointed suspension as (ΣX,𝚗𝚘𝚛𝚝𝚑).\left(\Sigma X,\mathtt{north}\right). This turns 𝕊n{\mathbb{S}}^{n} into pointed types for n1n\geq 1. For n=0n=0, we view 𝕊0𝟚{\mathbb{S}}^{0}\equiv\mathbb{2} as 𝟙+\mathbb{1}_{+}. We write the basepoint of 𝕊n{\mathbb{S}}^{n} as 𝚋𝚊𝚜𝚎\mathtt{base}.

Chapter 4 Homotopy nn-types and nn-connected types

Section 4.1 discusses contractible types, ‘trivial types’ that are equivalent to 𝟙\mathbb{1}. Section 4.2 generalises contractible types to (homotopy) nn-types: types with trivial ‘homotopy information’ in any dimension greater than nn (as in Theorem 4.8). Section 4.3 discusses how to truncate any given type into an nn-type. Then our tools at hand will allow us to define and calculate the homotopy groups of the circle in Section 4.4. Finally, Section 4.5 focuses on the ‘dual’ of nn-types, nn-connected types, which have trivial ‘homotopy information’ in any dimension less than or equal to nn.

4.1 Contractible types

Definition 4.1.

For A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, we define the predicate

𝚒𝚜-𝚌𝚘𝚗𝚝𝚛(A):a:A((x:A)(a=Ax))\mathtt{is\text{-}contr}(A):\equiv\sum_{a:A}\left((x:A)\rightarrow\left(a=_{A}x\right)\right)

which reads ‘AA is contractible’, and we say aa is the centre of contraction.

Clearly, 𝟙\mathbb{1} is a contractible type. In fact, AA is contractible if and only if A𝟙A\simeq\mathbb{1} [Uni13, Lemma 3.11.3]. Informally, contractibility means having trivial ‘homotopy information’ in all dimensions (observe that Ωn(𝟙)𝟙\Omega^{n}\left(\mathbb{1}\right)\simeq\mathbb{1} for all n:n:{\mathbb{N}}). We first give a non-example.

Example 4.2.

\blacksquare𝕊1{\mathbb{S}}^{1} is not contractible. Otherwise, taking 𝚋𝚊𝚜𝚎\mathtt{base} as the centre of contraction, we have to prove (x:𝕊1)(𝚋𝚊𝚜𝚎=x)\left(x:{\mathbb{S}}^{1}\right)\rightarrow\left(\mathtt{base}=x\right). By circle induction, when xx is 𝚋𝚊𝚜𝚎\mathtt{base}, we need p:𝚋𝚊𝚜𝚎=𝚋𝚊𝚜𝚎p:\mathtt{base}=\mathtt{base}. When xx ‘varies along’ 𝚕𝚘𝚘𝚙\mathtt{loop}, we need 𝚕𝚘𝚘𝚙(p)=p\mathtt{loop}_{\ast}(p)=p. By Lemma 3.15, 𝚕𝚘𝚘𝚙(p)=p𝚕𝚘𝚘𝚙\mathtt{loop}_{\ast}(p)=p\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{loop}, so by coherence operations, we need 𝚕𝚘𝚘𝚙=𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎\mathtt{loop}=\mathtt{refl}_{\mathtt{base}}, but this would give us absurdity by the non-triviality of 𝕊1{\mathbb{S}}^{1} [Uni13, Lemma 6.4.1].

As mentioned earlier, the space of all paths from a fixed point is contractible:

Proposition 4.3.

Let X:𝚃𝚢𝚙𝚎X:\mathtt{Type} and a:Xa:X. Then the type x:X(a=Xx)\sum_{x:X}\left(a=_{X}x\right) is contractible.

Proof.

The centre of contraction is given by (a,𝚛𝚎𝚏𝚕a)\left(a,\mathtt{refl}_{a}\right). For any (x,p):x:X(a=Xx)(x,p):\sum_{x:X}\left(a=_{X}x\right), we have p:a=xp:a=x and :p(𝚛𝚎𝚏𝚕a)=p\ell:p_{\ast}\left(\mathtt{refl}_{a}\right)=p by Lemma 3.15. Then we have 𝚙𝚊𝚒𝚛=(p,):(a,𝚛𝚎𝚏𝚕a)=(x,p)\mathtt{pair}^{=}(p,\ell):\left(a,\mathtt{refl}_{a}\right)=(x,p) by Proposition 3.21. ∎

\blacksquare This lends us some further insights into path induction, as in the two following corollaries.

Corollary 4.4 (Path induction, strengthened).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, a:Aa:A, and P:(x:A)(a=Ax)𝚃𝚢𝚙𝚎P:(x:A)\rightarrow\left(a=_{A}x\right)\rightarrow\mathtt{Type}. Then for any y:Ay:A, q:a=Ayq:a=_{A}y and d:P(y)(q)d:P(y)(q), there is a function f:(x:A)(p:(a=Ax))P(x)(p)f:(x:A)\rightarrow\left(p:\left(a=_{A}x\right)\right)\rightarrow P(x)(p).

Proof.

Let P^:x:A(a=Ax)𝚃𝚢𝚙𝚎\hat{P}:\sum_{x:A}\left(a=_{A}x\right)\rightarrow\mathtt{Type} be the uncurried form of PP. Then by the induction principle of 𝟙\mathbb{1}, it suffices to take any (y,q):x:A(a=Ax)(y,q):\sum_{x:A}\left(a=_{A}x\right) and d:P^(y,q)P(y)(q)d:\hat{P}(y,q)\equiv P(y)(q) to obtain f^:((x,p):x:A(a=Ax))P^(x,p)\hat{f}:\left((x,p):\sum_{x:A}\left(a=_{A}x\right)\right)\rightarrow\hat{P}(x,p). The desired ff is the curried form of f^\hat{f}. ∎

Remark 4.5.

In the usual path induction, yy and qq should be aa and 𝚛𝚎𝚏𝚕a\mathtt{refl}_{a} respectively.

We may also use 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝\mathtt{transport} to express functions defined using path induction:

Corollary 4.6.

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, a,x:Aa,x:A, p:(a=Ax)p:\left(a=_{A}x\right), P:(x:A)(a=Ax)𝚃𝚢𝚙𝚎P:(x:A)\rightarrow\left(a=_{A}x\right)\rightarrow\mathtt{Type} and d:P(a)(𝚛𝚎𝚏𝚕a)d:P(a)\left(\mathtt{refl}_{a}\right). Then

JP(d)(x)(p)=P(x)(p)𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝P^(𝚙𝚊𝚒𝚛=(p,))(d),J_{P}(d)(x)(p)=_{P(x)(p)}\mathtt{transport}^{\hat{P}}\left(\mathtt{pair}^{=}(p,\ell)\right)(d),

where :p(𝚛𝚎𝚏𝚕a)=p\ell:p_{\ast}\left(\mathtt{refl}_{a}\right)=p by Lemma 3.15, JJ is defined in Section 2.3 and P^:x:A(a=Ax)𝚃𝚢𝚙𝚎\hat{P}:\sum_{x:A}\left(a=_{A}x\right)\rightarrow\mathtt{Type} is the uncurried form of PP.

Proof.

By path induction, assume xx is aa and pp is 𝚛𝚎𝚏𝚕a\mathtt{refl}_{a}, then both sides are dd.∎

4.2 Homotopy nn-types

Definition 4.7.

We recursively define the predicate

𝚒𝚜-n-𝚃𝚢𝚙𝚎(A):{𝚒𝚜-𝚌𝚘𝚗𝚝𝚛(A)if n=2,(x:A)(y:A)𝚒𝚜-(n1)-𝚃𝚢𝚙𝚎(x=Ay)if n1,\mathtt{is\text{-}}n\mathtt{\text{-}Type}(A):\equiv\begin{cases}\mathtt{is\text{-}contr}(A)\quad&\text{if }n=-2,\\ (x:A)\rightarrow(y:A)\rightarrow\mathtt{is\text{-}}(n-1)\mathtt{\text{-}Type}(x=_{A}y)\quad&\text{if }n\geq-1,\end{cases}

for any n2n\geq-2, which reads ‘AA is an nn-type’. We also define

n-𝚃𝚢𝚙𝚎:X:𝚃𝚢𝚙𝚎𝚒𝚜-n-𝚃𝚢𝚙𝚎(X)n\mathtt{\text{-}Type}:\equiv\sum_{X:\mathtt{Type}}\mathtt{is\text{-}}n\mathtt{\text{-}Type}(X)

and in particular, we write 𝙿𝚛𝚘𝚙:(1)-𝚃𝚢𝚙𝚎\mathtt{Prop}:\equiv(-1)\mathtt{\text{-}Type}.

The type 𝚒𝚜-n-𝚃𝚢𝚙𝚎(A)\mathtt{is\text{-}}n\mathtt{\text{-}Type}(A) is a (1)(-1)-type [Uni13, Theorem 7.1.10], and the type n-𝚃𝚢𝚙𝚎n\mathtt{\text{-}Type} is an (n+1)(n+1)-type [Uni13, Theorem 7.1.11].

A (2)(-2)-type is by definition a contractible type; we also define a mere proposition as a (1)(-1)-type and a set as a 0-type. They are characterised as follows:

  • A:𝚃𝚢𝚙𝚎A:\mathtt{Type} is contractible, if and only if AA is a pointed mere proposition, if and only if A𝟙A\simeq\mathbb{1} [Uni13, Lemma 3.11.3].

  • A:𝚃𝚢𝚙𝚎A:\mathtt{Type} is a mere proposition if and only if for any x,y:Ax,y:A, we have x=Ayx=_{A}y [Uni13, Definition 3.3.1 and Lemma 3.11.10]. This aligns with the ‘proof-irrelevant’ propositions in classical logic. For example, 𝟘\mathbb{0} is a mere proposition [Bru16, Proposition 1.10.5].

  • A:𝚃𝚢𝚙𝚎A:\mathtt{Type} is a set, if and only if for any x,y:Ax,y:A and p,q:x=Ayp,q:x=_{A}y we have p=x=Ayqp=_{x=_{A}y}q, if and only if AA satisfies Axiom K, i.e., a=Aaa=_{A}a is contractible for any a:Aa:A [Uni13, Theorem 7.2.1]. This aligns with the ‘equality-irrelevant’ sets in classical mathematics and allows us to talk about set-theoretic notions such as subsets. The types 𝟚\mathbb{2}, \mathbb{N} and \mathbb{Z} are sets [Bru16, Proposition 1.10.7].

As a generalisation of Axiom K, we can characterise nn-types in terms of loop spaces:

Theorem 4.8 ([Uni13, Theorem 7.2.9]).

For any n1n\geq-1, a type AA is an nn-type if and only if Ωn+1(A,a)\Omega^{n+1}(A,a) is contractible for all a:Aa:A.

Noticeably, nn-types have the cumulativity property:

Proposition 4.9 ([Uni13, Theorem 7.1.7]).

Let mn2m\geq n\geq-2. An nn-type is also an mm-type.

4.3 nn-truncations

Any type AA can be turned into an nn-type An\left\|A\right\|_{n}, called the nn-truncation of AA, by a map ||n:AAn|-|_{n}:A\rightarrow\left\|A\right\|_{n}. The construction of An\left\|A\right\|_{n} as an HIT is elaborated in Appendix A.

The induction principle (called the truncation induction) for An\left\|A\right\|_{n} states that given

  • a dependent type P:Ann-𝚃𝚢𝚙𝚎P:\left\|A\right\|_{n}\rightarrow n\mathtt{\text{-}Type} and

  • a dependent function g:(a:A)P(|a|n)g:(a:A)\rightarrow P\left(|a|_{n}\right),

there is a dependent function f:(x:An)P(x)f:\left(x:\left\|A\right\|_{n}\right)\rightarrow P(x), such that f(|a|n):g(a)f\left(|a|_{n}\right):\equiv g(a) for all a:Aa:A [Uni13, Theorem 7.3.2]. The recursion principle states that given

  • an nn-type EE and

  • a function g:AEg:A\rightarrow E,

there is a function f:AnEf:\left\|A\right\|_{n}\rightarrow E such that f(|a|n):g(a)f\left(|a|_{n}\right):\equiv g(a).

Particularly, the (1)(-1)-truncation turns any type into a mere proposition. This allows us to get rid of the ‘superfluous’ information carried by the Σ\Sigma-type and disjoint union, as footnoted in Table 2.1, and perform logic in the classical sense. For A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and P:A𝚃𝚢𝚙𝚎P:A\rightarrow\mathtt{Type}, we shall use the expression ‘there merely exists a:Aa:A such that P(a)P(a)’ to represent the type a:AP(a)1\left\|{\sum_{a:A}P(a)}\right\|_{-1} (see [Uni13, Sections 3.6, 3.7, 3.10]).

The next result shows that truncation operation is a functor:

Proposition 4.10.

Given n2n\geq-2 and f:ABf:A\rightarrow B, there is a map fn:AnBn\left\|f\right\|_{n}:\left\|A\right\|_{n}\rightarrow\left\|B\right\|_{n} such that fn(|a|n):|f(a)|n\left\|f\right\|_{n}\left(|a|_{n}\right):\equiv|f(a)|_{n}.

Proof.

Since Bn\left\|B\right\|_{n} is an nn-type, define fn:AnBn\left\|f\right\|_{n}:\left\|A\right\|_{n}\rightarrow\left\|B\right\|_{n} by fn(|a|n):|f(a)|n\left\|f\right\|_{n}\left(|a|_{n}\right):\equiv|f(a)|_{n} by the recursion principle. ∎

Unsurprisingly, nn-truncating an nn-type gives an equivalence:

Proposition 4.11 ([Uni13, Corollary 7.3.7]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}. AA is an nn-type if and only if the map ||n:AAn|-|_{n}:A\rightarrow\left\|A\right\|_{n} is an equivalence.

Proof.

Suppose AA is an nn-type. Then we are allowed to define f:AnAf:\left\|A\right\|_{n}\rightarrow A by f(|a|n):af\left(|a|_{n}\right):\equiv a. By definition, f||nidAf\circ|-|_{n}\equiv\operatorname{id}\limits_{A}. Then we would like to define a dependent function (x:An)(|f(x)|n=Anx)\left(x:\left\|A\right\|_{n}\right)\rightarrow\left(\left|{f(x)}\right|_{n}=_{\left\|A\right\|_{n}}x\right). Notice that (|f(x)|n=Anx)\left(\left|{f(x)}\right|_{n}=_{\left\|A\right\|_{n}}x\right) is an nn-type (since it is by definition an (n1)(n-1)-type), so by its induction principle it suffices to give a dependent function (a:A)(|f(|a|n)|n=An|a|n)(a:A)\rightarrow\left(\left|{f\left(|a|_{n}\right)}\right|_{n}=_{\left\|A\right\|_{n}}|a|_{n}\right), which can be given by λa.𝚛𝚎𝚏𝚕|a|n\lambda a.\mathtt{refl}_{|a|_{n}} since f(|a|n):af\left(|a|_{n}\right):\equiv a. Therefore, ff forms a quasi-inverse for ||n|-|_{n} and ||n|-|_{n} is an equivalence.

Conversely, if ||n|-|_{n} is an equivalence, then since An\left\|A\right\|_{n} is an nn-type, so is AA. ∎

The following two results deal with nn-truncations of identity types and loop spaces:

Proposition 4.12 ([Uni13, Theorem 7.3.12]).

Let n2n\geq-2, A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and x,y:Ax,y:A. Then

x=Ayn(|x|n+1=An+1|y|n+1).\left\|{x=_{A}y}\right\|_{n}\simeq\left(|x|_{n+1}=_{\left\|A\right\|_{n+1}}|y|_{n+1}\right).
Proposition 4.13 ([Uni13, Corollary 7.3.14]).

Let n2n\geq-2, k0k\geq 0, and AA be a pointed type. Then Ωk(A)nΩk(An+k).\left\|{\Omega^{k}(A)}\right\|_{n}\simeq\Omega^{k}\left(\left\|A\right\|_{n+k}\right).

Finally, nn-truncations have the cumulativity property:

Lemma 4.14 ([Uni13, Lemma 7.3.15]).

For A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and 2mn-2\leq m\leq n, AnmAm.\left\|\left\|A\right\|_{n}\right\|_{m}\simeq\left\|A\right\|_{m}.

4.4 Interlude: homotopy groups of the circle

In this interlude, we first take groups as an example to demonstrate how to construct algebraic structures. Then we define homotopy groups and calculate them for 𝕊1{\mathbb{S}}^{1}.

Definition 4.15.

A group is a set GG with functions m:GGGm:G\rightarrow G\rightarrow G (called the multiplication function), i:GGi:G\rightarrow G (called the inversion function) and a term e:Ge:G (called the neutral element), such that the equalities hold for all x,y,z:Gx,y,z:G:

  • m(m(x)(y))(z)=Gm(x)(m(y)(z))m\left(m(x)(y)\right)(z)=_{G}m(x)\left(m(y)(z)\right);

  • m(x)(i(x))=Gem(x)\left(i(x)\right)=_{G}e;

  • m(i(x))(x)=Gem\left(i(x)\right)(x)=_{G}e;

  • m(x)(e)=Gxm(x)(e)=_{G}x;

  • m(e)(x)=Gxm(e)(x)=_{G}x.

The group is abelian if further m(x)(y)=Gm(y)(x)m(x)(y)=_{G}m(y)(x) hold for all x,y:Gx,y:G.

Remark 4.16.

Since a group is by definition a set, any of these equalities has at most one inhabitant. Hence, the predicate ‘(G,m,i,e)(G,m,i,e) is a group’ is a mere proposition. This allows the groups we define to behave identically as in classical mathematics.

Definition 4.17.

Let (G,m,i,e)(G,m,i,e) and (G,m,i,e)(G^{\prime},m^{\prime},i^{\prime},e^{\prime}) be two groups. Then a function f:GGf:G\rightarrow G^{\prime} is called a group homomorphism if m(f(x))(f(y))=Gf(m(x))(m(y))m^{\prime}\left(f(x)\right)\left(f(y)\right)=_{G^{\prime}}f\left(m(x)\right)\left(m(y)\right) for all x,y:Gx,y:G. A group homomorphism ff is a group isomorphism if it is an equivalence.

Example 4.18.

𝟙\mathbb{1} is trivially a group, written as 0.

Importantly, set-truncation enables us to turn a loop space into a group:

Definition 4.19.

Let AA be a pointed type and n1n\geq 1. Define the nn-th homotopy group of AA as πn(A):Ωn(A)0\pi_{n}(A):\equiv\left\|{\Omega^{n}(A)}\right\|_{0}.

When n1n\geq 1, the set πn(A)\pi_{n}(A) is a group with path concatenation, path inversion and reflexivity. When n2n\geq 2, by the Eckmann-Hilton argument [Uni13, Theorem 2.1.6], πn(A)\pi_{n}(A) is an abelian group. We may also write π0(A)A0\pi_{0}(A)\equiv\left\|A\right\|_{0}, although it is not a group in general. Finally, πn\pi_{n} is a functor, as truncation and loop space are both functors by Lemma 5.6 and Proposition 4.10.

We know that 𝕊1{\mathbb{S}}^{1} is not contractible by Example 4.2. For the rest of this section, we briefly sketch the calculation of πk(𝕊1)\pi_{k}\left({\mathbb{S}}^{1}\right) for all k1k\geq 1. We proceed by first showing Ω1(𝕊1)\Omega^{1}\left({\mathbb{S}}^{1}\right)\simeq{\mathbb{Z}} with the encode-decode method based on [Uni13, Section 8.1.4]. This technique will be used again in Chapter 6.

The initial idea would be to give two functions Ω1(𝕊1)\Omega^{1}\left({\mathbb{S}}^{1}\right)\leftrightarrows{\mathbb{Z}} and show that they are quasi-inverses. The function Ω1(𝕊1){\mathbb{Z}}\rightarrow\Omega^{1}\left({\mathbb{S}}^{1}\right) is given by φ:λn.𝚕𝚘𝚘𝚙n\varphi:\equiv\lambda n.\mathtt{loop}^{n}, where 𝚕𝚘𝚘𝚙n\mathtt{loop}^{n} denotes the |n||n|-time concatenation of 𝚕𝚘𝚘𝚙\mathtt{loop} if n>0n>0 or 𝚕𝚘𝚘𝚙1\mathtt{loop}^{-1} if n<0n<0 and 𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎\mathtt{refl}_{\mathtt{base}} if n=0n=0. However, we cannot easily define a function (𝚋𝚊𝚜𝚎=𝕊1𝚋𝚊𝚜𝚎)\left(\mathtt{base}=_{{\mathbb{S}}^{1}}\mathtt{base}\right)\rightarrow{\mathbb{Z}}, as path induction is unavailable when the two endpoints are both fixed. We thus generalise the claim Ω1(𝕊1)\Omega^{1}\left({\mathbb{S}}^{1}\right)\simeq{\mathbb{Z}} to the following.

Lemma 4.20.

There exists a dependent type 𝚌𝚘𝚍𝚎:𝕊1𝚃𝚢𝚙𝚎\mathtt{code}:{\mathbb{S}}^{1}\rightarrow\mathtt{Type}, such that

(x:𝕊1)((𝚋𝚊𝚜𝚎=𝕊1x)𝚌𝚘𝚍𝚎(x))\left(x:{\mathbb{S}}^{1}\right)\rightarrow\left(\left(\mathtt{base}=_{{\mathbb{S}}^{1}}x\right)\simeq\mathtt{code}(x)\right)

and 𝚌𝚘𝚍𝚎(𝚋𝚊𝚜𝚎):\mathtt{code}(\mathtt{base}):\equiv{\mathbb{Z}}.

Proof sketch.

To finish the definition of 𝚌𝚘𝚍𝚎\mathtt{code}, as 𝚜𝚞𝚌𝚌:\mathtt{succ}:{\mathbb{Z}}\rightarrow{\mathbb{Z}} is an equivalence, 𝚞𝚊(𝚜𝚞𝚌𝚌)\mathtt{ua}(\mathtt{succ}) is a path ={\mathbb{Z}}={\mathbb{Z}}. We then set 𝚊𝚙𝚌𝚘𝚍𝚎(𝚕𝚘𝚘𝚙):=𝚞𝚊(𝚜𝚞𝚌𝚌)\mathtt{ap}_{\mathtt{code}}\left(\mathtt{loop}\right):=\mathtt{ua}(\mathtt{succ}). 𝚌𝚘𝚍𝚎\mathtt{code} represents the universal cover of the circle: the fibre over 𝚋𝚊𝚜𝚎\mathtt{base} is \mathbb{Z} and going around 𝚕𝚘𝚘𝚙\mathtt{loop} once corresponds to going up by one in \mathbb{Z}.

From this definition, we can prove that

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝𝚌𝚘𝚍𝚎(𝚕𝚘𝚘𝚙c)(x)=(x+c)\mathtt{transport}^{\mathtt{code}}\left(\mathtt{loop}^{c}\right)(x)=(x+c) (4.1)

for any c:c:{\mathbb{Z}} (by [Uni13, Lemma 8.1.2] and Proposition 3.12).

It then remains to define four functions of the types:

  1. (1)

    𝚎𝚗𝚌𝚘𝚍𝚎:(x:𝕊1)(𝚋𝚊𝚜𝚎=𝕊1x)𝚌𝚘𝚍𝚎(x)\mathtt{encode}:\left(x:{\mathbb{S}}^{1}\right)\rightarrow\left(\mathtt{base}=_{{\mathbb{S}}^{1}}x\right)\rightarrow\mathtt{code}(x),

  2. (2)

    𝚍𝚎𝚌𝚘𝚍𝚎:(x:𝕊1)𝚌𝚘𝚍𝚎(x)(𝚋𝚊𝚜𝚎=𝕊1x)\mathtt{decode}:\left(x:{\mathbb{S}}^{1}\right)\rightarrow\mathtt{code}(x)\rightarrow\left(\mathtt{base}=_{{\mathbb{S}}^{1}}x\right),

  3. (3)

    (x:𝕊1)(p:𝚋𝚊𝚜𝚎=𝕊1x)(𝚍𝚎𝚌𝚘𝚍𝚎(x)(𝚎𝚗𝚌𝚘𝚍𝚎(x)(p))=p)\left(x:{\mathbb{S}}^{1}\right)\rightarrow\left(p:\mathtt{base}=_{{\mathbb{S}}^{1}}x\right)\rightarrow\left(\mathtt{decode}(x)(\mathtt{encode}(x)(p))=p\right), and

  4. (4)

    (x:𝕊1)(c:𝚌𝚘𝚍𝚎(x))(𝚎𝚗𝚌𝚘𝚍𝚎(x)(𝚍𝚎𝚌𝚘𝚍𝚎(x)(c))=c)\left(x:{\mathbb{S}}^{1}\right)\rightarrow\left(c:\mathtt{code}(x)\right)\rightarrow\left(\mathtt{encode}(x)(\mathtt{decode}(x)(c))=c\right),

where (3) and (4) state that for each x:𝕊1x:{\mathbb{S}}^{1}, 𝚎𝚗𝚌𝚘𝚍𝚎(x)\mathtt{encode}(x) and 𝚍𝚎𝚌𝚘𝚍𝚎(x)\mathtt{decode}(x) are quasi-inverses.

To proceed, (1) is given by

𝚎𝚗𝚌𝚘𝚍𝚎(x)(p):𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝𝚌𝚘𝚍𝚎(p)(0);\mathtt{encode}(x)(p):\equiv\mathtt{transport}^{\mathtt{code}}(p)(0);

(2) uses circle induction, where 𝚍𝚎𝚌𝚘𝚍𝚎(𝚋𝚊𝚜𝚎)\mathtt{decode}(\mathtt{base}) is given by the function φ:(𝚋𝚊𝚜𝚎=𝚋𝚊𝚜𝚎)\varphi:{\mathbb{Z}}\rightarrow\left(\mathtt{base}=\mathtt{base}\right) defined earlier; (3) uses path induction and (4) circle induction, and they both apply Equality 4.1. We omit the details. ∎

Now setting xx to 𝚋𝚊𝚜𝚎\mathtt{base} in Lemma 4.20 yields Ω1(𝕊1)\Omega^{1}\left({\mathbb{S}}^{1}\right)\simeq{\mathbb{Z}}.

Corollary 4.21.

π1(𝕊1)\pi_{1}\left({\mathbb{S}}^{1}\right)\simeq{\mathbb{Z}} and πk(𝕊1)0\pi_{k}\left({\mathbb{S}}^{1}\right)\simeq 0 for k2k\geq 2.

Proof.

Since \mathbb{Z} is a set, 0=\left\|{\mathbb{Z}}\right\|_{0}={\mathbb{Z}}. Thus, π1(𝕊1)Ω1(𝕊1)00=\pi_{1}\left({\mathbb{S}}^{1}\right)\equiv\left\|{\Omega^{1}\left({\mathbb{S}}^{1}\right)}\right\|_{0}\simeq\left\|{\mathbb{Z}}\right\|_{0}={\mathbb{Z}}. Further, since \mathbb{Z} is a set, Ω1(𝕊1)\Omega^{1}\left({\mathbb{S}}^{1}\right) is also a set, which implies that Ωk(𝕊1)\Omega^{k}\left({\mathbb{S}}^{1}\right) is trivial for any k2k\geq 2, and therefore so is πk(𝕊1)\pi_{k}\left({\mathbb{S}}^{1}\right). ∎

4.5 nn-connected types

Definition 4.22.

Let A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type} and f:ABf:A\rightarrow B. The fibre of ff over y:By:B is defined as the type

𝚏𝚒𝚋f(y):x:A(f(x)=By).\mathtt{fib}_{f}(y):\equiv\sum_{x:A}\left(f(x)=_{B}y\right).
Definition 4.23.

A type AA is nn-connected if An\left\|A\right\|_{n} is contractible, and a function f:ABf:A\rightarrow B is nn-connected if for all y:By:B, 𝚏𝚒𝚋f(y)n\left\|{\mathtt{fib}_{f}(y)}\right\|_{n} is contractible. In particular, a function f:ABf:A\rightarrow B is surjective, connected, or simply-connected if it is (1)(-1)-, 0-, or 11-connected, respectively.

Remark 4.24.

An nn-connected function ff can be thought of as ‘being surjective up to dimension (n+1)(n+1)’. In particular, ff preserves ‘homotopy information’ up to dimension nn. This is formalised in Lemma 4.32 and Corollary 5.14. We also remark that different conventions in defining the nn-connectedness of functions exist.

Easily seen from the definitions are:

  1. (1)

    A type AA is nn-connected if and only if the unique function A𝟙A\rightarrow\mathbb{1} is nn-connected;

  2. (2)

    Every type is (2)(-2)-connected and so is every function;

  3. (3)

    Every pointed type is (1)(-1)-connected.

Example 4.25 ( \blacksquare Inspired by [Hou17, Figure 3.4]).

Consider an HIT GG generated by a non-empty graph G¯\overline{G}: each vertex v¯G¯\overline{v}\in\overline{G} gives a term v:Gv:G and each edge e¯\overline{e} connecting vertices v1¯\overline{v_{1}} and v2¯\overline{v_{2}} gives a path e:v1=Gv2e:v_{1}=_{G}v_{2}, where the order of v1v_{1} and v2v_{2} is arbitrary thanks to path inversion.

If G¯\overline{G} has only one connected component, then GG is 0-connected. Indeed, as G0\left\|G\right\|_{0} is pointed, it suffices to show that x=yx^{\prime}=y^{\prime} is contractible for any x,y:G0x^{\prime},y^{\prime}:\left\|G\right\|_{0}. The goal is a mere proposition, so we assume xx^{\prime} is |x|0|x|_{0} and yy^{\prime} is |y|0|y|_{0} for x,y:Gx,y:G. By Proposition 4.12, (|x|0=|y|0)x=y1\left(|x|_{0}=|y|_{0}\right)\simeq\left\|{x=y}\right\|_{-1}, but x=y1\left\|{x=y}\right\|_{-1} is pointed by assumption and is thus contractible.

If further G¯\overline{G} is a tree, then GG is 11-connected. Indeed, using the same reasoning twice, it suffices to show that p=q1\left\|{p=q}\right\|_{-1} is contractible for any x,y:Gx,y:G and p,q:x=yp,q:x=y, which holds since any two vertices on a tree has a unique path between them up to homotopy.

Example 4.26.

𝕊0𝟚{\mathbb{S}}^{0}\equiv\mathbb{2} is pointed and is (1)(-1)-connected. Example 4.25 indicates that 𝕊1{\mathbb{S}}^{1} is 0-connected. In fact, for all n:n:{\mathbb{N}}, the sphere 𝕊n{\mathbb{S}}^{n} is (n1)(n-1)-connected [Uni13, Corollary 8.2.2].

We observe that nn-connected types and functions have the (downward) cumulativity property:

Proposition 4.27 ([Bru16, Proposition 2.3.7]).

Let 2mn-2\leq m\leq n. Any nn-connected type (resp. function) is also an mm-connected type (resp. function).

Proof.

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type} be nn-connected. Then AmAnm\left\|A\right\|_{m}\simeq\left\|\left\|A\right\|_{n}\right\|_{m} by Lemma 4.14, and AnmAn\left\|\left\|A\right\|_{n}\right\|_{m}\simeq\left\|A\right\|_{n} by Proposition 4.11 since An\left\|A\right\|_{n} is contractible and a fortiori an mm-type. So Am\left\|A\right\|_{m} is contractible. The case for nn-connected functions is similar. ∎

We can also say something about the lower homotopy groups of an nn-connected type:

Lemma 4.28 ([Uni13, Lemma 8.3.2]).

If AA is a pointed nn-connected type, then πk(A)0\pi_{k}(A)\simeq 0 for all knk\leq n.

Proof.

We calculate

πk(A)Ωk(A)0Ωk(Ak)Ωk(Ank)Ωk(𝟙k)Ωk(𝟙)𝟙,\pi_{k}(A)\equiv\left\|{\Omega^{k}(A)}\right\|_{0}\simeq\Omega^{k}\left(\left\|A\right\|_{k}\right)\simeq\Omega^{k}\left(\left\|\left\|A\right\|_{n}\right\|_{k}\right)\simeq\Omega^{k}\left(\left\|\mathbb{1}\right\|_{k}\right)\simeq\Omega^{k}\left(\mathbb{1}\right)\simeq\mathbb{1},

by Proposition 4.13 and Lemma 4.14. ∎

Corollary 4.29.

πk(𝕊n)0\pi_{k}\left({\mathbb{S}}^{n}\right)\simeq 0 for k<nk<n.

Proof.

We have ‘induction principles’ for nn-connected types and functions:

Proposition 4.30 (Induction principle for nn-connected types).

Suppose n2n\geq-2 and AA is an (n+1)(n+1)-connected type. Given

  • a dependent type P:An-𝚃𝚢𝚙𝚎P:A\rightarrow n\mathtt{\text{-}Type},

  • a0:Aa_{0}:A and

  • p:P(a0)p:P\left(a_{0}\right),

there is a dependent function f:(x:A)P(x)f:(x:A)\rightarrow P(x) such that f(a0):pf\left(a_{0}\right):\equiv p.

Proof.

\blacksquare Since n-𝚃𝚢𝚙𝚎n\mathtt{\text{-}Type} is an (n+1)(n+1)-type, by the recursion principle of An+1\left\|A\right\|_{n+1}, there is a dependent type P:An+1n-𝚃𝚢𝚙𝚎P^{\prime}:\left\|A\right\|_{n+1}\rightarrow n\mathtt{\text{-}Type} such that P(|a|n+1):P(a)P^{\prime}\left(|a|_{n+1}\right):\equiv P(a). Since An+1\left\|A\right\|_{n+1} is contractible, there is a function f:(x:An+1)P(x)f^{\prime}:\left(x:\left\|A\right\|_{n+1}\right)\rightarrow P^{\prime}(x) such that f(|a0|n+1):p:P(a0)P(|a0|n+1)f^{\prime}\left(\left|a_{0}\right|_{n+1}\right):\equiv p:P\left(a_{0}\right)\equiv P^{\prime}\left(\left|a_{0}\right|_{n+1}\right). Therefore, we obtain f:(f||n+1):(a:A)P(|a|n+1)P(a)f:\equiv\left(f^{\prime}\circ|-|_{n+1}\right):(a:A)\rightarrow P^{\prime}\left(|a|_{n+1}\right)\equiv P(a). ∎

Proposition 4.31 (‘Induction principle’ for nn-connected maps, [Uni13, Lemma 7.5.7]).

Suppose n2n\geq-2, A,B:𝚃𝚢𝚙𝚎A,B:\mathtt{Type}, and f:ABf:A\rightarrow B. Then ff is nn-connected, if and only if for any P:Bn-𝚃𝚢𝚙𝚎P:B\rightarrow n\mathtt{\text{-}Type}, the map

λs.sf:((b:B)P(b))((a:A)P(f(a)))\lambda s.s\circ f:\left((b:B)\rightarrow P(b)\right)\rightarrow\left((a:A)\rightarrow P\left(f(a)\right)\right)

is an equivalence.

Intuitively, Proposition 4.30 says that an (n+1)(n+1)-connected type ‘looks like’ a contractible type to any family of nn-types, and Proposition 4.31 says that in the presence of an nn-connected map f:ABf:A\rightarrow B, a family of nn-types over BB sees BB as being ‘generated’ by AA [HFLL16, Section 2].

Finally, we mention that an nn-connected function induces an equivalence on nn-truncations:

Lemma 4.32 ([Uni13, Lemma 7.5.14]).

If f:ABf:A\rightarrow B is nn-connected, then it induces an equivalence AnBn\left\|A\right\|_{n}\simeq\left\|B\right\|_{n}.

Chapter 5 Hopf fibration

The centre of this chapter is the following definition:

Definition 5.1.

Let XX, YY be pointed types. Define the type of pointed maps from XX to YY as

𝙼𝚊𝚙(X,Y):f:XY(f(X)=YY).\mathtt{Map}_{\star}(X,Y):\equiv\sum_{f:X\rightarrow Y}\left(f\left(\star_{X}\right)=_{Y}\star_{Y}\right).

We may say that f:XYf:X\rightarrow_{\star}Y is a pointed map witnessed by path f:f(X)=YYf_{\star}:f\left(\star_{X}\right)=_{Y}\star_{Y}.

For any pointed map f:XYf:X\rightarrow_{\star}Y, the homotopy groups of F𝚏𝚒𝚋f(Y)F\equiv\mathtt{fib}_{f}\left(\star_{Y}\right), XX and YY are related by a long exact sequence, obtained from a fibre sequence, shown in Section 5.1. In particular, given a ‘pointed fibration’ (in the sense of Corollary 5.3), FF, XX, YY correspond respectively to the fibre, total space and base space of the fibration. In Section 5.2, we work to build the Hopf construction, a fibration based on H-spaces. In Section 5.3, we demonstrate an H-space structure on 𝕊1{\mathbb{S}}^{1} and derive the Hopf fibration, whose long exact sequence fascinatingly connects the homotopy groups of 𝕊1{\mathbb{S}}^{1}, 𝕊2{\mathbb{S}}^{2} and 𝕊3{\mathbb{S}}^{3}.

5.1 Fibre sequences

We begin with a simple yet powerful observation.

Lemma 5.2.

Let XX and YY be pointed types and let f:XYf:X\rightarrow_{\star}Y be witnessed by ff_{\star}. Let F:𝚏𝚒𝚋f(Y)F:\equiv\mathtt{fib}_{f}\left(\star_{Y}\right) and i𝚙𝚛1:FXi\equiv\mathtt{pr}_{1}:F\rightarrow X. Then we have pointed types and pointed maps:

F𝑖X𝑓Y.F\overset{i}{\rightarrow}X\overset{f}{\rightarrow}Y.
Proof.

FF is pointed by (X,f)\left(\star_{X},f_{\star}\right), and since i(X,f)Xi\left(\star_{X},f_{\star}\right)\equiv\star_{X}, ii is a pointed map witnessed by 𝚛𝚎𝚏𝚕X\mathtt{refl}_{\star_{X}}. ∎

A special case is the following, a fibration over YY with fibre FF and total space XX.

Corollary 5.3.

Let YY be a pointed type and P:Y𝚃𝚢𝚙𝚎P:Y\rightarrow\mathtt{Type} be a dependent type such that P(Y)P\left(\star_{Y}\right) is a pointed type. Then we have pointed types and pointed maps:

P(Y)𝑖y:YP(y)𝑓Y,P\left(\star_{Y}\right)\overset{i}{\rightarrow}\sum_{y:Y}P(y)\overset{f}{\rightarrow}Y,

called the fibration sequence, where f𝚙𝚛1f\equiv\mathtt{pr}_{1} and iλz.(Y,z)i\equiv\lambda z.\left(\star_{Y},z\right).

Proof.

\blacksquareXy:YP(y)X\equiv\sum_{y:Y}P(y) has basepoint (Y,P(Y))\left(\star_{Y},\star_{P\left(\star_{Y}\right)}\right) and ff is thus a pointed map. Then we can apply Lemma 5.2, but F𝚏𝚒𝚋f(Y)P(Y)F\equiv\mathtt{fib}_{f}\left(\star_{Y}\right)\simeq P\left(\star_{Y}\right) by [Uni13, Lemma 4.8.1] (which uses Proposition 4.3). The map ii is as above under this equivalence. ∎

The rest of this section is based on the more general Lemma 5.2, although later in practice we only use the case Corollary 5.3. Since i:FXi:F\rightarrow X is again a pointed map, we apply Lemma 5.2 recursively to yield the following construction:

Definition 5.4.

Let XX and YY be pointed types. The fibre sequence of a pointed map f:XYf:X\rightarrow_{\star}Y witnessed by ff_{\star} is the infinite sequence of pointed types and pointed maps

f(n)X(n)f(n1)X(n1)f(n2)X(n2)f(0)X(0).\ldots\overset{f^{(n)}}{\rightarrow}X^{(n)}\overset{f^{(n-1)}}{\rightarrow}X^{(n-1)}\overset{f^{(n-2)}}{\rightarrow}X^{(n-2)}\rightarrow\ldots\overset{f^{(0)}}{\rightarrow}X^{(0)}.

We denote (n):X(n)\star^{(n)}:X^{(n)} as the basepoint of X(n)X^{(n)} and f(n):f(n)((n+1))=X(n)(n)f_{\star}^{(n)}:f^{(n)}\left(\star^{(n+1)}\right)=_{X^{(n)}}\star^{(n)} as the witnessing path of f(n)f^{(n)}. The sequence is then defined recursively by

  • X(0):YX^{(0)}:\equiv Y, X(1):XX^{(1)}:\equiv X, f(0):ff^{(0)}:\equiv f, (0):Y\star^{(0)}:\equiv\star_{Y}, (1):X\star^{(1)}:\equiv\star_{X}, f(0):ff_{\star}^{(0)}:\equiv f_{\star};

  • If n2n\geq 2,

    X(n):𝚏𝚒𝚋f(n2)((n2))\displaystyle X^{(n)}:\equiv\mathtt{fib}_{f^{(n-2)}}\left(\star^{(n-2)}\right) ,f(n1):𝚙𝚛1:X(n)X(n1),\displaystyle,\quad f^{(n-1)}:\equiv\mathtt{pr}_{1}:X^{(n)}\rightarrow X^{(n-1)},
    (n):((n1),f(n2))\displaystyle\star^{(n)}:\equiv\left(\star^{(n-1)},f_{\star}^{(n-2)}\right) ,f(n1):𝚛𝚎𝚏𝚕(n1).\displaystyle,\quad f_{\star}^{(n-1)}:\equiv\mathtt{refl}_{\star^{(n-1)}}.

We denote F:𝚏𝚒𝚋f(Y)X(2)F:\equiv\mathtt{fib}_{f}\left(\star_{Y}\right)\equiv X^{(2)}.

This fibre sequence can be (magically) turned into an equivalent form where the loop spaces of FF, XX and YY show up in a periodic fashion. The following two ingredients are needed before we move on.

Definition 5.5.

If f:ABf:A\rightarrow_{\star}B is a type equivalence, then ff is a pointed equivalence and in this case AA and BB are pointed equivalent.

Lemma 5.6.

The looping of f:ABf:A\rightarrow_{\star}B defined as Ωf:(λq.f1𝚊𝚙f(q)f):ΩAΩB\Omega f:\equiv\left(\lambda q.f_{\star}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{ap}_{f}(q)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}f_{\star}\right):\Omega A\rightarrow\Omega B is also a pointed map.

Proof.

(Ωf)(𝚛𝚎𝚏𝚕A)f1𝚛𝚎𝚏𝚕f(A)f=𝚛𝚎𝚏𝚕B(\Omega f)\left(\mathtt{refl}_{\star_{A}}\right)\equiv f_{\star}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{refl}_{f\left(\star_{A}\right)}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}f_{\star}=\mathtt{refl}_{\star_{B}}. ∎

We now work to reveal the first step of the alleged equivalence.

Lemma 5.7 ([Uni13, Lemma 8.4.4]).

Let XX and YY be pointed types and let f:XYf:X\rightarrow_{\star}Y. Then X(3)ΩYX^{(3)}\simeq\Omega Y in the fibre sequence of ff. Further, under the equivalence, f(2)f^{(2)} is identified with

:λr.(X,fr):ΩYF.\partial:\equiv\lambda r.\left(\star_{X},f_{\star}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}r\right):\Omega Y\rightarrow F.
xxX\star_{X}f(x)f(x)f(X)f(\star_{X})Y\star_{Y}qq𝚊𝚙f(q1)\mathtt{ap}_{f}(q^{-1})ppf1f_{*}^{-1}rrXXYYff
Figure 5.1: Diagram for Lemma 5.7.
Proof.

See Figure 5.1. Using the definition of fibres twice, a term of X(3)X^{(3)} is of the form ((x,p),q)\left((x,p),q\right), where x:Xx:X, p:f(x)=YYp:f(x)=_{Y}\star_{Y} and q:x=XXq:x=_{X}\star_{X}. We first define a function φ:X(3)Ω(Y)\varphi:X^{(3)}\rightarrow\Omega(Y). Take any ((x,p),q):X(3)\left((x,p),q\right):X^{(3)}. Then 𝚊𝚙f(q1):f(X)=Yf(x)\mathtt{ap}_{f}\left(q^{-1}\right):f\left(\star_{X}\right)=_{Y}f(x). Thus since f:f(X)=YYf_{\star}:f\left(\star_{X}\right)=_{Y}\star_{Y}, we can produce f1𝚊𝚙f(q1)p:Ω(Y)f_{\star}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{ap}_{f}\left(q^{-1}\right)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}p:\Omega(Y). Conversely, we define ψ:Ω(Y)X(3)\psi:\Omega(Y)\rightarrow X^{(3)} by

λr.((X,fr),𝚛𝚎𝚏𝚕X).\lambda r.\left(\left(\star_{X},f_{\star}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}r\right),\mathtt{refl}_{\star_{X}}\right).

Now take any ((x,p),q):X(3)\left((x,p),q\right):X^{(3)}, then

ψ(φ((x,p),q))\displaystyle\psi(\varphi((x,p),q)) ψ(f1𝚊𝚙f(q1)p)\displaystyle\equiv\psi\left(f_{\star}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{ap}_{f}\left(q^{-1}\right)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}p\right)
=((X,𝚊𝚙f(q1)p),𝚛𝚎𝚏𝚕X)\displaystyle=\left(\left(\star_{X},\mathtt{ap}_{f}\left(q^{-1}\right)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}p\right),\mathtt{refl}_{\star_{X}}\right)
=((x,p),q),\displaystyle=\left((x,p),q\right),

where the last equality is by Proposition 3.21 and Lemma 3.13. Conversely, for any r:Ω(Y,Y)r:\Omega(Y,\star_{Y}),

φ(ψ(r))φ((X,fr),𝚛𝚎𝚏𝚕X)=f1𝚊𝚙f(𝚛𝚎𝚏𝚕X1)fr=r.\varphi(\psi(r))\equiv\varphi(\left(\star_{X},f_{\star}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}r\right),\mathtt{refl}_{\star_{X}})=f_{\star}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{ap}_{f}\left(\mathtt{refl}_{\star_{X}}^{-1}\right)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}f_{\star}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}r=r.

Thus ψ\psi forms a quasi-inverse of φ\varphi. Also ψ\psi and φ\varphi are both pointed maps, so X(3)X^{(3)} and ΩY\Omega Y are pointed equivalent. We therefore identify f(2):X(3)Ff^{(2)}:X^{(3)}\rightarrow F with :f(2)ψ:ΩYF\partial:\equiv f^{(2)}\circ\psi:\Omega Y\rightarrow F, which can be simplified as λr.(X,fr)\lambda r.\left(\star_{X},f_{\star}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}r\right), easily a pointed map. ∎

By applying Lemma 5.7 recursively to the fibre sequence, we have:

Corollary 5.8 ([Uni13, Lemma 8.4.4]).

The fibre sequence of f:XYf:X\rightarrow_{\star}Y can be equivalently written as

Ω2XΩ2fΩ2YΩΩFΩiΩXΩfΩYF𝑖X𝑓Y.\rightarrow\Omega^{2}X\overset{\Omega^{2}f}{\rightarrow}\Omega^{2}Y\overset{-\Omega\partial}{\rightarrow}\Omega F\overset{-\Omega i}{\rightarrow}\Omega X\overset{-\Omega f}{\rightarrow}\Omega Y\overset{\partial}{\rightarrow}F\overset{i}{\rightarrow}X\overset{f}{\rightarrow}Y.

where i:𝚙𝚛1i:\equiv\mathtt{pr}_{1} and the minus sign represents composition with path inversion.

We will then show that this fibre sequence, when set-truncated, becomes an exact sequence, defined below.

Definition 5.9.

Let A,BA,B be sets and let f:ABf:A\rightarrow B, then the image of ff is defined as im(f):b:B𝚏𝚒𝚋f(b)1.\operatorname{im}(f):\equiv\sum_{b:B}\left\|{\mathtt{fib}_{f}(b)}\right\|_{-1}. If A,BA,B are pointed sets and let f:ABf:A\rightarrow_{\star}B, then the kernel of ff is defined as ker(f):𝚏𝚒𝚋f(B)\ker(f):\equiv\mathtt{fib}_{f}\left(\star_{B}\right).

Definition 5.10.

An exact sequence of pointed sets is a sequence of pointed sets and pointed maps:

A(n+1)f(n)A(n)f(n1)A(n1)\ldots\rightarrow A^{(n+1)}\overset{f^{(n)}}{\rightarrow}A^{(n)}\overset{f^{(n-1)}}{\rightarrow}A^{(n-1)}\rightarrow\ldots

such that im(f(n))=ker(f(n1))\operatorname{im}(f^{(n)})=\ker(f^{(n-1)}) for every nn. The sequence is an exact sequence of groups if further each A(n)A^{(n)} is a group and each f(n)f^{(n)} is a group homomorphism.

Lemma 5.11 ([Uni13, Theorem 8.4.6] 111\blacksquare A few typos in [Uni13, Theorem 8.4.6] are fixed in this proof.).

For any F𝑖X𝑓YF\overset{i}{\rightarrow}X\overset{f}{\rightarrow}Y given by Lemma 5.2,

F0i0X0f0Y0\left\|F\right\|_{0}\overset{\left\|i\right\|_{0}}{\rightarrow}\left\|X\right\|_{0}\overset{\left\|f\right\|_{0}}{\rightarrow}\left\|Y\right\|_{0}

is an exact sequence of pointed sets.

Proof.

im(i0)ker(f0)\operatorname{im}(\left\|i\right\|_{0})\subset\ker(\left\|f\right\|_{0}). Take any (x,p):F(x,p):F, then f(i(x,p))f(x)=YYf\left(i(x,p)\right)\equiv f(x)=_{Y}\star_{Y} as witnessed by pp. Thus fi0\left\|{f\circ i}\right\|_{0} sends everything to |Y|0\left|\star_{Y}\right|_{0}, and so does f0i0\left\|f\right\|_{0}\circ\left\|i\right\|_{0} by the functoriality of 0\left\|-\right\|_{0}.

ker(f0)im(i0)\ker(\left\|f\right\|_{0})\subset\operatorname{im}(\left\|i\right\|_{0}). For any x:X0x^{\prime}:\left\|X\right\|_{0} and p:f0(x)=Y0|Y|0p^{\prime}:\left\|f\right\|_{0}(x^{\prime})=_{\left\|Y\right\|_{0}}\left|\star_{Y}\right|_{0}, we claim that there merely exists t:Ft:F such that |i(t)|0=X0x\left|{i(t)}\right|_{0}=_{\left\|X\right\|_{0}}x^{\prime}. As the goal is a mere proposition and a fortiori a 0-type, by truncation induction, it suffices to assume xx^{\prime} is |x|0|x|_{0} for some x:Xx:X. Then since f0(|x|0)|f(x)|0\left\|f\right\|_{0}\left(|x|_{0}\right)\equiv\left|{f(x)}\right|_{0}, we have p:|f(x)|0=Y0|Y|0p^{\prime}:\left|{f(x)}\right|_{0}=_{\left\|Y\right\|_{0}}\left|\star_{Y}\right|_{0}, which by Proposition 4.12, corresponds to some p′′:f(x)=YY1p^{\prime\prime}:\left\|{f(x)=_{Y}\star_{Y}}\right\|_{-1}. Again by truncation induction, it suffices to assume p′′p^{\prime\prime} is |p|1|p|_{-1} for some p:f(x)=YYp:f(x)=_{Y}\star_{Y}. Thus we take t:(x,p):Ft:\equiv(x,p):F, and then |i(t)|0|x|0x\left|{i(t)}\right|_{0}\equiv|x|_{0}\equiv x^{\prime}. ∎

Theorem 5.12 ([Uni13, Theorem 8.4.6]).

Let X,YX,Y be pointed types and let f:XYf:X\rightarrow_{\star}Y. Let F:𝚏𝚒𝚋f(Y)F:\equiv\mathtt{fib}_{f}\left(\star_{Y}\right). Then we have an exact sequence of pointed sets

\displaystyle\ldots\rightarrow πk(F)πk(X)πk(Y)\displaystyle\pi_{k}(F)\rightarrow\pi_{k}(X)\rightarrow\pi_{k}(Y)\rightarrow
\displaystyle\ldots\rightarrow π2(F)π2(X)π2(Y)\displaystyle\pi_{2}(F)\rightarrow\pi_{2}(X)\rightarrow\pi_{2}(Y)
\displaystyle\rightarrow π1(F)π1(X)π1(Y)\displaystyle\pi_{1}(F)\rightarrow\pi_{1}(X)\rightarrow\pi_{1}(Y)
\displaystyle\rightarrow π0(F)π0(X)π0(Y).\displaystyle\pi_{0}(F)\rightarrow\pi_{0}(X)\rightarrow\pi_{0}(Y).

This is further an exact sequence of groups except the π0\pi_{0} terms, and an exact sequence of abelian groups except the π0\pi_{0} and π1\pi_{1} terms.

Proof.

By recursively applying Lemma 5.11 to the fibre sequence of ff, the above is an exact sequence of pointed sets. The rest of the proof, including some technicalities involving path inversion, is omitted. ∎

The following lemma is commonly known in classical algebraic topology.

Lemma 5.13 ([Uni13, Lemma 8.4.7]).

Let CA𝑓BDC\rightarrow A\overset{f}{\rightarrow}B\rightarrow D be an exact sequence of abelian groups. Then (1) ff is injective if CC is 0; (2) ff is surjective if DD is 0; (3) ff is an isomorphism if CC and DD are both 0.

From the next result, which characterises an nn-connected function in terms of homotopy groups, we formalise the idea that an nn-connected function is a generalisation of a surjective function.

Corollary 5.14.

Let X,YX,Y be pointed types and let f:XYf:X\rightarrow_{\star}Y be nn-connected.

  1. (1)

    If knk\leq n, then πk(f):πk(X)πk(Y)\pi_{k}(f):\pi_{k}(X)\rightarrow\pi_{k}(Y) is an isomorphism;

  2. (2)

    If k=n+1k=n+1, then πk(f):πk(X)πk(Y)\pi_{k}(f):\pi_{k}(X)\rightarrow\pi_{k}(Y) is surjective.

Proof.

We omit the case when k=0k=0 and suppose k>0k>0. We have an exact sequence

πk(F)πk(X)πk(Y)πk1(F).\pi_{k}(F)\rightarrow\pi_{k}(X)\rightarrow\pi_{k}(Y)\rightarrow\pi_{k-1}(F).

Since ff is nn-connected, by Proposition 4.27, ff is also kk-connected when knk\leq n. Thus Fk𝚏𝚒𝚋f(Y)k\left\|F\right\|_{k}\equiv\left\|{\mathtt{fib}_{f}\left(\star_{Y}\right)}\right\|_{k} is contractible, and πk(F)Ωk(F)0Ωk(Fk)\pi_{k}(F)\equiv\left\|{\Omega^{k}(F)}\right\|_{0}\simeq\Omega^{k}\left(\left\|F\right\|_{k}\right) (by Proposition 4.13) is also contractible for knk\leq n. Applying Lemma 5.13 yields the result. ∎

Remark 5.15.

Set YY to 𝟙\mathbb{1} and Corollary 5.14 would imply Lemma 4.28.

5.2 Hopf construction

To trigger all the machinery in the previous section, we only need a fibration sequence as in Corollary 5.3. We now build the Hopf construction, a fibration sequence derived from a 0-connected H-space.

Definition 5.16.

A type AA is an H-space if it is equipped with a base point e:Ae:A, a binary operation μ:A×AA\mu:A\times A\rightarrow A and equalities μ(e,a)=a\mu(e,a)=a and μ(a,e)=a\mu(a,e)=a for every a:Aa:A.

Lemma 5.17.

Let AA be a 0-connected H-space. Then μ(a,):AA\mu(a,-):A\rightarrow A and μ(,a):AA\mu(-,a):A\rightarrow A are equivalences for every a:Aa:A.

Proof.

Let P:A𝙿𝚛𝚘𝚙P:A\rightarrow\mathtt{Prop} be the dependent proposition which sends a:Aa:A to the predicate that μ(a,)\mu(a,-) (resp. μ(,a)\mu(-,a)) is an equivalence. By Proposition 4.30, it suffices to prove P(e)P(e), which holds by definition. ∎

The flattening lemma, used in the next proof, is a result concerning the total space of a fibration over an HIT constructed via univalence [Uni13, Section 6.12].

Theorem 5.18 ([Uni13, Lemma 8.5.7]).

Let AA be a 0-connected HH-space. Then there is a dependent type (fibration) P:ΣA𝚃𝚢𝚙𝚎P:\Sigma A\rightarrow\mathtt{Type} with fibre AA and total space x:ΣAP(x)AA\sum_{x:\Sigma A}P(x)\simeq A\ast A, called the Hopf construction.

Proof.

We define a dependent type P:ΣA𝚃𝚢𝚙𝚎P:\Sigma A\rightarrow\mathtt{Type} by P(𝚗𝚘𝚛𝚝𝚑):AP\left(\mathtt{north}\right):\equiv A, P(𝚜𝚘𝚞𝚝𝚑):AP\left(\mathtt{south}\right):\equiv A, and 𝚊𝚙P(𝚖𝚎𝚛𝚒𝚍(a)):=𝚞𝚊(μ(a,))\mathtt{ap}_{P}\left(\mathtt{merid}(a)\right):=\mathtt{ua}(\mu(a,-)) since each μ(a,)\mu(a,-) is an equivalence AAA\rightarrow A. By the flattening lemma (see [Uni13, Lemma 8.5.3] or [Bru16, Proposition 1.9.2]), x:ΣAP(x)\sum_{x:\Sigma A}P(x) is equivalent to the pushout of the span A𝚜𝚗𝚍A×A𝜇A.A\overset{\mathtt{snd}}{\leftarrow}A\times A\overset{\mu}{\rightarrow}A. We define a function α:A×AA×A\alpha:A\times A\rightarrow A\times A by α(x,y):(μ(x,y),y)\alpha(x,y):\equiv\left(\mu(x,y),y\right), and α\alpha is an equivalence because it has quasi-inverse λ(u,v).((μ(,v))1(u),v)\lambda(u,v).\left(\left(\mu(-,v)\right)^{-1}(u),v\right). Therefore, we have an equivalence of spans

A{A}A×A{{A\times A}}A{A}A{A}A×A{{A\times A}}A,{A,}𝚜𝚗𝚍\scriptstyle{\mathtt{snd}}μ\scriptstyle{\mu}𝚜𝚗𝚍\scriptstyle{\mathtt{snd}}𝚏𝚜𝚝\scriptstyle{\mathtt{fst}}𝚒𝚍A\scriptstyle{\mathtt{id}_{A}}α\scriptstyle{\alpha}𝚒𝚍A\scriptstyle{\mathtt{id}_{A}}

since both squares commute and each vertical line is an equivalence. Thus, the pushout of the two spans are also equivalent, but the pushout of the lower span is by definition AAA\ast A. ∎

5.3 Hopf fibration

We finally present the Hopf construction induced by the H-space structure on 𝕊1{\mathbb{S}}^{1}.

Lemma 5.19 ([Uni13, Lemma 8.5.8]).

There is an HH-space structure on 𝕊1{\mathbb{S}}^{1}.

Proof.

Take e:𝚋𝚊𝚜𝚎:𝕊1e:\equiv\mathtt{base}:{\mathbb{S}}^{1}. Now we define μ:𝕊1𝕊1𝕊1\mu:{\mathbb{S}}^{1}\rightarrow{\mathbb{S}}^{1}\rightarrow{\mathbb{S}}^{1} by circle induction on the first argument. We define μ(𝚋𝚊𝚜𝚎):id𝕊1\mu(\mathtt{base}):\equiv\operatorname{id}\limits_{{\mathbb{S}}^{1}}; then we need a path p:id𝕊1=𝕊1𝕊1id𝕊1p:\operatorname{id}\limits_{{\mathbb{S}}^{1}}=_{{\mathbb{S}}^{1}\rightarrow{\mathbb{S}}^{1}}\operatorname{id}\limits_{{\mathbb{S}}^{1}} such that 𝚊𝚙μ(𝚕𝚘𝚘𝚙):=p\mathtt{ap}_{\mu}\left(\mathtt{loop}\right):=p. By function extensionality, this is equivalent to a path px:x=𝕊1xp_{x}:x=_{{\mathbb{S}}^{1}}x for each x:𝕊1x:{\mathbb{S}}^{1}. By induction on x:𝕊1x:{\mathbb{S}}^{1} again, we define p𝚋𝚊𝚜𝚎:𝚕𝚘𝚘𝚙p_{\mathtt{base}}:\equiv\mathtt{loop}. It then remains to give a dependent path 𝚕𝚘𝚘𝚙=𝚕𝚘𝚘𝚙λx.x=𝕊1x𝚕𝚘𝚘𝚙\mathtt{loop}=_{\mathtt{loop}}^{\lambda x.x=_{{\mathbb{S}}^{1}}x}\mathtt{loop}, which is equivalent to 𝚕𝚘𝚘𝚙1𝚕𝚘𝚘𝚙𝚕𝚘𝚘𝚙=𝚕𝚘𝚘𝚙\mathtt{loop}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{loop}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{loop}=\mathtt{loop} by Lemma 3.13.

Now μ(𝚋𝚊𝚜𝚎)(x)x\mu(\mathtt{base})(x)\equiv x since μ(𝚋𝚊𝚜𝚎)id𝕊1\mu(\mathtt{base})\equiv\operatorname{id}\limits_{{\mathbb{S}}^{1}}. We show that μ(x)(𝚋𝚊𝚜𝚎)=𝕊1x\mu(x)(\mathtt{base})=_{{\mathbb{S}}^{1}}x by circle induction on x:𝕊1x:{\mathbb{S}}^{1}. When xx is 𝚋𝚊𝚜𝚎\mathtt{base}, μ(𝚋𝚊𝚜𝚎)(𝚋𝚊𝚜𝚎)𝚋𝚊𝚜𝚎\mu(\mathtt{base})(\mathtt{base})\equiv\mathtt{base}, so we take 𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎\mathtt{refl}_{\mathtt{base}}; when xx ‘varies along’ 𝚕𝚘𝚘𝚙\mathtt{loop}, we need a dependent path

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝λx.μ(x)(𝚋𝚊𝚜𝚎)=𝕊1x(𝚕𝚘𝚘𝚙)(𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎)=𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎,\mathtt{transport}^{\lambda x.\mu(x)(\mathtt{base})=_{{\mathbb{S}}^{1}}x}\left(\mathtt{loop}\right)\left(\mathtt{refl}_{\mathtt{base}}\right)=\mathtt{refl}_{\mathtt{base}},

which is equivalent to 𝚊𝚙λx.μ(x)(𝚋𝚊𝚜𝚎)(𝚕𝚘𝚘𝚙)1𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎𝚕𝚘𝚘𝚙=𝚛𝚎𝚏𝚕𝚋𝚊𝚜𝚎\mathtt{ap}_{\lambda x.\mu(x)(\mathtt{base})}\left(\mathtt{loop}\right)^{-1}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,\mathtt{refl}_{\mathtt{base}}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{loop}=\mathtt{refl}_{\mathtt{base}} by Lemma 3.13. By function extensionality,

𝚊𝚙λx.μ(x)(𝚋𝚊𝚜𝚎)(𝚕𝚘𝚘𝚙)=𝚑𝚊𝚙𝚙𝚕𝚢(𝚊𝚙μ(𝚕𝚘𝚘𝚙))(𝚋𝚊𝚜𝚎)=p𝚋𝚊𝚜𝚎𝚕𝚘𝚘𝚙.\mathtt{ap}_{\lambda x.\mu(x)(\mathtt{base})}\left(\mathtt{loop}\right)=\mathtt{happly}(\mathtt{ap}_{\mu}\left(\mathtt{loop}\right))\left(\mathtt{base}\right)=p_{\mathtt{base}}\equiv\mathtt{loop}.

Finally, we change μ\mu to its uncurried form. ∎

The next result follows from the 3×33\times 3-lemma [Bru16, Section 1.8].

Lemma 5.20 ([Bru16, Proposition 1.8.8]).

For every m,n:m,n:{\mathbb{N}}, 𝕊m𝕊n𝕊m+n+1{\mathbb{S}}^{m}\ast{\mathbb{S}}^{n}\simeq{\mathbb{S}}^{m+n+1}.

Theorem 5.21.

There is a fibration, called the Hopf fibration, over 𝕊2{\mathbb{S}}^{2} with fibre 𝕊1{\mathbb{S}}^{1} and total space 𝕊3{\mathbb{S}}^{3}.

Proof.

𝕊1{\mathbb{S}}^{1} is 0-connected by Example 4.26. By Lemma 5.19 and Theorem 5.18, there is a fibration over Σ𝕊1𝕊2\Sigma{\mathbb{S}}^{1}\equiv{\mathbb{S}}^{2} with fibre 𝕊1{\mathbb{S}}^{1} and total space 𝕊1𝕊1𝕊3{\mathbb{S}}^{1}\ast{\mathbb{S}}^{1}\simeq{\mathbb{S}}^{3} by Lemma 5.20. ∎

We put all the pieces together by writing the long exact sequence induced by the Hopf fibration:

Corollary 5.22 ([Uni13, Corollary 8.5.2]).

π2(𝕊2)\pi_{2}\left({\mathbb{S}}^{2}\right)\simeq{\mathbb{Z}} and πk(𝕊3)πk(𝕊2)\pi_{k}\left({\mathbb{S}}^{3}\right)\simeq\pi_{k}\left({\mathbb{S}}^{2}\right) for k3k\geq 3.

Proof.

By Corollary 5.3, Theorem 5.12 and Theorem 5.21, we have an exact sequence of groups

\displaystyle\ldots πk(𝕊1)πk(𝕊3)πk(𝕊2)\displaystyle\rightarrow\pi_{k}\left({\mathbb{S}}^{1}\right)\rightarrow\pi_{k}\left({\mathbb{S}}^{3}\right)\rightarrow\pi_{k}\left({\mathbb{S}}^{2}\right)\rightarrow
\displaystyle\ldots π2(𝕊1)π2(𝕊3)π2(𝕊2)\displaystyle\rightarrow\pi_{2}\left({\mathbb{S}}^{1}\right)\rightarrow\pi_{2}\left({\mathbb{S}}^{3}\right)\rightarrow\pi_{2}\left({\mathbb{S}}^{2}\right)
π1(𝕊1)π1(𝕊3)π1(𝕊2).\displaystyle\rightarrow\pi_{1}\left({\mathbb{S}}^{1}\right)\rightarrow\pi_{1}\left({\mathbb{S}}^{3}\right)\rightarrow\pi_{1}\left({\mathbb{S}}^{2}\right).

By Corollary 4.21 and Corollary 4.29, this is reduced to

\displaystyle... 0πk(𝕊3)πk(𝕊2)\displaystyle\to 0\to\pi_{k}(\mathbb{S}^{3})\to\pi_{k}(\mathbb{S}^{2})\to
\displaystyle... 00π2(𝕊2)\displaystyle\to 0\to 0\to\pi_{2}(\mathbb{S}^{2})
00.\displaystyle\to\mathbb{Z}\to 0\to 0.

Applying Lemma 5.13 yields the result. ∎

Chapter 6 Blakers–Massey theorem

In this chapter, we will ‘informalise’ the mechanised Agda proof of the Blakers–Massey theorem in [HFLL16] (or [Hou17, Sections 3.4, 4.3]) by combining [Uni13, Section 8.6]. For this, a generalised version of pushouts is first presented in Section 6.1. Then the theorem is stated, generalised and relaxed in Section 6.2. The proof employs a more sophisticated encode-decode method, where we define 𝚌𝚘𝚍𝚎\mathtt{code} by the wedge connectivity lemma in Section 6.3 and then show the contractibility of 𝚌𝚘𝚍𝚎\mathtt{code} in Section 6.4. Some consequences, including the Freudenthal suspension theorem and stability for spheres, are derived in Section 6.5.

Throughout the chapter, we shall omit proofs on coherence operations too technical for presentation, and write a square \square for an unspecified coherence path.

6.1 Generalised pushouts

Lemma 6.1 ([Uni13, Lemma 4.8.2]).

For any function f:ABf:A\rightarrow B, Ab:B𝚏𝚒𝚋f(b)A\simeq\sum_{b:B}\mathtt{fib}_{f}(b).

Proof.

This result shows that we can interchange function types and families of types, i.e., any function f:ABf:A\rightarrow B is equivalent to the projection 𝚙𝚛1:b:B𝚏𝚒𝚋f(b)B\mathtt{pr}_{1}:\sum_{b:B}\mathtt{fib}_{f}(b)\rightarrow B.

\blacksquare Recall that Section 3.5.2 defines a pushout for the span X𝑓C𝑔YX\overset{f}{\leftarrow}C\overset{g}{\rightarrow}Y. By rewriting the functions as families of types and expanding the definition of fibres, this span is equivalent to

X𝚙𝚛Xx:Xy:Yc:C((g(c)=Yy)×(f(c)=Xx))𝚙𝚛YY.X\overset{\mathtt{pr}_{X}}{\leftarrow}\sum_{x:X}\sum_{y:Y}\sum_{c:C}\left(\left(g(c)=_{Y}y\right)\times\left(f(c)=_{X}x\right)\right)\overset{\mathtt{pr}_{Y}}{\rightarrow}Y.

If we define a dependent type Q:XY𝚃𝚢𝚙𝚎Q:X\rightarrow Y\rightarrow\mathtt{Type}, then this span can be generalised as

X𝚙𝚛Xx:Xy:YQ(x)(y)𝚙𝚛YY.X\overset{\mathtt{pr}_{X}}{\leftarrow}\sum_{x:X}\sum_{y:Y}Q(x)(y)\overset{\mathtt{pr}_{Y}}{\rightarrow}Y.
Definition 6.2.

Let X,Y:𝚃𝚢𝚙𝚎X,Y:\mathtt{Type} and Q:XY𝚃𝚢𝚙𝚎Q:X\rightarrow Y\rightarrow\mathtt{Type}. The (generalised) pushout XQYX\sqcup^{Q}Y is the HIT generated by two point constructors 𝚒𝚗𝚕:XXQY\mathtt{inl}:X\rightarrow X\sqcup^{Q}Y and 𝚒𝚗𝚛:YXQY\mathtt{inr}:Y\rightarrow X\sqcup^{Q}Y and a path constructor

𝚐𝚕𝚞𝚎:(x:X)(y:Y)Q(x)(y)(𝚒𝚗𝚕(x)=XQY𝚒𝚗𝚛(y)),\mathtt{glue}:(x:X)\rightarrow(y:Y)\rightarrow Q(x)(y)\rightarrow\left(\mathtt{inl}(x)=_{X\sqcup^{Q}Y}\mathtt{inr}(y)\right),

as visualised by Figure 6.1.

xxyyqq𝚒𝚗𝚕(x)\mathtt{inl}(x)𝚒𝚗𝚛(y)\mathtt{inr}(y)XXYYQ(x)(y)Q(x)(y)XQYX\sqcup^{Q}Y𝚐𝚕𝚞𝚎x,y(q)\mathtt{glue}_{x,y}(q)𝚒𝚗𝚕\mathtt{inl}𝚒𝚗𝚛\mathtt{inr}𝚐𝚕𝚞𝚎x,y\mathtt{glue}_{x,y}
Figure 6.1: Diagram for the generalised pushout XQYX\sqcup^{Q}Y.
XX and YY are thought of as two ‘axes’ of a ‘coordinate system’, and each pair (x,y):X×Y(x,y):X\times Y corresponds to a type Q(x)(y)Q(x)(y). The two dashed circles represent the ‘image’ of XX and YY under 𝚒𝚗𝚕\mathtt{inl} and 𝚒𝚗𝚛\mathtt{inr}, respectively.

By previous discussions, when Qλx.λy.c:C((g(c)=Yy)×(f(c)=Xx))Q\equiv\lambda x.\lambda y.\sum_{c:C}\left(\left(g(c)=_{Y}y\right)\times\left(f(c)=_{X}x\right)\right), this definition is equivalent to the one in Section 3.5.2. Henceforth, we only use the generalised pushout.

The induction principle states that given

  • a dependent type P:XQY𝚃𝚢𝚙𝚎P:X\sqcup^{Q}Y\rightarrow\mathtt{Type},

  • two dependent functions h𝚒𝚗𝚕:(x:X)P(𝚒𝚗𝚕(x))h_{\mathtt{inl}}:(x:X)\rightarrow P\left(\mathtt{inl}(x)\right) and

  • h𝚒𝚗𝚛:(y:Y)P(𝚒𝚗𝚛(y))h_{\mathtt{inr}}:(y:Y)\rightarrow P\left(\mathtt{inr}(y)\right) and

  • a family of dependent paths

h𝚐𝚕𝚞𝚎:(x:X)(y:Y)(q:Q(x)(y))h𝚒𝚗𝚕(x)=𝚐𝚕𝚞𝚎x,y(q)Ph𝚒𝚗𝚛(y),h_{\mathtt{glue}}:(x:X)\rightarrow(y:Y)\rightarrow\left(q:Q(x)(y)\right)\rightarrow h_{\mathtt{inl}}(x)=_{\mathtt{glue}_{x,y}(q)}^{P}h_{\mathtt{inr}}(y),

there is a dependent function h:(z:XQY)P(z)h:\left(z:X\sqcup^{Q}Y\right)\rightarrow P(z) such that h(𝚒𝚗𝚕(x)):h𝚒𝚗𝚕(x)h\left(\mathtt{inl}(x)\right):\equiv h_{\mathtt{inl}}(x), h(𝚒𝚗𝚛(y)):h𝚒𝚗𝚛(y)h\left(\mathtt{inr}(y)\right):\equiv h_{\mathtt{inr}}(y), and 𝚊𝚙𝚍h(𝚐𝚕𝚞𝚎x,y(q)):=h𝚐𝚕𝚞𝚎(x)(y)(q)\mathtt{apd}_{h}\left(\mathtt{glue}_{x,y}(q)\right):=h_{\mathtt{glue}}(x)(y)(q).

Henceforth, we may omit the first two parameters of 𝚐𝚕𝚞𝚎\mathtt{glue} for conciseness.

6.2 Theorem statement

Theorem 6.3 (Blakers–Massey theorem).

Let X,Y:𝚃𝚢𝚙𝚎X,Y:\mathtt{Type} and Q:XY𝚃𝚢𝚙𝚎Q:X\rightarrow Y\rightarrow\mathtt{Type}. Let m,n1m,n\geq-1. Suppose the type y:YQ(x)(y)\sum_{y:Y}Q(x)(y) is mm-connected for each x:Xx:X, and the type x:XQ(x)(y)\sum_{x:X}Q(x)(y) is nn-connected for each y:Yy:Y. Then for each x:Xx:X and each y:Yy:Y, the map

𝚐𝚕𝚞𝚎x,y:Q(x)(y)(𝚒𝚗𝚕(x)=XQY𝚒𝚗𝚛(y))\mathtt{glue}_{x,y}:Q(x)(y)\rightarrow\left(\mathtt{inl}(x)=_{X\sqcup^{Q}Y}\mathtt{inr}(y)\right)

is (m+n)(m+n)-connected.

Let X,Y,Q,m,nX,Y,Q,m,n be fixed. We also fix xx0x\equiv x_{0}. By the definition of connectedness, the claim is equivalent to

(y:Y)(r:(𝚒𝚗𝚕(x0)=XQY𝚒𝚗𝚛(y)))𝚒𝚜-𝚌𝚘𝚗𝚝𝚛(𝚏𝚒𝚋𝚐𝚕𝚞𝚎(r)m+n).(y:Y)\rightarrow\left(r:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}\mathtt{inr}(y)\right)\right)\rightarrow\mathtt{is\text{-}contr}\left(\left\|\mathtt{fib}_{\mathtt{glue}}(r)\right\|_{m+n}\right).

Similar to Section 4.4, in order to apply path induction on rr, we need to generalise the right-hand side of (𝚒𝚗𝚕(x0)=𝚒𝚗𝚛(y))\left(\mathtt{inl}(x_{0})=\mathtt{inr}(y)\right) to an arbitrary term pp of XQYX\sqcup^{Q}Y. Therefore, we claim the following lemma, which would imply Theorem 6.3 by setting pp to 𝚒𝚗𝚛(y)\mathtt{inr}(y):

Lemma 6.4.

There exists a dependent type

𝚌𝚘𝚍𝚎:(p:XQY)(𝚒𝚗𝚕(x0)=XQYp)𝚃𝚢𝚙𝚎\mathtt{code}:\left(p:X\sqcup^{Q}Y\right)\rightarrow\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right)\rightarrow\mathtt{Type}

such that

  • 𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y))(r)𝚏𝚒𝚋𝚐𝚕𝚞𝚎(r)m+n\mathtt{code}(\mathtt{inr}(y))(r)\equiv\left\|\mathtt{fib}_{\mathtt{glue}}(r)\right\|_{m+n}, and

  • for any p:XQYp:X\sqcup^{Q}Y and any r:(𝚒𝚗𝚕(x0)=XQYp)r:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right), 𝚌𝚘𝚍𝚎(p)(r)\mathtt{code}(p)(r) is contractible.

Additionally, we need the following relaxation:

Lemma 6.5.

To prove Lemma 6.4, we may assume that there exist some fixed y0:Yy_{0}:Y and q00:Q(x0)(y0)q_{00}:Q\left(x_{0}\right)\left(y_{0}\right).

Proof.

By assumption, y:YQ(x0)(y)\sum_{y:Y}Q\left(x_{0}\right)(y) is mm-connected, so y:YQ(x0)(y)m\left\|{\sum_{y:Y}Q\left(x_{0}\right)(y)}\right\|_{m} is contractible and thus inhabited. The proposition that 𝚌𝚘𝚍𝚎(p)(r)\mathtt{code}(p)(r) is contractible is a mere proposition, and thus is a fortiori an mm-type as m1m\geq-1. Thus, by truncation induction, we may assume the inhabitant of y:YQ(x0)(y)m\left\|{\sum_{y:Y}Q\left(x_{0}\right)(y)}\right\|_{m} is of the form |(y0,q00)|m\left|\left(y_{0},q_{00}\right)\right|_{m} for some y0:Yy_{0}:Y and q00:Q(x0)(y0)q_{00}:Q\left(x_{0}\right)\left(y_{0}\right). ∎

In summary, our goal is to prove Lemma 6.4 while assuming some fixed y0:Yy_{0}:Y and q00:Q(x0)(y0)q_{00}:Q\left(x_{0}\right)\left(y_{0}\right). This is broken into the definition of 𝚌𝚘𝚍𝚎\mathtt{code} and its contractibility in the following two sections.

6.3 Definition of 𝚌𝚘𝚍𝚎\mathtt{code}

We begin with the wedge connectivity lemma. For two pointed types AA and BB, there is a canonical map i:ABA×Bi:A\vee B\rightarrow A\times B given by λa.(a,b0)\lambda a.\left(a,b_{0}\right) and λb.(a0,b)\lambda b.\left(a_{0},b\right). By Proposition 4.31 and the induction principle of wedge sums, the next lemma is an equivalent way to state that if AA is nn-connected and BB is mm-connected, then ii is (m+n)(m+n)-connected.

Lemma 6.6 (Wedge connectivity lemma, [Uni13, Lemma 8.6.2]).

Suppose (A,a0)\left(A,a_{0}\right) and (B,b0)\left(B,b_{0}\right) are nn- and mm-connected pointed types, respectively, with n,m1n,m\geq-1111This lemma works for m=1m=-1 or n=1n=-1 although [Uni13, Lemma 3.1.3] requires n,m0n,m\geq 0 [Hou17].. Then given

  • P:AB(n+m)-𝚃𝚢𝚙𝚎P:A\rightarrow B\rightarrow(n+m)\mathtt{\text{-}Type},

  • f:(a:A)P(a)(b0)f:(a:A)\rightarrow P(a)\left(b_{0}\right),

  • g:(b:B)P(a0)(b)g:(b:B)\rightarrow P\left(a_{0}\right)(b) and

  • p:f(a0)=P(a0)(b0)g(b0)p:f\left(a_{0}\right)=_{P\left(a_{0}\right)\left(b_{0}\right)}g\left(b_{0}\right),

there is h:(a:A)(b:B)P(a)(b)h:(a:A)\rightarrow(b:B)\rightarrow P(a)(b) with homotopies q:h()(b0)fq:h(-)\left(b_{0}\right)\sim f and r:h(a0)gr:h\left(a_{0}\right)\sim g such that p=q(a0)1r(b0)p={q\left(a_{0}\right)}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}r\left(b_{0}\right).

In shorter terms, to define the dependent function h:(a:A)(b:B)P(a)(b)h:(a:A)\rightarrow(b:B)\rightarrow P(a)(b), it suffices to consider respectively the cases when bb coincides with b0b_{0} by giving ff and when aa coincides with a0a_{0} by giving gg, and then ensure the consistency when both cases happen simultaneously by giving pp.

The following is an application of the wedge connectivity lemma, used in defining 𝚌𝚘𝚍𝚎\mathtt{code}.

Corollary 6.7.

Let X,Y:𝚃𝚢𝚙𝚎X,Y:\mathtt{Type} and Q:XY𝚃𝚢𝚙𝚎Q:X\rightarrow Y\rightarrow\mathtt{Type}. Let x1:Xx_{1}:X, y0:Yy_{0}:Y and q10:Q(x1)(y0)q_{10}:Q\left(x_{1}\right)\left(y_{0}\right). Define type A:x0:XQ(x0)(y0)A:\equiv\sum_{x_{0}:X}Q\left(x_{0}\right)\left(y_{0}\right) and type B:y1:YQ(x1)(y1)B:\equiv\sum_{y_{1}:Y}Q\left(x_{1}\right)\left(y_{1}\right). Assume that AA is nn-connected and BB is mm-connected. Define C:AB(m+n)-𝚃𝚢𝚙𝚎C:A\rightarrow B\rightarrow(m+n)\mathtt{\text{-}Type} by

λ(x0,q00).λ(y1,q11).𝚏𝚒𝚋𝚐𝚕𝚞𝚎x0,y1(𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1𝚐𝚕𝚞𝚎(q11))m+n,\lambda\left(x_{0},q_{00}\right).\lambda\left(y_{1},q_{11}\right).\left\|{{\mathtt{fib}_{\mathtt{glue}}}_{x_{0},y_{1}}\left(\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{glue}(q_{11})\right)}\right\|_{m+n},

where q00:Q(x0)(y0)q_{00}:Q\left(x_{0}\right)\left(y_{0}\right) and q11:Q(x1)(y1)q_{11}:Q\left(x_{1}\right)\left(y_{1}\right). Then there is a dependent function h:((x0,q00):A)((y1,q11):B)C(x0,q00)(y1,q11)h:\left(\left(x_{0},q_{00}\right):A\right)\rightarrow\left(\left(y_{1},q_{11}\right):B\right)\rightarrow C\left(x_{0},q_{00}\right)\left(y_{1},q_{11}\right).

Proof.

AA is pointed by (x1,q10)\left(x_{1},q_{10}\right) and BB is pointed by (y0,q10)\left(y_{0},q_{10}\right). By Lemma 6.6, to obtain hh, it suffices to consider the following cases:

(1) When (y1,q11)\left(y_{1},q_{11}\right) coincides with (y0,q10)\left(y_{0},q_{10}\right), for each (x0,q00):A\left(x_{0},q_{00}\right):A, we need a term of the type

C(x0,q00)(y0,q10)𝚏𝚒𝚋𝚐𝚕𝚞𝚎(𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1𝚐𝚕𝚞𝚎(q10))m+n,C\left(x_{0},q_{00}\right)\left(y_{0},q_{10}\right)\equiv\left\|{\mathtt{fib}_{\mathtt{glue}}\left(\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{glue}(q_{10})\right)}\right\|_{m+n},

which is inhabited by |(q00,)|m+n\left|\left(q_{00},\square\right)\right|_{m+n}. (Here, \square is the coherence path 𝚐𝚕𝚞𝚎(q00)=𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1𝚐𝚕𝚞𝚎(q10)\mathtt{glue}(q_{00})=\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{glue}(q_{10}).) (2) When (x0,q00)\left(x_{0},q_{00}\right) coincides with (x1,q10)\left(x_{1},q_{10}\right), for each (y1,q11):B\left(y_{1},q_{11}\right):B, we need to a term of the type

C(x1,q10)(y1,q11)𝚏𝚒𝚋𝚐𝚕𝚞𝚎(𝚐𝚕𝚞𝚎(q10)𝚐𝚕𝚞𝚎(q10)1𝚐𝚕𝚞𝚎(q11))m+n,C\left(x_{1},q_{10}\right)\left(y_{1},q_{11}\right)\equiv\left\|{\mathtt{fib}_{\mathtt{glue}}\left(\mathtt{glue}(q_{10})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{glue}(q_{11})\right)}\right\|_{m+n},

which is inhabited by |(q11,)|m+n\left|\left(q_{11},\square\right)\right|_{m+n}.

(3) Choices from (1) and (2) are consistent by coherence operations. ∎

We are now ready to define 𝚌𝚘𝚍𝚎\mathtt{code}.

XQYX\sqcup^{Q}Y𝚒𝚗𝚕(x0)\mathtt{inl}(x_{0})𝚒𝚗𝚕(x1)\mathtt{inl}(x_{1})𝚒𝚗𝚛(y0)\mathtt{inr}(y_{0})𝚒𝚗𝚛(y1)\mathtt{inr}(y_{1})𝚐𝚕𝚞𝚎(q00)\mathtt{glue}(q_{00})𝚐𝚕𝚞𝚎(q10)1\mathtt{glue}(q_{10})^{-1}𝚐𝚕𝚞𝚎(q01)\mathtt{glue}(q_{01})𝚐𝚕𝚞𝚎(q11)\mathtt{glue}(q_{11})rrss
Figure 6.2: Diagram for the definition of 𝚌𝚘𝚍𝚎\mathtt{code}.
Proposition 6.8.

𝚌𝚘𝚍𝚎:(p:XQY)(𝚒𝚗𝚕(x0)=XQYp)𝚃𝚢𝚙𝚎.\mathtt{code}:\left(p:X\sqcup^{Q}Y\right)\rightarrow\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right)\rightarrow\mathtt{Type}.

Proof.

See Figure 6.2. When pp is 𝚒𝚗𝚛(y1)\mathtt{inr}(y_{1}), for r:(𝚒𝚗𝚕(x0)=XQY𝚒𝚗𝚛(y1))r:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}\mathtt{inr}(y_{1})\right), as mentioned earlier,

𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))(r):q01:Q(x0)(y1)𝚐𝚕𝚞𝚎(q01)=rm+n.\mathtt{code}(\mathtt{inr}(y_{1}))(r):\equiv\left\|{\sum_{q_{01}:Q\left(x_{0}\right)\left(y_{1}\right)}\mathtt{glue}(q_{01})=r}\right\|_{m+n}.

When pp is 𝚒𝚗𝚕(x1)\mathtt{inl}(x_{1}), for s:(𝚒𝚗𝚕(x0)=XQY𝚒𝚗𝚕(x1))s:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}\mathtt{inl}(x_{1})\right),

𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))(s):q10:Q(x1)(y0)𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1=sm+n.\mathtt{code}(\mathtt{inl}(x_{1}))(s):\equiv\left\|{\sum_{q_{10}:Q\left(x_{1}\right)\left(y_{0}\right)}\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}=s}\right\|_{m+n}.

\blacksquare When pp ‘varies along’ 𝚐𝚕𝚞𝚎(q11):𝚒𝚗𝚕(x1)=𝚒𝚗𝚛(y1)\mathtt{glue}(q_{11}):\mathtt{inl}(x_{1})=\mathtt{inr}(y_{1}), we need to find a path

𝚊𝚙𝚍𝚌𝚘𝚍𝚎(𝚐𝚕𝚞𝚎(q11)):𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))=𝚐𝚕𝚞𝚎(q11)𝚌𝚘𝚍𝚎𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))\mathtt{apd}_{\mathtt{code}}\left(\mathtt{glue}(q_{11})\right):\mathtt{code}(\mathtt{inl}(x_{1}))=_{\mathtt{glue}(q_{11})}^{\mathtt{code}}\mathtt{code}(\mathtt{inr}(y_{1}))

By function extensionality, it suffices to find for every r:(𝚒𝚗𝚕(x0)=𝚒𝚗𝚛(y1))r:\left(\mathtt{inl}(x_{0})=\mathtt{inr}(y_{1})\right), a path

𝚐𝚕𝚞𝚎(q11)(𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1)))(r)=𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))(r).{\mathtt{glue}(q_{11})}_{\ast}\left(\mathtt{code}(\mathtt{inl}(x_{1}))\right)(r)=\mathtt{code}(\mathtt{inr}(y_{1}))(r).

Starting from the left-hand side, we have a path

𝚐𝚕𝚞𝚎(q11)(𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1)))(r)\displaystyle{\mathtt{glue}(q_{11})}_{\ast}\left(\mathtt{code}(\mathtt{inl}(x_{1}))\right)(r) =𝚐𝚕𝚞𝚎(q11)(𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))(𝚐𝚕𝚞𝚎(q11)1(r)))\displaystyle={\mathtt{glue}(q_{11})}_{\ast}\left(\mathtt{code}(\mathtt{inl}(x_{1}))({\mathtt{glue}(q_{11})}_{\ast}^{-1}(r))\right)
=𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))(r𝚐𝚕𝚞𝚎(q11)1),\displaystyle=\mathtt{code}(\mathtt{inl}(x_{1}))(r\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{11})}^{-1}),

where the first equality is by Lemma 3.14 and the second by Lemma 3.11 and Lemma 3.15. Therefore, by univalence, it remains to find a function

Φ:𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))(r𝚐𝚕𝚞𝚎(q11)1)𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))(r),\Phi:\mathtt{code}(\mathtt{inl}(x_{1}))(r\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{11})}^{-1})\rightarrow\mathtt{code}(\mathtt{inr}(y_{1}))(r), (6.1)

and show that Φ\Phi is an equivalence. By the definition of 𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))\mathtt{code}(\mathtt{inl}(x_{1})) and 𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))\mathtt{code}(\mathtt{inr}(y_{1})) and truncation induction, it suffices to find for each q01:Q(x1)(y0)q_{01}:Q\left(x_{1}\right)\left(y_{0}\right) with 𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1=r𝚐𝚕𝚞𝚎(q11)1\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}=r\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,{\mathtt{glue}(q_{11})}^{-1}, a term of q01:Q(x0)(y1)𝚐𝚕𝚞𝚎(q01)=rm+n\left\|{\sum_{q_{01}:Q\left(x_{0}\right)\left(y_{1}\right)}\mathtt{glue}(q_{01})=r}\right\|_{m+n}. By coherence operations, we then eliminate rr, and it suffices to find for each q10:Q(x1)(y0)q_{10}:Q\left(x_{1}\right)\left(y_{0}\right), a term of

q01:Q(x0)(y1)𝚐𝚕𝚞𝚎(q01)=𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1𝚐𝚕𝚞𝚎(q11)m+n.\left\|{\sum_{q_{01}:Q\left(x_{0}\right)\left(y_{1}\right)}\mathtt{glue}(q_{01})=\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\mathtt{glue}(q_{11})}\right\|_{m+n}.

We now invoke Corollary 6.7 (by using which the order of the variables is effectively rearranged), and the desired term is given by h(x0,q00)(y1,q11)h\left(x_{0},q_{00}\right)\left(y_{1},q_{11}\right). We can similarly define the function on the other direction and show that the two functions are quasi-inverses, but the details are omitted. ∎

6.4 Contractibility of 𝚌𝚘𝚍𝚎\mathtt{code}

We now show that for any p:XQYp:X\sqcup^{Q}Y and any r:(𝚒𝚗𝚕(x0)=XQYp)r:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right), 𝚌𝚘𝚍𝚎(p)(r)\mathtt{code}(p)(r) is contractible, by first giving its centre of contraction.

Proposition 6.9.

𝚌𝚎𝚗𝚝𝚛𝚎:(p:XQY)(r:(𝚒𝚗𝚕(x0)=XQYp))𝚌𝚘𝚍𝚎(p)(r).\mathtt{centre}:\left(p:X\sqcup^{Q}Y\right)\rightarrow\left(r:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right)\right)\rightarrow\mathtt{code}(p)(r).

Proof.

By path induction, it suffices to assume p𝚒𝚗𝚕(x0)p\equiv\mathtt{inl}(x_{0}) and r𝚛𝚎𝚏𝚕𝚒𝚗𝚕(x0)r\equiv\mathtt{refl}_{\mathtt{inl}(x_{0})}. Then

𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x0))(𝚛𝚎𝚏𝚕𝚒𝚗𝚕(x0))q:Q(x0)(y0)𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q)1=𝚛𝚎𝚏𝚕𝚒𝚗𝚕(x0)m+n,\mathtt{code}(\mathtt{inl}(x_{0}))(\mathtt{refl}_{\mathtt{inl}(x_{0})})\equiv\left\|{\sum_{q:Q\left(x_{0}\right)\left(y_{0}\right)}\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q)}^{-1}=\mathtt{refl}_{\mathtt{inl}(x_{0})}}\right\|_{m+n},

which is inhabited by |(q00,)|m+n\left|\left(q_{00},\square\right)\right|_{m+n}. Then 𝚌𝚎𝚗𝚝𝚛𝚎\mathtt{centre} is explicitly given by

𝚌𝚎𝚗𝚝𝚛𝚎(p)(r):𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝𝚌𝚘𝚍𝚎^(𝚙𝚊𝚒𝚛=(r,t))(|(q00,)|m+n)\mathtt{centre}(p)(r):\equiv\mathtt{transport}^{\hat{\mathtt{code}}}\left(\mathtt{pair}^{=}(r,t)\right)\left(\left|\left(q_{00},\square\right)\right|_{m+n}\right)

by Corollary 4.6, where t:r(𝚛𝚎𝚏𝚕x0)=rt:r_{\ast}\left(\mathtt{refl}_{x_{0}}\right)=r by Lemma 3.15 and

𝚌𝚘𝚍𝚎^:p:XQY(𝚒𝚗𝚕(x0)=XQYp)𝚃𝚢𝚙𝚎\hat{\mathtt{code}}:\sum_{p:X\sqcup^{Q}Y}\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right)\rightarrow\mathtt{Type}

is the uncurried form of 𝚌𝚘𝚍𝚎\mathtt{code}. ∎

Before we proceed, the next lemma allows us to extract some valuable information from the hard-earned definition of 𝚌𝚘𝚍𝚎\mathtt{code} for calculating a certain 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝\mathtt{transport} function.

Lemma 6.10 ([Uni13, Lemma 8.6.10]).

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type}, B:A𝚃𝚢𝚙𝚎B:A\rightarrow\mathtt{Type}, C:(a:A)B(a)𝚃𝚢𝚙𝚎C:(a:A)\rightarrow B(a)\rightarrow\mathtt{Type}, a1,a2:Aa_{1},a_{2}:A, m:a1=Aa2m:a_{1}=_{A}a_{2}, and b2:B(a2)b_{2}:B\left(a_{2}\right). Denote b1:m1(b2):B(a1)b_{1}:\equiv m_{\ast}^{-1}\left(b_{2}\right):B\left(a_{1}\right). Also denote the uncurried form of CC as C^:a:AB(a)𝚃𝚢𝚙𝚎\hat{C}:\sum_{a:A}B(a)\rightarrow\mathtt{Type}. Then the function

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝C^(𝚙𝚊𝚒𝚛=(m,t)):C(a1)(b1)C(a2)(b2),\mathtt{transport}^{\hat{C}}\left(\mathtt{pair}^{=}(m,t)\right):C\left(a_{1}\right)\left(b_{1}\right)\rightarrow C\left(a_{2}\right)\left(b_{2}\right),

where t:m(b1)=B(a2)b2t:m_{\ast}\left(b_{1}\right)=_{B\left(a_{2}\right)}b_{2} is an obvious path, is equal to the equivalence obtained by applying 𝚒𝚍𝚝𝚘𝚎𝚚𝚟\mathtt{idtoeqv} to the composite of paths

C(a1)(b1)=m(C(a1)(m1(b2)))=m(C(a1))(b2)=C(a2)(b2),C\left(a_{1}\right)\left(b_{1}\right)=m_{\ast}\left(C\left(a_{1}\right)\left(m_{\ast}^{-1}\left(b_{2}\right)\right)\right)=m_{\ast}\left(C\left(a_{1}\right)\right)\left(b_{2}\right)=C\left(a_{2}\right)\left(b_{2}\right),

where the first equality is by definition and by Lemma 3.11, the second is by Lemma 3.14, and the third is by 𝚑𝚊𝚙𝚙𝚕𝚢(𝚊𝚙𝚍C(m))(b2)\mathtt{happly}(\mathtt{apd}_{C}(m))\left(b_{2}\right).

a1a_{1}a2a_{2}m1(b2){\color[rgb]{0,0.453125,0.8515625}\definecolor[named]{pgfstrokecolor}{rgb}{0,0.453125,0.8515625}m_{*}^{-1}}(b_{2})b2b_{2}mmmm_{*}C(a1)C(a_{1})C(a2)C(a_{2})m(C(a1)){\color[rgb]{0.8046875,0.359375,0.359375}\definecolor[named]{pgfstrokecolor}{rgb}{0.8046875,0.359375,0.359375}m_{*}}(C(a_{1}))mm_{*}AAB(a1)B(a_{1})B(a2)B(a_{2})𝚃𝚢𝚙𝚎\mathtt{Type}C(a1)(m1(b2))C(a_{1})({\color[rgb]{0,0.453125,0.8515625}\definecolor[named]{pgfstrokecolor}{rgb}{0,0.453125,0.8515625}m_{*}^{-1}}(b_{2}))m(C(a1)(m1(b2))){\color[rgb]{0.234375,0.703125,0.44140625}\definecolor[named]{pgfstrokecolor}{rgb}{0.234375,0.703125,0.44140625}m_{*}}(C(a_{1})({\color[rgb]{0,0.453125,0.8515625}\definecolor[named]{pgfstrokecolor}{rgb}{0,0.453125,0.8515625}m_{*}^{-1}}(b_{2})))m(C(a1))(b2){\color[rgb]{0.8046875,0.359375,0.359375}\definecolor[named]{pgfstrokecolor}{rgb}{0.8046875,0.359375,0.359375}m_{*}}(C(a_{1}))(b_{2})C(a2)(b2)C(a_{2})(b_{2})
Figure 6.3: Diagram for Lemma 6.10.
The blue mm_{\ast} represents 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝B(m)\mathtt{transport}^{B}(m), the green mm_{\ast} represents 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝λa.𝚃𝚢𝚙𝚎(m)\mathtt{transport}^{\lambda a.\mathtt{Type}}(m) and the red mm_{\ast} represents 𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝C(m)\mathtt{transport}^{C}(m). The arrow between m(C(a1))m_{\ast}\left(C\left(a_{1}\right)\right) and C(a2)C\left(a_{2}\right) represents the dependent path 𝚊𝚙𝚍C(m)\mathtt{apd}_{C}(m).

\blacksquare We apply Lemma 6.10 with AXQYA\equiv X\sqcup^{Q}Y, B(p:A)(𝚒𝚗𝚕(x0)=p)B\equiv(p:A)\rightarrow\left(\mathtt{inl}(x_{0})=p\right), C𝚌𝚘𝚍𝚎C\equiv\mathtt{code}, a1𝚒𝚗𝚕(x1)a_{1}\equiv\mathtt{inl}(x_{1}), a2𝚒𝚗𝚛(y1)a_{2}\equiv\mathtt{inr}(y_{1}), m𝚐𝚕𝚞𝚎(q11)m\equiv\mathtt{glue}(q_{11}), and b2𝚐𝚕𝚞𝚎(q01)b_{2}\equiv\mathtt{glue}(q_{01}). Then b1m1(b2)=𝚐𝚕𝚞𝚎(q01)𝚐𝚕𝚞𝚎(q11)1b_{1}\equiv m_{\ast}^{-1}\left(b_{2}\right)=\mathtt{glue}(q_{01})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{11})}^{-1} by Lemma 3.15. Then Lemma 6.10 says that to calculate the function

T:𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝𝚌𝚘𝚍𝚎^(𝚙𝚊𝚒𝚛=(𝚐𝚕𝚞𝚎(q11),t)):𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))(b1)𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))(b2),T:\equiv\mathtt{transport}^{\hat{\mathtt{code}}}\left(\mathtt{pair}^{=}(\mathtt{glue}(q_{11}),t)\right):\mathtt{code}(\mathtt{inl}(x_{1}))(b_{1})\rightarrow\mathtt{code}(\mathtt{inr}(y_{1}))(b_{2}),

the major work lies in recovering our definition of 𝚊𝚙𝚍𝚌𝚘𝚍𝚎(𝚐𝚕𝚞𝚎(q11))\mathtt{apd}_{\mathtt{code}}\left(\mathtt{glue}(q_{11})\right), which is a part of the definition of 𝚌𝚘𝚍𝚎\mathtt{code}. Noticing that the type of TT matches the type of Φ\Phi (Function 6.1), to calculate TT, we can utilise our definition of Φ\Phi, with rr replaced with b2𝚐𝚕𝚞𝚎(q01)b_{2}\equiv\mathtt{glue}(q_{01}). The definition of Φ\Phi relies on Corollary 6.7 and we know explicitly the output under the two special cases in the proof of Corollary 6.7. In particular, suppose that (x0,q00)\left(x_{0},q_{00}\right) coincides with (x1,q10)\left(x_{1},q_{10}\right) and further q01q_{01} coincides with q11q_{11}. By case (2) in the proof of Corollary 6.7 and the full statement of Lemma 6.6, hh gives the term |(q01,)|m+n\left|\left(q_{01},\square\right)\right|_{m+n} (up to a path), and thus so does Φ\Phi and TT.

Finally, we show that each 𝚌𝚘𝚍𝚎(p)(r)\mathtt{code}(p)(r) is contractible, written as:

Proposition 6.11.

(p:XQY)(r:(𝚒𝚗𝚕(x0)=XQYp))(c:𝚌𝚘𝚍𝚎(p)(r))(𝚌𝚎𝚗𝚝𝚛𝚎(p)(r)=c).\left(p:X\sqcup^{Q}Y\right)\rightarrow\left(r:\left(\mathtt{inl}(x_{0})=_{X\sqcup^{Q}Y}p\right)\right)\rightarrow\left(c:\mathtt{code}(p)(r)\right)\rightarrow\left(\mathtt{centre}(p)(r)=c\right).

Remark 6.12.

\blacksquare It is tempting to assume by path induction that pp is 𝚒𝚗𝚕(x0)\mathtt{inl}(x_{0}) and rr is 𝚛𝚎𝚏𝚕𝚒𝚗𝚕(x0)\mathtt{refl}_{\mathtt{inl}(x_{0})}. The desired path is in 𝚌𝚘𝚍𝚎(p)(r)\mathtt{code}(p)(r) and thus is an (m+n1)(m+n-1)-type (and a fortiori an (m+n)(m+n)-type), so by truncation induction, we assume that cc is |(q,1)|m+n\left|\left(q,\ell_{1}\right)\right|_{m+n}, where q:Q(x0)(y0)q:Q\left(x_{0}\right)\left(y_{0}\right) and 1:𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q)1=𝚛𝚎𝚏𝚕𝚒𝚗𝚕(x0)\ell_{1}:\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q)}^{-1}=\mathtt{refl}_{\mathtt{inl}(x_{0})}. By the definition of 𝚌𝚎𝚗𝚝𝚛𝚎\mathtt{centre}, we need a path |(q00,)|m+n=|(q,1)|m+n.\left|\left(q_{00},\square\right)\right|_{m+n}=\left|\left(q,\ell_{1}\right)\right|_{m+n}. Now we can only attempt to prove q00=qq_{00}=q, which is unattainable, as 1\ell_{1} only indicates 𝚐𝚕𝚞𝚎(q00)=𝚐𝚕𝚞𝚎(q)\mathtt{glue}(q_{00})=\mathtt{glue}(q).

Proof.

By Corollary 4.4, it suffices to assume that pp is 𝚒𝚗𝚛(y0)\mathtt{inr}(y_{0}) and rr is 𝚐𝚕𝚞𝚎(q00)\mathtt{glue}(q_{00}). We need a re-generalisation for the yy‘s and claim the following:

(y1:Y)(r:𝚒𝚗𝚕(x0)=𝚒𝚗𝚛(y1))(c:𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))(r))(𝚌𝚎𝚗𝚝𝚛𝚎(𝚒𝚗𝚛(y1))(r)=c).\left(y_{1}:Y\right)\rightarrow\left(r:\mathtt{inl}(x_{0})=\mathtt{inr}(y_{1})\right)\rightarrow\left(c:\mathtt{code}(\mathtt{inr}(y_{1}))(r)\right)\rightarrow\left(\mathtt{centre}(\mathtt{inr}(y_{1}))(r)=c\right).

By truncation induction, it suffices to assume cc is |(q01,2)|m+n\left|\left(q_{01},\ell_{2}\right)\right|_{m+n} for some q01:Q(x0)(y1)q_{01}:Q\left(x_{0}\right)\left(y_{1}\right) and 2:𝚐𝚕𝚞𝚎(q01)=r\ell_{2}:\mathtt{glue}(q_{01})=r. Noticing that since rr is a free point in the type 𝚒𝚗𝚕(x0)=𝚒𝚗𝚛(y1)\mathtt{inl}(x_{0})=\mathtt{inr}(y_{1}), we use path induction on 2\ell_{2} to assume that rr is 𝚐𝚕𝚞𝚎(q01)\mathtt{glue}(q_{01}) and 2\ell_{2} is 𝚛𝚎𝚏𝚕𝚐𝚕𝚞𝚎(q01)\mathtt{refl}_{\mathtt{glue}(q_{01})}. It then remains to show that, for any y1:Yy_{1}:Y and any q01:Q(x0)(y1)q_{01}:Q\left(x_{0}\right)\left(y_{1}\right), we have

𝚌𝚎𝚗𝚝𝚛𝚎(𝚒𝚗𝚛(y1))(𝚐𝚕𝚞𝚎(q01))=|(q01,𝚛𝚎𝚏𝚕𝚐𝚕𝚞𝚎(q01))|m+n.\mathtt{centre}(\mathtt{inr}(y_{1}))(\mathtt{glue}(q_{01}))=\left|\left(q_{01},\mathtt{refl}_{\mathtt{glue}(q_{01})}\right)\right|_{m+n}.

By the definition of 𝚌𝚎𝚗𝚝𝚛𝚎\mathtt{centre}, the left-hand side is

𝚝𝚛𝚊𝚗𝚜𝚙𝚘𝚛𝚝𝚌𝚘𝚍𝚎^(𝚙𝚊𝚒𝚛=(𝚐𝚕𝚞𝚎(q01),t))(|(q00,)|m+n).\mathtt{transport}^{\hat{\mathtt{code}}}\left(\mathtt{pair}^{=}(\mathtt{glue}(q_{01}),t)\right)\left(\left|\left(q_{00},\square\right)\right|_{m+n}\right).

This is precisely the case we discussed after Lemma 6.10 (since now x0x_{0}, q00q_{00} and q01q_{01} coincide with x1x_{1}, q10q_{10}, q11q_{11}), thus it is indeed equal to |(q01,)|m+n\left|\left(q_{01},\square\right)\right|_{m+n}. ∎

We have hence completed the proof of Lemma 6.4 and thus Theorem 6.3.

6.5 Consequences

The contractibility of 𝚌𝚘𝚍𝚎\mathtt{code} in fact implies more than Theorem 6.3, which only uses the case 𝚌𝚘𝚍𝚎(𝚒𝚗𝚛(y1))\mathtt{code}(\mathtt{inr}(y_{1})). Our definition for the other case, 𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))\mathtt{code}(\mathtt{inl}(x_{1})), immediately implies the following:

Proposition 6.13.

\blacksquare Assume the same as in Theorem 6.3. Also let x0:Xx_{0}:X, y0:Yy_{0}:Y and q00:Q(x0)(y0)q_{00}:Q\left(x_{0}\right)\left(y_{0}\right). Then for any x1:Xx_{1}:X, the map

τ:λq10.𝚐𝚕𝚞𝚎(q00)𝚐𝚕𝚞𝚎(q10)1:Q(x1)(y0)(𝚒𝚗𝚕(x0)=𝚒𝚗𝚕(x1))\tau:\lambda q_{10}.\mathtt{glue}(q_{00})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{glue}(q_{10})}^{-1}:Q\left(x_{1}\right)\left(y_{0}\right)\rightarrow\left(\mathtt{inl}(x_{0})=\mathtt{inl}(x_{1})\right)

is (m+n)(m+n)-connected.

Proof.

For any s:(𝚒𝚗𝚕(x0)=𝚒𝚗𝚕(x1))s:\left(\mathtt{inl}(x_{0})=\mathtt{inl}(x_{1})\right), 𝚏𝚒𝚋τ(s)m+n\left\|{\mathtt{fib}_{\tau}(s)}\right\|_{m+n} matches our definition for 𝚌𝚘𝚍𝚎(𝚒𝚗𝚕(x1))(s)\mathtt{code}(\mathtt{inl}(x_{1}))(s), which is contractible by 6.11. ∎

Curiously, it is this dual case, instead of Theorem 6.3, that directly gives rise to the Freudenthal suspension theorem as below.

Theorem 6.14 (Freudenthal suspension theorem).

Let CC be an nn-connected type with n1n\geq-1 and x0:Cx_{0}:C. Then the map σ:CΩ(ΣC)\sigma:C\rightarrow\Omega(\Sigma C), given by σ:λx.𝚖𝚎𝚛𝚒𝚍(x)𝚖𝚎𝚛𝚒𝚍(x0)1\sigma:\equiv\lambda x.\mathtt{merid}(x)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{merid}(x_{0})}^{-1}, is 2n2n-connected.

Proof.

\blacksquare We rewrite the suspension using the generalised pushout. The suspension ΣC\Sigma C is the pushout of the diagram 𝟙N𝑓C𝑔𝟙S\mathbb{1}_{N}\overset{f}{\leftarrow}C\overset{g}{\rightarrow}\mathbb{1}_{S}, so X𝟙NX\equiv\mathbb{1}_{N}, Y𝟙SY\equiv\mathbb{1}_{S} and f,gf,g are two trivial maps. Then in this case, Q(N)(S)Q\left(\star_{N}\right)\left(\star_{S}\right) is equivalent to CC and under this equivalence the map 𝚐𝚕𝚞𝚎NS\mathtt{glue}_{NS} is identified with 𝚖𝚎𝚛𝚒𝚍\mathtt{merid}. The connectivity assumptions are easily seen to be satisfied, so by Proposition 6.13, the map σ:λx.𝚖𝚎𝚛𝚒𝚍(x0)𝚖𝚎𝚛𝚒𝚍(x)1:CΩ(ΣC)\sigma^{\prime}:\equiv\lambda x.\mathtt{merid}(x_{0})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{merid}(x)}^{-1}:C\rightarrow\Omega(\Sigma C) is 2n2n-connected. Hence, for any s:Ω(ΣC)s:\Omega(\Sigma C), the fibre 𝚏𝚒𝚋σ(s)\mathtt{fib}_{\sigma^{\prime}}(s) is 2n2n-connected. Notice that by the definition of fibres and coherence operations,

𝚏𝚒𝚋σ(s1)\displaystyle\mathtt{fib}_{\sigma^{\prime}}\left(s^{-1}\right) x:C(𝚖𝚎𝚛𝚒𝚍(x0)𝚖𝚎𝚛𝚒𝚍(x)1=s1)\displaystyle\equiv\sum_{x:C}\left(\mathtt{merid}(x_{0})\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{merid}(x)}^{-1}=s^{-1}\right)
x:C(𝚖𝚎𝚛𝚒𝚍(x)𝚖𝚎𝚛𝚒𝚍(x0)1=s)𝚏𝚒𝚋σ(s),\displaystyle\simeq\sum_{x:C}\left(\mathtt{merid}(x)\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}{\mathtt{merid}(x_{0})}^{-1}=s\right)\equiv\mathtt{fib}_{\sigma}(s),

so σ\sigma is also 2n2n-connected. ∎

Corollary 6.15 (Freudenthal equivalence, [Uni13, Corollary 8.6.14]).

Suppose that type XX is nn-connected and pointed with n1n\geq-1. Then X2nΩ(ΣX)2n\left\|X\right\|_{2n}\simeq\left\|{\Omega(\Sigma X)}\right\|_{2n}.

Proof.

We can now complete Table 1.1 as promised.

Corollary 6.16 (Stability for spheres).

If k2n2k\leq 2n-2, then πk+1(𝕊n+1)πk(𝕊n)\pi_{k+1}\left({\mathbb{S}}^{n+1}\right)\simeq\pi_{k}\left({\mathbb{S}}^{n}\right).

Proof.

By Example 4.26, 𝕊n{\mathbb{S}}^{n} is (n1)(n-1)-connected. By Corollary 6.15 and by the definition of nn-spheres, 𝕊n2(n1)Ω(Σ𝕊n)2(n1)Ω(𝕊n+1)2(n1)\left\|{\mathbb{S}}^{n}\right\|_{2(n-1)}\simeq\left\|{\Omega(\Sigma{\mathbb{S}}^{n})}\right\|_{2(n-1)}\equiv\left\|{\Omega({\mathbb{S}}^{n+1})}\right\|_{2(n-1)}. Since k2(n1)k\leq 2(n-1), by Lemma 4.14, 𝕊nkΩ(𝕊n+1)k\left\|{\mathbb{S}}^{n}\right\|_{k}\simeq\left\|{\Omega({\mathbb{S}}^{n+1})}\right\|_{k}. We then calculate

πk+1(𝕊n+1)\displaystyle\pi_{k+1}\left({\mathbb{S}}^{n+1}\right) Ωk+1(𝕊n+1)0Ωk(Ω(𝕊n+1))0\displaystyle\equiv\left\|{\Omega^{k+1}\left({\mathbb{S}}^{n+1}\right)}\right\|_{0}\equiv\left\|{\Omega^{k}\left(\Omega\left({\mathbb{S}}^{n+1}\right)\right)}\right\|_{0}
ΩkΩ(𝕊n+1)kΩk𝕊nkΩk(𝕊n)0πk(𝕊n),\displaystyle\simeq\Omega^{k}\left\|{\Omega\left({\mathbb{S}}^{n+1}\right)}\right\|_{k}\simeq\Omega^{k}\left\|{\mathbb{S}}^{n}\right\|_{k}\simeq\left\|{\Omega^{k}\left({\mathbb{S}}^{n}\right)}\right\|_{0}\equiv\pi_{k}\left({\mathbb{S}}^{n}\right),

where we use Proposition 4.13 twice to exchange truncation and Ω\Omega. ∎

Corollary 6.17.

πn(𝕊n)\pi_{n}\left({\mathbb{S}}^{n}\right)\simeq{\mathbb{Z}} for n1n\geq 1.

Proof.

π1(𝕊1)\pi_{1}\left({\mathbb{S}}^{1}\right)\simeq{\mathbb{Z}} by Corollary 4.21 and π2(𝕊2)\pi_{2}\left({\mathbb{S}}^{2}\right)\simeq{\mathbb{Z}} by Corollary 5.22. When n2n\geq 2, n2(n1)n\leq 2(n-1), so by induction on nn and Corollary 6.16, the result follows. ∎

Corollary 6.18.

π3(𝕊2)\pi_{3}\left({\mathbb{S}}^{2}\right)\simeq{\mathbb{Z}}.

Proof.

π3(𝕊2)π3(𝕊3)\pi_{3}\left({\mathbb{S}}^{2}\right)\simeq\pi_{3}\left({\mathbb{S}}^{3}\right)\simeq{\mathbb{Z}} by Corollary 5.22 and Corollary 6.17. ∎

Chapter 7 Conclusion and Further Discussions

Table 7.1: Main results and their locations in this dissertation.
Result Location(s)
Homotopy groups of nn-spheres in Table 1.1 Corollaries 4.21, 4.29, 5.22, 6.17, 6.18
Fibre sequence of a pointed map Corollary 5.8
Long exact sequence of a pointed map Theorem 5.12
Hopf construction Theorem 5.18
Hopf fibration Theorem 5.21
Blakers–Massey theorem Theorem 6.3
Freudenthal suspension theorem Theorem 6.14
Stability for spheres Corollary 6.16

The main results in this dissertation are listed in Table 7.1. We briefly evaluate our synthetic approach to homotopy theory:

  • Formal abstraction allows us to focus on the homotopy properties without considering the underlying set-theoretic structures. For example, unlike in classical topology, the universal cover of 𝕊1{\mathbb{S}}^{1} (see Lemma 4.20) does not involve real numbers \mathbb{R} (a helix projecting onto the circle [Hat02, Theorem 1.7]) but only a fibration with fibre \mathbb{Z}, a primitive notion expressed by a dependent type.

  • All notions are homotopy-invariant. For example, our formation of the Blakers–Massey theorem Theorem 6.3 replaces set intersection and union in classical text [Hat02, Theorem 4.23] with pushouts, leading to a more general statement.

  • Proof relevance has enabled us to effectively reuse pieces of previous results, such as the application of Lemma 6.10 in Section 6.4.

  • The rule-based nature of type theory has rendered many proofs routine applications of induction principles and existing lemmas. Whilst this allows for mechanised reasoning, occasionally proofs lack geometric intuition and appear overly technical. Nevertheless, there are methods, such as [Uni13, Section 8.1.5] for πk(𝕊1\pi_{k}({\mathbb{S}}^{1}) and [HFLL16, Section 4] for the Blakers–Massey theorem, that offer easier homotopy-theoretic interpretations.

These further topics are related to our work:

  • The proof of the Blakers–Massey theorem [HFLL16] has inspired a ‘reverse engineered’ classical proof [Rez15] and a generalised version valid in an arbitrary higher topos and with respect to an arbitrary modality [ABFJ20].

  • The Blakers–Massey theorem is used in proving that there is a natural number nn such that π4(𝕊3)/n\pi_{4}\left({\mathbb{S}}^{3}\right)\simeq{\mathbb{Z}}/n{\mathbb{Z}} [Bru16, Proposition 3.4.4].

  • There is a fibration over 𝕊4{\mathbb{S}}^{4} with fibre 𝕊3{\mathbb{S}}^{3} and total space 𝕊7{\mathbb{S}}^{7} by giving an H-space structure on 𝕊3{\mathbb{S}}^{3} [BR16, Theorem 4.10]. In particular, π7(𝕊4)\pi_{7}\left({\mathbb{S}}^{4}\right) has an element of infinite order [BR16, Corollary 4.11].

We also state some speculations based on current work:

  • Chapter 6 has left the proofs on coherence operations unattended. As remarked by [Bru16, p. 23], in general, these proofs can be done via recursive application of path inductions. Here we speculate that there may be automated methods or some ‘meta-theorem’ that reduce the need to spell out these proofs.

  • Our diagrams, combined with the topological interpretations of HoTT, suggest the potential for a systematic approach to HoTT-based graphical reasoning. For example, proof assistants may be equipped with a graphical interface, where the application of rules is visualised through shape transformations. This could potentially offer more intuition and simplify mechanised reasoning.

Appendix A The ‘hub and spoke’ construction of nn-truncations

Definition A.1.

Let A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and n1n\geq-1. Define An\left\|A\right\|_{n}, the nn-truncation of AA, as the higher inductive type generated by two point constructors ||n:AAn|-|_{n}:A\rightarrow\left\|A\right\|_{n} and h:(𝕊n+1An)Anh:\left({\mathbb{S}}^{n+1}\rightarrow\left\|A\right\|_{n}\right)\rightarrow\left\|A\right\|_{n} and a path constructor

s:(r:(𝕊n+1An))(x:𝕊n+1)(r(x)=Anh(r)).s:\left(r:\left({\mathbb{S}}^{n+1}\rightarrow\left\|A\right\|_{n}\right)\right)\rightarrow\left(x:{\mathbb{S}}^{n+1}\right)\rightarrow\left(r(x)=_{\left\|A\right\|_{n}}h(r)\right).

The rationale behind hh and ss (‘hub and spoke’) in this definition will be clear in the following proof, visualised by Figure A.1.

𝕊n+1\mathbb{S}^{n+1}An\left\|A\right\|_{n}𝚋𝚊𝚜𝚎\mathtt{base}xxr(𝚋𝚊𝚜𝚎)r(\mathtt{base})r(x)r(x)bbh(r)h(r)s(r)(x)s(r)(x)s(r)(𝚋𝚊𝚜𝚎)s(r)(\mathtt{base})rr_{*}rr
Figure A.1: Diagram for Lemma A.2.
nn is thought of as 0 and the dashed circle represents the ‘image’ of 𝕊n+1{\mathbb{S}}^{n+1} under rr.
Lemma A.2 ([Uni13, Lemma 7.3.1]).

For any A:𝚃𝚢𝚙𝚎A:\mathtt{Type} and n1n\geq-1, An\left\|A\right\|_{n} is an nn-type.

Proof.

Take any b:Anb:\left\|A\right\|_{n} and let An\left\|A\right\|_{n} be pointed by bb. By Theorem 4.8, it suffices to prove that Ωn+1An\Omega^{n+1}\left\|A\right\|_{n} is contractible. By a corollary of the ‘suspension-loop adjunction’ [Uni13, Lemma 6.5.4], it then suffices to prove that the type M:𝙼𝚊𝚙(𝕊n+1,An)M:\equiv\mathtt{Map}_{\star}\left({\mathbb{S}}^{n+1},\left\|A\right\|_{n}\right) is contractible. The constant function cb:λx.bc_{b}:\equiv\lambda x.b is a pointed map of type MM witnessed by 𝚛𝚎𝚏𝚕b\mathtt{refl}_{b}, and we claim it to be the centre of contraction, i.e., for any pointed function r:𝕊n+1Anr:{\mathbb{S}}^{n+1}\rightarrow_{\star}\left\|A\right\|_{n} witnessed by r:r(𝚋𝚊𝚜𝚎)=br_{\star}:r\left(\mathtt{base}\right)=b, we have (cb,𝚛𝚎𝚏𝚕b)=M(r,r)\left(c_{b},\mathtt{refl}_{b}\right)=_{M}\left(r,r_{\star}\right). By Proposition 3.21, it suffices to find a path q:cb=rq:c_{b}=r such that q(𝚛𝚎𝚏𝚕b)=rq_{\ast}\left(\mathtt{refl}_{b}\right)=r_{\star}. Using function extensionality, to find qq, it suffices to find a path qx:b=r(x)q_{x}:b=r(x) for any x:𝕊n+1x:{\mathbb{S}}^{n+1}. Now using the constructors we have a point h(r):Anh(r):\left\|A\right\|_{n} along with two paths s(r)(x):r(x)=h(r)s(r)(x):r(x)=h(r) and s(r)(𝚋𝚊𝚜𝚎):r(𝚋𝚊𝚜𝚎)=h(r)s(r)\left(\mathtt{base}\right):r\left(\mathtt{base}\right)=h(r). Thus the desired path qxq_{x} is given by

r1s(r)(𝚋𝚊𝚜𝚎)s(r)(x)1.r_{\star}^{-1}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,s(r)\left(\mathtt{base}\right)\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,s{(r)(x)}^{-1}.

Finally, by Lemma 3.13, q(𝚛𝚎𝚏𝚕b)=rq_{\ast}\left(\mathtt{refl}_{b}\right)=r_{\star} is equivalent to q𝚋𝚊𝚜𝚎1𝚛𝚎𝚏𝚕b𝚛𝚎𝚏𝚕b=rq_{\mathtt{base}}^{-1}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,\mathtt{refl}_{b}\,\mathchoice{\mathbin{\raisebox{2.15277pt}{$\displaystyle\centerdot$}}}{\mathbin{\raisebox{2.15277pt}{$\centerdot$}}}{\mathbin{\raisebox{1.07639pt}{$\scriptstyle\,\centerdot\,$}}}{\mathbin{\raisebox{0.43057pt}{$\scriptscriptstyle\,\centerdot\,$}}}\,\mathtt{refl}_{b}=r_{\star}, which holds by the definition of q𝚋𝚊𝚜𝚎q_{\mathtt{base}} and coherence operations. ∎

References

  • [ABFJ20] Mathieu Anel, Georg Biedermann, Eric Finster, and André Joyal. A generalized Blakers–Massey theorem. Journal of Topology, 13(4):1521–1553, 2020.
  • [AW09] Steve Awodey and Michael A. Warren. Homotopy theoretic models of identity types. Mathematical Proceedings of the Cambridge Philosophical Society, 146:45–55, 2009.
  • [BH18] Ulrik Buchholtz and Kuen-Bang (Favonia) Hou. Cellular cohomology in Homotopy Type Theory. In Proceedings of the 33rd Annual ACM/IEEE Symposium on Logic in Computer Science, pages 521–529. ACM, July 2018.
  • [BR16] Ulrik Buchholtz and Egbert Rijke. The Cayley–Dickson construction in Homotopy Type Theory, 2016.
  • [BR17] Ulrik Buchholtz and Egbert Rijke. The real projective spaces in Homotopy Type Theory. In 2017 32nd Annual ACM/IEEE Symposium on Logic in Computer Science (LICS), pages 1–8, June 2017.
  • [BR21] Ulrik Buchholtz and Egbert Rijke. The long exact sequence of homotopy nn-groups, 2021.
  • [Bru16] Guillaume Brunerie. On the Homotopy Groups of Spheres in Homotopy Type Theory. PhD thesis, Université de Nice, June 2016.
  • [Car22] David Martínez Carpena. Semantics of Homotopy Type Theory, November 2022.
  • [Cav15] Evan Cavallo. Synthetic cohomology in Homotopy Type Theory, December 2015.
  • [Esc22] Martín Hötzel Escardó. Introduction to univalent foundations of mathematics with Agda, 2022.
  • [Gra18] Robert Graham. Synthetic homology in Homotopy Type Theory, December 2018.
  • [Hat02] Allen Hatcher. Algebraic Topology. Cambridge University Press, 2002.
  • [HFLL16] Kuen-Bang (Favonia) Hou, Eric Finster, Dan Licata, and Peter LeFanu Lumsdaine. A mechanization of the Blakers–Massey connectivity theorem in Homotopy Type Theory, 2016.
  • [Hou17] Kuen-Bang (Favonia) Hou. Higher-Dimensional Types in the Mechanization of Homotopy Theory. PhD thesis, Carnegie Mellon University, February 2017.
  • [Lum11] Peter LeFanu Lumsdaine. Higher inductive types: a tour of the menagerie, April 2011. Blog post.
  • [ML75] Per Martin-Löf. An intuitionistic theory of types: Predicative part. In H. E. Rose and J. C. Shepherdson, editors, Logic Colloquium ’73, volume 80, pages 73–118. Elsevier, 1975.
  • [Rez15] Charles Rezk. Proof of the Blakers–Massey theorem, January 2015.
  • [Rij22] Egbert Rijke. Introduction to Homotopy Type Theory, 2022.
  • [Uni13] The Univalent Foundations Program. Homotopy Type Theory: Univalent Foundations of Mathematics. https://homotopytypetheory.org/book, Institute for Advanced Study, 2013.