<?xml version="1.0" encoding="UTF-8"?>
<TEI xml:space="preserve" xmlns="http://www.tei-c.org/ns/1.0" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://www.tei-c.org/ns/1.0 https://raw.githubusercontent.com/kermitt2/grobid/master/grobid-home/schemas/xsd/Grobid.xsd"
 xmlns:xlink="http://www.w3.org/1999/xlink">
	<teiHeader xml:lang="en">
		<fileDesc>
			<titleStmt>
				<title level="a" type="main">From EL to Tractable Existential Rules with Complex Role Inclusions</title>
			</titleStmt>
			<publicationStmt>
				<publisher/>
				<availability status="unknown"><licence/></availability>
			</publicationStmt>
			<sourceDesc>
				<biblStruct>
					<analytic>
						<author>
							<persName><forename type="first">Michaël</forename><surname>Thomazo</surname></persName>
							<affiliation key="aff0">
								<orgName type="institution">University Montpellier</orgName>
							</affiliation>
						</author>
						<title level="a" type="main">From EL to Tractable Existential Rules with Complex Role Inclusions</title>
					</analytic>
					<monogr>
						<imprint>
							<date/>
						</imprint>
					</monogr>
					<idno type="MD5">7B870244612696BE47422A1C9D71A522</idno>
				</biblStruct>
			</sourceDesc>
		</fileDesc>
		<encodingDesc>
			<appInfo>
				<application version="0.7.2" ident="GROBID" when="2023-03-24T23:09+0000">
					<desc>GROBID - A machine learning software for extracting information from scholarly documents</desc>
					<ref target="https://github.com/kermitt2/grobid"/>
				</application>
			</appInfo>
		</encodingDesc>
		<profileDesc>
			<abstract>
