• Keine Ergebnisse gefunden

In this section, we describe a general approach for solving the satisfiability problem for TQs which has been proposed in [BGL12; BBL15b] for DL-LTL formulas and TCQs.

We use this procedure to obtain several upper bounds. Recall that the TQ entailment problem, which we investigate in the context of TCQs, can be reduced to the satisfiability problem.

In a nutshell, the given satisfiability problem is reduced to two separate satisfiability problems—one in LTL and one in DL. In what follows, we assume Φ to be a TQ, Φpa to be its propositional abstraction, and the corresponding bijection ·pa to map the QL queries ϕ1, . . . , ϕm contained in Φ to propositions p1, . . . , pm such that pi = ϕpai for i ∈ [1, m]; we sometimes call ϕi induced by pi. For a better understanding, we first disregard the TKB.

The goal is thus to find a model of Φ. For the LTL part, we therefore look for a model W of Φpa. However, the DL part can obviously not be ignored entirely since not every model of Φpa is the propositional abstraction of a DL-LTL structure (e.g., the propositional abstraction of the EL-LTL formula Φ = A v BA(a)∧ ¬B(a) is clearly satisfiable while Φ is not). We therefore collect the worlds occurring in W in a (non-empty) setW ⊆2{p1,...,pm} to later be able to check the DL part. This is captured

Observe that the satisfiability of Φ implies the satisfiability of ΦpaW for some W. This allows to proceed as follows: choose a set W, test whether ΦpaW is satisfiable, and then

6If the variables were not disjoint, we could simply rename them. Note that this assumption also applies to Boolean UCQs.

3.2 A General Approach for Solving Satisfiability

check whether the model W can indeed be the propositional abstraction of a DL-LTL structure.

To check the latter, we consider the conjunctionVp

