Previous Article in Journal
Distribution-Free Normal Modal Logics
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Algorithmic Problems for Computation Trees

Computer, Electrical and Mathematical Sciences & Engineering Division, King Abdullah University of Science and Technology (KAUST), Thuwal 23955-6900, Saudi Arabia
Submission received: 12 March 2025 / Revised: 11 April 2025 / Accepted: 6 May 2025 / Published: 9 May 2025

Abstract

:
In this paper, we study three algorithmic problems involving computation trees: the optimization, solvability, and satisfiability problems. The solvability problem is concerned with recognizing computation trees that solve problems. The satisfiability problem is concerned with recognizing sentences that are true in at least one structure from a given set of structures. We study how the decidability of the optimization problem depends on the decidability of the solvability and satisfiability problems. We also consider various examples with both decidable and undecidable solvability and satisfiability problems.

1. Introduction

This paper is devoted to the study of three algorithmic problems related to computation trees: problems of optimization, solvability, and satisfiability. Computation trees can be used as algorithms for solving problems of combinatorial optimization, computation geometry, etc. Computation trees are a natural generalization of decision trees: in addition to one-place operations of the predicate type (attributes) which are used in decision trees, in computation trees, many-place predicate and function operations may be used. Algebraic computation trees and some of their generalizations have been studied most intensively [1,2,3]. This paper continues the line of research introduced by the work of [4]: this work does not concentrate on specific types of computation trees, such as algebraic, but studies computation trees over arbitrary structures.
Our consideration is based on the notions of signature and structure of this signature. Signature σ is a finite or countable set of predicate and function symbols with their arity. Structure U of the signature σ is a pair ( A , I ) , where A is a nonempty set called the universe of U, and I is an interpretation function mapping the symbols of σ to predicates and functions in A.
Each computation tree over structure U is a pair ( S , U ) of a computation tree scheme S of the signature σ and the structure U. Such computation trees are used to solve problems over structure U, each of which is a pair ( s , U ) of a problem scheme s of the signature σ and the structure U. The considered notions are discussed in Section 2, Section 3 and Section 4.
For a given class C of structures of the signature σ , we say that a scheme of computation tree S solves a scheme of problem s relative to the class C if, for any structure U C , the computation tree ( S , U ) solves the problem ( s , U ) .
We define the notion of so-called strictly limited complexity measure ψ over the signature σ and consider the following problem of optimization. For a given sentence α from a set of sentences H of the signature σ and scheme of problem s, we should find a scheme of computation tree S which satisfies the following conditions: (i) S solves the scheme of problem s relative to the class C ( α ) consisting of all structures U C for which α is true in U, and (ii) S has the minimum ψ -complexity among such schemes of computation trees. We study the decidability of this problem depending on the decidability of problems of solvability and satisfiability.
The problem of solvability: for an arbitrary sentence α H , scheme of problem s, and scheme of computation tree S, we should recognize if the scheme of computation tree S solves the scheme of problem s relative to the class C ( α ) .
In Section 5, we prove that the problem of solvability is decidable if and only if the following problem of satisfiability is decidable: for an arbitrary sentence β H Φ , we should recognize if there exists a structure U C for which β is true in U. Here, H Φ is the set of sentences α γ such that α H , γ Φ , and Φ is the set of sentences of the signature σ in prenex form with the prefixes of the form .
In the same section, we prove that if H is equal to the set of all sentences of the signature σ , then the problem of solvability is decidable if and only if the theory of the class C is decidable. This gives us many examples of both decidability and undecidability of the satisfiability problem.
We will find more examples in Section 6, where we study the case of the satisfiability problem when H = H 1 H n and, for i = 1 , , n , H i is the set of all sentences of the signature σ in prenex form with prefixes in a nonempty set of words in the alphabet { , } that is closed relative to subwords. We describe all classes of sentences H 1 H n Φ for which the problem of satisfiability is decidable both for the case when C is the class of all structures of the signature σ and for the case when C is the class of all finite structures of the signature σ .
In Section 7, we prove that, for any strictly limited complexity measure, the problem of optimization is undecidable if the problem of satisfiability is undecidable. We also prove that the problem of optimization is decidable if the problem of solvability is decidable and the considered strictly limited complexity measure satisfies some additional condition.
Section 8 contains short conclusions.

2. Sequences of Expressions

In this section, we consider the notions of function and predicate expressions of a signature σ and the notion of an n-sequence of such expressions. These notions are used when we consider schemes of problems and computation trees.
Let σ be a finite or countable signature containing generally both predicate and function symbols and their arity. This paper will not consider nullary predicate symbols. The paper will specifically mention when nullary function symbols (constants) are not allowed.
Let ω = { 0 , 1 , 2 , } , E 2 = { 0 , 1 } and X = { x i : i ω } be the set of variables. For n ω { 0 } , we denote X n = { x 0 , , x n 1 } . Let α be a formula of the signature σ . We will use the following notation: α 1 = α and α 0 = ¬ α .
Definition 1.
A function expression of the signature σ is an expression of the form x j f ( x l 1 , , x l m ) , where f is an m-ary function symbol of the signature σ. A predicate expression of the signature σ is an expression of the form x l 1 = x l 2 or an expression of the form r ( x l 1 , , x l k ) , where r is a k-ary predicate symbol of the signature σ.
Definition 2.
Let n ω { 0 } . An n-sequence of expressions is a pair ( n , β ) , where β is a finite sequence of function and predicate expressions.
Let β = β 1 , , β m . For i = 1 , 2 , , m , we correspond to the expression β i a sequence M i = t i 0 , t i 1 , of terms of the signature σ with variables from X n . Let M 1 = x 0 , x 1 , , x n 2 , x n 1 , x n 1 , . Let the sequences M 1 , , M i , m > i 1 , be already defined. We now define the sequence M i + 1 corresponding to the expression β i + 1 . If β i is a predicate expression, then M i + 1 = M i . Let β i be a function expression x j f ( x l 1 , , x l m ) . Then, M i + 1 = t i 0 , , t i j 1 , f ( t i l 1 , , t i l m ) , t i j + 1 , t i j + 2 , .
We associate with each predicate expression β i of the sequence β an atomic formula κ ( n , β , β i ) of the signature σ with variables from X n . Let β i be the expression x l 1 = x l 2 . Then, κ ( n , β , β i ) is equal to t i l 1 = t i l 2 . Let β i be the expression r ( x l 1 , , x l k ) . Then, κ ( n , β , β i ) is equal to r ( t i l 1 , , t i l k ) .

3. Schemes of Computation Trees and Computation Trees

