A denotational semantics for the symmetric interaction combinators

DAMIANO MAZZA
2007 Mathematical Structures in Computer Science  
The symmetric interaction combinators are a variant of Lafont's interaction combinators. They enjoy a weaker universality property with respect to interaction nets, but are equally expressive. They are a model of deterministic distributed computation, sharing the good properties of Turing machines (elementary reductions) and of the λ-calculus (higher-order functions, parallel execution). We introduce a denotational semantics for this system, inspired by the relational semantics for linear
more » ... proving an injectivity and full completeness result for it. We also consider the algebraic semantics defined by Lafont, and prove that the two are strongly related. Damiano Mazza 2 and can be turned into a practical (typed or untyped) programming language, in which important properties (like deadlock-freeness) are automatically checked through similar techniques to those used in linear logic (i.e., correctness criteria (Lafont, 1990) ). Among all interaction net systems, the interaction combinators (Lafont, 1997) stand out as particularly interesting, because they are universal, in the sense that all other interaction net systems can be "compiled" in them; again, this compilation process preserves the basic properties of parallelism and complexity of the original system. As a consequence, the interaction combinators can be seen as a computational model of its own, combining in some sense the good properties of Turing machines (local execution, transitions of elementary complexity, strong determinism) with those of the λ-calculus (higher-order functional programming, possibility of "parallelizing" the execution). From this it would appear that studying a denotational semantics for the interaction combinators may be, at least in principle, as interesting as studying the denotational semantics of the λ-calculus. And yet to this day there have been very few efforts in this direction; the only work dealing directly with the semantics of the interaction combinators is Lafont's original paper, in which a path semantics for nets of combinators is introduced, and an interpretation in terms of stack automata is given. Another contribution of semantical flavor is that of Maribel Fernández and Ian Mackie (Fernández and Mackie, 2003) , in which the fundamental operational equivalences for the interaction combinators are obtained as an application of more general results. Our work aims precisely at deepening the semantical study of the interaction combinators. In a previous paper (Mazza, 2006) , we have analyzed the notion of observational equivalence for nets of combinators. A congruence analogous to βη-equivalence is defined, and an internal separation result similar to Böhm's Theorem is proved for it. This paper takes this result as a basis for developing a denotational semantics, i.e., we find a mathematical structure in which βη-equivalence becomes an equality. More precisely, our semantics is inspired by the relational semantics for linear logic: nets are interpreted as subsets of a certain domain D, called interaction sets, which do not need to have any particular structure apart from the existence of two bijections between D × D and D itself, verifying a certain condition. As expected, this semantics is proved to be injective with respect to βη-equivalence, i.e., two nets are βη-equivalent if and only if they have the same semantical interpretation. Moreover, we prove a full-completeness result with respect to a certain class of subsets, called balanced, which is reminiscent of a similar result proved by Michele Pagani for multiplicative proof-nets (Pagani, 2006) . We also consider interaction sets with a minimum of algebraic structure, namely that of a monoid. These structures, called interaction monoids, have the property of naturally inducing an algebraic semantics for the combinators, which is a model of the geometry of interaction described by Lafont. In this semantics, a net µ is interpreted as a pair of monoid endomorphisms (u, σ), where σ = 0 (the everywhere-zero endomorphism) means that µ is in normal form. In case σ = 0, and if µ does have a normal form, the endomorphism interpreting it can be computed by means of Girard's execution formula Ex(u, σ). A Denotational Semantics for theSymmetric Interaction Combinators 3 The denotational and algebraic semantics are tightly connected to each other: we prove in fact that, if µ is a net admitting a normal form, given (u, σ), the denotational semantics of µ is equal to the submonoid of the fixpoints of Ex(u, σ); conversely, the denotational semantics of µ defines the endomorphism interpreting its normal form. There is an important technical point which must be clarified though: the semantics we discuss here does not deal with the interaction combinators, but with a slightly different variant, which we call the symmetric combinators. This interaction net system, also introduced by Lafont (Lafont, 1997) , is not universal in the same sense as the interaction combinators, but is just as expressive. In particular, every application of the interaction combinators found so far (for instance Mackie and Pinto's encoding of linear logic and the λ-calculus (Mackie and Pinto, 2002)) can be reformulated with virtually no change using the symmetric combinators. Of course, our work mentioned above on observational equivalence also applies mutatis mutandi to this system. By the way, the symmetric combinators are tightly connected to the directed combinators (Lafont, 1997) , which are an extension of multiplicative linear logic proof-structures, and may therefore have interesting logical properties. Contents of the paper. Section 2 contains the introductory material necessary to develop the rest of the paper. The exposition is as self-contained as possible, so even a reader completely unfamiliar with interaction nets should be able to follow the technical contents. In particular, in Sect. 2.4 we give an explicit proof of the expressiveness of the symmetric combinators, by encoding the SK combinators in them, and in Sect. 2.5 we briefly recall the main results of the above mentioned paper (Mazza, 2006) , which we use later in one of our proofs. Section 3 is the heart of the paper, and contains the definition of our denotational semantics, together with the injectivity and full completeness proofs. In Sect. 4 we introduce interaction monoids, and develop the algebraic semantics described in Lafont's original paper, proving the relationship between this and our denotational semantics. Section 5 concludes the paper with a discussion on the technical reasons behind our choice of the symmetric combinators instead of the "standard" interaction combinators, and gives some hints on future work. The symmetric interaction combinators Cells, wires, nets The symmetric interaction combinators, or, more simply, the symmetric combinators, are the three following cells: Each cell has a number of ports; δ and ζ have three, ε has only one. The fundamental property of cells is that exactly one of their ports is principal (drawn at the bottom in the above graphical representation), the others being auxiliary.
doi:10.1017/s0960129507006135 fatcat:56tymobe2jcjlb22yz466dvp74