Abstract 1 Introduction 2 Preliminaries 3 The Two-Variable Sub-fragment 4 More Than Two Variables 5 Counting With Reversed Relations 6 Discussion References Appendix A Preliminaries Appendix B Counting With Reversed Relations Appendix C Discussion

On Homogeneous Models of Fluted Languages

Daumantas Kojelis ORCID Department of Computer Science, University of Manchester, UK
Abstract

We study the fluted fragment of first-order logic which is often viewed as a multi-variable non-guarded extension to various systems of description logics lacking role-inverses. In this paper we show that satisfiable fluted sentences (even under reasonable extensions) admit special kinds of “nice” models which we call globally/locally homogeneous. Homogeneous models allow us to simplify methods for analysing fluted logics with counting quantifiers and establish a novel result for the decidability of the (finite) satisfiability problem for the fluted fragment with periodic counting. More specifically, we will show that the (finite) satisfiability problem for the language is Tower-complete. If only two variable are used, computational complexity drops to NExpTime-completeness. We supplement our findings by showing that generalisations of fluted logics, such as the adjacent fragment, have finite and general satisfiability problems which are, respectively, Σ10- and Π10-complete. Additionally, satisfiability becomes Σ11-complete if periodic counting quantifiers are permitted.

Keywords and phrases:
Fluted Fragment, Fluted Logic, Fluted Fragment with Periodic Counting, Adjacent Fragment, Adjacent Fragment with Counting, Adjacent Fragment with Periodic Counting, Counting Quantifiers, Periodic Counting Quantifiers, Decidable Fragments of First-Order Logic
Copyright and License:
[Uncaptioned image] © Daumantas Kojelis; licensed under Creative Commons License CC-BY 4.0
2012 ACM Subject Classification:
Theory of computation Complexity theory and logic
Acknowledgements:
The author would like to thank Dr. Ian Pratt-Hartmann and Dr. Bartosz Jan Bednarczyk for their valuable feedback.
Funding:
This work is supported by the NCN grant 2018/31/B/ST6/03662.
Editors:
Jörg Endrullis and Sylvain Schmitz

1 Introduction

The fluted fragment (denoted ) is a fragment of first-order logic in which, roughly put, variables appear in predicates following the order in which they were quantified. For illustrative purposes, we translate the sentence “Every conductor nominates their favorite soloist to play at every concert” into this language as follows:

x1(cond(x1)x2(solo(x2)fav(x1,x2)x3(conc(x3)nom(x1,x2,x3)))). (1)

As a non-example, the sentences axiomatising transitivity, symmetry and reflexivity of a relation are not in the fluted fragment.

The fluted fragment is a member of argument-sequence logics – a family of decidable (in terms of satisfiability) fragments of first-order logic which also includes the ordered [11, 13], forward [2] and adjacent [4] fragments. The fluted fragment in particular is decidable in terms of satisfiability even in the presence of counting quantifiers [19] or a distinguished transitive relation [22]. Surprisingly, the satisfiability problem for under a combination of the two not only retains decidability but also has the finite model property [24]. We refer the reader to [23] for a survey.

In this paper we will mostly be concerned with what we call the fluted fragment with periodic counting (denoted 𝒫𝒞). We remark that periodic counting quantifiers generalise standard (threshold) counting quantifiers which have been an object of intensive study as an extension for the fluted fragment in the past few years [19, 24]. Under this new formalism, we are allowed to write formulas requesting an even number of existential witnesses. As an example, we can express sentences as “Every orchestra hires an even number of people to play first violin” in our language (see (2)).

The origins of flutedness trace back to the works of W. V. Quine [26]. It is, however, the definition given by W. C. Purdy (in [25]) that has become widespread and will be the one we use. The popularity of Purdy’s idea of flutedness is not without cause, at least when keeping the field of description logics in mind. Indeed, after a routine translation, formulas of the description logic 𝒜𝒞 are contained in the two-variable sub-fragment of 𝒫𝒞. This is even the case when 𝒜𝒞 is augmented with role hierarchies, nominals and/or cardinality restrictions (possibly with modulo operations). We refer the reader to [12] for more details. In terms of expressive power, 𝒫𝒞 closely parallels 𝒜𝒞𝒮𝒞𝒞 – a new formalism with counting constrains expressible in quantifier-free Boolean algebra with Presburger arithmetic (see [16, 1]). Thus, noting that the guarded fragment with at least three variables becomes undecidable under counting extensions [8], and that the guarded fluted fragment has “nice” model theoretic properties such as Craig interpolation [3], fluted languages emerge as perfect candidates for generalising description logics in a multi-variable context.

Table 1: Complexity of finite (left-hand side of “/”) and general (right-hand side of “/”) satisfiability problems for languages (in the top row) under quantifier extensions (on the left-most column). All complexity classes are in regard to time. 𝒞-c (𝒞-h) stands for complete (hard). Here k4 and 3.
2 𝒜3 𝒜k
standard NExp-c [9] (2)-NExp [21] NExp-c [4] (k2)-NExp [4]
counting NExp-c [18] (1)-NExp [19] Σ10-c/Δ10 Th 11/claim Σ10-c/Π10-c Th 11/15
periodic NExp-c Th 5 (1)-NExp Th 9 Σ10-c/Σ10-h Th 11 Σ10-c/Σ11-c Th 11/15

In Sections 3 and 4 we establish that classes of models of satisfiable 𝒫𝒞-sentences always contain a “nice” structure in which elements behave (in a sense that we will make clear) homogeneously. Utilising this behaviour we will show that the fluted fragment extended with periodic counting quantifiers has a decidable satisfiability problem. Intriguingly, even though periodic counting quantifiers generalise standard counting quantifiers, our methodology allows us to avoid Presburger quantification, which was required to establish decidability of satisfiability for with standard counting [19].

In section 5 we show that the satisfiability problems for the fluted fragment with counting extensions become undecidable when minimal syntactic relaxations are allowed. More precisely, the section will culminate with a result showing that the finite satisfiability problem for the 3-variable adjacent fragment with counting is Σ10-complete. Additionally, the general satisfiability problem will be shown to be Π10-complete when 4 variables are used, and Σ11-complete if periodic counting is allowed. Denoting the adjacent fragment as 𝒜, we provide a brief survey of complexity and undecidability standings in Table 1.

The work in this paper is closely related to [6] in which decidability of satisfiability is established for the two-variable fragment with periodic counting (denoted 𝒪Pres2) but without a sharp complexity-theoretic bound. Our homogeneity conditions, which stem from lack of inverse relations in fluted logics, allow us to establish NExpTime-completeness for both the finite and general satisfiability problems of 𝒫𝒞2.

2 Preliminaries

We use to denote the set of integers {0,1,2,}, and to denote along with the first infinite cardinal; i.e. ={0}. By picking some n,p we write n+p for the linear set {n+ipi}. In the extended integers , the cardinal 0 is the maximum element under the canonical ordering “<” and

  • 00=00=0;

  • n+0=0+n=0 for all n; and

  • n0=0n=0 for all n{0}.

A linear Diophantine inequation is an expression of the form a1v1++anvn+bc1v1++cnvn+d, where (ai)i=1n,b,(ci)i=1n,d are constant values taken form , v¯=v1,vn is a vector of variables, and “” is any of the relations “=,,,<,,>” (each interpreted as one would assume). It is known that when the cardinal 0 is disallowed, a solution for a set of such inequations may be found in NPTime [17]. The picture does not change when 0 is permitted as a solution and/or constant. Indeed, we may reduce the problem of finding a solution over to that of finding it over as follows. First guess which variables should be mapped to 0 and which should have a finite value. Then, check that each inequation featuring a variable assigned 0 holds and discard them. What will be left is a system of inequations with constants in and in variables assumed to be finite. See [20, Ch 7.4] for greater detail. We will allow systems of inequations to contain disjunctions.

By a word a¯An we mean a tuple a¯=a1an, where aiA for each i, 1in. In case n=1, we often write a instead of a¯. By a¯1 we mean the reversal of a¯; i.e. a¯1=ana1. If a¯ and b¯ are words we write a¯b¯ for the concatenation of the two. We use the terms “tuple” and “word” interchangeably.

Now, take some structure 𝔄 and an i-tuple a¯ of elements from A. Suppose B={bA𝔄,a¯bφ} for some first-order formula φ(x1,,xi+1). Fixing n,p we extend the syntax of first-order logic with (threshold) counting quantifiers [n] and periodic counting quantifier [n+p]. Semantically, 𝔄,a¯[n]xi+1φ if and only if |B|n. Similarly, 𝔄,a¯[n+p]xi+1φ if and only if |B|n+p. We refrain from further generalisation to ultimately periodic counting quantifier [n1+p1nk+pk] (as in [6]) as they can be expressed as a disjunction of formulas using periodic counting quantifiers [n1+p1]xi+1φ[nk+pk]xi+1φ. Thus, a sentence such as “Every orchestra hires an even number of people to play first violin” may be written in a language with periodic counting:

x1(orch(x1)[0+2]x2(pers(x2)x3(1st_viol(x3)hires_to_play(x1,x2,x3)))). (2)