In this section, we discuss the notions of a scheme of computation tree and its complete path, as well as the notion of a computation tree.
Later, we will specifically clarify whether equality = can be used in the considered formulas of the signature σ .
For n ω { 0 } , denote Q n = ( σ ) as the set of formulas of the signature σ with variables from X n that are atomic formulas or negations of atomic formulas. Equality sign = in Q n = ( σ ) means that formulas of the form t 1 = t 2 and ¬ ( t 1 = t 2 ) belong to Q n = ( σ ) , where t 1 and t 2 are terms of the signature σ with variables from X n . We denote by Q n ( σ ) the set of formulas from Q n = ( σ ) that do not contain equality. The set Q n ( σ ) contains only formulas of the form r ( t 1 , , t k ) or ¬ r ( t 1 , , t k ) , where r is a k-ary predicate symbol from σ , and t 1 , , t k are terms of the signature σ with variables from X n .
Definition 3.
A scheme of computation tree of the signature σ is a pair S = ( n , G ) , where n ω { 0 } and G define a finite directed tree with root. This tree has three types of nodes: function, predicate, and terminal. A function node is labeled with a function expression of the signature σ. One edge leaves the function node. This edge is not labeled. A predicate node is labeled with a predicate expression of the signature σ. This expression can be of the form x l 1 = x l 2 if we allow equality. Two edges leave the predicate node. One edge is labeled with the number 0, and another edge is labeled with the number 1. A terminal node is labeled with a number from ω. This node has no leaving edges.
The set X n will be called the set of input variables of the scheme of computation tree S. Usually, we will not distinguish the scheme S and its graph G.
Definition 4.
A complete path of the scheme S is a directed path, which starts in the root and finishes in a terminal node of S.
Let τ = w 1 , d 1 , w 2 , d 2 , , w m , d m , w m + 1 be a complete path of the scheme S. We denote β = β 1 , , β m as the sequence of function and predicate expressions attached to nodes w 1 , , w m . Let us consider the n-sequence of expressions of ( n , β ) . We correspond to each predicate node w i of the path τ the formula κ ( n , β , β i ) c from Q n = ( σ ) , where c is the number attached to the edge d i .
We now define the set of formulas F ( τ ) associated with the complete path τ . If τ contains predicate nodes, then F ( τ ) is the set of formulas associated with the predicate nodes of τ . If τ does not contain predicate nodes, then F ( τ ) = { μ τ } , where μ τ is the formula x 0 = x 0 if equality is allowed and ¬ r ( x 0 , , x 0 ) r ( x 0 , , x 0 ) if equality is not allowed, and r is a predicate symbol of the signature σ . Note that if τ does not contain predicate nodes, then τ is the only complete path of the scheme S. Let F ( τ ) = { α 1 , , α k } . Denote by π τ ( S ) the formula α 1 α k . Denote by t τ the number attached to the terminal node w m + 1 of the path τ .
Definition 5.
Let U be a structure of the signature σ with the universe A and S = ( n , G ) be a scheme of computation tree of the signature σ. The pair Γ = ( S , U ) will be called a computation tree over U with the set of input values X n . The scheme S will be called the scheme of the computation tree Γ.
Definition 6.
A complete path τ of the scheme S will be called realizable in the structure U for a tuple a ¯ A n if any formula from F ( τ ) is true in U on the tuple a ¯ .
One can show that there exists exactly one complete path of S that is realizable in the structure U for the tuple a ¯ .
We correspond to the computation tree Γ a function φ Γ : A n ω . Let a ¯ A n and τ be a complete path of the scheme S that is realizable in the structure U for the tuple a ¯ . Then, φ Γ ( a ¯ ) = t τ . We will say that the computation tree Γ implements the function φ Γ .
We denote by Tree = ( σ ) the set of schemes of computation trees of the signature σ . Denote by Tree ( σ ) the set of schemes from Tree = ( σ ) that do not contain equality in the expressions attached to nodes.

4. Schemes of Problems and Problems

In this section, the notions of a scheme of problem and its special representation, as well as the notion of a problem, are considered. The notion of a computation tree solving a problem is also defined.
Definition 7.
A scheme of problem of the signature σ is a tuple s = ( n , ν , β 1 , , β m ) , where n ω { 0 } , m ω { 0 } , β 1 , , β m are functions and predicate expressions of the signature σ, and there is k ω { 0 } such that ν : E 2 k ω , and there are exactly k predicate expressions in the sequence β 1 , , β m .
The set X n is called the set of input variables for the scheme of problem s. We denote by β the sequence of expressions β 1 , , β m . Let us consider the n-sequence of expressions of ( n , β ) . Let β i 1 , , β i k be all predicate expressions in the sequence β . We correspond to each predicate expression β i j the formula α j = κ ( n , β , β i j ) from Q n = ( σ ) . The tuple ( n , ν , α 1 , , α k ) will be called the special representation of the scheme of problem s. We correspond to the scheme s and to each tuple δ ¯ = ( δ 1 , , δ k ) E 2 k the formula π δ ¯ ( s ) = α 1 δ 1 α k δ k .
Definition 8.
Let U be a structure of the signature σ consisting of a universe A and an interpretation I of symbols from σ. Let s = ( n , ν , β 1 , , β m ) be a scheme of problem of the signature σ. The pair z = ( s , U ) will be called a problem over U with the set of input variables X n . The scheme s will be called the scheme of the problem z.
Let us consider the special representation ( n , ν , α 1 , , α k ) of the scheme of problem s. The interpretation I corresponds to the formula α j , j = 1 , , k , a function from A n to E 2 in a natural way: any predicate including predicates of the form x l 1 = x l 2 can be considered as a function with values from the set E 2 .
We correspond to the problem z the function φ z : A n ω defined as follows: φ z ( a ¯ ) = ν ( α 1 ( a ¯ ) , , α k ( a ¯ ) ) for any a ¯ A n . The problem z may be interpreted as a problem of searching for the number φ z ( a ¯ ) for a given a ¯ A n .
Definition 9.
Let S = ( n , G ) be a scheme of computation tree of the signature σ. We will say that the computation tree Γ = ( S , U ) solves the problem z = ( s , U ) if the functions φ Γ and φ z coincide.
We denote by Probl = ( σ ) the set of schemes of problems of the signature σ . Denote by Probl ( σ ) the set of schemes from Probl = ( σ ) that do not contain equality in the predicate expressions.

5. Solvability Versus Satisfiability