<div xmlns="http://www.tei-c.org/ns/1.0"><p>Ontology-based data access consists in using ontologies while querying data. Due to the high complexity of this problem, considering lightweight description logics like EL is especially relevant. Another strand of research is based on existential rules. In this paper, we use this latter formalism in order to cover EL with the same complexity of reasoning while allowing any predicate arity and some cycles on variables. We then add complex role inclusions to enhance expressivity, while staying polynomial in data complexity and generalizing existing results. In particular, we consider transitivity and right/left identity rules, which do not behave well with respect to usual decidability paradigms.</p></div>
			</abstract>
		</profileDesc>
	</teiHeader>
	<text xml:lang="en">
		<body>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="1">Introduction</head><p>Ontology-based data access (OBDA) recently received a lot of attention both from knowledge representation and database communities. This problem can be stated as follows: given a set of facts and an ontology (the knowledge base), one wants to evaluate a conjunctive query against this knowledge base. The ontology can be represented in several ways. Traditional ontology languages are description logics (DLs, <ref type="bibr" target="#b3">[4]</ref>). The original focus of DL research was the ontology in itself, with problems like satisfiability or subsumption between concepts. The conjunctive query answering problem has been considered more recently. Classical DLs appeared to be highly complex for that reasoning problem, and lightweight description logics (such as EL and DL-Lite) are thus very relevant.</p><p>A parallel approach relies on existential rules <ref type="bibr" target="#b4">[5,</ref><ref type="bibr" target="#b5">6]</ref>, also known as TGDs <ref type="bibr" target="#b0">[1]</ref> that form the basis of Datalog ± <ref type="bibr" target="#b7">[8]</ref>. Existential rules are logical formulas of the form B → H, where B and H are conjunctions of atoms and where H might contain existentially quantified variables. In contrast to DLs, they allow for any predicate arity (which in particular eases the integration with database systems in which relations are naturally translated into n-ary predicates) and can express some cyclic dependencies on variables. On the other hand, neither disjunction nor negation is expressible with existential rules. Interestingly, the two main families of DLs that have been designed for conjunctive query answering can be translated into existential rules. The associated ontology-based conjunctive query answering problem (CQA) is formalized as follows: given a set of facts (in their logical form an existentially closed conjunction of atoms) F, a set of rules R, and a conjunctive query Q, check whether F, R | = Q hold. This problem is undecidable, and numerous restrictions on R have been proposed recently in order to ensure decidability (see <ref type="bibr" target="#b11">[12]</ref> for a survey), which is usually proven by means of one of the two following mechanisms, or a combination of both. The first one is forward chaining: rules are iteratively applied to F, until either no new information is added, or the query is entailed. If a set of rules is such that for any fact, this process halts in finite time or generates a set of facts of bounded treewidth (which is defined on a graph naturally associated with the facts, see e.g. <ref type="bibr" target="#b5">[6]</ref>), then the CQA problem is decidable ( <ref type="bibr" target="#b6">[7,</ref><ref type="bibr" target="#b4">5]</ref>). The second mechanism is backward chaining: a query Q is rewritten into a set of conjunctive queries (which can be seen as a union of conjunctive queries), such that Q is entailed by F and R if and only if one its rewritings is entailed by F. The CQA problem is decidable if the set of rewritings is finite for any query.</p><p>EL <ref type="bibr" target="#b1">[2,</ref><ref type="bibr" target="#b10">11]</ref> is one of the description logics that have a reasonable complexity for CQA: NP-complete in combined complexity and Ptime-complete in data complexity. As pointed out before, any EL TBox can be translated into existential rules. However, the smallest known Datalog ± decidable class covering such rules is a class for which CQA complexity is much higher than the original one (2-Exptime-complete in combined complexity). Finally, it is known that one can add to EL inclusions a special kind of complex role inclusions while keeping polynomial data complexity <ref type="bibr" target="#b9">[10]</ref>. As far as we know, such results have no counter-part in the rule framework. Moreover, one of the most used complex role inclusion, namely transitivity, is out of the scope of known decidability criteria when combined with decidable classes of existential rules.</p><p>The contribution of this paper is two-fold:</p><p>first, it presents a class of existential rules, namely orientable fr1, that covers EL ontologies while keeping the same (data or combined) complexity for CQA (Theorem 1). The proposed class allows for predicates of arbitrary arity and a form of cyclic dependencies between variables; second, it generalizes this class by adding complex role inclusions while staying polynomial in data complexity (Theorem 2); it allows for left and right identity rules, which have been proven useful for modeling purposes <ref type="bibr" target="#b2">[3]</ref>. The syntactic regularity condition enforced is close from the one imposed in Horn-SROIQ ( <ref type="bibr" target="#b8">[9]</ref>).</p><p>In Section 2, basic definitions about EL and existential rules are recalled. In Section 3, orientable fr1 rules are introduced. Section 4 adapts the algorithm presented in <ref type="bibr" target="#b12">[13]</ref> and designed for a more general existential rule class, yielding an easier and worst-case optimal algorithm for orientable fr1 rules. This algorithm is further modified in Section 5 in order to take some complex role inclusions into account. Section 6 concludes the paper.</p><p>In this paper, we will avoid technical definitions and rely on examples, to provide an intuition about the main techniques.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2">Preliminaries</head><p>We briefly recall the preliminary definitions presented in <ref type="bibr" target="#b5">[6]</ref>. An atom is of the form p(t 1 , . . . , t k ) where p is a predicate with arity k, and the t i are terms, i.e., variable or constants. A fact is the existential closure of a conjunction of atoms. <ref type="foot" target="#foot_0">1</ref> An existential rule (or simply a rule when not ambiguous) is a formula R = ∀x∀y(B[x, y] → (∃zH[y, z])) <ref type="foot" target="#foot_1">2</ref>where B = body(R) and H = head(R) are finite conjunctions of atoms, called the body and the head of R, respectively. The frontier of R, denoted by fr(R), is the set of variables vars(B) ∩ vars(H) = y. A rule R is applicable to a fact F if there is a homomorphism π from body(R) to F; the result of the application of R on F w.r.t. π is a fact α(F, R, π) = F ∪ π safe (head(R)) where π safe is a substitution of head(R), that replaces each x ∈ fr(R) with π(x), and each other variable with a "fresh" variable, i.e., not introduced before. The direct saturation of F with R is defined as</p><formula xml:id="formula_0">α(F, R) = F ∪ (R=(H,C),π)∈Π(F,R) π safe (C), where Π(F, R) = {(R, π) | R = (B, H) ∈ R and π is a homomorphism from H to F}. The k saturation of F with R is denoted by α k (F, R) and is such that: α 0 (F, R) = F, and for i &gt; 0, α i (F, R) = α(α i−1 (F, R), R). The universal model of F and R is the union of α k (F, R) for k ∈ N. Q is entailed by F and R iff it is entailed by α k (F, R) for some k ∈ N (i.e.</formula><p>, by the universal model of F and R).</p><p>An EL TBox contains concept inclusions C 1 C 2 , where C 1 and C 2 are concepts built as follows:</p><formula xml:id="formula_1">C := | A | C 1 C 2 | ∃R.C</formula><p>Any EL ontology can be translated into a set of existential rules (which are called EL-rules), where</p><formula xml:id="formula_2">C 1 C 2 is translated into φ(C 1 )(x) → φ(C 2 )(x)</formula><p>, with φ inductively built as explained Table <ref type="table" target="#tab_0">1</ref>. The smallest known decidable class covering rules needed for the translation of an arbitrary EL TBox is the set of frontier-1 (fr1) rules, i.e., the set of rules whose body and head share exactly one variable. </p><formula xml:id="formula_3">EL concept Logical translation φ A A(x) C 1 C 2 φ(C 1 )(x) ∧ φ(C 2 )(x) ∃R.C r(x, y) ∧ φ(C)(y)</formula><p>3 Orientable fr1 Rules</p><p>However, the combined complexity of reasoning with fr1 rules and EL is quite different: 2-Exptime-complete in the former case, and NP-complete in the latter -though both are in Ptime for data complexity. In this section, we present a class of rules that covers EL while keeping the same combined and data complexities. EL-rules have the following idiosyncrasy: they add information "below" the frontier of the rule, as pictured in Figure <ref type="figure">1</ref>. Any EL-rule mapping its frontier to x 1 will map its body to dashed atoms, and will create atoms that are also below x 1 . This is due to the fact that information about a term "above" x 1 is not even expressible, since no inverse role is possible. Orientable fr1 rules generalize this idea.</p><p>We define for every predicate r of arity k a strict total order on its positions r 1 , . . . , r k . We denote by &lt; the union of all these relations. Given such a strict partial order, we can associate a directed graph with each set of atoms.</p><p>• a</p><formula xml:id="formula_4">• • y 1 • • x 1 x 2 x 3</formula><p>Fig. <ref type="figure">1</ref>. An arc is directed from the first to the second argument of an atom.</p><p>Definition 1 (&lt;-graph associated with a set of atoms). Let A be a set of atoms. The &lt;-graph associated with A is the directed graph defined as follows:</p><p>to each term x appearing in A, we assign a vertex v x , for any x, y such that x y and x and y appear in the same atom with position p x &lt; p y , there is an arc from v x to v y (note that no loop can occur).</p><p>Intuitively, a rule is oriented for an order &lt; if the atoms needed to trigger it as well as the atoms created by it are situated both in the same right direction according to &lt;. Definition 2 (&lt;-oriented fr1 rule). Let R be a rule and &lt; a strict total order on the position of its predicates. R is &lt;-oriented fr1 if it is fr1 and if the &lt;-graph associated with body(R) ∪ head(R) is a directed acyclic graph such that there is a path from fr(R) to any other node.</p><p>Given this notion of rule orientation, we naturally define the notion of orientable fr1 set of rules. Definition 3 (Orientable fr1 set of rules). A set of rules R is orientable fr1 (or simply orientable when not ambiguous) if there exists an order &lt; such that every rule of R is &lt;-oriented fr1.</p><p>Example 1 (Orientable fr1 set of rules). Let us take R = {r(x, y) ∧ p(y) → q(x, z, t) ∧ s(z, t); q(x, y, z) ∧ s(y, z) → r(x, t) ∧ r(t, t) ∧ p(t)}. By taking r 1 &lt; r 2 , s 1 &lt; s 2 and q 1 &lt; q 2 &lt; q 3 , we can easily check that this set of rules is &lt;-oriented. Note that these rules are not translatable in EL because of the predicate of arity 3 and of cycles.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>Property 1 (Recognizability problem)</head><p>The problem of deciding whether a set of rules R is orientable is NP-complete.</p><p>The hardness result comes from a reduction of 3-SAT. NP-hardness of the recognizability problem might impede the practical applicability of following results. However, this complexity remains quite small compared to the combined complexity of CQA with a lot of known classes, and, more importantly, even strongly restricted sets of orientable rules are still of interest. Indeed, the next property shows that rules translating EL ontologies are very naturally oriented (with R 1 &lt; R 2 for any role R).</p><p>Property 2 (Generalization of EL) Any set of EL-rules is orientable.</p><p>In the next examples, we assume for all predicate p that p i &lt; p j if and only if i &lt; j.</p><p>In this section, we present a forward chaining algorithm which is a simplified version of the algorithm introduced in <ref type="bibr" target="#b12">[13]</ref> for a class of rules called greedy bounded treewidth set, which includes fr1. While performing forward chaining, a greedy tree decomposition (of bounded width) of the currently generated fact is maintained. We call bags the nodes of this tree, which is built as follows: the root of this tree contains all atoms in F, and each time a rule with frontier f is applied by means of a homomorphism π, we create a new bag that contains the newly generated atoms, and choose as its pBarent the root of the tree if π( f ) is a constant or a variable of F, otherwise the bag in which the variable π( f ) has been generated.</p><p>Example 2 (Greedy tree decomposition). Let F = {p(a), q(a)} and R = {R 1 : p(x) → r(x, y) ∧ q(y); R 2 : q(x) → t(x, y) ∧ p(y)}. We show the greedy tree decomposition of α 4 (F, R) in Figure <ref type="figure">2</ref>. p(a), q(a) r(a, x 1 ), q(x 1 ) t(a, y 1 ), p(y 1 )</p><formula xml:id="formula_5">t(x 1 , x 2 ), p(x 2 ) r(y 1 , y 2 ), q(y 2 )</formula><p>r(x 2 , x 3 ), q(x 3 )</p><formula xml:id="formula_6">t(x 3 , x 4 ), p(x 4 )</formula><p>r(y 2 , y 3 ), q(y 3 )</p><p>t(y 3 , y 4 ), p(y 4 )</p><formula xml:id="formula_7">B 0 L 1 L 2 D 1 D 2 L 3 L 4 D 3 D 4 R 1 R 2 R 2 R 1 R 1 R 2 R 2 R 1</formula><p>Fig. <ref type="figure">2</ref>. The greedy tree decomposition of α 4 (F, R)</p><formula xml:id="formula_8">(Example 2)</formula><p>Maintaining this tree decomposition is not sufficient by itself to ensure the termination of the algorithm, since the universal model can be infinite. The main notion used in <ref type="bibr" target="#b12">[13]</ref> to ensure the finiteness of the built tree is the equivalence between bags: two bags B and B are said equivalent when every fact that will eventually be mapped "under B" (i.e., using at least one term generated below B) can be mapped similarly (i.e., up to a bijection between terms of B and B )"under B ", and conversely. If two bags are equivalent, it is only necessary to apply rules below one of them, and the other one will be said "blocked". When no more rule is applicable on a non-blocked bag, we obtain the full blocked tree.</p><p>This equivalence as well as rule applications are computed in the original algorithm by means of patterns, that are attached to each bag. The complexity of the original algorithm is due to the high number of relevant patterns. In the remaining of this section, we explain how to compute the equivalence relation as well as new rule applications without using patterns -and thus we do not present patterns here.</p><p>First, we can simplify equivalence between bags: with orientable fr1 rules, two bags are equivalent if they have been created by the same rule, as stated by the following property.</p><p>Property 3 Let R be a set of orientable fr1 rules, R ∈ R, R ∈ R, and F be a fact. Let B 1 and B 2 be two bags of T * (the tree decomposition of the universal model of F and R) created by the same rule R. Let z be an existential variable of R, z 1 and z 2 be the corresponding fresh variables in B 1 and B 2 . B 1 has a child created by a rule application of R mapping fr(R ) to z 1 if and only if B 2 has a child created by a rule application of R mapping fr(R ) to z 2 .</p><p>Example 2 (contd.). A full blocked tree of F and R is represented in Figure <ref type="figure" target="#fig_0">3</ref>. L 2 is equivalent to D 1 , D 2 to L 1 ; L 2 and D 2 are blocked and no new rule application can be done on B 0 , L 1 or D 1 -this is checked by existence of a * -homomorphism, see below.</p><p>Second, we check rule applicability by means of * -homomorphism. This tool is introduced in <ref type="bibr" target="#b12">[13]</ref> to evaluate a conjunctive query. Suppose that, at some step of the algorithm, we have generated a blocked tree T . We want to check if there is a homomorphism from Q to the possibly infinite fact encoded by T . This fact can be obtained from T by a possibly infinite sequence of completions, that iteratively copies under blocked bags the atoms found under their equivalent bag (up to variable renaming). Such a homomorphism induces a partition of Q (two atoms are in the same set if they are mapped to the same -initial or added -bag) and a tree structure for this partition (mimicking the tree structure of the image bags). Finally, <ref type="bibr" target="#b12">[13]</ref> shows that if there exists such a homomorphism, there exists one requiring only a completion sequence of bounded length. To encode the homomorphism, we thus only need the tree decomposition of Q, homomorphisms from each subset of Q to a bag of T , and the required bounded number of completions: this is the structure called a * -homomorphism. p(a), q(a) r(a, x 1 ), q(x 1 ) t(a, y 1 ), p(y 1 )</p><p>t(x 1 , x 2 ), p(x 2 ) r(y 1 , y 2 ), q(y 2 ) Example 3 ( * -homomorphism). Let Q = {r(z, z 1 ), t(z 1 , z 2 ), r(z 2 , z 3 ), t(z 3 , z 4 ), t(z, z 1 )}. Let π = {(z, a), (z 1 , x 1 ), (z 2 , x 2 ), (z 3 , x 3 )(z 4 , x 4 ), (z 1 , y 1 )} from Q to the fact associated with the tree drawn in Figure <ref type="figure">2</ref>. The corresponding * -homomorphism is pictured in Figure <ref type="figure">4</ref>.</p><formula xml:id="formula_9">B 0 L 1 L 2 D 1 D 2 R 1 R 2 R 2 R 1</formula><p>∅ r(z, z 1 ) t(z, z 1 )</p><formula xml:id="formula_10">t(z 1 , z 2 ) r(z 2 , z 3 ) t(z 3 , z 4 ) Q 0 → B 0 z → a Q 1 → L 1 z → a, z 1 → x 1 Q 2 → L 2 z 1 → x 1 , z 2 → x 2 Q 3 → D 2 z 2 → y 1 , z 3 → y 2 Q 4 → L 2 z 3 → x 1 , z 4 → x 2 Q 6 → D 1 Fig. 4. A * -homomorphism from Q = {r(z, z 1 ), t(z 1 , z 2 ), r(z 2 , z 3 ), t(z 3 , z 4 ), t(z, z 1 )} to the structure of Figure 3.</formula><p>Given a tree decomposition of Q and homomorphisms from bags of this decomposition to corresponding bags of T (as in Figure <ref type="figure">4</ref>), we check if it is actually a *homomorphism. We check for any pair of adjacent nodes that the associated mappings are compatible, i.e., the image of any term is unique. In the given example, for Q 1 , {(z, a), (z 1 , x 1 )} is a homomorphism from r(z, z 1 ) to r(a, x 1 ), q(x 1 ), which is consistent with Q 0 since z is mapped to a in both cases. An interesting consistency check occurs for Q 2 and Q 3 : since Q 2 has been mapped to a bag having no child, z 2 has image x 2 when considering Q 2 , and y 1 when considering Q 3 . However, this is consistent since when copying D 2 under L 2 , we rename y 1 by x 2 .</p><p>Theorem 1. The conjunctive query answering problem with a set of orientable fr1 rules is Ptime-complete for data complexity and NP-complete for combined complexity.</p><p>Proof. The Ptime membership comes from similar result for fr1 rules in <ref type="bibr" target="#b12">[13]</ref>. The NPmembership is due to the fact that the structure we build is of polynomial size in F and R. The hardness holds because it generalizes EL.</p><p>It is interesting to note that our algorithm, when further restricted to EL ontologies, becomes similar to the algorithm presented in <ref type="bibr" target="#b10">[11]</ref>. The main difference is that, while our algorithm maintains equivalence classes, the algorithm in <ref type="bibr" target="#b10">[11]</ref> merges equivalent bags. These merges result in the finiteness of the process, but also in the loss of homomorphism soundness with respect to first-order semantics. Soundness is regained by modifying homomorphism check, in a way both based on the orientation of EL and on its tree-model property.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="5">Adding Complex Role Inclusions</head><p>Complex role inclusions are arguably useful in practice. However, this kind of rules does not behave well with respect to both forward chaining and backward chaining, as illustrated with Example 4.</p><p>Example 4. Let R = {p(x) → r(x, y) ∧ p(y); r(x, y) ∧ r(y, z) → r(x, z)}. The query Q = {q(x), r(x, y), q(y)} is not rewritable w.r.t. R into a finite union of conjunctive queries, and R does not generate facts of bounded treewidth either: a clique of arbitrary size can be built by performing forward chaining on the fact p(a).</p><p>In order to stay as close as possible to the algorithm of previous section, we split any fact generated during the chase into two parts: atoms generated by fr1 rules (the backbone), and those generated by role inclusions. The first part is of bounded treewidth, and can be managed in the same way as before. The second part will be dealt with in a different fashion: we restrict the set of allowed role inclusions in order to deal with them by means of automata, as it was already done in <ref type="bibr" target="#b9">[10]</ref>. In the following, we define an abstract condition of regularity for so-called oriented join rules, and an easily checkable syntactic condition that generalizes existing results. We then illustrate the algorithm with Example 5.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>Definition 4 (Join rule).</head><p>A join rule is a rule of the following shape: r(x, y) ∧ s(y, z) → t(x, z). Transitivity rules are the case where r = s = t, left-identity rules where r = t. Definition 5 (Backbone). Let F be a fact, R = R o ∪ R j where R o is a set of fr1 rules and R j is a set of join rules. The backbone associated with F and R is the subset of atoms of the universal model of F and R that have been created by a fr1 rule.</p><p>The backbone is of bounded treewidth, and a tree decomposition can be built greedily. In order to have a counter-part of Property 3 on bag equivalence, we consider only orientable join rules. Definition 6 (&lt;-oriented join rules). Let R be the following join rule: r(x, y)∧s(y, z) → t(x, z). R is a &lt;-oriented join rule if:</p><p>either r 1 &lt; r 2 , s 1 &lt; s 2 and t 1 &lt; t 2 , or r 1 &gt; r 2 , s 1 &gt; s 2 and t 1 &gt; t 2 .</p><p>The following property allows us to keep a trivial equivalence relation on bags. Indeed, it ensures that the criterion used in the previous section to check equivalence between bags remains valid when adding &lt;-oriented join rules to our framework. Property 4 Let R o be a set of &lt;-oriented fr1 rules, R j be a set of &lt;-oriented join rules (for the same order &lt;), R, R ∈ R o , F be a fact. Let B 1 and B 2 two bags of T * (the greedy tree decomposition of the backbone associated with F and R o ∪ R j ) created by the same rule R ∈ R o . Let z be an existential variable of R, z 1 and z 2 be the corresponding fresh variables of B 1 and B 2 . B 1 has a child created by a rule application of R mapping fr(R ) to z 1 if and only if B 2 has a child created by a rule application of R mapping fr(R ) to z 2 .</p><p>Having a finite representation of the backbone, we use regularity in order to manage join rules. Given a fact F and x and y two terms of F, we denote by P F (x, y) the set of words that describe a finite elementary path from x to y. For instance, in the query Q of Figure <ref type="figure">4</ref>, P F (z, z 3 ) = {rtr}. Definition 7 (Regularity of a set of join rules). Let P be a set of binary predicates, and R c be a set of join rules over P. R c is regular if for any predicate p ∈ P, there exists a regular language L p such that, for any fact F , for any x, y ∈ terms(F), the following holds:</p><p>F, R c | = p(x, y) ⇔ P F (x, y) ∩ L p ∅</p><p>Similarly to a * -homomorphism, a * j -homomorphism is a labeled tree structure, together with a mapping from its bags to the bags of the full blocked tree. In the *homomorphism case, the consistency check consists only in checking that each term of the query has a well-defined image. In the * j -homomorphism case, we also have to check that atoms generated by complex role inclusions can be effectively generated. Let us consider Example 5 and Figure <ref type="figure" target="#fig_1">5</ref>. In order to have w(a, x) entailed by the universal model, not only should x be mapped to t 1 in a bag B equivalent to B 3 , but there should also be a path from a to the image of the frontier of the rule creating B, such that A w (Figure <ref type="figure" target="#fig_1">5</ref>) ends in s 3 when reading the word associated with that path. It is worth to note that this is not the case for B 3 and B 5 , but it holds for B 7 , even though B 3 , B 5 and B 7 are equivalent. We thus add this information about states in the * j -homomorphism.</p><p>Compared to the orientable fr1 case, the size of a completion needed to map a query can be bigger up to a factor which is exponential in the query and in the automaton used to recognize regular predicates. This does not increase the data complexity of CQA with the union of a &lt;-oriented fr1 set of rules and a &lt;-oriented and regular set of join rules, which remains Ptime-complete. However further work is required to determine the combined complexity of the problem.</p><formula xml:id="formula_11">Example 5. Let R = R o ∪ R j with R o = {p(x) → r(x, y) ∧ r(y, z) ∧ q(z) ∧ p(z), q(x) → w(x, y)} and R j = {r(x, y) ∧ r(y, z) → s(x, z), s(x, y) ∧ r(y, z) → t(x, z), t(x, y) ∧ w(y, z) → w(x, z)}.</formula><p>We take a fact F = {p(a)} and a query Q = {w(a, x)}. The regular expressions associated with r, s, t and w are r, rr + s, rrr + sr + t, and (rrr + sr + t) * w.</p><p>There exists a homomorphism π from Q to the completion represented in Figure <ref type="figure">6</ref>, mapping x to t 3 . We represent this homomorphism by the structure represented Figure <ref type="figure">7</ref>. Last, we present a syntactic condition that ensures that a set of join rules is regular. In particular, this condition generalizes the condition proposed in <ref type="bibr" target="#b9">[10]</ref>. Definition 8 (Stratified set of join rules). A set of join rules is stratified if the directed graph G built as follows is acyclic. For every predicate p, there exists a vertex v p in V. There is an arc from v p to v q where p q if there exists a rule r(x, y) ∧ s(y, z) → t(x, z), where p = r or p = s and q = t. p(a) r(a, y 1 ), r(y 1 , z 1 ), q(z 1 ), p(z 1 ) r(z 1 , y 2 ), r(y 2 , z 2 ), q(z 2 ), p(z 2 ) r(z 2 , y 2 ), r(y 3 , z 3 ), q(z 3 ), p(z 3 )</p><formula xml:id="formula_12">w(z 1 , t 1 ) w(z 3 , t 3 ) w(z 2 , t 2 ) B 1 B 2 B 4 B 3 B 7 B 5</formula><p>Fig. <ref type="figure">6</ref>. In plain, the full blocked tree; in dashed, a completion (Example 5). By additionally using (only) role inclusions, Q = w(a, x) can be mapped, mapping x to t 3 . Property 5 (Regularity of a stratified set of join rules) A stratified set of join rules is regular.</p><p>Proof (sketch). By induction on the structure of G. A predicate p whose vertex does not have an incoming arc is associated with the regular expression p. For any q, if we have a regular expression for any p such that (v p , v q ) is an arc of G, we can build one for q.</p><p>Theorem 2. The CQA problem with rules being the union of of &lt;-oriented fr1 rules and &lt;-oriented regular join rules (for the same order &lt;) is Ptime in data complexity.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="6">Conclusion</head><p>In this preliminary work, we identified a class of existential rules, namely fr1 orientable rules, covering EL ontologies while keeping the same complexity for CQA. Rules allow to easily use predicates of any arity and some cycles between variables. We exploited the simplicity of orientable fr1 rules to simplify the very recent algorithm from <ref type="bibr" target="#b12">[13]</ref>.</p><p>We then investigated how to add some expressive power that could be useful in practice, while staying polynomial in data complexity: we showed how to add transitivity axioms and left-and right-identity rules. Although adding these rules does not fulfill the usual decidability criteria, we adapted the algorithm for orientable rules by using finite automata. Some follow-up naturally come to mind: can we generalize our approach to cover Horn-SROIQ? What is the combined complexity of CQA with the considered rules? What are interesting classes of rules with predicate of any arity that could be added to this basis, while staying polynomial in data complexity? How does the algorithm behave in practice? Moreover, compared to the algorithm presented in <ref type="bibr" target="#b10">[11]</ref>, the representation of the universal model uses more space, since equivalent nodes are not merged. Can we adapt our algorithm in order to reduce the space requirements?</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>Aknowledgment</head><p>The author thanks the anonymous reviewers for their useful and constructive comments.</p></div><figure xmlns="http://www.tei-c.org/ns/1.0" xml:id="fig_0"><head>Fig. 3 .</head><label>3</label><figDesc>Fig. 3. The full blocked tree of F and R (Example 2)</figDesc></figure>
