The more legs the merrier: A new composition for symmetric (multi-)lenses

Michael Johnson
(Macquarie University)
Robert Rosebrugh
(Mount Allison University)

Lenses are a category theoretic construct and are used in a wide variety of applications. Symmetric lenses compose to, of course, form new symmetric lenses. Symmetric lenses are usually represented as spans of asymmetric lenses. In many applications, the fact that a symmetric lens might also be represented as a cospan of asymmetric lenses is important, especially for implementation purposes. However, the composition of symmetric lenses does not preserve the property that the lenses can be represented by cospans — two such symmetric lenses may (and frequently do) compose to form a symmetric lens which cannot be represented as a cospan of asymmetric lenses. Thus preserving the factorisation to show how cospans of asymmetric lenses might be used in implementations becomes important. In 2018, the first work on multilenses was begun. Multilenses can be represented as multi-spans of asymmetric lenses (often called 'wide spans', these are spans with an arbitrary finite number of legs). In this paper we analyse a small but realistic example of a supply chain in which the cospan representations would be 'composed away' by ordinary symmetric lens composition, and introduce a new kind of composition which we call 'fusion' in which two ordinary symmetric lenses (spans with two legs) fuse to form a multilens with three legs preserving the cospan representations, and more generally, two symmetric multilenses, spans with say m and n legs, fuse to form a symmetric multilens with m+n-1 legs, again preserving cospan representations.

In David I. Spivak and Jamie Vicary: Proceedings of the 3rd Annual International Applied Category Theory Conference 2020 (ACT 2020), Cambridge, USA, 6-10th July 2020, Electronic Proceedings in Theoretical Computer Science 333, pp. 92–107.
Published: 8th February 2021.

ArXived at: bibtex PDF
References in reconstructed bibtex, XML and HTML format (approximated).
Comments and questions to:
For website issues: