This paper was converted on www.awesomepapers.org from LaTeX by an anonymous user.
Want to know more? Visit the Converter page.

Descriptive complexity of real computation and probabilistic independence logic

Miika Hannula 0000-0002-9637-6664 University of HelsinkiFinland miika.hannula@helsinki.fi Juha Kontinen [0000-0003-0115-5154 University of HelsinkiFinland juha.kontinen@helsinki.fi Jan Van den Bussche 0000-0003-0072-3252 Hasselt UniversityBelgium jan.vandenbussche@uhasselt.be  and  Jonni Virtema 0000-0002-1582-3718 Hokkaido UniversityJapan jonni.virtema@let.hokudai.ac.jp Hasselt UniversityBelgium
(2020)
Abstract.

We introduce a novel variant of BSS machines called Separate Branching BSS machines (S-BSS in short) and develop a Fagin-type logical characterisation for languages decidable in nondeterministic polynomial time by S-BSS machines. We show that NP on S-BSS machines is strictly included in NP on BSS machines and that every NP language on S-BSS machines is a countable disjoint union of closed sets in the usual topology of n\mathbb{R}^{n}. Moreover, we establish that on Boolean inputs NP on S-BSS machines without real constants characterises a natural fragment of the complexity class \exists\mathbb{R} (a class of problems polynomial time reducible to the true existential theory of the reals) and hence lies between 𝖭𝖯\mathsf{NP} and 𝖯𝖲𝖯𝖠𝖢𝖤\mathsf{PSPACE}. Finally we apply our results to determine the data complexity of probabilistic independence logic.

Blum-Shub-Smale machines, descriptive complexity, team semantics, independence logic, real arithmetic.
journalyear: 2020copyright: acmlicensedconference: Proceedings of the 35th Annual ACM/IEEE Symposium on Logic in Computer Science; July 8–11, 2020; Saarbrücken, Germanybooktitle: Proceedings of the 35th Annual ACM/IEEE Symposium on Logic in Computer Science (LICS ’20), July 8–11, 2020, Saarbrücken, Germanyprice: 15.00doi: 10.1145/3373718.3394773isbn: 978-1-4503-7104-9/20/07ccs: Theory of computation Complexity theory and logicccs: Theory of computation Finite Model Theoryccs: Mathematics of computing Probability and statisticsccs: Theory of computation Models of computation
©Authors 2020. This is the author’s version of the work. It is posted here for your personal use. Not for redistribution. The definitive version was published in Proceedings of the 35th Annual ACM/IEEE Symposium on Logic in Computer Science (LICS ’20), July 8–11, 2020, Saarbrücken, Germany, ACM, New York, NY, USA, https://doi.org/10.1145/3373718.3394773.

1. Introduction

The existential theory of the reals consists of all first-order sentences that are true about the reals and are of the form

x1xnϕ(x1,,xn),\exists x_{1}\ldots\exists x_{n}\phi(x_{1},\ldots,x_{n}),

where ϕ\phi is a quantifier-free arithmetic formula containing inequalities and equalities. Known to be 𝖭𝖯\mathsf{NP}-hard on the one hand, and in 𝖯𝖲𝖯𝖠𝖢𝖤\mathsf{PSPACE} on the other hand (Canny, 1988), the exact complexity of this theory is a major open question. The existential theory of the reals is today attracting considerable interest due to its central role in geometric graph theory. First isolated as a complexity class in its own right in (Schaefer, 2009), \exists\mathbb{R} is defined as the closure of the existential theory of the reals under polynomial-time reductions. In the past decade several algebraic and geometric problems have been classified as complete for \exists\mathbb{R}; a recent example is the art gallery problem of deciding whether a polygon can be guarded by a given number of guards (Abrahamsen et al., 2018).

The existential theory of the reals is closely connected to Blum-Shub-Smale machines (BSS machine for short) which are essentially random access machines with registers that can store arbitrary real numbers and which can compute rational functions over reals in a single time step. Many complexity classes from classical complexity theory transfer to the realm of BSS machines, such as nondeterministic polynomial time (𝖭𝖯\mathsf{NP}_{\mathbb{R}}) over languages consisting of finite strings of reals. While the focus is primarily on languages over some numerical domain (e.g., reals or complex numbers), also Boolean inputs (strings over {0,1}\{0,1\}) can be considered. In this context \exists\mathbb{R} corresponds to the Boolean part of 𝖭𝖯0\mathsf{NP}_{\mathbb{R}}^{0} (BP(𝖭𝖯0)\mathrm{BP}(\mathsf{NP}_{\mathbb{R}}^{0})), obtained by restricting 𝖭𝖯\mathsf{NP}_{\mathbb{R}} to Boolean inputs and limiting the use of machine constants to 0 and 11, as feasibility of Boolean combinations of polynomial equations is complete for both of these classes (Bürgisser and Cucker, 2006; Schaefer and Stefankovic, 2017).

BSS computations can also be described logically. This research orientation was initiated by Grädel and Meer who showed that 𝖭𝖯\mathsf{NP}_{\mathbb{R}} is captured by a variant of existential second-order logic (ESO{\rm ESO}_{\mathbb{R}}) over metafinite structures (Grädel and Meer, 1995). Metafinite structures are two-sorted structures that consist of a finite structure, an infinite domain with some arithmetics (such as the reals with multiplication and addition), and weight functions bridging the two sorts (Grädel and Gurevich, 1998). Since the work by Grädel and Meer, others (see, e.g., (Cucker and Meer, 1999; Hansen and Meer, 2006; Meer, 2000)) have shed more light upon the descriptive complexity over the reals mirroring the development of classical descriptive complexity. In addition to metafinite structures, the connection between logical definability encompassing numerical structures and computational complexity has received attention in constraint databases (Benedikt et al., 2003; Grädel and Kreutzer, 1999; Kreutzer, 2000). A constraint database models, e.g., geometric data by combining a numerical context structure, such as the real arithmetic, with a finite set of quantifier-free formulae defining infinite database relations (Kanellakis et al., 1995).

In this paper we investigate the descriptive complexity of so-called probabilistic independence logic in terms of the BSS model of computation and the existential theory of the reals. Probabilistic independence logic is a recent addition to the vast family of new logics in team semantics. In team semantics (Väänänen, 2007) formulae are evaluated with respect to sets of assignments which are called teams. During the past decade research on team semantics has flourished with interesting connections to fields such as database theory (Hannula and Kontinen, 2016), statistics (Corander et al., 2019), hyperproperties (Krebs et al., 2018), and quantum information theory (Hyttinen et al., 2017), just to mention a few examples. The focus of this article is probabilistic team semantics that extends team based logics with probabilistic dependency notions. While the first ideas of probabilistic teams trace back to (Galliani, 2008; Hyttinen et al., 2017), the systematic study of the topic was initiated by the works (Durand et al., 2018a, b).

At the core of probabilistic independence logic FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c}) is the concept of conditional independence. The models of this logic are finite first-order structures but the notion of a team is replaced by a probabilistic team, i.e., a discrete probability distribution over a finite set of assignments. In (Durand et al., 2018b) it was observed that probabilistic independence logic is equivalent to a restriction of ESO{\rm ESO}_{\mathbb{R}} in which the weight functions are distributions. The exact complexity and relationship of FO(c){\rm FO}({\perp\!\!\!\perp_{\rm c}}) to ESO{\rm ESO}_{\mathbb{R}} and 𝖭𝖯\mathsf{NP}_{\mathbb{R}} was left as an open question; in this paper we present a (strict) sublogic of ESO{\rm ESO}_{\mathbb{R}} and a (strict) subclass of 𝖭𝖯\mathsf{NP}_{\mathbb{R}} that both capture FO(c){\rm FO}({\perp\!\!\!\perp_{\rm c}}).

Our contribution. In this paper we introduce a novel variant of BSS machines called Separate Branching BSS machines (S-BSS machines for short) and characterise its 𝖭𝖯\mathsf{NP} languages (denoted by S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}) with L-ESO[0,1][+,×,,(r)r]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}] that is a natural sublogic of ESO{\rm ESO}_{\mathbb{R}}. Likewise, we isolate a fragment [0,1]\exists[0,1]^{\leq} of the complexity class \exists\mathbb{R} and show that it coincides with the class of Boolean languages in S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}. Moreover we establish a topological characterisation of the languages decidable by S-BSS machines; we show that, under certain natural restrictions, languages decidable by S-BSS machines are countable disjoint unions of closed sets in the usual topology of n\mathbb{R}^{n}. The topological characterisation separates the languages decidable by BSS machines and S-BSS machines, respectively. Moreover it enables us to separate the complexity classes S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]} and 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}. Finally we show the equivalence of the logics L-ESO[0,1][+,×,,0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,\allowbreak 0,1}] and FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c}), implying that FO(c)S-𝖭𝖯[0,1]0{\rm FO}(\perp\!\!\!\perp_{\rm c})\equiv\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}. Table 1 summarises the main results of the paper.

Structure of the paper. Section 2 gives the basic definitions on descriptive complexity, BSS machines, and logics on \mathbb{R}-structures required for this paper. Section 3 focuses in giving logical characterisations of variants of 𝖭𝖯\mathsf{NP} on S-BSS machines. In Section 4 we establish the aforementioned topological characterisation of S-BSS decidable languages. In Section 5 we prove a hierarchy of the related complexity classes; in particular we separate S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]} and 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}. Section 6 deals with probabilistic team semantics and establishes that FO(c)S-𝖭𝖯[0,1]0{\rm FO}(\perp\!\!\!\perp_{\rm c})\equiv\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}. Section 7 concludes the paper.

BP(S-𝖭𝖯[0,1]0)\mathrm{BP}(\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}) BP(𝖭𝖯0)\mathrm{BP}(\mathsf{NP}^{0}_{\mathbb{R}})
𝖭𝖯\mathsf{NP} \subseteq

==

\subseteq

==

\subseteq 𝖯𝖲𝖯𝖠𝖢𝖤\mathsf{PSPACE}
[0,1]\exists[0,1]^{\leq} \exists\mathbb{R}
S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]} 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}

\equiv

\subset^{*}

\equiv

L-ESO[0,1][+,×,,0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,0,1}] ESO[+,×,,0,1]{\rm ESO}_{\mathbb{R}}[+,\times,\leq,0,1]

\equiv

FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c})
Table 1. Known complexity results and logical characterisations together with the main results of this paper. The results of this paper are marked with an asterisk (*). The top figure is with respect to Boolean inputs; on the bottom figure, the inputs can include real numbers.

2. Preliminaries

A vocabulary is relational (resp., functional) if it consists of only relation (resp., function) symbols. A structure is relational if it is defined over a relational vocabulary. We let Var1\mathrm{Var_{1}} and Var2\mathrm{Var_{2}} denote disjoint countable sets of first-order and function variables (with prescribed arities), respectively. We write x\vec{x} to denote a tuple of first-order variables and |x||\vec{x}\rvert to denote the length of that tuple. The arities of function variables ff and relation symbols RR are denoted by ar(f)\operatorname{ar}(f) and ar(R)\operatorname{ar}(R), respectively. If ff is a function with domain Dom(f)\operatorname{Dom}(f) and AA a set, we define fAf\upharpoonright A to be the function with domain Dom(f)A\operatorname{Dom}(f)\cap A that agrees with ff for each element in its domain. Given a finite set DD, a function f:D[0,1]f\colon D\to[0,1] that maps elements of DD to elements of the closed interval [0,1][0,1] of real numbers such that sDf(s)=1\sum_{s\in D}f(s)=1 is called a (probability) distribution.

2.1. \mathbb{R}-structures

Let τ\tau be a relational vocabulary. A τ\tau-structure is a tuple 𝔄=(A,(R𝔄)Rτ)\mathfrak{A}=(A,(R^{\mathfrak{A}})_{R\in\tau}), where AA is a nonempty set and each R𝔄R^{\mathfrak{A}} an ar(R)\operatorname{ar}(R)-ary relation on AA. The structure 𝔄\mathfrak{A} is a finite structure if τ\tau and AA are finite sets. In this paper, we consider structures that enrich finite relational τ\tau-structures by adding real numbers (\mathbb{R}) as a second domain sort and functions that map tuples over AA to \mathbb{R}.

Definition 2.1.

Let τ\tau and σ\sigma be respectively a finite relational and a finite functional vocabulary, and let XX\subseteq\mathbb{R}. An XX-structure of vocabulary τσ\tau\cup\sigma is a tuple

𝔄=(A,,(R𝔄)Rτ,(g𝔄)gσ),\mathfrak{A}=(A,\mathbb{R},(R^{\mathfrak{A}})_{R\in\tau},(g^{\mathfrak{A}})_{g\in\sigma}),

where the reduct of 𝔄\mathfrak{A} to τ\tau is a finite relational structure, and each g𝔄g^{\mathfrak{A}} is a weight function from Aar(g)A^{\operatorname{ar}(g)} to XX. Additionally, an d[0,1]d[0,1]-structure 𝔄\mathfrak{A} is defined analogously, with the exception that the weight functions g𝔄g^{\mathfrak{A}} are distributions.

An assignment is a total function s:Var1As:\mathrm{Var_{1}}\rightarrow A that assigns a value for each first-order variable. The modified assignment s[a/x]s[a/x] is an assignment that maps xx to aa and agrees with ss for all other variables.

Next, we define a variant of functional existential second-order logic with numerical terms (ESO{\rm ESO}_{\mathbb{R}}) that is designed to describe properties of \mathbb{R}-structures. As first-order terms we have only first-order variables. For a set σ\sigma of function symbols, the set of numerical σ\sigma-terms ii is generated by the following grammar:

i::=cf(x)i×ii+iSUMyi,i::=c\mid f(\vec{x})\mid i\times i\mid i+i\mid\mathrm{SUM}_{\vec{y}}\,i,

where cc\in\mathbb{R} is a real constant denoting itself, fσf\in\sigma, and x\vec{x} and y\vec{y} are tuples of first-order variables from Var1\mathrm{Var_{1}} such that the length of x\vec{x} is ar(f)\operatorname{ar}(f). The value of a numerical term ii in a structure 𝔄\mathfrak{A} under an assignment ss is denoted by [i]s𝔄[i]^{\mathfrak{A}}_{s}. In addition to the natural semantics for the real constants, we have the following rules for the numerical terms:

[f(x)]s𝔄:=f𝔄(s(x)),\displaystyle[f(\vec{x})]^{\mathfrak{A}}_{s}:=f^{\mathfrak{A}}(s(\vec{x})),\quad [i×j]s𝔄:=[i]s𝔄[j]s𝔄,\displaystyle[i\times j]^{\mathfrak{A}}_{s}:=[i]^{\mathfrak{A}}_{s}\cdot[j]^{\mathfrak{A}}_{s},
[i+j]𝔄:=[i]𝔄+[j]𝔄,\displaystyle[i+j]^{\mathfrak{A}}:=[i]^{\mathfrak{A}}+[j]^{\mathfrak{A}},\hskip 5.69054pt [SUMyi]s𝔄:=aA|y|[i]s[a/y]𝔄,\displaystyle[\mathrm{SUM}_{\vec{y}}\,i]^{\mathfrak{A}}_{s}:=\sum_{\vec{a}\in A^{|\vec{y}|}}[i]^{\mathfrak{A}}_{s[\vec{a}/\vec{y}]},

where +,,+,\cdot,\sum are the addition, multiplication, and summation of real numbers, respectively.

Definition 2.2 (Syntax of ESO{\rm ESO}_{\mathbb{R}}).

Let τ\tau be a finite relational vocabulary and σ\sigma a finite functional vocabulary. Let O{+,×,SUM}O\subseteq\{+,\times,\mathrm{SUM}\}, E{=,<,}E\subseteq\{=,<,\leq\}, and CC\subseteq\mathbb{R}. The set of τσ\tau\cup\sigma-formulae of ESO[O,E,C]{\rm ESO}_{\mathbb{R}}[{O,E,C}] is defined via the grammar:

ϕ::=\displaystyle\phi::=\ x=y¬x=yi𝑒j¬i𝑒jR(x)¬R(x)\displaystyle x=y\mid\neg x=y\mid i\mathrel{e}j\mid\neg{i\mathrel{e}j}\mid R(\vec{x})\mid\neg R(\vec{x})\mid{}
ϕϕϕϕxϕxϕfψ,\displaystyle\phi\land\phi\mid\phi\lor\phi\mid\exists x\phi\mid\forall x\phi\mid\exists f\psi,

where ii and jj are numerical σ\sigma-terms constructed using operations from OO and constants from CC, and eEe\in E, RτR\in\tau is a relation symbol, ff is a function variable, xx and yy are first-order variables and x\vec{x} a tuple of first-order variables, and ψ\psi is a τ(σ{f})\tau\cup(\sigma\cup\{f\})-formula of ESO[O,E,C]{\rm ESO}_{\mathbb{R}}[{O,E,C}].

Note that the syntax of ESO[O,E,C]{\rm ESO}_{\mathbb{R}}[{O,E,C}] allows first-order subformulae to appear only in negation normal form. This restriction however does not restrict the expressiveness of the language.

The semantics of ESO[O,E,C]{\rm ESO}_{\mathbb{R}}[{O,E,C}] is defined via \mathbb{R}-structures and assignments analogous to first-order logic; note that first-order variables are always assigned to a value in AA whereas functions map tuples over AA to \mathbb{R}. In addition to the clauses of first-order logic, we have the following semantical clauses:

𝔄si𝑒j[i]s𝔄𝑒[j]s𝔄,𝔄s¬i𝑒j𝔄⊧̸si𝑒j,\displaystyle\mathfrak{A}\models_{s}i\mathrel{e}j\Leftrightarrow[i]^{\mathfrak{A}}_{s}\mathrel{e}[j]^{\mathfrak{A}}_{s},\quad\mathfrak{A}\models_{s}\neg{i\mathrel{e}j}\Leftrightarrow\mathfrak{A}\not\models_{s}i\mathrel{e}j,
(1) 𝔄sfϕ𝔄[h/f]sϕ for some h:Aar(f),\displaystyle\mathfrak{A}\models_{s}\exists f\phi\Leftrightarrow\mathfrak{A}[h/f]\models_{s}\phi\text{ for some $h\colon A^{\operatorname{ar}(f)}\to\mathbb{R}$,}

where 𝔄[h/f]\mathfrak{A}[h/f] is the expansion of 𝔄\mathfrak{A} that interprets ff as hh.

Given SS\subseteq\mathbb{R}, we define ESOS[O,E,C]{\rm ESO}_{S}[{O,E,C}] as the variant of ESO[O,E,C]{\rm ESO}_{\mathbb{R}}[{O,E,C}] in which (1) is modified such that h:Aar(f)Sh\colon A^{\operatorname{ar}(f)}\to S, and ESOd[0,1][O,E,C]{\rm ESO}_{d[0,1]}[{O,E,C}] as the variant in which (1) is modified such that h:Aar(f)[0,1]h\colon A^{\operatorname{ar}(f)}\to[0,1] is a distribution, that is, ΣaAar(f)h(a)=1\Sigma_{\vec{a}\in A^{\operatorname{ar}(f)}}h(\vec{a})=1. Note that in the setting of ESOd[0,1][O,E,C]{\rm ESO}_{d[0,1]}[{O,E,C}] the value f𝔄f^{\mathfrak{A}} of a 0-ary function symbol ff is always 11.

Loose fragment.

For both SS\subseteq\mathbb{R} and S=d[0,1]S=d[0,1], define L-ESOS[O,E,C]\mathrm{L}\text{-}{\rm ESO}_{S}[{O,E,C}] as the loose fragment of ESOS[O,E,C]{\rm ESO}_{S}[{O,E,C}] in which negated numerical atoms ¬i𝑒j\neg{i\mathrel{e}j} are disallowed. We want to point out that as long as =E{=}\in E and 0,1C0,1\in C, the logic L-ESOS[O,E,C]\mathrm{L}\text{-}{\rm ESO}_{S}[{O,E,C}] subsumes existential second-order logic over finite structures (a precise formulation is given later by Proposition 3.1).

Expressivity comparisons.

Fix a relational vocabulary τ\tau and a functional vocabulary σ\sigma. Let \mathcal{L} and \mathcal{L}^{\prime} be some logics over τσ\tau\cup\sigma defined above, and let XX\subseteq\mathbb{R} or X=d[0,1]X=d[0,1]. For a formula ϕ\phi\in\mathcal{L}, define StrucX(ϕ)\mathrm{Struc}^{X}(\phi) to be the class of XX-structures 𝔄\mathfrak{A} of vocabulary τσ\tau\cup\sigma such that 𝔄ϕ\mathfrak{A}\models\phi. We write X\mathcal{L}\leq_{X}\mathcal{L}^{\prime} if for all sentences ϕ\phi\in\mathcal{L} there is a sentence ψ\psi\in\mathcal{L}^{\prime} such that StrucX(ϕ)=StrucX(ψ)\mathrm{Struc}^{X}(\phi)=\mathrm{Struc}^{X}(\psi). As usual, the shorthand X\equiv_{X} stands for X\leq_{X} in both directions. For X=X=\mathbb{R}, we write simply \leq and \equiv.

In plain words, the subscript SS in ESOS[O,E,C]{\rm ESO}_{S}[{O,E,C}] constitutes the class of functions available for quantification, whereas the superscript XX in StrucX(ϕ)\mathrm{Struc}^{X}(\phi) constitutes the class of functions available for function symbols in the vocabulary. Thus, ϕESOS[O,E,C]\phi\in{\rm ESO}_{S}[{O,E,C}] defines a class StrucX(ϕ)\mathrm{Struc}^{X}(\phi), even if SS and XX are different.

2.2. Blum-Shub-Smale Model

We will next give a definition of BSS machines (see e.g. (Blum et al., 1997)). We define :={nn}\mathbb{R}^{*}:=\bigcup\{\mathbb{R}^{n}\mid n\in\mathbb{N}\}. The size |x||x| of xnx\in\mathbb{R}^{n} is defined as nn. The space \mathbb{R}^{*} can be seen as the real analogue of Σ\Sigma^{*} for a finite set Σ\Sigma. We also define \mathbb{R}_{*} as the set of all sequences x=(xi)ix=(x_{i})_{i\in\mathbb{Z}} where xix_{i}\in\mathbb{R}. The members of \mathbb{R}_{*} are thus of the form (,x2,x1,x0,x1,x2,)(\ldots,x_{-2},x_{-1},x_{0},x_{1},x_{2},\ldots). Given an element xx\in\mathbb{R}^{*}\cup\mathbb{R}_{*} we write xix_{i} for the iith coordinate of xx. The space \mathbb{R}_{*} has natural shift operations. We define shift left σl:\sigma_{l}\colon\mathbb{R}_{*}\to\mathbb{R}_{*} and shift right σr:\sigma_{r}\colon\mathbb{R}_{*}\to\mathbb{R}_{*} as σl(x)i:=xi+1\sigma_{l}(x)_{i}:=x_{i+1} and σr(x)i:=xi1\sigma_{r}(x)_{i}:=x_{i-1}.

Definition 2.3 (BSS machines).

A BSS machine consists of an input space =\mathcal{I}=\mathbb{R}^{*}, a state space 𝒮=\mathcal{S}=\mathbb{R}_{*}, and an output space 𝒪=\mathcal{O}=\mathbb{R}^{*}, together with a connected directed graph whose nodes are labelled by 1,,N1,\ldots,N. The nodes are of five different types.

  1. (1)

    Input node. The node labeled by 11 is the only input node. The node is associated with a next node β(1)\beta(1) and the input mapping gI:𝒮g_{I}:\mathcal{I}\to\mathcal{S}.

  2. (2)

    Output node. The node labeled by NN is the only output node. This node is not associated with any next node. Once this node is reached, the computation halts, and the result of the computation is placed on the output space by the output mapping gO:𝒮𝒪g_{O}:\mathcal{S}\to\mathcal{O}.

  3. (3)

    Computation nodes. A computation node mm is associated with a next node β(m)\beta(m) and a mapping gm:𝒮𝒮g_{m}:\mathcal{S}\to\mathcal{S} such that for some cc\in\mathbb{R} and i,j,ki,j,k\in\mathbb{Z} the mapping gmg_{m} is identity on coordinates lil\neq i and on coordinate ii one of the following holds:

    • gm(x)i=xj+xkg_{m}(x)_{i}=x_{j}+x_{k} (addition),

    • gm(x)i=xjxkg_{m}(x)_{i}=x_{j}-x_{k} (subtraction),

    • gm(x)i=xj×xkg_{m}(x)_{i}=x_{j}\times x_{k} (multiplication),

    • gm(x)i=cg_{m}(x)_{i}=c (constant assignment).

  4. (4)

    Branch nodes. A branch node mm is associated with nodes β(m)\beta^{-}(m) and β+(m)\beta^{+}(m). Given x𝒮x\in\mathcal{S} the next node is β(m)\beta^{-}(m) if x00x_{0}\leq 0, and β+(m)\beta^{+}(m) otherwise.

  5. (5)

    Shift nodes. A shift node mm is associated either with shift left σl\sigma_{l} or shift right σr\sigma_{r}, and a next node β(m)\beta(m).

The input mapping gI:𝒮g_{I}:\mathcal{I}\to\mathcal{S} places an input (x1,,xn)(x_{1},\ldots,x_{n}) in the state

(,0,n,x1,,xn,0,)𝒮,(\ldots,0,n,x_{1},\ldots,x_{n},0,\ldots)\in\mathcal{S},

where the size of the input nn is located at the zeroth coordinate. The output mapping gO:𝒮𝒪g_{O}\colon\mathcal{S}\to\mathcal{O} maps a state to the string consisting of its first ll positive coordinates, where ll is the number of consecutive ones stored in the negative coordinates starting from the first negative coordinate. For instance, gOg_{O} maps

(,2,1,1,1,n,x1,x2,x3,x4,)𝒮,(\ldots,2,1,1,1,n,x_{1},x_{2},x_{3},x_{4},\ldots)\in\mathcal{S},

to (x1,x2,x3)𝒪(x_{1},x_{2},x_{3})\in\mathcal{O}. A configuration at any moment of computation consists of a node m{1,,N}m\in\{1,\ldots,N\} and a current state x𝒮x\in\mathcal{S}. The (sometimes partial) input-output function fM:f_{M}:\mathbb{R}^{*}\to\mathbb{R}^{*} of a machine MM is now defined in the obvious manner. A function f:f:\mathbb{R}^{*}\to\mathbb{R}^{*} is computable if f=fMf=f_{M} for some machine MM. A language LL\subseteq\mathbb{R}^{*} is decided by a BSS machine MM if its characteristic function χL:\chi_{L}\colon\mathbb{R}^{*}\to\mathbb{R}^{*} is fMf_{M}.

Deterministic complexity classes.

A machine MM runs in (deterministic) time t:t\colon\mathbb{N}\rightarrow\mathbb{N}, if MM reaches the output in t(|x|)t(|x|) steps for each input xx\in\mathcal{I}. The machine MM runs in polynomial time if tt is a polynomial function. The complexity class 𝖯\mathsf{P}_{\mathbb{R}} is defined as the set of all subsets of \mathbb{R}^{*} that are decided by some machine MM running in polynomial time.

Nondeterministic complexity classes.

A language LL\subseteq\mathbb{R}^{*} is decided nondeterministically by a BSS machine MM, if

xL if and only if fM((x,x))=1, for some x,x\in L\quad\text{ if and only if }\quad f_{M}((x,x^{\prime}))=1,\text{ for some $x^{\prime}\in\mathbb{R}^{*}$},

when a slightly different input mapping gI:𝒮g_{I}:\mathcal{I}\to\mathcal{S}, which places an input (x1,,xn,x1,,xm)(x_{1},\ldots,x_{n},x^{\prime}_{1},\ldots,x^{\prime}_{m}) in the state

(,0,n,m,x1,,xn,x1,,xm,)𝒮,(\ldots,0,n,m,x_{1},\ldots,x_{n},x^{\prime}_{1},\ldots,x^{\prime}_{m},\ldots)\in\mathcal{S},

where the sizes of xx and xx^{\prime} are respectively placed on the first two coordinates, is used. When we consider languages that a machine MM decides nondeterministically, we call MM nondeterministic. Sometimes when we wish to emphasize that this is not the case, we call MM deterministic. Moreover, we say that MM is [0,1]-nondeterministic, if the guessed strings xx^{\prime} are required to be from [0,1][0,1]^{*}. L is decided in time t:t\colon\mathbb{N}\rightarrow\mathbb{N}, if, for every xLx\in L, MM reaches the output 11 in t(|x|)t(|x|) steps for some xx^{\prime}\in\mathbb{R}^{*}. The machine runs in polynomial time if tt is a polynomial function. The class 𝖭𝖯\mathsf{NP}_{\mathbb{R}} consists of those languages LL\subseteq\mathbb{R}^{*} for which there exists a machine MM that nondeterministically decides LL in polynomial time. Note that, in this case, the size of xx^{\prime} above can be bounded by a polynomial (e.g., the running time of MM) without altering the definition. The complexity class 𝖭𝖯\mathsf{NP}_{\mathbb{R}} has many natural complete problems such as 4-FEAS, i.e., the problem of determining whether a polynomial of degree four has a real root (Blum et al., 1989).

Complexity classes with Boolean restrictions.

If we restrict attention to machines MM that may use only c{0,1}c\in\{0,1\} in constant assignment nodes, then the corresponding complexity classes are denoted using an additional superscript 0 (e.g., as in 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}). Complexity classes over real computation can also be related to standard complexity classes. For a complexity class 𝒞\mathcal{C} over the reals, the Boolean part of 𝒞\mathcal{C}, written BP(𝒞)\mathrm{BP}(\mathcal{C}), is defined as {L{0,1}L𝒞}\{L\cap\{0,1\}^{*}\mid L\in\mathcal{C}\}.

Descriptive complexity.

Similar to Turing machines, also BSS machines can be studied from the vantage point of descriptive complexity. To this end, finite \mathbb{R}-structures are encoded as finite strings of reals using so-called rankings that stipulate an ordering on the finite domain. Let 𝔄\mathfrak{A} be an \mathbb{R}-structure over τσ\tau\cup\sigma where τ\tau and σ\sigma are relational and functional vocabularies, respectively. A ranking of 𝔄\mathfrak{A} is any bijection π:Dom(A){1,,|A|}\pi\colon\operatorname{Dom}(A)\to\{1,\ldots,|A|\}. A ranking π\pi and the lexicographic ordering on k\mathbb{N}^{k} induce a kk-ranking πk:Dom(A)k{1,,|A|k}\pi_{k}\colon\operatorname{Dom}(A)^{k}\to\{1,\ldots,|A|^{k}\} for kk\in\mathbb{N}. Furthermore, π\pi induces the following encoding encπ(𝔄)\mathrm{enc}_{\pi}(\mathfrak{A}). First we define encπ(R𝔄)\mathrm{enc}_{\pi}(R^{\mathfrak{A}}) and encπ(f𝔄)\mathrm{enc}_{\pi}(f^{\mathfrak{A}}) for RτR\in\tau and fσf\in\sigma:

  • Let RτR\in\tau be a kk-ary relation symbol. The encoding encπ(R𝔄)\mathrm{enc}_{\pi}(R^{\mathfrak{A}}) is a binary string of length |A|k\lvert A\rvert^{k} such that the jjth symbol in encπ(R𝔄)\mathrm{enc}_{\pi}(R^{\mathfrak{A}}) is 11 if and only if (a1,,ak)R𝔄(a_{1},\ldots,a_{k})\in R^{\mathfrak{A}}, where πk(a1,,ak)=j\pi_{k}(a_{1},\ldots,a_{k})=j.

  • Let fσf\in\sigma be a kk-ary function symbol. The encoding encπ(f𝔄)\mathrm{enc}_{\pi}(f^{\mathfrak{A}}) is string of real numbers of length |A|k\lvert A\rvert^{k} such that the jjth symbol in encπ(f𝔄)\mathrm{enc}_{\pi}(f^{\mathfrak{A}}) is f𝔄(a)f^{\mathfrak{A}}(\vec{a}), where πk(a)=j\pi_{k}(\vec{a})=j.

The encoding encπ(𝔄)\mathrm{enc}_{\pi}(\mathfrak{A}) is then the concatenation of the string (1,,1)(1,\ldots,1) of length |A||A| and the encodings of the interpretations of the relation and function symbols in τσ\tau\cup\sigma. We denote by enc(𝔄)\mathrm{enc}(\mathfrak{A}) any encoding encπ(𝔄)\mathrm{enc}_{\pi}(\mathfrak{A}) of 𝔄\mathfrak{A}.

Let 𝒞\mathcal{C} be a complexity class and ESOS[O,E,C]{\rm ESO}_{S}[{O,E,C}] a logic, where O{+,×,SUM}O\subseteq\{+,\times,\mathrm{SUM}\}, E{=,<,}E\subseteq\{=,<,\leq\}, CC\subseteq\mathbb{R}, and SS\subseteq\mathbb{R} or S=d[0,1]S=d[0,1]. Let XX\subseteq\mathbb{R} or X=d[0,1]X=d[0,1], and let 𝒮\mathcal{S} be an arbitrary class of XX-structures over τσ\tau\cup\sigma that is closed under isomorphisms. We write enc(𝒮)\mathrm{enc}(\mathcal{S}) for the set of encodings of structures in 𝒮\mathcal{S}. Consider the following two conditions:

  1. (i)

    enc(𝒮)={enc(𝔄)𝔄StrucX(ϕ)}\mathrm{enc}(\mathcal{S})=\{\mathrm{enc}(\mathfrak{A})\mid\mathfrak{A}\in\mathrm{Struc}^{X}(\phi)\} for some ϕESOS[O,E,C][τσ]}\phi\in{\rm ESO}_{S}[{O,E,C}][\tau\cup\sigma]\},

  2. (ii)

    enc(𝒮)𝒞\mathrm{enc}(\mathcal{S})\in\mathcal{C}.

If (i)(i) implies (ii)(ii), we write ESOS[O,E,C]X𝒞{\rm ESO}_{S}[{O,E,C}]\leq_{X}\mathcal{C}, and if the vice versa holds, we write 𝒞XESOS[O,E,C]\mathcal{C}\leq_{X}{\rm ESO}_{S}[{O,E,C}]. If both directions hold, then we write ESOS[O,E,C]X𝒞{\rm ESO}_{S}[{O,E,C}]\equiv_{X}\mathcal{C}. We omit the subscript XX in the notation if X=X=\mathbb{R}.

The following results due to Grädel and Meer extend Fagin’s theorem to the context of real computation.111Only the first equivalence is explicitly stated in (Grädel and Meer, 1995). The second, however, is a simple corollary, using the fact that 0 and 11 can be identified in ESO[+,×,]{\rm ESO}_{\mathbb{R}}[{+,\times,\leq}]; these two are the only idempotent reals for multiplication, and 0 is the only idempotent real for addition.

Theorem 2.4 ((Grädel and Meer, 1995)).

ESO[+,×,,(r)r]𝖭𝖯{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv\mathsf{NP}_{\mathbb{R}} and
ESO[+,×,]𝖭𝖯0{\rm ESO}_{\mathbb{R}}[{+,\times,\leq}]\equiv\mathsf{NP}^{0}_{\mathbb{R}}.

2.3. Separate Branching BSS

We now define a restricted version of the BSS model which branches with respect to two separated intervals (,ϵ](-\infty,\epsilon^{-}] and [ϵ+,)[\epsilon^{+},\infty). We will later relate these BSS machines to certain fragments of ESO{\rm ESO}_{\mathbb{R}} and the existential theory of the reals.

Definition 2.5 (Separate Branching BSS Machine).

Separate branching BSS machines (S-BSS machines for short) are otherwise identical to the BSS machines of Definition 2.3, except that the branch nodes are replaced with the following separate branch nodes.

  • Separate branch nodes. A separate branch node mm is associated with ϵ,ϵ+\epsilon_{-},\epsilon_{+}\in\mathbb{R}, ϵ<ϵ+\epsilon_{-}<\epsilon_{+}, and nodes β+(m)\beta^{+}(m) and β(m)\beta^{-}(m). Given x𝒮x\in\mathcal{S} the next node is β+(m)\beta^{+}(m) if x0ϵ+x_{0}\geq\epsilon_{+}, β(m)\beta^{-}(m) if x0ϵx_{0}\leq\epsilon_{-}, and otherwise the input is rejected.

Note that for a given S-BSS machine it is easy to write an equivalent BSS machine. A priori it is not clear whether the converse is possible; in fact, we will later show that in some cases the converse is not possible.

We can now define the variants of the complexity classes 𝖯\mathsf{P}_{\mathbb{R}}, 𝖯0\mathsf{P}^{0}_{\mathbb{R}}, 𝖭𝖯\mathsf{NP}_{\mathbb{R}}, and 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}} that are obtained by replacing BSS machines with S-BSS machines in the definitions of the complexity classes. Furthermore, we define 𝖭𝖯[0,1]\mathsf{NP}_{[0,1]}, and 𝖭𝖯[0,1]0\mathsf{NP}^{0}_{[0,1]} as the variants of 𝖭𝖯\mathsf{NP}_{\mathbb{R}}, and 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}} in which the input xx may be any element from \mathbb{R}^{*} but the guessed element xx^{\prime} must be taken from [0,1][0,1]^{*}. Let 𝒞\mathcal{C} be one of the aforementioned complexity classes. We define S-𝒞\mathrm{S}\textrm{-}\mathcal{C} to be the variant of 𝒞\mathcal{C}, where, instead of BSS machines, S-BSS machines are used. If 𝒞\mathcal{C} includes the superscript 0, this means that not only the parameter cc in constant assignment, but also ϵ\epsilon_{-} and ϵ+\epsilon_{+} in separate branching are from {0,1}\{0,1\}.

3. Descriptive complexity of nondeterministic polynomial time in S-BSS

We now show that S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} corresponds to a numerical variant of ESO{\rm ESO} in which quantified functions take values from the unit interval and numerical inequality atoms only appear positively. Later we show that both of these restrictions are necessary in the sense that removing either one lifts expressiveness to the level of ESO[+,×,,(r)r]{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}] which captures 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. On the other hand, we give a logical proof, based on topological arguments, that S-𝖭𝖯[0,1]<𝖭𝖯\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}<\mathsf{NP}_{\mathbb{R}}. The proof of Theorem 3.3 is a nontrivial adaptation of the proof of Theorem 2.4 (see (Grädel and Meer, 1995, Theorem 4.2)). In the proof we apply Lemma 3.2 and, by Proposition 3.1, assume without loss of generality built-in ESO{\rm ESO} definable predicates on the finite part.

Let 0 and 11 be distinct constants, dd a (k+1)(k+1)-ary distribution, and RR a kk-ary relation on a finite domain AA of size nn. We say that dd is the characteristic distribution of RR (w.r.t. 0 and 11) if aR\vec{a}\in R implies d(a,1)=1nkd(\vec{a},1)=\frac{1}{n^{k}}, and aR\vec{a}\notin R implies d(a,0)=1nkd(\vec{a},0)=\frac{1}{n^{k}}. The next proposition implies that it is possible to simulate existential quantification of ESO{\rm ESO} definable predicates on the finite domain using function (or distribution) quantification; in particular, we may assume without loss of generality built-in predicates such as a linear ordering and its induced successor relation on the finite domain. Clearly, any predicate that is ESO{\rm ESO}-definable over finite structures is also ESO{\rm ESO}-definable (w.r.t. the finite domain) over \mathbb{R}-structures.

Below, we write L\mathrm{L}-ESOS[O,E,C,X]{\rm ESO}_{S}[O,E,C,\exists X] to denote the extension of L\mathrm{L}-ESOS[O,E,C]{\rm ESO}_{S}[O,E,C] by existential quantification of relations over the finite domain with the usual semantics.

Proposition 3.1.

Let {0,1}S\{0,1\}\subseteq S and O,E,CO,E,C be arbitrary. For every formula ϕL\phi\in\mathrm{L}-ESOS[O,E,C,X]{\rm ESO}_{S}[O,E,C,\exists X] there exist formulas ϕL\phi^{\prime}\in\mathrm{L}-ESOS[O,E{=},C{0,1}]{\rm ESO}_{S}[O,E\cup\{=\},C\cup\{0,1\}] and ϕ′′L\phi^{\prime\prime}\in\mathrm{L}-ESOd[0,1][O,E{=},C]{\rm ESO}_{d[0,1]}[O,E\cup\{=\},C] such that, for every \mathbb{R}-structure 𝔄{\mathfrak{A}} and assignment ss,

𝔄sϕ𝔄sϕ𝔄sϕ′′.{\mathfrak{A}}\models_{s}\phi\,\Leftrightarrow\,{\mathfrak{A}}\models_{s}\phi^{\prime}\,\Leftrightarrow\,{\mathfrak{A}}\models_{s}\phi^{\prime\prime}.
Proof.

The sentence ϕ\phi^{\prime} (ϕ′′\phi^{\prime\prime}, resp.) is obtained from ϕ\phi by a translation that is the identity function, except that, for second-order variables XX of arity kk, we rewrite the quantifications X\exists X as fX\exists f_{X}, where fXf_{X} is a kk-ary ((k+1k+1)-ary, resp.) function variable, and the atoms X(x)X(\vec{x}) and ¬X(x)\neg X(\vec{x}) by fX(x)=1f_{X}(\vec{x})=1 and fX(x)=0f_{X}(\vec{x})=0 (fX(x,1)=u(x)f_{X}(\vec{x},1)=u(\vec{x}) and fX(x,0)=u(x)f_{X}(\vec{x},0)=u(\vec{x}), resp.), respectively. Here, uu is the kk-ary uniform distribution which is definable in L\mathrm{L}-ESOd[0,1][=]{\rm ESO}_{d[0,1]}{[=]} by xxu(x)=u(x)\forall\vec{x}\vec{x}^{\prime}u(\vec{x})=u(\vec{x}^{\prime}). ∎

Lemma 3.2.

If {0,1}C\{0,1\}\subseteq C, we have L-ESO[0,1][+,×,,C]L-ESO[1,1][+,×,,C]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,C}]\equiv\mathrm{L}\text{-}{\rm ESO}_{[-1,1]}[{+,\times,\leq,C}].

Proof.

Left-to-right direction is straightforward; the quantification fψ\exists f\,\psi in L-ESO[0,1][+,×,,C]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,C}] can be simulated in L-ESO[1,1][+,×,,C]\mathrm{L}\text{-}{\rm ESO}_{[-1,1]}[{+,\times,\leq,C}] by the formula f(x 0f(x)ψ).\exists f(\forall\vec{x}\,0\leq f(\vec{x})\wedge\psi).

The converse direction is nontrivial. Let ϕ\phi be an arbitrary L-ESO[1,1][+,×,,C]\mathrm{L}\text{-}{\rm ESO}_{[-1,1]}[{+,\times,\leq,C}]-formula. We will show how to construct an equivalent L-ESO[0,1][+,×,,C]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,C}]-formula ϕ\phi^{\prime}. By the standard Skolemization argument we may assume that ϕ\phi is in the prenex normal form. Moreover, we assume that every atomic formula of the form t1t2t_{1}\leq t_{2} is written such that t1t_{1} and t2t_{2} are multivariate polynomials where function terms f(x)f(\vec{x}) play the role of variables; this normal form is obtained by using the distributive laws of addition and multiplication. Let MM be the smallest set that includes every term of polynomials t1t_{1} and t2t_{2} such that t1t2t_{1}\leq t_{2} is a subformula of ϕ\phi, and is closed under taking subterms. Clearly MM is a finite set, for its cardinality is bounded by the length of ϕ\phi. For each pMp\in M with mm variables, we introduce an mm-ary function gpg_{p} that will be interpreted as the sign function for the term pp. Let xp\vec{x}_{p} be the related tuple of variables. The idea is that gp(a)=0g_{p}(\vec{a})=0 (gp(a)=1g_{p}(\vec{a})=1) if p(a)<0p(\vec{a})<0 (p(a)0p(\vec{a})\geq 0).

We are now ready to define the translation ϕϕ\phi\mapsto\phi^{\prime}, where

ϕ=f1fmQ1x1Qnxnψ\phi=\exists f_{1}\ldots\exists f_{m}Q_{1}x_{1}\ldots Q_{n}x_{n}\,\psi

is in the normal form mentioned above. We define

ϕ:=pMgpf1fmQ1x1Qnxn(θψ),\phi^{\prime}:=\mathop{\lower 3.22916pt\hbox{${{{{\exists}}}}$}}\limits_{p\in M}g_{p}\exists f_{1}\ldots\exists f_{m}Q_{1}x_{1}\ldots Q_{n}x_{n}(\theta\land\psi^{\circ}),

where the recursively defined translation is homomorphic for the Boolean connectives and identity for first-order literals.

For atomic formulae t1t2t_{1}\leq t_{2} of the form s1++slr1++rms_{1}+\dots+s_{l}\leq r_{1}+\dots+r_{m} the translation is defined as follows. The translation makes certain that every term (of polynomial) of the inequation after the translation has a non-negative value; this is done by moving terms to the other side of the inequation. Denote ={1,,l}\mathcal{I}=\{1,\dots,l\} and 𝒥={1,,m}\mathcal{J}=\{1,\dots,m\}, and define (t1t2)(t_{1}\leq t_{2})^{\circ} as

IJ𝒥\displaystyle\bigvee_{\begin{subarray}{c}I\subseteq\mathcal{I}\\ J\subseteq\mathcal{J}\end{subarray}} (iIjJgsi(xsi)=1grj(xrj)=1\displaystyle\Big{(}\bigwedge_{\begin{subarray}{c}i\in I\\ j\in J\end{subarray}}g_{s_{i}}(\vec{x}_{s_{i}})=1\land g_{r_{j}}(\vec{x}_{r_{j}})=1
iIj𝒥Jgsi(xsi)=0grj(xrj)=0\displaystyle\land\bigwedge_{\begin{subarray}{c}i\in\mathcal{I}\setminus I\\ j\in\mathcal{J}\setminus J\end{subarray}}g_{s_{i}}(\vec{x}_{s_{i}})=0\land g_{r_{j}}(\vec{x}_{r_{j}})=0
iIsi+j𝒥JrjiIsi+jJrj).\displaystyle\land\sum_{i\in I}s_{i}+\sum_{j\in\mathcal{J}\setminus J}r_{j}\leq\sum_{i\in\mathcal{I}\setminus I}s_{i}+\sum_{j\in J}r_{j}\Big{)}.

