Seven Sketches in Compositionality an Invitation to Applied Category Theory

Total Page:16

File Type:pdf, Size:1020Kb

Seven Sketches in Compositionality an Invitation to Applied Category Theory Seven Sketches in Compositionality An Invitation to Applied Category Theory IAP 2019 – 18.S097 Summary: Category theory is a relatively new branch of mathematics that has ​ transformed much of pure math research. The technical advance is that category theory provides a framework in which to organize formal systems and translate between them, allowing one to transfer knowledge from one field to another. But the same organizational framework also has many compelling examples outside of pure math. In this course, we will give seven sketches about real-world applications of category theory. We’ll teach from our recent book on the subject, which is available online (https://arxiv.org/abs/1803.05316). Dates: January 14 – February 1, 2019 Time: 2:00 – 3:00 pm, MTWRF Location: Room 2-142 ​ Instructors: David Spivak and Brendan Fong Credit/audit: For credit (3 units), sign up for 18.S097. You are also invited to audit. URL: http://brendanfong.com/7sketches.html Seven Sketches in Compositionality An Invitation to Applied Category Theory IAP 2019 – 18.S097 Applications Category theoretic notions Cascade effects Posets and adjunctions Resource theory Monoidal posets and categorification Data transformation Categories, functors, and universal constructions Collaborative design Enriched categories and profunctors Signal flow graphs Props and graphical proof systems Electrical circuits Wiring diagrams, operads, and functorial semantics A logic of behavior Sheaves, toposes, and internal languages Dates: January 14 – February 1, 2019 Time: 2:00 – 3:00 pm, MTWRF Location: Room 2-142 ​ Instructors: David Spivak and Brendan Fong Credit/audit: For credit (3 units), sign up for 18.S097. You are also invited to audit. URL: http://brendanfong.com/7sketches.html .
Recommended publications
  • The ACT Pipeline from Abstraction to Application
    Addressing hypercomplexity: The ACT pipeline from abstraction to application David I. Spivak (Joint with Brendan Fong, Paolo Perrone, Evan Patterson) Department of Mathematics Massachusetts Institute of Technology 0 / 25 Introduction Outline 1 Introduction Why? How? What? Plan of the talk 2 Some new applications 3 Catlab.jl 4 Conclusion 0 / 25 Introduction Why? What's wrong? As problem complexity increases, good organization becomes crucial. (Courtesy of Spencer Breiner, NIST) 1 / 25 Introduction Why? The problem is hypercomplexity The world is becoming more complex. We need to deal with more and more diverse sorts of interaction. Rather than closed dynamical systems, everything is open. The state of one system affects those of systems in its environment. Examples are everywhere. Designing anything requires input from more diverse stakeholders. Software is developed by larger teams, touching a common codebase. Scientists need to use experimental data obtained by their peers. (But the data structure and assumptions don't simply line up.) We need to handle this new complexity; traditional methods are faltering. 2 / 25 Introduction How? How might we deal with hypercomplexity? Organize the problem spaces effectively, as objects in their own right. Find commonalities in the various problems we work on. Consider the ways we build complex problems out of simple ones. Think of problem spaces and solutions as mathematical entities. With that in hand, how do you solve a hypercomplex problem? Migrating subproblems to groups who can solve them. Take the returned solutions and fit them together. Ensure in advance that these solutions will compose. Do this according the mathematical problem-space structure.
    [Show full text]
  • Diagrammatics in Categorification and Compositionality
    Diagrammatics in Categorification and Compositionality by Dmitry Vagner Department of Mathematics Duke University Date: Approved: Ezra Miller, Supervisor Lenhard Ng Sayan Mukherjee Paul Bendich Dissertation submitted in partial fulfillment of the requirements for the degree of Doctor of Philosophy in the Department of Mathematics in the Graduate School of Duke University 2019 ABSTRACT Diagrammatics in Categorification and Compositionality by Dmitry Vagner Department of Mathematics Duke University Date: Approved: Ezra Miller, Supervisor Lenhard Ng Sayan Mukherjee Paul Bendich An abstract of a dissertation submitted in partial fulfillment of the requirements for the degree of Doctor of Philosophy in the Department of Mathematics in the Graduate School of Duke University 2019 Copyright c 2019 by Dmitry Vagner All rights reserved Abstract In the present work, I explore the theme of diagrammatics and their capacity to shed insight on two trends|categorification and compositionality|in and around contemporary category theory. The work begins with an introduction of these meta- phenomena in the context of elementary sets and maps. Towards generalizing their study to more complicated domains, we provide a self-contained treatment|from a pedagogically novel perspective that introduces almost all concepts via diagrammatic language|of the categorical machinery with which we may express the broader no- tions found in the sequel. The work then branches into two seemingly unrelated disciplines: dynamical systems and knot theory. In particular, the former research defines what it means to compose dynamical systems in a manner analogous to how one composes simple maps. The latter work concerns the categorification of the slN link invariant. In particular, we use a virtual filtration to give a more diagrammatic reconstruction of Khovanov-Rozansky homology via a smooth TQFT.
    [Show full text]
  • Category Theory Cheat Sheet
    Musa Al-hassy https://github.com/alhassy/CatsCheatSheet July 5, 2019 Even when morphisms are functions, the objects need not be sets: Sometimes the objects . are operations —with an appropriate definition of typing for the functions. The categories Reference Sheet for Elementary Category Theory of F -algebras are an example of this. “Gluing” Morphisms Together Categories Traditional function application is replaced by the more generic concept of functional A category C consists of a collection of “objects” Obj C, a collection of “(homo)morphisms” composition suggested by morphism-arrow chaining: HomC(a; b) for any a; b : Obj C —also denoted “a !C b”—, an operation Id associating Whenever we have two morphisms such that the target type of one of them, say g : B A a morphism Ida : Hom(a; a) to each object a, and a dependently-typed “composition” is the same as the source type of the other, say f : C B then “f after g”, their composite operation _ ◦ _ : 8fABC : Objg ! Hom(B; C) ! Hom(A; B) ! Hom(A; C) that is morphism, f ◦ g : C A can be defined. It “glues” f and g together, “sequentially”: required to be associative with Id as identity. It is convenient to define a pair of operations src; tgt from morphisms to objects as follows: f g f◦g C − B − A ) C − A composition-Type f : X !C Y ≡ src f = X ^ tgt f = Y src; tgt-Definition Composition is the basis for gluing morphisms together to build more complex morphisms. Instead of HomC we can instead assume primitive a ternary relation _ : _ !C _ and However, not every two morphisms can be glued together by composition.
    [Show full text]
  • SHEAVES, TOPOSES, LANGUAGES Acceleration Based on A
    Chapter 7 Logic of behavior: Sheaves, toposes, and internal languages 7.1 How can we prove our machine is safe? Imagine you are trying to design a system of interacting components. You wouldn’t be doing this if you didn’t have a goal in mind: you want the system to do something, to behave in a certain way. In other words, you want to restrict its possibilities to a smaller set: you want the car to remain on the road, you want the temperature to remain in a particular range, you want the bridge to be safe for trucks to pass. Out of all the possibilities, your system should only permit some. Since your system is made of components that interact in specified ways, the possible behavior of the whole—in any environment—is determined by the possible behaviors of each of its components in their local environments, together with the precise way in which they interact.1 In this chapter, we will discuss a logic wherein one can describe general types of behavior that occur over time, and prove properties of a larger-scale system from the properties and interaction patterns of its components. For example, suppose we want an autonomous vehicle to maintain a distance of some safe R from other objects. To do so, several components must interact: a 2 sensor that approximates the real distance by an internal variable S0, a controller that uses S0 to decide what action A to take, and a motor that moves the vehicle with an 1 The well-known concept of emergence is not about possibilities, it is about prediction.
    [Show full text]
  • UNIVERSITY of CALIFORNIA RIVERSIDE the Grothendieck
    UNIVERSITY OF CALIFORNIA RIVERSIDE The Grothendieck Construction in Categorical Network Theory A Dissertation submitted in partial satisfaction of the requirements for the degree of Doctor of Philosophy in Mathematics by Joseph Patrick Moeller December 2020 Dissertation Committee: Dr. John C. Baez, Chairperson Dr. Wee Liang Gan Dr. Carl Mautner Copyright by Joseph Patrick Moeller 2020 The Dissertation of Joseph Patrick Moeller is approved: Committee Chairperson University of California, Riverside Acknowledgments First of all, I owe all of my achievements to my wife, Paola. I couldn't have gotten here without my parents: Daniel, Andrea, Tonie, Maria, and Luis, or my siblings: Danielle, Anthony, Samantha, David, and Luis. I would like to thank my advisor, John Baez, for his support, dedication, and his unique and brilliant style of advising. I could not have become the researcher I am under another's instruction. I would also like to thank Christina Vasilakopoulou, whose kindness, energy, and expertise cultivated a deeper appreciation of category theory in me. My expe- rience was also greatly enriched by my academic siblings: Daniel Cicala, Kenny Courser, Brandon Coya, Jason Erbele, Jade Master, Franciscus Rebro, and Christian Williams, and by my cohort: Justin Davis, Ethan Kowalenko, Derek Lowenberg, Michel Manrique, and Michael Pierce. I would like to thank the UCR math department. Professors from whom I learned a ton of algebra, topology, and category theory include Julie Bergner, Vyjayanthi Chari, Wee-Liang Gan, Jos´eGonzalez, Jacob Greenstein, Carl Mautner, Reinhard Schultz, and Steffano Vidussi. Special thanks goes to the department chair Yat-Sun Poon, as well as Margarita Roman, Randy Morgan, and James Marberry, and many others who keep the whole thing together.
    [Show full text]
  • Mathematics and the Brain: a Category Theoretical Approach to Go Beyond the Neural Correlates of Consciousness
    entropy Review Mathematics and the Brain: A Category Theoretical Approach to Go Beyond the Neural Correlates of Consciousness 1,2,3, , 4,5,6,7, 8, Georg Northoff * y, Naotsugu Tsuchiya y and Hayato Saigo y 1 Mental Health Centre, Zhejiang University School of Medicine, Hangzhou 310058, China 2 Institute of Mental Health Research, University of Ottawa, Ottawa, ON K1Z 7K4 Canada 3 Centre for Cognition and Brain Disorders, Hangzhou Normal University, Hangzhou 310036, China 4 School of Psychological Sciences, Faculty of Medicine, Nursing and Health Sciences, Monash University, Melbourne, Victoria 3800, Australia; [email protected] 5 Turner Institute for Brain and Mental Health, Monash University, Melbourne, Victoria 3800, Australia 6 Advanced Telecommunication Research, Soraku-gun, Kyoto 619-0288, Japan 7 Center for Information and Neural Networks (CiNet), National Institute of Information and Communications Technology (NICT), Suita, Osaka 565-0871, Japan 8 Nagahama Institute of Bio-Science and Technology, Nagahama 526-0829, Japan; [email protected] * Correspondence: georg.northoff@theroyal.ca All authors contributed equally to the paper as it was a conjoint and equally distributed work between all y three authors. Received: 18 July 2019; Accepted: 9 October 2019; Published: 17 December 2019 Abstract: Consciousness is a central issue in neuroscience, however, we still lack a formal framework that can address the nature of the relationship between consciousness and its physical substrates. In this review, we provide a novel mathematical framework of category theory (CT), in which we can define and study the sameness between different domains of phenomena such as consciousness and its neural substrates. CT was designed and developed to deal with the relationships between various domains of phenomena.
    [Show full text]
  • Categorification of the Müller-Wichards System Performance Estimation Model: Model Symmetries, Invariants, and Closed Forms
    Article Categorification of the Müller-Wichards System Performance Estimation Model: Model Symmetries, Invariants, and Closed Forms Allen D. Parks 1,* and David J. Marchette 2 1 Electromagnetic and Sensor Systems Department, Naval Surface Warfare Center Dahlgren Division, Dahlgren, VA 22448, USA 2 Strategic and Computing Systems Department, Naval Surface Warfare Center Dahlgren Division, Dahlgren, VA 22448, USA; [email protected] * Correspondence: [email protected] Received: 25 October 2018; Accepted: 11 December 2018; Published: 24 January 2019 Abstract: The Müller-Wichards model (MW) is an algebraic method that quantitatively estimates the performance of sequential and/or parallel computer applications. Because of category theory’s expressive power and mathematical precision, a category theoretic reformulation of MW, i.e., CMW, is presented in this paper. The CMW is effectively numerically equivalent to MW and can be used to estimate the performance of any system that can be represented as numerical sequences of arithmetic, data movement, and delay processes. The CMW fundamental symmetry group is introduced and CMW’s category theoretic formalism is used to facilitate the identification of associated model invariants. The formalism also yields a natural approach to dividing systems into subsystems in a manner that preserves performance. Closed form models are developed and studied statistically, and special case closed form models are used to abstractly quantify the effect of parallelization upon processing time vs. loading, as well as to establish a system performance stationary action principle. Keywords: system performance modelling; categorification; performance functor; symmetries; invariants; effect of parallelization; system performance stationary action principle 1. Introduction In the late 1980s, D.
    [Show full text]
  • Constructing Symmetric Monoidal Bicategories Functorially
    Constructing symmetric monoidal bicategories. functorially Constructing symmetric monoidal bicategories functorially Michael Shulman Linde Wester Hansen AMS Sectional Meeting UC Riverside Applied Category Theory Special Session November 9, 2019 Constructing symmetric monoidal bicategories. functorially Outline 1 Constructing symmetric monoidal bicategories. 2 . functorially Constructing symmetric monoidal bicategories. functorially Symmetric monoidal bicategories Symmetric monoidal bicategories are everywhere! 1 Rings and bimodules 2 Sets and spans 3 Sets and relations 4 Categories and profunctors 5 Manifolds and cobordisms 6 Topological spaces and parametrized spectra 7 Sets and (decorated/structured) cospans 8 Sets and open Markov processes 9 Vector spaces and linear relations Constructing symmetric monoidal bicategories. functorially What is a symmetric monoidal bicategory? A symmetric monoidal bicategory is a bicategory B with 1 A functor ⊗: B × B ! B 2 A pseudonatural equivalence (A ⊗ B) ⊗ C ' A ⊗ (B ⊗ C) 3 An invertible modification ((AB)C)D (A(BC))D A((BC)D) π + (AB)(CD) A(B(CD)) 4 = 5 more data and axioms for units, braiding, syllepsis. Constructing symmetric monoidal bicategories. functorially Surely it can't be that bad In all the examples I listed before, the monoidal structures 1 tensor product of rings 2 cartesian product of sets 3 cartesian product of spaces 4 disjoint union of sets 5 ... are actually associative up to isomorphism, with strictly commuting pentagons, etc. But a bicategory doesn't know how to talk about isomorphisms, only equivalences! We need to add extra data: ring homomorphisms, functions, linear maps, etc. Constructing symmetric monoidal bicategories. functorially Double categories A double category is an internal category in Cat. It has: 1 objects A; B; C;::: 2 loose morphisms A −7−! B that compose weakly 3 tight morphisms A ! B that compose strictly 4 2-cells shaped like squares: A j / B : + C j / D No one can agree on which morphisms to draw horizontally or vertically.
    [Show full text]
  • Applied Category Theory in Data Science Evan Patterson Statistics Department, Stanford University
    Applied category theory in data science Evan Patterson Statistics Department, Stanford University Ioana Baldini, Aleksandra Mojsilovic, Kush R. Varshney IBM Research AI Applied Category Theory: Bridging Theory & Practice March 15-16, 2018, NIST, Gaithersburg, MD Problem: Program understanding for data science A classic, hard problem in AI: How can we teach machines to understand code, as opposed to merely executing it? We try to solve an incarnation of this problem in data science: How about understanding data analysis (in the form of computer code)? Our goals Technical. Form semantic representations of data analyses capturing: generic concepts of computing (functions, programs, etc.) domain-specic concepts of data science (data, models, prediction, etc.) Applications. Create an AI assistant for data scientists: Summarize data analyses in natural language text Discover related data sets or data analyses Automate meta-analysis and meta-learning Two examples Example 1: k-means clustering using NumPy and SciPy In [1]: import numpy as np from scipy.cluster.vq import kmeans2 iris = np.genfromtxt('iris.csv', dtype='f8', delimiter=',', skip_header=1) iris = np.delete(iris, 4, axis=1) centroids, clusters = kmeans2(iris, 3) Example 2: k-means clustering using pandas and scikit-learn In [2]: import pandas as pd from sklearn.cluster import KMeans iris = pd.read_csv('iris.csv') iris = iris.drop('Species', 1) kmeans = KMeans(n_clusters=3) kmeans.fit(iris.values) centroids = kmeans.cluster_centers_ clusters = kmeans.labels_ Demo: Semantic ow graphs Example 1: k-means clustering using SciPy Example 2: k-means clustering using scikit-learn The two examples have the same semantic representation. Methodology Derive semantic representation from computer program in two steps: 1.
    [Show full text]
  • Categories for Planning and Scheduling
    Categories for Planning and Scheduling Reactor Hold/Hold/ Hold/ Hold/ Hold/ Hold/ Blender Equipment Centrifuge Tote Hold Hold Hold Hold Hold Hold h 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 h 10 20 30 40 50 60 70 80 Spencer Breiner, Peter Denno, and Eswaran Subrahmanian 1. Introduction easier to digest. The presentation is not self-contained— Applied category theory is an ongoing effort to use the ab- we won’t review standard definitions of functors and nat- stract machinery of category theory (CT) to organize math- ural transformations—but we have tried to minimize our ematical knowledge across a wide range of science and reliance on prior knowledge. We recommend [Spi14] for engineering [BPS20]. Mostly this requires a change of fo- a more careful development. cus; the same tools designed to handle cohomology and Our primary goal is to demonstrate the capabilities of quantum groups fit surprisingly well with more down-to- category theory as a formal modeling language. It provides earth subjects like process planning and error diagnosis an extremely precise and expressive set of constructions [BJS19, BMRPS20]. both internally (within the model) and externally (in the This paper gives an introduction and case study in the meta-theory). The general principles are relevant for both use of CT for data modeling and transformation. The formal modeling languages like OWL, SysML or Modelica subject of the case study is a standard problem in oper- as well as generic modeling contexts like programming, ations research called open-shop scheduling.
    [Show full text]
  • Applied Category Theory
    Applied Category Theory John Baez We need a good mathematical theory of these. In many areas of science and engineering, people use diagrams of networks, with boxes connected by wires: In many areas of science and engineering, people use diagrams of networks, with boxes connected by wires: We need a good mathematical theory of these. Categories must be part of the solution. This became clear in the 1980s, at the interface of knot theory and quantum physics: Categories are great for describing processes of all kinds. A process with input x and output y is called a morphism F : x ! y, and we draw it like this: x F y The input and output are called objects. We can do one process after another if the output of the first equals the input of the second: x F y G z Here we are composing morphisms F : x ! y and G : y ! z to get a morphism GF : x ! z. In a monoidal category, we can also do processes `in parallel': x x0 F G y y 0 Here we are tensoring F : x ! y and G : x0 ! y 0 to get a morphism F ⊗ G : x ⊗ x0 ! y ⊗ y 0. In a braided monoidal category, we have a process of switching: x y y x This is called the braiding Bx;y : x ⊗ y ! y ⊗ x. It has an inverse: y x x y In a symmetric monoidal category it doesn't matter which wire goes over which: x y x y = y x y x All these kinds of categories obey some axioms, which are easy to find.
    [Show full text]
  • Diagrammatic Sets and Rewriting in Weak Higher Categories
    Diagrammatic sets and rewriting in weak higher categories Amar Hadzihasanovic IRIF, Universit´ede Paris GeoCat 2020 5 July 2020 arXiv:1909.07639 There is a draft, but I am rewriting it from scratch. Some definitions have changed. Some results I will mention do not hold with the old definitions. The new version should be out before the end of the month. There is a familiar world of spaces/1-groupoids/homotopy types in the background. Everything must be weak. n-categories in this world are (1; n)-categories. Do we really need to work in a specific model? If we do, it should feel familiar. Segal spaces, complicial sets... pick your favourite. Higher categories for all In homotopy theory, algebraic geometry, ...: Everything must be weak. n-categories in this world are (1; n)-categories. Do we really need to work in a specific model? If we do, it should feel familiar. Segal spaces, complicial sets... pick your favourite. Higher categories for all In homotopy theory, algebraic geometry, ...: There is a familiar world of spaces/1-groupoids/homotopy types in the background. Do we really need to work in a specific model? If we do, it should feel familiar. Segal spaces, complicial sets... pick your favourite. Higher categories for all In homotopy theory, algebraic geometry, ...: There is a familiar world of spaces/1-groupoids/homotopy types in the background. Everything must be weak. n-categories in this world are (1; n)-categories. If we do, it should feel familiar. Segal spaces, complicial sets... pick your favourite. Higher categories for all In homotopy theory, algebraic geometry, ...: There is a familiar world of spaces/1-groupoids/homotopy types in the background.
    [Show full text]