<figure xmlns="http://www.tei-c.org/ns/1.0" xml:id="fig_1"><head>Fig. 5 .</head><label>5</label><figDesc>Fig. 5. A w , an automaton recognizing L w (Example 5)</figDesc></figure>
<figure xmlns="http://www.tei-c.org/ns/1.0" xml:id="fig_2"><head>B 1 →→ t 1 Fig. 7 .</head><label>117</label><figDesc>Fig. 7. A * j -homomorphism of Q = {w(a, x)} in the full blocked tree of Example 5</figDesc></figure>
<figure xmlns="http://www.tei-c.org/ns/1.0" type="table" xml:id="tab_0"><head>Table 1 .</head><label>1</label><figDesc>Translation of an EL ontology</figDesc><table /></figure>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="1" xml:id="foot_0">Note that this notion generalizes the usual definition of fact by taking existential variables generated by rules into account.</note>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="2" xml:id="foot_1">We can now omit quantifiers since there is no ambiguity.</note>
		</body>
		<back>
			<div type="references">

				<listBibl>

<biblStruct xml:id="b0">
	<monogr>
		<title level="m" type="main">Foundations of Databases</title>
		<author>
			<persName><forename type="first">S</forename><surname>Abiteboul</surname></persName>
		</author>
		<author>
			<persName><forename type="first">R</forename><surname>Hull</surname></persName>
		</author>
		<author>
			<persName><forename type="first">V</forename><surname>Vianu</surname></persName>
		</author>
		<imprint>
			<date type="published" when="1994">1994</date>
			<publisher>Addison Wesley</publisher>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b1">
	<analytic>
		<title level="a" type="main">Terminological cycles in a description logic with existential restrictions</title>
		<author>
			<persName><forename type="first">F</forename><surname>Baader</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="j">IJ-CAI</title>
		<imprint>
			<biblScope unit="page" from="325" to="330" />
			<date type="published" when="2003">2003</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b2">
	<analytic>
		<title level="a" type="main">Pushing the EL envelope</title>
		<author>
			<persName><forename type="first">F</forename><surname>Baader</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Brandt</surname></persName>
		</author>
		<author>
			<persName><forename type="first">C</forename><surname>Lutz</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">Proc. 19th Int. Joint Conf. on Artificial Intelligence (IJCAI&apos;05)</title>
				<editor>
			<persName><forename type="first">L</forename><surname>Kaelbling</surname></persName>
		</editor>
		<editor>
			<persName><forename type="first">A</forename><surname>Saffiotti</surname></persName>
		</editor>
		<meeting>19th Int. Joint Conf. on Artificial Intelligence (IJCAI&apos;05)</meeting>
		<imprint>
			<publisher>Professional Book Center</publisher>
			<date type="published" when="2005">2005</date>
			<biblScope unit="page" from="364" to="369" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b3">
	<monogr>
		<title level="m">The Description Logic Handbook: Theory, Implementation, and Applications</title>
				<editor>
			<persName><forename type="first">F</forename><surname>Baader</surname></persName>
		</editor>
		<editor>
			<persName><forename type="first">D</forename><surname>Calvanese</surname></persName>
		</editor>
		<editor>
			<persName><forename type="first">D</forename><surname>Mcguinness</surname></persName>
		</editor>
		<editor>
			<persName><forename type="first">D</forename><surname>Nardi</surname></persName>
		</editor>
		<editor>
			<persName><forename type="first">P</forename><surname>Patel-Schneider</surname></persName>
		</editor>
		<imprint>
			<publisher>Cambridge University Press</publisher>
			<date type="published" when="2007">2007</date>
		</imprint>
	</monogr>
	<note>second edn</note>
