# A Heuristic Proof Procedure for First-Order Logic

Inspired by the efficient proof procedures discussed in Computability logicJap03,Japic,Japfin, we describe a heuristic proof procedure for first-order logic. This is a variant of Gentzen sequent system and has the following features: (a) it views sequents as games between the machine and the environment, and (b) it views proofs as a winning strategy of the machine. From this game-based viewpoint, a poweful heuristic can be extracted and a fair degree of determinism in proof search can be obtained. This article proposes a new deductive system LKg with respect to first-order logic and proves its soundness and completeness.

## Authors

• 9 publications
• ### A new viewpoint of the Gödel's incompleteness theorem and its applications

A new viewpoint of the Gödel's incompleteness theorem be given in this a...
05/08/2018 ∙ by Tianheng Tsui, et al. ∙ 0

• ### Automated proof search system for logic of correlated knowledge

The automated proof search system and decidability for logic of correlat...
02/23/2019 ∙ by Haroldas Giedra, et al. ∙ 0

• ### Working with first-order proofs and provers

Verifying software correctness has always been an important and complica...
03/18/2019 ∙ by Michael Raskin, et al. ∙ 0

• ### A Curiously Effective Backtracking Strategy for Connection Tableaux

Automated proof search with connection tableaux, such as implemented by ...
06/25/2021 ∙ by Michael Färber, et al. ∙ 0

• ### Dialogues for proof search

Dialogue games are a two-player semantics for a variety of logics, inclu...
05/08/2014 ∙ by Jesse Alama, et al. ∙ 0

• ### The Abstract Machinery of Interaction (Long Version)

This paper revisits the Interaction Abstract Machine (IAM), a machine ba...
02/13/2020 ∙ by Beniamino Accattoli, et al. ∙ 0

• ### Yet another argument in favour of NP=CoNP

This article shows yet another proof of NP=CoNP. In a previous article, ...
12/28/2020 ∙ by Edward Hermann Haeusler, et al. ∙ 0

##### This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

## 1 Introduction

The Gentzen sequent system LK plays a key role in modern theorem proving. Unfortunately, the LK system and its variants such as LK (as well as resolution and tableux (see [6] for discussions)) are typically based on blind search and, therefore, does not provide the best strategy if we want a short proof.

In this paper, inspired by the seminal work of [1], we present a variant of LK, called LKg (g for game), which yields a proof in normal form with the following features:

• All the quantifier inferences are processed first. This is achieved via deep inference.

• If there are several quantifiers to resolve in the sequent, we apply to sequents a technique called stability analysis, a powerful heuristic technique which greatly cuts down the search space for finding a proof.

In essence, LKg is a - proof which captures - nature in proof search. It views

1. sequents as games between the machine and the environment,

2. proofs as a winning strategy of the machine, and

3. as the env’s move and as the machine’s move.

At each stage, we construct a proof by the following rules:

1. If the sequent is stable, then it means that the machine is the current winner. In this case, it requests the user to make a move.

2. If the sequent is instable, then it means that the environment is the current winner. In this case, the machine makes a move.

In this way, a fair (probably maximum) degree of determinism can be obtained from the LKg proof system.

In this paper we present the proof procedure for first-order classical logic. The remainder of this paper is structured as follows. We describe LKg in the next section. In Section 3, we present some examples of derivations. In Section 4, we prove the soundness and completeness of LKg. Section 5 concludes the paper.

## 2 The logic LKg

The formulas are the standard first-order classical formulas, with the features that (a) are added, and (b) is only allowed to be applied to atomic formulas. Thus we assume that formulas are in negation normal form.

The deductive system LKg below axiomatizes the set of valid formulas. LKg is a one-sided sequent calculus system, where a sequent is a multiset of formulas. Our presentation closely follows the one in [1].

First, we need to define some terminology.

1. A surface occurrence of a subformula is an occurrence that is not in the scope of any quantifiers ( and/or ).

2. A sequent is propositional iff all of its formulas are so.

3. The propositionalization of a formula is the result of replacing in all -subformulas by , and all -subformulas by . The propositionalization of a sequent is the propositional formula

4. A sequent is said to be stable iff its propositionalization is classically valid; otherwise it is unstable.

5. The notation repesents a formula together with some surface occurrence of a subformula .

LKg has the five rules listed below, with the following additional conditions:

1. :stable means that must meet the condition that it is stable. Similarly for :unstable.

2. is a multiset of formulas and is a formula.

3. In -Choose, is a closed term, and is the result of replacing by all free occurrences of in .

In the above, the “Replicate” rule is an optimized version of what is known as Contraction, where contraction occurs only when there is a surface occurrence of .

A LKg-proof of a sequent is a sequence of sequents, with , such that, each follows by one of the rules of LKg from .

## 3 Examples

Below we describe some examples.

###### Example 3.1

The formula is provable in LKg as follows:

1.   Succ

2.   -Choose

3.   -Choose

###### Example 3.2

The formula is provable in LKg as follows:

1.   Succ

2.   -Choose

3.   -Choose

4.   -Choose

5.   -Choose

6.   Replicate

On the other hand, the formula which is invalid can be seen to be unprovable. This can be derived only by two -Choose rules and then the premise should be of the form for some new constants . The latter is not classically valid.

