advanced34 min studyLesson 540 in Mathematics

Enriched and monoidal categories

Replace Hom sets by structured objects and interpret directed shortest paths as enriched composition.

On this page

What you’ll understand

  • State the tensor, unit, and coherence data needed for a monoidal base.
  • Interpret enriched composition in Boolean and extended-distance bases.
  • Compute a directed distance closure and check its enriched triangle inequalities.

Ordinary categories use sets of arrows. Enriched categories replace those sets by objects carrying another kind of structure, while composition becomes a morphism in a chosen base category. To combine two such Hom objects, the base needs a tensor product and a unit with coherent associativity. Boolean truth values recover preorders; nonnegative extended distances recover a generalized notion of metric space. These examples make the enriched axioms concrete while showing which familiar metric assumptions are additional.

The monoidal base supplies a coherent tensor

A monoidal category V\mathcal V has a tensor bifunctor, a unit object I, and natural associator and left and right unit isomorphisms. The associator satisfies a pentagon identity, and the unit maps satisfy a triangle identity. These coherence conditions ensure that differently bracketed compositions interact consistently. Associativity is not assumed to be literal equality of objects: even Cartesian products are ordinarily connected by canonical rebracketing isomorphisms rather than identical ordered-pair encodings.

A symmetric monoidal category has additional coherent symmetry maps. A closed monoidal category has internal Hom objects implementing tensor–Hom adjunctions. Neither symmetry nor closedness is required merely to define an enriched category over a monoidal base. They become necessary assumptions for particular further constructions and theorems. For example, a general enriched functor category may demand suitable closedness and limits; those properties cannot be inferred just from the existence of a tensor.

αU,V,W:(U⊗V)⊗W→ ≅ U⊗(V⊗W),I⊗U≅U≅U⊗I.\alpha_{U,V,W}:(U\otimes V)\otimes W\xrightarrow{\ \cong\ }U\otimes(V\otimes W),\qquad I\otimes U\cong U\cong U\otimes I.
The associator and unit maps are specified natural isomorphisms subject to pentagon and triangle coherence.↔ Scroll wide equations horizontally.

Composition now lives inside the base

A V\mathcal V-enriched category has objects x, a Hom object A(x,y)\mathcal A(x,y) in the base for every ordered pair, composition morphisms from A(y,z)⊗A(x,y)\mathcal A(y,z)\otimes\mathcal A(x,y) to A(x,z)\mathcal A(x,z), and identity morphisms from I to A(x,x)\mathcal A(x,x). Associativity and identity diagrams use the base's coherence maps. When the base is locally small, its ordinary maps from I into these Hom objects form the Hom sets of an underlying ordinary category.

Take the Boolean poset with tensor given by conjunction and unit true. A Hom object is a truth value expressing whether x relates to y. Identity requires reflexivity, and composition requires transitivity. Antisymmetry is not an enriched axiom, so this base describes preorders rather than only partially ordered sets. The base is symmetric, but that does not require its enriched relation to be symmetric: a directed order is already a counterexample.

A(y,z)⊗A(x,y)⟶A(x,z),I⟶A(x,x).\mathcal A(y,z)\otimes\mathcal A(x,y)\longrightarrow\mathcal A(x,z),\qquad I\longrightarrow\mathcal A(x,x).
These are morphisms of the base category, rather than ordinary composition functions between sets.↔ Scroll wide equations horizontally.

Distances are Hom objects with reversed order

Use the monoidal poset ([0,∞],≥,+,0)([0,\infty],\ge,+,0), where an arrow from r to s exists when r is at least s. Composition becomes the usual triangle inequality, and the unit forces a zero self-distance. The allowed infinity satisfies the standard extended addition rule. Neither symmetry nor separation of distinct points at positive distance is required. These are Lawvere generalized metric spaces, whose axioms are weaker than those of ordinary symmetric, separated metric spaces.

For a finite directed graph with nonnegative edge weights, shortest-path distances provide such an enrichment whenever all distances are interpreted with infinity for missing routes. Concatenating two paths proves the triangle inequality after taking shortest lengths. Raw edge weights need not satisfy it, so taking their closure changes some entries. The associated ordinary category has a morphism exactly when the distance is zero, since a base map from the unit zero to a distance exists precisely in that case.