Finally the subformula θ\theta makes sure that the signs of the terms in pMp\in M propagate correctly from subterms to terms. Define θ\theta as

pMcM[0,]dM[,0)x(gp(x)=0gp(x)=1)gc=1gd=0\displaystyle\bigwedge_{\begin{subarray}{c}p\in M\\ c\in M\cap[0,\infty]\\ d\in M\cap[-\infty,0)\end{subarray}}\forall\vec{x}\big{(}g_{p}(\vec{x})=0\lor g_{p}(\vec{x})=1\big{)}\land g_{c}=1\land g_{d}=0
p,q,rMp=q×r((gq(xq)=gr(xr)gp(xp)=1)\displaystyle\land\bigwedge_{\begin{subarray}{c}p,q,r\in M\\ p=q\times r\end{subarray}}\Big{(}\big{(}g_{q}(\vec{x}_{q})=g_{r}(\vec{x}_{r})\land g_{p}(\vec{x}_{p})=1\big{)}
(gq(xq)=0gr(xr)=1gp(xp)=0)\displaystyle\quad\quad\lor\big{(}g_{q}(\vec{x}_{q})=0\land g_{r}(\vec{x}_{r})=1\land g_{p}(\vec{x}_{p})=0\big{)}
(gq(xq)=1gr(xr)=0gp(xp)=0)).\displaystyle\quad\quad\lor\big{(}g_{q}(\vec{x}_{q})=1\land g_{r}(\vec{x}_{r})=0\land g_{p}(\vec{x}_{p})=0\big{)}\Big{)}.

Note that the sign function maps terms of value 0 to either 0 or 11, since for the purpose of the construction the sign of 0 valued terms does not matter. ∎

Theorem 3.3.

L-ESO[0,1][+,×,,(r)r]S-𝖭𝖯[0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}.

Proof.

Right-to-left direction. Suppose LS-𝖭𝖯[0,1]L\in\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} is a class of \mathbb{R}-structures that is closed under isomorphisms. By Lemma 3.2 it suffices to construct an L-ESO[1,1][+,×,,]\mathrm{L}\text{-}{\rm ESO}_{[-1,1]}[{+,\times,\leq,\mathbb{R}}] sentence ϕ\phi such that 𝔄ϕ{\mathfrak{A}}\models\phi iff 𝔄L{\mathfrak{A}}\in L for all \mathbb{R}-structures 𝔄{\mathfrak{A}}. Let MM be an S-BSS machine such that MM consists of NN nodes, and for each input xx it accepts (x,x)(x,x^{\prime}) for some x[0,1]x^{\prime}\in[0,1]^{*} in time |x|k|x|^{k^{*}} iff x=enc(𝔄)x=\mathrm{enc}({\mathfrak{A}}) for some 𝔄L{\mathfrak{A}}\in L, where kk^{*} is some fixed natural number. We may assume that |x||x^{\prime}| is of size |x|k|x|^{k^{*}}. Let kk be a fixed natural number such that |x|k|A|k|x\rvert^{k^{*}}\leq|A\rvert^{k}; such a kk always exists since |enc(𝔄)|\lvert\mathrm{enc}({\mathfrak{A}})\rvert is polynomial in |A|\lvert A\rvert. The computation of MM on a given input enc(𝔄)\mathrm{enc}({\mathfrak{A}}) can be represented using functions f:A2k+1(1,1)f:A^{2k+1}\to(-1,1), g:A2k+1(0,1]g:A^{2k+1}\to(0,1], and h1,,hN:Ak{0,1}h_{1},\ldots,h_{N}:A^{k}\to\{0,1\} such that

  1. (a)

    f(s,t)/g(s,t)f(\vec{s},\vec{t})/g(\vec{s},\vec{t}) is the content of register s\vec{s} at time t\vec{t};

  2. (b)

    hi(t)h_{i}(\vec{t}) is 1 if ii is the node label at time t\vec{t}, and 0 otherwise.

Note that s\vec{s} is (k+1)(k+1)-ary because we need to store |A|k|A|^{k} positive and negative register contents. We may assume kk such that registers with index greater than |A|k|A|^{k} do not contribute to the final outcome, i.e., their contents are never shifted to registers associated with the nodes of MM. Construct a formula

ψ(f,g,h):=θpreθinitialθcompθaccept\psi(f,g,h):=\theta_{\textrm{pre}}\wedge\theta_{\textrm{initial}}\wedge\theta_{\textrm{comp}}\wedge\theta_{\textrm{accept}}

of L-ESO[1,1][+,×,,(r)r]\mathrm{L}\text{-}{\rm ESO}_{[-1,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}] such that 𝔄fghψ{\mathfrak{A}}\models\exists fgh\,\psi iff MM accepts enc(𝔄)\mathrm{enc}({\mathfrak{A}}). By Proposition 3.1 we may assume a built-in ordering fin\leq_{\mathrm{fin}} and its induced successor relation SS and constants 0,1,max0,1,\max on the finite domain. Likewise, we may extend fin\leq_{\mathrm{fin}} to order also kk-tuples from the finite domain. Under such ordering we then write x+1\vec{x}+1 (x1\vec{x}-1) for the element succeeding (preceding) a kk-tuple x\vec{x}, and n\vec{n} for the nn-th kk-tuple. First, θpre\theta_{\textrm{pre}} is the conjunction of a formula stating that the ranges of gg and hh are as stated, and another formula

(2) yf(y)2+g(y)=1,\displaystyle\forall\vec{y}\,f(\vec{y})^{2}+g(\vec{y})=1,

where f(y)2f(\vec{y})^{2} is a shorthand for f(y)×f(y)f(\vec{y})\times f(\vec{y}). Observe that (2) implies

f(y)g(y)=f(y)(1f(y)2).\frac{f(\vec{y})}{g(\vec{y})}=\frac{f(\vec{y})}{(1-f(\vec{y})^{2})}.

Also, xx/(1x2)x\mapsto x/(1-x^{2}) is a bijection from (1,1)(-1,1) to \mathbb{R}. That the range of ff is (1,1)(-1,1) will follow from the remaining conjuncts of ψ\psi, described below.

Initial configuration. We give a description of θinitial\theta_{\textrm{initial}} such that

(3) (𝔄,f,g,h)θinitialiff (f,g,h) satisfies (a) & (b) at time 0.({\mathfrak{A}},f,g,\vec{h})\models\theta_{\textrm{initial}}\\ \text{iff $(f,g,\vec{h})$ satisfies (a) \& (b) at time $\vec{0}$}.

For clause (b) it suffices to add to θinitial\theta_{\textrm{initial}}

h1(0)=1h2(0)=0hN(0)=0.h_{1}(\vec{0})=1\wedge h_{2}(\vec{0})=0\wedge\ldots\wedge h_{N}(\vec{0})=0.

Consider then clause (a). We denote by s0\vec{s}_{0} the |Ak+1|/2\lfloor|A^{k+1}|/2\rfloorth k+1k+1-tuple with respect to fin\leq_{\mathrm{fin}}. The sequence s0\vec{s}_{0}, which is clearly definable in ESO{\rm ESO}, now represents the zeroth coordinate of RR_{*}. To encode that |x||x| is placed on zeroth coordinate we add to θinitial\theta_{\textrm{initial}}

(4) ϵfcount(\displaystyle\exists\epsilon\exists f_{\rm count}\Big{(} fcount(0)=ϵ\displaystyle f_{\rm count}(0)=\epsilon
xy(S(x,y)fcount(y)=fcount(x)+ϵ)\displaystyle\land\forall xy\big{(}S(x,y)\to f_{\rm count}(y)=f_{\rm count}(x)+\epsilon\big{)}
fcount(max)=1f(s0,0)=p(1/ϵ)×g(s0,0)),\displaystyle\land f_{\rm count}(\max)=1\land f(\vec{s}_{0},\vec{0})=p(1/\epsilon)\times g(\vec{s}_{0},\vec{0})\Big{)},

where ϵ\epsilon is a nullary function variable (i.e., a real from [1,1][-1,1]), pp is a polynomial such that |enc(𝔄)|=p(|A|)|\mathrm{enc}({\mathfrak{A}})|=p(|A|), and the last conjunct of (4) is a shorthand for

ϵdeg(p)×f(s0,0)=p(ϵ)×g(s0,0),\epsilon^{\deg(p)}\times f(\vec{s}_{0},\vec{0})=p^{*}(\epsilon)\times g(\vec{s}_{0},\vec{0}),

where deg(p)\deg(p) is the degree of the polynomial pp, and pp^{*} is the polynomial obtained by multiplying pp by ϵdeg(p)\epsilon^{\deg(p)} (that is ϵdeg(p)×p(1/ϵ)=p(ϵ)\epsilon^{\deg(p)}\times p(1/\epsilon)=p^{*}(\epsilon)). It follows from (2) and (4) that f(s0,0)(1,1)f(\vec{s}_{0},\vec{0})\in(-1,1) and f(s0,0)/g(s0,0)=|enc(𝔄)|f(\vec{s}_{0},\vec{0})/g(\vec{s}_{0},\vec{0})=|\mathrm{enc}({\mathfrak{A}})|. To encode that |x||x^{\prime}| is placed on the first coordinate we also add to θinitial\theta_{\textrm{initial}} a formula stipulating that f(s0,0)k/g(s0,0)k=f(s0+1,0)/g(s0+1,0)f(\vec{s}_{0},\vec{0})^{k^{*}}/g(\vec{s}_{0},\vec{0})^{k^{*}}=f(\vec{s}_{0}+1,\vec{0})/g(\vec{s}_{0}+1,\vec{0}).

Let fτf^{*}\in\tau be a function symbol and let rfr_{f^{*}} be a natural number that indicates the starting position of the encoding of ff^{*} in enc(𝔄)\mathrm{enc}({\mathfrak{A}}). Clearly rfr_{f^{*}} is a definable real number as it is the value of a fixed univariate polynomial. We use the shorthand s=y+rf\vec{s}=\vec{y}+r_{f^{*}} to denote that in the ordering of kk-tuples (induced from fin\leq_{\mathrm{fin}}) the ordinal number of s\vec{s} is the sum of the ordinal number of y\vec{y} and rfr_{f^{*}}. Clearly s=y+rf\vec{s}=\vec{y}+r_{f^{*}} is expressible in our logic. We then add the following to θinitial\theta_{\textrm{initial}}:

(5) syfτ(s=y+rf(f(s,0)=f(y)×g(s,0)))\forall\vec{s}\vec{y}\bigwedge_{f^{*}\in\tau}\Big{(}\vec{s}=\vec{y}+r_{f^{*}}\rightarrow\big{(}f(\vec{s},\vec{0})=f^{*}(\vec{y})\times g(\vec{s},\vec{0})\big{)}\Big{)}

Note that (2) and (5) imply that f(s,0)(1,1)f(\vec{s},\vec{0})\in(-1,1); for, by (2), |f(s,0)|=1|f(s,0)|=1 leads to g(s,0)=0g(s,0)=0 which contradicts (5). The interpretations of relations in σ\sigma are treated analogously. For all the remaining positions s>s0\vec{s}>\vec{s}_{0} we stipulate that 0f(s,0)g(s,0)0\leq f(\vec{s},\vec{0})\leq g(\vec{s},\vec{0}), and for all positions s<s0\vec{s}<\vec{s}_{0} we stipulate that f(s,0)=0f(\vec{s},\vec{0})=0. In the first case f(s,0)/g(s,0)f(\vec{s},\vec{0})/g(\vec{s},\vec{0}) is some value guessed from the unit interval [0,1][0,1] and in the second case it is 0. We conclude that (3) holds by this construction.

Computation configurations. Then we define θcomp\theta_{\textrm{comp}} such that

(6) (𝔄,f,g,h)θcomp iff (f,g,h) satisfies (a) and (b) at time t>0.({\mathfrak{A}},f,g,\vec{h})\models\theta_{\textrm{comp}}\\ \text{ iff $(f,g,\vec{h})$ satisfies (a) and (b) at time $\vec{t}>\vec{0}$}.

We let

θcomp:=st(\displaystyle\theta_{\textrm{comp}}:=\forall\vec{s}\,\vec{t}\Big{(} 1m<mN(hm(t)=0hm(t)=0)\displaystyle\bigvee_{1\leq m<m^{\prime}\leq N}\big{(}h_{m}(\vec{t})=0\vee h_{m^{\prime}}(\vec{t})=0\big{)}\wedge
1mN(hm(t)=1θm)),\displaystyle\bigvee_{1\leq m\leq N}\big{(}h_{m}(\vec{t})=1\wedge\theta_{m}\big{)}\Big{)},

where each θm\theta_{m} describes the instruction of node mm. Suppose mm is a computation node associated with a mapping gmg_{m} that is the identity on coordinates lil\neq i and on coordinate ii defined as gm(x)i=xj+xkg_{m}(x)_{i}=x_{j}+x_{k}. Let us write fs,tf_{\vec{s},\vec{t}} and gs,tg_{\vec{s},\vec{t}} for f(s,t)f(\vec{s},\vec{t}) and g(s,t)g(\vec{s},\vec{t}), and si,sj,sk\vec{s}_{i},\vec{s}_{j},\vec{s}_{k} for the tuples that correspond to the iith, jjth, and kkth input coordinates. Clearly, these tuples are definable. We define

θm:=\displaystyle\theta_{m}:= hβ(m)(t+1)=1fsi,t+1×gsj,t×gsk,t\displaystyle\,h_{\beta(m)}(\vec{t}+1)=1\wedge f_{\vec{s}_{i},\vec{t}+1}\times g_{\vec{s}_{j},\vec{t}}\times g_{\vec{s}_{k},\vec{t}}
=gsi,t+1×(fsj,t×gsk,t+gsj,t×fsk,t)\displaystyle=g_{\vec{s}_{i},\vec{t}+1}\times(f_{\vec{s}_{j},\vec{t}}\times g_{\vec{s}_{k},\vec{t}}+g_{\vec{s}_{j},\vec{t}}\times f_{\vec{s}_{k},\vec{t}})\wedge
ssi(fs,t+1=fs,tgs,t+1=gs,t).\displaystyle\vec{s}\neq\vec{s}_{i}\to(f_{\vec{s},\vec{t}+1}=f_{\vec{s},\vec{t}}\wedge g_{\vec{s},\vec{t}+1}=g_{\vec{s},\vec{t}}).

The other computation nodes are described analogously. For a shift left node mm we define

θm:=\displaystyle\theta_{m}:= hβ(m)(t+1)=1\displaystyle\,h_{\beta(m)}(\vec{t}+1)=1\,\wedge
s<max(fs,t+1=fs+1,tgs,t+1=gs+1,t),\displaystyle\vec{s}<\vec{\max}\to(f_{\vec{s},\vec{t}+1}=f_{\vec{s}+1,\vec{t}}\wedge g_{\vec{s},\vec{t}+1}=g_{\vec{s}+1,\vec{t}}),

and the case for shift right node is analogous. For a separate branch node mm we define

