## The Theory of Devices

I’m visiting the University of Genoa and talking to two category theorists: Marco Grandis and Giuseppe Rosolini. Grandis works on algebraic topology and higher categories, while Rosolini works on the categorical semantics of programming languages.

Yesterday, Marco Grandis showed me a fascinating paper by his thesis advisor:

• Gabriele Darbo, Aspetti algebrico-categoriali della teoria dei dispotivi, Symposia Mathematica IV (1970), Istituto Nazionale di Alta Matematica, 303–336.

It’s closely connected to Brendan Fong’s thesis, but also different—and, of course, much older. According to Grandis, Darbo was the first person to work on category theory in Italy. He’s better known for other things, like ‘Darbo’s fixed point theorem’, but this piece of work is elegant, and, it seems to me, strangely ahead of its time.

The paper’s title translates as ‘Algebraic-categorical aspects of the theory of devices’, and its main concept is that of a ‘universe of devices’: a collection of devices of some kind that can be hooked up using wires to form more devices of this kind. Nowadays we might study this concept using operads—but operads didn’t exist in 1970, and Darbo did quite fine without them.

The key is the category $\mathrm{FinCorel},$ which has finite sets as objects and ‘corelations’ as morphisms. I explained corelations here:

Corelations in network theory, 2 February 2016.

Briefly, a corelation from a finite set $X$ to a finite set $Y$ is a partition of the disjoint union of $X$ and $Y.$ We can get such a partition from a bunch of wires connecting points of $X$ and $Y.$ The idea is that two points lie in the same part of the partition iff they’re connected, directly or indirectly, by a path of wires. So, if we have some wires like this:

they determine a corelation like this:

There’s an obvious way to compose corelations, giving a category $\mathrm{FinCorel}.$

Gabriele Darbo doesn’t call them ‘corelations’: he calls them ‘trasduttori’. A literal translation might be ‘transducers’. But he’s definitely talking about corelations, and like Fong he thinks they are basic for studying ways to connect systems.

Darbo wants a ‘universe of devices’ to assign to each finite set $X$ a set $D(X)$ of devices having $X$ as their set of ‘terminals’. Given a device in $D(X)$ and a corelation $f \colon X \to Y,$ thought of as a bunch of wires, he wants to be able to attach these wires to the terminals in $X$ and get a new device with $Y$ as its set of terminals. Thus he wants a map $D(f): D(X) \to D(Y).$ If you draw some pictures, you’ll see this should give a functor

$D : \mathrm{FinCorel} \to \mathrm{Set}$

Moreover, if we have device with a set $X$ of terminals and a device with a set $Y$ of terminals, we should be able to set them side by side and get a device whose set of terminals form the set $X + Y$, meaning the disjoint union of $X$ and $Y.$ So, Darbo wants to have maps

$\delta_{X,Y} : D(X) \times D(Y) \to D(X + Y)$

If you draw some more pictures you can convince yourself that $\delta$ should be a lax symmetric monoidal functor… if you’re one of the lucky few who knows what that means. If you’re not, you can look it up in many places, such as Section 1.2 here:

• Brendan Fong, The Algebra of Open and Interconnected Systems, Ph.D. thesis, University of Oxford, 2016. (Blog article here.)

Darbo does not mention lax symmetric monoidal functors, perhaps because such concepts were first introduced by Mac Lane only in 1968. But as far as I can tell, Darbo’s definition is almost equivalent to this:

Definition. A universe of devices is a lax symmetric monoidal functor $D \colon \mathrm{FinCorel} \to \mathrm{Set}.$

One difference is that Darbo wants there to be exactly one device with no terminals. Thus, he assumes $D(\emptyset)$ is a one-element set, say $1$, while the definition above would only demand the existence of a map $\delta \colon 1 \to D(\emptyset)$ obeying a couple of axioms. That gives a particular ‘favorite’ device with no terminals. I believe we get Darbo’s definition from the above one if we further assume $\delta$ is the identity map. This makes sense if we take the attitude that ‘a device is determined by its observable behavior’, but not otherwise. This attitude is called ‘black-boxing’.

Darbo does various things in his paper, but the most exciting to me is his example connected to linear electrical circuits. He defines, for any pair of objects $V$ and $I$ in an abelian category $C,$ a particular universe of devices. He calls this the universe of linear devices having $V$ as the object of potentials and $I$ as the object of currents.

If you don’t like abelian categories, think of $C$ as the category of finite-dimensional real vector spaces, and let $V = I = \mathbb{R}.$ Electric potential and electric current are described by real numbers so this makes sense.

The basic idea will be familiar to Fong fans. In an electrical circuit made of purely conductive wires, when two wires merge into one we add the currents to get the current on the wire going out. When one wire splits into two we duplicate the potential to get the potentials on the wires going out. Working this out further, any corelation $f : X \to Y$ between finite set determines two linear relations, one

$f_* : I^X \rightharpoonup I^Y$

relating the currents on the wires coming in to the currents on the wires going out, and one

$f^* : V^Y \rightharpoonup V^X$

relating the potentials on the wires going out to the potentials on the wires coming in. Here $I^X$ is the direct sum of $X$ copies of $I,$ and so on; the funky arrow indicates that we have a linear relation rather than a linear map. Note that $f_*$ goes forward while $f^*$ goes backward; this is mainly just conventional, since you can turn linear relations around, but we’ll see it’s sort of nice.

