8.1.3 The universal cover in type theory
Let us consider how we might express the preceding proof in type theory. We have already remarked that the path fibration of is represented by the type family . We have also already seen a good candidate for the universal cover of : itβs none other than the type family which we defined in \autorefsec:pi1s1-initial-thoughts! By definition, the fiber of this family over is , while the effect of transporting around is to add one β thus it behaves just as we would expect from \autoreffig:winding.
However, since we donβt know yet that this family behaves like a universal cover is supposed to (for instance, that its total space is simply connected), we use a different name for it. For reference, therefore, we repeat the definition.
Definition 8.1.1 (Universal Cover of ).
Define by circle-recursion, with
We emphasize briefly the definition of this family, since it is so different from how one usually defines covering spaces in classical homotopy theory. To define a function by circle recursion, we need to find a point and a loop in the codomain. In this case, the codomain is , and the point we choose is , corresponding to our expectation that the fiber of the universal cover should be the integers. The loop we choose is the successor/predecessor isomorphism on , which corresponds to the fact that going around the loop in the base goes up one level on the helix. Univalence is necessary for this part of the proof, because we need to convert a non-trivial equivalence on into an identity.
We call this the fibration of βcodesβ, because its elements are combinatorial data that act as codes for paths on the circle: the integer codes for the path which loops around the circle times.
From this definition, it is simple to calculate that transporting with takes to the successor function, and to the predecessor function:
Lemma 8.1.2.
and .
Proof.
For the first equation, we calculate as follows:
(by \autorefthm:transport-compose) | ||||
(by computation for $\mathsf{rec}_{\mathbb{S}^{1}}$) | ||||
(by computation for $\mathsf{ua}$) |
The second equation follows from the first, because and are always inverses, so must be the inverse of . β
We can now see what was wrong with our first approach: we defined and only on the fibers and , when we should have defined a whole morphism of fibrations over . In type theory, this means we should have defined functions having types
(1) | ||||
(2) |
instead of only the special cases of these when is . This is also an instance of a common observation in type theory: when attempting to prove something about particular inhabitants of some inductive type, it is often easier to generalize the statement so that it refers to all inhabitants of that type, which we can then prove by induction. Looked at in this way, the proof of fits into the same pattern as the characterization of the identity types of coproducts and natural numbers in \autorefsec:compute-coprod,\autorefsec:compute-nat.
At this point, there are two ways to finish the proof. We can continue mimicking the classical argument by constructingΒ (1) orΒ (2) (it doesnβt matter which), proving that a homotopy equivalence between total spaces induces an equivalence on fibers, and then that the total space of the universal cover is contractible. The first type-theoretic proof of followed this pattern; we call it the homotopy-theoretic proof.
Later, however, we discovered that there is an alternative proof, which has a more type-theoretic feel and more closely follows the proofs in \autorefsec:compute-coprod,\autorefsec:compute-nat. In this proof, we directly construct bothΒ (1) andΒ (2), and prove that they are mutually inverse by calculation. We will call this the encode-decode proof, because we call the functionsΒ (1) andΒ (2) encode and decode respectively. Both proofs use the same construction of the cover given above. Where the classical proof induces an equivalence on fibers from an equivalence between total spaces, the encode-decode proof constructs the inverse map (decode) explicitly as a map between fibers. And where the classical proof uses contractibility, the encode-decode proof uses path induction, circle induction, and integer induction. These are the same tools used to prove contractibilityβindeed, path induction is essentially contractibility of the path fibration composed with βbut they are applied in a different way.
Since this is a book about homotopy type theory, we present the encode-decode proof first. A homotopy theorist who gets lost is encouraged to skip to the homotopy-theoretic proof (\autorefsubsec:pi1s1-homotopy-theory).
Title | 8.1.3 The universal cover in type theory |
\metatable |