In this section, two algorithmic problems are considered. The problem of solvability is related to the recognition of schemes of computation trees solving schemes of problems relative to a class of structures. The problem of satisfiability is about the recognition of sentences that are true in at least one structure from a given set of structures. It is shown here that the problem of solvability is decidable if and only if corresponding to it the problem of satisfiability is decidable. Various examples with both decidable and undecidable solvability and satisfiability problems are also considered.
Let C be a class of structures of the signature σ .
Definition 10.
We will say that a scheme of computation tree S = ( n 1 , G ) from Tree = ( σ ) solves a scheme of problem s = ( n 2 , ν , β 1 , , β m ) from Probl = ( σ ) relative to the class C if n 1 = n 2 and either C = or C , and for any structure U from C, the computation tree ( S , U ) solves the problem ( s , U ) .
For a sentence (formula without free variables) α of the signature σ , denote C ( α ) = { U : U C , U α } , where the notation U α means that the sentence α is true in U. Let H be a nonempty set of sentences of the signature σ , and let
( Probl , Tree ) { ( Probl = ( σ ) , Tree = ( σ ) ) , ( Probl ( σ ) , Tree ( σ ) ) } .
We can consider the pair ( Probl ( σ ) , Tree ( σ ) ) only if the signature σ contains predicate symbols.
Definition 11.
We now define the problem of solvability for the quadruple ( Probl , Tree , H , C ) : for arbitrary α H , s Probl , and S Tree , we should recognize if the scheme of computation tree S solves the scheme of problem s relative to the class C ( α ) .
Definition 12.
Let us define the problem of satisfiability for the pair ( H , C ) : for an arbitrary α H , we should recognize if there exists a structure U C such that U α .
This is the general definition of the satisfiability problem. Later, for each version of the solvability problem, we will consider its corresponding version of the satisfiability problem and prove that they are both decidable or both undecidable.
Let H 1 , , H m be nonempty sets of sentences of the signature σ . We denote by H 1 H m the class of sentences of the form α 1 α m , where α 1 H 1 , , α m H m . Let Π be a set of words in the alphabet { , } . Denote by Φ = ( Π , σ ) the class of all sentences in prenex form of the signature σ with prefixes from Π . Denote by Φ ( Π , σ ) the class of all sentences from Φ = ( Π , σ ) that do not contain equality.
Let w be a word in the alphabet { , , * , * } . The set P ( w ) of prefixes is defined in the following way:
P ( n ) = { i : 0 i n } , P ( n ) = { i : 0 i n } , P ( * ) = { i : i ω } , P ( * ) = { i : i ω } , P ( w 1 w 2 ) = { u 1 u 2 : u 1 P ( w 1 ) , u 2 P ( w 2 ) } .
Denote H = ( σ ) as the set of sentences of the signature σ . Denote H ( σ ) as the set of sentences of the signature σ that do not contain equality.
Theorem 1.
Let C be a nonempty class of structures of the signature σ and H be a nonempty set of sentences of the signature σ:
(a) Let H H = ( σ ) . The problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H , C ) is decidable if and only if the problem of satisfiability for the pair ( H Φ = ( P ( * ) , σ ) , C ) is decidable.
(b) Let H H ( σ ) . The problem of solvability for the quadruple ( Probl ( σ ) , Tree ( σ ) , H , C ) is decidable if and only if the problem of satisfiability for the pair ( H Φ ( P ( * ) , σ ) , C ) is decidable.
Proof. 
(a) Let the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H , C ) be decidable. We now describe an algorithm for solving the problem of satisfiability for the pair ( H Φ = ( P ( * ) , σ ) , C ) . Let α H and β Φ = ( P ( * ) , σ ) . We construct a sentence of the signature σ that is logically equivalent to the sentence β and is of the form x 0 x n 1 ( ( β 11 β 1 m 1 ) ( β k 1 β k m k ) ) , where, for j = 1 , , k and i = 1 , , m j , β j i Q n = ( σ ) .
For j = 1 , , k , we construct a scheme of computation tree S j = ( n , G j ) from Tree = ( σ ) such that for any structure U of the signature σ and any tuple a ¯ A n , where A is the universe of U,
φ ( S j , U ) ( a ¯ ) = 0 , if   U ¬ ( β j 1 ( a ¯ ) β j m j ( a ¯ ) ) , 1 , if   U β j 1 ( a ¯ ) β j m j ( a ¯ ) .
We denote by s 0 = ( n , ν , x 0 = x 0 ) the scheme of problem from Probl = ( σ ) such that ν : E 2 { 0 } , i.e., φ ( s 0 , U ) 0 for any structure U of the signature σ .
Using an algorithm that solves the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H , C ) , for j = 1 , , k , we recognize if the scheme of computation tree S j solves the scheme of problem s 0 relative to the class C ( α ) . It is not difficult to show that a structure U C such that U α β exists if and only if there exists j { 1 , , k } for which the scheme of computation tree S j does not solve the scheme of problem s 0 relative to the class C ( α ) .
Let the problem of satisfiability for the pair ( H Φ = ( P ( * ) , σ ) , C ) be decidable. We now describe an algorithm solving the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H , C ) . Let α H , S = ( n 1 , G ) be a scheme of computation tree from Tree = ( σ ) , and let s = ( n 2 , ν , β 1 , , β m ) be a scheme of problem from Probl = ( σ ) with the special representation ( n 2 , ν , α 1 , , α k ) .
If n 1 n 2 , then the scheme of computation tree S does not solve the scheme of problem s relative to the class C ( α ) . Let n 1 = n 2 . Let τ be a complete path of the scheme of computation tree S and δ ¯ E 2 k . Denote γ τ δ ¯ = x 0 x n 1 1 ( π τ ( S ) π δ ¯ ( s ) ) .
Using an algorithm solving the problem of satisfiability for the pair ( H Φ = ( P ( * ) , σ ) , C ) , for each pair of path τ and tuple δ ¯ such that t τ ν ( δ ¯ ) , we check if there exists a structure U C in which the sentence α γ τ δ ¯ is true. One can show that the scheme of computation tree S does not solve the scheme of problem s relative to the class C ( α ) if and only if, for at least one of the considered pairs τ and δ ¯ , the sentence α γ τ δ ¯ is true in a structure from the class C.
(b) The second part of the theorem statement can be proved in a similar way. □
We now consider some corollaries of Theorem 1.
Definition 13.
Let C be a nonempty class of structures of the signature σ. The theory Th ( C ) of the class C consists of all sentences from H = ( σ ) that are true in all structures from C. This theory is called decidable if there exists an algorithm that, for a given sentence from H = ( σ ) , recognizes if this sentence belongs to Th ( C ) .
Proposition 1.
Let C be a nonempty class of structures of the signature σ. The problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H = ( σ ) , C ) is decidable if and only if the theory Th ( C ) of the class C is decidable.
Proof. 
Let the theory Th ( C ) be decidable. Let α H = ( σ ) Φ = ( P ( * ) , σ ) . It is clear that the sentence α is true in a structure from C if and only if the sentence ¬ α does not belong to the theory Th ( C ) . Taking into account that the theory Th ( C ) is decidable, we obtain that the problem of satisfiability for the pair ( H = ( σ ) Φ = ( P ( * ) , σ ) , C ) is decidable. Using Theorem 1, we obtain that the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H = ( σ ) , C ) is decidable.
Let the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H = ( σ ) , C ) be decidable. Let α H = ( σ ) . Evidently, α does not belong to the theory Th ( C ) if and only if the sentence ¬ α x 0 ( x 0 = x 0 ) from H = ( σ ) Φ = ( P ( * ) , σ ) is true in a structure from C. Using Theorem 1, we obtain that the problem of satisfiability for the pair ( H = ( σ ) Φ = ( P ( * ) , σ ) , C ) is decidable. Hence, the theory Th ( C ) is decidable. □
We now consider examples of classes of structures with decidable theory [5,6]:
  • The class of abelian groups and the class of finite abelian groups.
  • The class of finite fields.
  • The field of real numbers.
  • The field of complex numbers.
  • The addition of natural numbers.
We now consider examples of classes of structures with undecidable theory [6,7]:
  • The class of groups and the class of finite groups.
  • The class of fields.
  • The arithmetic of natural numbers.

6. Decidable Classes of Sentences

This section studies decidable classes of sentences of a special kind. The details of the study are described first.
Let σ be a finite or countable signature that does not contain nullary predicate symbols and nullary function symbols. A set Π of words in the alphabet { , } will be called closed relative to subwords if, for any word w Π , any word obtained from w by the removal of some letters belongs to Π . Let Π 1 , , Π n be nonempty sets of words in the alphabet { , } closed relative to subwords. Let Π n + 1 = P ( * ) . Denote L = = Φ = ( Π 1 , σ ) Φ = ( Π n , σ ) , K = = L = Φ = ( Π n + 1 , σ ) , L = Φ ( Π 1 , σ ) Φ ( Π n , σ ) , and K = L Φ ( Π n + 1 , σ ) .
We denote by C σ the class of all structures of the signature σ and by C σ f i n the class of all finite structures of the signature σ . The next statement follows directly from Theorem 1. It describes the connections between the solvability problems under consideration and the corresponding satisfiability problems.
Proposition 2.
(a) The problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , L = , C σ ) is decidable if and only if the problem of satisfiability for the pair ( K = , C σ ) is decidable.
(b) The problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , L = , C σ f i n ) is decidable if and only if the problem of satisfiability for the pair ( K = , C σ f i n ) is decidable.
(c) The problem of solvability for the quadruple ( Probl ( σ ) , Tree ( σ ) , L , C σ ) is decidable if and only if the problem of satisfiability for the pair ( K , C σ ) is decidable.
(d) The problem of solvability for the quadruple ( Probl ( σ ) , Tree ( σ ) , L , C σ f i n ) is decidable if and only if the problem of satisfiability for the pair ( K , C σ f i n ) is decidable.
Let H be a class of sentences of the signature σ .
Definition 14.
We will say that the class H is decidable if the problem of satisfiability for the pair ( H , C σ ) is decidable and the problem of satisfiability for the pair ( H , C σ f i n ) is decidable.
Definition 15.
We will say that a sentence α of the signature σ is satisfiable if α is true in a structure from C σ . We will say that a sentence α of the signature σ is finite satisfiable if α is true in a structure from C σ f i n .
Definition 16.
We will say that the class H is a class of reduction if there exists an algorithm that corresponds to an arbitrary sentence α of the signature σ a sentence α H such that α is satisfiable if and only if α is satisfiable, and α is finite satisfiable if and only if α is finite satisfiable. Note that each class of reduction is undecidable.
In this section, based on the results from [8,9,10,11], all decidable classes of sentences K and K = are described.

