You're reading the public-facing archive of the Category Theory Zulip server.
To join the server you need an invite. Anybody can get an invite by contacting Matteo Capucci at name dot surname at gmail dot com.
For all things related to this archive refer to the same person.
The natural numbers (including zero) together with addition form a monoid. We can associate to each natural number a set having the corresponding number of elements (e.g. associate to "3" a set have three elements). Then, we can use the coproduct in the category of sets to "carry out addition". For example, we can map "3" to a set with three elements, map "5" to a set with five elements, and then take the disjoint union of the resulting sets to get a set with eight elements. By counting the number of elements in the resulting set, we can produce a natural number - so that the addition of the two numbers was computed in the category of sets using the coproduct.
So, at least in some cases, it is possible to compute a monoid operation in a different category using coproducts. When is this possible? And what do these other categories - used for computation in terms of coproducts - look like? Are they anything like the category of sets in general?
For example, consider the monoid having elements 0,1,2,3 together with addition modulo 4 (e.g. 2+3=1 now). Is there some other category where we can compute this operation using coproducts, in a way analogous to how we could carry out regular addition on the natural numbers in the category of sets using coproducts?
Symbolically, if the elements of the monoid in question form the set , when is there a category with objects so that there are functions and satisfying the following: ?
(I'm also interested in thinking about what kind of monoids we can generate in this way by using different universal constructions besides the coproduct...)
So, you're asking for necessary and/or sufficient conditions for a monoid to arise from decategorifying a category with coproducts. (This is how an expert would say your question. It's an interesting question.)
I don't know the answer to your question, but here are some necessary conditions for a monoid to arise from decategorifying a category with coproducts:
The latter condition rules out all groups except the trivial group! So, the answer to this question:
For example, consider the monoid having elements 0,1,2,3 together with addition modulo 4 (e.g. 2+3=1 now). Is there some other category where we can compute this operation using coproducts, in a way analogous to how we could carry out regular addition on the natural numbers in the category of sets using coproducts?
is no!
And here's a little puzzle:
And another little puzzle:
It seems relevant that natural numbers are an ordered monoid, the order being a shadow of some of the maps from FinSet (namely the monomorphisms aka injections)
Thanks to both of you for your responses!
John Baez said:
And here's a little puzzle:
- There is a category with coproducts that when decategorified gives the natural numbers with multiplication as the monoid operation. What is it?
My initial guess is that the category we are looking for here is the opposite category of the category of sets. My idea is that when we move from a category to its opposite, what were products (should intuitively) become coproducts. In the category of sets, we can carry out multiplication (in terms of numbers of elements) by using the product. So, maybe in the coproduct corresponds to multiplication of natural numbers.
Thinking about it a little more, in a morphism from a set to a set is a function from to . So, if any diagram exists in , we can draw a corresponding diagram in by reversing all the arrows. I believe the diagrams describing a product and a coproduct are the same, except with arrows reversed. It seems like a product in should be a coproduct in then.
John Baez said:
And another little puzzle:
- Find a category with coproducts that when decategorified gives a monoid that lacks the cancellation property. That is, find a category with objects such that but .
I know that multiplying by zero can result in a situation like this: even when . The natural numbers (including zero) together with multiplication form a monoid where this situation can occur. If I figured out the previous puzzle, then I would expect to be a setting where there exist objects such that with (where "+" denotes the coproduct).
For example, let be a set with three elements and be a set with two elements. Let be the empty set. Then in I think should be the product of and in , which is the empty set . Similarly, should be the product of and in , which is also the empty set. So, but .
Matteo Capucci (he/him) said:
It seems relevant that natural numbers are an ordered monoid, the order being a shadow of some of the maps from FinSet (namely the monomorphisms aka injections)
That sounds interesting. I'd be interested to learn what other monoids exist that have a natural ordering inherited like this. I guess the natural numbers together with multiplication have the opposite ordering, if we produce the order from the monomorphisms in (which I think should be epimorphisms in , which are the surjections)? Although this ordering is a little bit weird compared to what I would have expected, because there is no function from a non-empty set to an empty set.
(Hmm. I may have gotten confused with all the "op" stuff. I'll leave this up with this disclaimer, though.)
David Egolf said:
John Baez said:
And here's a little puzzle:
- There is a category with coproducts that when decategorified gives the natural numbers with multiplication as the monoid operation. What is it?
My initial guess is that the category we are looking for here is the opposite category of the category of sets. My idea is that when we move from a category to its opposite, what were products (should intuitively) become coproducts. In the category of sets, we can carry out multiplication (in terms of numbers of elements) by using the product.
That's almost right! You've definitely got the key idea. So why is your answer actually wrong?
You can easily fix it.
David Egolf said:
John Baez said:
And another little puzzle:
- Find a category with coproducts that when decategorified gives a monoid that lacks the cancellation property. That is, find a category with objects such that but .
I know that multiplying by zero can result in a situation like this: even when . The natural numbers (including zero) together with multiplication form a monoid where this situation can occur. If I figured out the previous puzzle, then I would expect to be a setting where there exist objects such that with (where "+" denotes the coproduct).
Excellent! Even though your answer to the first problem was not quite correct, you are right in saying that has objects such that but . As you said, we can take to be the empty set.
So now I can't resist giving you this clue to why your answer to the first problem was wrong. In fact is also a category with objects such that but . This was the example I had in mind.
There are also other nice examples.
John Baez said:
So now I can't resist giving you this clue to why your answer to the first problem was wrong. In fact is also a category with objects such that but . This was the example I had in mind.
This was fun to think about! I think the answer has to do with the presence of infinite sets. For example, let be a set with three elements, and let be a set with five elements. Then let be a countably infinite set. Then I think that and both have a countably infinite number of elements, so but .
So, if we create a monoid from by creating an element of the monoid for each isomorphism class of , we don't just get the natural numbers. We get the natural numbers augmented with some fancy extra elements that I think model different infinite cardinalities. I don't know what that resulting structure is called!
Working from this hint, if we want to decategorify some category with coproducts to get the natural numbers together with multiplication - we probably want to make sure we don't end up with extra elements (from infinite sets) like this. So, maybe instead of , we want , the opposite category of the category of finite sets.
Why "maybe"? Please tell me what you're worrying about.
David Egolf said:
John Baez said:
So now I can't resist giving you this clue to why your answer to the first problem was wrong. In fact is also a category with objects such that but . This was the example I had in mind.
This was fun to think about! I think the answer has to do with the presence of infinite sets. For example, let be a set with three elements, and let be a set with five elements. Then let be a countably infinite set. Then I think that and both have a countably infinite number of elements, so but .
Right!
So, if we create a monoid from by creating an element of the monoid for each isomorphism class of , we don't just get the natural numbers. We get the natural numbers augmented with some fancy extra elements that I think model different infinite cardinalities.
Right!
I don't know what that resulting structure is called!
It's called Card, the class of all cardinals. You can add cardinals, but if and is infinite then .
The class of all cardinals is too big to be a set, so Card is not a monoid in the usual sense. It's a 'large' monoid.
Here are some more puzzles:
What monoids do you get from these two categories with coproducts?
Also, here's a nice little category with coproducts:
It has two objects, 0 and 1, and a morphism from 0 to 1 (along with the two identity morphisms).
What commutative monoid does this give? Does this monoid obey the cancellation law
By the way, this category is also called the poset of truth values or Booleans - it's very important in classical logic.
John Baez said:
Why "maybe"? Please tell me what you're worrying about.
Well, I missed a detail before, and I wouldn't put it past me to miss another one. :upside_down: I suppose I'm just generally not super familiar with this stuff... Plus, I'm not carefully writing these arguments out anywhere, and that tends to lead to me making more mistakes. However, I didn't have a specific mathematical worry.
John Baez said:
What monoids do you get from these two categories with coproducts?
Based on the discussion above, from we get the natural numbers together with addition. And from we get the natural numbers together with multiplication.
John Baez said:
Also, here's a nice little category with coproducts:
It has two objects, 0 and 1, and a morphism from 0 to 1 (along with the two identity morphisms).
What commutative monoid does this give? Does this monoid obey the cancellation law
Before thinking about , I want to quickly think about the category . This has one object, and a single identity morphism. I believe it has coproducts, and . So this category with coproducts produces the trivial monoid by decategorification.
Ok, back to . The coproduct of 0 and 0 needs to have a morphism to it from 0, and a unique morphism to every other object that satisfies this condition. That means 0+0=0. The coproduct of 1 and 1 needs to have a morphism to it from 1, and a unique morphism to every other object that satisfies this condition. That means 1+1=1. The coproduct of 0 and 1 needs to have a morphism to it from 0 and a morphism to it from 1, and a unique morphism from it to every other object that satisfies this condition. That means 0+1=1, and 1+0=1.
This monoid does not obey the cancellation law! but . (And 0 is indeed not isomorphic to 1, as there is no inverse for the morphism from 0 to 1 in our category).
John Baez said:
By the way, this category is also called the poset of truth values or Booleans - it's very important in classical logic.
Ah, right! I can see that this monoid is one I'm familiar with, if we think of 0 as "false" and 1 as "true" and our monoid operation as "OR".
A few thoughts about this:
David Egolf said:
John Baez said:
Why "maybe"? Please tell me what you're worrying about.
Well, I missed a detail before, and I wouldn't put it past me to miss another one. :upside_down: I suppose I'm just generally not super familiar with this stuff... Plus, I'm not carefully writing these arguments out anywhere, and that tends to lead to me making more mistakes. However, I didn't have a specific mathematical worry.
Okay, I guess that makes sense. A really important thing about math is that one can work things out to the point of being completely sure about things... and being right, too. I had thought you were at that point. It wouldn't be good to be so scared that one sticks a "maybe" in a sentence when there's no real doubt. But yes, if you're not familiar with these things and you're not writing things up there may be a "cloud of doubt" even absent any specific worry.
Usually I deal with the opposite problem: I've had a lot of bright grad students of an intuitive bent who leap to a conclusion because the conclusion feels like it makes sense and it's very attractive. It's important to be able to make these leaps - intuition is an important tool. But I need to teach them to be careful, because the "flash of insight" often comes with a purely subjective sense that something "must be true", which is actually quite different from being sure because you've worked out the details.
David Egolf said:
John Baez said:
What monoids do you get from these two categories with coproducts?
Based on the discussion above, from we get the natural numbers together with addition. And from we get the natural numbers together with multiplication.
Yes, that's right! This is where addition and multiplication of natural numbers come from... though usually we say multiplication comes from the product in (which is the same as the coproduct in ).
David Egolf said:
Before thinking about , I want to quickly think about the category . This has one object, and a single identity morphism. I believe it has coproducts, and . So this category with coproducts produces the trivial monoid by decategorification.
Right! It's good to go back like that. I also urge you to go forward and look at . Categories of this ilk are called "ordinals".
Your analysis of was spot on.
David Egolf said:
Ah, right! I can see that this monoid is one I'm familiar with, if we think of 0 as "false" and 1 as "true" and our monoid operation as "OR".
Right!
And if we looked at products in we'd get "AND".
The arrow in is "false implies true".
So this is an extremely important category.
David Egolf said:
A few thoughts about this:
- I suppose that in any category. Without checking carefully, it seems like if we get a coproduct with one order of the objects and , then the resulting object will still satisfying the appropriate diagram after we rearrange the order of the objects. Since coproducts, if they exist, are unique up to isomorphism, and and (I think) satisfy both of the coproduct diagrams (with one corresponding to each order), then I think that means we have .
That would explain why the monoids we get from decategorification have to be commutative.
Yes, all this is correct.
David Egolf said:
- While working out coproducts in , I noticed that for , we need there to be morphisms from and to . If we put a partial order on the objects by saying that exactly when there is at least one morphism from to , then that means that if , then and .
Yes, that's right. It's nice how you can make up a concept of that's compatible with addition to this extent. Now I'm wondering if this obeys the usual axiom
Yes, it does.
David Egolf said:
- The result that 0+1=1 and 1+1=1 reminds me of something that happens when working with instruments that take readings. Generally there is a maximum reading that a sensor can produce, and if the input is larger than that maximum, the sensor may just output that maximum reading. I remember wondering years ago what kind of algebraic structure would model what I was thinking of as "saturated addition". I wonder if categories in this style would model this sort of thing.
You might take a look and see whether this category with coproducts:
gives the commutative monoid where the monoid operation is 'saturated addition', .
John Baez said:
And if we looked at products in we'd get "AND".
If you want to get "AND" without switching to products, you can change the assignments of "false" and "true" instead (i.e. by thinking of 0 as "true" and 1 as "false"). :octopus:
Of course, using the product is "better" in the sense that "AND" and "OR" are compatible – they have matching notions of what 0 and 1 mean.
A: You misunderstood me because when I say "true" it means what you mean by "false"; when I say "false" it means what you mean by "true"; when I say "implies" it means what you mean by "implied by"; when I say "and" it means what you mean by "or", and when I say "or" it means what you mean by "and".
B: What about "not"?
A: Oh - on that we agree.
John Baez said:
I also urge you to go forward and look at . Categories of this ilk are called "ordinals".
The coproduct of 0 and 0 needs to have morphisms to it from zero, and have a unique morphism to every other object that satisfies this condition. In terms of the induced preorder mentioned above, I think this corresponds to asking for the smallest object at least as large as zero. So, .
I think this line of argument indicates that . So, , , , , . This is a bit different than the "saturated addition" mentioned above, which would have .
Looking here, I read that the "join" operation corresponds to the coproduct in posets, which makes sense.
The categories we've looked at so far induce an identity element: they have an object so that for all . That ensures that in each of these categories there exists an object so that for all . (This is under the preoder induced by saying when there is at least one morphism from to ).
So, our categories with coproducts must have a "smallest element" if they are to induce a monoid via decategorification. In the case of these ordinal categories, the smallest element is the one we've called "0". But in , every set is a "smallest element" in this sense, so this isn't enough to specify which object will act as the identity element in the induced monoid.
I notice that "0" is the initial object in the ordinal categories, and we saw it became the identity element in the monoid induced by decategorification. The empty set is the initial object in , and it also became the identity element after decategorification. In , an initial object is a terminal object of , so any singleton set is an initial object in . Each singleton set satisfies for each in , and so each singleton becomes the identity element in the monoid induced by decategorification.
In each of these three cases, the initial object becomes the identity morphism in the induced monoid. That seems like an interesting pattern! I wonder if this is always the case.
If for every , then there must be exactly one morphism from to each , so yes, that must be the case! From this perspective, uniqueness up to isomorphism of initial objects decategorifies to uniqueness of the unit element of a monoid.
Would restricted to sets with two or fewer elements have a coproduct that, when decategorified, gives the "saturated addition" commutative monoid on ? Note that there are two morphisms and two morphisms in this category, so it's not the same as the poset . I have no problems finding , but I'm confusing myself on whether the other coproducts exist (mostly because I forgot the second morphism exists until I ran out of spare time to think about this).
I don't think the category of sets with at most 2 elements has coproducts. Remember
I think you can use this to show that the category of finite sets with at most 2 elements, and functions between those, does not have the coproduct 2 + 2.
Morgan Rogers (he/him) said:
If for every , then there must be exactly one morphism from to each , so yes, that must be the case!
I've been staring at this for a while, and I wish I knew how to prove this. I can see that there is at least one morphism from to each . If is an isomorphism, and is the coprojection morphism of the coproduct from , then . However, I'm not sure where to begin to show that this morphism is unique.
I don't know exactly what Morgan meant, but I don't think this is actually true as stated. Consider the full subcategory of the category of sets containing the set of natural numbers as its only object. This category has binary coproducts and satisfies that condition, but has no initial object.
(Of course, if a category does have an initial object, then this will be the unit with respect to the operation of binary coproduct.)
It's true, I'm missing a hypothesis, thanks for spotting that @Graham Manuell . I think "naturally in X" would do it, or the less powerful assumption that for each there exists such that is (non-empty and) finite; the latter one seems to be what I was assuming when I wrote that above.
(Fortunately, a terminal object fulfils this requirement, and having a terminal object isn't a terribly constrictive thing to require.)
I'm not quite sure where I'd like to take this topic as this point. The discussion so far has been interesting, and I've learned a number of cool things from it.
I'll take this moment to summarize some of the things I've learned:
Does anyone have some specific direction/question they think would be interesting to discuss in this thread? I sometimes get a little overwhelmed by how much there is to learn, and I struggle to pick a constructive direction.
I guess this is a good thing to notice now. A category is called a preorder if there's at most one morphism from any object to any other; then we write if there's a morphism from to . A preorder is called a poset if whenever and then .
It's very interesting to think about posets that have finite coproducts (that is, binary coproducts and an initial object ). This sort of poset is called a [[join-semilattice]].
Examples include our friends but also many other interesting things.
Do you see why any join-semilattice is a commutative monoid?
Do you see how to make the collection of all subsets of a set into a join-semilattice?
Join-semilattices are a very interesting kind of commutative monoid.
It's worth noting that every finitely-cocomplete finite category is a preorder, so the monoids we get from finite categories are always semilattices.
Thinking about join-semilattices sounds interesting!
John Baez said:
Do you see why any join-semilattice is a commutative monoid?
Well, we can decategorify a join-semilattice to get a commutative monoid. Join-semilattices have binary coproducts to provide the composition of elements, and an initial object to provide a neutral element in the monoid. The decategorified monoid will be commutative because the binary coproduct operation is commutative up to isomorphism.
However, I think the objects of a join-semilattice together with the binary coproduct operation directly form a monoid. If for objects and , then in a preorder and , and in a poset that means that . Since where "+" denotes the binary coproduct operation, that means that in a join semi-lattice for all objects and . And similarly for all objects , where is the unique initial object.
Interestingly, the nlab article points out that the monoid induced by a join semi-lattice is idempotent. That is, we have for all monoid elements .
John Baez said:
Do you see how to make the collection of all subsets of a set into a join-semilattice?
We can set the objects of our category to be the subsets of , and put a morphism when , I would guess. This forms a preorder, and actually a poset since if and then . The join of two sets corresponds to the union, which always exists, and provides a binary commutative operation with the empty set as its neutral element. The empty set is the initial object, and I think that means we've met all the conditions to have a join-semilattice.
This reminds me a little bit of the definition of a topological space. Starting with a set , we can form a category where the objects are all the subsets of and there is a morphism from to exactly when , as we did above. However, we can then consider full subcategories of . At first I thought that requiring a full subcategory of to have all coproducts and finite products would result in a topological space, but I believe that isn't quite right - for example, coproducts can end up being different than the union.
Graham Manuell said:
It's worth noting that every finitely-cocomplete finite category is a preorder, so the monoids we get from finite categories are always semilattices.
Huh, so somehow having (1) all colimits under finite diagrams and (2) a finite number of objects and morphisms then forces a category to have at most one morphism between any pair of objects?
Yes. The proof is just like the usual proof that a small complete category is a preorder.
Graham Manuell said:
Yes. The proof is just like the usual proof that a small complete category is a preorder.
Thanks for the link! This is quite interesting. I may ask some questions about this proof in a separate thread, to keep this one organized.
David Egolf said:
Thinking about join-semilattices sounds interesting!
John Baez said:Do you see why any join-semilattice is a commutative monoid?
Well, we can decategorify a join-semilattice to get a commutative monoid. Join-semilattices have binary coproducts to provide the composition of elements, and an initial object to provide a neutral element in the monoid. The decategorified monoid will be commutative because the binary coproduct operation is commutative up to isomorphism.
This is all correct! Decategorifying a poset is a rather mild operation, since when we decategorify we take isomorphism classes of objects, but in a poset isomorphic objects are already equal! (As you said.)
David Egolf said:
Graham Manuell said:
Yes. The proof is just like the usual proof that a small complete category is a preorder.
Thanks for the link! This is quite interesting. I may ask some questions about this proof in a separate thread, to keep this one organized.
Note that while this holds classically, it does not hold constructively in general.
Yes, though I think the finite version does hold constructively, depending on what you mean by finite.
(deleted)
Graham Manuell said:
Yes, though I think the finite version does hold constructively, depending on what you mean by finite.
Ah interesting! Even as I wrote I wondered whether small=finite is okay! :)
I wonder that too!
The point is that if and are Bishop-finite and then can't inject into even constructively since we have for .