θm:=\displaystyle\theta_{m}:= ((hβ+(m)(t+1)=1fs0,tϵ+)\displaystyle\,\Big{(}\big{(}h_{\beta^{+}(m)}(\vec{t}+1)=1\wedge f_{\vec{s}_{0},\vec{t}}\geq\epsilon^{+}\big{)}\vee
(hβ(m)(t+1)=1fs0,tϵ))\displaystyle\big{(}h_{\beta^{-}(m)}(\vec{t}+1)=1\wedge f_{\vec{s}_{0},\vec{t}}\leq\epsilon^{-}\big{)}\Big{)}\wedge
fs,t+1=fs,tgs,t+1=gs,t.\displaystyle f_{\vec{s},\vec{t}+1}=f_{\vec{s},\vec{t}}\wedge g_{\vec{s},\vec{t}+1}=g_{\vec{s},\vec{t}}.

Our formulae now imply that (6) follows by the construction. In particular, keeping the values of ff in (1,1)(-1,1) ensures that the arithmetical operations are encoded correctly.

Finally, to express that the value of the characteristic function fMf_{M} is 11 we may stipulate without loss of generality that coordinates 2,1,1-2,-1,1 respectively contain 0,1,10,1,1; we also need to state that the machine is in node NN at the last step:

θaccept:=\displaystyle\theta_{\rm accept}:= hN(max)=1fs0+1,max=gs0+1,max\displaystyle h_{N}(\vec{\max})=1\land f_{\vec{s}_{0}+1,\vec{\max}}=g_{\vec{s}_{0}+1,\vec{\max}}
fs01,max=gs01,maxfs02,max=0.\displaystyle\wedge f_{\vec{s}_{0}-1,\vec{\max}}=g_{\vec{s}_{0}-1,\vec{\max}}\wedge f_{\vec{s}_{0}-2,\vec{\max}}=0.

We conclude that 𝔄fghψ{\mathfrak{A}}\models\exists fg\vec{h}\,\psi iff MM accepts enc(𝔄)\mathrm{enc}({\mathfrak{A}}).

Left-to-right direction. Let ϕL-ESO[0,1][+,×,,]\phi\in\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,\mathbb{R}}] be a sentence over some vocabulary στ\sigma\cup\tau. As in the previous lemma, we may assume that ϕ\phi is of the form

f1fmQ1x1Qnxnψ,\exists f_{1}\ldots\exists f_{m}Q_{1}x_{1}\ldots Q_{n}x_{n}\,\psi,

where ψ\psi is quantifier-free. We may further may transform ϕ\phi to an equivalent form

(7) f1fmgil+1ginxi1xilψ,\exists f_{1}\ldots\exists f_{m}\exists g_{i_{l+1}}\ldots\exists g_{i_{n}}\forall x_{i_{1}}\ldots\forall x_{i_{l}}\,\psi^{\prime},

where gijg_{i_{j}} are Skolem functions on the finite domain and ψ\psi^{\prime} is obtained from ψ\psi by replacing each occurrence of xijx_{i_{j}}, l+1jnl+1\leq j\leq n, with gij(xj)g_{i_{j}}(\vec{x}_{j}). Note that (7) is an intermediate expression which is not anymore in L-ESO[0,1][+,×,,]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,\mathbb{R}}]. We may assume ψ\psi^{\prime} is in disjunctive normal form iICi\bigvee_{i\in I}C_{i}, where II is a finite set of indices.

Suppose the relational and function symbols in στ{f1,,fm}\sigma\cup\tau\cup\{f_{1},\ldots,f_{m}\} are of arity at most nnn^{\prime}\geq n. First, a fixed initial segment of negative coordinates is allocated with the following intention:

  • one coordinate aa for separate branching,

  • three coordinates i,j,ki,j,k for numerical identity atoms,

  • two sequences of coordinates b=(b1,,bn)\vec{b}=(b_{1},\ldots,b_{n}) and c=(c1,,cn)\vec{c}=(c_{1},\ldots,c_{n^{\prime}}) for elements of the finite domain.

We construct a machine MM which runs in polynomial time and accepts (x,x)(x,x^{\prime}) iff

  1. (1)

    x=enc(𝔄)x=\mathrm{enc}({\mathfrak{A}}) where 𝔄{\mathfrak{A}} is a model over στ\sigma\cup\tau, and

  2. (2)

    (x,x)(x,x^{\prime}) is a concatenation of enc((𝔄,f,g))\mathrm{enc}(({\mathfrak{A}},\vec{f},\vec{g})) and indices iaIi_{\vec{a}}\in I such that (𝔄,f,g,a)Cia({\mathfrak{A}},\vec{f},\vec{g},\vec{a})\models C_{i_{\vec{a}}} for each aAl\vec{a}\in A^{l}.

We may suppose that f\vec{f} and (g,(ia)aAl)(\vec{g},(i_{\vec{a}})_{\vec{a}\in A^{l}}) are respectively encoded as strings of reals and integers.

Let pp^{\prime} be a polynomial such that for each 𝔄{\mathfrak{A}} over στ\sigma\cup\tau we have p(|A|)=enc(𝔄)p^{\prime}(|A|)=\mathrm{enc}({\mathfrak{A}}). The machine first checks whether there is a natural number dd such that p(d)=|x|p^{\prime}(d)=|x|. For this, it first sets xi1x_{i}\leftarrow 1 and xax0p(xi)x_{a}\leftarrow x_{0}-p^{\prime}(x_{i}), where initially x0=|x|x_{0}=|x|. If xa=0x_{a}=0, then x0xix_{0}\leftarrow x_{i}, and if xa1x_{a}\geq 1, then xixi+1x_{i}\leftarrow x_{i}+1 and the process is repeated. Otherwise, if xa{0}[1,)x_{a}\notin\{0\}\cup[1,\infty), the input is rejected. This type of branching can be implemented repeating separate branching twice. Provided that the input is not rejected, this process terminates with x0=dx_{0}=d where p(d)=|x|p^{\prime}(d)=|x|. The machine then checks whether item 1 holds; given |𝔄|\lvert{\mathfrak{A}}\rvert this is straightforward. Checking that (x,x)(x,x^{\prime}) is a concatenation of enc((𝔄,f,g))\mathrm{enc}(({\mathfrak{A}},\vec{f},\vec{g})), for some functions f,g\vec{f},\vec{g}, and some indices iai_{\vec{a}} is analogous.

It remains to be checked that the last claim of item 2 holds. We go through all tuples aAl\vec{a}\in A^{l}, calculate the values of the Skolem functions, and check that the disjunct CiaC_{i_{\vec{a}}} holds for the calculated value of the variables. For each a=(a1,,al){0,,d1}l\vec{a}=(a_{1},\ldots,a_{l})\in\{0,\ldots,d-1\}^{l}, placed on the coordinates b1,,blb_{1},\ldots,b_{l}, the machine uses x0x_{0} and c\vec{c} for retrieving and placing gil+1(al+1),,gin(an)g_{i_{l+1}}(\vec{a}_{l+1}),\ldots,g_{i_{n}}(\vec{a}_{n}) on the coordinates bl+1,,bnb_{l+1},\ldots,b_{n}. The machine then retrieves the index iai_{\vec{a}} and checks whether CiaC_{i_{\vec{a}}} holds true with respect to the values on coordinates b\vec{b}. Once this process is completed for all value combinations (a1,,al){0,,d1}l(a_{1},\ldots,a_{l})\in\{0,\ldots,d-1\}^{l} the computation halts with accept.

The contents of the input are accessed using shifts which fix the contents of the allocated coordinates. That is, we use operations σlX\sigma_{l}^{X}, where XX is a finite set of coordinates, such that σlX(x)i=xi\sigma_{l}^{X}(x)_{i}=x_{i} if iXi\in X, and otherwise σlX(x)i=xj\sigma_{l}^{X}(x)_{i}=x_{j} where j=min{kk>i,kX}j=\min\{k\in\mathbb{N}\mid k>i,k\notin X\}. For instance, σl{0}\sigma_{l}^{\{0\}} is obtained by first swapping x0x_{0} and x1x_{1} and then shifting left.

Also, if CiaC_{i_{\vec{a}}} contains a numerical atom f(t0)g(t1)×h(t2)f(\vec{t}_{0})\leq g(\vec{t}_{1})\times h(\vec{t}_{2}), then the values of its constituent function terms with respect to b\vec{b} are placed on coordinates i,j,ki,j,k. The machine then sets xaxixj×xkx_{a}\leftarrow x_{i}-x_{j}\times x_{k}, and if xa0x_{a}\leq 0, then it continues to the next atom in CiaC_{i_{\vec{a}}}, and else it rejects. If CiaC_{i_{\vec{a}}} contains a relational atom R(x0)R(\vec{x}_{0}), then the value of its characteristic function with respect to b\vec{b} is placed on coordinate aa. If xa=1x_{a}=1, then the machine moves to the next atom in CiaC_{i_{\vec{a}}}, and else it rejects. Negated relational atoms are treated analogously, and the stated branching is straightforward to implement with separate branch nodes.

It follows from our construction that MM runs in polynomial time and accepts (x,x)(x,x^{\prime}) iff items 1 and 2 hold. Hence, we conclude that L-ESO[0,1][+,×,,(r)r]S-𝖭𝖯[0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\leq\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}. ∎

Suppose we above consider (i) guesses from \mathbb{R} instead of [0,1][0,1], or (ii) BSS instead of S-BSS machines. Then slightly modified proofs yield (i) L-ESO[+,×,,(r)r]S-𝖭𝖯\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv\mathrm{S}\textrm{-}\mathsf{NP}_{\mathbb{R}}, and (ii) ESO[0,1][+,×,,(r)r]𝖭𝖯[0,1]{\rm ESO}_{[0,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv\mathsf{NP}_{[0,1]}. Furthermore, logical constants r{0,1}r\in\mathbb{R}\setminus\{0,1\} are only needed to capture cc in constant assignment and ϵ+,ϵ\epsilon^{+},\epsilon^{-} in separate branching, and for the converse direction only those machine constants r{0,1}r\in\mathbb{R}\setminus\{0,1\} which explicitly occur in the logical expression are needed. Thus we obtain the following corollary.

Corollary 3.4.
  1. (1)

    L-ESO[+,×,,(r)r]S-𝖭𝖯\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv\mathrm{S}\textrm{-}\mathsf{NP}_{\mathbb{R}},

  2. (2)

    L-ESO[+,×,,0,1]S-𝖭𝖯0\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}]\equiv\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{\mathbb{R}},

  3. (3)

    L-ESO[0,1][+,×,,0,1]S-𝖭𝖯[0,1]0\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,0,1}]\equiv\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]},

  4. (4)

    ESO[0,1][+,×,,(r)r]𝖭𝖯[0,1]{\rm ESO}_{[0,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv\mathsf{NP}_{[0,1]},

  5. (5)

    ESO[0,1][+,×,,0,1]𝖭𝖯[0,1]0{\rm ESO}_{[0,1]}[{+,\times,\leq,0,1}]\equiv\mathsf{NP}_{[0,1]}^{0}.

In the following two sections we investigate how S-BSS computability relates to BSS computability, and in particular how S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} relates to 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. On the one hand it turns out that S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} is strictly weaker than 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. On the other hand both obvious strengthenings of S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}, namely S-𝖭𝖯\mathrm{S}\textrm{-}\mathsf{NP}_{\mathbb{R}} and 𝖭𝖯[0,1]\mathsf{NP}_{[0,1]}, collapse to 𝖭𝖯\mathsf{NP}_{\mathbb{R}}.

4. Characterisation of S-BSS decidable languages

We give a characterisation of languages decidable by S-BSS machines using the ideas from the previous section. The goal of this section is to establish the following theorem:

Theorem 4.1.

Every language that can be decided by a) a deterministic S-BSS machine, or b) a [0,1][0,1]-nondeterministic S-BSS machine in time tt, for some function t:t\colon\mathbb{N}\rightarrow\mathbb{N}, is a countable disjoint union of closed sets in the usual topology of n\mathbb{R}^{n}.

The result complements an analogous characterisation of BSS-decidable languages thus giving insight on the difference of the computational powers of BSS machines and S-BSS machines.

Theorem 4.2 ((Blum et al., 1997, Theorem 1)).

Every language decidable by a (deterministic) BSS machine is a countable disjoint union of semi-algebraic sets.

These characterisations are based on the fact that the computation of BSS and S-BSS machines can be encoded by formulae of first-order real arithmetic.

Existential theory of the real arithmetic.

Formulae of the existential real arithmetic are given by the grammar

(8) ϕ::=iii<iϕϕϕϕxϕ,\phi::=i\leq i\mid i<i\mid\phi\wedge\phi\mid\phi\vee\phi\mid\exists x\phi,

where ii stands for numerical terms given by the grammar

i::=01xi×ii+i,i::=0\mid 1\mid x\mid i\times i\mid i+i,

where xx is a first-order variable. The semantics is defined over a fixed structure (,+,×,,0,1)(\mathbb{R},+,\times,\leq,0,1) of real arithmetic in the usual way. Relations definable by such formulae with additional real constants are called semi-algebraic.

Let MM be an S-BSS machine and n,tn,t\in\mathbb{N} positive natural numbers. We denote by Ltn(M)L^{n}_{t}(M) (Ltn(M)L^{n}_{\leq t}(M), resp.) the set of strings sns\in\mathbb{R}^{n} accepted by MM in time exactly (at most, resp.) tt, and define Ln(M):=L(M)nL^{n}(M):=L(M)\cap\mathbb{R}^{n}. The following restricted fragment of FO\exists{\rm FO} is enough to encode S-BSS computations.

Existential theory of the loose [0,1][0,1]-guarded real arithmetic.

Formulae of the existential loose [0,1][0,1]-guarded real arithmetic are defined as in (8), but without i<ii<i and replacing xϕ\exists x\phi with x(0x1ϕ)\exists x(0\leq x\leq 1\wedge\phi).

Lemma 4.3.

Given a deterministic or [0,1][0,1]-nondeterminis-tic S-BSS machine MM and positive n,tn,t\in\mathbb{N} it is possible to construct, in polynomial time, formulas ϕ\phi and ψ\psi of loose [0,1][0,1]-guarded real arithmetic, with free variables x1,,xnx_{1},\dots,x_{n}, that may use real constants used in MM such that

{(s(x1),,s(xn))(,+,×,,(r)r)\displaystyle\{\big{(}s(x_{1}),\dots,s(x_{n})\big{)}\mid(\mathbb{R},+,\times,\leq,(r)_{r\in\mathbb{R}}) sϕ}=Lnt(M),\displaystyle\models_{s}\phi\}=L^{n}_{t}(M),
{(s(x1),,s(xn))(,+,×,,(r)r)\displaystyle\{\big{(}s(x_{1}),\dots,s(x_{n})\big{)}\mid(\mathbb{R},+,\times,\leq,(r)_{r\in\mathbb{R}}) sψ}=Lnt(M).\displaystyle\models_{s}\psi\}=L^{n}_{\leq t}(M).
Proof.

