TITLE: Role of univalence in homotopy group calculations
QUESTION [15 upvotes]: This book has a section with proofs of the fact $\pi_1(S^1)=\mathbb Z$ using the univalence axiom. They are a bit too technical for me at the moment to read, but I want to understand the following (vague but conceptual) question:
What is the role of the univalence axiom in these proofs?
Usually, univalence is motivated with a slogan like "isomorphic structures are equal". However, it seems the application of univalence in the proofs of $\pi_1(S^1)=\mathbb Z$ must be of a completely different kind than "treating isomorphic algebraic structures as the same". So I really would like to get a hint at how univalence can be relevant to such concrete questions, as a motivation for reading the proofs in more detail.

REPLY [11 votes]: This is essentially the same content as earlier answers, but I’ll try to emphasise the aspect OP is asking about a bit more explicitly.  $\newcommand{\Z}{\mathbb{Z}}$I’ll use the terminology of “paths” rather than “equalities”, to emphasise the space-like viewpoint.

Classically, how do you investigate the structure of a free group, or a group presented by generators and relations?  In particular, how do you know it’s non-trivial?  You look at actions or representations of it — concretely presented groups, into which the presented group maps.

The circle $S^1$ is defined as the type freely generated by a point and a loop at that point.  $\pi_1(S^1)$ is the total type of loops at the basepoint.  There’s a clear map $\Z \to \pi_1(S^1)$, by taking integer powers of the generating loop.  But how do you show this is non-trivial?  Since it’s a freely presented structure, you need to find maps into concretely presented types.

Univalence says that paths between types correspond to equivalences between them.  It follows fairly directly that paths between types-with-structure correspond to structure-preserving-equivalences — e.g. paths in the type of groups correspond to group isomorphisms.

Take $\Z$, equipped with the successor endomorphism $s$.  As a type-with-endomorphism $(\Z,s)$, it has $\Z$-many automorphisms, the integer powers of $s$ — you can calculate this in HoTT exactly the same way you would calculate it classically.  By univalence, it follows that it has $\Z$-many paths to itself, all the integer powers of the basic loop corresponding to $s$.  $\newcommand{\TyEnd}{\textrm{TyEnd}}$ In other words, $\pi_1(\TyEnd,(\Z,s)) \cong \Z$, where $\TyEnd$ is the type of types-with-endomorphism.

So the universal property of $S^1$ gives a map into $\TyEnd$, taking its basepoint to $(\Z,s)$ and its generating loop to (the path corresponding to) $s$.  This shows that the $\Z$-many powers of the loop in $\pi_1(S^1)$ must be distinct, since they get mapped to the automorphisms of $(\Z,s)$, which we know are distinct.  (And with a little more work in similar tools, we can show the map $\Z \to \pi_1(S^1)$ is surjective.)


So the take-home in all this is: $S^1$ is the free type-with-a-loop.  So to investigate its structure (in particular, $\pi_1(S^1)$), we want to find types with non-trivial loop spaces, or better still, where we can calculate loop spaces explicitly.  Univalence tells us that loops in types of types-with-structure correspond to automorphisms of such types-with-structure; so it gives us types where there are interesting loop spaces that we can calculate explicitly.