6.1. Signatures with Predicate Symbols Only

In this section, we consider a finite or countable signature σ that does not contain function symbols and nullary predicate symbols.
Denote P 1 = P ( * * ) , P 2 = P ( * 2 * ) , and P 3 = P ( * 2 ) . In [9], a constant r 0 is defined in the following way: r 0 = log 2 m * + 13 , where m * is the number of states in a universal Turing machine.
Theorem 2.
Let the signature σ contain at least r 0 + 1 predicate symbols and not contain function symbols. Let Π 1 , , Π n be nonempty sets of words in the alphabet { , } closed relative to subwords, Π n + 1 = P ( * ) , K = = Φ = ( Π 1 , σ ) Φ = ( Π n , σ ) Φ = ( Π n + 1 , σ ) , and K = Φ ( Π 1 , σ ) Φ ( Π n , σ ) Φ ( Π n + 1 , σ ) .
(a) Either the class K is decidable or it is a class of reduction. The same applies to the class K = .
(b) K is a class of reduction if and only if K = is a class of reduction.
(c) If the class K = is decidable, then, with the exception of a finite number of sentences, the satisfiability for sentences from K = coincides with the finite satisfiability.
(d) K is decidable if and only if at least one of the following four possibilities occurs:
   (d.1) σ contains only 1-ary predicate symbols.
   (d.2) For i = 1 , , n , Π i P 1 .
   (d.3) For i = 1 , , n , Π i P 2 .
   (d.4) There exists i 0 { 1 , , n } such that Π i 0 P 1 P 2 and, for each i { 1 , , n } { i 0 } , Π i P 3 .
Proof. 
Statements (a), (b), and (c) follow directly from Theorems 19 and 21 [9].
Let σ be an infinite signature. From Theorem 19 [9], it follows that K is a class of reduction if and only if the signature σ contains at least one predicate symbol, wherein the arity is at least two, and at least one of the following two possibilities occurs:
  • For some i { 1 , , n + 1 } , Φ ( Π i , σ ) is a reduction class.
  • For some i , j { 1 , , n } such that i j , Π i , and 3 Π j .
From Theorem 3 [9], it follows that the class Φ ( P 1 P 2 , σ ) is decidable. Therefore if, for the class K, at least one of the possibilities (d.1), (d.2), (d.3), and (d.4) occurs, then K is decidable.
Let K be decidable. We now show that K satisfies at least one of the conditions (d.1), (d.2), (d.3), and (d.4).
If σ contains only 1-ary predicate symbols, then K satisfies the condition (d.1). Let σ contain at least one predicate symbol F, wherein the arity is at least two. Then, for any i { 1 , , n + 1 } , Φ ( Π i , σ ) is a decidable class, and there are no i , j { 1 , , n } such that i j , Π i and 3 Π j . Taking into account that the signature σ is infinite and contains the predicate symbol F, and using Theorem 3 [9], we obtain that, for any i { 1 , , n } , Π i P 1 P 2 .
A set of words Π in the alphabet { , } , which is closed relative to subwords, will be called as follows:
  • ∅-set if Π P 1 P 2 , Π and 3 Π .
  • 3 -set if Π P 1 P 2 , Π and 3 Π .
  • -set if Π P 1 P 2 , Π and 3 Π .
  • 3 - -set if Π P 1 P 2 , Π and 3 Π .
Evidently, if Π is an ∅-set, then Π P ( * 2 ) = P 3 . If Π is a 3 -set, then Π P 1 . If Π is a -set, then Π P 2 . If Π is a 3 - -set, then Π P 1 P 2 . Note that P 3 = P 1 P 2 .
Let there exist i 0 such that Π i 0 is a 3 - -set. Then, for any i { 1 , , n } { i 0 } , Π i is an ∅-set, and Π P 3 . Therefore, K satisfies the condition (d.4).
Let, for any i { 1 , , n } , Π i be not a 3 - -set.
If, for any i { 1 , , n } , Π i is an ∅-set, then K satisfies the conditions (d.2) and (d.3).
Let there exist i { 1 , , n } such that Π i is a 3 -set. Then, evidently, for any j { 1 , , n } , Π j is an ∅-set or a 3 -set, and K satisfies the condition (d.2).
Let there exist i { 1 , , n } such that Π i is a -set. Then, evidently, for any j { 1 , , n } , Π j is an ∅-set or a -set, and K satisfies the condition (d.3).
Let σ be a finite signature. Let the class K satisfy at least one of the conditions (d.1), (d.2), (d.3), or (d.4). We add to σ an infinite set of 1-ary predicate symbols. As a result, we obtain a signature σ 1 . It is clear that the class K ( σ 1 ) = Φ ( Π 1 , σ 1 ) Φ ( Π n + 1 , σ 1 ) satisfies at least one of the conditions (d.1), (d.2), (d.3), or (d.4). According to what was proven above, the class K ( σ 1 ) is decidable. Since K K ( σ 1 ) , the class K is decidable.
Let σ contain at least r 0 + 1 predicate symbols. Let K be decidable. If σ contains only 1-ary predicate symbols, then K satisfies the condition (d.1). Let σ contain at least one predicate symbol, wherein the arity is greater than or equal to two. Taking into account that Π n + 1 = P ( * ) and using Theorem 21 [9], we obtain that, for any i { 1 , , n } , Π i and 3 Π i . Therefore, for i = 1 , , n , Π i P 1 P 2 .
Taking into account that Π n + 1 = P ( * ) and using Theorem 21 [9], we obtain that there are no i , j { 1 , , n } such that i j , Π i and 3 Π j .
Next, using arguments similar to the case of infinite signature σ , where we considered ∅-sets, 3 -sets, -sets, and 3 - -sets, we obtain that K satisfies condition (d.2), condition (d.3), or condition (d.4). □
Remark 1.
If the signature σ contains less than r 0 + 1 predicate symbols and K satisfies at least one of the conditions (d.1), (d.2), (d.3), or (d.4), then K is decidable—see the proof of the theorem.

6.2. Signatures with Function Symbols. Equality Is Not Allowed

In this section, we consider a finite or countable signature σ that does not contain nullary predicate and function symbols and contains a function symbol of arity greater than 0. The equality = cannot be used in the formulas of the signature σ .
Theorem 3.
Let σ be a signature with at least one function symbol of arity greater than 0. Let Π 1 , , Π n be nonempty sets of words in the alphabet { , } closed relative to subwords, Π n + 1 = P ( * ) , and K = Φ ( Π 1 , σ ) Φ ( Π n , σ ) Φ ( Π n + 1 , σ ) .
(a) Either the class K is decidable or it is a class of reduction.
(b) If the class K is decidable, then for sentences from K, the satisfiability coincides with the finite satisfiability.
(c) The class K is decidable if and only if at least one of the following three conditions is satisfied:
   (c.1) The signature σ does not contain predicate symbols.
   (c.2) The signature σ contains only 1-ary predicate and 1-ary function symbols.
   (c.3) For i = 1 , , n , Π i P ( * * ) .