d(x,z)≤d(x,y)+d(y,z),d(x,x)=0.d(x,z)\le d(x,y)+d(y,z),\qquad d(x,x)=0.
The base order is reversed, so an enriched composition arrow expresses the familiar less-than-or-equal distance inequality.↔ Scroll wide equations horizontally.

Close a directed three-point distance table

On vertices A, B, C, give directed edges A→B weight 2, B→C weight 3, A→C weight 8, B→A weight 4, C→B weight 1, and C→A weight 10. Compute all shortest-path distances and identify what prevents the raw edge table from already defining a distance enrichment.

  1. The path A→B→C has length five, shortening the raw A→C edge of weight eight. The path C→B→A also has length five, shortening the raw C→A edge of weight ten. The other four nonidentity edges are not shortened by routing through the third vertex.

  2. Use zero on the diagonal and these shortest values off the diagonal. The resulting matrix in A,B,C order has rows (0,2,5)(0,2,5), (4,0,3)(4,0,3), and (5,1,0)(5,1,0). Concatenating shortest paths gives every triangle inequality; direct checks give equalities for A→C through B and C→A through B.

  3. The raw table fails the A,B,C triangle because eight exceeds two plus three; it also fails the reverse triangle because ten exceeds one plus four. The corrected table is asymmetric, since A→B has distance two while B→A has distance four, which is permitted for this enrichment.

D=(025403510),d(A,C)=2+3=5<8.D=\begin{pmatrix}0&2&5\\4&0&3\\5&1&0\end{pmatrix},\qquad d(A,C)=2+3=5<8.
The distance matrix records optimal directed paths, not merely the original edge labels.↔ Scroll wide equations horizontally.
The result

Shortest-path closure gives a valid asymmetric distance enrichment. The raw edge table fails two required triangles and must first be closed.

Explore the model

Interactive lab

Interactive lab · vectors

Inspect a triangle inequality without a graph solver

Pause and Reset, then set angle to 0 degrees and magnitude to 2; record u=(2,0). For a fresh comparison, Pause and Reset, then set angle to 90 degrees and magnitude to 3; record v=(0,3). Predict on paper that their sum has length √13, at most 5. The instrument shows one vector and its projections at a time, not a shortest-path graph or an enriched category. Control changes keep elapsed time, so Reset and both settings are required for each fresh comparison.

Inspect a triangle inequality without a graph solverPlayback traces a fixed vector and its projections. Angle and magnitude set the geometry; the moving marker does not change them. Current readings: x component: 1.393; y component: 0.975; Magnitude: 1.7. All parameters are adjustable with the labeled controls below.−7.46−3.7303.737.46−3.5−1.7501.753.5xyvvₓ = 1.39
Vectorx / y projectionsTrace marker
x component
1.393
y component
0.975
Magnitude
1.7
t = 0 s

Playback traces a fixed vector and its projections. Angle and magnitude set the geometry; the moving marker does not change them. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.

Look forThe triangle inequality gives a compositional bound, while an enrichment additionally specifies its base, Hom objects, identities, and coherence.

Check your understanding

Which assumption is sufficient to define a V-enriched category, before asking for additional enriched constructions?

Try it yourself

In the Boolean monoidal base, use three objects a, b, c. Declare a and b related in both directions, both related to c, each related to itself, and no relation from c back to a or b. Does this define an enriched category? Is it a partial order, and are a and b isomorphic in its underlying category?

Take a moment to make a prediction or work it out on paper. Open a hint when you need one.

Give me a hint

Check reflexivity and transitivity separately from antisymmetry. In a category with at most one arrow of each type, opposite arrows automatically compose to the available identities.

Compare with the solution

All identities are present, and composing any two declared relations produces another declared relation. Thus this is a Boolean-enriched category, equivalently a preorder. It is not a partial order because distinct a and b are mutually related. In the underlying ordinary category the unique arrows a→b and b→a compose to the unique endomorphisms, which are identities, so a and b are isomorphic despite being distinct objects.

Take it with you

  • A monoidal base supplies tensor and unit coherence for enriched composition.
  • Boolean enrichment gives preorders without requiring antisymmetry.
  • Extended-distance enrichment allows asymmetry, zero distances between distinct points, and infinity.

Read further

Original sources and deeper explanations to follow at your own pace.

Optional progress, saved in this browser when available. Revisit any lesson at any time.

Lesson not marked complete.