focusing on binding and computation
play

Focusing on Binding and Computation Robert Harper Carnegie Mellon - PowerPoint PPT Presentation

Focusing on Binding and Computation Robert Harper Carnegie Mellon University (Joint work with Dan Licata and Noam Zeilberger) June 18, 2008 1 / 41 The Payload Main Results and Ideas Main Results and Ideas Motivation Focusing


  1. Focusing on Binding and Computation Robert Harper Carnegie Mellon University (Joint work with Dan Licata and Noam Zeilberger) June 18, 2008 1 / 41

  2. The Payload • Main Results and Ideas • Main Results and Ideas Motivation Focusing Generalized Datatypes Conclusion The Payload 2 / 41

  3. Main Results and Ideas The Payload Integrate Logical Frameworks and Functional Programming. • Main Results and Ideas • LF level provides a generalized datatype mechanism adequate • Main Results and Ideas for syntax, judgements, rules, proofs. Motivation • FP level provides the means to compute over these datatypes. Focusing In this talk we restrict attention to simple (non-indexed) types (to Generalized Datatypes Conclusion appear, LICS 2008). Current work on extending to dependent types and indexed types (not to appear, ICFP 2008). 3 / 41

  4. Main Results and Ideas The Payload Polarized type systems. • Main Results and Ideas • Positive types are inductively defined by intro/focusing rules, • Main Results and Ideas manipulated by elim/inversion rules. Motivation • Negative types are inductively defined by elim/inversion rules, Focusing manipulated by intro/focusing rules. Generalized Datatypes Conclusion Contextual modal type systems. � Ψ � A has as elements “open terms” with parameters specified • by context Ψ . • Treats binding and scope without reliance on effects/state. 4 / 41

  5. The Payload Motivation • Representation and Computation • Example: Domain-Specific Logics • Example: Domain-Specific Logics • Example: Domain-Specific Logics • Representation and Computation Motivation • Derivability and Admissibility • Representation and Computation Focusing Generalized Datatypes Conclusion 5 / 41

  6. Representation and Computation The Payload Goal: integrate representation and computation in a functional Motivation language. • Representation and Computation 1. Representation: types for syntax including binding and scope. • Example: Domain-Specific Logics 2. Computation: type of higher-order computations over these • Example: Domain-Specific Logics types. • Example: Domain-Specific Logics • Representation and Computation • Derivability and Admissibility • Representation and Computation Focusing Generalized Datatypes Conclusion 6 / 41

  7. Representation and Computation The Payload Goal: integrate representation and computation in a functional Motivation language. • Representation and Computation 1. Representation: types for syntax including binding and scope. • Example: Domain-Specific Logics 2. Computation: type of higher-order computations over these • Example: Domain-Specific Logics types. • Example: Domain-Specific Logics • Representation and Requirements: Computation • Derivability and 1. Sufficiently powerful to represent syntax, judgements, rules, Admissibility • Representation and proofs. Computation 2. Sufficiently flexible to permit computation by structural induction Focusing modulo α -equivalence. Generalized Datatypes Conclusion 3. Purely functional, so that we may index types by syntax. 6 / 41

  8. Example: Domain-Specific Logics The Payload Access control logic (excerpts): Motivation • Representation and sort : type. Computation • Example: princ : sort. Domain-Specific Logics • Example: res : sort. Domain-Specific Logics • Example: Domain-Specific Logics term : sort => type. • Representation and Computation dan : term princ. • Derivability and bob : term princ. Admissibility • Representation and /home/dan/pub : term res. Computation Focusing prop : type. Generalized Datatypes owns : term princ => term res => prop. Conclusion mayrd : term princ => term res => prop. 7 / 41

  9. Example: Domain-Specific Logics The Payload Access control logic (excerpts): Motivation • Representation and true : prop => type. Computation • Example: affirms : term princ => prop => type. Domain-Specific Logics • Example: Domain-Specific Logics impi : (imp A B) true <= (A true => B true). • Example: Domain-Specific Logics impe : B true <= A true <= (imp A B) true. • Representation and Computation • Derivability and aff : K affirms A <= A true. Admissibility • Representation and Computation saysi : (K says A) true <= K affirms A. Focusing sayse : (K affirms C) <= (says K A) <= Generalized Datatypes (K affirms A => K affirms C). Conclusion 8 / 41

  10. Example: Domain-Specific Logics The Payload Signature for proof-carrying access control: Motivation • Representation and type file[r:term res] Computation • Example: val paper.tex : file[/home/dan/pub] Domain-Specific Logics • Example: Domain-Specific Logics type iam[p:term princ] • Example: Domain-Specific Logics val iambob : iam[bob] • Representation and Computation • Derivability and val read : Admissibility • Representation and ∀ r. ∀ p. ∀ pf:atom (p mayrd r) true. Computation file[r] -> iam[p] -> string Focusing Generalized Datatypes Implementation of read structurally analyzes proofs at run-time! Conclusion 9 / 41

  11. Representation and Computation There are two different function spaces in play here! The Payload Motivation Representational: A ⇒ B (aka B ⇐ A ). • Representation and 1. Computation Computational: A → B (aka B ← A ). 2. • Example: Domain-Specific Logics • Example: Representational functions: Domain-Specific Logics • Example: Domain-Specific Logics • Representation and Computation • Derivability and Admissibility • Representation and Computation Focusing Generalized Datatypes Conclusion 10 / 41

  12. Representation and Computation There are two different function spaces in play here! The Payload Motivation Representational: A ⇒ B (aka B ⇐ A ). • Representation and 1. Computation Computational: A → B (aka B ← A ). 2. • Example: Domain-Specific Logics • Example: Representational functions: Domain-Specific Logics • Example: Domain-Specific Logics • Adequate for syntax, rules, proofs. • Representation and Computation • Derivability and Admissibility • Representation and Computation Focusing Generalized Datatypes Conclusion 10 / 41

  13. Representation and Computation There are two different function spaces in play here! The Payload Motivation Representational: A ⇒ B (aka B ⇐ A ). • Representation and 1. Computation Computational: A → B (aka B ← A ). 2. • Example: Domain-Specific Logics • Example: Representational functions: Domain-Specific Logics • Example: Domain-Specific Logics • Adequate for syntax, rules, proofs. • Representation and • Closed-ended: schemas built from parameters by composing Computation • Derivability and rules. Admissibility • Representation and Computation Focusing Generalized Datatypes Conclusion 10 / 41

  14. Representation and Computation There are two different function spaces in play here! The Payload Motivation Representational: A ⇒ B (aka B ⇐ A ). • Representation and 1. Computation Computational: A → B (aka B ← A ). 2. • Example: Domain-Specific Logics • Example: Representational functions: Domain-Specific Logics • Example: Domain-Specific Logics • Adequate for syntax, rules, proofs. • Representation and • Closed-ended: schemas built from parameters by composing Computation • Derivability and rules. Admissibility • Representation and Computation Computational functions: Focusing Generalized Datatypes Conclusion 10 / 41

  15. Representation and Computation There are two different function spaces in play here! The Payload Motivation Representational: A ⇒ B (aka B ⇐ A ). • Representation and 1. Computation Computational: A → B (aka B ← A ). 2. • Example: Domain-Specific Logics • Example: Representational functions: Domain-Specific Logics • Example: Domain-Specific Logics • Adequate for syntax, rules, proofs. • Representation and • Closed-ended: schemas built from parameters by composing Computation • Derivability and rules. Admissibility • Representation and Computation Computational functions: Focusing • Compute by pattern matching. Generalized Datatypes Conclusion 10 / 41

  16. Representation and Computation There are two different function spaces in play here! The Payload Motivation Representational: A ⇒ B (aka B ⇐ A ). • Representation and 1. Computation Computational: A → B (aka B ← A ). 2. • Example: Domain-Specific Logics • Example: Representational functions: Domain-Specific Logics • Example: Domain-Specific Logics • Adequate for syntax, rules, proofs. • Representation and • Closed-ended: schemas built from parameters by composing Computation • Derivability and rules. Admissibility • Representation and Computation Computational functions: Focusing • Compute by pattern matching. Generalized Datatypes • Open-ended: any form of computation allowable. Conclusion 10 / 41

  17. Derivability and Admissibility Representational functions witness derivabilities, J 1 ⊢ J 2 . The Payload Motivation • Representation and Computation • Example: Domain-Specific Logics • Example: Domain-Specific Logics • Example: Domain-Specific Logics • Representation and Computation • Derivability and Admissibility • Representation and Computation Focusing Generalized Datatypes Conclusion 11 / 41

Recommend


More recommend