ect contexts in refl a theorem proving meta language
play

ect : Contexts in reFL A Theorem Proving Meta-Language Jim Grundy - PowerPoint PPT Presentation

ect : Contexts in reFL A Theorem Proving Meta-Language Jim Grundy Intel Corporation, Strategic CAD Labs Tom Melham Oxford University, Computing Laboratory John OLeary Intel Corporation, Strategic CAD Labs Sava Krsti c Intel


  1. ect : Contexts in reFL A Theorem Proving Meta-Language Jim Grundy Intel Corporation, Strategic CAD Labs Tom Melham Oxford University, Computing Laboratory John O’Leary Intel Corporation, Strategic CAD Labs Sava Krsti´ c Intel Corporation, Strategic CAD Labs October 2005

  2. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties

  3. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties ect is typed λ -calculus + ◮ reFL ◮ A quotation mechanism, like: � � � | | | this | | | � � � ◮ An anti-quotation mechanism, like: ˆ ˆ ˆ this

  4. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties ect is typed λ -calculus + ◮ reFL ◮ A quotation mechanism, like: � � � | | | this | | | � � � ◮ An anti-quotation mechanism, like: ˆ ˆ ˆ this ◮ Quoted expressions denote values of type term

  5. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties ect is typed λ -calculus + ◮ reFL ◮ A quotation mechanism, like: � � � | | | this | | | � � � ◮ An anti-quotation mechanism, like: ˆ ˆ ˆ this ◮ Quoted expressions denote values of type term ◮ Values of type term are ASTs of well-typed expressions

  6. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties ect is typed λ -calculus + ◮ reFL ◮ A quotation mechanism, like: � � � | | | this | | | � � � ◮ An anti-quotation mechanism, like: ˆ ˆ ˆ this ◮ Quoted expressions denote values of type term ◮ Values of type term are ASTs of well-typed expressions ◮ 1 + 2 and 2 + 1 are equal, they both describe the number 3

  7. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties ect is typed λ -calculus + ◮ reFL ◮ A quotation mechanism, like: � � � | | | this | | | � � � ◮ An anti-quotation mechanism, like: ˆ this ˆ ˆ ◮ Quoted expressions denote values of type term ◮ Values of type term are ASTs of well-typed expressions ◮ 1 + 2 and 2 + 1 are equal, they both describe the number 3 ◮ � � � | | | 1 + 2 | | | � and � � � � � | | | 2 + 1 | | | � � � are not equal, they are different ASTs

  8. Language Overview ect is reFL ◮ 2nd version of FL with reflection ◮ a dialect of ML used at Intel for applications including ◮ correctness preserving design transformations ◮ interactive theorem proving of design properties ect is typed λ -calculus + ◮ reFL ◮ A quotation mechanism, like: � � � | | | this | | | � � � ◮ An anti-quotation mechanism, like: ˆ ˆ ˆ this ◮ Quoted expressions denote values of type term ◮ Values of type term are ASTs of well-typed expressions ◮ 1 + 2 and 2 + 1 are equal, they both describe the number 3 ◮ � � � | | | 1 + 2 | | | � � � and � � � | | | 2 + 1 | | | � � � are not equal, they are different ASTs ◮ � � � | ˆ | | ˆ ˆ � � � | | | 1 | | | � + 2 | � � | | � � � and � � � | | | 1 + ˆ ˆ ˆ � � � | | | 2 | | | � � �| | | � � � are equal, they describe � � � | | | 1 + 2 | | | � � �

  9. Example - letrec � | | � � | | � comm � � | | ˆ ˆ ˆx + ˆ ˆy | ˆ | � � = � � | | ˆ ˆ ˆ(comm y) + ˆ ˆ ˆ(comm x) | | � � | comm � � � | | | ˆ ˆx | | | � � � = � � � | | | ˆ ˆ(comm x) | | | � � � ˆ ˆf ˆ ˆ ˆ ˆ(comm f) ˆ ˆ � | | � � | | � | comm � � | | λ ˆ ˆ ˆ ˆb | | � � = � � | | λ ˆ ˆ ˆ ˆ(comm b) | | � � ˆp. ˆ ˆp. ˆ | ... | comm x = x;

  10. Example - letrec � | | � � | | � comm � � | ˆ | ˆx + ˆ ˆ ˆ ˆy | | � � = � � | | ˆ ˆ ˆ(comm y) + ˆ ˆ(comm x) | ˆ | � � | comm � � � | ˆ | | ˆx | | | � � � = � � � | | | ˆ ˆ(comm x) | | | � � � ˆ ˆf ˆ ˆ ˆ ˆ(comm f) ˆ ˆ � | | � � | | � | comm � � | | λ ˆ ˆ ˆb | ˆ | � � = � � | | λ ˆ ˆ ˆ ˆ(comm b) | | � � ˆp. ˆ ˆp. ˆ | ... | comm x = x; comm: term → term -

  11. Example - letrec � | | � � | | � comm � � | | ˆ ˆx + ˆ ˆ ˆy | ˆ | � � = � � | | ˆ ˆ ˆ(comm y) + ˆ ˆ ˆ(comm x) | | � � | comm � � � | | | ˆ ˆx | | | � � � = � � � | | | ˆ ˆ(comm x) | | | � � � ˆf ˆ ˆ ˆ ˆ ˆ(comm f) ˆ ˆ � | | � � | | � | comm � � | λ ˆ | ˆ ˆb | ˆ | � � = � � | | λ ˆ ˆ ˆ ˆ(comm b) | | � � ˆp. ˆ ˆp. ˆ | ... | comm x = x; comm: term → term - comm � � � | | | y = m*x + c | | | � � � ;

  12. Example - letrec � | | � � | | � comm � � | ˆ | ˆx + ˆ ˆ ˆy | ˆ | � � = � � | | ˆ ˆ ˆ(comm y) + ˆ ˆ ˆ(comm x) | | � � | comm � � � | | | ˆ ˆx | | | � � � = � � � | | | ˆ ˆ(comm x) | | | � � � ˆf ˆ ˆ ˆ ˆ ˆ(comm f) ˆ ˆ � | | � � | | � | comm � � | λ ˆ | ˆ ˆ ˆb | | � � = � � | λ ˆ | ˆ ˆ ˆ(comm b) | | � � ˆp. ˆ ˆp. ˆ | ... | comm x = x; comm: term → term - comm � � � | | | y = m*x + c | | | � � � ; � � � | | | y = c + m*x | | | � � � : term

  13. ect The Higher Order Logic of reFL The HOL Logic  λ − calculus   +     constants: =, true, false    + axioms, inference rules     +     definitions 

  14. ect The Higher Order Logic of reFL ect Logic The reFL The HOL Logic ect  reFL  λ − calculus    +  +         constants: =, true, false constants: =, true, false       + + axioms, inference rules axioms, inference rules          + +        definitions definitions  

  15. ect The Higher Order Logic of reFL ect Logic The reFL The HOL Logic ect  reFL  λ − calculus    +  +         constants: =, true, false constants: =, true, false       + + axioms, inference rules axioms, inference rules          + +        definitions definitions   Common to Both ◮ Not everything that may be discussed may be executed ◮ let ∀ f = f = ( λ x . true ) ◮ Reductions in the language are valid inferences in the logic ◮ If Λ → true , then ⊢ Λ

  16. Levels and Their Relationships ◮ A deep embedding of LTL in HOL: 0: ML 1: HOL logic, deeply embedded in ML 2: LTL logic, deeply embedded in HOL Use the prover (level 0 program) to reason about what HOL functions (level 1) do to LTL expressions (level 2)

  17. Levels and Their Relationships ◮ A deep embedding of LTL in HOL: 0: ML 1: HOL logic, deeply embedded in ML 2: LTL logic, deeply embedded in HOL Use the prover (level 0 program) to reason about what HOL functions (level 1) do to LTL expressions (level 2) ect ◮ A shallow embedding of LTL in reFL ect 0: reFL ect expressions 1: quoted reFL ect expressions 2: twice quoted reFL Use the prover (level 0 program) to reason about what ect functions (level 1) do to reFL ect expressions (level 2) reFL

  18. Levels are Separate We want the same relationship between level n and n + 1 ect expressions as between ML and HOL reFL (or between HOL and LTL, the deeply embedded language) ◮ Level n expressions can manipulate level n + 1 expressions

  19. Levels are Separate We want the same relationship between level n and n + 1 ect expressions as between ML and HOL reFL (or between HOL and LTL, the deeply embedded language) ◮ Level n expressions can manipulate level n + 1 expressions ◮ Level n expressions don’t interpret those above level n + 1 (We don’t implement LTL reasoning directly in ML.)

  20. Levels are Separate We want the same relationship between level n and n + 1 ect expressions as between ML and HOL reFL (or between HOL and LTL, the deeply embedded language) ◮ Level n expressions can manipulate level n + 1 expressions ◮ Level n expressions don’t interpret those above level n + 1 (We don’t implement LTL reasoning directly in ML.) ◮ They do not, usually, become level n + 1 expressions (ML does not become HOL)

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend