Categories
What is the common structure behind numbers, spaces, functions, transformations, and deformations?
How little must be kept in order to talk about mathematical structure at all?
Arithmetic had numbers and operations. Algebra had expressions, equations, groups, rings, and homomorphisms. Linear algebra had vector spaces and linear maps. Geometry had spaces and rigid motions. Calculus and analysis had functions, limits, and operators. Topology had spaces and continuous maps. Homotopy went one level higher and treated deformations between maps as objects of comparison.
The content changed each time. The pattern did not.
objects
|
| structure-preserving transformations
v
objects
Again and again, mathematics selected a kind of object, selected the transformations allowed between those objects, composed those transformations, and studied what survived.
Category theory begins by keeping only that grammar.
A category consists of objects, morphisms between objects, identity morphisms, and a rule for composing morphisms.
A --f--> B --g--> C
g . f : A -> C
The word "object" is deliberately broad. An object in a category may be a set, a group, a ring, a vector space, a topological space, a proposition, a type, a graph, or something more abstract. Category theory asks how objects are connected by structure-respecting arrows. The arrows are called morphisms. In familiar categories, morphisms are the transformations that preserve the structure being studied.
sets functions
groups group homomorphisms
rings ring homomorphisms
vector spaces linear maps
topological spaces continuous maps
Each line defines a different mathematical world. The objects differ, and the morphisms differ, but the categorical shape is the same: objects connected by composable arrows.
Composition is the central discipline. If f: A -> B and g: B -> C, then there must be a composite morphism
g . f : A -> C
This says that two allowed transformations performed in sequence still form an allowed transformation.
A --f--> B --g--> C
| ^
| |
`---- g . f ------'
That closure under composition is what lets a collection of objects and arrows become a mathematical world. Composition must be associative.
If three morphisms fit together,
A --f--> B --g--> C --h--> D
then it should not matter whether we first combine f with g, or first combine g with h.
h . (g . f) = (h . g) . f
The equality says the final composite transformation is the same. A path through the diagram has a well-defined total effect. Every object must also have an identity morphism.
id_A : A -> A
The identity morphism leaves the object unchanged in the only way relevant to the category. It composes neutrally with every morphism entering or leaving the object.
f . id_A = f
id_B . f = f
for every f: A -> B.
This is the minimal structure needed to speak coherently about transformations. There are objects. There are arrows. Arrows compose. Composition is associative. Each object has an arrow that does nothing.
category =
objects
morphisms
composition
identities
The definition is small because it is trying to expose a pattern, not replace the subjects it describes. A category of groups still needs group theory. A category of topological spaces still needs topology. Category theory supplies a language for the structural behavior they share.
Consider the category Set. Its objects are sets. Its morphisms are functions. The identity morphism on a set is the identity function, and composition is ordinary composition of functions.
X --f--> Y --g--> Z
x |-> f(x) |-> g(f(x))
The category Vect has vector spaces as objects and linear maps as morphisms. The composite of linear maps is linear, and every vector space has an identity linear map. The same categorical axioms hold, even though the objects now carry addition and scalar multiplication.
V --T--> W --S--> U
S . T is linear
The category Top has topological spaces as objects and continuous maps as morphisms. The composite of continuous maps is continuous, and the identity map is continuous.
X --f--> Y --g--> Z
continuous followed by continuous is continuous
In each case, the chosen morphisms are exactly the transformations stable under identity and composition. That stability turns the subject into a category.
Category theory therefore changes the focus from internal description to external behavior. Instead of asking first what an object contains, it asks how the object participates in a network of arrows.
A group was a structure whose meaningful maps were homomorphisms. A topological space was a space whose meaningful maps were continuous maps. A polynomial was characterized by how it could be interpreted in every ring.
Category theory makes that style explicit.
internal view:
what is inside the object?
categorical view:
what arrows enter, leave, and compose around it?
It packages internal structure through the transformations that preserve it. The structure of a vector space appears in the fact that its morphisms must preserve addition and scaling. The structure of a topological space appears in the fact that its morphisms must be continuous. The structure of a group appears in the fact that its morphisms must preserve multiplication and inverses.
The object is seen through its lawful interactions.
A category can also have only one object. In that case, all morphisms start and end at that same object, so composition becomes a binary operation on morphisms.
* --a--> *
* --b--> *
b . a : * -> *
A monoid can be viewed this way: one object, one identity morphism, and associative composition. This shows how category theory absorbs earlier structures without forcing them into one surface form. A monoid has exactly the same compositional grammar when written categorically.
At the opposite end, a preorder can be seen as a category in which there is at most one morphism from one object to another. If a <= b, there is an arrow from a to b. Transitivity becomes composition, and reflexivity becomes identity.
a <= b <= c
|
v
a <= c
So categories are broad enough to include structures of transformation, structures of operation, and structures of order.
The point is that many different mathematical settings share a compositional skeleton. Category theory studies that skeleton directly.
This also clarifies what counts as sameness at this level. Equality of objects is often too strict. Two groups may have different underlying sets but the same group structure up to isomorphism. Two vector spaces may be different collections of vectors but equivalent once a basis-free linear isomorphism connects them. Two topological spaces may be the same up to homeomorphism.
In a category, an isomorphism is a morphism f: A -> B with an inverse morphism g: B -> A such that
g . f = id_A
f . g = id_B
A --f--> B
A <--g-- B
This generalizes reversible sameness. The nature of the sameness depends on the category. In Set, isomorphisms are bijections. In Vect, they are invertible linear maps. In Top, they are homeomorphisms. The categorical pattern is one definition that specializes to many familiar equivalences.
category chosen
|
v
morphisms chosen
|
v
isomorphism means reversible morphism
This is why categories are a natural endpoint for the structural path. Every earlier branch made meaning by choosing objects, transformations, composition, and invariants. Category theory names that entire arrangement.
The objects are the entities of a mathematical world. The morphisms are the allowed structure-preserving arrows between them. What composes are consecutive morphisms, and composition must be associative with identity morphisms at every object. The invariant is the compositional pattern itself: which arrows exist, how they compose, and which arrows are reversible. The defining relation is the category axioms. Equality of objects is weakened by isomorphism, which captures sameness internal to the chosen category. What remains outside the frame is comparison between entire categories.
A category is the grammar of objects, transformations, identity, and composition.
If categories are worlds of structure, what should count as a structure-preserving transformation between those worlds?