Category Theory
Zulip Server
Archive

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.


Stream: learning: questions

Topic: sum, zero, copy, discard


view this post on Zulip Paolo Perrone (Nov 27 2021 at 10:45):

Hi all. I've come across the following phenomenon, which looks like a sort of duality. Can someone tell me if it is an instance of something known?

Let X={x,y,z}X=\{x,y,z\} and A={a,b,c}A=\{a,b,c\} be sets. Consider the function f:XAf:X\to A given by f(x)=af(x)=a and f(y)=f(z)=bf(y)=f(z)=b.
Consider now a (discrete) distribution pp on XX, with values p(x),p(y),p(z)p(x),p(y),p(z). The push-forward distribution fpf_*p on AA is as follows: fp(a)=p(x)f_*p(a)=p(x), fp(b)=p(y)+p(z)f_*p(b)=p(y)+p(z), fp(c)=0f_*p(c)=0. In other words, the pushforward distribution fpf_*p looks at what happens in the ff-preimage of a given point of AA, it sums whatever is in there in case the preimage is not a single point, and it gives zero if the preimage is empty. So the commutative monoid structure of RR (where distributions take values) is showing up.

Now consider a function g:ARg:A\to R, with values g(a),g(b),g(c)g(a), g(b), g(c). We can pull back the function to XX by precomposition, that is, forming fg=gf:XRf^*g=g\circ f:X\to R. In this case we have that fg(x)=g(a)f^*g(x)=g(a) and fg(y)=fg(z)=g(b)f^*g(y)=f^*g(z)=g(b). In other words, the pullback function fgf^*g looks at what happens in the ff-image of a given point of XX, it copies the value to all the elements of the preimage in case there is not a single point, and it discards that value (for example, g(c)g(c)) in case the preimage is empty. So the commutative comonoid structure of RR is showing up.

What kind of duality is this?

view this post on Zulip Morgan Rogers (he/him) (Nov 27 2021 at 12:05):

If RR has both structures and they're compatible (something Hopf algebra-ish, say), you might hope that these operations are adjoint to one another somehow. This construction only really works as stated for functions between finite sets and quite special RR; both parts can be adapted to infinite situations but the operations become a lot more subtle!

view this post on Zulip Robin Piedeleu (Nov 29 2021 at 10:45):

I can think of a category in which there is a known duality between the monoid and comonoid structures you point out: if RR is a field, swapping addition/zero with copy/discard gives a duality on RR-linear relations, i.e., those relations RnRmR^n\rightarrow R^m that are linear subspaces of Rn+mR^{n+m}. The duality becomes obvious when working with a presentation of this (symmetric monoidal) category, such as the one in this paper, where addition/zero are the white nodes and copy/discard are the black nodes. Then, swapping the two colours defines a (self-)duality! One explanation for why this works is that all the equations involving these two structures are completely symmetric, a somewhat mysterious fact already pointed out by @Pawel Sobocinski in this blog post for example.

view this post on Zulip Robin Piedeleu (Nov 29 2021 at 10:46):

Now I'm not sure precisely how it is related to what you've pointed out, but there must be a similar underlying explanation hiding somewhere.

view this post on Zulip Robin Piedeleu (Nov 29 2021 at 10:49):

In fact, all the objects you're working with live in this category - the distributions are just vectors and the set maps are maps between the canonical bases, which are all certainly RR-linear relations - so it might not be so hard to make sense of what you've noticed in those terms

view this post on Zulip Robin Piedeleu (Nov 29 2021 at 10:52):

Oh, and isn't the pullback given by the transpose of the relevant map, seen as a matrix? In the associated graphical language, the transpose is realised by colour-swap (followed by taking the converse relation) so that would explain it

view this post on Zulip Andrea Gentili (Nov 29 2021 at 14:45):

Not quite what you're after in terms of algebraic structures, but if you categorify (in the sense that you see AA and XX as discrete categories and substitute the monoid RR with a category with objects the elements of RR and such that the coproduct corresponds to the sum in RR and the initial object to 0), then your map fpf_\ast p is the left Kan extension of pp with respect to ff, so that your two constructions amount to the usual direct and inverse image of presheaves, and the duality is indeed given by an adjunction.

(I'm not sure at all that any monoid can be categorified in this sense, but one can always work with the monoid freely generated by the elements of RR, through which any pp naturally factorizes)