The Mathematics Ontology Bible · Version 1.0
Part III: Category Theory — The Language of Structure
If set theory is the microscope that reveals the internal structure of mathematical objects, category theory is the telescope that reveals the relationships between mathematical structures. It is the most abstract and most universal of all mathematical languages.
3.1 Categories
Definition: A category C consists of:
- A collection of objects Ob(C)
- For each pair of objects A, B: a collection Hom(A,B) of morphisms (arrows) from A to B
- For each object A: an identity morphism id_A ∈ Hom(A,A)
- A composition operation: Hom(A,B) × Hom(B,C) → Hom(A,C), written (f,g) ↦ g∘f
Axioms:
- Associativity: h∘(g∘f) = (h∘g)∘f
- Unit: f∘id_A = f = id_B∘f for f: A→B
Examples:
- Set: objects are sets, morphisms are functions
- Grp: objects are groups, morphisms are group homomorphisms
- Top: objects are topological spaces, morphisms are continuous maps
- Vect_k: objects are vector spaces over field k, morphisms are linear maps
- Pos: objects are posets, morphisms are order-preserving maps
- 0, 1, 2, …: discrete categories (no non-identity morphisms)
- B(G): the delooping of a group G — one object, morphisms are elements of G, composition is group multiplication
3.2 Functors
Definition: A functor F: C → D assigns to each object A ∈ Ob(C) an object F(A) ∈ Ob(D), and to each morphism f: A→B a morphism F(f): F(A)→F(B), preserving identity and composition.
Contravariant functors reverse arrows. The powerset functor 𝒫: Set → Set^op sends each function f: A→B to the preimage function f⁻¹: 𝒫(B) → 𝒫(A).
Examples:
- The forgetful functor Grp → Set forgets the group structure
- The free functor Set → Grp sends a set S to the free group on S
- Homology functors Hₙ: Top → Ab send topological spaces to abelian groups
3.3 Natural Transformations
Definition: A natural transformation η: F ⟹ G between functors F, G: C → D assigns to each object A ∈ C a morphism η_A: F(A) → G(A) such that for every f: A→B in C, the square
F(A) --η_A--> G(A)
| |
F(f) G(f)
↓ ↓
F(B) --η_B--> G(B)
commutes. Natural transformations are the morphisms between functors; they make functors into objects of a functor category.
Significance: Naturality is the categorical formalization of "canonical" or "coordinate-free." The double dual embedding V → V** (in linear algebra) is natural; the dual embedding V → V* requires a choice of basis and is not natural.
3.4 Universal Properties and Adjoints
Universal property: An object X with morphisms satisfying some property P is universal if every other object satisfying P maps uniquely through X. This characterizes mathematical constructions up to unique isomorphism — without specifying internal structure.
Adjoint functors: Functors F: C → D and G: D → C are adjoint (F ⊣ G) if for every A ∈ C, B ∈ D there is a natural bijection:
Hom_D(F(A), B) ≅ Hom_C(A, G(B))
F is the left adjoint, G the right adjoint.
Adjunctions are ubiquitous: Free/forgetful, product/exponential, quantification/substitution, suspension/loop. "Every concept that matters is an adjoint" (Lawvere). Adjunctions formalize the idea that two mathematical constructions are "optimal inverses" of each other.
3.5 Limits and Colimits
Limit: The limit of a diagram D: J → C is an object L with projections to each D(j) that commutes with all morphisms in J, universal among all such cones.
Special cases:
- Terminal object: limit of the empty diagram — the "point"
- Product: limit of a discrete diagram — A×B
- Equalizer: limit of a parallel pair — {x : f(x) = g(x)}
- Pullback: limit of a cospan — the fiber product
Colimit: Dual — cone from the diagram. Special cases: initial object, coproduct (disjoint union), coequalizer, pushout.
3.6 The Yoneda Lemma
Statement: For any category C, functor F: C → Set, and object A ∈ C:
Nat(Hom_C(A, -), F) ≅ F(A)
Natural transformations from the representable functor Hom(A,-) to F are in bijection with elements of F(A).
Corollary (Yoneda embedding): The functor A ↦ Hom(A,-) is a fully faithful embedding of C into [C^op, Set]. Every category embeds into a category of presheaves. An object is completely determined by its relationship to all other objects.
Philosophical significance: Yoneda says that an object is nothing more than the totality of its relationships to other objects. This is categorical structuralism made precise.
3.7 Higher Categories
n-categories: 2-categories have objects, morphisms, and 2-morphisms (morphisms between morphisms). 3-categories add 3-morphisms. The limit is ∞-categories (quasi-categories, complete Segal spaces).
Importance: Homotopy theory is naturally the theory of ∞-groupoids (∞-categories where all morphisms are invertible). Homotopy Type Theory makes this precise: types in HoTT are ∞-groupoids.