Categories by cardinality
Since arrows connect objects, the cardinality of a category is determined by the number of objects it contains. Objects are prerequisite for arrows - no objects, no arrows. Here, I consider some categories divided by classes which are determined by the number of contained objects; then each class has a number of subclasses that form by the incremental addition of arrows.
The code in parens (x.y) denotes the number of objects (x) along with the number of id arrows (always the same number, since each object must have its own unique id arrow), and the number of non-identity arrows (y).
No objects
(0.0) There exists the empty category, a category devoid of objects and thus also of arrows, however, it's not particularly interesting. No objects, no arrows.
One object
(1.0) At a minimum, besides the object A
, a single-object category must also have its identity arrow, 1α΄
. One object, one arrow (id).
(1.x) A singleton category can possibly have any number of other arrows [?], but they are all isomorphic to the identity arrow. If this is true, how does one distinguish the id arrow?
1 object and its id arrow, plus β of other arrows [?]
Two objects
(2.0) At a minimum, a category with two objects has:
two distinct objects
A
andB
two ID arrows,
1α΄
and1Κ
, one for each object
The objects need not be connected, so no other arrows need exist.
(2.1) Finally, we have a situation when an arrow is added to our 2-object category! We decide to direct it from A
to B
and name it f
. How existing, our first proper morphism f : A -> B
! It allows us to finally compose things, although trivially; we can only precompose 1α΄
before f
as f β 1α΄
. It leads us to our first equality f β 1α΄ = f
. [NOTE] Some authors use this to define the identity arrow [!?], which seems incorrect because there are categories without inter-object arrows that still have identity arrows!
which is equal to f
i.e.. On the other hand composing 1α΄
after f
, 1π β f
, would make no sense because the codomain of f
is not the domain of 1α΄
, i.e. cod(f) β dom(1α΄)
.
Definition
A category is a collection of objects together with morphisms connecting these objects.
A category C
is given by a collection Cβ
of objects and a collection Cβ
of arrows, which have the following structure:
each arrow has an object as source and target,
f: A -> B
identity: each object has identity arrow,
1β
orIβ
transitivity axiom: if there is an arrow
a -> b
and an arrowb -> c
then there must be an arrowa -> c
Examples of categories
Ordered categories: sets and relations
Category of sets and functions
Hask
quasi-category of Haskell types and functions
A category C is an algebraic structure consisting of a class of objects (denoted by A, B, C, etc.), and a class of arrows (denoted by f, g, h, etc.), together with three total and one partial operation.
The first two total operations are called target and source; both assign an object to an arrow. We write f : A <- B
(pronounced "f has type A from B") to indicate that the target of the arrow f
is A
and the source is B
.
The third total operation takes an object A
to an arrow idα΄ : A <- A
, called the identity arrow on A
.
The partial operation is called composition and takes two arrows to another one. The composition f β g
(read "f after g") is defined iff f : A <- B
and g : B <- C
for some objects A, B, C, in which case f β g : A <- C
. In other words, if the source of f
is the target of g
, then f β g
is an arrow whose target is the target of f
and whose source is the source of g
.
Composition is required to be associative and to have identity arrows as units:
βfgh. (f: A <- B) β§ (g: B <- C) β§ (h: C <- D) . f β (g β h) = (f β g) β h = f β g β h
βf. f: A <- B . idα΄ β f = f = f β idΚ
Last updated
Was this helpful?