j∈Wϕjfor everyW ∈ W. However, the rigid names additionally make it necessary that these conjunctions are considered together and that we also consider the queries ϕj for whichpjW (e.g., the proposi-tional abstraction of Φ =A(a)∧#F¬A(a) is satisfiable while Φ is not ifA∈NRC, since every DL-LTL structure respects rigid names). To not mix up the flexible namesX oc-curring in different elements of W, we introduce copiesX(i) of them for alli∈[1,|W|];

X(i) is called the i-th copy of X. In χW, we then use queries ϕ(i)j for all j ∈ [1, m], which are obtained from the corresponding queriesϕj by replacing every occurrence of a flexible name by its i-th copy:

χW :=

k

^

i=1

^

pj∈Wi

ϕ(i)j^

pj∈Wi

¬ϕ(i)j . (3.2)

[BGL12] apply this formula for characterizing the satisfiability problem in ALC-LTL (see the claim in the proof of Lemma 4.3), and it can be easily shown that this result holds for TQs in general: The TQ Φ is satisfiable iff there is a set W ⊆2{p1,...,pm} such that ΦpaW and χW are both satisfiable.

Regarding TCQs, [BBL15b] extend this approach to the setting with a TKB. We describe this procedure next, and consider a TKB K = hO,(Ai)0≤i≤ni. As before, the task is to find a model of Φ and split into an LTL and a DL satisfiability problem.

For the former, we similarly consider the set W = {W1, . . . , Wk} ⊆ 2{p1,...,pm} and LTL formula ΦpaW. Yet, the two differences are now that the satisfiability is regarded at n—in line with the satisfiability problem for TQs w.r.t. a TKB which may contain data—and that, in addition to W, we consider a second link to the DL part: a mapping ι: [0, n] → [1, k] that maps time points to indexes from W. This mapping points out the first n+ 1 worlds, which have to be considered w.r.t. the respective ABoxes. The notion of t-satisfiability summarizes the LTL part.

Definition 3.11 (t-satisfiable)The LTL formula Φpa ist-satisfiablew.r.t. W andιif there is an LTL structure W= (wi)i≥0 such that the following hold:

wi∈ W for all i≥0,

• W, n|= Φpa,

wi=Wι(i) for all i∈[0, n]. ♦

Note that the first condition captures the second conjunct of (3.1).

For the DL part, we can similarly consider the satisfiability of a TQ of the form (3.2) w.r.t. a TKB where the ontology contains copies of the CIs in O and the ABoxes are empty, if the TQ is extended such that it encodes the ABox assertions (see also Lemma 3.7). Observe, however, that this satisfiability test does not suit data complexity investigations, because the size of both the TQ and the ontology then depends on the data given. For that reason, [BBL15b] provide the following definition of r-satisfiability (r for “rigid”) to summarize the DL part.

Definition 3.12 (r-satisfiable) The setW is r-satisfiable w.r.t. ι and K iff there are interpretations J1, . . . ,Jk,I0, . . . ,Inas follows:

• the interpretations share the same domain and respect rigid names,

• the interpretations are models of O,

• Ji is a model ofχi :=Vp

j∈WiϕjVp

j∈Wi¬ϕj for alli∈[1, k],

• Ii is a model ofAi andχι(i) for alli∈[0, n]. ♦ This definition explicitly asks for a shared domain and the consideration of rigid names.

In addition, it states k+n+ 1 TQ satisfiability problems: for the TQs χi w.r.t. hO,∅i wherei∈[1, k], and for the TQsχι(i) w.r.t.hO,Aii wherei∈[0, n]. Observe that these TQs do not contain temporal operators at all and that the TKBs are KBs as well.

The satisfiability of Φ w.r.t.K can then be decided by combining the two parts.

Lemma 3.13 ([BBL15b, Lem. 4.7]) A TQ Φ has a model w.r.t. a TKB K iff there are a set W ={W1, . . . , Wk} ⊆2{p1,...,pm} and a mapping ι: [0, n]→[1, k]such that

• Φpa is t-satisfiable w.r.t. W and ι, and

• W is r-satisfiable w.r.t. ιand K.

The original proof of Lemma 3.13 in [BBL15b] considers TCQs and the DL SHQ, but it is actually independent of both the DL and QL queries under consideration and hence also applies in our setting. In fact, regarding the empty TKB h∅,∅i, the lemma is equivalent to the result from [BGL12] stated above. Specifically, the (trivial) mapping ι: [0,0]→[1, k] can be considered to be such thatι(0) points to the indexi∈[1, k] that exists due to the t-satisfiability requirement that w0∈ W, such that we havew0 =Wi. We lastly consider an alternative characterization of r-satisfiability. As outlined above, the latter can be decided using a TQ similar to (3.2) and an ontologyOW,ι. To this end, we considercopiesα(i)of ontology axiomsαobtained from the axioms inOby replacing every occurrence of a flexible name by its i-th copy. In addition to the k worlds—or time points—already discerned, the first n+ 1 time points have to be distinguished.

This is basically because a set of assertions from some of the ABoxes may contradict a QLquery not induced by some world, and because aQLquery induced by a world may be contradicted by an assertion in one of the ABoxes (i.e., based on the assertion, the ontology may imply something contrary to what is stated in theQLquery). Lemma 3.14 captures this approach.

Lemma 3.14 ([BBL15b, Lem. 4.14]) Let QLbe such that every assertion in DL is a QL query. The set W is r-satisfiable w.r.t. ι and K iff the conjunction χW,ι of QL query literals has a model w.r.t. hOW,ι,Ai where

χW,ι:= ^

1≤i≤k

χ(i)^

0≤i≤n

χ(k+i+1)ι(i) , χ(i):= ^

pj∈Wi

ϕ(i)j^

pj∈Wi

¬ϕ(i)j , OW,ι:={α(i)|α∈ O, 1≤ik+n+ 1}, A:= [

0≤i≤n, α∈Ai

(k+i+1)}.