A subobject of an object in a Category is (an isomorphism class of) a Monomorphism . Two monos , define the same subobject when there is an Isomorphism with . Subobjects of are preordered by factorization ( iff for some ), giving the poset .
Sources: 7 Sketches §7.2.2 (“it will do no harm to think of monomorphisms into as subobjects of ”), Definition 7.12, §7.4.3 (“The poset of subobjects”); Kittenlab Lecture 14 (subsets as injections vs. as characteristic functions); DaoFP §2.4.
- In , a mono is an Injection, isomorphic to the inclusion of the Subset ; so , the Power Set.
- In a presheaf category a subobject of is a sub-functor: a choice of subset for each , closed under the action of morphisms. For graphs: a subgraph.
- In a category with a Subobject Classifier , : subobjects are the same as predicates on . In a Topos, is a Heyting Algebra; meets are pullbacks, joins are images of coproducts (Epi-Mono Factorization).
- Pullback along gives a Monotone Map (the preimage), with adjoints (Quantification, Direct Image, Preimage, and Dual Image).
- Kittenlab (Lecture 14) contrasts two representations of a finite subset: as an injective
FinFunctionand as a Boolean vector — the two sides of the subobject-classifier bijection.
Docs: FinSets · C-set morphisms · Graphs · Vignette: subgraphs — Kittenlab Lecture 14
using Catlab
Y = FinSet(5)
A = Subobject(Y, [1, 2, 4]) # a subobject of a finite set
hom(A) # the mono FinFunction([1, 2, 4], 5)
B = Subobject(Y, [2, 4, 5])
A ∧ B, A ∨ B # Sub(Y) is a lattice (here: a Boolean algebra)
G = path_graph(Graph, 3)
H = Subobject(G, V=[1, 2], E=[1]) # a subgraph as a subobject
force(hom(H)) # the monic ACSetTransformation H ↪ Gimport Mathlib
open CategoryTheory
#check @CategoryTheory.Subobject -- Subobject X := quotient of MonoOver X by iso
#check @CategoryTheory.MonoOver
#check @CategoryTheory.Subobject.pullback -- f^* : Subobject Y ⥤ Subobject X
#check @CategoryTheory.Subobject.inf -- meets via pullback (needs HasPullbacks)-- a subobject of a finite type, two ways (Kittenlab): as a list of elements or as a predicate
newtype Sub a = Sub [a]
toPred :: Eq a => Sub a -> (a -> Bool)
toPred (Sub xs) = (`elem` xs)
fromPred :: [a] -> (a -> Bool) -> Sub a
fromPred univ p = Sub (filter p univ)