## 4 The soundness and completeness of LKg

We now present the soundness and completeness of LKg.

###### Theorem 4.1
1. If LKg terminates with success for , then is valid.

2. If LKg terminates with failure for , then is invalid.

3. If LKg does not terminate for , then is invalid.

Proof. Consider an arbitrary sequent .

Soundness: Induction on the length of derivatons.

Case 1: is derived from by -Choose. By the induction hypothesis, is valid, which implies that is valid.

Case 2: is derived from by Replicate. By the induction hypothesis, is valid. Then, it is easy to see that is valid.

Case 3: is derived from by Succ.

In this case, we know that there is no surface occurrences of in and is classically valid. It is then easy to see that, reversing the propositionalization of (replacing by any formula of the form ) preserves validity. For example, if is , then is valid and is valid as well.

Case 4: is derived from by -Choose.

Thus, there is an occurrence of in . The machine makes a move by picking up some fresh constant not occurring in . Then, by the induction hypothesis, the premise is valid. Now consider any interpretation that makes the premise true. Then it is easy to see that the conclusion is true in . It is commonly known as “generalization on constants”.

Completeness: Assume LKg terminates with failure.

We proceed by induction on the length of derivations.

If is stable, then there should be a LKg-unprovable sequent with the following condition.

Case 1: -Choose: has the form , and is , where is a new constant not occurring in . In this case, is a LKg-unprovable sequent, for otherwise is LKg-provable. By the induction hypothesis, is not true in some interpretation . Then it is easy to see that is not true in . Therefore is not valid.

Next, we consider the cases when is not stable. Then there are three cases to consider.

Case 2.1: Fail: In this case, there is no surface occurrence of and the alorithm terminates with fauilure. As is not stable, is not classically valid. If we reverse the propositionalization of by replacing by any formula with some surface occurrence of , we observe that invalidity is preserved. Therefore, is not valid.

Case 2.2: -Choose: In this case, has the form , and is , where is a closed term. In this case, is a LKg-unprovable sequent for any , for otherwise is LKg-provable. By the induction hypothesis, none of is valid and thus none of is not true in some interpretation . Then it is easy to see that is not true in . Therefore is not valid.

Case 2.3: Replicate: In this case, has the form , and is . In this case, is a LKg-unprovable sequent, for otherwise is LKg-provable. By the induction hypothesis, is not valid and is not true in some interpretation . Then it is easy to see that is not true in . Therefore is not valid.

Now assume LKg is not terminating, because Replicate occurs infinitely many times. We prove this by contradition.

Assume that is valid but unprovable. Let be an infinite multiset of propositional formulas obtained by applying infinite numbers of Replicate, together with -Choose and -Choose rules. Then it is easy to see that remains still valid but unprovable. By the compactness theorem on propositional logic, there is a finite subset of , which is a valid sequent. Then there must be a step in the procedure such that, after , is derived. Then it is easy to see that remains LKg-unprovable. However, as is valid, it must be provable by Succ. This is a contradiction and, therefore, is not valid.

## 5 Some Optimizations

Although LKg performs well for valid sequents, it performs poorly for invalid sequents. For example, it does not even terminate for the invalid sequent .

For this reason, what we need is a good heuristic for determining, in a simple yet effective way, whether a sequent is invalid. In this section, we employ a simple heuristic called maximum propositionalization which replaces in a sequent all -subformulas by . If is obtained from by maximum propositionalization, then it is easy to observe that if is invalid, then is invalid as well.

The deductive system uses this heuristic. First, we need to define some terminology.

1. The max-propositionalization of a formula is the result of replacing in all -subformulas by , and all -subformulas by . This process naturally extends to sequents.

2. The min-propositionalization of a formula is the result of replacing in all -subformulas by , and all -subformulas by . This process naturally extends to sequents.

3. A sequent is said to be max-p-invalid iff its max-propositionalization is classically invalid. A sequent is said to be min-p-valid iff its min-propositionalization is classically valid.

Below, :stable means that is stable but not min-p-valid. stable. Similarly :unstable means that is unstable but not min-p-valid.

The heuristic employed in is quite simple and needs to be improved. For example, it does not apply well to the invalid sequent . It would be nice to improve our heuristic so that it can apply to a wider class of invalid sequents.

## References

• [1] G. Japaridze. Introduction to computability logic. Annals of Pure and Applied Logic 123 (2003), No.1-3, pp. 1-99.
• [2] G. Japaridze. From truth to computability I. Theoretical Computer Science 357 (2006), No.1-3, pp. 100-135.
• [3] G. Japaridze. Introduction to cirquent calculus and abstract resource semantics. Journal of Logic and Computation 16 (2006), No.4, pp. 489-532.
• [4] G. Japaridze. Computability logic: a formal theory of interaction. In: Interactive Computation: The New Paradigm. D. Goldin, S. Smolka and P. Wegner, eds. Springer 2006, pp. 183-223.
• [5] G. Japaridze. In the beginning was game semantics. In: Games: Unifying Logic, Language, and Philosophy. O. Majer, A.-V. Pietarinen and T. Tulenheimo, eds. Springer 2009, pp. 249-350.
• [6] S. Reeves and M. Clarke. Logic for Computer Science. Addison Wesley, 1990.