Developing Modal Tableaux and Resolution Methods via First-Order Resolution Renate Schmidt University of Manchester Reference: Advances in Modal Logic, Vol. 6 (2006)
Modal logic: Background Established field, long history in mathematics and philosophy Popular in CS: program specification & verification, NLP, multi-agent systems, description logics, semantic web & ontology reasoning,... Commonly used MLs have many good properties: fragments of FOL, decidable, nice computational complexity language is simple & natural, powerful enough to describe useful structures s 3 e 12 b c d 5 30 s 1 s 2 a transition systems 2 2 4 trees 8 22 37 Deduktionstreffen, Koblenz, March 2007 p.2
Basic modal logic Basic modal logic K (m) = propositional logic plus [a], [b],... Ac = {a, b,...} (index set) Modal formulae φ, ψ p i φ φ ψ [a]φ a φ = def [a] φ Semantics: Kripke model M = (W, {R a a Ac}, ι) M, x = p i iff x ι(p i ) M, x = φ iff M, x = φ M, x = φ ψ iff M, x = φ and M, x = ψ M, x = [a]φ iff for all R a -successors y of x M, y = φ M, x = a φ iff for some R a -successor y of x M, y = φ Deduktionstreffen, Koblenz, March 2007 p.3
Extensions of the basic modal logic Traditional MLs: extension of K (m) with extra modal axioms epistemic ML, doxastic ML,... Dynamic MLs: extensions of K (m) with operators on actions dynamic logic PDL = K(m) (, ;,,?) description logics with role operators Reading of [a]φ Notation Logic φ is necessary φ basic modal logic K agent a knows φ K a φ epistemic logic KT 45 (m) agent a believes φ B a φ doxastic logic KD45 (m) program a causes φ [a]φ dynamic logic PDL R a -relatives of only C φ s R a.c φ description logics, ALC family Deduktionstreffen, Koblenz, March 2007 p.4
Automating reasoning in modal logic Given: Wanted: What is needed? a modal logic L an automated theorem prover for answering Γ = L ϕ? 1. a deduction calculus Cal for L 2. soundness and completeness results for Cal 3. techniques to ensure termination & efficiency 4. implementation Problem: There are infinitely many modal logics and we do not really want to repeat these steps for every new logic. Deduktionstreffen, Koblenz, March 2007 p.5
Automating reasoning in modal logic (cont d) Usual solution: Adapt and extend an existing calculus and theorem prover. Develop calculi for class of MLs and implement in one prover This talk: Develop via first-order resolution approach Systematic method for developing special-purpose calculi, much of which can be automated Which style of deduction? Modal tableau, modal resolution, Rasiowa-Sikorski calculi Deduktionstreffen, Koblenz, March 2007 p.6
Overview Tableau Rasiowa-Sikorski Resolution First-order hyperresolution Simulation of tableau by resolution Synthesis of tableau rules / calculus Simulation and reduction Soundness, completeness of synthesised calculi; decidability Synthesising direct resolution calculi & Rasiowa-Sikorski calculi Other consequences Deduktionstreffen, Koblenz, March 2007 p.7
Tableau refutation approach, testing (un)satisfiability goal-directed approach rules for each logical operator branching rules derivations are trees ϕ s : ψ 1 ψ 2 s : ψ i s : ψ 1 ψ 2 s : ψ 1 s : ψ 2 s : [α]ψ, (s, u) : α etc u : ψ In this talk: tableau = ground labelled modal tableau!! Deduktionstreffen, Koblenz, March 2007 p.8
Rasiowa-Sikorski systems proving approach, testing validity goal-directed approach rules for each logical operator branching rules derivations are trees ϕ s : ψ 1 ψ 2 s : ψ i s : ψ 1 ψ 2 s : ψ 1 s : ψ 2 s : α ψ, (s, u) : α etc u : ψ Deduktionstreffen, Koblenz, March 2007 p.9
Resolution refutation approach, testing (un)satisfiability operates on clauses two rules: resolution and factoring no branching rules required derivations are linear N......... Resolution: Factoring: C A A D C D C A A C A Deduktionstreffen, Koblenz, March 2007 p.10
The develop via first-order resolution method Basic idea: define transformation and resolution refinement which simulates behaviour of desired deduction method synthesise modal inference rules read them off from clausal form of transformation Our case study: develop ground semantic calculi Requirements: Π Cls L FOL clause logic Π, Cls efficiently computable, sound and complete, structure preserving transformations range-restriction hyperresolution with splitting Deduktionstreffen, Koblenz, March 2007 p.11
Hyperresolution Hyperresolution C 1 A 1... C n A n B 1... B n D (C 1... C n D)σ provided σ = mgu(a 1. = B1,..., A n. = Bn ), and C i A i and D are positive clauses Positive factoring C A B (C A)σ provided σ = mgu(a. = B) and C is positive Splitting N {C D} N {C} N {D} provided C and D are variable-disjoint and positive Theorem: H, H sp are sound and complete for FO clause logic. Deduktionstreffen, Koblenz, March 2007 p.12
Tableau derivation for (p q) p in K 1. a : (p q) p 2. a : (p q) 1, ( ) 1 3. a : p 1, ( ) 2 4. (a, b) : R 2, ( ) 1 5. b : p q 2, ( ) 2 6. b : p 3, 4, () 7. b : p 5, ( ) 8. b : q 5, ( ) 9. 6, 7, ( ) Deduktionstreffen, Koblenz, March 2007 p.13
Transformation to clausal form Simplified structural transformation of ϕ = (p q) p: 1. Q ϕ (a) 2. Q ϕ (x) Q (p q) (x) 3. Q ϕ (x) Q p (x) 4. Q (p q) (x) R(x, f (x)) 5. Q (p q) (x) Q p q (f (x)) 6. Q p q (x) Q p (x) Q q (x) 7. Q p (x) R(x, y) Q p (y) 8. Q p (x) Q p (x) ϕ satisfiable in K iff {1,..., 8} satisfiable in FOL Deduktionstreffen, Koblenz, March 2007 p.14
Transformation to clausal form Simplified structural transformation of ϕ = (p q) p: 1. Q ϕ (a) 2. Q ϕ (x) Q (p q) (x) x = ϕ.(x = (p q)) 3. Q ϕ (x) Q p (x) (x = p) 4. Q (p q) (x) R(x, f (x)) 5. Q (p q) (x) Q p q (f (x)) 6. Q p q (x) Q p (x) Q q (x) 7. Q p (x) R(x, y) Q p (y) 8. Q p (x) Q p (x) ϕ satisfiable in K iff {1,..., 8} satisfiable in FOL Deduktionstreffen, Koblenz, March 2007 p.14
Hyperresolution derivation 1. Q ϕ (a) a : ϕ 2. Q ϕ (x) Q (p q) (x) 3. Q ϕ (x) Q p (x) 4. Q (p q) (x) R(x, f (x)) 5. Q (p q) (x) Q p q (f (x)) 6. Q p q (x) Q p (x) Q q (x) 7. Q p (x) R(x, y) Q p (y) 8. Q p (x) Q p (x) 9. Q (p q) (a) (1, 2) a : (p q) 10. Q p (a) (1, 3) a : p 11. R(a, f (a)) (9, 4) (a, b) : R 12. Q p q (f (a)) (9, 5) b : p q Deduktionstreffen, Koblenz, March 2007 p.15
Hyperresolution derivation (cont d) 1. Q ϕ (a) 6. Q p q (x) Q p (x) Q q (x) 7. Q p (x) R(x, y) Q p (y) 8. Q p (x) Q p (x) 9. Q (p q) (a) (1, 2) 10. Q p (a) (1, 3) 11. R(a, f (a)) (9, 4) 12. Q p q (f (a)) (9, 5) 13. Q p (f (a)) (10, 11, 7) 14. Q p (f (a)) Q q (f (a)) (12, 6) 15. Q p (f (a)) 16. Q q (f (a)) (14, Sp) 17. (13, 15, 8) Deduktionstreffen, Koblenz, March 2007 p.16
Hyperresolution derivation & tableau derivation 1. Q ϕ (a) a : ϕ 6. Q p q (x) Q p (x) Q q (x) 7. Q p (x) R(x, y) Q p (y) 8. Q p (x) Q p (x) 9. Q (p q) (a) (1, 2) a : (p q) 10. Q p (a) (1, 3) a : p 11. R(a, f (a)) (9, 4) (a, b) : R 12. Q p q (f (a)) (9, 5) b : p q 13. Q p (f (a)) (10, 11, 7) b : p 14. Q p (f (a)) Q q (f (a)) (12, 6) 15. Q p (f (a)) b : p 16. Q q (f (a)) (14, Sp) b : q 17. (13, 15, 8) Deduktionstreffen, Koblenz, March 2007 p.16
Synthesising tableau rules 1. Q ψ1 ψ 2 (s) 2. Q ψ1 ψ 2 (x) Q ψ1 (x) 3. Q ψ1 (s) hyp.res, 1, 2 s : ψ 1 ψ 2 s : ψ 1 1. Q [α]ψ (s) 2. R α (s, u) 3. Q [α]ψ (x) R α (x, y) Q ψ (y) 4. Q ψ (u) hyp.res, 1, 2, 3 s : [α]ψ, (s, u) : α u : ψ 1. Q ψ1 ψ 2 (s) 2. Q ψ1 ψ 2 (x) Q ψ1 (x) Q ψ2 (x) 3. Q ψ1 (s) Q ψ2 (s) hyp.res, 1, 2 4. Q ψ1 (s) 5.Q ψ2 (s) split, 3 s : ψ 1 ψ 2 s : ψ 1 s : ψ 2 Deduktionstreffen, Koblenz, March 2007 p.17
Obtained ground tableau calculus Tab for K (m) s : ψ φ s : ψ φ ( ) 1 s : ψ ( ) 2 s : φ ( ) s : (ψ φ) s : ψ s : φ ( [ ]) 1 s : [α]ψ (s, t) : α ( [ ]) 2 s : [α]ψ t : ψ ([ ]) s : [α]ψ, (s, u) : α u : ψ ( ) s : ψ, s : ψ (c) s : (ψ ψ) s : ψ t = term uniquely associated with s : [α]ψ Deduktionstreffen, Koblenz, March 2007 p.18
Simulation Calculus C 2 step-wise simulates calculus C 1 (wrt. to Π) iff n such that inference step in C 1 there are n inference steps in C 2 which derive the corresponding conclusion.... More C2 -inferences may be possible s : ψ... H sp step-wise simulates the Q ψ (s) generated Tab (wrt. structural transformation). Theorem 1 Suppose C 2 step-wise simulates C 1. C 1 sim C 2 (i) If C 1 is (refutationally) complete then C 2 is (ref.) complete. (ii) If C 2 is sound then C 1 is sound. Deduktionstreffen, Koblenz, March 2007 p.19
Reduction Calculus C 1 is a reduct of C 2 iff n such that the inference steps in any C 2 derivation can be uniquely and exhaustively grouped into macro inference steps (of size n) corresponding to inference steps in C 1.... All C2 inferences are used s : ψ... Tab is a reduct of H sp (wrt. Q ψ (s) structural transformation). Theorem 2 Suppose C 1 is a reduct of C 2. C 1 C 2 red (i) If C 2 is (ref.) complete then C 1 is (ref.) complete. (ii) If C 1 is sound then C 2 is sound.
Simulation & reduction Corollary 3 sim Suppose C 1 C 2 Then red (i) If C 2 is sound and complete, then C 1 is sound and complete. (ii) If C 2 is a decision procedure, then C 1 is a decision procedure. Deduktionstreffen, Koblenz, March 2007 p.21
Tab: Soundness, completeness and decidability Theorem 4 (i) H sp on structural clause form Tab step-wise simulates Tab. (ii) Tab is a reduct of H sp on structural clause form. sim red H sp Theorem 5 (JIGPL 2000) H sp, H decide a clausal class subsuming the structural clausal form associated with K (m). Corollary 6 (i) Tab w/wo contraction is sound, complete. (ii) Tab provides a decision procedure for K (m). Deduktionstreffen, Koblenz, March 2007 p.22
Case studies for different logics Tableau synthesis via first-order resolution: Dynamic modal logic K(m) (,,, ) [AiML 2006] Description logic with modal operators ALCM [Mostafavi 2007] Common traditional modal logics [CADE 2003, TOCL] Linear simulation by first-order resolution modal ground labelled tableau, single-step prefix tableau [FTP98, JIGPL 2000, SAT 2000] tableau for ALC with non-empty TBoxes [IJCAI 1999] Deduktionstreffen, Koblenz, March 2007 p.23
Variations of the method Varying the definition of resolution calculus [AiML 2006] Variation Res Generated calculi H sp tableau calculi omit splitting H modal resolution calculi add ordering OH ordered modal resolution calculi dualise DH sp Rasiowa-Sikorski calculi DH DOH dual modal resolution dual ordered modal resolution Deduktionstreffen, Koblenz, March 2007 p.24
Variations of the method (cont d) Varying the translation to FOL [TOCL] Translation Res Generated calculi std relational H sp tableaux using structural rules functional H sp prefix tableau calculi axiomatic H sp tableaux using propagation rules Deduktionstreffen, Koblenz, March 2007 p.25
Develop via f.o. resolution method: Contribution Non-standard application of first-order resolution Method for synthesis of semantic ground calculi (tableau, dual tableau, direct resolution) Automatic soundness and completeness Other transferring properties: - decidability - finite model building - complexity Techniques carrying over: - ordering restrictions - different notions of redundancy Deduktionstreffen, Koblenz, March 2007 p.26
Other consequences Easy back-translation of resolution derivations to modal logic derivations Demo First-order resolution provers can be used as special-purpose provers free provers / implemented decision procedures fast prototyping Uniform framework for comparing different calculi Deduktionstreffen, Koblenz, March 2007 p.27
Analytical comparison of different calculi Tab sim red H sp d-sim d-red d-sim d-red RS sim red DH sp Res sim red H ORes sim red OH d-sim d-red d-sim d-red d-sim d-red d-sim d-red DRes sim red DH DORes sim red DOH Deduktionstreffen, Koblenz, March 2007 p.28
Empirical comparison with TABSPASS Selection refinement with splitting Selection refinement without splitting 1000 1000 100 100 10 10 1 1 0.1 0.1 0.01 100 90 80 70 60 10 15 20 25 L/N 30 35 40 0.01 100 90 80 70 60 10 15 20 25 L/N 30 35 40 [SAT 2000] Deduktionstreffen, Koblenz, March 2007 p.29
Further work Methodology extends to: other logics other styles of deduction calculi Implementing a tableau calculus generator and generator of other styles of deduction calculi... Deduktionstreffen, Koblenz, March 2007 p.30