For a given input of length nn, the computation of MM consists of tt many configurations c1,ct\vec{c}_{1},\dots\vec{c}_{t} of MM, where c1\vec{c}_{1} and ct\vec{c}_{t} are the initial configuration and a terminal configuration, respectively, and, for 1m<t1\leq m<t, cm+1\vec{c}_{m+1} is a successor configuration of cm\vec{c}_{m}. Each configuration is a string of real numbers of length 𝒪(t)\mathcal{O}(t). We can use a similar technique as in the right-to-left direction of Theorem 3.3 and encode the contents of registers by pairs of real numbers from the unit interval [0,1][0,1]. In order to encode the computation, it suffices to encode the values of 𝒪(t2)\mathcal{O}(t^{2}) registers; thus 𝒪(t2)\mathcal{O}(t^{2}) variables suffice. We then construct a formula of existential loose [0,1][0,1]-guarded real arithmetic of size 𝒪(t2)\mathcal{O}(t^{2}) that first existentially quantifies 𝒪(t2)\mathcal{O}(t^{2})-many variables in order to guess the whole computation of MM on the given input and then expresses, using perhaps at most polynomially many extra variables, that the computation is correct and accepting. We omit further details, for the encoding is done in a similar manner as in the right-to-left direction of Theorem 3.3. ∎

Given a deterministic S-BSS machine MM, it is easy to see that the sets Ltn(M)L^{n}_{t}(M), for n,tn,t\in\mathbb{N}, are disjoint. However, the same does not need to hold for nondeterministic machines, for the time it takes to accept an input string xx might depend on the guessed value for the string xx^{\prime} (and there may be multiple accepting runs with different values for xx^{\prime}). This problem can be evaded for languages LL that can be decided by a [0,1][0,1]-nondeterministic S-BSS machine NN in time ff, for some function f:f\colon\mathbb{N}\rightarrow\mathbb{N}. In this case Ln(N)=Lf(n)n(N)L^{n}(N)=L^{n}_{\leq f(n)}(N), for each nn\in\mathbb{N}. Now since L(M)=n,tLtn(M)L(M)=\bigcup_{n,t\in\mathbb{N}}L^{n}_{t}(M) and L(N)=nLn(N)L(N)=\bigcup_{n\in\mathbb{N}}L^{n}(N) where the unions are disjoint, we obtain the following characterisation.

Theorem 4.4.

Every language decidable by a) a deterministic S-BSS machine or b) a [0,1][0,1]-nondeterministic S-BSS machine in time tt, for some t:t\colon\mathbb{N}\rightarrow\mathbb{N}, is a countable disjoint union of relations defined by existential loose [0,1][0,1]-guarded real arithmetic formulae that may use real constants from some finite set.

The rest of this section is dedicated on proving the following theorem, which together with Theorem 4.4 implies Theorem 4.1.

Theorem 4.5.

Every relation defined by some existential loose [0,1][0,1]-guarded real arithmetic formula ϕ(x1,,xn)\phi(x_{1},...,x_{n}) with real constants is closed in n\mathbb{R}^{n}.

Point-set topology.

The proof of the theorem relies on some rudimentary notions and knowledge from point-set topology summarised in the following two lemmas (for basics of point-set topology see, e.g., the monograph (Willard, 2004)). In order to simplify the notation, for a topological space XX, we use XX to denote also the underlying set of the space. Likewise, in this section, we let [0, 1] denote the topological space that has domain [0, 1] and the metric of Euclidean distance.

Lemma 4.6.

Let XX and YY be topological spaces, f:XYf\colon X\rightarrow Y a continuous function, AA and BB closed sets in XX, and CC a closed set in YY. Then

  • XX, ABA\cap B, ABA\cup B, and f1[C]f^{-1}[C] are closed in XX,

  • the product A×CA\times C is closed in the product space X×YX\times Y,

  • if YAY\supseteq A is a subspace of XX then AA is closed in YY.

Lemma 4.7.

Let XX be a topological space, YY a compact topological space, AA a closed set in the product space X×YX\times Y, and ff the projection function X×YXX\times Y\rightarrow X. Then the image f[A]f[A] of AA is closed in XX.

Proof of Theorem 4.5.

We prove the following claim by induction on the structure of the formulae: Let x\vec{x} be a kk-tuple of distinct variables and ϕ(x)\phi(\vec{x}) an existential loose [0,1][0,1]-guarded real arithmetic formula with real constants, and its free variables in x\vec{x}. The relation defined by ϕ(x)\phi(\vec{x}) is closed in k\mathbb{R}^{k}.

  • Assume ϕ=t1t2\phi=t_{1}\leq t_{2}. Recall that t1(x)t_{1}(\vec{x}) and t2(x)t_{2}(\vec{x}) are multivariate polynomials. Define g(x)g(\vec{x}) as the multivariate polynomial t1(x)t2(x)t_{1}(\vec{x})-t_{2}(\vec{x}) and consider the preimage g1[(,0]]g^{-1}[(-\infty,0]]. Since (,0](-\infty,0] is closed in \mathbb{R} and g:kg\colon\mathbb{R}^{k}\rightarrow\mathbb{R} is a continuous function, it follows that g1[(,0]]g^{-1}[(\infty,0]] is closed. Clearly g1[(,0]]g^{-1}[(-\infty,0]] is the relation defined by ϕ(x)\phi(\vec{x}).

  • The cases of disjunctions and conjunctions are clear, for the union and intersection of closed sets is closed.

  • Assume ϕ=y(0y1ψ(x,y))\phi=\exists y(0\leq y\leq 1\wedge\psi(\vec{x},y)). Let RψR_{\psi} be the relation defined by ψ(x,y)\psi(\vec{x},y), which by induction hypothesis is closed in k+1\mathbb{R}^{k+1}. Define Rψ:=Rψ(k×[0,1])R^{\prime}_{\psi}:=R_{\psi}\cap(\mathbb{R}^{k}\times[0,1]). Since [0,1][0,1] is closed in \mathbb{R}, it follows from Lemma 4.6 that RψR^{\prime}_{\psi} is closed both in k+1\mathbb{R}^{k+1} and k×[0,1]\mathbb{R}^{k}\times[0,1]. Let RψR^{*}_{\psi} be the projection of RψR^{\prime}_{\psi} to its kk first columns. Since RψR^{\prime}_{\psi} is closed in k×[0,1]\mathbb{R}^{k}\times[0,1], and [0,1][0,1] is a compact topological space, it follows from Lemma 4.7 that RψR^{*}_{\psi} is closed in k\mathbb{R}^{k}. Clearly RψR^{*}_{\psi} is the relation defined by ψ(x)\psi(\vec{x}).∎

5. Hierarchy of the complexity classes

The main result of this section is the separation of the complexity classes S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} and 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. We have already done most of the work required for the separation as the result follows directly from the topological argument of Section 4.5 that more generally separates S-BSS computations from BSS computations. The characterisations of Section 3 then yield the separation of the related logics on \mathbb{R}-structures. We also give logical proofs implying that the obvious strengthenings of S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} coincide with 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. Finally we study the restriction of S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]} on Boolean inputs and establish that it coincides with a natural fragment of \exists\mathbb{R}.

5.1. Separation of S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} and 𝖭𝖯\mathsf{NP}_{\mathbb{R}}

We can now use Theorem 4.5 to prove the following:

Theorem 5.1.

The following separations hold:

  1. (1)

    S-𝖭𝖯[0,1]0<𝖭𝖯0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}<\mathsf{NP}^{0}_{\mathbb{R}} and S-𝖭𝖯[0,1]<𝖭𝖯\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}<\mathsf{NP}_{\mathbb{R}},

  2. (2)

    L-ESO[0,1][+,×,,0,1]<ESO[+,×,,0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,0,1}]<{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}],

  3. (3)

    L-ESO[0,1][+,×,,(rr)]<ESO[+,×,,(r)r]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,\leq,(r_{r\in\mathbb{R}})}]<{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r_{\in}\mathbb{R}}}].

Proof.

We prove 1. by showing that there are languages in 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}} that are not in S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]}. The claims 2. and 3. then follow from the logical characterisations of Corollary 3.4.

Let LL be a language in S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} and MM an S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} S-BSS machine such that L(M)=LL(M)=L. Let pp be a polynomial function that bounds the running time of MM. Fix nn\in\mathbb{N}. Now Ln=Lp(n)nL^{n}=L^{n}_{\leq p(n)}. By Lemma 4.3 Lp(n)nL^{n}_{\leq p(n)}, and hence LnL^{n}, is definable by an existential loose [0,1][0,1]-guarded real arithmetic formula ϕ(x1,,xn)\phi(x_{1},...,x_{n}) that uses real constants from MM. By Theorem 4.5 LnL^{n} is a closed set in the product space n\mathbb{R}^{n}, which is not true for all languages in 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}; for instance, a language PP consisting of all finite strings of positive reals can be decided in 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}} (using branching), but PnP^{n} is not closed in n\mathbb{R}^{n}. ∎

5.2. Robustness of 𝖭𝖯\mathsf{NP}_{\mathbb{R}}

We have just seen that S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} is a complexity class strictly below 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. We now give purely logical proofs implying that the obvious strengthenings of S-𝖭𝖯[0,1]\mathrm{S}\textrm{-}\mathsf{NP}_{[0,1]} collapse to 𝖭𝖯\mathsf{NP}_{\mathbb{R}}. The proofs are based on the logical characterisations established in Corollary 3.4.

The first obvious question is: Are S-𝖭𝖯\mathrm{S}\textrm{-}\mathsf{NP}_{\mathbb{R}} and S-𝖭𝖯0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{\mathbb{R}} strictly below 𝖭𝖯\mathsf{NP}_{\mathbb{R}} and 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}? In logical terms this boils down to the expressivity of the logic L-ESO[+,×,,(r)r]\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]. We answer to this question in the negative.

Proposition 5.2.

L-ESO[+,×,,0,1]ESO[+,×,]\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}]\equiv{\rm ESO}_{\mathbb{R}}[{+,\times,\leq}] and L-ESO[+,×,,(r)r]ESO[+,×,,(r)r]\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}].

Proof.

The left-to-right direction is immediate as the constants 0 and 11 are definable in ESO[+,×,]{\rm ESO}_{\mathbb{R}}[{+,\times,\leq}]. For the converse direction, note that the numerical atom ¬ij\neg i\leq j is equivalent to the statement j<ij<i. We show that << is definable in L-ESO[+,×,,0,1]\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}]. First note that every strictly positive real number rr\in\mathbb{R} can be expressed by a ratio of two real numbers n,mn,m\in\mathbb{R} such that n,m1n,m\geq 1. Moreover note that, for every such nn and mm, the ratio n/m>0n/m>0. It is easy to see that the following L-ESO[+,×,,0,1]\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}]-formula

rnm(1n1mn=r×mi+r=j),\exists r\exists n\exists m(1\leq n\land 1\leq m\land n=r\times m\land i+r=j),

where rr, nn, and mm are 0-ary function variables, expresses that i<ji<j. ∎

Theorem 2.4, Proposition 5.2, Corollary 3.4 together then yield the following:

Corollary 5.3.

S-𝖭𝖯=𝖭𝖯\mathrm{S}\textrm{-}\mathsf{NP}_{\mathbb{R}}=\mathsf{NP}_{\mathbb{R}} and S-𝖭𝖯0=𝖭𝖯0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{\mathbb{R}}=\mathsf{NP}^{0}_{\mathbb{R}}.

The second natural question is: Are 𝖭𝖯[0,1]\mathsf{NP}_{[0,1]} and 𝖭𝖯[0,1]0\mathsf{NP}^{0}_{[0,1]} strictly below 𝖭𝖯\mathsf{NP}_{\mathbb{R}} and 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}}? Again, the answer is no. The proof of the following proposition follows directly from the observation that arbitrary real numbers can be encoded as ratios x/(1x)x/(1-x), where x[0,1]x\in[0,1], using an additional marker for sign. It is crucial to note that with negated numerical atoms one can express that the denominators of such encodings are positive; in the loose fragment this is not possible. The encodings needed can be clearly expressed in ESO[0,1][+,×,]{\rm ESO}_{[0,1]}[{+,\times,\leq}]. We omit the proof.

Proposition 5.4.

ESO[0,1][+,×,,0,1]ESO[+,×,,0,1]{\rm ESO}_{[0,1]}[{+,\times,\leq,0,1}]\equiv{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}] and ESO[0,1][+,×,,(r)r]ESO[+,×,,(r)r]{\rm ESO}_{[0,1]}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}]\equiv{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,(r)_{r\in\mathbb{R}}}].

Hence Corollary 3.4 yields the following:

Corollary 5.5.

𝖭𝖯[0,1]=𝖭𝖯\mathsf{NP}_{[0,1]}=\mathsf{NP}_{\mathbb{R}} and 𝖭𝖯[0,1]0=𝖭𝖯0\mathsf{NP}^{0}_{[0,1]}=\mathsf{NP}^{0}_{\mathbb{R}}.

Finally we consider a weakening of L-ESO[+,×,,0,1]\mathrm{L}\text{-}{\rm ESO}_{\mathbb{R}}[{+,\times,\leq,0,1}] by removing the constant 11 from the language. It turns out that this small weakening has profound implications to the expressivity of the logic when restricted to function-free vocabularies.

Proposition 5.6.

Let 0S0\in S\subseteq\mathbb{R}. Then L-ESOS[+,×,]FO\mathrm{L}\text{-}{\rm ESO}_{S}[{+,\times,\leq}]\equiv{\rm FO} with respect to \mathbb{R}-structures on function-free vocabularies.

Proof.

The direction FOL-ESOS[+,×,]{\rm FO}\leq\mathrm{L}\text{-}{\rm ESO}_{S}[{+,\times,\leq}] is self-evident. We give a proof for the converse. Let 𝔄{\mathfrak{A}} be an \mathbb{R}-structure of a function-free vocabulary τ\tau, ϕL-ESOS[+,×,][τ]\phi\in\mathrm{L}\text{-}{\rm ESO}_{S}[{+,\times,\leq}][\tau] a formula, and ss an assignment for the first-order variables. Note that ϕ\phi can be regarded also as a formula of L-ESO{0}[+,×,]\mathrm{L}\text{-}{\rm ESO}_{\{0\}}[{+,\times,\leq}]; we write ϕ0\phi_{0} to denote this interpretation. Let ϕ\phi_{\top} denote the FO{\rm FO}-formula obtained from ϕ\phi by removing the function quantifications in ϕ\phi and replacing every numerical atom iji\leq j in ϕ\phi with the formula xx=x\exists x\,x=x. Now note that there is a homomorphism from the first-order structure (S,+,×,)(S,+,\times,\leq) to ({0},+,×,)(\{0\},+,\times,\leq), and consequently, 𝔄sφ𝔄sφ0.{\mathfrak{A}}\models_{s}\varphi\Leftrightarrow{\mathfrak{A}}\models_{s}\varphi_{0}. Here we note that φ0\varphi_{0} implies φ\varphi since the second structure is a substructure of the first, and truth of existential formulae is preserved to extensions. Conversely, φ\varphi implies φ0\varphi_{0} because atoms iji\leq j appear only positively, and the truth of formulae with only positive literals are preserved to homomorphic images. Since in the evaluation of ϕ0\phi_{0} every numerical term is evaluated to 0 it follows that 𝔄sϕ0𝔄sϕ.{\mathfrak{A}}\models_{s}\phi_{0}\Leftrightarrow{\mathfrak{A}}\models_{s}\phi_{\top}.

5.3. Separate branching on Boolean inputs and the existential theory of the reals

It is known that on Boolean inputs 𝖭𝖯0\mathsf{NP}^{0}_{\mathbb{R}} coincides with the complexity class \exists\mathbb{R} (i.e., the class of problems polynomially reducible to the existential theory of the reals) (Bürgisser and Cucker, 2006; Schaefer and Stefankovic, 2017). In this section we show an analogous result for S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}.

Definition 5.7.

