Descriptive complexity of #P functions: A new perspective
Introduction
The complexity of arithmetic computations is a current focal topic in complexity theory. Most prominent is Valiant's class #P of all functions that count accepting paths of nondeterministic polynomial-time Turing machines. This class has interesting complete problems like counting the number of satisfying assignments of propositional formulae or counting the number of perfect matchings of bipartite graphs (which is equivalent to computing the permanent of the adjacency matrix of such graphs [1]).
The class #P has been characterized in a model-theoretic way by Saluja, Subrahmanyam and Thakur in [2]. Their characterization is a natural generalization of Fagin's Theorem: Given a first-order formula with a free relational variable, instead of asking if there exists an assignment to this variable that makes the formula true (NP = ESO), we now ask to count how many such assignments there are. In this way, the class #P is characterized: . We use the superscript rel to denote that we are counting assignments to relational variables. The decision version PP of #P has been characterized from a descriptive complexity point of view in [3].
From another point of view, the class #P can be seen as the class of those functions that can be computed by arithmetic circuits of polynomial size, i.e., circuits with plus and times gates instead of the usual Boolean gates (cf., e.g., [4]). This is why here we speak of arithmetic computations. In the following, all circuit complexity classes we are referring to will be FO-uniform classes, which means that there are FO-formulae describing the circuits for all input lengths (a formal definition will be given).
It is very natural to restrict the resource bounds of such arithmetic circuits. An important class defined in this way is the class of all functions computed by polynomial-size bounded-depth arithmetic circuits. It is interesting to note that and all analogous classes defined by arithmetic circuits, i.e., plus-times circuits, can also be defined making use of a suitable counting process for Boolean circuits in which negations only occur in the form of input gates being labeled as negated: A witness that such a Boolean circuit accepts its input is a so-called proof tree of the circuit, i.e., a subtree of the circuit unwound into a tree containing the output gate and for each contained gate a minimum number of its inputs that allow to deduce that it evaluates to 1. That also means that all contained input gates have to evaluate to 1. Then the arithmetic class , restricted to binary inputs, can be characterized as the counting class of all functions that count proof trees of (Boolean) circuits. The correspondence between arithmetic computations and counting classes is explored in [5]. In this paper, we are mainly interested in these counting classes, and without further mention we use the notation in this vein.
There was no model-theoretic characterization of , until it was recently shown in [6] that , where means counting of possible Skolem functions for FO-formulae.
The aim of this paper is to compare the model-theoretic characterization obtained in [2] to that from [6] in order to get a unified view of both arithmetic circuit classes, and #P. This is done by noticing that the number of Skolem functions of an FO-formula can be counted as satisfying assignments to free function variables in a -formula. This gives rise to the idea to restate the result by Saluja et al. counting functions instead of relations. We call our class where we count assignments to function variables #FO, in contrast to Saluja et al.'s . In this setting, we get , which places both classes within .
Furthermore, we show that actually corresponds to a syntactic fragment of and, considering further syntactic subclasses of #FO defined by quantifier alternations, we get the inclusions Thus we establish (unconditionally, i.e., under no complexity theoretic assumptions) the complete structure of the alternation hierarchy within #FO and show where is located in this hierarchy.
Once we know that only universal quantifiers suffice to obtain the full class, i.e., , it is a natural question to ask how many universal quantifiers are needed to express certain functions. We obtain the result that the hierarchy based on the number of universal variables is infinite; however, a possible connection to the depth hierarchy within remains open.
We also study the question of which of the classes in our hierarchy are tractable. The main result we obtain is that all functions in posses a fully polynomial-time randomized approximation scheme (see e.g. [7]). For this, we consider a generalization of disjunctive normal-form we call “pseudo-DNF”. A pseudo-DNF has identities of the form or as literals, where f is a function symbol, for some and . These are then evaluated over assignments to the function symbols. The main technical result we obtain in this area is an FPRAS for counting satisfying assignments for pseudo-k-DNF formulae. Then we show that every problem in can be reduced to such a problem. The concept of pseudo-DNF and the approximability may be of independent interest.
We see that counting assignments to free function variables instead of relation variables in first-order formulae leads us to a hierarchy of arithmetic classes suitable for a study of the power and complexity of the class . We show that the hierarchy introduced by Saluja et al. [2] is not suitable for such a goal, see Section 7.
This paper is an extended full version of an earlier conference paper.1 In the meantime, another paper appeared [8] that extended the framework by Saluja et al. In that paper, a so called quantitative logic is introduced, where arithmetic operators are introduced into second-order logic. This framework allowed for characterizations of the classes FP, #P and FPSPACE. Furthermore, in a recent paper [9], the study of descriptive complexity of arithmetic circuit classes was extended from to other small arithmetic circuit classes: Inspired by a work of Compton and Laflamme [10], variants of a certain recursion on predicates was introduced into FO. This yields characterizations of the Boolean classes , and which extend to the respective counting classes. Another recent paper [11] studied functions counting assignments to free relational variables in formulae, including interesting connections to counting problems in team-based logics. In this way, a characterization of the class was obtained.
This paper is organized as follows: In the next section, we introduce relevant concepts from finite model theory. Here, we also introduce the Saluja et al. hierarchy, and we explain the model-theoretic characterization of . In Sect. 3 we introduce our new framework and the class #FO and its subclasses. In Sect. 4 we determine the full structure of the alternation hierarchy within #FO and place in this hierarchy. In Sect. 5 we study the class with respect to efficient approximability and show that every function in this class admits an FPRAS. Finally, we conclude in Sect. 8 with some open questions. In Sect. 6 we study the hierarchy defined by the number of universal variables in the -fragment. In Sect. 7 we turn to the hierarchy defined by Saluja et al. and show that the arithmetic class is incomparable to all except the level-0 class and the full class of this hierarchy.
Our proofs make use of a number of different results and techniques, some stemming from computational complexity theory (such as separation of Boolean circuit classes or the time hierarchy theorem for nondeterministic RAMs), some from model theory (like closure of certain fragments of first-order logic under extensions or taking substructures) or descriptive complexity (correspondence between time-bounded NRAMs and fragments of existential second-order logic). Most techniques have to be adapted to work in our very low complexity setting (new counting reductions, use of the right set of built-in relations, etc.). Our paper sits right in the intersection of finite model theory and computational complexity theory.
Section snippets
Definitions and preliminaries
In this paper we consider finite σ-structures where σ is a finite vocabulary consisting of relation and constant symbols. For such vocabularies σ, we denote by the class of finite σ-structures. For a structure , denotes its universe. We will always use structures with universe for some . Sometimes we will assume that our structures contain certain built-in relations and constants, e.g., , , and min. In the following, we will always make it clear
Connecting the characterizations of and #P
We will now establish a unified view of the model-theoretic characterizations of both and #P. This will be done by viewing as a syntactic subclass of #FO. Theorem 9 characterizes by a process of counting assignments to function variables in FO-formulae, but only in a very restricted setting. It is natural to define the process of counting functions in a more general way, similar to the framework of [2], repeated here in Definition 2, where Saluja et al. count assignments to free
An alternation hierarchy in #FO
In this section we study the quantifier alternation hierarchy of #FO. Interestingly, our approach allows us to locate in this hierarchy. First we note that the whole hierarchy collapses to a quite low class.
Theorem 14 .
Proof Let via an FO-formula in prenex normal form. We show how to transform φ to a -formula also defining h. As a first step, we change φ in such a way that for each existential variable instead of “there is an x” we say “there is a smallest x”. Formally, this can be
Feasibility of
One of the main goals of Saluja et al. in their paper [2] was to identify feasible subclasses of #P. They showed that -functions can be computed in polynomial time, but even more interestingly, that functions from a certain higher class allow a fully polynomial-time randomized approximation scheme. In this vein, we study the feasibility of the class in terms of approximability. We will show that every counting function in the class has a fully polynomial-time randomized
Hierarchy based on the number of universal variables
In this section we study another hierarchy in #FO based on syntactic restrictions, this time given by the number of universal variables.
Let denote the class of formulae of the form where ψ is a quantifier-free formula. The function class corresponding to is denoted by . We will show that for all . These results can be shown by applying a result of Grandjean and Olive which we will discuss next. Definition 26 We denote by the class of ESO-sentences in Skolem
compared to the classes from Saluja et al.
In this section we study the relationship of to the syntactic classes introduced in [2]. As in [2], these classes are defined assuming a built-in order relation only.
Theorem 28 , Let . Then the following holds: and .
Proof
The proof of the inclusion is analogous to the proof of Theorem 15 and is thus omitted.
For the second statement recall from Theorem 3 that . The claim for can be proven as
Conclusion
In this paper we have investigated a descriptive complexity approach to arithmetic computations. We have introduced a new framework to define arithmetic functions by counting assignments to free function variables of first-order formulae. Compared to a similar definition of Saluja et al. where assignments to free relational variables are counted, we obtain a hierarchy with a completely different structure, different properties and different problems. The main interest in our hierarchy is that
Declaration of Competing Interest
The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.
Acknowledgements
This work is partially supported by DFG VO 630/8-1, DAAD grant 57348395, grants 308099 and 308712 of the Academy of Finland and grant ANR-14-CE25-0017-02 AGGREG of the ANR.
We thank the anonymous reviewers for their helpful comments.
References (24)
The complexity of computing the permanent
Theor. Comput. Sci.
(1979)- et al.
Descriptive complexity of #P functions
J. Comput. Syst. Sci.
(1995) - et al.
On uniformity within NC1
J. Comput. Syst. Sci.
(1990) - et al.
On TC0, AC0, and arithmetic circuits
J. Comput. Syst. Sci.
(2000) - et al.
Subtractive reductions and complete problems for counting complexity classes
Theor. Comput. Sci.
(2005) - et al.
Graph properties checkable in linear time in the number of vertices
J. Comput. Syst. Sci.
(2004) A hierarchy for nondeterministic time complexity
J. Comput. Syst. Sci.
(1973)A logical characterization of the counting hierarchy
ACM Trans. Comput. Log.
(2009)Introduction to Circuit Complexity - a Uniform Approach
(1999)Arithmetic circuits and counting complexity classes
A model-theoretic characterization of constant-depth arithmetic circuits
Approximation Algorithms
Cited by (5)
An Approximate Skolem Function Counter
2024, Proceedings of the AAAI Conference on Artificial IntelligenceAn Approximate Skolem Function Counter
2023, arXivCounting Computations with Formulae: Logical Characterisations of Counting Complexity Classes
2023, Leibniz International Proceedings in Informatics, LIPIcsMajority Problems: Formal Study and Practical Resolution
2023, Conference Proceedings - IEEE International Conference on Systems, Man and Cybernetics