We study the data complexity of model-checking for logics with team semantics. For dependence and independence logic, we completely characterize the tractability/intractability frontier of data complexity of both quantifier-free and quantified formulas. For inclusion logic formulas, we reduce the model-checking problem to the satisfiability problem of so-called Dual-Horn propositional formulas. Via this reduction, we give an alternative proof for the recent result showing that the data complexity of inclusion logic is in PTIME.

see [

For the applications it is important to understand the complexity theoretic aspects of dependence logic
and its variants. During the past few years, these aspects have been addressed in several studies. We will
next briefly discuss some previous work. The data complexity of inclusion logic is sensitive to the choice
between the two main variants of team semantics: under the so-called lax semantics it is equivalent
to positive greatest fixed point logic (GFP+) and captures PTIME over finite (ordered) structures [

In [

The combined complexity of the model-checking problem of dependence logic, and many of its
variants, was recently shown to be NEXPTIME-complete [

The starting point for the present work are the following results of [

Surprisingly, the data complexity of the model-checking problem of ?1 and ?2 is already NL-complete
and NP-complete, respectively. In [

In this article our goal is to give as complete picture as possible of the tractability frontier of data complexity of model-checking of formulas of dependence, independence, and inclusion logic under the lax team semantics. In order to state our results, we define a new syntactic measure called the disjunctionwidth d?(? ) of a formula ? . Our results show that, for quantifier-free formulas ? of dependence logic, the data complexity of model-checking is in NL if d?(? ) ? 2. Surprisingly, for independence logic the case of quantifier-free formulas turns out to be more fine grained. We give a complete characterization also in this case and, in particular, exhibit a quantifier-free formula with d?(? ) ? 2 whose data-complexity is NP-complete and a seemingly maximal fragment in NL. For quantified formulas, the complexity is shown to be NP-complete already with simple formulas constructed in terms of existential quantification and conjunction in the empty non-logical vocabulary.

For inclusion logic, we show that model-checking can be reduced to the satisfiability problem of
dual-Horn propositional formulas. While interesting in its own right, this also provides an alternative
proof of the recent result of [

In this section we briefly discuss the basic definitions and results needed in this article. Definition 1. Let A be a structure with domain A, and V = {x1, . . . , xk} be a finite (possibly empty) set of variables.

? A team X of A with domain Dom(X ) = V is a finite set of assignments s : V ? A. ? For a tuple x = (x1, . . . , xn), where xi ? V , X (x) := {s(x) : s ? X } is the n-ary relation of A, where s(x) := (s(x1), . . . , s(xn)). ? For W ? V , X ? W denotes the team obtained by restricting all assignments of X to W . ? The set of free variables of a formula ? is defined as in first-order logic and is denoted by Fr(?).

We are now ready to define team semantics. As now customary, we will restrict attention to formulas
in negation normal form, and use the Lax semantics introduced in [

Definition 2. Let A be a structure, X be a team of A, and ? be a first-order formula such that Fr(? ) ? Dom(X ). lit: For a first-order literal ? , A |=X ? if and only if, for all s ? X , A |=s ? . ?: A |=X ? ? ? if and only if, there are Y and Z such that Y ? Z = X , A |=Y ? and A |=Z ? . ?: A |=X ? ? ? if and only if, A |=X ? and A |=X ? . ?: A |=X ?x? if and only if, there exists a function F : X ? P(A) \ { 0/} such that A |=X(F/x) ? , where

X (F/x) = {s(m/x) : s ? X , m ? F (s)}. ?: A |=X ?x? if and only if, A |=X(A/x) ? , where X (A/x) = {s(m/x) : s ? X , m ? A}. A sentence ? is true in A (abbreviated A |= ?) if A |={0/} ?. Sentences ? and ?? are equivalent, ? ? ??, if for all models A, A |= ? ? A |= ??.

First-order formulas satisfy what is known as the Flatness property: A |=X ?, if and only if, A |=s ? for all s ? X . Next we will give the semantic clauses for the new dependency atoms: Definition 3. ? Let x be a tuple of variables and let y be another variable. Then =(x, y) is a dependence atom, with the semantic rule

A |=X =(x, y) if and only if for all s, s? ? X , if s(x) = s?(x), then s(y) = s?(y); ? Let x, y, and z be tuples of variables (not necessarily of the same length). Then x ?y z is a conditional independence atom, with the semantic rule

A |=X x ?y z if and only if for all s, s? ? X such that s(y) = s?(y), there exists a s?? ? X such that s??(xyz) = s(xy)s?(z). Furthermore, when z is empty, we write x?y as a shorthand for x?zy, and call it a pure independence atom; ? Let x and y be two tuples of variables of the same length. Then x ? y is an inclusion atom, with the semantic rule

A |=X x ? y if and only if for all s ? X there exists a s? ? X such that s?(y) = s(x).

The formulas of dependence logic, D, are obtained by extending the syntax of FO by dependence atoms. The semantics of D-formulas is obtained by extending Definition 2 by the semantic rule defined above for dependence atoms. Independence logic, FO(?c), and inclusion logic, FO(?), are defined analogously using independence and inclusion atoms, respectively.

It is easy to see that the flatness property is lost immediately when FO is extended by any of the above dependency atoms. On the other hand, it is straightforward to check that all D-formulas satisfy the following strong Downwards Closure property: if A |=X ? and Y ? X , then A |=Y ?. Another basic property shared by all of the above logics is called Locality: A |=X ?, if and only if, A |=X?Fr(?) ?.

In this article we study the data complexity of model-checking of dependence, independence, and inclusion logic formulas. In other words, for a fixed formula ? of one of the aforementioned logics, we study the complexity of the following model-checking problem: given a model A and a team X , decide whether A |=X ?.

We assume that the reader is familiar with the basics of complexity theory. 3

In this section we consider the complexity of model-checking for quantifier-free and quantified formulas of dependence and independence logic. 3.1

The case of quantifier-free formulas
In this section we consider the complexity of model-checking for quantifier-free formulas of dependence
and independence logic. For dependence logic the problem has already been essentially settled in [

Theorem 4 ([

When two disjunctions can be used, the model checking problem becomes intractable as shown by the following results.

Theorem 5 ([

In order to give a syntactic analogue of Theorem 4, we define next the disjunction-width of a formula. Definition 6. Let ? be a relational signature. The disjunction-width of a ? -formula ? , denoted d?(? ), is defined as follows: ? 1 if ? is y ?x z or =(x, y) or x ? y ??? 0 if ? is R(x) or ¬R(x), for R ? ? ? {=} ? d?(? ) = ? max(d?(? 1), d?(? 2)) if ? is ? 1 ? ? 2 ? d?(? 1) + d?(? 2) if ? is ? 1 ? ? 2 ? ??? d?(? 1) if ? is ?x? 1 or ?? 1.

The next theorem is a syntactically defined analogue of Theorem 4.

Proposition 7. The data complexity of model-checking of quantifier-free D-formulas ? with d?(?) ? 2 is in NL.

Proof. We will first show that a formula ? with d?(?) = 1 is 2-coherent. This follows by induction using
the following facts [

It is also straightforward to check that the data complexity of a formula ? with d?(?) = 1 is in Logspace (the formula ? can be expressed in FO assuming the team X with domain x = Fr(?) is represented by the n-ary relation X (x)). We will complete the proof using induction on ? with d?(?) = 2. Suppose that ? = ? ? ?, where d?(? ) = d?(?) = 1. Then the claim follows by Theorem 4. The case ? = ? ? ? is also clear. Suppose finally that ? = ? ? ?, where ? is first-order. Note that by downward closure

A |=X ? ? A |=X? ? , where X ? = {s ? X | A 6|=s ?}. Now since X ? can be computed in Logspace, the model-checking problem of ? can be decided in NL by the induction assumption for ? .

In this section we examine potential analogues of Theorems 4 and 5 for independence logic. It is
well-known that the dependence atom =(x, y) is logically equivalent to the independence atom y ?x y.
Hence, the following is immediate from Theorem 5 [

Corollary 8. The model checking problem for formula

y ?x y ? v ?z v ? v ?z v is NP-complete.

For independence logic, the situation is not as clear, in particular concerning tractability. In the following we will exhibit a fragment of independence logic whose data complexity is in NL and which is in some sense the maximal such fragment.

Definition 9. The Boolean closure of an independence atom by first-order formulas, denoted BC(?, FO), is defined as follows: ? Any independence atom x ?y z is in BC(?, FO). ? If ? ? BC(?, FO), then for any formula ? ? FO, ? ? ? and ? ? ? are in BC(?, FO).

Let ? ? BC(?, FO). Up to permutation of disjunction and conjunction, ? can be put into the following normalized form:

? ? ((. . . ((x ?z y ? ?1) ? ?1) ? . . . ) ? ?k) ? ?k Let A be any structure, C+ = Tik=1 ?i(A) and C? = Si=1 ?i(A), where, ?i(A) is the set of assignk ments s : Fr(? ) ? A such that A |=s ?i. We can restate the fundamental property for satisfiability of an independence atom in a team (and a structure) to tackle the case of BC(?, FO) formulas. It holds that, for any ? ? BC(?, FO), any team X and structure A, A |=X ? if and only if: ? for all s ? X : either s ? [((..(?1 ? ?2) ? . . . ) ? ?k) ? ?k](A) or s ? C+, s 6? C? and ? for all s1, s2 ? X such that s1, s2 ? C+, s1, s2 6? C?, and s1(z) = s2(z), there exists s3 ? X such that: s3(z) = s1(z), s3(x) = s1(x) and s3(y) = s2(y).

The first item is true by exhaustive case distinction. The second one comes from the fact that if a tuple s satisfies s ? C+ and s 6? C? then it is forced to be in the sub-team satisfying x ?z y.

In the rest of the paper, assignments s1, s2 as in the second item will be said compatible for formula ? and team X and s3 is called a witness of s1, s2 (for formula ? ).

Since checking whether a tuple s belongs to the query result ?(A) of a first-order formula can be done in logarithmic space, deciding whether A |=X ? is in Logspace. The following tractability result can be obtained.

Theorem 10. The data complexity of the model checking problem for formulas of the form ? 1 ? ? 2 with ? 1,? 2 ? BC(?, FO) is in NL.

Proof. The proof is given by a Logspace reduction to the satisfiability problem of 2-CNF formulas which is well-known to be in NL. Given a structure A and a team X we construct a 2-CNF propositional formula ? such that:

A |=X ? 1 ? ? 2 ?? ? is satisfiable. (1)

Recall that if a team X is such that A |=X ? 1 ? ? 2 then, there exists Y, Z ? X such that Y ? Z = X and A |=Y ? 1 and A |=Z ? 2. For each assignment s ? X , we introduce two Boolean variables Y [s] and Z[s]. Our Boolean formula ? will be defined below with these 2|X | variables the set of which is denoted by Var(?). It will express that the set of assignments must split into Y and Z but also make sure that incompatible assignments do not appear in the same subteam.

For each pair si, s j that are incompatible for ? 1 on team X , one adds the 2-clause: ¬Y [si] ? ¬Y [s j]. The conjunction of these clauses is denoted by CY . Similarly, for each pair si, s j that are incompatible for ? 2 on team X , one adds the clause: ¬Z[si] ? ¬Z[s j] and call CZ the conjunction of these clauses.

Finally, the construction of ? is completed by adding the following conjunction:

C ? ^ Y [s] ? Z[s].

s?X

It is not hard to see, due to the remark on compatible pairs, that the formula ? ? C ? CY ? CZ can be built in Logspace. It remains to show that the equivalence (1) holds.

Assume that the left-hand side of the equivalence holds. Then, there exists Y, Z ? X such that Y ? Z = X , A |=Y ? 1 and A |=Z ? 2. We construct a propositional assignment I : Var(?) ? {0, 1} as follows. For all s ? Y , we set I(Y [s]) = 1 and for all s ? Z, we set similarly I(Z[s]) = 1.

Let us consider a clause ¬Y [si] ? ¬Y [s j] for incompatible si, s j. Then, I(Y [si]) = 0 or I(Y [s j]) = 0 must hold. For a contradiction, suppose that I(Y [si]) = I(Y [s j]) = 1. Then since A |=Y ? 1 holds, by construction si and s j must be compatible for ? 1. Hence we get a contradiction and may conclude that I satisfies ¬Y [si] ? ¬Y [s j]. The situation is similar for each clause ¬Z[si] ? ¬Z[s j]. Finally since X = Y ? Z, I also satisfies C.

Let us then assume that ? is satisfiable, and let I : Var(?) ? {0, 1} be a satisfying assignment for ?. Since I |= C, we get that I(Y [s]) = 1 or I(Z[s]) = 1 for all s ? X . Let

XY = {s : I(Y [s]) = 1} and XZ = {s : I(Z[s]) = 1}.

Note that XY ? XZ = X . We will next show how the sets XY and XZ can be extended to sets Y and Z such that A |=Y ? 1 and A |=Z ? 2. Note first that, since I satisfies ?, for all s1, s2 ? XY , ? cannot have a clause of the form ¬Y [s1] ? ¬Y [s2], and hence s1, s2 are compatible for ? 1. Analogously we see that all s1, s2 ? XZ are compatible for ? 2. We will define the sets Y and Z incrementally by first initializing them to XY and XZ, respectively. Note that even if XY ? XZ = X , no decision has been made regarding the membership of assignments s in Y (resp. Z) such that I(Y [s]) = 0 (resp. I(Z[s]) = 0). Let us first consider Y . Until no changes occur, we consider all pairs s1, s2 ? Y such that s1(z) = s2(z) and add into Y (if they are not already in) all tuples s3 ? X such that s3 is a witness for the pair (s1, s2) regarding property ? 1. Since by construction s1, s2 are compatible then at least one such s3 exists (but may be out of Y till now). We prove below that this strategy is safe. First of all, it is easily seen that any pair among {s1, s2, s3} is compatible for ? 1. Therefore, it remains to show that the new assignments s3 are compatible with every other element s added to Y so far. Suppose this is not the case and that there exists s ? Y \ {s1, s2} such that s3 and s are incompatible for ? 1. In passing one must have s3(z) = s(z). Since s1, s2, and s are in Y they are all pairwise compatible. Hence, there exists t1 such that t1 is a witness for the pair (s1, s).

Then, t1(x) = s1(x) = s3(x), and t1(y) = s(y). Consequently, t1 is also a witness for s3, s hence, s3 and s are compatible which is a contradiction. Therefore, the assignment s3 can be safely added to Y . The set Z is defined analogously. By the construction, it holds that A |=Y ? 1 and A |=Z ? 2.

We will next show that a slight relaxation on the form of the input formula immediately yields intractability of model-checking.

Theorem 11. The exists a formula ? 1 ? ? 2 such that ? 1 ? BC(?, FO) and ? 2 is the conjunction of two independence atoms whose model-checking problem is NP-complete.

Proof. Define ? 1 ? w 6= 1 ? x ?t y, ? 2 ? c1 ?c c2 ? x ?z y. We will reduce 3-SAT to the modelchecking problem of ? 1 ? ? 2. Let ? = Vin=1 Ci be a 3-SAT instance. Each Ci = pi1 ? pi2 ? pi3 with pi1 , pi2 , pi3 ? { v1, . . . , vm, ¬v1, . . . , ¬vm }. To this instance we associate a universe A and a team X on the variables w, c, c1, c2, z, x, y,t. The structure A is composed of m new elements a1, . . . , am and of { v1, . . . , vm, ¬v1, . . . , ¬vm } ? { 0, 1 }. For each clause Ci we add in X the 6 assignments displayed on the left below, and for each variable vi, we add to X the 2 assignments on the right: w c c1 c2 0 i 0 i 0 i 1 i 1 i 1 i We will next show that ? is satisfiable if and only if A |=X ?.

? Suppose there is an assignment I : { v1, . . . , vm } ? {0, 1} that evaluates ? to true, i.e., at least one literal in each clause is evaluated to 1. We have to split X into two sub-teams X = Y ? Z such that A |=Y (w 6= 1 ? x ?t y) and A |=Z (c1 ?c c2 ? x ?z y). We must put every assignment s ? X such that s(w) = 1 in Z. There are exactly three such assignments per clause. We put in Z every assignment s such that s(x) = vi if I(vi) = 1, and s(x) = ¬vi if I(vi) = 0. The other assignments are put into Y .

For each clause Ci, one literal pi1 , pi2 , pi3 is assigned to 1 by I. Then there is at least one assignment s(c, c1, c2) = (i, 1, 1) in Z. In Z, the assignments mapping c to i map (c, c1, c2) to (i, 1, 1), (i, 1, 0), (i, 0, 1) or (i, 0, 0). Thus A |=Z c1 ?c c2. If s1, s2 ? Z are such that s1(z) = s2(z) = i, then s1(x) (analogously s2(x)) is vi if I(vi) = 1, ¬vi otherwise. Therefore, s1(x) = s2(x) = s1(y) = s2(y), and hence A |=Z x ?z y holds.

As for Y , it is immediate that A |=Y w 6= 1. The only pair of assignments s1, s2 in X such that s1(t) = s2(t) are (0, 0, 0, 0, i, vi, vi, ak) and (0, 0, 0, 0, i, ¬vi, ¬vi, ak). Only one of them is in Y (s1 if I(vi) = 1, s2 otherwise). Thus A |=Y x ?t y. ? Suppose then that X = Y ? Z such that A |=Y (w 6= 1 ? x ?t y) and A |=Z (c1 ?c c2 ? x ?z y). Define an assignment I of the variables of ? by: I(vi) = 1 if sti := (0, 0, 0, 0, i, vi, vi, ak) is in Z, I(vi) = 0 if sif := (0, 0, 0, 0, i, ¬vi, ¬vi, ak) is in Z. Since A |=Z x ?z y, sif (z) = sti(z) and because there is no s? ? X such that s?(x) = sif (x), s?(y) = sti(y) and s?(z) = sif (z), for each i at most one of sif , sti can be in Z. Similarly, because A |=Y x ?t y, only one of them can be in Y . Thus I is indeed a function. Since A |=Z x ?z y and there is no assignment in X such that (x, y) 7? (vi, ¬vi), every pair s1, s2 ? Z such that s1(z) = s2(z) = i must have the same value of x and y. Every assignment representing a clause in Z respects the choice of I. Furthermore, since A |=Z c1 ?c c2 and (w, c, c1, c2) 7? (1, i, 0, 0), (1, i, 1, 0), (1, i, 0, 1) are in Z, (1, i, 1, 1) must be in Z, i.e., at least one assignment per clause is in Z. By the above we may conclude that I satisfies ?: at least one literal per clause is evaluate to 1 by I.

Hardness result of Proposition 8 concerns conditional independence atoms. We prove an analog for the case of pure independence below.

Theorem 12. The model checking problem is NP-complete for formula ? of the form ? ? (x ? y) ? (x ? y) ? (x ? y) ? x 6= y Proof. Let G = (VG, EG) be a graph, A = VG be a first order structure of the empty signature, and X be the team X = { (v, v) | v ? VG } ? { (v1, v2), (v2, v1) | (v1, v2) ? EG } (we write an assignment s with s(x) = v1 and s(y) = v2 succinctly as (v1, v2)). We are going to show that G has a 3-clique cover if and only if A |=X ?.

? Suppose that G has a 3-clique cover, i.e., there exists C1,C2,C3 three cliques such that VG = VC1 ? VC2 ? VC3 . We have to prove A |=X ?. For i ? { 1, 2, 3 }, let

Xi = { (v, v) | v ? Ci } ? { (v1, v2), (v2, v1) | v1, v2 ? Ci } and X4 = X \ (X1 ? X2 ? X3).

Because it is a vertex cover, every assignment of the form (v, v) is contained in X1 ? X2 ? X3 and not in X4, i.e. A |=X4 x 6= y.

Let i ? { 1, 2, 3 } and s, s? ? Xi be two assignments. If s(x, y) = (v, v) and s?(x, y) = (v?, v?), then v, v? ? Ci and there exists two assignments s1, s2 in Xi such that s1(x, y) = (v, v?) and s2(x, y) = (v?, v) by construction. Similarly if s(x, y) = (v, v) and s?(x, y) = (v1, v2), there exists in Xi the assignments (v, v2) and (v1, v) (even if v1 = v or v2 = v). Finally, if s(x, y) = (v1, v2) and s?(x, y) = (v?1, v?2), the assignments (v1, v1), (v2, v2), (v?1, v?1), (v?2, v?2) are in Xi and so are (v1, v?2), (v?1, v2). The above implies that A |=Xi x ? y. ? Suppose that A |=X (x ? y) ? (x ? y) ? (x ? y) ? x 6= y, then X = X1 ? X2 ? X3 ? X4 such that A |=Xi x ? y for i ? { 1, 2, 3 } and A |=X4 x 6= y. For i ? { 1, 2, 3 } let Ci be the graph whose vertices are { v | (v, v) ? Xi } and edges are

{ (v1, v2) | (v1, v2) ? Xi and (v2, v1) ? Xi }.

Note that some Ci can be empty but they form a vertex cover of G as no assignment (v, v) is in X4. If v, v? ? Ci then (v, v) and (v?, v?) are in Xi. By independence, (v, v?) and (v?, v) are also in Xi. Therefore the edge (v, v?) is in Ci: Ci is a clique. Therefore, G is covered by the three disjoint cliques C1? = C1, C2? = C2/C1 and C3? = C3/(C1 ? C2). In this section we show that existential quantification even without disjunction makes the model checking problem hard for both dependence and independence logic.

Theorem 13. There is a formula ? of dependence logic of empty non-logical vocabulary build with ? and ? whose model-checking problem is NP-complete.

Proof. Define the formula ? as follows:

? ? ?x=(x, r1, r2, e, m) ? =(v1, v2, x) .

We will reduce the problem of determining whether a graph G with n2 vertices is n-colorable to the model-checking problem of ?. This graph problem is easily seen to be NP-complete.

Let G be a graph with n2 vertices VG = {?0, . . . ,?n2?1}, A = {0, . . . , n ? 1} a first order structure of the empty signature and X = {sij | i ? {0, . . . , n2 ? 1}, 0 ? j ? i} be a team such that : ? sij(v1) = ?i/n? and sij(v2) = i mod n. In other words, sij(v1, v2) is the decomposition of i in base n. ? sij(r1) = ? j/n? and sij(r2) = j mod n. In other words, sij(r1, r2) is the decomposition of j in base n. ? sij(m) = 0 if i 6= j and sii(m) = 1. ? sii? (e) = 1, if i? = i, or if there is an edge between ?i and ?i? with i? > i. Otherwise sii? (e) = 0.

For example, for n = 2 and EG = {(0, 1); (1, 2); (0, 2); (2, 3)}, we obtain the following team on the universe A = {0, 1}:

G is n-colourable iff A |=X ? We are going to demonstrate that A |=X ? if and only if G is n-colourable.

First the left to right implication. Since A |=X ? there exists a mapping F : X ? P(A) \ { 0/} such that A |=X(F/x) =(x, r1, r2, e, m) ? =(v1, v2, x). By downwards closure, we may assume without loss of generality that F (s) is a singleton for all s ? X . Since =(v1, v2, x) holds, F induces a mapping F? : VG ? A, by F?(?i) = si0(x). If there is an edge between ?i and ?i? , i? > i, then sii? (e) = 1 = sii(e). Furthermore, si? (r1, r2) = sii(r1, r2) = i but sii? (m) = 0 and sii(m) = 1 Therefore, because the atom =(x, r1, r2, e, m) holds, i we must have si? (x) 6= sii? (x) (and F?(?i) 6= F?(?i? )) if there is an edge between ?i and ?i? . Thus F? is a i colouring of G with |A| = n colours.

Let us then consider the right to left implication. Let c : VG ? {0, . . . , n ? 1} be an n colouring. We extend X to variable x with a new team X ? such that sij(x) = c(?i). The value of x depends only on i, which is encoded in (v1, v2), i.e., A |=X? =(v1, v2, x).

Let sij, sij?? be two assignments of X ?. Suppose that sij(r1, r2, e) = sij?? (r1, r2, e) but sij(m) 6= sij?? (m). In ? this case we must check that sij(x) is different from sij? (x) (because A |=X? =(x, r1, r2, e, m)). Now it holds that j = j? because sij(r1, r2) = sij?? (r1, r2). Furthermore, since sij(m) 6= sij?? (m), either i = j or i? = j?. Let ? us suppose i = j. Because 1 = sii(e) = sij(e) = sij? (e) = sii? (e), there is an edge between ?i and ?i? in G. Therefore c(i) 6= c(i?) and sij(x) 6= sij?? (x).

By encoding dependence atoms in terms of conditional independence atoms we get the analogous results for free for independence logic.

Corollary 14. There is a formula ? of independence logic of empty non-logical vocabulary build with ? and ? whose model-checking problem is NP-complete.

We end this section by noting that existential quantifiers cannot be replaced by universal quantifiers in the above theorems.

Proposition 15. The model-checking problem for formulas of dependence or independence logic using only universal quantification and conjunction is in Logspace.

Proof. We first transform ? into prenex normal-form exactly as in first-order logic [

?x1 . . . ?xn ^?i(x1, . . . , xn, y1, . . . , ym),
where ?i is either a first-order, dependence, or independence atom. Let A be a model, and X be a
team of A with domain {x1, . . . , xn, y1, . . . , ym}. As in [

A |=X ^?i(x1, . . . , xn, y1, . . . , ym) ? (A, X (x, y)) |= ? .

Since X (x, y) is a first-order definable extension of X (y) it is clear that we can construct a FO-sentence ? ? such that

A |=X ?x ^?i(x, y) ? (A, X (y)) |= ? ?, holds for all structures A and teams X with domain {y1, . . . , ym}. The claim follows from the fact that the data complexity of FO is in Logspace.

In this section we show that the model-checking problem of inclusion logic formulas can be reduced to the satisfiability problem of dual-Horn propositional formulas. A propositional formula ? in conjunctive normal form is called dual-Horn if each of its clauses contain at most one negative literal.

For a team X , x = {xi1 , ..., xin } ? dom(X ), and s ? X , we denote by s(x) the restriction of s to the variables xi1 , ..., xin . In this section, ? denotes a relational signature.

Proposition 16. There exists an algorithm which, given ? ? FO(?), a structure A over ? , and a team X such that ? ? dom(X ), outputs a propositional formula ? in dual-Horn form such that: A |=X ? ?? ? is satisfiable. Furthermore, when ? is fixed, the algorithm runs in logarithmic space in the size of A and X .

Proof. Let ? , A, X be as above and rX = |dom(X )|. For any team X , we will consider the set X of propositional variables X [s] for s ? ArX . Starting from ? , A, and X we decompose step by step formula ? into subformulas (until reaching its atomic subformulas) and different teams Y , Z, ... and control the relationships between the different teams by propositional dual-Horn formulas built over the propositional variables issued from X ,Y, Z, ..... Let S = {(? , X , rX )} and C = {X [s] : s ? X } ? {¬X [s] : s 6? X }. The propositional formula ? is now constructed inductively as follows.

As long as S 6= 0/, we apply the following rule: Pick (? , X , r) in S and apply the following rules. ? If ? is R(x) with R ? ? then: S := S \{(? , X , r)} and C := C ? {X [s] ? R(s(x)) : for all s ? Ar}.

Clearly, it holds that A |=X R(x) iff Vs(x)6?R ¬X [s] is satisfiable. ? If ? is x ? y then: S := S \{(? , X , r)} and

C := C ? {X [s] ? Ws??Ar,s?(y)=s(x) X [s?] : s ? Ar}.

It holds that A |=X x ? y iff Vs?Ar (X [s] ? Ws??Ar,s?(y)=s(x) X [s?]) is satisfiable. ? If ? is ?x? , then: S := (S \{(? , X , r)}) ? {(? ,Y, r + 1)}and

C := C ? {X [s] ? Ws?=(s,a), a?A Y [s?] : s ? Ar}, where the Y [s], s ? Ar+1 are new propositional variables (not used in C ). If A |=X ?x? then, there exists a function F : X ? P(A) \ { 0/}, such that A |=X(F/x) ? . In other words, A |=Y ? for some team Y defined by the solutions of the constraint Vs?Ar X [s] ? Ws?=(s,a), a?A Y [s?] (which define a suitable function F). Conversely, if A |=Y ? for a team Y as above defined from X , then clearly A |=X ?x? . ? If ? is ?x? , then: S := (S \{(? , X , r)}) ? {(? ,Y, r + 1)} and

C := C ? {X [s] ? Y [s?] : s ? Ar, s? ? Ar+1 s.t. s?(x) = s(x)}, where the Y [s], s ? Ar+1 are new propositional variables (not used in C ). The conclusion is similar as for the preceding case. ? If ? is ?1 ? ?2 then: S := (S \{(? , X , r)}) ? {(?1, X , r), (?2, X , r)} and C is unchanged. By definition, A |=X ? iff A |=X ?1 ? ?2. ? If ? is ?1 ? ?2 then: S := (S \{(? , X , r)}) ? {(?1,Y, r), (?2, Z, r)} and where again the Y [s] and Z[s], s ? Ar are new propositional variables (not used in C ). Here again, A |=X ? if and only if A |=Y ?1 and A |=Z ?2 for some suitable Y and Z such that Y ? Z = X which is exactly what is stated by the Boolean constraints.

Observe that each new clause added to C during the process is of dual-Horn form, i.e., contains at most one negative literal. Observe also, that applied to some (? , X , r), the algorithm above only adds triples S whose first component is a proper subformula of ? and eliminates (? , X , r). When the formula ? is atomic, no new triple is added afterwards. Hence the algorithm will eventually terminate with S = 0/. Setting ? := VC?C C, it can easily be proved by induction that: A |=X ? iff ? is satisfiable.

Observe also that each clause in C can be constructed from X and A by simply running through their elements (using their index) hence in logarithmic space.

Remark 1. The construction of Proposition 16 can be done in principle for any kind of atom: dependence, independence, exclusion, constancy etc. To illustrate this remark, one could translate in the above proof a dependence atom of the form =(x, y) by (using the notations of the proof):

^ s,s??Ar s(x)=s?(x)?s(y)6=s?(y)

(¬X [s] ? ¬X [s?]).

The additional clauses are of length two. A similar treatment can be done for independence atoms x ?y z. In the two cases however, the resulting formula is not in Dual-Horn form anymore and there is no way to do so (unless PTIME = NP).

Since deciding the satisfiability of a propositional formula in dual-Horn form can be done in polynomial time we obtain the following already known corollary.

Corollary 17. The data complexity of FO(?) is in PTIME. 5

We have studied the tractability/intractability frontier of data complexity of both quantifier-free and quantified dependence and independence logic formulas. Furthermore, we defined a novel translation of inclusion logic formulas into dual-Horn propositional formulas, and used it to show that the data-complexity of inclusion logic is in PTIME. It is an interesting open question whether the translation of Proposition 16 can be generalized to hold for some interesting extensions of FO(?) by further dependency atoms.

The authors would like to thank Arne Meier for a number of corrections and useful suggestions. The second author was supported by the Academy of Finland grant 264917.