Proof. 
Let K satisfy the condition (c.1). Then, K = and, consequently, K is decidable. Since K = , the statement (b) holds for K.
Let K satisfy the condition (c.2). By Theorem 7 [10], the class Φ ( P , σ ) , where P is the set of all words in the alphabet { , } , is decidable. Evidently, there exists an algorithm that transforms any sentence α K to a sentence α Φ ( P , σ ) such that α is satisfiable if and only if α is satisfiable, and α is finite satisfiable if and only if α is finite satisfiable. Therefore, K is decidable. By Theorem 7 [10], the statement (b) holds for Φ ( P , σ ) . Therefore, the statement (b) holds for K.
Let K satisfy the condition (c.3). Let α = α 1 α n + 1 K . By introducing some new nullary function symbols c 1 , , c k and changing variables, we can transform the sentence α to the form β = x 0 u 1 x 0 u n + 1 such that u 1 , , u n + 1 are quantifier-free formulas of the signature σ = σ { c 1 , , c k } with pairwise disjoint sets of variables (except x 0 ), and for any structure U of the signature σ , α is true in U if and only if β is true in U for some interpretation of new symbols c 1 , , c k in the universe of U. Denote γ = x 0 ( u 1 u n + 1 ) . Evidently, for any structure U of the signature σ , γ is true in U if and only if β is true in U . Furthermore, we can transform the sentence γ to the form δ = x 0 u such that u is a quantifier-free formula of the signature σ , and for any structure U of the signature σ , δ is true in U if and only if γ is true in U .
Let y 1 , , y k be variables from X that do not belong to δ . Denote ε = y 1 y k x 0 v , where v is obtained from u by replacing symbols c 1 , , c k with variables y 1 , , y k , respectively. One can show that, for any structure U of the signature σ , ε is true in U if and only if δ is true in U for some interpretation of new symbols c 1 , , c k in the universe of U. Therefore, for any structure U of the signature σ , ε is true in U if and only if α is true in U. It is clear that ε Φ ( P ( * * ) , σ ) . Using Theorem 7 [10], we obtain that the class Φ ( P ( * * ) , σ ) is decidable. Therefore, the class K is decidable. By Theorem 7 [10], the statement (b) holds for Φ ( P ( * * ) , σ ) . Therefore, the statement (b) holds for K.
Let K not satisfy any of the conditions (c.1), (c.2), or (c.3). Then, σ contains a predicate symbol p and a function symbol f such that, for at least one of these symbols, its arity is at least 2, and there exists i { 1 , , n } such that Π i P ( * * ) . Let, for definiteness, i = 1 . Since Π 1 P ( * * ) , the word 2 belongs to Π 1 .
We now show that, for i = 2 , , n + 1 , the set Φ ( Π i , σ ) contains a sentence that is true in any structure U of the signature σ . Let i { 2 , , n + 1 } and Q 0 Q t Π i , where Q 0 , , Q t { , } . Then, the sentence π i = Q 0 x 0 Q t x t ( p ( x 0 , , x 0 ) ¬ p ( x 0 , , x 0 ) ) is true in any structure U of the signature σ and π i Φ ( Π i , σ ) .
Let the arity of the symbol p be greater than or equal to two. From Theorem 7 [10], it follows that the class Φ ( P ( 2 ) , σ 1 ) , where σ 1 consists of the 2-ary predicate symbol ρ and the 1-ary function symbol φ , is a class of reduction. Let us show that there is an algorithm which, for an arbitrary sentence α Φ ( P ( 2 ) , σ 1 ) , constructs a sentence α K such that α is satisfiable if and only if α is satisfiable, and α is finite satisfiable if and only if α is finite satisfiable.
Let us replace in α every occurrence of ρ ( t 1 , t 2 ) by p ( t 1 , t 2 , , t 2 ) and every occurrence of φ ( t ) by f ( t , t , , t ) , where t 1 , t 2 , and t are arbitrary terms of the signature σ . Denote by β the obtained formula. Then, as α , we can take the sentence β π 2 π n + 1 , which belongs to K. Since Φ ( P ( 2 ) , σ 1 ) is a class of reduction, K is also a class of reduction.
Let the arity of the symbol f be greater than or equal to two. From Theorem 7 [10], it follows that the class Φ ( P ( 2 ) , σ 2 ) , where σ 2 consists of the 1-ary predicate symbol ρ and the 2-ary function symbol φ , is a class of reduction. Let us show that there is an algorithm which, for an arbitrary sentence α Φ ( P ( 2 ) , σ 2 ) , constructs a sentence α K such that α is satisfiable if and only if α is satisfiable, and α is finite satisfiable if and only if α is finite satisfiable.
Let us replace in α every occurrence of ρ ( t ) by p ( t , t , , t ) and every occurrence of φ ( t 1 , t 2 ) by f ( t 1 , t 2 , , t 2 ) , where t, t 1 , and t 2 are arbitrary terms of the signature σ . Denote by β the obtained formula. Then, as α , we can take the sentence β π 2 π n + 1 , which belongs to K. Since Φ ( P ( 2 ) , σ 2 ) is a class of reduction, K is also a class of reduction. This completes the proofs of statements (a), (b), and (c). □

6.3. Signatures with Function Symbols. Equality Is Allowed

Theorem 4.
Let σ be a signature with at least one function symbol. Let Π 1 , , Π n be nonempty sets of words in the alphabet { , } closed relative to subwords, Π n + 1 = P ( * ) , and K = = Φ = ( Π 1 , σ ) Φ = ( Π n , σ ) Φ = ( Π n + 1 , σ ) .
(a) Either the class K = is decidable or it is a class of reduction.
(b) The class K = is decidable if and only if at least one of the following three conditions is satisfied:
   (b.1) For i = 1 , , n , Π i P ( * ) .
   (b.2) The signature σ contains only 1-ary predicate symbols, at most one 1-ary function symbol, and does not contain function symbols with arity greater than one.
   (b.3) For i = 1 , , n , Π i P ( * * ) , and the signature σ contains at most one 1-arity function symbol and does not contain function symbols with arity greater than one. There are no any restrictions regarding predicate symbols.
Proof. 
Let K = satisfy the condition (b.1). Evidently, there is an algorithm which transforms an arbitrary sentence α K = into a sentence α Φ = ( P ( * ) , σ ) such that α is satisfiable if and only if α is satisfiable, and α is finite satisfiable if and only if α is finite satisfiable. Using the main theorem in [11], we obtain that the class Φ = ( P ( * ) , σ ) is decidable. Therefore, the class K = is decidable.
Let K = satisfy the condition (b.2). From the main theorem in [11], it follows that the class Φ = ( P , σ ) is decidable, where P is the set of all words in the alphabet { , } . Taking into account that there is an algorithm that converts any sentence from K = to prenex form, we obtain that the class K = is decidable.
Let K = satisfy the condition (b.3). Now, we will almost repeat the reasoning from the proof of Theorem 3. Let α = α 1 α n + 1 K = . By introducing some new nullary function symbols c 1 , , c k and changing variables, we can transform the sentence α to the form β = x 0 u 1 x 0 u n + 1 such that u 1 , , u n + 1 are quantifier-free formulas of the signature σ = σ { c 1 , , c k } with pairwise disjoint sets of variables (except x 0 ), and for any structure U of the signature σ , α is true in U if and only if β is true in U for some interpretation of new symbols c 1 , , c k in the universe of U. Denote γ = x 0 ( u 1 u n + 1 ) . Evidently, for any structure U of the signature σ , γ is true in U if and only if β is true in U . Furthermore, we can transform the sentence γ to the form δ = x 0 u such that u is a quantifier-free formula of the signature σ , and for any structure U of the signature σ , δ is true in U if and only if γ is true in U .
Let y 1 , , y k be variables from X that do not belong to δ . Denote ε = y 1 y k x 0 v , where v is obtained from u by replacing symbols c 1 , , c k with variables y 1 , , y k , respectively. One can show that, for any structure U of the signature σ , ε is true in U if and only if δ is true in U for some interpretation of new symbols c 1 , , c k in the universe of U. Therefore, for any structure U of the signature σ , ε is true in U if and only if α is true in U. It is clear that ε Φ = ( P ( * * ) , σ ) . Using the main theorem in [11], we obtain that the class Φ = ( P ( * * ) , σ ) is decidable. Therefore, the class K = is decidable.
Let K = not satisfy any of the conditions (b.1), (b.2), or (b.3).One can show that in this case K = satisfy at least one of the following three conditions:
(c.1) There exists i { 1 , , n } such that Π i P ( * ) , i.e., Π i , and σ contains two 1-ary function symbols.
(c.2) There exists i { 1 , , n } such that Π i P ( * ) , i.e., Π i , and σ contains a function symbol with arity greater than one.
(c.3) There exists i { 1 , , n } such that Π i P ( * * ) , i.e., 2 Π i , and σ contains a predicate symbol with arity greater than one and a function symbol.
Denote by σ 1 the signature consisting of two 1-ary function symbols, σ 2 the signature consisting of one 2-ary function symbol, and σ 3 the signature consisting of one 2-ary predicate symbol and one 1-ary function symbol. From the main theorem in [11] (see also Theorem 4.0.1 [8]), it follows that the classes Φ = ( P ( ) , σ 1 ) , Φ = ( P ( ) , σ 2 ) , and Φ = ( P ( 2 ) , σ 3 ) are classes of reduction.
If the class K = satisfies the condition (c.1), then Φ = ( P ( ) , σ 1 ) can be reduced to K = , and K = is a class of reduction. If the class K = satisfies the condition (c.2), then Φ = ( P ( ) , σ 2 ) can be reduced to K = , and K = is a class of reduction. If the class K = satisfies the condition (c.3), then Φ = ( P ( 2 ) , σ 3 ) can be reduced to K = , and K = is a class of reduction. We will not go into details of the proof—similar statements were considered in the proof of Theorem 3. □