Formally, the fluted fragment with periodic counting is the union of sets of formulas 𝒫𝒞[] defined by simultaneous induction as follows:

  1. (i)

    any atom r(xk,,x), where xk,,x is a contiguous subsequence of x1,x2, and r is a predicate of arity k+1, is in 𝒫𝒞[];

  2. (ii)

    𝒫𝒞[] is closed under Boolean combinations;

  3. (iii)

    if φ𝒫𝒞[+1], then [n+p]x+1φ is in 𝒫𝒞[] for every n,p.

We write 𝒫𝒞=0𝒫𝒞[] for the set of all fluted formulas with periodic counting and define the -variable fluted fragment with periodic counting to be the set 𝒫𝒞:=𝒫𝒞𝒪. (Here 𝒪 is the set of first-order formulas that do not use more than variables). We will implicitly restrict attention to signatures σ{=} which feature no function and/or constant symbols, and where “=” is always interpreted as the canonical equality relation. Lastly, we use xφ interchangeably with [0+0]x¬φ whenever convenient.

Variables in fluted logics convey no meaningful information. Indeed, since the arity of every predicate in σ{=} is fixed and each atom features a suffix of the variable quantification order, we may employ what we call variable-free notation. As an example, formulas (1) and (2) may be (respectively) written as

(cond(solofav(concnom))), (3)
(orch[0+2](person(1st_violhires_to_play))) (4)

without ambiguity (up to a shift of variable indices). Writing for x1x, we will employ variable-free notation extensively throughout subsequent sections.

Fix a first-order formula φ with periodic counting quantifiers. We assume that numeric values are encoded in binary and write φ for the number of symbols used in φ. We point out that the signature of φ (which we write as sig(φ) for brevity) is no larger than φ.

Now, let φ be a formula in 𝒫𝒞+1. We say that φ is in normal-form if it takes the following shape

rR(αr[nr+pr]γr)tT(βt¬[nt+pt]δt), (5)

where R,T are sets of indices, each αr,βt is a quantifier-free formula in variables, each γr,δt is a quantifier-free formula in +1 variables, and each nr+pr,nt+pt is a linear set. Using standard rewriting techniques we prove the following in Appendix A.

Lemma 1.

Suppose φ is an 𝒫𝒞+1-sentence. Then, we may compute, in polynomial time, an equisatisfiable normal-form 𝒫𝒞+1-sentence ψ.

Notice that the negation before the periodic counting quantifier in the second conjunct of (5) is not moved-inwards. This is done deliberately so as to avoid computing complements of linear sets, which may be of exponential size as a function of φ.

Now, let 𝔄 be a structure over a finite signature σ{=}. We say that an atom is (+1)-fluted if it features a suffix of x1,,x+1 as arguments. The fluted atomic (+1)-type τ of ab¯cA+1 (denoted 𝖿𝗍𝗉+1𝔄(ab¯c)) is then the set of (+1)-fluted (possibly negated) atoms over σ{=} with arity no greater than +1 that are satisfied by ab¯c in 𝔄. We invite the reader to view the tuple ab¯ as emitting τ, and b¯c as absorbing τ. Write τ[2,+1] for the fluted -type π obtained by deleting entries in τ of arity greater than and decrementing variable indices by 1. We say that a fluted -type π is an endpoint of a fluted (+1)-type τ if τ[2,+1]=π. We define 𝖥𝖳𝖯+1σ to be the set of all fluted (+1)-types over σ{=}.

The fluted -profile of ab¯A (denoted 𝖿𝗉𝗋𝔄(ab¯)) is a function ρ mapping τ𝖥𝖳𝖯+1σ to the number of times ab¯ emits τ. Formally, ρ(τ)=|{cA𝖿𝗍𝗉i+1𝔄(ab¯c)=τ}|. If φ is a quantifier-free 𝒫𝒞+1-formula, we write ρ[n+p]φ just in case τ𝖥𝖳𝖯+1στφρ(τ)n+p. Clearly, ρ[n+p]φ if and only if 𝔄,ab¯[n+p]φ.

In the sequel we will assume that all structures are countable. This comes with no loss of generality as 𝒫𝒞 is subsumed by the countable fragment of infinitary logic ω1,ω; a language for which the downward Löwenheim-Skolem Theorem holds (folklore, see [15, p. 69]). Note that, in 𝒫𝒞, the finite model property fails as ¬[0+1] is an axiom of infinity.

3 The Two-Variable Sub-fragment

In this section we restrict attention to the two-variable fluted fragment with periodic counting. To achieve decidability of (finite) satisfiability we first specify what kind of “nice” models we will be looking for. Take any σ-structure 𝔄 and π𝖥𝖳𝖯1σ. For convenience, we write Aπ for the set of all elements aA with 𝖿𝗍𝗉𝔄(a)=π. We say that π is globally homogeneous in 𝔄 if 𝖿𝗉𝗋𝔄(a)=𝖿𝗉𝗋𝔄(b) for each a,bAπ. That is to say, π is globally homogeneous in 𝔄 if, for each τ𝖥𝖳𝖯2σ, the number of fluted 2-types τ emitted is the same for each element in Aπ. The structure 𝔄 is globally homogeneous if each π𝖥𝖳𝖯1σ is globally homogeneous in 𝔄.

For the remainder of the section fix some normal-form 𝒫𝒞2-sentence φ. We claim that if φ is a satisfiable, then it is satisfiable in a globally homogeneous model. To see this, take some structure 𝔄φ and a pair of elements cdA2 that realised the fluted 2-type τ in 𝔄. Since τ consists of fluted formulas, it does not feature atoms of the form p(x1) and p(x2,x1). Referencing τ only, we lack information to deduce what formulas are satisfied by the pair dc in 𝔄. On the other hand, 𝔄,cdψ if and only if τψ for each quantifier-free 𝒫𝒞2-formula ψ. Thus, if we were to in any way alter the fluted 2-type of dc in 𝔄, the set of quantifier-free 𝒫𝒞2-formulas satisfied by cd in 𝔄 would not change.

Taking a step back, take any π𝖥𝖳𝖯1σ and recall that AπA is the set of all elements realising the 1-type π in 𝔄. We redefine 2-types emitted by elements of Aπ in 𝔄 in such a way that makes π globally homogeneous in the rewiring of 𝔄. Let us fix any aAπ and write ρ=𝖿𝗉𝗋𝔄(a). The element a and profile ρ picked will serve as an “example” of how the rest of Aπ should form fluted 2-types with other elements of the model. Taking any bAπ{a} and cA{a,b} we see that it is impossible to prohibit b from emitting the fluted 2-type 𝖿𝗍𝗉𝔄(ac) to c via any normal-form 𝒫𝒞2-formula. We thus allow b to impersonate a in 𝔄 by rewiring the fluted 2-type 𝖿𝗍𝗉𝔄(bc) to be 𝖿𝗍𝗉𝔄(ac) for each cA{a,b} and, additionally, by resetting 𝖿𝗍𝗉𝔄(ba) to be the 2-type 𝖿𝗍𝗉𝔄(ab) and 𝖿𝗍𝗉𝔄(bb) to be 𝖿𝗍𝗉𝔄(aa). Clearly, only fluted 2-types emitted by b were reconsidered in this procedure, thus pairs in (A{b})×A satisfy the same quantifier-free 𝒫𝒞2-formulas as before. To see that 𝔄 still models φ we need only show that b does not violate αr[nr+pr]γr and βt¬[nt+pt]δt for each rR and tT. By our rewiring procedure, we have that 𝖿𝗉𝗋𝔄(a)=ρ=𝖿𝗉𝗋𝔄(b). Thus,

𝔄,a[n+p]ψρ[n+p]ψ𝔄,b[n+p]ψfor quantifier-free ψ𝒫𝒞2.

Having already argued that 𝔄,aαr[nr+pr]γr and 𝔄,aβt¬[nt+pt]δt for each rR and tT we therefore conclude that 𝔄φ.

Since the only 2-types redefined are those emitted by b, we can run this construction in parallel for each element in Aπ{a}. Clearly, this renders π globally homogeneous in the rewired model. Since elements in AAπ are left untouched by our rewiring, we can repeat this procedure for each π𝖥𝖳𝖯1σ thus proving the following:

Lemma 2.

Suppose φ is a satisfiable normal-form 𝒫𝒞2-sentence. Then, φ is satisfiable in a globally homogeneous model.

In globally homogeneous structures elements realising the same fluted 1-type are, in a sense, stripped away of their individuality as they all realise the same fluted 1-profile. When the globally homogeneous structure 𝔄 is clear from context, we can unambiguously write ρπ for the fluted 1-profile realised by each element of Aπ (for π𝖥𝖳𝖯1σ).

When considering the (finite) satisfiability problem for normal-form 𝒫𝒞2-sentences such as φ, we will confine ourselves to the search of globally homogeneous models. More precisely, we will produce a system of linear Diophantine inequations Ψ that has a solution over if and only if φ is satisfiable in a globally homogeneous model. For this purpose, let (xπ)π𝖥𝖳𝖯1σ, (yπ,τ)π𝖥𝖳𝖯1στ𝖥𝖳𝖯2σ, (iπ,r)π𝖥𝖳𝖯1σrR, and (jπ,t)π𝖥𝖳𝖯1σtT be sequences of variables. Intuitively, the value assigned to xπ will represent the number of elements realising the fluted 1-type π; yπ,τ – the number times the 2-type τ is emitted by an element realising π; and with iπ,r and jπ,t acting as periodic counters for elements realising π when considering linear sets nr+pr and nt+pt. To be more precise, when given a satisfying assignment for Ψ, we will build a globally homogeneous 𝔄φ with