</biblStruct>

<biblStruct xml:id="b4">
	<analytic>
		<title level="a" type="main">Extending decidable cases for rules with existential variables</title>
		<author>
			<persName><forename type="first">J</forename><forename type="middle">F</forename><surname>Baget</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Leclère</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><forename type="middle">L</forename><surname>Mugnier</surname></persName>
		</author>
		<author>
			<persName><forename type="first">E</forename><surname>Salvat</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">IJCAI</title>
				<imprint>
			<date type="published" when="2009">2009</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b5">
	<analytic>
		<title level="a" type="main">On rules with existential variables: Walking the decidability line</title>
		<author>
			<persName><forename type="first">J</forename><forename type="middle">F</forename><surname>Baget</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Leclère</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><forename type="middle">L</forename><surname>Mugnier</surname></persName>
		</author>
		<author>
			<persName><forename type="first">E</forename><surname>Salvat</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="j">Artif. Intell</title>
		<imprint>
			<biblScope unit="volume">175</biblScope>
			<biblScope unit="issue">9-10</biblScope>
			<biblScope unit="page" from="1620" to="1654" />
			<date type="published" when="2011">2011</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b6">
	<analytic>
		<title level="a" type="main">Taming the infinite chase: Query answering under expressive relational constraints</title>
		<author>
			<persName><forename type="first">A</forename><surname>Calì</surname></persName>
		</author>
		<author>
			<persName><forename type="first">G</forename><surname>Gottlob</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Kifer</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">Proceedings of the Eleventh International Conference on the Principles of Knowledge Representation and Reasoning (KR 2008)</title>
				<meeting>the Eleventh International Conference on the Principles of Knowledge Representation and Reasoning (KR 2008)<address><addrLine>Sydney, Australia</addrLine></address></meeting>
		<imprint>
			<date type="published" when="2008">2008</date>
			<biblScope unit="page" from="70" to="80" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b7">
	<analytic>
		<title level="a" type="main">A general datalog-based framework for tractable query answering over ontologies</title>
		<author>
			<persName><forename type="first">A</forename><surname>Calì</surname></persName>
		</author>
		<author>
			<persName><forename type="first">G</forename><surname>Gottlob</surname></persName>
		</author>
		<author>
			<persName><forename type="first">T</forename><surname>Lukasiewicz</surname></persName>
		</author>
		<idno type="DOI">10.1145/1559795.1559809</idno>
		<ptr target="http://doi.acm.org/10.1145/1559795.1559809" />
	</analytic>
	<monogr>
		<title level="m">Proceedings of the 28th symposium on Principles of database systems (PODS&apos;09)</title>
				<meeting>the 28th symposium on Principles of database systems (PODS&apos;09)<address><addrLine>New York, NY, USA</addrLine></address></meeting>
		<imprint>
			<publisher>ACM</publisher>
			<date type="published" when="2009">2009</date>
			<biblScope unit="page" from="77" to="86" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b8">
	<analytic>
		<title level="a" type="main">The even more irresistible SROIQ</title>
		<author>
			<persName><forename type="first">I</forename><surname>Horrocks</surname></persName>
		</author>
		<author>
			<persName><forename type="first">O</forename><surname>Kutz</surname></persName>
		</author>
		<author>
			<persName><forename type="first">U</forename><surname>Sattler</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="j">KR</title>
		<imprint>
			<biblScope unit="page" from="57" to="67" />
			<date type="published" when="2006">2006</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b9">
	<analytic>
		<title level="a" type="main">Conjunctive queries for EL with role composition</title>
		<author>
			<persName><forename type="first">M</forename><surname>Krötzsch</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Rudolph</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="j">DL</title>
		<imprint>
			<biblScope unit="volume">250</biblScope>
			<date type="published" when="2007">2007</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b10">
	<analytic>
		<title level="a" type="main">Conjunctive query answering in the description logic EL using a relational database system</title>
		<author>
			<persName><forename type="first">C</forename><surname>Lutz</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Toman</surname></persName>
		</author>
		<author>
			<persName><forename type="first">F</forename><surname>Wolter</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">IJCAI</title>
				<imprint>
			<date type="published" when="2009">2009</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b11">
	<monogr>
		<title level="m" type="main">Ontological query answering with existential rules</title>
		<author>
			<persName><forename type="first">M</forename><forename type="middle">L</forename><surname>Mugnier</surname></persName>
		</author>
		<imprint>
			<date type="published" when="2011">2011</date>
			<biblScope unit="page" from="2" to="23" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b12">
	<monogr>
		<title level="m" type="main">A generic querying algorithm for greedy sets of existential rules</title>
		<author>
			<persName><forename type="first">M</forename><surname>Thomazo</surname></persName>
		</author>
		<author>
			<persName><forename type="first">J</forename><forename type="middle">F</forename><surname>Baget</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><forename type="middle">L</forename><surname>Mugnier</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Rudolph</surname></persName>
		</author>
		<editor>KR</editor>
		<imprint>
			<date type="published" when="2012">2012</date>
		</imprint>
	</monogr>
	<note>to appear</note>
</biblStruct>

				</listBibl>
			</div>
		</back>
	</text>
</TEI>