Define [0,1]\exists[0,1]^{\leq} to be the set of all languages L{0,1}L\subseteq\{0,1\}^{*} for which there is a polynomial-time reduction ff from {0,1}\{0,1\}^{*} into sentences of existential loose [0,1][0,1]-guarded real arithmetic such that xLx\in L iff (,+,×,,0,1)f(x)(\mathbb{R},+,\times,\leq,\allowbreak 0,1)\models f(x).

We show the following theorem:

Theorem 5.8.

[0,1]=BP(S-𝖭𝖯[0,1]0)\exists[0,1]^{\leq}=\mathrm{BP}(\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}).

Proof.

Note that the right-to-left direction of this theorem follows immediately from Lemma 4.3 by noting that the only real constants used by S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]} S-BSS machines MM are 0 and 11, and that the Boolean inputs to MM can be defined in [0,1]\exists[0,1]^{\leq} by using the constants 0 and 11.

Left-to-right. There exists a deterministic polynomial time Turing machine MM that given an input string computes the corresponding sentence ϕ\phi of existential loose [0,1][0,1]-guarded real arithmetic. Let pp be the polynomial that bounds the running time of MM. Without loss of generality we may assume that, for any given input ii of length nn, the formula computed by MM from input ii uses only variables x1,,xp(n)x_{1},\dots,x_{p(n)}. Let MM^{*} be a nondeterministic S-BSS machine that, for a given input ii of length nn, first guesses p(n)p(n) many real numbers from the unit interval [0,1][0,1] (these will correspond to the values of the variables x1,,xp(n)x_{1},\dots,x_{p(n)}). Then MM^{*} simulates the run of the deterministic polynomial time Turing machine MM on input ii. Let ϕ\phi be the formula computed this way. Finally we can use MM^{*} to check the matrix of ϕ\phi using the values guessed for the variables x1,,xp(n)x_{1},\dots,x_{p(n)}. We omit further details, for the evaluation of the matrix can done essentially in the same way as in the left-to-right direction of Theorem 3.3. ∎

6. Probabilistic team semantics

The purpose of this section is to characterise the descriptive complexity of probabilistic independence logic (Durand et al., 2018b). The formulae of this logic, and other logics that make use of dependency concepts involving quantities, are interpreted in probabilistic team semantics which generalises team semantics by adding weights on variable assignments. A finite model together with a probabilistic team can then be seen as a particular metafinite structure, and thus a natural approach to computational complexity comes from BSS machines.

Let DD be a finite set of first-order variables, AA a finite set, and XX a finite set of assignments (i.e., a team) from DD to AA. A probabilistic team 𝕏\mathbb{X} is then defined as a function

𝕏:X[0,1]\mathbb{X}\colon X\rightarrow[0,1]

such that sX𝕏(s)=1\sum_{s\in X}\mathbb{X}(s)=1. Also the empty function is considered a probabilistic team. We call DD and AA the variable domain and value domain of 𝕏\mathbb{X}, respectively.

Probabilistic independence logic (FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c})) is defined as the extension of first-order logic with probabilistic independence atoms yxz\vec{y}~{}\!\!\perp\!\!\!\perp_{\vec{x}}\!\!~{}\vec{z} whose semantics is the standard semantics of conditional independence in probability distributions. Another probabilistic logic, FO(){\rm FO}(\approx), is obtained by extending first-order logic with marginal identity atoms xy\vec{x}\approx\vec{y} which state that the marginal distributions on x\vec{x} and y\vec{y} are identically distributed. The semantics for complex formulae are defined compositionally by generalising the team semantics of dependence logic to probabilistic teams. For details, not necessary in this paper, we refer the reader to (Durand et al., 2018b). In principle, the point is that formulae of probabilistic independence logic define properties of (𝔄,𝕏)({\mathfrak{A}},\mathbb{X}) where 𝔄\mathfrak{A} is a finite model and 𝕏\mathbb{X} a probabilistic team with value domain Dom(𝔄)\operatorname{Dom}({\mathfrak{A}}).

Example 6.1.

Suppose we flip a coin. If we get heads, we roll two dice xx and yy. If we get tails, we roll only xx and copy the same value for yy. Repeating this procedure infinitely many times yields at the limit a probabilistic team (i.e., a joint probability distribution) over variables xx and yy satisfying

(xyx=y)zxz.(x~{}\!\!\perp\!\!\!\perp\!\!~{}y\vee x=y)\wedge\forall z\,x\approx z.

By definition ϕψ\phi\vee\psi is true for a probabilistic team 𝕏\mathbb{X} if 𝕏\mathbb{X} is a mixture of two teams with respective properties ϕ\phi and ψ\psi (here independence and (row-wise) identity between xx and yy). By definition zϕ\forall z\phi is true for a probabilistic team 𝕏\mathbb{X} if the extension of 𝕏\mathbb{X} with a uniform distribution for zz has the property ϕ\phi (here identity between marginal distributions on xx and zz).

We will now show that the descriptive complexity of probabilistic independence logic is exactly S-𝖭𝖯[0,1]0\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}. For this we need some background definitions and results.

Expressivity comparisons wrt. probabilistic team semantics

Fix a relational vocabulary τ\tau. For a probabilistic team 𝕏\mathbb{X} with variable domain {x1,,xn}\{x_{1},\ldots,x_{n}\} and value domain AA, the function f𝕏:An[0,1]f_{\mathbb{X}}:A^{n}\to[0,1] is defined as the probability distribution such that f𝕏(s(x))=𝕏(s)f_{\mathbb{X}}(s(\vec{x}))=\mathbb{X}(s) for all sXs\in X. For a formula ϕFO(c)\phi\in{\rm FO}(\perp\!\!\!\perp_{\rm c}) of vocabulary τ\tau and with free variables {x1,,xn}\{x_{1},\ldots,x_{n}\}, the class Struc(ϕ)\mathrm{Struc}(\phi) is defined as the class of \mathbb{R}-structures 𝔄\mathfrak{A} over τ{f}\tau\cup\{f\} such that (𝔄τ)𝕏ϕ(\mathfrak{A}\upharpoonright\tau)\models_{\mathbb{X}}\phi, where f𝕏=f𝔄f_{\mathbb{X}}=f^{\mathfrak{A}} and 𝔄τ\mathfrak{A}\upharpoonright\tau is the finite τ\tau-structure underlying 𝔄\mathfrak{A}.

Let \mathcal{L} be any of the logics defined in Section 2. We write FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c})\leq\mathcal{L} if for every formula ϕFO(c)\phi\in{\rm FO}(\perp\!\!\!\perp_{\rm c}) of vocabulary τ\tau there is a sentence ψ\psi\in\mathcal{L} of vocabulary τ{f}\tau\cup\{f\} such that Struc(ϕ)=Strucd[0,1](ψ)\mathrm{Struc}(\phi)=\mathrm{Struc}^{d[0,1]}(\psi). Vice versa, we write FO(c)\mathcal{L}\leq{\rm FO}(\perp\!\!\!\perp_{\rm c}) if for every sentence ψ\psi\in\mathcal{L} of vocabulary τ{f}\tau\cup\{f\} there is a formula ϕFO(c)\phi\in{\rm FO}(\perp\!\!\!\perp_{\rm c}) of vocabulary τ\tau such that Struc(ϕ)=Strucd[0,1](ψ)\mathrm{Struc}(\phi)=\mathrm{Struc}^{d[0,1]}(\psi).

Complexity characterisations wrt. probabilistic team semantics.

Let FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c}) be a logic with vocabulary τ\tau and 𝒞\mathcal{C} a complexity class. Let 𝒮\mathcal{S} be an arbitrary class of \mathbb{R}-structures over τ{f}\tau\cup\{f\} that is closed under isomorphisms and where the interpretations of ff are distributions. We write enc(𝒮)\mathrm{enc}(\mathcal{S}) for the set of encodings of structures in 𝒮\mathcal{S}. Consider the following two conditions:

  1. (i)

    enc(𝒮)={enc(𝔄)𝔄Struc(ϕ)}\mathrm{enc}(\mathcal{S})=\{\mathrm{enc}(\mathfrak{A})\mid\mathfrak{A}\in\mathrm{Struc}(\phi)\} for some ϕFO(c)}\phi\in{{\rm FO}(\perp\!\!\!\perp_{\rm c})}\}.

  2. (ii)

    enc(𝒮)𝒞\mathrm{enc}(\mathcal{S})\in\mathcal{C}.

If (i)(i) implies (ii)(ii), we write FO(c)𝒞{\rm FO}(\perp\!\!\!\perp_{\rm c})\leq\mathcal{C}, and if the vice versa holds, we write 𝒞FO(c)\mathcal{C}\leq{\rm FO}(\perp\!\!\!\perp_{\rm c}).

It is already known that probabilistic independence logic captures a variant of loose existential second-order logic in which function quantification ranges over distributions. This result was shown in two stages. First, it was proven in (Durand et al., 2018b) that the logic FO(c,){\rm FO}(\perp\!\!\!\perp_{\rm c},\approx) is expressively equivalent to L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}].222In (Durand et al., 2018b) equi-expressivity with ESOd[0,1][SUM,×,=]{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}] is erroneously stated; the results in the paper actually entail equi-expressivity with L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]. Later, it was proven in (Hannula et al., 2019) that marginal identity can be expressed using independence, that is, FO(c,){\rm FO}(\perp\!\!\!\perp_{\rm c},\approx) is expressively equivalent to FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c}).333In fact, FO(c){\rm FO}(\perp\!\!\!\perp_{\rm c}) is expressively equivalent to FO(){\rm FO}(\perp\!\!\!\perp) which is the extension of first-order logic with marginal independence atoms xy\vec{x}~{}\!\!\perp\!\!\!\perp\!\!~{}\vec{y}, the semantics of which is the standard semantics of marginal independence in probability distributions (Hannula et al., 2019).

Theorem 6.2 ((Durand et al., 2018b; Hannula et al., 2019)).

FO(c)L-ESOd[0,1][SUM,×,=]{\rm FO}(\perp\!\!\!\perp_{\rm c})\equiv\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}].

We will now improve this result by removing the condition that restricts function quantification to distributions. For this we utilize a normal form lemma from (Durand et al., 2018b). Observe that we restrict attention to d[0,1]d[0,1]-structures, that is, all function symbols from the underlying vocabulary are interpreted as distributions.

Lemma 6.3 ((Durand et al., 2018b)).

For every L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]-formula ϕ\phi there is an L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]-formula ϕ\phi^{*} such that Strucd[0,1]ϕ=Strucd[0,1]ϕ\mathrm{Struc}^{d[0,1]}{\phi}=\mathrm{Struc}^{d[0,1]}{\phi^{*}}, where ϕ\phi^{*} is of the form fxθ\exists\vec{f}\forall\vec{x}\theta, where θ\theta is quantifier-free and such that its second sort identity atoms are of the form fi(u,v)=fj(u)×fk(v)f_{i}(\vec{u},\vec{v})=f_{j}(\vec{u})\times f_{k}(\vec{v}) or fi(u)=SUMvfj(u,v)f_{i}(\vec{u})=\mathrm{SUM}_{\vec{v}}f_{j}(\vec{u},\vec{v}) for distinct fi,fj,fkf_{i},f_{j},f_{k} such that at most one of them is not quantified.

Lemma 6.4.

L-ESOd[0,1][SUM,×,=]d[0,1]L-ESOd[0,1][+,×,=]d[0,1]L-ESO[0,1][+,×,=,0,1]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]\\ \equiv_{d[0,1]}\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{+,\times,=}]\equiv_{d[0,1]}\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,=,0,1}].

Proof.

We prove the claim in three steps, without relying on multiplication at any step. By Proposition 3.1 we may assume that the finite domain is enriched with a successor function SS for tuples, its transitive derivatives <,<,\leq, and its minimal and maximal tuples min\vec{\min} and max\vec{\max} (of an appropriate arity), obtained by the lexicographic ordering induced from some linear ordering fin\leq_{\mathrm{fin}}. Additionally, we may assume a constant cc on the finite domain.

Step 1: L-ESOd[0,1][SUM,×,=]d[0,1]L-ESOd[0,1][+,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]\leq_{d[0,1]}\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{+,\times,=}]. We may assume that any L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}] formula is of the form stated in Lemma 6.3. Thus it suffices to express in L-ESOd[0,1][+,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{+,\times,=}] each numerical identity of the form f(u)=SUMxf(u,x)f(\vec{u})=\mathrm{SUM}_{\vec{x}}f^{\prime}(\vec{u},\vec{x}). First, we quantify a 2m2m-ary distribution variable gg upon which we impose:

(9) xy[\displaystyle\forall\vec{x}\vec{y}\big{[} g(x,min)+g(x,min)=f(u,x)\displaystyle g(\vec{x},\vec{\min})+g(\vec{x},\vec{\min})=f^{\prime}(\vec{u},\vec{x})\wedge
(y<max\displaystyle\big{(}\vec{y}<\vec{\max}\to
g(S(y),S(y))+g(S(y),S(y))=g(S(y),y)+g(y,y))\displaystyle g(S(\vec{y}),S(\vec{y}))+g(S(\vec{y}),S(\vec{y}))=g(S(\vec{y}),\vec{y})+g(\vec{y},\vec{y})\big{)}\wedge
(S(y)<x\displaystyle\big{(}S(\vec{y})<\vec{x}\to
g(x,S(y))+g(x,S(y))=g(x,y))].\displaystyle g(\vec{x},S(\vec{y}))+g(\vec{x},S(\vec{y}))=g(\vec{x},\vec{y})\big{)}\big{]}.

The point is to calculate partial sums SUMxyf(u,x)\mathrm{SUM}_{\vec{x}\leq y}f^{\prime}(\vec{u},\vec{x}) and store sufficiently small fractions of them in g(y,y)g(\vec{y},\vec{y}). Suppose y\vec{y} is the nnth tuple. Then

g(y,y)=12n(f(u,min)++f(u,y)),g(\vec{y},\vec{y})=\frac{1}{2^{n}}(f^{\prime}(\vec{u},\vec{\min})+\ldots+f^{\prime}(\vec{u},\vec{y})),

and for x>y\vec{x}>\vec{y},

g(x,y)=12nf(u,x).g(\vec{x},\vec{y})=\frac{1}{2^{n}}f^{\prime}(\vec{u},\vec{x}).

Consequently, the sum of all g(x,y)g(\vec{x},\vec{y}) where xy\vec{x}\geq\vec{y} is at most 11. By allocating the remaining weights to (x,y)(\vec{x},\vec{y}) such that x<y\vec{x}<\vec{y}, it follows that gg is a distribution.

Furthermore, we quantify a 2m2m-ary distribution variable hh satisfying:

x\displaystyle\forall\vec{x} [h(min)+h(min)=f(u)\displaystyle[h(\vec{\min})+h(\vec{\min})=f(\vec{u})\wedge
x<maxh(S(x))+h(S(x))=h(x)].\displaystyle\vec{x}<\vec{\max}\to h(S(\vec{x}))+h(S(\vec{x}))=h(\vec{x})].

It follows that h(y)=12nf(u)h(\vec{y})=\frac{1}{2^{n}}f(\vec{u}). Consequently, g(max,max)=h(max)g(\vec{\max},\vec{\max})=h(\vec{\max}) if and only if f(u)=SUMxf(u,x)f(\vec{u})=\mathrm{SUM}_{\vec{x}}f^{\prime}(\vec{u},\vec{x}). Note that hh is not a distribution since the weights do not add up to 11. However, we may increment the arity of hh by one and replace h(x)h(\vec{x}) above with h(x,c)h(\vec{x},c). Then hh is a distribution if the remaining weights are pushed to h(x,y)h(\vec{x},y), where ycy\neq c. This concludes the proof of Step 1.