7. Problem of Optimization

This section considers the problem of optimization of schemes of computation trees and studies how their decidability depends on the decidability of the problems of solvability and satisfiability. It is proven that, for any strictly limited complexity measure, the problem of optimization is undecidable if the problem of satisfiability is undecidable. It is also proven that the problem of optimization is decidable if the problem of solvability is decidable and the considered strictly limited complexity measure satisfies some additional condition. Note that the problem of solvability and its corresponding problem of satisfiability are either both decidable or both undecidable.

7.1. Equality Is Not Allowed

First, we consider the case when the equality is not allowed.
Let σ be a finite or countable signature. If σ is finite, then we represent it in the form σ = { q 0 , , q m } , where q 0 , , q m are predicate and function symbols, each with its own arity. If σ is infinite, then we represent it in the form σ = { q 0 , q 1 , } . We denote by σ * the set of finite words in the alphabet σ , including the empty word λ .
Definition 17.
A complexity measure over the signature σ is an arbitrary map ψ : σ * ω . The complexity measure ψ will be called strictly limited if it is computable and, for any α 1 , α 2 , α 3 σ * , it possesses the following property: if α 2 λ , then ψ ( α 1 α 2 α 3 ) > ψ ( α 1 α 3 ) .
We now consider some examples of complexity measures. Let ψ : σ ω { 0 } . The function ψ is called a weight function for the signature σ . We extend the function ψ to the set σ * in the following way: ψ ( α ) = 0 if α = λ and ψ ( α ) = j = 1 m ψ ( q i j ) if α = q i 1 q i m . This function is called a weighted depth. If ψ ( q i ) = 1 for any q i σ , then the function ψ is called the depth and is denoted by h. The depth and any computable weighted depth are strictly limited complexity measures.
Let ψ be a complexity measure over the signature σ . We extend it to the sets Probl ( σ ) and Tree ( σ ) . Let β be a finite sequence of function and predicate expressions of the signature σ that do not contain the equality. We correspond to β a word word ( β ) from σ * . If the length of β is equal to 0, then word ( β ) = λ . If β = β 1 , , β m , then word ( β ) = q i 1 q i m , where, for j = 1 , , m , q i j is the symbol of the signature σ from the expression β j .
Let s = ( n , ν , β 1 , , β m ) be a scheme of problem from the set Probl ( σ ) . Then, ψ ( s ) = ψ ( word ( β 1 , , β m ) ) .
Let S = ( n , G ) be a scheme of computation tree from the set Tree ( σ ) and τ = w 1 , d 1 , w 2 , d 2 , , w m , d m , w m + 1 be a complete path of the scheme S. We denote β τ = β 1 , , β m as the sequence of function and predicate expressions attached to nodes w 1 , , w m . Then, ψ ( S ) = max { ψ ( word ( β τ ) ) : τ Path ( S ) } , where Path ( S ) is the set of complete paths of the scheme S. The value ψ ( S ) will be called the ψ -complexity of the scheme of computation tree S. We denote by h ( S ) the depth of the scheme of computation tree S. By σ ( S ) , we denote the set of symbols of the signature σ used in the function and predicate expressions in the scheme S.
Lemma 1.
Let ψ be a strictly limited complexity measure over the signature σ and S be a scheme of computation tree from the set Tree ( σ ) . Then, the following statements hold:
(a) ψ ( S ) h ( S ) .
(b) ψ ( S ) max { ψ ( q j ) : q j σ ( S ) } .
Proof. 
Let α σ * . Then, it is easy to show that ψ ( α ) | α | , where | α | is the length of the word α , and ψ ( α ) ψ ( q j ) for any letter q j in the word α . Using these relations, one can show that the statements of the lemma hold. □
Let us recall that H ( σ ) is the set of sentences of the signature σ that do not contain equality. Let ψ be a strictly limited complexity measure over the signature σ , C be a nonempty class of structures of the signature σ , and H be a nonempty subset of the set H ( σ ) .
Definition 18.
We now define the problem of optimization for the triple ( ψ , H , C ) : for arbitrary sentence α H and scheme of problem s Probl ( σ ) , we should find a scheme of computation tree S Tree ( σ ) which solves the scheme of problem s relative to the class C ( α ) and has the minimum ψ-complexity. We will call such a scheme of computation tree optimal relative to ψ, s, and C ( α ) .
Lemma 2.
The ψ-complexity of a scheme of computation tree that is optimal relative to ψ, s, and C ( α ) is at most ψ ( s ) .
Proof. 
Let s = ( n , ν , β 1 , , β m ) . It is easy to construct a scheme of computation tree S Tree ( σ ) , which solves the scheme of problem s relative to the class C ( α ) and for which, for any complete path τ of S, the sequence β τ of predicate and function expressions attached to the nodes of τ coincides with β 1 , , β m . Therefore, ψ ( S ) = ψ ( s ) . Thus, the ψ -complexity of a scheme of computation tree that is optimal relative to ψ , s, and C ( α ) is at most ψ ( s ) . □
Let S 1 = ( n , G 1 ) and S 2 = ( n , G 2 ) be schemes of computation trees from the set Tree ( σ ) . We will say that these schemes are equivalent if, for any structure U of the signature σ , the functions implemented by the computation trees ( S 1 , U ) and ( S 2 , U ) coincide.
Lemma 3.
Any scheme of computation tree S 1 = ( n , G 1 ) Tree ( σ ) can be transformed by changing the variables into a scheme of computation tree S 2 = ( n , G 2 ) Tree ( σ ) , which is equivalent to S 1 and in which all variables in the function and predicate expressions belong to the set X n + 2 h ( S 1 ) .
Proof. 
One can show that the number of function nodes in the scheme S 1 is at most 2 h ( S 1 ) . Each function node v of the scheme S 1 is labeled with a function expression
x i ( v ) q j ( v ) ( x l ( 1 , v ) , , x l ( m ( v ) , v ) ) ,
where m ( v ) is the arity of the function symbol q j ( v ) . Let v 1 , , v k be all function nodes of the scheme S 1 for which variables x i ( v 1 ) , , x i ( v k ) do not belong to the set X n . Let x j 1 , , x j p be all pairwise different variables in the sequence x i ( v 1 ) , , x i ( v k ) . Denote Y = { x j 1 , , x j p } .
In all expressions attached to function and predicate nodes of the scheme S 1 , we replace each variable that does not belong to the set X n Y with the variable x n 1 and replace variables x j 1 , , x j p with variables x n , , x n + p 1 , respectively. Denote by S 2 = ( n , G 2 ) the obtained scheme of computation tree. One can show that the scheme S 2 is equivalent to the scheme S 1 , and all variables in the function and predicate expressions of the scheme S 2 belong to the set X n + 2 h ( S 1 ) . □
Let ψ be a strictly limited complexity measure over the signature σ . For i ω , we denote ω ψ ( i ) = { q j : q j σ , ψ ( q j ) = i } . Define a partial function K ψ : ω ω as follows. Let i ω . If ω ψ ( i ) is a finite set, then K ψ ( i ) = | ω ψ ( i ) | . If ω ψ ( i ) is an infinite set, then the value K ψ ( i ) is indefinite.
For us, the most interesting situation is when the function K ψ is a total recursive function. If σ is a finite signature, then, evidently, K ψ is a total recursive function.
We now consider a class of strictly limited complexity measures ψ over the infinite signature σ for which K ψ is a total recursive function. Let σ = { q j : j ω } , g : ω ω { 0 } be a nondecreasing unbounded total recursive function, and ψ be a weighted depth over signature σ for which ψ ( q j ) = g ( j ) for any j ω . Then, ψ is a strictly limited complexity measure over the signature σ for which K ψ is a total recursive function.
Theorem 5.
Let ψ be a strictly limited complexity measure over the signature σ for which K ψ is a total recursive function, C be a nonempty class of structures of the signature σ, H be a nonempty subset of the set H ( σ ) , and the problem of solvability for the quadruple ( Probl ( σ ) , Tree ( σ ) , H , C ) be decidable. Then, the problem of optimization for the triple ( ψ , H , C ) is decidable.
Proof. 
Taking into account that the function K ψ is a total recursive function, it is not difficult to show that there exists an algorithm constructing the set { q j : q j σ , ψ ( q j ) r } for any number r ω . From this fact, it follows that there exists an algorithm which, for an arbitrary number r ω , an arbitrary number n ω { 0 } , and an arbitrary finite nonempty subset M of the set ω , constructs the set Tree ( σ , r , n , M ) of schemes of computation trees S = ( n , G ) from Tree ( σ ) satisfying the following conditions:
  • The terminal nodes of S are labeled with numbers from M.
  • h ( S ) r .
  • max { ψ ( q j ) : q j σ ( S ) } r .
  • All variables in the function and predicate expressions in the scheme S belong to the set X n + 2 r .