|Aπ|=xπ and ρπ(τ)=yπ,τ for each π𝖥𝖳𝖯1σ and τ𝖥𝖳𝖯2σ. (6)

On the other hand, we will have that any globally homogeneous model 𝔄φ gives rise to a solution of Ψ with the following assignments for all π𝖥𝖳𝖯1σ, τ𝖥𝖳𝖯2σ, rR and tT:111 In case pr (resp. pt) is 0, we allow iπ,r (resp. jπ,t) to take any integer value.

xπ:=|Aπ|;yπ,τ:=ρπ(τ);iπ,r:=(τ𝖥𝖳𝖯2στγrρπ(τ)nr)/pr;jπ,t:=(τ𝖥𝖳𝖯2στδtρπ(τ)nt)/pt. (7)

We will proceed first by showing that the latter assignment satisfies our (yet to be defined) system of inequations Ψ:=Ψ1Ψ6.

When considering any model 𝔄φ we have that the domain A=π𝖥𝖳𝖯1σAπ is non-empty. The following is thus trivially satisfied by the assignment xπ:=Aπ:

{π𝖥𝖳𝖯1xπ1}. (Ψ1)

Additionally, picking any element aAπ (for any π𝖥𝖳𝖯1σ) and picking any π𝖥𝖳𝖯πσ, we have that the number of fluted 2-types emitted by a to Aπ must be |Aπ|=xπ. Assuming that 𝔄 is globally homogeneous, we may fixate on the fact that the shared profile ρπ of π has exactly |Aπ| witnesses for fluted 2-types with the endpoint π, or, more formally, τ𝖥𝖳𝖯2στ[2,2]=πρ(τ)=|Aπ|. Thus, the assignment yπ,τ:=ρπ(τ) satisfies the following set of inequations:

{xπ0τ𝖥𝖳𝖯2στ[2,2]=πyπ,τ=xπ|π,π𝖥𝖳𝖯1σ}. (Ψ2)

Of course, under the supposition that παr for some rR and π𝖥𝖳𝖯1σ such that |Aπ|1, we have that ρπ[nr+pr]γr. Clearly, k:=τ𝖥𝖳𝖯2στγrρπ(τ) must be a member of the linear set nr+pr. Thus, there is a period counter iπ,r such that k=nr+iπ,rpr. Turning the equation around we get that iπ,r=(knr)/pr. Recalling that ρπ(τ)=yπ,τ for all τ𝖥𝖳𝖯2σ, we have that the following is satisfied by our assignments:

{xπ0τ𝖥𝖳𝖯2στγryπ,τ=nr+iπ,rpr|rR,π𝖥𝖳𝖯1σ s.t. παr}. (Ψ3)

On the other hand, supposing πβt for some tT and with π𝖥𝖳𝖯1σ such that |Aπ|1, we have that ρπ⊧̸[nt+pt]δr, thus leaving k:=τ𝖥𝖳𝖯2στγrρπ(τ) outside of the linear set nt+pt. Notice that this happens when the following conditions are met:

  1. 1.

    k<nt; or

  2. 2.

    pt0 and k>m for each mnt+pt (which only happens when k=0); or

  3. 3.

    pt=0 and k>nt; or

  4. 4.

    for some mnt+pt we have m<k<m+pt.

Note that the listed conditions are exhaustive. We translate the requirements 14 into four functions Θ1,,Θ4 which map fluted 1-types paired with indices in T to linear equations. The functions are then defined as follows:

  • Θ1(π,t):=τ𝖥𝖳𝖯2στδtyπ,τ<nt,

  • Θ2(π,t):=τ𝖥𝖳𝖯2στδtyπ,τ=0,

  • Θ3(π,t):=(pt=0)(nt<τ𝖥𝖳𝖯2στδtyπ,τ),

  • Θ4(π,t):=nt+jπ,tpt<τ𝖥𝖳𝖯2στδtyπ,τ<nt+(jπ,t+1)pt.

Since k adheres to at least one of the four conditions, we write the following clauses for eligible fluted 1-types:

{xπ0i[1,4]Θi(π,t)|tT and π𝖥𝖳𝖯1σ such that πβt}. (Ψ4)

To verify that jπ,τ=(knt)/pt is indeed a satisfying assignment for Ψ4, we need only consider case 4. For this assume that m<k<m+pt for some mnt+pt. We can thus write m=nt+jpt. Since jπ,τ=(knt)/pt, we conclude that jπ,τ=j thus satisfying Θ4(π,t).

Reflecting on the semantics of the equality predicate, we see that for any given π𝖥𝖳𝖯1σ in any globally homogeneous model 𝔄φ there is exactly one τ𝖥𝖳𝖯2σ such that τ features the non-negated equality predicate and ρπ(τ)0. More precisely, ρπ(τ)=1 and the endpoint of τ is π. We have that our assignment respects this condition and thus satisfies the following inequations:

{yπ,τ=0|π𝖥𝖳𝖯1σ,τ𝖥𝖳𝖯2σ s.t. =τ,τ[2,2]π}{τ𝖥𝖳𝖯2σ=τyπ,τ=1|π𝖥𝖳𝖯1σ}. (Ψ5)

Finally, we forbid the periodic counters (iπ,r)π𝖥𝖳𝖯1σrR and (jπ,t)π𝖥𝖳𝖯1σtR from taking the value 0:

{iπ,r,jπ,t<0|π𝖥𝖳𝖯1σ and rR,tT}. (Ψ6)

Putting everything together, we have engineered a system of equations Ψ=Ψ1Ψ6 that is satisfied by extracting relevant cardinalities (see (7)) from homogeneous models of φ.

Lemma 3.

Suppose 𝔄φ is a globally homogeneous model. Then, Ψ is satisfiable.

We now move on to the converse direction:

Lemma 4.

Suppose Ψ is satisfiable. Then, there is a globally homogeneous model 𝔄φ.

Proof.

Suppose that Ψ has a satisfying assignment. To avoid notational clutter, we identify the solution vectors of variables in Ψ as themselves. We will build a globally homogeneous model 𝔄 over the domain A=π𝖥𝖳𝖯1σAπ, where Aπ={aπ,ii[1,xπ]}. Intuitively, we wish that elements of Aπ realise the fluted 1-type π. We thus assign 𝖿𝗍𝗉1𝔄(a):=π for all aAπ. Recalling that Aπ is the set of all elements that realise the 1-type π in 𝔄, we have that Aπ=Aπ is of cardinality xπ as required by (6). By Ψ1, the domain is non-empty.

Picking any π𝖥𝖳𝖯1σ we now move on to the assignment of fluted 2-types. Take any π𝖥𝖳𝖯1σ and let S={τ𝖥𝖳𝖯2στ[2,2]=π}, i.e. S is the set of all fluted 2-types containing the fluted 1-type π as an endpoint. By Ψ2, we have that τSyπ,τ=xπ, thus τSyπ,τ=|Aπ|. Now, pick some element aAπ. In case ππ, equation Ψ5 prohibits fluted 2-types that feature the (non-negated) equality literal. We set fluted 2-types between a and elements of Aπ in any way that results in |{bAπ𝖿𝗍𝗉2𝔄(ab)=τ}|=yπ,τ for each τS (n.b. the exact configuration of fluted 2-types between a and elements of Aπ is irrelevant as the fluted 2-type of ba for any bAπ is not set in this process). In case π=π notice that by Ψ5 there is exactly one τ=S such that (i) =τ=, (ii) yπ,τ=0, and with (iii) τ=[2,2]=π. By Ψ5 again, we have that yπ,τ==1. We therefore set the fluted 2-types between a and Aπ{a} for each τS{τ=} as in the case before and, additionally, specify that 𝖿𝗍𝗉2𝔄(aa):=τ=.

By repeating the fluted 2-type assignment for each element aA and fluted 1-type π𝖥𝖳𝖯1σ we are guaranteed that elements in Aπ (where π=𝖿𝗍𝗉𝔄(a)) realise the fluted 1-profile ρπ:={τyπ,ττ𝖥𝖳𝖯2σ} as required by (6). The resulting structure is clearly globally homogeneous.

We now claim that the resulting structure is a model of φ. Indeed, take any aA with π=𝖿𝗍𝗉1𝔄(a) and suppose παr for some rR. Let S={τ𝖥𝖳𝖯2στγr}. By equations Ψ3 and Ψ6, the sum τSyπ,τ is a member of the linear set nr+pr. Since the element a is of fluted 1-type π, we have that it realises the profile ρπ in 𝔄. By our construction, ρπ(τ)=yπ,τ for each τ𝖥𝖳𝖯2σ. Thus, ρπ[nr+pr]γr which is equivalent to 𝔄,a[nr+pr]γr as required.

On the other hand, suppose πβt for some tT. We claim that 𝔄,a⊧̸[nt+pt]δt. To see this, let S be the set {τ𝖥𝖳𝖯2στδt}. Writing k=τSyπ,τ we take note of equations Ψ4 and Ψ6, and conclude that one of the following conditions must be true:

  1. 1.

    k is smaller than the minimal element of nt+pt; or

  2. 2.

    nt+pt and k=0; or

  3. 3.

    pt=0 and k>nt; or

  4. 4.

    k is in between two consecutive elements of nt+pt.

