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.
Nima Motamed said:
I would be glad to; though it might be best to talk about the basics and specifics of modal logic, coalgebra and coalgebraic logic in a different topic, so the focus here can stay on applications of the Yoneda lemma. I'll answer the following here though, just for clarity :)
Wonderful!
In this thread, I am hoping we can ask and answer questions regarding the basics of modal logic, coalgebras and coalgebraic logic - at least enough to understand @Nima Motamed's example application of the Yoneda lemma in #learning: questions > yoneda lemma applications .
(I'll post some specific questions here later today! Hopefully we can have an interesting discussion).
The first question I have is: What is a coalgebra?
I found a definition in "Coalgebraic logic" by Moss (p. 288):
A coalgebra for an endofunctor is a pair such that is a set or class, together with a map . is called the carrier, and is the coalgebra map.
Would this be called an -coalgebra? (I think so!)
Take Kripke frames, which are just unlabelled non-deterministic transition systems, or more simply just binary relations on a set . Such a binary relation can equivalently be treated as a function , with , i.e. the set of all successor states of .
Let me see if I can understand how this is a coalgebra. We start with the functor that sends any set to its powerset, and any function to the corresponding function between powersets (that sends any subset to the image of that subset under ).
A -coalgebra I think is a pair where is a set and is a map . This is indeed what we have - the map sends any given state to the set of successor states. (Here is a set of states).
So, we do indeed have a -coalgebra.
Nima Motamed said:
If you would be interested in deterministic automata for some alphabet , then you can verify that these are precisely coalgebras for the functor , ignoring the requirements of a finite set of states and a distinguished initial state.
Let's see if I can now understand this^.
Let be a functor that acts on objects by . Then, a -coalgebra is a pair , where is a set and is a map .
Here is a set of states. What is ? It is a map .
Say we evaluate on some particular state . Then . I think this can be viewed as describing the way in which the system moves to the next state from . To start with, the first part of is a function from (which might be a set of possible inputs) to , the possible states. So, this part of can be viewed as describing which state is next after , and this next state is allowed to depend on inputs provided. I'm not sure what the part does - I suppose it could be viewed as providing some kind of label for the "kind" of the next state?
David Egolf said:
The first question I have is: What is a coalgebra?
I found a definition in "Coalgebraic logic" by Moss (p. 288):
A coalgebra for an endofunctor is a pair such that is a set or class, together with a map . is called the carrier, and is the coalgebra map.
Just to warn you, "coalgebra" means three main things:
1) a "coalgebra of a functor", which you've described: nice and simple.
2) a "coalgebra of a comonad", which is very much like an algebra of a monad, but with all the arrows turned around.
2) to algebraists, a "coalgebra" is a monoid in just as an "algebra" is a monoid in . For example, the vector space of matrices is an algebra with the usual matrix multiplication, but there's also a way to make it into a coalgebra.
You definitely don't want to learn all three of these things at once! You can probably ignore two of them. I only mention them because for beginners it can be confusing that different people use the word "coalgebra" in different ways, when they're looking around online.
You probably picked the right one to focus on, number 1), though of course @Nima Motamed will be the one who knows what he wants to talk about.
Number 2) may also show up at some point in your studies with Nima; hard to tell.
It's delightful how all 3 fit together in the end, but don't think about that. :upside_down:
I appreciate the warning/clarification! Googling the term "coalgebra" was indeed rather confusing.
About what the part does: The composite map (second arrow the projection) singles out a subset of , the set of "accepted states". The idea is that the automaton reads a string of symbols from the alphabet, symbol by symbol, and if it ends in an accepted state, the string is accepted.
In detail: You start in a starting state. You apply the map (first projection this time) to your current state and get a map . You read a symbol from your string and apply that map to it. You go into the new state you obtained. You repeat this until your string of symbols ends. Then you apply and see if you get (i.e. whether you are in a an accepted state). If yes, the string is accepted, otherwise not. In this way automata define subsets of the set of all words over the alphabet (e.g. the well-formed formulas of a logic, or the syntactically correct programs in some programming language).
David Egolf said:
The first question I have is: What is a coalgebra?
I found a definition in "Coalgebraic logic" by Moss (p. 288):
A coalgebra for an endofunctor is a pair such that is a set or class, together with a map . is called the carrier, and is the coalgebra map.
John Baez said:
Just to warn you, "coalgebra" means three main things:
1) a "coalgebra of a functor", which you've described: nice and simple.
2) a "coalgebra of a comonad", which is very much like an algebra of a monad, but with all the arrows turned around.
2) to algebraists, a "coalgebra" is a monoid in just as an "algebra" is a monoid in . For example, the vector space of matrices is an algebra with the usual matrix multiplication, but there's also a way to make it into a coalgebra.
You definitely don't want to learn all three of these things at once! You can probably ignore two of them. I only mention them because for beginners it can be confusing that different people use the word "coalgebra" in different ways, when they're looking around online.
You probably picked the right one to focus on, number 1), though of course Nima Motamed will be the one who knows what he wants to talk about.
Indeed. Sorry I didn't specify the type of coalgebra I meant - that is very confusing. While all three notions mentioned by @John Baez are highly related, it is most relevant to the examples we've been discussing to stick to the simple definition of a -coalgebra for a general functor , which is the definition you found in Moss' work. The coalgebraic logic he speaks of is by the way not precisely of the same flavor of logic I was talking about - his logic is truly beautiful, but also very strange, at least when you first encounter it. I'd love to also chat about that, but I don't think it would aid in understanding coalgebraic logic right now :)
David Egolf said
Let me see if I can understand how this is a coalgebra. We start with the functor that sends any set to its powerset, and any function to the corresponding function between powersets (that sends any subset to the image of that subset under ).
A -coalgebra I think is a pair where is a set and is a map . This is indeed what we have - the map sends any given state to the set of successor states. (Here is a set of states).
So, we do indeed have a -coalgebra.
Precisely!
Let's see if I can now understand this^.
@Peter Arndt explained this perfectly - I hope that helps, and if not, give a shout.
I don't want to push any material on you and risk not matching the pace at which you'd like to explore all of this, so please feel free to ask any questions - coalgebra and coalgebraic logic are honestly some of my favorite branches of mathematics/logic, so it's always great to have an excuse to talk about them. (This also increases the risk of me dumping a tidal wave of information on you, hence why I'm being a bit careful ;) )
Until you come with questions, I do want to point you towards some excellent, detailed and approachable material on the subject, all of which is freely and legally available online.
For the general theory of coalgebra (for a functor), also referred to as universal coalgebra, Jan Rutten's most recent book is hard to beat. He focuses on coalgebras for -functors, and provides a good amount of examples of dynamical systems that can be studied through the coalgebraic lens.
If you then want to look at the interplay between coalgebra and (modal) logic, this article, written by several coalgebraic logicians, gives a nice conceptual introduction to a broad audience. I am a big fan of one of the arguments they give for the use of coalgebraic logic: whenever you are considering a new type of transition structure and/or its logic, you can often just plug it into the general theory of coalgebraic logic, and get a bunch of definitions, theorems and even algorithms for free! Coalgebra and coalgebraic logic find a lot of their strength in this plug-and-play approach.
Finally, if you want to get into the more technical side of coalgebraic logic, there's this article by Clemens Kupke and Dirk Pattinson.
There's of course a lot more material to be found than this -the rabbit hole goes deep, moving through (Stone) duality theory and factorization systems- but the articles I mentioned give a strong, and more importantly pleasant introduction.
Thanks for the wonderful recommendations, @Nima Motamed ! I started looking at Rutten's book , and it looks excellent.
I don't have a specific question for you right now. However, I wanted to express how cool the idea of an "algebra" is, as introduced in that book!
Before Rutten's book defines a coalgebra, it defines an algebra:
"Let be a functor from a category to itself. An -algebra is a pair consisting of an object an arrow ".
This seems like an amazing framework for making your own algebraic structures!
For example, say we want an algebraic structure corresponding to a binary operation on the real numbers, together with some distinguished element of the real numbers. Then, we could consider maps of the form: , where + is the disjoint union, and 1 is a set with a single element.
is a function that takes in an element from 1 OR an element from , and returns a real number. So, it contains information about two maps: and . It describes both a distinguished element of and a binary operation on . Maps of this form will corresponds to -algebras, where for a set .
This strategy for thinking about algebraic structures also lets one start with a functor of interest and then ask what an -algebra would correspond to. For example, in the context of imaging, say sends a set to the set of "observations" of its elements . Then an -algebra would correspond to a map for some set , which sends observations to (perhaps) estimates for unknown objects. I guess a -coalgebra in this case would be a map that sends set elements to their observations. In imaging system in general is going to have both of these. (This makes me wonder if morphisms of algebras and morphisms of coalgebras would correspond to an interesting way to relate image reconstruction schemes, and observation schemes, respectively).
It feels exciting to have a clean framework to describe and generate custom algebraic structures in terms of functors!
It seems like coalgebras correspond to components of a particular kind of natural transformation.
Let be a functor and be the identity functor.
Let be a natural transformation.
Then the component of for a set is a function . This is a coalgebra .
Also, if and are components of , and there is a function , I believe there is a morphism of coalgebras between and corresponding to . The existence of this morphism (a commutative square) corresponds to the fact that is a natural transformation.
I suppose this means we can view this kind of natural transformation as corresponding to a collection of coalgebras, and morphisms between them. Does this seem right? (If so - do we care about this connection?)