Let s = ( n , ν , β 1 , , β m ) be a scheme of problem from Probl ( σ ) , and let M ( s ) be the set of values of the map ν . Denote Tree ( s ) = Tree ( σ , ψ ( s ) , n , M ( s ) ) . We now shall see that the set Tree ( s ) contains a scheme of computation tree that is optimal relative to ψ , s, and C ( α ) .
Using Lemma 3, one can show that there exists a scheme of computation tree S Tree ( σ ) which is optimal relative to ψ , s, and C ( α ) , in which numbers attached to terminal nodes belong to the set M ( s ) , and in which all variables in function and predicate expressions in the scheme S belong to the set X n + 2 h ( S ) . Using Lemma 2, we obtain that ψ ( S ) ψ ( s ) . From this inequality and Lemma 1, it follows that h ( S ) ψ ( s ) and max { ψ ( q j ) : q j σ ( S ) } ψ ( s ) . Therefore, the scheme S, which is optimal relative to ψ , s, and C ( α ) , belongs to the set Tree ( s ) .
We now describe an algorithm solving the problem of optimization for the triple ( ψ , H , C ) . Let α H and s = ( n , ν , β 1 , , β m ) be a scheme of problem from the set Probl ( σ ) . First, we compute the value ψ ( s ) and construct the set M ( s ) . Next, we construct the set Tree ( s ) = Tree ( σ , ψ ( s ) , n , M ( s ) ) . Using the algorithm solving the problem of solvability for the quadruple ( Probl ( σ ) , Tree ( σ ) , H , C ) , we can find a scheme of computation tree S Tree ( s ) , which solves the scheme of problem s relative to the class C ( α ) and has the minimum ψ -complexity among such schemes of computation trees. The scheme of computation tree S is optimal relative to ψ , s, and C ( α ) . □
Corollary 1.
Let σ be a finite signature, ψ be a strictly limited complexity measure over the signature σ, C be a nonempty class of structures of the signature σ, H be a nonempty subset of the set H ( σ ) , and the problem of solvability for the quadruple ( Probl ( σ ) , Tree ( σ ) , H , C ) be decidable. Then, the problem of optimization for the triple ( ψ , H , C ) is decidable.
Theorem 6.
Let C be a nonempty class of structures of the signature σ, H be a nonempty subset of the set H ( σ ) , ψ be a strictly limited complexity measure over the signature σ, and the problem of satisfiability for the pair ( H Φ ( P ( * ) , σ ) , C ) be undecidable. Then, the problem of optimization for the triple ( ψ , H , C ) is undecidable.
Proof. 
Let us assume the contrary: the problem of optimization for the triple ( ψ , H , C ) is decidable. We now describe an algorithm for solving the problem of satisfiability for the pair ( H Φ ( P ( * ) , σ ) , C ) .
Let α H and γ Φ ( P ( * ) , σ ) . We construct a sentence of the signature σ that is logically equivalent to the sentence γ and is of the form x 0 x n 1 ( ( γ 11 δ 11 γ 1 m 1 δ 1 m 1 ) ( γ k 1 δ k 1 γ k m k δ k m k ) ) , where, for j = 1 , , k and i = 1 , , m j , δ j i E 2 and γ j i define an atomic formula of the signature σ of the form q l ( t 1 , , t p ) , where q l is a p-ary predicate symbol from σ , and t 1 , , t p are terms of the signature σ with variables from X n .
For j = 1 , , k , we construct a scheme of problem s j from Probl ( σ ) with special representation ( n , ν j , γ j 1 , , γ j m j ) such that ν j : E 2 m j E 2 and, for any δ ¯ E 2 m j , ν j ( δ ¯ ) = 1 if and only if δ ¯ = ( δ j 1 , , δ j m j ) . It is clear that, for any structure U of the signature σ and any tuple a ¯ A n , where A is the universe of U,
φ ( s j , U ) ( a ¯ ) = 0 , if   U ¬ ( γ j 1 ( a ¯ ) δ j 1 γ j m j ( a ¯ ) δ j m j ) , 1 , if   U γ j 1 ( a ¯ ) δ j 1 γ j m j ( a ¯ ) δ j m j .
We denote by S 0 the scheme of computation tree from Tree ( σ ) , which consists of only one node labeled with the number 0. It is clear that, for any structure U of the signature σ and any tuple a ¯ A n , where A is the universe of U, φ ( S 0 , U ) ( a ¯ ) = 0 .
Using an algorithm that solves the problem of optimization for the triple ( ψ , H , C ) , for j = 1 , , k , we find a scheme of computation tree S j Tree ( σ ) which solves the scheme of problem s j relative to the class C ( α ) and has the minimum ψ -complexity.
Using the properties of the strictly limited complexity measure ψ , it is not difficult to show that a structure U C such that U α γ exists if and only if there exists j { 1 , , k } for which the scheme of computation tree S j does not coincide with the scheme of computation tree S 0 . Therefore, the problem of satisfiability for the pair ( H Φ ( P ( * ) , σ ) , C ) is decidable, but this is impossible. □

7.2. Equality Is Allowed

