Articles

Recepción: 01 Septiembre 2021
Publicación: 15 Diciembre 2021
DOI: https://doi.org/10.15388/LMR.2021.25215
Abstract: In this paper authors research the problem of traceability of assumptions in logical derivation. The essence of this task is to trace which assumptions from the available knowledge base of assumptions are necessary to derive a certain conclusion. The paper presents a new derivation procedure for propositional logic, which ensures traceability feature. For the derivable conclusion formula derivation procedure also returns the smallest set of assumptions those are enough to get derivation of the conclusion formula. Verification of the procedure were performed using authors implementation.
Keywords: propositional logic, traceability, loop checking.
Summary: Šiame darbe autoriai nagrine˙ja loginio išvedimo iš prielaidu˛ atsekamumo problemą. Šio uždavinio esme˙ yra atsekti, kurios prielaidos iš turimos prielaidu˛ žiniu˛ baze˙s yra bu¯tinos tam tikros išvados išvedimui. Darbe pristatoma nauja teiginiu˛ logikai skirta išvedimo procedu¯ra užtikrinanti prielaidu˛ atsekamumo savybę. Išvedamai formulei išvedimo procedu¯ra grąžina ir mažiausią prielaidu˛ aibę, kurios užtenka išvados formule˙s išvedimui gauti. Procedu¯ra verifikuota su autoriu˛ realizacija.
Keywords: teiginiu˛ logika, atsekamumas, ciklu˛ aptikimas.
Introduction
In the recent decades artificial intelligence is increasingly used by software developers to provide more and more smart systems. One of the areas of the artificial intelligence is formal logics. There are lots of classical methods for logical derivation. Some of them are applicable for particular logic, some of them are universal methods, those may be applied for a big set of logics. The most widely used methods are sequent calculi, resolution methods, tableaux methods [5]. The logic to be chosen depends on the application scope and may vary from the propositional logic, predicate logic, descriptive logic and different modal logics. The goal of these methods is to determine if given formula (conclusion) is derivable from the set of assumption formulas. Different provers based on the different calculi or derivation procedures are already implemented and used in real word applications.
In the real applications we use knowledge bases, those contain hundreds, thousands or even much more assumptions. Most of the assumptions are not related to the particular goal formula. Usually prover, especially if we take a general-purpose prover, returns simple result – if given conclusion formula is derivable or non-derivable. For the most applications such a simple result is enough. For some application we also need the smallest set of assumptions, those are enough to get a derivation of given conclusion formula.
For example, suppose we have logic-based intelligent system for reasoning on requirements of legal acts. Our knowledge base is a set of assumptions (logic formulas), those describe particular requirements, restrictions presented in the legal acts. Suppose, our system may check if some given restriction, requirement shall be applied or not, or some action, operation is legal or not in the particular situation. Using classical prover, we will be able to provide the main answer – is it applicable or not. But in the example case, it is not enough. The system user should be able to explain the decision correctness – to present the set of legal act requirements, those leads to the decision. Therefore, we also need the set of assumptions (related to particular legal requirements) used to derive our conclusion.
General purpose calculi and decision procedures do not care about assumption traceability. Usually they may by modified to return used assumptions. Unfortunately, the returned set of assumptions may contain unnecessary assumptions, those are not needed for the derivation, but they were used during derivation. There can be few different derivation trees based on the different assumptions, classical methods will return only one of them. As a result, we may get the set of used assumptions containing 50 or 100 assumptions, even if there exist a small set of 5 or 10 assumptions, those are enough to prove a goal formula. Therefore, we need methods those ensure assumption traceability feature – returning the smallest set of assumptions for provided formula derivation.
There is also other research area of the traceability. When a set of used assumptions to derive some goal and derivation tree is already presented, we may analyse the decision tree itself to get even more useful information. Sometimes formal logics are also used for such a reasoning. Such a research may be found in [3].
In the next section we will introduce a new propositional logic method with assumption traceability feature. We will call it “Decision procedure with assumption traceability for the propositional logic”, or shortly PWATPL procedure. For creating PWATPL procedure some techniques were used – indexing formulas and loop checking. Indexing formulas are widely used in logical calculi for different modal logics. Usually indexing formulas are used to show finality, completeness or soundness of the calculus (see [4, 6]). We use indexed formulas for the different purpose. We will introduce 2 level indexes: the first is used to ensure the smallest set of assumptions, the second – to ensure traceability itself. Loop checking technique for some modal logics are used to achieve the finality of the calculus (see [1]). We will use loop checking to ensure completeness and soundness of our method.
1 Derivation procedure
Suppose we have the set of premises (assumption formulas) and the goal formula
Definition 1. Suite is a structure: where:
– 2-level clause indices.
– the state of the suite.
– looping literals of this suite; not used for closed suites.
Example 1. Suite is a loop suite (with looping literals and ), containing indeces, those refer to clauses from 2 premises .
Definition 2. Joint (union) suite of the suites and is a new suite where state st= closed if closed, and, otherwise, st= loop.
Definition 3. Literal structure LS = ⟨state,setOfSuites⟩, where:
state ∈ {init,started,finished} – current state.
setOfSuites – set of suites assigned to the literal.
Initialization:
, where is a disjunctive clause (further clause).PWATPL procedure for the goal formula G derivation follows:
Conjunct
derivation procedure deriveConjunct() follows:

is obtained similar to getting Cortesian product – every suite form should be joint (union operation) with every suite from and the result suites – with every suite from and so on. If , for any is also an empty set. contains suites, from which conjunct is derivable.
Now we introduce helper suite generation procedure genSuites(suiteMap,C(p)). It generates suites for the literal p from suites of the literals containing in the same clause.
Suppose clause and suite map for literals is suiteMap is a set of the suites of the literal
Procedure genSuites(suiteMap,C(p)) generates new suites for literal p as follows:
– all posible unions of m suites taking one suite per one literal (like Cartesian product).
Finally, we present the main procedure getSuitesFor(). It returns the set of suites literal is derivable from.
For the further text, by the ¬c we denote the opposite literal to c: if , then if then Therefore, does not mean, that literal has negation.
Procedure getSuitesFor() follows:


The following examples explain the main idea of the used loop-checking (good and bad loops) in the procedure.
Example 2 |Good-loop|. Suppose we have the set of clauses
Clauses creates “good-loop” for y, since for deriving p using it is enough to derive q ∨ p (and z): to derive p from the p ∨ ¬q ∨ ¬z, we need to derive q and z, to derive q, we need to derive y, to derive y, we need to derive ¬p. Since p is our goal, there is no need to eliminate p at all – we leave it in a loop suite.
Clauses p ∨ ¬q ∨ ¬z,z ∨ ¬p creates another “good-loop” for z.
Therefore, we create loop suites: [3.1;loop;p] for y and, as a result, we create loop suite [2.1,3.1;loop;p] for q, and [4.1;loop;p] for z.
Finally, from loop suites [2.1,3.1;loop;p] and [4.1;loop;p] we generate closed loop [1.1,2.1,3.1,4.1;closed;] for p.
Remark that q and z are non-derivable by themselves form the given set S. Example
Example 3 [Bad-loop]. Suppose we have the set of clauses
Clauses p∨¬q∨¬z,q∨¬y, y∨¬p creates “bad-loop”, since it is impossible to derive p using these clauses: to derive p from the p ∨ ¬q ∨ ¬z, we need to derive q and z, to derive q, we need to derive y, to derive y, we need to derive p. But p is our goal. Therefore, there is no sense to use such a derivation path for p derivation.
Despite this, it does not mean, that y is not derivable by itself using clause is not useful for p derivation, but y may be derived from the and . This is the reason, we cannot mark y as non-derivable if “bad-loop” was found. We just mark it is explored for particular derivation path. Derivation procedure still derives y.
Note, that p is still derivable from the set {D1.1,D2.1,D4.1,D5.1} in the given example, and PWATPL procedure returns suite [1.1,2.1,4.1,5.1;closed].
At first sight, it may look like PWATPL procedure is polynomial, since we explore every literal once. Unfortunately, it is not a true. “Bad loops” cause us to mark literals as explored for particular derivation path only. It means the same literal may be explored for the second time, and, therefore, we get an exponential complexity. It is not surprise, since it is 3SAT problem, which is known to be NP-complete according Cook theorem [2].
Lemma 1. If Derivation procedure getSuitesFor(p) for literal p returns suite loop/closed; then clause p∨q1 ∨q2 ∨···∨qk is derivable from the set of clauses S = {Di1,Di2,...,Din} using Resolution method.
Proof. The proof goes from mathematical induction according suite size S size – n.
Lemma 2. If clause is derivable from the set of clauses then suite loop/closed; will be returned by the Derivation procedure getSuitesFor(p).
Proof. The proof goes from mathematical induction according clause derivation length m using Resolution method.
As the special case, we get, that literal p is derivable from the set of clauses S =
As the special case, we get, that literal p is derivable from the set of clauses using Resolution method if and only if suite [ closed] is returned by the Derivation procedure getSuitesFor(p).
Therefore, PWATPL procedure is equivalent to classical Resolution method.
2 Conclusions
PWATPL procedure is a decision procedure with assumption traceability feature for propositional logic. Suites structures were used to “catch” loops, and 2 level indices were used to ensure getting smallest set of the used assumptions as a result. Despite PWATPL procedure returns much more information (set of needed and enough assumptions) comparing with classical derivation methods, its complexity is still as the Resolution method complexity for the worst case.
References
1. R. Alonderis, H. Giedra, A. Pliuškevičiene˙, R. Pliuškevičius. Loop-type sequent calculi for temporal logic. J. Autom. Reason., 64:1663—-1684, 2020.
2. S.A. Cook. The complexity of theorem-proving procedures. In Conference Record of Third Annual ACM Symposium on Theoryof Computing, pp. 151—-158, 1971.
3. J. Dick. Rich traceability. In Proc. 1st TEFSE, pp. 18–23, 2002.
4. G. Mints. Indexed systems of sequents and cut-elimination. J. Philos. Log., 26(6):671– 696, 1997.
5. S. Norge˙la. Matematine˙ logika. TEV, Vilnius, 2004.
6. A. Pliuškevičiene˙, R. Pliuškevičius. A new method to obtain termination in backward proof search for modal logic s4. J. Log. Comput., 20(1):353—-379, 2010.