Whichever case it may be, we have that knt+pt. Again, recalling that ρπ(τ)=yπ,τ for each τ𝖥𝖳𝖯2σ, we conclude that ρπ⊧̸[nt+pt]δt which is equivalent to saying 𝔄,a⊧̸[nt+pt]δt.

Given an 𝒫𝒞2-sentence φ we present a decision procedure for the (finite) satisfiability problem. Compute a normal-form formula ψ from φ and write the linear Diophantine equations Ψ. Now, guess a solution vector z¯ which can be done in non-deterministic polynomial time as a function of Ψ. If z¯ is indeed a solution for Ψ, accept, otherwise, reject. In the case of the finite satisfiability problem, prohibit 0 from being a solution in Ψ. Correctness of the procedure follows from the fact that, by Lemma 2, ψ if satisfiable then it is satisfiable in a globally homogeneous model. Thus, by Lemma 3, if ψ is satisfiable, then Ψ has a solution. On the other hand, by Lemma 4, if Ψ has a solution, then ψ is satisfiable.

Noting that the satisfiability problem for 2 is NExpTime-hard [21], and that Ψ is bounded by a polynomial function on the number of different fluted 1- and 2-types (of which there are 2φ many), we conclude the following:

Theorem 5.

The (finite) satisfiability problem of 𝒫𝒞2 is NExpTime-complete.

4 More Than Two Variables

We now generalise our results on homogeneity and decidability of satisfiability for higher-arity formulas of 𝒫𝒞. Thus, throughout this section, we will be working in the (+1)-variable sub-fragment of 𝒫𝒞, where 2 is fixed.

Firstly, we lift our homogeneity conditions to the multivariable setting. Suppose 𝔄 is a σ-structure and take any (1)-tuple b¯ from A and π𝖥𝖳𝖯σ. Let Aπb¯ be the set {aA𝖿𝗍𝗉𝔄(ab¯)=π}. We say that π is b¯-homogeneous in 𝔄 if for each a,aAπb¯ and all cA we have that 𝖿𝗍𝗉𝔄(ab¯c)=𝖿𝗍𝗉𝔄(ab¯c). That is to say, b¯c absorbs the same fluted (+1)-type from each -tuple ab¯ that realises the fluted -type π. If each π𝖥𝖳𝖯σ is b¯-homogeneous in 𝔄, then we say that the (1)-tuple b¯ is homogeneous in 𝔄. Finally, if each (1)-tuple b¯ is homogeneous in 𝔄, then we say that 𝔄 is locally -homogeneous.

When considering satisfiable normal-form 𝒫𝒞+1-sentences we can, without loss of generality, confine ourselves to locally -homogeneous structures. To see this fix some normal-form 𝒫𝒞+1-sentence φ and take b¯A1 and a,aAπb¯. Proceeding similarly as before Lemma 2 we see that the fluted (+1)-type of ab¯c does not impact the satisfaction of quantifier-free 𝒫𝒞+1-formulas by cb¯1a. Thus, redefining the fluted (+1)-types emitted by ab¯ will not alter the satisfaction of quantifier-free 𝒫𝒞+1-formulas by other tuples. Notice again that it is impossible to prohibit 𝖿𝗍𝗉𝔄(ab¯c)𝖿𝗍𝗉𝔄(ab¯c) by a normal-form formula. Thus, by setting 𝖿𝗍𝗉𝔄(ab¯c):=𝖿𝗍𝗉𝔄(ab¯c) for each cA and repeating the procedure for each aAπb¯{a}, we will have that π is b¯-homogeneous in 𝔄. Clearly 𝔄φ as the tuples rewired by this procedure (i.e. ab¯ with aAπb¯{a}) now emit τ𝖥𝖳𝖯+1σ to a given witness if and only if ab¯ does. The rewired tuples thus satisfy the same exact 𝒫𝒞+1-formulas with at most 1 quantifier as ab¯ does. Repeating the procedure for all π𝖥𝖳𝖯σ and b¯A1 we will have the following:

Lemma 6.

Suppose φ is a satisfiable normal-form 𝒫𝒞+1-sentence. Then, φ is satisfiable in a locally -homogeneous model.

Using local -homogeneity coupled with variable reduction techniques prevalent in studies of fluted logics (see [21]), we will establish a decidability result for the (finite) satisfiability problem of 𝒫𝒞+1. More specifically, fixing a normal-form 𝒫𝒞+1-sentence φ we will compute a normal-form 𝒫𝒞-sentence ψ that is satisfiable in structures holding just enough information to build locally -homogeneous models for φ. To aid motivation, we fix 𝔄 to be any locally -homogeneous model of φ. We shall construct ψ whilst also expanding 𝔄 into 𝔄ψ. Note that the construction depends exclusively on the syntactic properties of φ.

First, set 𝔄:=𝔄. Take (qπ)π𝖥𝖳𝖯σ to be a sequence of fresh (1)-ary predicate symbols. In 𝔄 we decorate (1)-tuples b¯ over A with qπ just in case we have that Aπb¯. That is to say, qπ𝔄 remembers which (1)-tuples can be extended (by appending an element to the left) to realise the fluted -type π. It is clear that 𝔄 models the following:

π𝖥𝖳𝖯σ(πqπ). (ψ1)

Proceeding similarly, let (sπ,τ)π𝖥𝖳𝖯στ𝖥𝖳𝖯+1σ be a sequence of new -ary predicates. Intuitively, we will have b¯csπ,τ𝔄 if in 𝔄 it is the case that b¯c absorbs the fluted (+1)-type τ emitted from ab¯ for some aAπb¯. Notice that, by local -homogeneity, if b¯c absorbs τ from some ab¯ with aAπb¯, then it absorbs τ from ab¯ for all aAπb¯. Thus, by our construction, sπ,τ is the unique predicate amongst (sπ,τ)τ𝖥𝖳𝖯+1σ satisfied by b¯c in 𝔄. Clearly, 𝔄 models:

π𝖥𝖳𝖯στ𝖥𝖳𝖯+1σ(sπ,ττ[2,+1])π𝖥𝖳𝖯σ1(qπ(τ𝖥𝖳𝖯+1σsπ,ττ,τ𝖥𝖳𝖯+1σττ(¬sπ,τ¬sπ,τ))). (ψ2)

Again taking b¯A1 and any π𝖥𝖳𝖯σ suppose παr for some rR. In case Aπb¯ is non-empty (thus guaranteeing b¯qπ𝔄), we pick any aAπb¯ and write S={cA𝔄,ab¯cγr}. Since π is b¯-homogeneous in 𝔄, the exact element in Aπb¯ we pick has no effect on S. By our construction, S is then exactly the set of element cA such that 𝔄,b¯cτ𝖥𝖳𝖯+1στγrsπ,τ. Since |S|nr+pr it is then immediate that 𝔄 models the following:

rRπ𝖥𝖳𝖯σπαr1(qπ[nr+pr]τ𝖥𝖳𝖯+1στγrsπ,τ). (ψ3)

Similar observations follow whenever πβt for some tT. This time, however, the cardinality of S={cA𝔄,ab¯cδr} must be outside the set nr+pr. Clearly, 𝔄 models:

tTπ𝖥𝖳𝖯σπβt1(qπ¬[nt+pt]τ𝖥𝖳𝖯+1στδtsπ,τ). (ψ4)

Writing ψ:=ψ1ψ4 we have shown the following:

Lemma 7.

Suppose 𝔄φ is a locally -homogeneous model. Then, 𝔄 can be extended to a model 𝔄 of ψ.

Lemma 8.

Suppose 𝔄ψ. Then, we can construct a locally -homogeneous model 𝔄+ of φ over the same domain.

Proof.

Supposing ψ is satisfiable we take any model 𝔄. Now, let 𝔄 be the model 𝔄 but with the predicates in (qπ)π𝖥𝖳𝖯σ and (sπ,τ)π𝖥𝖳𝖯στ𝖥𝖳𝖯+1σ removed from the signature. We proceed by expanding 𝔄 into a locally -homogeneous model 𝔄+ of the original sentence φ.

Fix b¯A1 and take some aA. Supposing that 𝖿𝗍𝗉𝔄(ab¯)=π, by ψ1 we have that 𝔄,b¯qπ. Taking any cA we observe that the conjuncts of ψ2 enforce the following:

  • if 𝔄,b¯csπ,τ for some τ𝖥𝖳𝖯+1σ, then b¯c can absorb the fluted (+1)-type τ,

  • b¯c satisfies at least one of the predicates (sπ,τ)τ𝖥𝖳𝖯+1σ, and

  • b¯c satisfies at most one of the predicates (sπ,τ)τ𝖥𝖳𝖯+1σ.

We can then safely set 𝖿𝗍𝗉+1𝔄+(ab¯c):=τ for each cA, where τ is taken from the subscript of the unique sπ,τ(sπ,τ)τ𝖥𝖳𝖯+1σ that b¯c satisfies in 𝔄. By repeating the above procedure for all aA and tuples b¯A1 we will obtain the desired structure 𝔄+.

