tableaux modulo theories using superdeduction
play

Tableaux Modulo Theories using Superdeduction An Application to the - PowerPoint PPT Presentation

Tableaux Modulo Theories using Superdeduction An Application to the Verification of B Proof Rules with the Zenon Automated Theorem Prover David Delahaye David.Delahaye@cnam.fr CPR Team / Deducteam (CEDRIC / Inria) CPR / Deducteam Seminar


  1. Tableaux Modulo Theories using Superdeduction An Application to the Verification of B Proof Rules with the Zenon Automated Theorem Prover David Delahaye David.Delahaye@cnam.fr CPR Team / Deducteam (CEDRIC / Inria) CPR / Deducteam Seminar Inria, Paris June 8, 2012

  2. Introduction Collaboration with Siemens (IC-MOL) M. Jacquel’s PhD thesis, superv. by K. Berkani, D. Delahaye, C. Dubois ; VAL, automatic metro systems, optical guidance for buses/trolleybuses ; Meteor line (line 14) at Paris, opened 13 years ago. D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 1 / 12

  3. Use of the B Method The B Method Defined in the B-Book (1996) by J.-R. Abrial ; Based on a (typed) set theory ; Generation of executable code which conforms to formal specifications ; Notion of machines, which are refined until implementations ; Generation of proof obligations (consistency, refinement) ; Supporting tool : Atelier B (ClearSy). Proof Activity with Atelier B Automated proofs (pp) ; Interactive proofs : ◮ Apply some tactics ; ◮ Add some rules (axioms). If the added rule is wrong then : ◮ The proof of the proof obligation may be unsound ; ◮ The generated code may contain some bugs. D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 2 / 12

  4. Use of the B Method The B Method Defined in the B-Book (1996) by J.-R. Abrial ; Based on a (typed) set theory ; Generation of executable code which conforms to formal specifications ; Notion of machines, which are refined until implementations ; Generation of proof obligations (consistency, refinement) ; Supporting tool : Atelier B (ClearSy). Figures Meteor : 27,800 proof obligations, 1,400 added rules ; Currently about 5,300 rules in the rule database of Siemens. D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 2 / 12

  5. Rule Verification Rules Set formulas with metavariables and guards ; Deduction rule : → B ) ∧ ( a ∈ dom ( f )) ∧ ( f ( a ) ∈ u ) ⇒ ( a ∈ f − 1 [ u ]) InSetXY : binhyp ( f ∈ A � Rewrite rule : Associativity : a ∪ ( b ∪ c ) == a ∪ b ∪ c Verification Process Variable Capture OK Typing KO OK Rule Well- Definedness OK B Theorem D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 3 / 12

  6. The BCARe Environment Rewrite Zenon Variable Rule Checking Rule Proofs : Type - Type-checking Inference - Well-definedness Fail - Verification of the rule Rule Modifiation Fail D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 4 / 12

  7. Automated Verification of Rules L tac Approach Proof algorithm written in Coq using L tac ; Preliminary normalization to get rid of set constructs ; Naive and incomplete heuristic ; No unification, no contraction. Zenon Approach Use of a complete and efficient ATP ; Preliminary normalization (as previously) ; Unreification of formulas required ; Rereification of the generated Coq proofs. D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 5 / 12

  8. Benchmarks Derived Rules 0 5 10 15 20 25 30 30 30 25 25 71% 20 20 Zenon 15 15 10 10 5 5 0 0 0 5 10 15 20 25 30 Ltac Proof Times using Zenon and L tac (in s) D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 6 / 12

  9. Benchmarks Figures Derived rules of the B-Book : ◮ For 71% of the rules of the graph, Zenon is faster than L tac ; ◮ Over 200 tested derived rules, 15 of them cannot be proved using L tac . Added rules of the rule database of Siemens : ◮ 1735 tested rules (only rules with set operators) ; ◮ 1269 rules (73%) proved by the Zenon approach ; ◮ 804 rules (46%) proved by the L tac approach. See the SEFM’11 paper for more details. Problems Incomplete approaches (preliminary normalization) ; Weak performances in terms of time (preliminary normalization). D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 6 / 12

  10. Deduction Modulo and Superdeduction Inclusion ∀ a ∀ b (( a ⊆ b ) ⇔ ( ∀ x ( x ∈ a ⇒ x ∈ b ))) Proof in Sequent Calculus Ax . . . , x ∈ A ⊢ A ⊆ A , x ∈ A ⇒ R . . . ⊢ A ⊆ A , x ∈ A ⇒ x ∈ A ∀ R Ax . . . ⊢ A ⊆ A , ∀ x ( x ∈ A ⇒ x ∈ A ) . . . , A ⊆ A ⊢ A ⊆ A ⇒ L . . . , ( ∀ x ( x ∈ A ⇒ x ∈ A )) ⇒ A ⊆ A ⊢ A ⊆ A ∧ L A ⊆ A ⇔ ( ∀ x ( x ∈ A ⇒ x ∈ A )) ⊢ A ⊆ A ∀ L × 2 ∀ a ∀ b (( a ⊆ b ) ⇔ ( ∀ x ( x ∈ a ⇒ x ∈ b ))) ⊢ A ⊆ A D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 7 / 12

  11. Deduction Modulo and Superdeduction Inclusion ∀ a ∀ b (( a ⊆ b ) → ( ∀ x ( x ∈ a ⇒ x ∈ b ))) Rewrite Rule ( a ⊆ b ) → ( ∀ x ( x ∈ a ⇒ x ∈ b )) Proof in Deduction Modulo Ax x ∈ A ⊢ x ∈ A ⇒ R ⊢ x ∈ A ⇒ x ∈ A ∀ R , A ⊆ A → ∀ x ( x ∈ A ⇒ x ∈ A ) ⊢ A ⊆ A D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 7 / 12

  12. Deduction Modulo and Superdeduction Inclusion ∀ a ∀ b (( a ⊆ b ) → ( ∀ x ( x ∈ a ⇒ x ∈ b ))) Computation of the Superdeduction Rule Γ ⊢ ∀ x ( x ∈ a ⇒ x ∈ b ) , ∆ Γ ⊢ a ⊆ b , ∆ D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 7 / 12

  13. Deduction Modulo and Superdeduction Inclusion ∀ a ∀ b (( a ⊆ b ) → ( ∀ x ( x ∈ a ⇒ x ∈ b ))) Computation of the Superdeduction Rule Γ , x ∈ a ⊢ x ∈ b , ∆ ⇒ R Γ ⊢ x ∈ a ⇒ x ∈ b , ∆ ∀ R , x �∈ Γ , ∆ Γ ⊢ ∀ x ( x ∈ a ⇒ x ∈ b ) , ∆ Γ ⊢ a ⊆ b , ∆ D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 7 / 12

  14. Deduction Modulo and Superdeduction Inclusion ∀ a ∀ b (( a ⊆ b ) → ( ∀ x ( x ∈ a ⇒ x ∈ b ))) Computation of the Superdeduction Rule Γ , x ∈ a ⊢ x ∈ b , ∆ IncR , x �∈ Γ , ∆ Γ ⊢ a ⊆ b , ∆ Proof in Superdeduction Ax x ∈ A ⊢ x ∈ A IncR ⊢ A ⊆ A D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 7 / 12

  15. Integrating Superdeduction to Zenon The Tableau Method We start from the negation of the goal (no clausal form) ; We apply the rules in a top-down fashion ; We build a tree whose each branch must be closed ; When the tree is closed, we have a proof of the goal. Closure and Cut Rules ⊥ ⊙ ⊥ ¬⊤ ⊙ ¬⊤ cut P | ¬ P ⊙ ⊙ ¬ R r ( t , t ) ⊙ r R s ( a , b ) ¬ R s ( b , a ) ⊙ s P ¬ P ⊙ ⊙ ⊙ ⊙ D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 8 / 12

  16. Integrating Superdeduction to Zenon Analytic Rules ¬ ( P ⇔ Q ) ¬¬ P α ¬¬ P ⇔ Q β ⇔ β ¬⇔ P ¬ P , ¬ Q | P , Q ¬ P , Q | P , ¬ Q ¬ ( P ∨ Q ) α ¬∨ ¬ ( P ⇒ Q ) α ¬⇒ P ∧ Q α ∧ P , Q ¬ P , ¬ Q P , ¬ Q ¬ ( P ∧ Q ) β ¬∧ P ∨ Q β ∨ P ⇒ Q β ⇒ P | Q ¬ P | Q ¬ P | ¬ Q ∃ x P ( x ) ¬∀ x P ( x ) δ ∃ δ ¬∀ P ( ǫ ( x ) . P ( x )) ¬ P ( ǫ ( x ) . ¬ P ( x )) D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 8 / 12

  17. Integrating Superdeduction to Zenon γ -Rules ∀ x P ( x ) γ ∀ M ¬∃ x P ( x ) γ ¬∃ M P ( X ) ¬ P ( X ) ∀ x P ( x ) γ ∀ inst ¬∃ x P ( x ) γ ¬∃ inst P ( t ) ¬ P ( t ) Relational Rules Equality, reflexive, symmetric, transitive rules ; Are not involved in the computation of superdeduction rules. D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 8 / 12

  18. Integrating Superdeduction to Zenon Computation of Superdeduction Rules S ≡ closure rules, analytic rules, γ ∀ M and γ ¬∃ M rules ; Axiom : R : P → ϕ ; A positive superdeduction rule R (and a negative one ¬ R ) : ◮ We initialize the procedure with the formula ϕ ; ◮ We apply the rules of S until there is no applicable rule anymore ; ◮ We collect the premises and the conclusion, and replace ϕ by P . If metavariables, we add an instantiation rule R inst (or ¬ R inst ). Example (inclusion) ¬∀ x ( x ∈ a ⇒ x ∈ b ) δ ¬∀ ∀ x ( x ∈ a ⇒ x ∈ b ) γ ∀ M ¬ ( ǫ x ∈ a ⇒ ǫ x ∈ b ) α ¬⇒ X ∈ a ⇒ X ∈ b β ⇒ ǫ x ∈ a , ǫ x �∈ b X �∈ a | X ∈ b with ǫ x = ǫ ( x ) . ¬ ( x ∈ a ⇒ x ∈ b ) D. Delahaye (CPR / Deducteam, CEDRIC / Inria) Tableaux Modulo Theories & Superdeduction CPR / Deducteam Seminar 8 / 12

Recommend


More recommend