We now consider the case when the equality is allowed.
Let σ be a finite or countable signature. If σ is finite, then we represent it in the form σ = { q 1 , , q m } . If σ is infinite, then we represent it in the form σ = { q 1 , q 2 , } . Let σ = = σ { q 0 } , where q 0 is the symbol denoting equality =, and σ = * is the set of finite words in the alphabet σ = , including the empty word λ .
Definition 19.
An e-complexity measure over the signature σ is an arbitrary map ψ : σ = * ω . The e-complexity measure ψ will be called strictly limited if it is computable and, for any α 1 , α 2 , α 3 σ = * , it possesses the following property: if α 2 λ , then ψ ( α 1 α 2 α 3 ) > ψ ( α 1 α 3 ) .
The prefix “e-” here and later indicates the presence of the equality.
Let ψ be an e-complexity measure over the signature σ . We extend it to the sets Probl = ( σ ) and Tree = ( σ ) . Let β be a finite sequence of the function and predicate expressions of the signature σ . We correspond to β a word word ( β ) from σ = * . If the length of β is equal to 0, then word ( β ) = λ . If β = β 1 , , β m , then word ( β ) = q i 1 q i m , where, for j = 1 , , m , q i j is the symbol from σ = contained in the expression β j . In particular, if β j has the form x l 1 = x l 2 , then q i j = q 0 .
Let s = ( n , ν , β 1 , , β m ) be a scheme of problem from the set Probl = ( σ ) . Then, ψ ( s ) = ψ ( word ( β 1 , , β m ) ) .
Let S = ( n , G ) be a scheme of computation tree from the set Tree = ( σ ) and τ = w 1 , d 1 , w 2 , d 2 , , w m , d m , w m + 1 be a complete path of the scheme S. We denote β τ = β 1 , , β m as the sequence of function and predicate expressions attached to nodes w 1 , , w m . Then, ψ ( S ) = max { ψ ( word ( β τ ) ) : τ Path ( S ) } , where Path ( S ) is the set of complete paths of the scheme S. The value ψ ( S ) is called the ψ -complexity of the scheme of computation tree S.
Let us recall that H = ( σ ) is the set of sentences of the signature σ . Let ψ be a strictly limited e-complexity measure over the signature σ , C be a nonempty class of structures of the signature σ , and H be a nonempty subset of the set H = ( σ ) .
Definition 20.
We now define the problem of e-optimization for the triple ( ψ , H , C ) : for arbitrary sentence α H and scheme of problem s Probl = ( σ ) , we should find a scheme of computation tree S Tree = ( σ ) which solves the scheme of problem s relative to the class C ( α ) and has the minimum ψ-complexity.
Let ψ be a strictly limited e-complexity measure over the signature σ . For i ω , we denote ω ψ ( i ) = { q j : q j σ = , ψ ( q j ) = i } . Define a partial function K ψ : ω ω as follows. Let i ω . If ω ψ ( i ) is a finite set, then K ψ ( i ) = | ω ψ ( i ) | . If ω ψ ( i ) is an infinite set, then the value K ψ ( i ) is indefinite.
The proof of the next statement is similar to the proof of Theorem 5.
Theorem 7.
Let ψ be a strictly limited e-complexity measure over the signature σ for which K ψ is a total recursive function, C be a nonempty class of structures of the signature σ, H be a nonempty subset of the set H = ( σ ) , and the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H , C ) be decidable. Then, the problem of e-optimization for the triple ( ψ , H , C ) is decidable.
Corollary 2.
Let σ be a finite signature, ψ be a strictly limited e-complexity measure over the signature σ, C be a nonempty class of structures of the signature σ, H be a nonempty subset of the set H = ( σ ) , and the problem of solvability for the quadruple ( Probl = ( σ ) , Tree = ( σ ) , H , C ) be decidable. Then, the problem of e-optimization for the triple ( ψ , H , C ) is decidable.
The proof of the next statement is similar to the proof of Theorem 6.
Theorem 8.
Let C be a nonempty class of structures of the signature σ, H be a nonempty subset of the set H = ( σ ) , ψ be a strictly limited e-complexity measure over the signature σ, and the problem of satisfiability for the pair ( H Φ = ( P ( * ) , σ ) , C ) be undecidable. Then, the problem of e-optimization for the triple ( ψ , H , C ) is undecidable.

8. Conclusions

This paper studied relationships among three algorithmic problems involving computation trees: the optimization, solvability, and satisfiability problems. It also studied the decidability of these problems in different situations.
A powerful toolkit, developed in particular in [8], was used to describe the decidability conditions of the satisfiability problem and, consequently, the decidability of the optimization problem for various classes of structures. Naturally, like any fairly universal approaches, the methods considered may not be applicable in some situations, for example, if we study a specific structure of interest to us.
This paper was limited to considering the fundamental question of the decidability of the optimization problem. To use such results in real applications, it is necessary to study the time complexity of the optimization problem. The prerequisites for this are provided by the book [8], which studies not only the decidability of the satisfiability problem but also its time complexity. One can consider such a study of the optimization problem, including the development of various heuristics for optimizing computation trees, as one of the future goals of this work.

Funding

This research was funded by the King Abdullah University of Science and Technology.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

No new data were created or analyzed in this study.

Acknowledgments

Research reported in this publication was supported by the King Abdullah University of Science and Technology (KAUST). The author is indebted to the anonymous reviewers for useful comments and suggestions.

Conflicts of Interest

The author declares no conflicts of interest.

References

  1. Ben-Or, M. Lower bounds for algebraic computation trees (preliminary report). In Proceedings of the 15th Annual ACM Symposium on Theory of Computing, STOC 1983, Boston, MA, USA, 25–27 April 1983; pp. 80–86. [Google Scholar]
  2. Gabrielov, A.; Vorobjov, N.N. On topological lower bounds for algebraic computation trees. Found. Comput. Math. 2017, 17, 61–72. [Google Scholar] [CrossRef]
  3. Grigoriev, D.; Vorobjov, N.N. Complexity lower bounds for computation trees with elementary transcendental function gates. Theor. Comput. Sci. 1996, 157, 185–214. [Google Scholar] [CrossRef]
  4. Moshkov, M. Rough analysis of computation trees. Discret. Appl. Math. 2022, 321, 90–108. [Google Scholar] [CrossRef]
  5. Ax, J. The elementary theory of finite fields. Ann. Math. 1968, 88, 239–271. [Google Scholar] [CrossRef]
  6. Ershov, Y.L.; Lavrov, I.A.; Taimanov, A.D.; Taitslin, M.A. Elementary theories. Russ. Math. Surv. 1965, 20, 35–105. [Google Scholar] [CrossRef]
  7. Ershov, Y.L.; Palyutin, E.A. Mathematical Logic, 6th ed.; Fizmatlit: Moscow, Russia, 2011. (In Russian) [Google Scholar]
  8. Börger, E.; Grädel, E.; Gurevich, Y. The Classical Decision Problem; Perspectives in Mathematical Logic; Springer: Berlin/Heidelberg, Germany, 1997. [Google Scholar]
  9. Gurevich, Y. On the effective recognizing of satisfiability of predicate formulas. Algebra Log. 1966, 5, 25–55. (In Russian) [Google Scholar]
  10. Gurevich, Y. The decision problem for logic of predicates and operations. Algebra Log. 1969, 8, 284–308. (In Russian) [Google Scholar] [CrossRef]
  11. Gurevich, Y. The decision problem for standard classes. J. Symb. Log. 1976, 41, 460–464. [Google Scholar] [CrossRef]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Moshkov, M. Algorithmic Problems for Computation Trees. Logics 2025, 3, 4. https://doi.org/10.3390/logics3020004

AMA Style

Moshkov M. Algorithmic Problems for Computation Trees. Logics. 2025; 3(2):4. https://doi.org/10.3390/logics3020004

Chicago/Turabian Style

Moshkov, Mikhail. 2025. "Algorithmic Problems for Computation Trees" Logics 3, no. 2: 4. https://doi.org/10.3390/logics3020004

APA Style

Moshkov, M. (2025). Algorithmic Problems for Computation Trees. Logics, 3(2), 4. https://doi.org/10.3390/logics3020004

Article Metrics

Back to TopTop