To verify that 𝔄+ is a model of φ we first claim that 𝔄+rR(αr[nr+pr]γr). For this purpose, fix some rR and ab¯A, and suppose παr, where 𝖿𝗍𝗉𝔄+(ab¯)=π. Recall that b¯qπ𝔄 by ψ1. Then, ψ3 gives us 𝔄,b¯[nr+pr]τ𝖥𝖳𝖯+1στγrsπ,τ. Taking any cA we have, by our construction, that 𝔄+,ab¯cτ if and only if 𝔄,b¯csπ,τ. Thus, 𝔄+,ab¯[nr+pr]τ𝖥𝖳𝖯+1στγrτ, which is equivalent to saying 𝔄+,ab¯[nr+pr]γr. Repeating the argument for each rR and ab¯A will yield the required result.

To show 𝔄+tT(βt¬[nt+pt]δt) we proceed analogously with ψ4 in place of ψ3.

Let us take stock of the previous three lemmas. Take φ to be an 𝒫𝒞+1-sentence. Without loss of generality, assume that it is in normal-form (Lemma 1). By Lemma 6, φ is satisfiable if it is satisfiable in a locally -homogeneous model. By computing the formula ψ we have, by Lemmas 7 and 8, that ψ is (finitely) satisfiable if and only if φ is. Noting that the (finite) satisfiability problem for 𝒫𝒞2 is in NExpTime (Theorem 5) and that ψ can be constructed from φ in polynomial time in regards to the number of different fluted - and (+1)-types (of which there are 2O(φ)), we conclude the following:

Theorem 9.

The (finite) satisfiability problem for 𝒫𝒞+1 is in -NExpTime.

Noting that the (finite) satisfiability problem for +1 is (+1)/2-NExpTime-hard [21], we see that no elementary function can encapsulate the complexity of (finite) satisfiability for 𝒫𝒞. We thus conclude our section having reached our initial goal:

Theorem 10.

The (finite) satisfiability problem for 𝒫𝒞 is Tower-complete.

5 Counting With Reversed Relations

In this section we will show that relaxing the syntactic restrictions of the fluted fragment with counting yields undecidability of satisfiability. We define the language rev to be but with the addition of atoms with reversed variable sequences. More formally, if r(xk,,x) is an -atom, then r(xk,,x) and r(x,,xk) are rev-atoms. The language 𝒞rev (𝒫𝒞rev) is then the obvious extension of rev with (periodic) counting quantifiers. Clearly, the languages rev, 𝒞rev, and 𝒫𝒞rev are subfragments of the adjacent fragment with the appropriate counting extensions. We will use counting quantifiers [=1] and [1] with the meanings “there is exactly one element s.t. …” and “there is at most one element s.t. …” along side periodic counting qunatifiers. For simplicity, we do away with variable-free notation and use variable sequences of x,y,z and z,y,x in place of x1,x2,x3.

We proceed by reducing Hilbert’s 10th problem to the finite satisfiability problem of 𝒞rev3. Let be a system of Diophantine equations. We assume that each equation e is of one of the following (simple) forms: (i) u=1, (ii) u+v=w, or (iii) uv=w, where u,v,w are mutually disjoint variables. Clearly, no loss of generality occurs as any (non-simple) Diophantine equation can be rewritten into the simpler form by introducing new variables. For each e we will define a formula φe depending on the form that e takes. Then, φ:=eφeψ will be the advertised formula that is finitely satisfiable if and only if has a solution over . We specify that the signature of φ includes (1) unary predicates Au for each variable of u in , (2) binary predicates Re for each e of the form (ii), and (3) ternary predicates Pe for each e of the form (iii). We will not assume that the equality predicate is available. In the sequel we will argue that if 𝔄φ, then has a solution with u|Au𝔄| for each variable u. (And, of course, the converse as well). For technical reasons we wish for the sets Au𝔄 and Av𝔄 with uv to be disjoint. Denoting vars() for the set of variables in , we first define ψ:=u,vvars()uvx(¬Au(x)¬Av(x)), which clearly has the required effect. We proceed by taking e in turn.

Suppose first that e is of the form (i) u=1. We ensure that every model 𝔄 of φ will have |Au𝔄|=1 by defining φe to be [=1]xAu(x).

Now, supposing that e is of the form (ii) u+v=w, we define φe with the intent that models 𝔄 of φ will have Re𝔄 being a bijection between Au𝔄Av𝔄 and Aw𝔄 (i.e. |Au𝔄|+|Av𝔄|=|Aw𝔄|):

x ((Au(x)Av(x))[=1]y(Aw(y)Re(xy)))
y (Aw(y)[=1]x((Au(x)Av(x))Re(xy))).

Lastly, if e is of the form (iii) uv=w, then φe (defined just below) will guarantee that 𝔄φ forces Pe𝔄 to be a bijection between Au𝔄×Av𝔄 and Aw𝔄 (i.e. |Au𝔄||Av𝔄|=|Aw𝔄|):

x(Au(x)y(Av(y)[=1]z(Aw(z)Pe(xyz))))z(Aw(z)[=1]y(Av(y)x(Au(x)Pe(xyz))))z(Aw(z)y(Av(y)[=1]x(Au(x)Pe(xyz)))).

It is then straightforward to show (see Appendix B) that φ is finitely satisfiable iff has a solution over . Noting that the problem of finding solutions to Diophantine equations over is Σ10-complete, and that φ[0+1]x is an 𝒫𝒞rev3-sentence that is satisfiable if and only if φ is finitely satisfiable, we conclude the following:

Theorem 11.

The finite satisfiability problem for 𝒞rev3 is Σ10-hard. If periodic counting is permitted, then so is the general satisfiability problem.

We note that one can use the same type of argument as above when reducing from the problem of solving Diophantine equations over ={1,2,}{0} to the general satisfiability problem of 𝒞+1. Such an approach, however, is not fruitful for determining undecidability as the problem of finding solutions to over is in NPTime [14]. Thus, to show undecidability of general satisfiability, we resort to the tiling problem. Take Φ=𝒯,,𝒱 with ,𝒱𝒯×𝒯. We will produce and 𝒞rev4-sentence φ that is satisfiable if and only if Φ tiles the infinite × plane in accordance to the horizontal () and vertical (𝒱) constraints. Additionally, we will argue that one can append additional 𝒫𝒞rev2 conjuncts to φ and thus obtain a reduction from the tiling problem with a designated tile recurring infinitely often on the first column (see [10] for details about the problem). All-in-all, such reductions will guarantee that 𝒞rev4 is Π10-hard, whilst making 𝒫𝒞rev4 hard for Σ11.

Take G to be unary and H, V to be binary predicate symbols. We define the canonical (×)-grid to be a {G,H,V}-structure 𝔊 over the domain × with the following extensions:

  • G𝔄:=×,

  • H𝔄:={(i,j),(i,j+1)i,j}, and

  • V𝔄:={(i,j),(i+1,j)i,j}.

We say that a structure 𝔄 is a (×)-grid if 𝔄 restricted to elements G𝔄 and the signature {G,H,V} is isomorphic to the canonical (×)-grid. More leniently, 𝔄 is grid-like if it contains a homomorphic embedding of 𝔊. It is well known that the satisfiability problem posed over subclasses of grid-like structures is undecidable for even inexpressive logics such as 2. The following is almost immediate:

Lemma 12.

The satisfiability problem for 𝒞rev2 posed over subclasses of grid-like structures is Π10-hard. The satisfiability problem for 𝒫𝒞rev2 posed over subclasses of (×)-grids is Σ11-hard.

The lemma above is, of course, the “easy” part of a much larger reduction. The axiomatisation of grid-like structures and (×)-grids is where the expressive power of 𝒞rev4 and 𝒫𝒞rev4 is needed. Before writing the advertised formulas, we build the motivating structure we will be looking for in three steps. Suppose 𝔊 is the canonical (×)-grid. Letting EH, EV be binary and O be unary predicate symbols we define the graphed expansion of 𝔊 to be the structure 𝔊+ over the domain (×) with the following extensions:

  • 𝔊+×:=𝔊,

  • kG𝔊+ for each k,

  • kO𝔊+ if and only if k=0,

  • EH𝔊+:=i,j{(i,j),k| 1ki}, and

  • EV𝔊+:=i,j{(i,j),k| 1kj}.

Intuitively, 𝔊+, when restricted to ×=G𝔊+, is the canonical (×)-grid. Notice that each (i,j)× has i elements in that are EH-successors and j elements that are EV-successors. In other words, the coordinates of (i,j) are explicitly encoded in 𝔊+ as the out-degrees of EH and EV respectively. (In the future, we will simply speak of EH- and EV-degree with “out” being left implicit). We invite the reader to regard as the set of extra elements which help encode positions of grid elements. Notice that the singleton 0O𝔊+ is not featured in any binary relations (most notably, EH and EV). This is deliberate as it will act as a spare part in the constructions to come.