Step 2: We show a stronger claim: L-ESOd[0,1][+,×,=]L-ESO[0,1][+,×,=,0,1]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{+,\times,=}]\leq\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,=,0,1}]. For this, it suffices to show how to express in L-ESO[0,1][+,=,0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,=,0,1}] that a function ff is a distribution. The following formula expresses just that:

g(\displaystyle\exists g\big{(} g(min)=f(min)\displaystyle g(\vec{\min})=f(\vec{\min})\wedge
x(x<maxg(S(x))=g(x)+f(S(x)))g(max)=1).\displaystyle\forall\vec{x}(\vec{x}<\vec{\max}\to g(S(\vec{x}))=g(\vec{x})+f(S(\vec{x})))\wedge g(\vec{\max})=1\big{)}.

Step 3: We show a stronger claim: L-ESO[0,1][+,×,=,0,1][0,1]L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,=,0,1}]\\ \leq_{[0,1]}\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]. Suppose ϕ\phi is some formula in L-ESO[0,1][+,×,=,0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,=,0,1}]. Let kk be the maximal arity of any function variable/symbol appearing in ϕ\phi, and suppose nn is the size of the finite domain; the total sum of the weights of a function is thus at most nkn^{k}. We now show how to obtain from ϕ\phi an equivalent formula in L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}]; the idea is to scale all function weights by 1/nk1/n^{k}. We have two cases:

Function variables. If ff is an mm-ary quantified function variable, we replace it with an (m+1)(m+1)-ary quantified distribution variable dfd_{f} satisfying

xdyd(y,c)=df(x,c),\forall\vec{x}\exists d^{\prime}\forall\vec{y}\,d^{\prime}(\vec{y},c)=d_{f}(\vec{x},c),

where dd^{\prime} is a (k+1)(k+1)-ary distribution variable. Now nkdf(x,c)1n^{k}d_{f}(\vec{x},c)\leq 1 because dd^{\prime} is a distribution, and thus df(x,c)1nkd_{f}(\vec{x},c)\leq\frac{1}{n^{k}}.

Function symbols. Suppose f(x)f(\vec{x}) is a function term which appears as a term or subterm in ϕ\phi, and ff is a function symbol from the underlying vocabulary. We quantify a (k+1)(k+1)-ary distribution variable df(x)d_{f(\vec{x})} satisfying

x(SUMydf(x)(y,c)=f(x)yzdf(x)(y,c)=df(x)(z,c)).\forall\vec{x}(\mathrm{SUM}_{\vec{y}}d_{f(\vec{x})}(\vec{y},c)=f(\vec{x})\wedge\forall\vec{y}\vec{z}d_{f(\vec{x})}(\vec{y},c)=d_{f(\vec{x})}(\vec{z},c)).

It follows that df(x)(x,c)=1nkf(x)d_{f(\vec{x})}(\vec{x},c)=\frac{1}{n^{k}}f(\vec{x}). Since f(x)1f(\vec{x})\leq 1, we may define df(x)d_{f(\vec{x})} as a distribution.

Observe now that each numerical atom appearing in ϕ\phi is an identity between two multivariate polynomials over function terms. Without loss of generality all the constituent monomials in these atoms are of a fixed degree DD and have coefficient one; note that each monomial with degree less than DD can be appended in L-ESO[0,1][+,×,=,0,1]\mathrm{L}\text{-}{\rm ESO}_{[0,1]}[{+,\times,=,0,1}] with a quantified nullary function nn taking value 11. We now replace in each numerical atom i=ji=j function terms f(x)f(\vec{x}) with df(x,c)d_{f}(\vec{x},c) or df(x)(x,c)d_{f(\vec{x})}(\vec{x},c), depending on whether ff is a function variable or a function symbol. Thus we represent i=ji=j in L-ESOd[0,1][SUM,×,=]\mathrm{L}\text{-}{\rm ESO}_{d[0,1]}[{\mathrm{SUM},\times,=}] as inDk=jnDk\frac{i}{n^{Dk}}=\frac{j}{n^{Dk}}, wherefore not only its truth value, but also that of ϕ\phi, is preserved in the transformation. ∎

By combining Corollary 3.4.3, Theorem 6.2, and Lemma 6.4, we finally obtain the following result.

Theorem 6.5.

FO(c)S-𝖭𝖯[0,1]0{\rm FO}(\perp\!\!\!\perp_{\rm c})\equiv\mathrm{S}\textrm{-}\mathsf{NP}^{0}_{[0,1]}.

7. Concluding remarks

Applications of logic in AI and advanced data management require probabilistic interpretations, a role that is well fulfilled by probabilistic team semantics. On the other hand, in the theory of computation and automated reasoning, computation and logics over the reals are well established with solid foundations. In this paper we have provided bridges between the two worlds. We introduced a novel variant of BSS machines and provided a logical and topological characterisation of its computational power. In addition, we determined the expressivity of probabilistic independence logic with respect to the BSS model of computation.

There are many interesting directions of future research. One is to consider the additive fragment of BSS computation. Restricted to Boolean inputs it is known that, if unrestricted use of machine constants is allowed, the additive 𝖭𝖯\mathsf{NP}_{\mathbb{R}} branching on equality collapses to 𝖭𝖯\mathsf{NP} and branching on inequality captures 𝖭𝖯/poly\mathsf{NP}/poly (Koiran, 1994). What can we say about the additive fragment of S-BSS computation? Another direction is to devise logics that characterise other important complexity classes over S-BSS machines. Grädel and Meer (Grädel and Meer, 1995) established a characterisation of polynomial time on ranked \mathbb{R}-structures using a variant of least fixed point logic. In the setting of team semantics and classical computation, Galliani and Hella (Galliani and Hella, 2013) showed that the so-called inclusion logic characterises polynomial time on ordered structures. Can we extend the applicability of these results to the realms of S-BSS computation and probabilistic team semantics? Finally, we would like to devise natural complete problems for the complexity classes defined by S-BSS machines. In particular, we would like to obtain a natural complete problem for [0,1]\exists[0,1]^{\leq}; a weakening of the art gallery problem is one promising candidate. We conclude with a few open problems:

  • Is [0,1]\exists[0,1]^{\leq} strictly included in \exists\mathbb{R}? A positive answer would be a major breakthrough, as it would separate 𝖭𝖯\mathsf{NP} from 𝖯𝖲𝖯𝖠𝖢𝖤\mathsf{PSPACE}.

  • We know that 𝖭𝖯[0,1]𝖯𝖲𝖯𝖠𝖢𝖤\mathsf{NP}\leq\exists[0,1]^{\leq}\leq\exists\mathbb{R}\leq\mathsf{PSPACE}. Can we establish a better upper bound for [0,1]\exists[0,1]^{\leq}? In particular, is [0,1]\exists[0,1]^{\leq} contained in the polynomial hierarchy?

  • We established that S-BSS computable languages are included in the class of BSS computable languages that are countable disjoint unions of closed sets. Does the converse hold?

Acknowledgements.
The first and the second author were supported by the Academy of Finland grant 308712. The third and the fourth author were supported by the Research Foundation Flanders grant G0G6516N. The third author was partially supported by the National Natural Science Foundation of China under grant 61972455, and the fourth author was an international research fellow of the Japan Society for the Promotion of Science, Postdoctoral Fellowships for Research in Japan (Standard).

References

  • (1)
  • Abrahamsen et al. (2018) Mikkel Abrahamsen, Anna Adamaszek, and Tillmann Miltzow. 2018. The art gallery problem is \exists \mathbb{R}-complete. In Proceedings of the 50th Annual ACM SIGACT Symposium on Theory of Computing, STOC 2018, Los Angeles, CA, USA, June 25-29, 2018. 65–73. https://doi.org/10.1145/3188745.3188868
  • Benedikt et al. (2003) Michael Benedikt, Martin Grohe, Leonid Libkin, and Luc Segoufin. 2003. Reachability and connectivity queries in constraint databases. J. Comput. System Sci. 66, 1 (2003), 169 – 206. https://doi.org/10.1016/S0022-0000(02)00034-X Special Issue on PODS 2000.
  • Blum et al. (1997) Lenore Blum, Felipe Cucker, Michael Shub, and Steve Smale. 1997. Complexity and Real Computation. Springer-Verlag, Berlin, Heidelberg.
  • Blum et al. (1989) Lenore Blum, Mike Shub, and Steve Smale. 1989. On a theory of computation and complexity over the real numbers: NPNP- completeness, recursive functions and universal machines. Bull. Amer. Math. Soc. (N.S.) 21, 1 (07 1989), 1–46. https://projecteuclid.org:443/euclid.bams/1183555121
  • Bürgisser and Cucker (2006) Peter Bürgisser and Felipe Cucker. 2006. Counting complexity classes for numeric computations II: Algebraic and semialgebraic sets. J. Complexity 22, 2 (2006), 147–191. https://doi.org/10.1016/j.jco.2005.11.001
  • Canny (1988) John F. Canny. 1988. Some Algebraic and Geometric Computations in PSPACE. In Proceedings of the 20th Annual ACM Symposium on Theory of Computing, May 2-4, 1988, Chicago, Illinois, USA. 460–467. https://doi.org/10.1145/62212.62257
  • Corander et al. (2019) Jukka Corander, Antti Hyttinen, Juha Kontinen, Johan Pensar, and Jouko Väänänen. 2019. A logical approach to context-specific independence. Ann. Pure Appl. Logic 170, 9 (2019), 975–992. https://doi.org/10.1016/j.apal.2019.04.004
  • Cucker and Meer (1999) Felipe Cucker and Klaus Meer. 1999. Logics Which Capture Complexity Classes Over The Reals. J. Symb. Log. 64, 1 (1999), 363–390. https://doi.org/10.2307/2586770
  • Durand et al. (2018a) Arnaud Durand, Miika Hannula, Juha Kontinen, Arne Meier, and Jonni Virtema. 2018a. Approximation and dependence via multiteam semantics. Ann. Math. Artif. Intell. 83, 3-4 (2018), 297–320. https://doi.org/10.1007/s10472-017-9568-4
  • Durand et al. (2018b) Arnaud Durand, Miika Hannula, Juha Kontinen, Arne Meier, and Jonni Virtema. 2018b. Probabilistic Team Semantics. In Foundations of Information and Knowledge Systems - 10th International Symposium, FoIKS 2018, Budapest, Hungary, May 14-18, 2018, Proceedings. 186–206. https://doi.org/10.1007/978-3-319-90050-6_11
  • Galliani (2008) Pietro Galliani. 2008. Game Values and Equilibria for Undetermined Sentences of Dependence Logic. (2008). MSc Thesis. ILLC Publications, MoL–2008–08.
  • Galliani and Hella (2013) Pietro Galliani and Lauri Hella. 2013. Inclusion Logic and Fixed Point Logic. In Computer Science Logic 2013 (CSL 2013) (Leibniz International Proceedings in Informatics (LIPIcs)), Simona Ronchi Della Rocca (Ed.), Vol. 23. Schloss Dagstuhl–Leibniz-Zentrum fuer Informatik, Dagstuhl, Germany, 281–295. https://doi.org/10.4230/LIPIcs.CSL.2013.281
  • Grädel and Gurevich (1998) Erich Grädel and Yuri Gurevich. 1998. Metafinite Model Theory. Inf. Comput. 140, 1 (1998), 26–81. https://doi.org/10.1006/inco.1997.2675
  • Grädel and Kreutzer (1999) Erich Grädel and Stephan Kreutzer. 1999. Descriptive Complexity Theory for Constraint Databases. In Computer Science Logic, 13th International Workshop, CSL ’99, 8th Annual Conference of the EACSL, Madrid, Spain, September 20-25, 1999, Proceedings. 67–81. https://doi.org/10.1007/3-540-48168-0_6
  • Grädel and Meer (1995) Erich Grädel and Klaus Meer. 1995. Descriptive complexity theory over the real numbers. In Proceedings of the Twenty-Seventh Annual ACM Symposium on Theory of Computing, 29 May-1 June 1995, Las Vegas, Nevada, USA. 315–324. https://doi.org/10.1145/225058.225151
  • Hannula et al. (2019) Miika Hannula, Åsa Hirvonen, Juha Kontinen, Vadim Kulikov, and Jonni Virtema. 2019. Facets of Distribution Identities in Probabilistic Team Semantics. In JELIA (Lecture Notes in Computer Science), Vol. 11468. Springer, 304–320.
  • Hannula and Kontinen (2016) Miika Hannula and Juha Kontinen. 2016. A finite axiomatization of conditional independence and inclusion dependencies. Inf. Comput. 249 (2016), 121–137. https://doi.org/10.1016/j.ic.2016.04.001
  • Hansen and Meer (2006) Uffe Flarup Hansen and Klaus Meer. 2006. Two logical hierarchies of optimization problems over the real numbers. Math. Log. Q. 52, 1 (2006), 37–50. https://doi.org/10.1002/malq.200510021
  • Hyttinen et al. (2017) Tapani Hyttinen, Gianluca Paolini, and Jouko Väänänen. 2017. A Logic for Arguing About Probabilities in Measure Teams. Arch. Math. Logic 56, 5-6 (2017), 475–489. https://doi.org/10.1007/s00153-017-0535-x
  • Kanellakis et al. (1995) Paris C. Kanellakis, Gabriel M. Kuper, and Peter Z. Revesz. 1995. Constraint Query Languages. J. Comput. Syst. Sci. 51, 1 (1995), 26–52. https://doi.org/10.1006/jcss.1995.1051
  • Koiran (1994) Pascal Koiran. 1994. Computing over the Reals with Addition and Order. Theor. Comput. Sci. 133, 1 (1994), 35–47. https://doi.org/10.1016/0304-3975(93)00063-B
  • Krebs et al. (2018) Andreas Krebs, Arne Meier, Jonni Virtema, and Martin Zimmermann. 2018. Team Semantics for the Specification and Verification of Hyperproperties. In MFCS (LIPIcs), Vol. 117. Schloss Dagstuhl - Leibniz-Zentrum fuer Informatik, 10:1–10:16.
  • Kreutzer (2000) Stephan Kreutzer. 2000. Fixed-Point Query Languages for Linear Constraint Databases. In Proceedings of the Nineteenth ACM SIGMOD-SIGACT-SIGART Symposium on Principles of Database Systems, May 15-17, 2000, Dallas, Texas, USA. 116–125. https://doi.org/10.1145/335168.335214
  • Meer (2000) Klaus Meer. 2000. Counting problems over the reals. Theor. Comput. Sci. 242, 1-2 (2000), 41–58. https://doi.org/10.1016/S0304-3975(98)00190-X
  • Schaefer (2009) Marcus Schaefer. 2009. Complexity of Some Geometric and Topological Problems. In Graph Drawing, 17th International Symposium, GD 2009, Chicago, IL, USA, September 22-25, 2009. Revised Papers. 334–344. https://doi.org/10.1007/978-3-642-11805-0_32
  • Schaefer and Stefankovic (2017) Marcus Schaefer and Daniel Stefankovic. 2017. Fixed Points, Nash Equilibria, and the Existential Theory of the Reals. Theory Comput. Syst. 60, 2 (2017), 172–193. https://doi.org/10.1007/s00224-015-9662-0
  • Väänänen (2007) Jouko Väänänen. 2007. Dependence Logic. Cambridge University Press.
  • Willard (2004) S. Willard. 2004. General Topology. Dover Publications. https://books.google.co.jp/books?id=-o8xJQ7Ag2cC