1 Introduction
Firstorder modal logics (FMLs) [4]
have many applications, e.g., in planning, natural language processing, program verification, querying knowledge bases, and modeling communication. These applications motivate the use of
automated theorem proving (ATP) systems for FMLs. Several new FML ATP systems, including two FMLtoHOLbased solutions, have recently been provided [1].This paper describes the FMLtoHOL tool, which automatically converts problems in FML, formulated in the new qmfsyntax [5] (which extends the TPTP folsyntax [7] with operators #box and #dia), into problems in classical higherorder logic (HOL), formulated in thf0syntax [6]. FMLtoHOL exploits and implements a semantic embedding of constant domain FML in HOL [2, 3]. Moreover, the tool extends this embedding to varying and cumulative domain semantics.
FMLtoHOL thus turns any thf0compliant HOL ATP system — such as LEOII^{1}^{1}1Cf. www.leoprover.org and www.ps.unisaarland.de/~cebrown/satallax/ and Satallax — into a flexible ATP system for FML. At present FMLtoHOL supports modal logics K,K4,D,D4,T,S4,S5, all with respect to constant, varying and cumulative domain semantics. Extending the tool to other normal FMLs and their combinations is straightforward.
In the remainder the language of FML is fixed as: . The symbols are ary () relation constants which are applied to terms . The () are ordinary firstorder terms and they may contain function symbols. The formula is used as an example, it is referred to as E1. In constant domain (resp. varying domain) semantics E1 is a theorem (resp. countersatisfiable) for logics . In cumulative domain semantics E1 is a theorem for S5 and countersatisfiable for the other logics in .
2 Theory of FMLtoHOL
FMLtoHOL exploits the fact that Kripke structures can be elegantly embedded in HOL [2, 3]: FML propositions are associated with HOL terms of predicate type . Type denotes the set of truth values and type is associated with the domain of possible worlds. Thus, the application corresponds to the evaluation of FML proposition in world . Consequently, validity is formalized as . Classical connectives like and are simply lifted to type as follows: and . is modeled as , where constant symbol denotes the accessibility relation of the operator, which remains unconstrained in logic K. Further logical connectives are defined as usual: , , . To obtain e.g. modal logics D, T, S4, and S5, is axiomatized as serial, reflexive, reflexive and transitive, and an equivalence relation, respectively. Arbitrary normal modal logics extending K can be axiomatized this way.
For individuals a further base type is reserved in HOL. Universal quantification is introduced as syntactic sugar for , where is defined as follows: . For existential quantification, is introduced. is then syntactic sugar for . ary relation symbols P, ary function symbols and individual constants in FML obtain types , (both with for ) and , respectively.
For any FML formula holds: is a valid in modal logic K for constant domain semantics if and only if is valid in HOL for Henkin semantics. This correspondence provides the foundation for proof automation of FMLs with HOLATP systems. The correspondence follows from [2], where a more general result is shown for FMLs with additional quantification over Boolean variables.
The above approach is adopted for varying domain semantics as follows: 1. is now defined as , where relation (for ’exists in world’) relates individuals with worlds. 2. The nonemptiness axiom for these individual domains is added. 3. For each individual constant symbol an axiom is postulated; these axioms enforce the designation of in the individual domain of each world . Analogous designation axioms are required for function symbols.
For cumulative domain semantics the axiom is additionally postulated. It states that the individual domains are increasing along relation .
3 Implementation and Functionality of FMLtoHOL
FMLtoHOL is implemented as part of the TPTP2X tool [7]. TPTP2X is a multifunctional utility for generating, transforming, and reformatting TPTP problem files. It is written in Prolog and it can be easily modified and extended.
The tool is invoked as “tptp2X f thf:<logic>:<domain> <qmffile>” where K,K4,D,D4,T,S4,S5 and .
To illustrate its use it is assumed that file E1.qmf contains E1 in qmfsyntax:
qmf(con,conjecture,( ( ! [X] : ( #box : ( f(X) ) ) ) => ( #box : ( ! [X] : ( f(X) ) ) ) )).
“tptp2X f thf:d:const E1.qmf” generates the corresponding HOL problem file E1.thf in thfsyntax^{2}^{2}2Some explanations: ^ is abstraction and @ an (explicit) application operator. !, ?, ~, , and => encode universal and existential quantification, negation, disjunction and implication in HOL. mu > $i > $o encodes the HOL type . mimplies, mforall_ind, and mbox_d are embedded logical connectives as described in Sect. 2. Their denotation is fixed by adding definition axioms; see e.g. mforall_ind below. [6] for constant domain logic D:
%Include axioms for modal logic D under constant domains include(’Axioms/LCL013^0.ax.const’). include(’Axioms/LCL013^2.ax’). % thf(f_type,type,( f: mu > $i > $o )). % type declaration for constant f thf(prove,conjecture,( mvalid @ ( mimplies @ ( mforall_ind @ ^ [X: mu] : ( mbox_d @ ( f @ X ) ) ) @ ( mbox_d @ ( mforall_ind @ ^ [X: mu] : ( f @ X ) ) ) ) )).
The included axiom files contain the definitions of the logical connectives as outlined in Sect. 2. For example, the definition for mforall_ind (which realizes for constant domain semantics) is given in LCL013^0.ax.const:
thf(mforall_ind,definition,( mforall_ind = ( ^ [Phi: mu > $i > $o, W: $i] : ! [X: mu] : ( Phi @ X @ W ) ) )).
LCL013^2.ax contains the definition of the serial operator in logic D:
thf(mbox_d,definition,( mbox_d = ( ^ [Phi: $i > $o,W: $i] : ! [V: $i] : ( ~ ( rel_d @ W @ V )  ( Phi @ V ) ) ) )). thf(a1,axiom,( mserial @ rel_d )).
Similar definitions are provided in the included axiom files for the other logical connectives and for auxiliary terms like mserial. The HOL ATP systems LEOII and Satallax when applied to E1.thf find a proof within a few milliseconds.
When FMLtoHOL is called with option “f thf:s5:vary” a modified file E1.thf is created containing a conjecture identical to above except that mbox_d is replaced by mbox_s5. Moreover, E1.thf now includes different axiom files LCL013^0.ax.vary and LCL013^6.ax. The former contains a modified definition of mforall_ind, which incorporates an explicit ’exists in world’ condition:
thf(mforall_ind,definition,( mforall_ind = ( ^ [Phi: mu > $i > $o,W: $i] : ! [X: mu] : ( ( exists_in_world @ X @ W ) => ( Phi @ X @ W ) ) ) )). thf(nonempty_ax,axiom,( ! [V : $i] : ? [X : mu] : (exists_in_world @ X @ V))).
The latter axiom specifies the domains of existing objects as nonempty for all worlds worlds . Axiom file LCL013^6.ax specifies mbox_s5 as follows:
thf(mbox_s5,definition,( mbox_s5 = ( ^ [Phi: $i > $o,W: $i] : ! [V: $i] : ( ~ ( rel_s5 @ W @ V )  ( Phi @ V ) ) ) )). thf(a1,axiom,( mreflexive @ rel_s5 )). thf(a2,axiom,( mtransitive @ rel_s5 )). thf(a3,axiom,( msymmetric @ rel_s5 )).
For the modified problem Satallax finds a counter model within milliseconds.
4 Discussion and Outlook
The FMLtoHOL has been applied and evaluated in combination with the HOL ATP systems Satallax and LEOII; cf. [1] for details. In this case study the approach has also been compared with other, heterogeneous FML ATP systems. The FMLtoHOL based solution has the best coverage (and it can easily be extended to other modal logics and their combinations) and it is second best in overall performance behind the clausal connection prover MleanCoP^{3}^{3}3Cf. the information at http://www.iltp.de/qmltp/systems.html.
Future work includes several optimizations of the tool, extensions for multimodal logics (which it already partly supports), and further case studies. These case studies should evaluate the tool also in combination with other thf0compliant HOL provers and model finders as outlined in [6]: TPS, Isabelle, Refute and Nitpick.
A recent observation is that the HOL model finders Satallax, Refute
and Nitpick apparently work well for constant and varying domain
semantics but have problems to find counter models for
cumulative domain semantics.
Acknowledgements:
We thank Jens Otten, Geoff Sutcliffe and Chad Brown for their support and their valuable input to this work.
References
 [1] C. Benzmüller, T. Raths and J. Otten. Implementing and Evaluating Provers for Firstorder Modal Logics, Proceedings of ECAI’2012, to appear.
 [2] C. Benzmüller and L. C. Paulson. Quantified Multimodal Logics in Simple Type Theory. Logica Universalis, 2012. DOI:10.1007/s117870120052y
 [3] C. Benzmüller and L. C. Paulson, Exploring Properties of Normal Multimodal Logics in Simple Type Theory with LEOII. In Festschrift in Honor of Peter B. Andrews on His 70th Birthday, 2008. College Publications.
 [4] M. Fitting and R. L. Mendelsohn. FirstOrder Modal Logic. Kluwer, 1998.

[5]
T. Raths and J. Otten. The QMLTP Problem Library for Firstorder Modal Logics. The 6th International Joint Conference on Automated Reasoning (IJCAR), Manchester, UK, 2012.
 [6] G. Sutcliffe and C. Benzmüller. Automated Reasoning in HigherOrder Logic using the TPTP THF Infrastructure. Journal of Formalized Reasoning, 3(1):127, 2010.
 [7] G. Sutcliffe. The TPTP Problem Library and Associated Infrastructure: The FOF and CNF Parts, v3.5.0. Journal of Automated Reasoning, 43(4):337–362, 2009.
Comments
There are no comments yet.