We now define the mapped expansion 𝔊 of 𝔊+, where 𝔊+ itself is the graphed expansion of 𝔊. For this, we introduce quaternary RH, RV, SH, SV and ternary predicates CH, CV, whilst setting the following extensions:

  • RH𝔊:=i,j,i,jii{k,(i,j),(i,j),k| 1ki},

  • RV𝔊:=i,j,i,jjj{k,(i,j),(i,j),k| 1kj},

  • SH𝔊:=i,j,j{k1,(i,j),(i+1,j),k| 1ki+1},

  • SV𝔊:=i,j,i{k1,(i,j),(i,j+1),k| 1kj+1},

  • CH𝔊:=i,j,i,jii{k,(i,j),(i,j)| 1ki}, and

  • CV𝔊:=i,j,i,jjj{k,(i,j),(i,j)| 1kj}.

Recall that each (i,j)× sends EH-edges to each k[1,i]. Fixing some (i,j)× with ii, we have that RH𝔊 injectively maps EH-edges originating from (i,j) to EH-edges of (i,j). On the other hand, SH𝔊 is a bijection between the EH-edges of (i,j) with the spare part 0 and EH-edges of (i+1,j). The relation CH𝔊 simply remembers which EH-edges of (i,j) are mapped to EH-edges of (i,j) via RH𝔄. Relations RV𝔊, SV𝔊 and CV𝔊 act similarly.

Lastly, We say that 𝔊# is the ordered expansion of 𝔊, where 𝔊 itself is the graphed and mapped expansion of 𝔊, if the signature contains two additional relations H and V which we will define to be total orders over ×. For motivational purposes, we will forget that grid elements a and b are pairs of natural numbers and instead focus on the EH- and EV-degrees of the elements. In 𝔊# we will have that

  • aH𝔊#b if and only if the EH-degree of a is no more than that of b, and

  • aV𝔊#b if and only if the EV-degree of a is no more than that of b.

(Again, the EH- and EV-degrees encode the horizontal and vertical positions of the element).

We will now write the sentence φ:=φ1φ13 one conjunct at a time. At a high level, the conjuncts simply state facts about the graphed mapped and ordered expansion 𝔊# of 𝔊. In the sequel we will argue that the satisfaction of φ by 𝔄 is sufficient to deduce that the structure in question is grid-like. For readability, we will be using variable sequences x,y,z,w and w,z,y,x instead of x1,x2,x3,x4. Strictly speaking, the formulas to be defined are not (reverse) fluted, but can be made such by moving quantifiers inwards.

Fix 𝔊# to be as described above. We first capture some graphed properties. Recall that in 𝔊# there is a single spare part element 0O𝔊#. Noting that this element is not part of the grid (0G𝔊#) we have that 𝔊# models:

[=1]xO(x)x(O(x)¬G(x)) (φ1)

Additionally, recall that the spare part 0 has no incoming edges EH- or EV-edges in 𝔊#. Thus, 𝔊# also models:

x(O(x)y(¬EH(yx)¬EV(yx))) (φ2)

Moving to grid elements, we see that there is a single element in G𝔄# with no EH- or EV-degree. Thus, 𝔊# is a model of:

[=1]x(G(x)y(¬EH(xy)¬EV(xy))). (φ3)

Additionally, each element in G𝔊# has a single H- and V-successor. Thus, 𝔊# models:

x(G(x)([=1]y(H(xy)G(y))[=1]y(V(xy)G(y)))). (φ4)

For the next two conjuncts fix (i,j)G𝔊#. Notice that the H-successor (i+1,j) has an EH-degree that is larger by 1 when compared to its predecessor (i,j). We can thus map the EH-edges from (i+1,j) to the set of EH-edges from (i,j) taken together with the spare part element bijectively. This is exactly how the extension to SH in 𝔊# is set up. Noting that V-successors have analogous properties we conclude that 𝔊# models the following sentences:

X{H,V}xyz(((EX(yx)O(x))X(yz))[=1]w(EX(zw)SX(xyzw))), (φ5)
X{H,V}wzy((EX(zw)X(yz))[=1]x((EX(yx)O(x))SX(xyzw))). (φ6)

Recall that for grid elements (i,j),(i,j)G𝔊# we have 𝔊#(i,j)V(i,j) if and only if the EV-degree of (i,j) is no more than that of (i,j). Fixing (i,j) and its H-successor (i+1,j) we see that 𝔊#(i,j)V(i+1,j)(i+1,j)V(i,j). That is, (i,j) and its H-successor have the same EV-degrees. Thus, 𝔊# models:

X,Y{H,V}XYxy(X(xy)(xYyyYx)). (φ7)

Now, recall that the ordering X (X{H,V}) is total on G𝔊#. Thus, 𝔊# models:

X{H,V}xy((G(x)G(y))(xXyyXx)). (φ8)

Taking (i,j),(i,j)G𝔊# with ii recall that the elements have EH-edges mapped injectively by RH𝔊#. Thus, 𝔊#(i,j)H(i,j) if and only if RH𝔊# is an injection between the EH-edges of (i,j) and that of (i,j). We capture the “only-if” direction of the dependency with the sentences φ9 and φ10, whilst the “if” direction is handled by φ11 and φ12.

Still holding the supposition that 𝔊#(i,j)H(i,j), we write a sentence ensuring that each EH-edge from (i,j) is mapped to some single EH-edge from (i,j):

X{H,V}xyz((yXzEX(yx))[=1]w(EX(zw)RX(xyzw))). (φ9)