If we let $\mathrm{Rel}(A,B)$ be the set of linear relations between two objects $A, B \in C,$ we can use the above technology to get a universe of devices where

$D(X) = \mathrm{Rel}(V^X, I^X)$

In other words, a device of this kind is simply a linear relation between the potentials and currents at its terminals!

How does $D$ get to be a functor $D : \mathrm{FinCorel} \to \mathrm{FinSet}$? That’s pretty easy. We’ve defined it on objects (that is, finite sets) by the above formula. So, suppose we have a morphism (that is, a corelation) $f \colon X \to Y.$ How do we define $D(f) : D(X) \to D(Y)?$

To answer this question, we need a function

$D(f) : \mathrm{Rel}(V^X, I^X) \to \mathrm{Rel}(V^Y, I^Y)$

Luckily, we’ve got linear relations

$f_* : I^X \rightharpoonup I^Y$

and

$f^* : V^Y \rightharpoonup V^X$

So, given any linear relation $R \in \mathrm{Rel}(V^X, I^X),$ we just define

$D(f)(R) = f_* \circ R \circ f^*$

Voilà!

People who have read Fong’s thesis, or my paper with Blake Pollard on reaction networks:

• John Baez and Blake Pollard, A compositional framework for reaction networks.

will find many of Darbo’s ideas eerily similar. In particular, the formula

$D(f)(R) = f_* \circ R \circ f^*$

appears in Lemma 16 of my paper with Blake, where we are defining a category of open dynamical systems. We prove that $D$ is a lax symmetric monoidal functor, which is just what Darbo proved—though in a different context, since our $R$ is not linear like his, and for a different purpose, since he’s trying to show $D$ is a ‘universe of devices’, while we’re trying to construct the category of open dynamical systems as a ‘decorated cospan category’.

In short: if this work of Darbo had become more widely known, the development of network theory could have been sped up by three decades! But there was less interest in a general theory of networks at the time, lax monoidal functors were brand new, operads unknown… and, sadly, few mathematicians read Italian.

Darbo has other papers, and so do his students. We should read them and learn from them! Here are a few open-access ones:

• Franco Parodi, Costruzione di un universo di dispositivi non lineari su una coppia di gruppi abeliani, Rendiconti del Seminario Matematico della Università di Padova 58 (1977), 45–54.

• Franco Parodi, Categoria degli universi di dispositivi e categoria delle T-algebre, Rendiconti del Seminario Matematico della Università di Padova 62 (1980), 1–15.

• Stefano Testa, Su un universo di dispositivi monotoni, Rendiconti del Seminario Matematico della Università di Padova 65 (1981), 53–57.

At some point I will scan in G. Darbo’s paper and make it available here.

### 7 Responses to The Theory of Devices

1. Alsn Davis says:

This is all far beyond my mathematical knowledge, but it did remind me of something silly I’ll risk sharing. It relates to devices in the everyday sense.

Davis’s law of small devices:
A device can be made arbitrarily small if it doesn’t have to work.

2. Martin Rubey says:

If I’m not mistaken, $\mathrm{FinCorel}$ is also known as the partition category. The corresponding algebra (a splendid survey is by Halverson and Ram, https://arxiv.org/abs/math/0401314), where you only consider morphisms between sets of a fixed size $r$, is the centralizer algebra $\mathrm{End}_{\mathfrak S_n}(V^{\otimes r})$ of the symmetric group, $V$ being its defining representation, when $n$ is at least $2r$.

More precisely, when you compose two morphisms, some blocks may lose contact to the input and the output. In this case, these blocks (let’s say there are $k$ of them) are omitted and the result is multiplied with the $k$-th power of a parameter, usually denoted $\delta$.

When $n$ is small, there is a basis of the centralizer algebra indexed (!) by set partitions into at most $n$ blocks.

Still, there are some mysterious open questions…

• John Baez says:

Hey, that’s cool! I hadn’t thought of linearizing this category! This is connected to Blake Stacey’s comment on taking formal linear combinations of morphisms in a category to get a new ‘linear’ category. It’s nice how the representation theory of the symmetric group shows up here. This could be pretty important, at least in applications of network theory to linear systems.

By the way, to use TeX here, you have to enclose the math with

$latex$

with the word ‘latex’ appearing directly after the first dollar sign, no space between, but then a space after it.

• Martin Rubey says:

Indeed, the idea of Blake Stacey is what Bruce and I try to expand upon in https://arxiv.org/abs/1408.3592 – warning: this paper is still work in progress…

(thank you for fixing my syntax!)

• John Baez says:

Nice! I hadn’t known, or had forgotten, that you are collaborating with Bruce Westbury. I really like his paper on a diagrammatic approach to normed division algebras (or more precisely, composition algebras).

3. Refurio Anachro says:

Nice paper, Martin Rubey, thanks!

• Martin Rubey says:

Thank you! Just very recently, Georgia Benkart and Tom Halverson got a step further: https://arxiv.org/abs/1707.01410

I am still trying to figure out a refinement, I hope I’ll manage!

This site uses Akismet to reduce spam. Learn how your comment data is processed.