Analysis-directed semantics

Size: px
Start display at page:

Download "Analysis-directed semantics"

Transcription

1 Analysis-directed semantics Dominic Orchard Imperial College London work in progress

2 Syntax directed e.g. (untyped) λ-calculus to reduction relation (λx. e 1 ) e 2 e 1 [x/e 2 ] e 1 e 1 e 1 e 2 e 1 e 2 2

3 Syntax-and-type directed e.g. simply-typed λ-calculus to CCCs [ Γ e : τ ] C([Γ], [τ]) i.e. : [Γ] [τ] with [Γ] C [τ] C e.g. [[ ` e 1 :! ]] = f :[[ ]]! [[ ` e 2 : ]] = g :[[ ]]! [[ ` e 1 e 2 : ]] = app hf,gi :[[ ]]! [[,v : ` e : ]] = f :[[ ]]! [[ ` v.e :! ]] = f :[[ ]]! 3

4 Syntax-and-type directed [ Γ1 e1 : t1 ] = [ Γ2 e2 : t2 ] t1 = t2 Γ1 = Γ2 see signature of interpretation [_] : (e : term) * ((Γ, τ) : ty(e)) C([Γ],[τ]) syntax type analysis 4

5 (Syntax-and-)analysis directed [_] : (e : term) * (i : analysis(e)) D i e.g. simple-typed λ-calculus with effect system [ Γ e : τ, F ] (Γ T F τ) 5

6 Constructing analysisdirected semantics Analysis domain A, semantic domain D Define F : A D to be structure preserving (homomorphism) between A and D Gives a design framework for A and D Equations in A map to equations in D 6

7 Context Work on coeffects (with Tomas Petricek & Alan Mycroft) [ Γ? R e : τ ] C(DR[Γ], [τ]) A core quantitative coeffect calculus (Brunel, Gaboardi, Mazza, Zdancewic), ESOP 2013 Bounded linear types (Ghica and Smith), ESOP 2013 Work on effects (Shinya Katsumata, parametric effect monads ) [ Γ e : τ! F ] C([Γ], MF[τ]) All define analysis-directed semantics (and leverage this for soundness) 7

8 Effect systems Γ e : τ, F monoid (F,, ) [abs] Γ, x : σ e : τ, F F Γ λx. e : σ τ, [var] x : σ Γ Γ x : σ, [app] F Γ e 1 : σ τ, G Γ e 2 : σ, H Γ e 1 e 2 : τ, G H F [write] Γ e : τ, F (x : ref τ) Γ Γ x := e : (), F {W(x)} [read] (x : ref τ) Γ Γ!x : τ, {R(x)} 8

9 Effect systems married to monads Γ e : T F τ monoid (F,, ) [abs] Γ, x : σ e : T F τ Γ λx. e : T (σ T F τ) [var] x : σ Γ Γ x : T σ [app] Γ e 1 : T G (σ T F τ) Γ e 2 : T H σ Γ e 1 e 2 : T (G H F) τ 9 The marriage of effects and monads (Wadler & Thiemann, 2003)

10 <4 A9 Unifying effect-analysis and semantics monoid homomorphism M : [C, C ] F : Set T : F [C, C ] seq id μ : M M M η : 1C M : F F F : 1 F T F T G = T (F G) 1 C = T F F t / F 1 ; / F T T [C, C] [C, C] / [C, C] µ T id + T [C, C] μf,g : TF TG T(F G) η : 1 T 10 Katsumata, Parametric Effect Monads and Semantics of Effect Systems, POPL 2014

11 Equations Identities preserved (trivial) T F = T (F ) = T F T = T F 1 = T F For lax, have the diagram: For strict monoids analogues of monad laws T T F O t ; o T F µ F,; T F µ F,; T F O T ; o T F ; T F 1 C T F T ; ot F ; T F 11

12 Corresponding equations [ Γ1 e1 : t1, F] = [ Γ2 e2 : t2, G ] t1 = t2 Γ1 = Γ2 (F = G) When considering equations on semantics? [ Γ1 e1 : t1, F] = [ Γ2 e2 : t2, G ] proof tree for (F = G) implies semantic laws e.g. [ Γ1 e1 : t1, F ] = [ Γ2 e2 : t2, F ] µ F,; T F O if η is the only way to introduce 12 T F T ; ot F ; T F

13 Bounded linear logic analysis Reuse bounds on free-variables x : σ? n Core rules (with sub-coeffects) [abs] Γ, x : σ? s e : τ Γ λx.e : σ τ [app] Specialised structural rules s Γ1 e1 : σ τ s [var] Γ1, s * Γ2 e1 e2 : τ x : σ? 1 x : σ Γ2 e2 : σ [weak] Γ e : τ Γ, x : σ? 0 e : τ [contr] Γ1, x : σ? a, y : σ? b, Γ2 e : τ Γ1, z : σ? a+b, Γ2 e[z/x,z/y] : τ 13

14 Bounded linear logic analysis (abs) (app) ` ( v.x+v+v)(x+y). variable x is used three x:z,v : Z?h1, 2i ` x + v + v : Z x:z?h1i ` ( v.x + v + v) :Z 2! Z.. x 0 : Z,y : Z?h1, 1i ` x 0 + y : Z ( ) x:z,x0 :Z,y:Z?h1i (2 h1, 1i) ` ( v.x + v + v) (x 0 + y) :Z (contr) x:z,x0 :Z,y:Z?h1, 2, 2i ` ( v.x + v + v) (x 0 + y) :Z x:z,y:z?h3, 2i ` ( v.x + v + v) (x + y) :Z ( v.x + v + v) (x + y) x +(x + y)+(x + y) h i ` x:z,y:z?h3, 2i ` x +(x + y)+(x + y) :Z 14

15 BLL-directed semantics Bounded reuse (exponent) Dn A = A n = <A1,..,An> D : N [C,C] Monoid and scalar-vector multiplication (monoid action) on N + : N N N contraction 0 : 1 N weakening 1 : 1 N variables * : N N n N n * : N N N composition Γ1 e1 : σ τ s Γ1, s * Γ2 e1 e2 : τ Γ2 e2 : σ s * (x1 : t1? r1,, xn : tn? rn) = x1 : t1? s * r1,, xn : tn? s * rn 15 will treat as a vector s * <r1,, rn> = <s * r1,, s * rn>

16 BLL-directed semantics Structure preserving D : N [C,C] s * <r1,, rn> N N n * N n <s * r1,, s * rn> D D n δ n D n Ds <Dr1,, Drn> [C,C] [C,C] n n [C,C] n <D(s * r1),, D(s * rn)> δ n <DsDr1,, DsDrn> 16 δ n : (D(s * r1) D(s * rn)) (DsDr1 DsDrn)

17 BLL-directed semantics δ n : (D(s * r1) D(s * rn)) (DsDr1 DsDrn) Coeffect-parameterised comonad δ : Ds*r A DsDr A s*r copies turned into s copies of r copies ε : D1 A A use one copy 17

18 Coeffect-directed semantics [contr] Γ1, x : σ? a, y : σ? b, Γ2 e : τ Γ1, z : σ? a+b, Γ2 e : τ (N N) D D [C,C] [C,C] + m <-, -> N D [C, C] Δr,s : D (r + s) A Dr A Ds A 18

19 Coeffect-directed semantics BLL analysis as coeffect analysis in general one shaped annotation [abs] [abs] [abs] Γ, x : σ? s e : τ Γ λx.e : σ τ Γ, x : σ? R s e : τ Γ? R λx.e : σ τ Γ, x : σ? R s e : τ Γ? R λx.e : σ τ s s s e.g. distributed resources [abs] Γ, x : σ? {gps, db} e : τ gps Γ? {db} λx.e : σ τ 19

20 Coeffect-directed semantics [abs] Γ, x : σ? R s e : τ Γ? R λx.e : σ τ s let D = uncurry D i.e. D : I C C composes binary ops (I C) (I C) D D C C m I C D C mr,s : Dr A Ds B D (r s) (A B) 20

21 Constructing analysisdirected semantics Analysis domain A, semantic domain D Define F : A D to be structure preserving (homomorphism) between A and D Gives a design framework for A and D Equations in A map to equations in D 21

22 Corresponding equations Use algebraic solver on analysis domain A (e.g., I use Prover 9) Rest of proof not corresponding to A usually naturally and universality Tactic generator! Build into theorem prover? 22

23 Thanks!

Combining Effects and Coeffects via Grading (slides)

Combining Effects and Coeffects via Grading (slides) Combining Effects and Coeffects via Grading (slides) Marco Gaboardi SUNY Buffalo, USA Shin-ya Katsumata Kyoto University, Japan Dominic Orchard University of Kent, UK Flavien Breuvart INRA Sophia Antipolis,

More information

Combining Effects and Coeffects via Grading

Combining Effects and Coeffects via Grading Combining Effects and Coeffects via Grading Marco Gaboardi SUNY Buffalo, USA gaboardi@buffalo.edu Shin-ya Katsumata Kyoto University, Japan sinya@kurims.kyoto-u.ac.jp Dominic Orchard University of Cambridge,

More information

Normalisation by evaluation

Normalisation by evaluation Normalisation by evaluation Sam Lindley Laboratory for Foundations of Computer Science The University of Edinburgh Sam.Lindley@ed.ac.uk August 11th, 2016 Normalisation and embedded domain specific languages

More information

Monads and More: Part 4

Monads and More: Part 4 Monads and More: Part 4 Tarmo Uustalu, Institute of Cybernetics, Tallinn University of Nottingham, 14 18 May 2007 University of Udine, 2 6 July 2007 Comonads Comonads are the dual of monads. A comonad

More information

Towards a Formal Theory of Graded Monads

Towards a Formal Theory of Graded Monads Towards a Formal Theory of Graded Monads Soichiro Fujii 1, Shin-ya Katsumata 2, and Paul-André Melliès 3 1 Department of Computer Science, The University of Tokyo 2 RIMS, Kyoto University 3 Laboratoire

More information

Monads and More: Part 4

Monads and More: Part 4 Monads and More: Part 4 Tarmo Uustalu, Tallinn Nottingham, 14-18 May 2007 Coeffectful computation and comonads For coeffectful notions of computation, we have a comonad (D, ε, δ) on the base category C

More information

Adjoint Logic and Its Concurrent Semantics

Adjoint Logic and Its Concurrent Semantics Adjoint Logic and Its Concurrent Semantics Frank Pfenning ABCD Meeting, Edinburgh, December 18-19, 2017 Joint work with Klaas Pruiksma and William Chargin Outline Proofs as programs Linear sequent proofs

More information

The Lifting Lemma. Ralf Hinze

The Lifting Lemma. Ralf Hinze The Lifting Lemma Ralf Hinze Computing Laboratory, University of Oxford Wolfson Building, Parks Road, Oxford, OX1 3QD, England ralf.hinze@comlab.ox.ac.uk http://www.comlab.ox.ac.uk/ralf.hinze/ June 2009

More information

Modèles des langages de programmation Domaines, catégories, jeux. Programme de cette seconde séance:

Modèles des langages de programmation Domaines, catégories, jeux. Programme de cette seconde séance: Modèles des langages de programmation Domaines, catégories, jeux Programme de cette seconde séance: Modèle ensembliste du lambda-calcul ; Catégories cartésiennes fermées 1 Synopsis 1 the simply-typed λ-calculus,

More information

Universal Algebra for Termination of Higher-Order Rewriting. Makoto Hamana

Universal Algebra for Termination of Higher-Order Rewriting. Makoto Hamana Universal Algebra for Termination of Higher-Order Rewriting Makoto Hamana Department of Computer Science, Gunma University, Japan RTA 05 2005, April 1 Intro: First-Order Term Rewriting System (TRS) Terms

More information

High-Level Small-Step Operational Semantics for Transactions (Technical Companion)

High-Level Small-Step Operational Semantics for Transactions (Technical Companion) High-Level Small-Step Operational Semantics for Transactions (Technical Companion) Katherine F. Moore, Dan Grossman July 15, 2007 Abstract This document is the technical companion to our POPL 08 submission

More information

Technical Report. Programming contextual computations. Dominic Orchard. Number 854. May Computer Laboratory UCAM-CL-TR-854 ISSN

Technical Report. Programming contextual computations. Dominic Orchard. Number 854. May Computer Laboratory UCAM-CL-TR-854 ISSN Technical Report UCAM-CL-TR-854 ISSN 1476-2986 Number 854 Computer Laboratory Programming contextual computations Dominic Orchard May 2014 15 JJ Thomson Avenue Cambridge CB3 0FD United Kingdom phone +44

More information

Information Flow Inference for ML

Information Flow Inference for ML POPL 02 INRIA Rocquencourt Projet Cristal Francois.Pottier@inria.fr http://cristal.inria.fr/~fpottier/ Vincent.Simonet@inria.fr http://cristal.inria.fr/~simonet/ Information flow analysis account number

More information

Algebraic theories in the presence of binding operators, substitution, etc.

Algebraic theories in the presence of binding operators, substitution, etc. Algebraic theories in the presence of binding operators, substitution, etc. Chung Kil Hur Joint work with Marcelo Fiore Computer Laboratory University of Cambridge 20th March 2006 Overview First order

More information

Beyond First-Order Logic

Beyond First-Order Logic Beyond First-Order Logic Software Formal Verification Maria João Frade Departmento de Informática Universidade do Minho 2008/2009 Maria João Frade (DI-UM) Beyond First-Order Logic MFES 2008/09 1 / 37 FOL

More information

A Linear/Producer/Consumer model of Classical Linear Logic

A Linear/Producer/Consumer model of Classical Linear Logic A Linear/Producer/Consumer model of Classical Linear Logic Jennifer Paykin Steve Zdancewic February 14, 2014 Abstract This paper defines a new proof- and category-theoretic framework for classical linear

More information

A Core Quantitative Coeffect Calculus

A Core Quantitative Coeffect Calculus A Core Quantitative Coeffect Calculus Aloïs Brunel 1, Marco Gaboardi 2, Damiano Mazza 1, and Steve Zdancewic 3 1 CNRS, UMR 7030, LIPN, Université Paris 13, Sorbonne Paris Cité 2 University of Dundee 3

More information

Types in categorical linguistics (& elswhere)

Types in categorical linguistics (& elswhere) Types in categorical linguistics (& elswhere) Peter Hines Oxford Oct. 2010 University of York N. V. M. S. Research Topic of the talk: This talk will be about: Pure Category Theory.... although it might

More information

A Call-by-Name CPS Hierarchy

A Call-by-Name CPS Hierarchy A Call-by-Name CPS Hierarchy Asami Tanaka and Yukiyoshi Kameyama University of Tsukuba, Japan asami@logic.cs.tsukuba.ac.jp,kameyama@acm.org Abstract. The Continuation-Passing-Style (CPS) translation gives

More information

Normalization by Evaluation

Normalization by Evaluation Normalization by Evaluation Andreas Abel Department of Computer Science and Engineering Chalmers and Gothenburg University PhD Seminar in Mathematical Engineering EAFIT University, Medellin, Colombia 9

More information

A Differential Model Theory for Resource Lambda Calculi - Part I

A Differential Model Theory for Resource Lambda Calculi - Part I A Differential Model Theory for Resource Lambda Calculi - Part I Giulio Manzonetto g.manzonetto@cs.ru.nl Intelligent Systems Radboud University Nijmegen FMCS 2011 - Calgary - 11 th June 2011 Giulio Manzonetto

More information

Type Inference. For the Simply-Typed Lambda Calculus. Peter Thiemann, Manuel Geffken. Albert-Ludwigs-Universität Freiburg. University of Freiburg

Type Inference. For the Simply-Typed Lambda Calculus. Peter Thiemann, Manuel Geffken. Albert-Ludwigs-Universität Freiburg. University of Freiburg Type Inference For the Simply-Typed Lambda Calculus Albert-Ludwigs-Universität Freiburg Peter Thiemann, Manuel Geffken University of Freiburg 24. Januar 2013 Outline 1 Introduction 2 Applied Lambda Calculus

More information

Lecture 4: Effect Handlers

Lecture 4: Effect Handlers Gordon Laboratory for the Foundations of Computer Science, School of Informatics, University of Edinburgh Beihang University October, 2015 Outline Effect Deconstructors 1 Effect Deconstructors 2 Outline

More information

Mathematical Synthesis of Equational Deduction Systems. Marcelo Fiore. Computer Laboratory University of Cambridge

Mathematical Synthesis of Equational Deduction Systems. Marcelo Fiore. Computer Laboratory University of Cambridge Mathematical Synthesis of Equational Deduction Systems Marcelo Fiore Computer Laboratory University of Cambridge TLCA 2009 3.VII.2009 Context concrete theories meta-theories Context concrete theories meta-theories

More information

Normalisation by Evaluation for Dependent Types

Normalisation by Evaluation for Dependent Types Normalisation by Evaluation for Dependent Types Ambrus Kaposi Eötvös Loránd University, Budapest, Hungary (j.w.w. Thorsten Altenkirch, University of Nottingham) FSCD, Porto 24 June 2016 Introduction Goal:

More information

CS 611 Advanced Programming Languages. Andrew Myers Cornell University. Lecture 26 Type reconstruction. 1 Nov 04. Type reconstruction

CS 611 Advanced Programming Languages. Andrew Myers Cornell University. Lecture 26 Type reconstruction. 1 Nov 04. Type reconstruction CS 611 Advanced Programming Languages Andrew Myers Cornell University Lecture 26 Type reconstruction 1 Nov 04 Type reconstruction Simple typed language: e ::= x b λx:τ. e e 1 e 2 e 1 + e 2 if e 0 then

More information

Subtyping and Intersection Types Revisited

Subtyping and Intersection Types Revisited Subtyping and Intersection Types Revisited Frank Pfenning Carnegie Mellon University International Conference on Functional Programming (ICFP 07) Freiburg, Germany, October 1-3, 2007 Joint work with Rowan

More information

A Linear/Producer/Consumer Model of Classical Linear Logic

A Linear/Producer/Consumer Model of Classical Linear Logic A Linear/Producer/Consumer Model of Classical Linear Logic Jennifer Paykin Steve Zdancewic University of Pennsylvania Philadelphia, USA jpaykin@seas.upenn.edu stevez@cis.upenn.edu This paper defines a

More information

One Year Later. Iliano Cervesato. ITT Industries, NRL Washington, DC. MSR 3.0:

One Year Later. Iliano Cervesato. ITT Industries, NRL Washington, DC.  MSR 3.0: MSR 3.0: The Logical Meeting Point of Multiset Rewriting and Process Algebra MSR 3: Iliano Cervesato iliano@itd.nrl.navy.mil One Year Later ITT Industries, inc @ NRL Washington, DC http://www.cs.stanford.edu/~iliano

More information

Sequents are written as A, where A; B represent formulae and ; represent multisets of formulae. Where represents the multiset A 1 ; : : : ; A n, then!

Sequents are written as A, where A; B represent formulae and ; represent multisets of formulae. Where represents the multiset A 1 ; : : : ; A n, then! What is a Categorical Model of ntuitionistic Linear Logic G.M. Bierman University of Cambridge Computer Laboratory Abstract. This paper re-addresses the old problem of providing a categorical model for

More information

Full abstraction for nominal exceptions and general references

Full abstraction for nominal exceptions and general references Full abstraction for nominal exceptions and general references Nikos Tzevelekos Oxford University N.Tzevelekos GALOP 08 1 Summary Summary Nominal games Further directions Semantics of nominal computation.

More information

Midterm Exam Types and Programming Languages Frank Pfenning. October 18, 2018

Midterm Exam Types and Programming Languages Frank Pfenning. October 18, 2018 Midterm Exam 15-814 Types and Programming Languages Frank Pfenning October 18, 2018 Name: Andrew ID: Instructions This exam is closed-book, closed-notes. You have 80 minutes to complete the exam. There

More information

On the Semantics of Parsing Actions

On the Semantics of Parsing Actions On the Semantics of Parsing Actions Hayo Thielecke School of Computer Science University of Birmingham Birmingham B15 2TT, United Kingdom Abstract Parsers, whether constructed by hand or automatically

More information

Monads Need Not Be Endofunctors

Monads Need Not Be Endofunctors Monads Need Not Be Endofunctors Thorsten Altenkirch, University of Nottingham James Chapman, Institute of Cybernetics, Tallinn Tarmo Uustalu, Institute of Cybernetics, Tallinn ScotCats, Edinburgh, 21 May

More information

Quantum groupoids and logical dualities

Quantum groupoids and logical dualities Quantum groupoids and logical dualities (work in progress) Paul-André Melliès CNS, Université Paris Denis Diderot Categories, ogic and Foundations of Physics ondon 14 May 2008 1 Proof-knots Aim: formulate

More information

Distributive residuated frames and generalized bunched implication algebras

Distributive residuated frames and generalized bunched implication algebras Distributive residuated frames and generalized bunched implication algebras Nikolaos Galatos and Peter Jipsen Abstract. We show that all extensions of the (non-associative) Gentzen system for distributive

More information

Semantics and syntax of higher inductive types

Semantics and syntax of higher inductive types Semantics and syntax of higher inductive types Michael Shulman 1 Peter LeFanu Lumsdaine 2 1 University of San Diego 2 Stockholm University http://www.sandiego.edu/~shulman/papers/stthits.pdf March 20,

More information

Erasable Contracts. Abstract. 1. Introduction. Harvard University {jchinlee,

Erasable Contracts. Abstract. 1. Introduction. Harvard University {jchinlee, Erasable Contracts Jao-ke Chin-Lee Louis Li Harvard University {jchinlee, louisli}@college.harvard.edu Abstract Contract programming is a design approach that allows programmers to design formal specifications

More information

State-Dependent Representation Independence (Technical Appendix)

State-Dependent Representation Independence (Technical Appendix) State-Dependent Representation Independence (Technical Appendix) Amal Ahmed Derek Dreyer Andreas Rossberg TTI-C MPI-SWS MPI-SWS amal@tti-c.org dreyer@mpi-sws.mpg.de rossberg@mpi-sws.mpg.de Contents August

More information

Realizability Semantics of Parametric Polymorphism, General References, and Recursive Types

Realizability Semantics of Parametric Polymorphism, General References, and Recursive Types Realizability Semantics of Parametric Polymorphism, General References, and Recursive Types Lars Birkedal IT University of Copenhagen Joint work with Kristian Støvring and Jacob Thamsborg Oct, 2008 Lars

More information

An extension of HM(X) with bounded existential and universal data-types

An extension of HM(X) with bounded existential and universal data-types Groupe de travail Cristal July, 2003 An extension of HM(X) with bounded existential and universal data-types (To appear at ICFP 03) Vincent Simonet INRIA Rocquencourt Cristal project Vincent.Simonet@inria.fr

More information

Monads for Relations. Jeremy G. Siek University of Colorado at Boulder SPLS, June Jeremy Siek Monads for Relations 1 / 20

Monads for Relations. Jeremy G. Siek University of Colorado at Boulder SPLS, June Jeremy Siek Monads for Relations 1 / 20 Monads for Relations Jeremy G. Siek University of Colorado at Boulder SPLS, June 2010 Jeremy Siek Monads for Relations 1 / 20 Natural (Big-Step) Semantics for CBV Lambda ρ e v Env Expr Value ρ x ρ x ρ

More information

Categorical relativistic quantum theory. Chris Heunen Pau Enrique Moliner Sean Tull

Categorical relativistic quantum theory. Chris Heunen Pau Enrique Moliner Sean Tull Categorical relativistic quantum theory Chris Heunen Pau Enrique Moliner Sean Tull 1 / 15 Idea Hilbert modules: naive quantum field theory Idempotent subunits: base space in any category Support: where

More information

On the Syntax and Semantics of Quantitative Typing

On the Syntax and Semantics of Quantitative Typing On the Syntax and Semantics of Quantitative Typing Andreas Abel 1 1 Department of Computer Science and Engineering Chalmers and Gothenburg University, Sweden Workshop on Mixed Inductive-Coinductive Reasoning

More information

Elements of Category Theory

Elements of Category Theory Elements of Category Theory Robin Cockett Department of Computer Science University of Calgary Alberta, Canada robin@cpsc.ucalgary.ca Estonia, Feb. 2010 Functors and natural transformations Adjoints and

More information

Complete Partial Orders, PCF, and Control

Complete Partial Orders, PCF, and Control Complete Partial Orders, PCF, and Control Andrew R. Plummer TIE Report Draft January 2010 Abstract We develop the theory of directed complete partial orders and complete partial orders. We review the syntax

More information

The lambda calculus with constructors

The lambda calculus with constructors The lambda calculus with constructors Categorical semantic and Continuations Barbara Petit Focus - Univ. Bologna CaCos 2012 Barbara Petit (Focus - Univ. Bologna) The lambda calculus with constructors 1

More information

OPERAD BIMODULE CHARACTERIZATION OF ENRICHMENT. V2

OPERAD BIMODULE CHARACTERIZATION OF ENRICHMENT. V2 OPERAD BIMODULE CHARACTERIZATION OF ENRICHMENT. 2 STEFAN FORCEY 1. Idea In a recent talk at CT06 http://faculty.tnstate.edu/sforcey/ct06.htm and in a research proposal at http://faculty.tnstate.edu/sforcey/class_home/research.htm

More information

Taming Selective Strictness

Taming Selective Strictness Taming Selective Strictness Daniel Seidel and Janis Voigtländer Technische Universität Dresden, 01062 Dresden, Germany {seideld,voigt}@tcs.inf.tu-dresden.de Abstract: Free theorems establish interesting

More information

Logic for Computational Effects: work in progress

Logic for Computational Effects: work in progress 1 Logic for Computational Effects: work in progress Gordon Plotkin and John Power School of Informatics University of Edinburgh King s Buildings Mayfield Road Edinburgh EH9 3JZ Scotland gdp@inf.ed.ac.uk,

More information

Information Flow Inference for ML

Information Flow Inference for ML Information Flow Inference for ML Vincent Simonet INRIA Rocquencourt Projet Cristal MIMOSA September 27, 2001 Information flow account number bank applet order vendor account H order L bank H vendor L

More information

An Alternative Direct Simulation of Minsky Machines into Classical Bunched Logics via Group Semantics (full version)

An Alternative Direct Simulation of Minsky Machines into Classical Bunched Logics via Group Semantics (full version) MFPS 2010 An Alternative Direct Simulation of Minsky Machines into Classical Bunched Logics via Group Semantics (full version) Dominique Larchey-Wendling LORIA CNRS, UMR 7503 Vandœuvre-lès-Nancy, France

More information

Relational Algebra by Way of Adjunctions. Jeremy Gibbons (joint work with Fritz Henglein, Ralf Hinze, Nicolas Wu) DBPL, October 2015

Relational Algebra by Way of Adjunctions. Jeremy Gibbons (joint work with Fritz Henglein, Ralf Hinze, Nicolas Wu) DBPL, October 2015 Relational Algebra by Way of Adjunctions Jeremy Gibbons (joint work with Fritz Henglein, Ralf Hinze, Nicolas Wu) DBPL, October 2015 Relational Algebra by Way of Adjunctions 2 1. Summary bulk types (sets,

More information

CSE 505, Fall 2008, Midterm Examination 29 October Please do not turn the page until everyone is ready.

CSE 505, Fall 2008, Midterm Examination 29 October Please do not turn the page until everyone is ready. CSE 505, Fall 2008, Midterm Examination 29 October 2008 Please do not turn the page until everyone is ready. Rules: The exam is closed-book, closed-note, except for one side of one 8.5x11in piece of paper.

More information

Uniform Schemata for Proof Rules

Uniform Schemata for Proof Rules Uniform Schemata for Proof Rules Ulrich Berger and Tie Hou Department of omputer Science, Swansea University, UK {u.berger,cshou}@swansea.ac.uk Abstract. Motivated by the desire to facilitate the implementation

More information

Relations to first order logic

Relations to first order logic An Introduction to Description Logic IV Relations to first order logic Marco Cerami Palacký University in Olomouc Department of Computer Science Olomouc, Czech Republic Olomouc, November 6 th 2014 Marco

More information

QPEL Quantum Program and Effect Language

QPEL Quantum Program and Effect Language QPEL Quantum Program and Effect Language QPL 2014 Kyoto Robin Adams r.adams@cs.ru.nl 5 June 2014 R Adams 5 June 2014 QPEL 1 / 32 Introduction QPEL (Quantum Program and Effect language) is a formal system

More information

A fully abstract semantics for a nondeterministic functional language with monadic types

A fully abstract semantics for a nondeterministic functional language with monadic types A fully abstract semantics for a nondeterministic functional language with monadic types Alan Jeffrey 1 School of Cognitive and Computing Sciences University of Sussex, Brighton BN1 9QH, UK alanje@cogs.susx.ac.uk

More information

Towards a Flowchart Diagrammatic Language for Monad-based Semantics

Towards a Flowchart Diagrammatic Language for Monad-based Semantics Towards a Flowchart Diagrammatic Language or Monad-based Semantics Julian Jakob Friedrich-Alexander-Universität Erlangen-Nürnberg julian.jakob@au.de 21.06.2016 Introductory Examples 1 2 + 3 3 9 36 4 while

More information

DEFINITIONS: OPERADS, ALGEBRAS AND MODULES. Let S be a symmetric monoidal category with product and unit object κ.

DEFINITIONS: OPERADS, ALGEBRAS AND MODULES. Let S be a symmetric monoidal category with product and unit object κ. DEFINITIONS: OPERADS, ALGEBRAS AND MODULES J. P. MAY Let S be a symmetric monoidal category with product and unit object κ. Definition 1. An operad C in S consists of objects C (j), j 0, a unit map η :

More information

Views: Compositional Reasoning for Concurrent Programs

Views: Compositional Reasoning for Concurrent Programs Views: Compositional Reasoning for Concurrent Programs Thomas Dinsdale-Young Imperial College td202@doc.ic.ac.uk Lars Birkedal IT University of Copenhagen birkedal@itu.dk Philippa Gardner Imperial College

More information

Towards Concurrent Type Theory

Towards Concurrent Type Theory Towards Concurrent Type Theory Luís Caires 1, Frank Pfenning 2, Bernardo Toninho 1,2 1 Universidade Nova de Lisboa 2 Carnegie Mellon University Workshop on Types in Language Design and Implementation (TLDI)

More information

Contextual equivalence

Contextual equivalence Techniques 16/22 ACS L16, lecture 2 4/10 Contextual equivalence Two phrases of a programming language are ( Morris style ) contextually equivalent ( = ctx ) if occurrences of the first phrase in any program

More information

Relating Nominal and Higher-Order Pattern Unification

Relating Nominal and Higher-Order Pattern Unification Relating Nominal and Higher-Order Pattern Unification James Cheney University of Edinburgh UNIF 2005 April 22, 2005 1 Motivation Higher-order unification: studied since ca. 1970 Undecidable, infinitary,

More information

Techniques. Contextual equivalence

Techniques. Contextual equivalence Techniques 16/22 Contextual equivalence Two phrases of a programming language are ( Morris style ) contextually equivalent ( = ctx )if occurrences of the first phrase in any program can be replaced by

More information

M, N ::= x λp : A.M MN (M, N) () c A. x : b p x : b

M, N ::= x λp : A.M MN (M, N) () c A. x : b p x : b A PATTERN-MATCHING CALCULUS FOR -AUTONOMOUS CATEGORIES ABSTRACT. This article sums up the details of a linear λ-calculus that can be used as an internal language of -autonomous categories. The coherent

More information

On the Construction of Free Algebras for Equational Systems

On the Construction of Free Algebras for Equational Systems On the Construction of Free Algebras for Equational Systems Marcelo Fiore and Chung-Kil Hur 1 Computer Laboratory, University of Cambridge Abstract The purpose of this paper is threefold: to present a

More information

Preuves de logique linéaire sur machine, ENS-Lyon, Dec. 18, 2018

Preuves de logique linéaire sur machine, ENS-Lyon, Dec. 18, 2018 Université de Lorraine, LORIA, CNRS, Nancy, France Preuves de logique linéaire sur machine, ENS-Lyon, Dec. 18, 2018 Introduction Linear logic introduced by Girard both classical and intuitionistic separate

More information

Axiomatizability of Algebras of Binary Relations

Axiomatizability of Algebras of Binary Relations Axiomatizability of Algebras of Binary Relations Szabolcs Mikulás Department of Computer Science and Information Systems Birkbeck, University of London szabolcs@dcs.bbk.ac.uk 22/09/2010 Sz. Mikulás ()

More information

Monadic Refinements for Relational Cost Analysis (Appendix)

Monadic Refinements for Relational Cost Analysis (Appendix) Monadic Refinements for Relational Cost Analysis (Appendix) Ivan Radiček Gilles Barthe Marco Gaboardi Deepak Garg Florian Zuleger Structure of the Appendix In the appendix we give material that was omitted

More information

The Approximation Theorem for the Λµ-Calculus

The Approximation Theorem for the Λµ-Calculus The Approximation Theorem for the Λµ-Calculus Ugo de Liguoro ICTCS 13 - September 2013, Palermo Parigot s λµ-calculus (1992) is an extension of the λ-calculus to compute with classical proofs However there

More information

From parametric polymorphism to models of polymorphic FPC

From parametric polymorphism to models of polymorphic FPC Under consideration for publication in Math. Struct. in Comp. Science From parametric polymorphism to models of polymorphic FPC Rasmus Ejlers Møgelberg IT University of Copenhagen Rued Langgaards Vej 7

More information

Abstraction and Invariance for Algebraically Indexed Types

Abstraction and Invariance for Algebraically Indexed Types Abstraction and Invariance for Algebraically Indexed Types Robert Atkey Patricia Johann University of Strathclyde {Robert.Atkey,Patricia.Johann}@strath.ac.uk Andrew Kennedy Microsoft Research Cambridge

More information

A Taste of Categorical Logic Tutorial Notes

A Taste of Categorical Logic Tutorial Notes A Taste of Categorical Logic Tutorial Notes Lars Birkedal birkedal@cs.au.dk) Aleš Bizjak abizjak@cs.au.dk) October 12, 2014 Contents 1 Introduction 2 2 Higher-order predicate logic 2 3 A first set-theoretic

More information

The algebraicity of the lambda-calculus

The algebraicity of the lambda-calculus The algebraicity of the lambda-calculus André Hirschowitz 1 and Marco Maggesi 2 1 Université de Nice Sophia Antipolis http://math.unice.fr/~ah 2 Università degli Studi di Firenze http://www.math.unifi.it/~maggesi

More information

CSE 505, Fall 2009, Midterm Examination 5 November Please do not turn the page until everyone is ready.

CSE 505, Fall 2009, Midterm Examination 5 November Please do not turn the page until everyone is ready. CSE 505, Fall 2009, Midterm Examination 5 November 2009 Please do not turn the page until everyone is ready Rules: The exam is closed-book, closed-note, except for one side of one 85x11in piece of paper

More information

Safety Analysis versus Type Inference for Partial Types

Safety Analysis versus Type Inference for Partial Types Safety Analysis versus Type Inference for Partial Types Jens Palsberg palsberg@daimi.aau.dk Michael I. Schwartzbach mis@daimi.aau.dk Computer Science Department, Aarhus University Ny Munkegade, DK-8000

More information

On Typability for Rank-2 Intersection Types with Polymorphic Recursion

On Typability for Rank-2 Intersection Types with Polymorphic Recursion On Typability for Rank-2 Intersection Types with Polymorphic Recursion Tachio Terauchi EECS Department University of California, Berkeley Alex Aiken Computer Science Department Stanford University Abstract

More information

Fully-Abstract Compilation by Approximate Back-Translation Technical Appendix

Fully-Abstract Compilation by Approximate Back-Translation Technical Appendix Fully-Abstract Compilation by Approximate Back-Translation Technical Appendix Abstract This technical appendix provides the full formalisation and proofs for its paper 1 Contents 1 The Source Language

More information

Classical Program Logics: Hoare Logic, Weakest Liberal Preconditions

Classical Program Logics: Hoare Logic, Weakest Liberal Preconditions Chapter 1 Classical Program Logics: Hoare Logic, Weakest Liberal Preconditions 1.1 The IMP Language IMP is a programming language with an extensible syntax that was developed in the late 1960s. We will

More information

Recent Developments in and Around Coaglgebraic Logics

Recent Developments in and Around Coaglgebraic Logics Recent Developments in and Around Coaglgebraic Logics D. Pattinson, Imperial College London (in collaboration with G. Calin, R. Myers, L. Schröder) Example: Logics in Knowledge Representation Knowledge

More information

Equational Logic. Chapter Syntax Terms and Term Algebras

Equational Logic. Chapter Syntax Terms and Term Algebras Chapter 2 Equational Logic 2.1 Syntax 2.1.1 Terms and Term Algebras The natural logic of algebra is equational logic, whose propositions are universally quantified identities between terms built up from

More information

Linearity and Passivity

Linearity and Passivity Linearity and Passivity David A. 1 School of Computing University of Tasmania GPO Box 252-100 Hobart 7001 Australia Abstract A simple symmetric logic is proposed which captures both the notions of Linearity

More information

Relative Hilbert-Post completeness for exceptions

Relative Hilbert-Post completeness for exceptions Relative Hilbert-Post completeness for exceptions Dominique Duval with J.-G. Dumas, B. Ekici, D. Pous, J.-C. Reynaud LJK University of Grenoble-Alpes and ENS Lyon November 12., 2015 MACIS 2015, Berlin

More information

Reconsidering MacLane. Peter M. Hines

Reconsidering MacLane. Peter M. Hines Reconsidering MacLane Coherence for associativity in infinitary and untyped settings Peter M. Hines Oxford March 2013 Topic of the talk: Pure category theory... for its own sake. This talk is about the

More information

A RESOLUTION DECISION PROCEDURE FOR SHOIQ

A RESOLUTION DECISION PROCEDURE FOR SHOIQ A RESOLUTION DECISION PROCEDURE FOR SHOIQ Yevgeny Kazakov and Boris Motik The University of Manchester August 20, 2006 SHOIQ IS A DESCRIPTION LOGIC! Yevgeny Kazakov and Boris Motik A Resolution Decision

More information

Abstracting away from cell complexes

Abstracting away from cell complexes Abstracting away from cell complexes Michael Shulman 1 Peter LeFanu Lumsdaine 2 1 University of San Diego 2 Stockholm University March 12, 2016 Replacing big messy cell complexes with smaller and simpler

More information

Call by Effect. Kevin Ellis. Catlin Gabel

Call by Effect. Kevin Ellis. Catlin Gabel Call by Effect Kevin Ellis Catlin Gabel Abstract. Evaluation strategies specify rules for evaluation of terms in a programming language. That the choice of evaluation strategy affects the expressiveness

More information

Principles of Program Analysis: A Sampler of Approaches

Principles of Program Analysis: A Sampler of Approaches Principles of Program Analysis: A Sampler of Approaches Transparencies based on Chapter 1 of the book: Flemming Nielson, Hanne Riis Nielson and Chris Hankin: Principles of Program Analysis Springer Verlag

More information

Semantic Solutions to Program Analysis Problems

Semantic Solutions to Program Analysis Problems Semantic Solutions to Program Analysis Problems Sam Tobin-Hochstadt and David Van Horn PLDI FIT 2011 A talk in three parts. 1. A provocative claim. (The thought) 2. A idea about modular program analysis.

More information

Interpreting Polymorphic FPC into domain theoretic models of parametric polymorphism

Interpreting Polymorphic FPC into domain theoretic models of parametric polymorphism Interpreting Polymorphic FPC into domain theoretic models of parametric polymorphism Rasmus Ejlers Møgelberg DISI, Università di Genova mogelberg@disi.unige.it Abstract. This paper shows how parametric

More information

FROM LAX MONAD EXTENSIONS TO TOPOLOGICAL THEORIES

FROM LAX MONAD EXTENSIONS TO TOPOLOGICAL THEORIES FROM LAX MONAD EXTENSIONS TO TOPOLOGICAL THEORIES MARIA MANUEL CLEMENTINO AND WALTER THOLEN To Manuela, teacher and friend Abstract. We investigate those lax extensions of a Set-monad T = (T, m, e) to

More information

BRICS. A Computational Formalization for Partial Evaluation. (Extended Version) Basic Research in Computer Science

BRICS. A Computational Formalization for Partial Evaluation. (Extended Version) Basic Research in Computer Science BRICS RS-96-34 Hatcliff & Danvy: A Computational Formalization for Partial Evaluation BRICS Basic Research in Computer Science A Computational Formalization for Partial Evaluation (Extended Version) John

More information

Limitations of OCAML records

Limitations of OCAML records Limitations of OCAML records The record types must be declared before they are used; a label e can belong to only one record type (otherwise fun x x.e) would have several incompatible types; we cannot

More information

Resource lambda-calculus: the differential viewpoint

Resource lambda-calculus: the differential viewpoint Resource lambda-calculus: the differential viewpoint Preuves, Programmes et Systèmes (PPS) Université Paris Diderot and CNRS September 13, 2011 History ( 1985): Girard Girard had differential intuitions

More information

A few bridges between operational and denotational semantics of programming languages

A few bridges between operational and denotational semantics of programming languages A few bridges between operational and denotational semantics of programming languages Soutenance d habilitation à diriger les recherches Tom Hirschowitz November 17, 2017 Hirschowitz Bridges between operational

More information

Non- -overlappings TRSs are UN. Stefan Kahrs and Connor Smith University of Kent

Non- -overlappings TRSs are UN. Stefan Kahrs and Connor Smith University of Kent Non- -overlappings TRSs are UN Stefan Kahrs and Connor Smith University of Kent This is about: When is the equational theory of a TRS consistent (CON), when does it have unique normal forms (UN), How can

More information

Boolean bunched logic: its semantics and completeness

Boolean bunched logic: its semantics and completeness Boolean bunched logic: its semantics and completeness James Brotherston Programming Principles, Logic and Verification Group Dept. of Computer Science University College London, UK J.Brotherston@ucl.ac.uk

More information

Relational Reasoning for Recursive Types and References

Relational Reasoning for Recursive Types and References Relational Reasoning for Recursive Types and References Nina Bohr and Lars Birkedal IT University of Copenhagen (ITU) {ninab,birkedal}@itu.dk Abstract. We present a local relational reasoning method for

More information

Interpreting the Full λ-calculus in the π-calculus

Interpreting the Full λ-calculus in the π-calculus Interpreting the Full λ-calculus in the π-calculus Xiaojuan Cai Joint work with Yuxi Fu BASICS Lab October 12, 2009 Motivation The λ-calculus: sequential model; The π-calculus: concurrent model A deep

More information