With the next sentence we require that each EH-edge from (i,j) is a witness (in regard to RH𝔊#) to at most a single EH-edge from (i,j):

X{H,V}wzy((yXzEX(zw))[1]x(EX(yx)RX(xyzw))). (φ10)

It is easy to verify that this is indeed how RH𝔊# is set up. Noting that V and RV behave symmetrically we conclude 𝔊#φ9φ10.

For the converse direction of the implication take any (i,j),(i,j)G𝔊# and recall that k,(i,j),(i,j)CH𝔊# if and only if there is some k for which k,(i,j),(i,j),kRH𝔊#. In other words, CH𝔊# remembers which EH-edges from (i,j) are featured in a mapping (by RH𝔊#) with EH-edges from (i,j). We axiomatise this relationship as follows:

X{H,V}wzy(CX(wzy)[=1]x(EX(yx)RX(xyzw))). (φ11)

Utilising CH we can then test if each EH-edge of (i,j) is mapped to some EX-edge of (i,j) and, if that is indeed the case, require that the grid elements be related via H accordingly. We do just that with φ12:

X=H,Vyz((G(y)G(z)w(EX(zw)CX(wzy)))zXy). (φ12)

Noting that V, RV and CV behave similarly, we have that 𝔊#φ11φ12.

Lastly, notice that there are no two grid elements that have the same EH- and EV-degrees. Thus, 𝔊# models the uniqueness requirement as given by φ13:

y(G(y)[=1]z(X=H,V(yXzzXy))). (φ13)

Notice that by stepping inside the realm of periodic counting, we may capture the fact that in 𝔊# there are no transfinite positions by defining the sentence χ limiting the EH- and EV-degrees of elements to finite values:

X=H,Vx[0+1]yEX(xy). (χ)

Recalling that φ:=φ1φ13 we have showed the following:

Lemma 13.

The graphed, mapped and ordered expansion of the canonical (×)-grid is a model of φχ.

We proceed with the other direction as follows:

Lemma 14.

Suppose 𝔄φ. Then 𝔄 is a grid-like structure. In addition, if 𝔄χ, then 𝔄 is an (×)-grid.

Proof.

Suppose first that 𝔄φ. Notice that by φ1 there is exactly one element that satisfies O in 𝔄 and, by φ2, has no incoming EH- and EV-edges. This will be our spare part element in the argument to come. Now, take any element a0,0A such that a0,0G𝔄 (i.e. a0,0 is a grid element) with finite EH- and EV-degree. Such an element is guaranteed to exist by φ3. Then, φ4 gives us that a0,0 has an H-successor a1,0 and a V-successor a0,1. Notice that, by φ5 each EH-edge originating from a0,0 along with the spare part is paired with exactly one edge EH-edge from a1,0 in SE𝔄. That is to say, writing U={bAa0,0bEH𝔄 or bO𝔄} and U={cAa1,0cEH𝔄}, we have that for each bU there is exactly one cU such that ba0,0a1,0cSE𝔄. The reverse is established by φ6. Clearly, there is a bijection between U and U thus making the EH-degree of a1,0 one greater than that of a0,0. By φ7 we have that a0,0V𝔄a1,0 and a1,0V𝔄a0,0. We first fixate on the fact that a0,0V𝔄a1,0. Writing U={bAa0,0bEV𝔄} and U={cAa1,0cEV𝔄} we have, by φ9, that for each bU there is exactly one cU such that ba0,0a1,0cRV𝔄. By φ10, for each cU there is at most a single bU such that ba0,0a1,0cRV𝔄. We may thus regard RV𝔄 as being an injection between EV-edges of a0,0 and that of a1,0. Then, again by φ9, φ10 and the fact that a1,0V𝔄a0,0, we have that RV𝔄 is an injection between the EV-edges from a1,0 and that of a0,0. By the Cantor-Schröder-Bernstein Theorem, their EV-degrees are thus equal. A symmetric argument holds for the EV- and EH-degree of a0,1.

Now, let a1,1 and a1,1 be, respectively, the V-sucessor of a1,0 and the H-sucessor of a0,1 promised by φ4. Using the same arguments as in the paragraph above, it is easy to see that the EH-degrees of a1,1 and a1,1 coincide; and so do the EV-degrees. We claim that a1,1=a1,1. By φ13 we need only show that a1,1 is equal to a1,1 with respect to the orderings H𝔄 and V𝔄 as we already have that a1,1Ea1,1 and a1,1Va1,1 by φ8. Fixating on EH-edges first, we have, by φ8, that a1,1 and a1,1 are comparable by E𝔄 in some way. Suppose, without loss of generality, that a1,1E𝔄a1,1. Writing U={bAa1,1bEH𝔄} and U={cAa1,1cEH𝔄} we have, by φ9, that for each bU there is exactly one cU such that ba1,1a1,1cRE𝔄, and, by φ10, for each cU there is at most one bU such that the same holds. That is to say, RE𝔄 is an injection between EH-edges originating from a1,1 and EH-edges from a1,1. Notice that since a1,1 and a1,1 both have an equal and finite EH-degree, we can conclude that RE𝔄 is a bijection between the edges. Using this, we have that ca1,1a1,1CH𝔄 for each cU by φ11. Clearly, the antecedents of φ12 are met and thus a1,1E𝔄a1,1 as required. Repeating the argument for V𝔄 we indeed have (by φ13) that a1,1=a1,1 thus closing the grid.

By repeating the argument above on element in G𝔄 with finite EH- and EV-degree we conclude that 𝔄 contains a homomorphic embedding of the canonical (×)-grid thus making it grid-like.

Supposing, in addition, that 𝔄χ we have that each element in G𝔄 has a finite EH- and EV-degree. We may thus unambiguously identify these elements as the pair of their EH-degree i and EV-degree j. Hence, the structure 𝔄 restricted to elements in G𝔄 and signature {G,H,V} is isomorphic to the canonical (×)-grid thus making 𝔄 an (×)-grid as required.

Combining Lemmas 13 and 14 we have that φ is a satisfiable 𝒞rev4-sentence modeled exclusively by (some non-empty subclass of) grid-like structures, whilst φχ is a satisfiable 𝒫𝒞rev4-sentence that is modeled only by (some non-empty subclass of) (×)-grids. Combining the observation above with Lemma 12 we have the following:

Theorem 15.

The satisfiability problem for 𝒞rev4 is Π10-hard. The same problem for 𝒫𝒞rev4 is Σ11-hard.

Note that the adjacent fragment with periodic counting is a fragment of the constructive fragment of ω1,ω, which has a Σ11-complete satisfiability problem [10, 15]. We conclude the section by reformulating results of Theorems 11 and 15 in terms of the adjacent fragment:

Corollary 16.

The finite and general satisfiability problems for the adjacent fragment with counting are, respectively, Σ10- and Π10-complete. If periodic counting is permitted, then the general satisfiability problem turns to be Σ11-complete.

6 Discussion

In this paper we utilised the homogeneity property of satisfiable 𝒫𝒞-sentences to establish a decision procedure for the (finite) satisfiability problem of the new language. With this methodology we not only gained a better understanding of models of fluted formulas, but also managed to establish decidability of (finite) satisfiability using simpler methods when compared to Presburger quantifiers discussed in previous literature [19, 24].

Reflecting on global homogeneity we see that, as opposed to local homogeneity, the rewiring in Lemma 2 is impacted by the presence of the (in)equality atom. More precisely, the semantics of predicates of arity at most do not interfere in the rewiring for local -homogeneity. Because of this we may establish a more general result for local homogeneity of fluted sentences with semantic extensions. Consider a signature that is split into symbols σ with a fixed interpretation (e.g. transitive relation, reversed relation, etc.) and standard predicate symbols σ with no fixed meaning. Furthermore, suppose that the maximum arity of any symbol in σ is at most k. Then, Lemma 6 implies the following:

Corollary 17.

Suppose φ is a fluted, normal-form, (+1)-variable sentence (possibly with periodic counting) over the signature σσ, and where k. Then if φ is satisfiable it is satisfiable in a locally -homogeneous model.

The same cannot be said about (+1)-variable sentences when <k, and thus establishing an analogue to global homogeneity (as was done for 𝒫𝒞2 with equality in Lemma 2) requires case-by-case consideration. Nonetheless, we believe our approach could not only be used to simplify existing decidability procedures for satisfiability (e.g. for with a transitive relation and counting [24]) but to also expand on expressiveness of fluted languages.

We make use of Corollary 17 when (briefly) analysing the language formed by combining 𝒫𝒞 and 𝒪Pres2. That is to say, is 𝒫𝒞 with (+1)-atoms R(x+1,R) and R(x+1,x+1) allowed. The following is almost immediate. (See Appendix C for the proof).

Theorem 18.

The (finite) satisfiability problem for is decidable.

Combining the result above with Corollary 16, and noting that more expressive counting quantifiers render the two-variable fragment undecidable [7, 5], one can argue that the language is on the edge of decidability (for satisfiability). There are, however, other maximal fragments with counting that have a decidable satisfiability problem. The reader might have noticed that, in Section 5, we did not consider the general satisfiability problem for the 3-variable adjacent fragment with counting (whilst noting that the finite variant is undecidable in Theorem 11). Surprisingly, the problem was recently shown to be in Δ10 by the current author. The details, however, are beyond the scope of this article. We conclude the paper by outlining the following problems which, to the best of our knowledge, are open.

  1. 1.

    What is the complexity of satisfiability for the 3-variable adjacent fragment with counting?

  2. 2.

    Is the satisfiability problem for the adjacent fragment with periodic counting Σ11-hard?

  3. 3.

    Is the satisfiability problem for the guarded adjacent fragment with counting decidable?

References

  • [1] Franz Baader. A new description logic with set constraints and cardinality constraints on role successors. In Frontiers of Combining Systems, pages 43–59. Springer International Publishing, 2017. doi:10.1007/978-3-319-66167-4_3.
  • [2] Bartosz Bednarczyk. Exploiting forwardness: Satisfiability and query-entailment in forward guarded fragment. In Logics in Artificial Intelligence - 17th European Conference, JELIA 2021, Virtual Event, May 17-20, 2021, Proceedings, volume 12678 of Lecture Notes in Computer Science, pages 179–193. Springer, 2021. doi:10.1007/978-3-030-75775-5_13.
  • [3] Bartosz Bednarczyk and Reijo Jaakkola. Towards a model theory of ordered logics: Expressivity and interpolation. In 47th International Symposium on Mathematical Foundations of Computer Science, MFCS 2022, August 22-26, 2022, Vienna, Austria, volume 241 of LIPIcs, pages 15:1–15:14. Schloss Dagstuhl – Leibniz-Zentrum für Informatik, 2022. doi:10.4230/LIPICS.MFCS.2022.15.
  • [4] Bartosz Bednarczyk, Daumantas Kojelis, and Ian Pratt-Hartmann. On the Limits of Decision: the Adjacent Fragment of First-Order Logic. In 50th International Colloquium on Automata, Languages, and Programming (ICALP 2023), volume 261 of Leibniz International Proceedings in Informatics (LIPIcs), pages 111:1–111:21, Dagstuhl, Germany, 2023. Schloss Dagstuhl – Leibniz-Zentrum für Informatik. doi:10.4230/LIPICS.ICALP.2023.111.
  • [5] Bartosz Bednarczyk, Maja Orłowska, Anna Pacanowska, and Tony Tan. On Classical Decidable Logics Extended with Percentage Quantifiers and Arithmetics. In 41st IARCS Annual Conference on Foundations of Software Technology and Theoretical Computer Science (FSTTCS 2021), volume 213 of Leibniz International Proceedings in Informatics (LIPIcs), pages 36:1–36:15, Dagstuhl, Germany, 2021. Schloss Dagstuhl – Leibniz-Zentrum für Informatik. doi:10.4230/LIPICS.FSTTCS.2021.36.
  • [6] Michael Benedikt, Egor V. Kostylev, and Tony Tan. Two variable logic with ultimately periodic counting. SIAM Journal on Computing, 53(4):884–968, 2024. doi:10.1137/22M1504792.
  • [7] Erich Grädel, Martin Otto, and Eric Rosen. Undecidability results on two-variable logics. Archive for Mathematical Logic, 38(4):313–354, 1999. doi:10.1007/S001530050130.
  • [8] Erich Grädel. On the restraining power of guards. The Journal of Symbolic Logic, 64(4):1719–1742, 1999. doi:10.2307/2586808.
  • [9] Erich Grädel, Phokion G. Kolaitis, and Moshe Y. Vardi. On the decision problem for two-variable first-order logic. The Bulletin of Symbolic Logic, 3(1):53–69, 1997. doi:10.2307/421196.
  • [10] David Harel. Recurring dominoes: Making the highly undecidable highly understandable. In Topics in the Theory of Computation, volume 102 of North-Holland Mathematics Studies, pages 51–71. North-Holland, 1985.
  • [11] Andreas Herzig. A new decidable fragment of first order logic. In Abstracts of the 3rd Logical Biennial Summer School and Conference in honour of S. C. Kleene, Varna, Bulgaria, 1990.
  • [12] Ullrich Hustadt, Renate A Schmidt, and Lilia Georgieva. A survey of decidable first-order fragments and description logics. Journal of Relational Methods in Computer Science, 1(3):251–276, 2004.
  • [13] Reijo Jaakkola. Ordered fragments of first-order logic. In 46th International Symposium on Mathematical Foundations of Computer Science, MFCS 2021, August 23-27, 2021, Tallinn, Estonia, volume 202 of LIPIcs, pages 62:1–62:14. Schloss Dagstuhl – Leibniz-Zentrum für Informatik, 2021. doi:10.4230/LIPICS.MFCS.2021.62.
  • [14] Emil Jeřábek. Division by zero. Archive for Mathematical Logic, 55(7):997–1013, 2016. doi:10.1007/S00153-016-0508-5.
  • [15] H. Jerome. Keisler. Model theory for infinitary logic : logic with countable conjunctions and finite quantifiers. Studies in logic and the foundations of mathematics ; v. 62. North-Holland Pub. Co., Amsterdam, 1971.
  • [16] Viktor Kuncak and Martin Rinard. Towards efficient satisfiability checking for boolean algebra with presburger arithmetic. In Automated Deduction – CADE-21, pages 215–230, Berlin, Heidelberg, 2007. Springer Berlin Heidelberg. doi:10.1007/978-3-540-73595-3_15.
  • [17] Christos H. Papadimitriou. On the complexity of integer programming. J. ACM, 28(4):765–768, 1981. doi:10.1145/322276.322287.
  • [18] Ian Pratt-Hartmann. The two-variable fragment with counting revisited. In Logic, Language, Information and Computation, 17th International Workshop, WoLLIC 2010, Brasilia, Brazil, July 6-9, 2010. Proceedings, volume 6188 of Lecture Notes in Computer Science, pages 42–54. Springer, 2010. doi:10.1007/978-3-642-13824-9_4.
  • [19] Ian Pratt-Hartmann. Fluted logic with counting. In 48th International Colloquium on Automata, Languages, and Programming, ICALP 2021, July 12-16, 2021, Glasgow, Scotland (Virtual Conference), volume 198 of LIPIcs, pages 141:1–141:17. Schloss Dagstuhl – Leibniz-Zentrum für Informatik, 2021. doi:10.4230/LIPICS.ICALP.2021.141.
  • [20] Ian Pratt-Hartmann. Fragments of First-Order Logic. Oxford University Press, 2023.
  • [21] Ian Pratt-Hartmann, Wieslaw Szwast, and Lidia Tendera. The fluted fragment revisited. Journal of Symbolic Logic, 84(3):1020–1048, 2019. doi:10.1017/JSL.2019.33.
  • [22] Ian Pratt-Hartmann and Lidia Tendera. The Fluted Fragment with Transitivity. In 44th International Symposium on Mathematical Foundations of Computer Science (MFCS 2019), volume 138 of Leibniz International Proceedings in Informatics (LIPIcs), pages 18:1–18:15, Dagstuhl, Germany, 2019. Schloss Dagstuhl – Leibniz-Zentrum für Informatik. doi:10.4230/LIPICS.MFCS.2019.18.
  • [23] Ian Pratt-Hartmann and Lidia Tendera. The fluted fragment with transitive relations. Annals of Pure and Applied Logic, 173(1):103042, 2022. doi:10.1016/J.APAL.2021.103042.
  • [24] Ian Pratt-Hartmann and Lidia Tendera. Adding Transitivity and Counting to the Fluted Fragment. In 31st EACSL Annual Conference on Computer Science Logic (CSL 2023), volume 252 of Leibniz International Proceedings in Informatics (LIPIcs), pages 32:1–32:22, Dagstuhl, Germany, 2023. Schloss Dagstuhl – Leibniz-Zentrum für Informatik. doi:10.4230/LIPICS.CSL.2023.32.
  • [25] William C. Purdy. Fluted formulas and the limits of decidability. The Journal of Symbolic Logic, 61(2):608–620, 1996. doi:10.2307/2275678.
  • [26] Willard Van Orman Quine. On the limits of decision. In Proceedings of the 14th International Congress of Philosophy, volume III, pages 57–62. University of Vienna, 1969.

Appendix A Preliminaries

Lemma 1.

Suppose φ is an 𝒫𝒞+1-sentence. Then, we may compute, in polynomial time, an equisatisfiable normal-form 𝒫𝒞+1-sentence ψ.

Proof.

We start by assuming that φ contains no universal quantifiers. No loss of generality follows this supposition as every formula of the form θ is equivalent to [0]¬θ. Writing φ0:=φ, take any subformula θ:=[n+p]χ of φ0, where χ is quantifier-free. Supposing there are k free variables in θ, let q be a fresh predicate of arity k. We write ψ1 as (q[n+p]χ)(¬q¬[n+p]χ) and define φ1 to be φ0 but with θ replaced by q. Clearly, φ1ψ1φ0. Conversely, if 𝔄φ0, we may expand 𝔄 to 𝔄 by setting a¯q𝔄 if 𝔄,a¯θ for each a¯Ak. Then, 𝔄φ1ψ1 as required. Processing φ1 and subsequent sentences in the same way, we are left with a sentence φm composed solely of proposition letters and sentences ψ1,,ψm. The conjunction of the aforementioned sentences is then (after rearrangement) of the required form.

Appendix B Counting With Reversed Relations

Claim.

Suppose is an instance of Hilbert’s 10th problem and φ is computed as described as above Theorem 11. Then, φ is finitely satisfiable if and only if has a solution over .

Proof.

Suppose 𝔄φ. We claim that {u|Au𝔄|uvars()} is a satisfying assignment for . Thus, again taking e in turn, we have that if e is of the form (i) u=1, then 𝔄φe|Au𝔄|=1. If e takes the form (ii) u+v=w, we then claim that Re𝔄 is a bijection between Au𝔄Av𝔄 and Aw𝔄 having cardinality |Au𝔄|+|Av𝔄|. Indeed, by the first conjunct of φe we have that each element in Au𝔄Av𝔄 is paired with a single element in Aw𝔄; the converse is establishes by the second conjunct. Thus, clearly, |Au𝔄Av𝔄|=|Aw𝔄|. But since 𝔄ψ we have that Au𝔄Av𝔄=. This coupled with our initial assumption that uv gives us |Au𝔄Av𝔄|=|Au𝔄|+|Av𝔄| as required. Lastly, suppose e takes the form (iii) uv=w. By the first conjunct of φe for each abAu𝔄×Av𝔄 there is a single cAw𝔄 such that abcPe𝔄. Hence, Pe𝔄 gives rise to a function f:={abcabcPe𝔄(Au𝔄×Av𝔄×Aw𝔄)}. Thus, writing f(xy)=z in place of Pe(xyz), we claim that f is a bijection between Au𝔄×Av𝔄 and Aw𝔄 and has cardinality |Au𝔄||Av𝔄|. It is easily seen that f is surjective from either the second or third conjunct of φe. To establish injectivity suppose f(ab)=f(ab)=c. But, by the second conjunct of φe, we have that 𝔄,c[=1]y(Av(y)x(Au(x)f(xy)=z)), thus b=b. Notice that this establishes that b is the only element in Av𝔄 for which, under the assignment cz, by, 𝔄,cbx(Au(x)f(xy)=z). Combining this fact with the third conjunct of φe we have that, again under the assignment cz, by, 𝔄,cb[=1]x(Au(x)f(xy)=z) thus making a=a. We finish our argument by noting that |Au𝔄||Av𝔄|=|Au𝔄×Av𝔄|=|f|=|Aw𝔄| as required.

Conversely, suppose has a solution. We define π:vars() to be the satisfying assignment for and construct a model 𝔄 of φ as follows. For each variable uvars() set Au𝔄 be a set of π(u) distinct elements and set the domain of 𝔄 to be A=uvars()Au𝔄 where each Au𝔄Av𝔄= for uv. Clearly, 𝔄ψ. If φe was constructed from e of the form (i) u=1, then Au𝔄=1 as required by φe. On the other hand, if e is of the form (ii) u+v=w, we have that 𝔄φe by setting Re𝔄 to be a bijection between Au𝔄Av𝔄 and Aw𝔄 (this can be done as π(u)+π(v)=π(w) and, by initial assumption, uv). Lastly, if e is (iii) uv=w, then π(u)π(v)=π(w). Thus, index elements of Au𝔄 as a1aπ(u), elements of Av𝔄 as b1bπ(v) and elements of Aw𝔄 as (ci,j)1jπ(v)1iπ(u). Clearly, by setting Pe𝔄={aibjci,j1iπ(u),1jπ(v)} we have that 𝔄φe thus concluding the proof.

Appendix C Discussion

Theorem 18.

The (finite) satisfiability problem for (i.e. the combination of 𝒫𝒞 and 𝒪Pres2) is decidable.

Proof.

Let +1 be the +1-variable sub-fragment of . Taking some sentence φ+1 we proceed by induction on the number of variables. If +1=2, then φ is a sentence in the two-variable fragment with periodic counting which is known to have a decidable (finite) satisfiability problem [6]. Now, set +1>2 and suppose that the (finite) satisfiability problem for is decidable. We may assume (by allowing αr,βt,γr,δt to contain binary predicates of the form R(x+1,x) and R(x+1,x+1)) that φ is in normal-form (5). Defining σ to be the set of predicates of arity no more than 2, we have that if φ is satisfiable then, by Corollary 17, it is satisfiable in an -homogeneous model. Applying the variable reduction outlined in Lemmas 7 and 8 we will then have the required result.