On monoids in the category of sets and relations
Anna Jen\v{c}ov\'a, Gejza Jen\v{c}a

TL;DR
This paper explores the structure of monoids within the category of sets and relations, revealing connections to hypergroups, partial monoids, and quantum logics through a 2-categorical framework.
Contribution
It introduces a 2-categorical perspective on monoids in Rel, unifying various classes like hypergroups and effect algebras and clarifying their foundational relations.
Findings
Characterizes monoids in Rel as including hypergroups and partial monoids.
Shows how 2-categorical structure explains congruence relations in effect algebras.
Connects categorical structures to quantum logics and small categories.
Abstract
The category is the category of sets (objects) and relations (morphisms). Equipped with the direct product of sets, is a monoidal category. Moreover, is a locally posetal 2-category, since every homset is a poset with respect to inclusion. We examine the 2-category of monoids in this category. The morphism we use are lax. This category includes, as subcategories, various interesting classes: hypergroups, partial monoids (which include various types of quantum logics, for example effect algebras) and small categories. We show how the 2-categorical structure gives rise to several previously defined notions in these categories, for example certain types of congruence relations on generalized effect algebras. This explains where these definitions come from.
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
∎
11institutetext: A. Jenčová 22institutetext: Mathematical Institute, Slovak Academy of Sciences, Slovak Republic
22email: [email protected] 33institutetext: G. Jenča 44institutetext: Department of Mathematics and Descriptive Geometry
Faculty of Civil Engineering, Slovak University of Technology, Slovak Republic
44email: [email protected]
On monoids in the category of sets and relations
Anna Jenčová
Gejza Jenča
Abstract
The category is the category of sets (objects) and relations (morphisms). Equipped with the direct product of sets, is a monoidal category. Moreover, is a locally posetal 2-category, since every homset is a poset with respect to inclusion. We examine the 2-category of monoids in this category. The morphism we use are lax.
This category includes, as subcategories, various interesting classes: hypergroups, partial monoids (which include various types of quantum logics, for example effect algebras) and small categories. We show how the 2-categorical structure gives rise to several previously defined notions in these categories, for example certain types of congruence relations on generalized effect algebras. This explains where these definitions come from.
Keywords:
effect algebra, relational monoid, 2-category
MSC:
Primary: 03G12, Secondary: 18D05
Acknowledgements.
This research is supported by grants VEGA 2/0069/16, 1/0420/15, Slovakia and by the Slovak Research and Development Agency under the contract APVV-14-0013.
1 Introduction
A strict 2-category ehresmann1963categories ; benabou1965categories is a category with “morphisms between morphisms” or, in other words, a category where the set of all homomorphism between two objects carries the structure of a category. The most important example is – the category of small categories.
The most straightforward definition of a strict 2-category is relatively simple: it is a category enriched kelly1982basic in the (cartesian closed) category . Unfortunately, this definition is not general enough to cover many interesting cases, because it may happen that the composition of 1-cells is associative only up to a 2-isomorphism (for example, the category of spans over is not strict), so one has to weaken the axioms, obtaining a notion of a weak 2-category, sometimes called a bicategory. We refer the reader to lack20102categories ; kelly1974review ; leinster2004higher for an introduction to the subject of 2-categories and to mac1998categories ; awodey2006category for category-theoretical terminology.
The starting point of the formal category theory is the observation that one can formulate various categorical notions (for example, monads, adjunctions, Kan extensions) in the language of 2-categories. Changing the underlying 2-category from to some other 2-category , it may then happen that these notions give rise to either well-known or new notions, perhaps allowing for a new insight. Let us illustrate this phenomenon by an example:
Example 1
For every category , there is a bicategory of spans (see (mac1998categories, , Chapter XII, Section 7)). If is then the monads in are small categories. If is the category of groups then the monads in are the twisted modules (see (mac1998categories, , Chapter XII, Section 8)).
The aim of this paper is to examine the notions “adjunction” and “monad” in the 2-category of monoids in the monoidal 2-category of sets and relations, equipped with the direct product of sets . We denote this 2-category of monoids by . This category includes partial monoids (which include effect algebras), as well as small categories (considered as sets of arrows equipped with the composition).
Realistically, one probably cannot hope to achieve some sort of “real result” from these considerations. However, we find it interesting and surprising that some notions and conditions used in quantum logics appear to come from monads and adjunctions in . Moreover, there are other concrete manifestations of these abstract notions in other parts of mathematics, as demonstrated by several examples.
Recently, there were several other papers published in the area of categorical quantum mechanics abramsky2009categorical that concern and . In heunen2013relative and heunen2015categories , authors establish an interesting equivalence between special dagger Frobenius structures in the dagger monoidal category and internal groupoids in , for a regular category . In contreras2015groupoids , the results from heunen2013relative are extended to describe a correspondence between certain types of generalized groupoids and associative structures in , establishing a link between these abstract results and Poisson sigma models. In heunen2016monads , monads on dagger categories are investigated. In pavlovic2017modular , effect algebras are characterized as certain monoids in , using merely the dagger-compact structure of .
2 The 2-category of sets and relations
In this section, we review some elementary facts concerning the 2-category of sets and relations. Everything in this section is well-known, see benabou1967introduction .
The category of sets and relations, denoted by , is a category whose objects (or [math]-cells) are sets and arrows (or -cells) are relations . The composite of arrows and is the arrow given by the rule
[TABLE]
The identity arrow is the identity relation .
Note that there is an obvious faithful functor that is identity on objects and takes a mapping to its graph
[TABLE]
This forgetful functor is a left adjoint, the corresponding right adjoint is the powerset/image functor . This adjunction induces the well-known covariant powerset monad on . is then isomorphic to the Kleisli category for this monad.
Moreover, the category of sets and relations is a 2-category: if are relations , then a 2-cell is simply the fact that . Thus, every hom-category in is a poset.
As usual, we draw a 2-cell in a commutative diagram as a double arrow, for example
[TABLE]
means that . Note that on the level of elements, the diagram (1) means that
- •
for every and such that there is a with and ,
- •
there exists such that and .
Besides the structure of a 2-category, carries the structure of a dagger category: there is an involution functor that is identity on objects. For a relation , is the relation given by the equivalence
[TABLE]
If , then the disjoint union of sets is both the product and the coproduct of in . Since lacks some (co)equalizers, it is not a (co)complete category.
Considering as a 2-category, we may look at various category-theoretic notions in .
Recall lack20102categories , that in a 2-category a 1-cell is left adjoint to a 1-cell if and only if there are 2-cells and such that in the hom-categories and the diagrams
[TABLE]
commute.
However, since every hom-category in is a poset, these conditions are automatically valid whenever there exist 2-cells and . A straightforward reasoning gives us the following fact.
Fact 1
An arrow in is a left adjoint to an arrow if and only if is (a graph of) a mapping and .
Note that this implies that the canonical inclusion embeds into as the subcategory of left-adjoints in the 2-category .
Recall street1972formal , that a monad in a 2-category is an object equipped with a triple , where , and such that in the hom-category the equations and hold.
Similarly as for the notion of a left-adjoint, the fact that is enriched in implies that these equations for and are valid whenever and exist. Thus, an in is an underlying 1-cell of a monad if and only if and . In other words,
Fact 2
Monads in are preorders.
Indeed, observe that means that is a reflexive and means that is transitive.
In a 2-category, if is left adjoint to (in symbols ), then the quadruple gives rise to a monad on the domain of .
In the 2-category , every monad arises from an adjunction. This is not true in .
Fact 3
A monad in arises from an adjunction if and only if is an equivalence relation.
Indeed, if is a mapping (that means, a left adjoint in ), then the monad associated with the corresponding adjunction is . This is the equivalence relation on given by the decomposition of to the fibers of , usually called the kernel of . On the other hand, if is an equivalence relation on , then we have an obvious adjunction between and the quotient that in turn gives rise to .
3 Monoids in
It is easy to see that the cartesian product of sets is a bifunctor from to .
As is the product in , it satisfies the coherence conditions for a monoidal category (mac1998categories, , Chapter VII), so is a monoidal category.
Definition 1
Let be a monoidal category. A monoid in is a triple , where is an object of , and such that the following diagrams commute
[TABLE]
Here, and denote the (left and right) unitors and the associator of the monoidal category .
The triangle diagrams are called the right (left) unit axioms. The pentagon diagram is called the associativity axiom.
The monoids in the category are called relational monoids.
Let us spell out the axioms of a relational monoid in detail. Let be a relational monoid. Since is a relation, we may identify with a subset
[TABLE]
of , which we call the set of units of .
The is a relation from to , so it is a subset of . We shall write to denote the fact that .
The right unit axiom means that, for every , there is such that and, at the same time, whenever there is a such that , then . The meaning of the left unit axiom is similar.
Associativity axiom means that for every quadruple of elements of , the following statements are equivalent:
- •
there exists such that and ;
- •
there exists such that and .
We know that every ordinary monoid in has exactly one unit. In general, this is not true for relational monoids.
Proposition 1
Let be a relational monoid. For every , there is exactly one (called the right unit of ) such that .
Proof
By previous remarks, there exists such that . Let us prove that this is unique.
Let be another right unit of . We see that
[TABLE]
By the associativity axiom, there is some such that
[TABLE]
So, in particular, and . Therefore, by the right unit axiom, . Similarly, by the left unit axiom, and this implies .
By a symmetrical argument, there is exactly one left unit for every element of .
Let us consider some examples of relational monoids.
Example 2
Every ordinary monoid in is a relational monoid.
Example 3
Every hypergroup wall1937hypergroups is a relational monoid.
Example 4
Every small category is a relational monoid: the underlying set of the relational monoid corresponding to a category is the set all arrows in . Multiplication is the composition of arrows and the set of units is the set of all identity arrows of . This observation goes back to the seminal paper barr1970relational , see also kenney2011categories ; heunen2013relative for more results on the connections between and .
Example 5
As a consequence of the previous example, the set of all comparable pairs in a poset is a relational monoid.
Explicitly, let be a poset, write for the set of all comparable pairs of elements of . In lattice theory, the elements of are called quotients. As usual (see for example Gra:GLT ) we write to express the facts that that and .
Let us equip with the relation given by the rule if and only if and the relation that selects the trivial quotients of the type .
Then is a relational monoid.
Example 6
Let be the set of all nonnegative real numbers, let be a relation given by the rule if and only if and let be a relation that picks out [math] from . Then is a relational monoid. Note that is not a partial mapping.
For every monoidal category , the class of monoids in comes equipped with a standard notion of morphism between monoids, giving rise to a category of monoids in . However, this notion does not work in examples we are interested in. It turns out that another notion is more appropriate for our purposes.
For relational monoids and a relation , we say that is a morphism of relational monoids if and only if there are 2-cells
[TABLE]
By a category of relational monoids we mean a 2-category in which
- •
0-cells are relational monoids,
- •
1-cells are morphisms of relational monoids,
- •
2-cells are the inclusions of relations, inherited from .
The category of relational monoids is denoted by .
Example 7
The power set of the set of all positive natural numbers, equipped with a elementwise multiplication, is a monoid with a neutral element . Let us define a relation , where is the additive monoid of natural numbers, by the rule if and only if there is some such that the length of the prime decomposition of is equal to . Then is a morphism in from to that is not a graph of mapping.
Since is a 2-category, we may consider adjunctions in . Let be relational monoids, let and be morphisms in . Then it is easy to check that is left adjoint to if and only if is a mapping and .
From this, we obtain a characterization of left adjoints in .
Proposition 2
A morphism of relational monoids is a left adjoint if and only if is a mapping and the following conditions are satisfied.
- (L1)
For all and such that there exist such that , and . 2. (L2)
If and , then .
Proof
Clearly, a morphism of relational monoids is left adjoint in if and only if is left adjoint in (that means, a mapping) and is a morphism in . It remains to observe that the conditions (L1) and (L2) just spell out that the right adjoint is a morphism of relational monoids.
Example 8
Let be a field. Let be set of all monic polynomials over equipped with the multiplication of polynomials. Then is an ordinary monoid in , hence it is a relational monoid. Consider the mapping that takes every polynomial to its degree. Then is a morphism of monoids. Moreover, is a left adjoint in if and only if is algebraically closed.
Indeed, let be a left adjoint in and let be a monic polynomial of degree greater than 1. Since we have , property (L1) of Proposition 2 implies that there are such that , and . So is divisible by a polynomial of degree , hence has a root.
Assume that is algebraically closed. Let us prove (L1), (L2) of Proposition 2. Let and suppose that . To prove (L1), we need to find monic polynomials such that , and . This is easy, because is a product of some polynomials of degree . Moreover, if and only if (this is why we have to consider monic polynomials). So (L2) holds and hence is left adjoint in .
4 Monads in
A monad in the 2-category on a relational monoid is necessarily a monad in on the underlying set . Thus a monad on is a preorder on the set which is, at the same time, an endomorphism of the relational monoid .
[TABLE]
Explicitly, a preorder on is a monad in if and only if for all such that , there are such that , and , moreover, for every , implies that . 111A reader who knows what the Riesz decomposition property means might wish to look at Example 12 now. Let us look at some examples of monads in in .
Example 9
Consider the monoid . Equip with the divisibility partial order , meaning that if and only if there is such that . Assume that . Then there is such that and, putting , we see that , and . Moreover implies that . Therefore, is a monad on .
Example 10
Let be a set. Consider the free monoid , consisting of all words over the alphabet , equipped with the concatenation of words. Recall, that a word is a subword of a word if we can obtain from by deleting the letters at some positions in . For example, the word is a subword of the word . For write if and only if is a subword of . Then is a monad on .
Indeed, if is a subword of , then , where is a subword of and is a subword of . Moreover, is a subword of the empty word if and only if is empty. Therefore, is a monad on the free monoid.
Let be a category, in which
- •
objects are all pairs , where is an endomorphism in
- •
a morphism is an oplax commutative square
[TABLE]
where is a morphism of relational monoids.
We write for the full subcategory of monads in .
Lemma 1
Let be relational monoids, let be a family of morphisms with . Then the relation is a morphism of relational monoids.
Proof
Trivial.
Theorem 4.1
* is a reflexive subcategory of .*
Proof
Let be an object of . Write for the reflexive and transitive closure of the relation . As is a union of a family of morphisms, is an endomorphism of , so is an object of . Moreover, since is a preorder, is an object of . We claim that the morphism
[TABLE]
is a reflection, that means, for every object of and for every arrow there is unique dotted arrow such that
[TABLE]
commutes. Note that, if the dotted arrow exists, then it must be induced by . So it suffices to prove that induces a morphism in from to .
We claim that, for all , induces a morphism in from to . For this is trivial. Suppose that our claim is valid for . Pasting together the 2-cells
[TABLE]
gives us the 2-cell
[TABLE]
Thus, for all , . Taking the union of these inclusions over gives us the inclusion , meaning that induces a morphism in .
Thus, every endomorphism in generates a monad in .
Example 11
Consider the monoid , fix and the endomorphism given by . The reflection of the object of is a monad , where the preorder is given by the rule if and only if and is a power of .
5 Modular lattices as monads in
We have seen (Example 5), that for every poset the set of all quotients is a relational monoid. Let be a lattice. There is a canonical partial order on given by the rule if and only if and . This partial order plays a central role in the theory of lattice congruences (see Gra:GLT ).
Recall, that a lattice is modular if and only if, for all , .
Proposition 3
Let be a lattice. Then is a monad in if and only if is a modular lattice.
Proof
The statement that is a monad means that the diagrams
[TABLE]
commute. The commutativity of the triangle diagram means that implies that . This is easily seen to be true for every lattice .
The commutativity of the square is equivalent to the following property of the lattice :
(**) For every such that there exists such that and , .
Let us prove that the modularity of implies the property (). Suppose that is a modular lattice and let be as in the assumption of (). Let us put so that . We claim that , that means, , . Since , we see that
[TABLE]
and, applying the modular law with , we obtain
[TABLE]
which means that .
Suppose that is a lattice satisfying the () property. Let be such that . We need to prove that . Put , , , , . We see that satisfy the assumptions of (), hence there is a such that and , . This implies that and therefore
[TABLE]
For modular lattices and and a lattice morphism , we write for the mapping given by the rule .
Corollary 1
* is a functor from the category of modular lattices to the category .*
Proof
The proof is straightforward and is thus omitted.
6 Quantum structures as relational monoids
Let be a partial algebra with a nullary operation [math] and a binary partial operation . Denote the domain of by . is called a partial abelian monoid if and only if for all the following conditions are satisfied:
- (P1)
and implies , , . 2. (P2)
implies and 3. (P3)
and .
A partial abelian monoid is positive if and only if, for all , implies . A partial abelian monoid is cancellative if and only if, for all , implies . A cancellative and positive partial abelian monoid is called a generalized effect algebra.
On every generalized effect algebra, there is a canonical partial order given by the rule if and only if there is such that . A generalized effect algebra that is upper bounded is an effect algebra. Effect algebras were introduced in FouBen:EAaUQL , the definition we give here is different but equivalent with the original one. See also KopCho:DP and GiuGre:TaFLfUP for other axiomatizations of effect algebras.
The prototype effect algebra is , where is a Hilbert space and consists of all self-adjoint operators of such that . For , is defined iff and then . The set plays an important role in the foundations of quantum mechanics Lud:FoQM , BusGraLah:OQP .
It is obvious that every generalized effect algebra is a monoid in . Let be generalized effect algebras. A mapping is a morphism of generalized effect algebras if and only if and for all such that we have and . Note that every morphism of generalized effect algebras is a morphism in . Thus, the category of generalized effect algebras is a subcategory of .
Example 12
Let be a generalized effect algebra. What does it mean that the canonical partial order is a monad in on ? The square diagram means that, for all , implies that there are such that , and . This is a well-known condition, called the Riesz decomposition property Goo:POAGwI ; JenPul:QoPAMatRDP . The triangle diagram means that implies that , which is true in any generalized effect algebra. Thus, is a monad on a generalized effect algebra if and only if the generalized effect algebra satisfies the Riesz decomposition property.
Similarly as in , a monad in arises from an adjunction if and only if the preorder is an equivalence.
Explicitly, this gives us the following conditions:
- (M1)
is an equivalence. 2. (M2)
The diagram
[TABLE]
commutes. 3. (M3)
If and is a unit of , then is a unit of .
Proposition 4
ChePul:SILiPAM * Let be a partial abelian monoid. Let be a relation satisfying the following:*
- (C1)
* is an equivalence relation.* 2. (C2)
If exists, exists, and , then . 3. (C5)
If exists and , then there are such that , and . 222The notation (C1), (C2) and (C5) is inherited from the original paper ChePul:SILiPAM . It coincides with the notation used later in several other papers and in the book DvuPul:NTiQS .
Define a partial operation on the quotient by the rule , where are such that , and exists. Then is well defined on and is a partial abelian monoid.
Let us note that the conditions from Proposition 4 are not necessary for an equivalence to induce a partial abelian monoid structure on , they are merely sufficient.
Proposition 5
Let and be a partial abelian monoids, let be a left adjoint in . Then the monad on arising from the adjunction satisfies the conditions in Proposition 4.
Proof
The monad is an equivalence, so (C1) is satisfied.
Let be as in the assumptions of (C2). In this context that means , . Since is a morphism in ,
[TABLE]
commutes, so the existence of in implies the existence of in and . Similarly, , so , meaning that .
Suppose that exists and that , that means, . By Proposition 2 (L1), there are such that , and , so (C5) holds.
Proposition 6
Let be a relation on a partial abelian monoid , satisfying the conditions from Proposition 4 and an additional condition
[TABLE]
Then the quotient map given by is a left adjoint in and .
Proof
By ChePul:SILiPAM , is a morphism of partial abelian monoids, hence it is a morphism in . The condition (C5) implies (L1) and the additional condition implies (L2).
Thus, we may say that some of the conditions from the paper ChePul:SILiPAM come from the 2-structure on .
Finally, let us mention another definition, from the classical paper loomis1955lattice .
Definition 2
Let be a complete orthomodular lattice. A dimension equivalence on is a equivalence relation on such that
- (A)
If , then . 2. (B)
If and , then there exists an orthogonal decomposition of , , such that and . 3. (C)
If and are pairwise orthogonal families of elements, such that for all , then . 4. (D)
If and are not orthogonal in then there are nonzero in such that , and .
An orthomodular lattice can be defined as an effect algebra that is lattice-ordered and satisfies the condition . Note that (A) is (M3), (B) is (M2) and (C) is an infinitary version of (C2). So a dimensional equivalence on an orthomodular lattice is a particular type of monad in arising from an adjunction. It remains an open problem whether we can obtain the conditions (C) and (D) using the 2-categorical machinery within . Especially, the condition (D) remains a puzzle to us.
Acknowledgements We are indebted to both anonymous referees for valuable comments and suggestions.
The reference list from the paper itself. Each links out to its DOI / PubMed record.
- 1(1) Samson Abramsky and Bob Coecke. Categorical Quantum Mechanics. In Kurt Engesser, Dov M. Gabbay, and Daniel Lehmann, editors, Handbook of Quantum Logic and Quantum Structures , pages 261–32. Elsevier, Amsterdam, 2009.
- 2(2) Steve Awodey. Category Theory . Number 49 in Oxford Logic Guides. Oxford University Press, 2006.
- 3(3) Michael Barr. Relational algebras , pages 39–55. Springer Berlin Heidelberg, Berlin, Heidelberg, 1970.
- 4(4) Jean Bénabou. Introduction to bicategories. In Reports of the Midwest Category Seminar , pages 1–77. Springer, 1967.
- 5(5) P. Bush, M. Grabowski, and P. Lahti. Operational Quantum Physics . Springer-Verlag, Berlin, 1995.
- 6(6) J Bénabou. Catégories relatives. C.R. Acad. Sci. Paris , 260:3824–3827, 1965.
- 7(7) G. Chevalier and S.Pulmannová. Some ideal lattices in partial abelian monoids and effect algebras. Order , 17:75–92, 2000.
- 8(8) Ivan Contreras. Groupoids, Frobenius algebras and Poisson sigma models. In Mathematical Aspects of Quantum Field Theories , pages 413–426. Springer, 2015.
