<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Restricted Unification in the DL E L</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Franz Baader</string-name>
          <email>franz.baader@tu-dresden.de</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Maryam Rostamigiv</string-name>
          <email>Maryam.Rostamigiv@irit.fr</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Département d'Informatique, Paul Sabatier University</institution>
          ,
          <addr-line>Toulouse</addr-line>
          ,
          <country country="FR">France</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>Theoretical Computer Science, TU Dresden</institution>
          ,
          <addr-line>Dresden</addr-line>
          ,
          <country country="DE">Germany</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>Research on unification in Description Logic (DL) has concentrated on the lightweight DLs F L0 and EL. For both DLs, the unification type is zero, which is the worst possible type. The complexity of deciding unifiability is ExpTime-complete for F L0 and NP-complete for EL. In a recent paper, we have shown that, for F L0, both the unification type and the complexity of the decision problem can be improved by considering restricted versions of the unification problem where either the role depth of concepts is restricted syntactically or the length of role paths in interpretations is restricted semantically. In the present paper, we show that no such improvements can be obtained for EL: both in the syntactically and in the semantically restricted case, the unification type stays zero, and the complexity of the decision problem stays NP-complete.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>Introduction</title>
      <p>
        Unification theory [
        <xref ref-type="bibr" rid="ref13">13</xref>
        ] investigates the unification properties of equational
theories (such as associativity and commutativity of a binary function symbol). Given
an equational theory E and terms s; t, the decision problem asks whether s and t
can be made equal modulo E by replacing variables by terms, i.e., whether there
is a substitution such that (s) =E (t). In addition to testing unifiability,
one is also interested in computing a small representation of all unifiers, i.e., a
set of unifiers from which all unifiers can be obtained by instantiation. Such a
set is called a complete set of unifiers. From a practical point of view, it is useful
to have finite complete sets of unifiers. If the theory has unification type zero,
then there is a unification problem w.r.t. this theory such that every complete
set of unifiers is redundant in the sense that it contains unifiers that are in an
instance relationship, which implies that the unification problem cannot have a
finite complete set of unifiers. Unification in modal and description logics [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] can
be seen as a special case of unification w.r.t. an equational theory, where the
theory axiomatizes equivalence of formulae/concepts (viewed as terms) in the
respective logic.
      </p>
      <p>Copyright c 2021 for this paper by its authors. Use permitted under Creative
Commons License Attribution 4.0 International (CC BY 4.0).</p>
      <p>Unification of concept patterns has been proposed as a nonstandard
inference service in DL that can, for instance, be used to detect redundancies in
ontologies. For example, assume that one ontologist describes the medical
concept of myocarditis by the E L concept HeartDisease u 9cause:Virus whereas
another one describes it by ViralInfection u 9location:Heart : These two
concepts are not equivalent, but they can be unified (i.e., made equivalent) if we
view HeartDisease and ViralInfection as variables that can be replaced by
complex concepts. In fact, replacing HeartDisease with Disease u 9location:Heart
in the first concept yields Disease u 9location:Heart u 9cause:Virus ; and
replacing ViralInfection with Disease u 9cause:Virus in the second concept yields
Disease u 9cause:Virus u 9location:Heart : These two concepts are clearly
equivalent, and they actually yield an appropriate description of myocarditis.</p>
      <p>
        For the DL F L0, which has the concept constructors conjunction (u), value
restriction (8r:C), and top concept (&gt;), unification was investigated in detail
in [
        <xref ref-type="bibr" rid="ref12">12</xref>
        ]. It was shown there that unification in F L0 is ExpTime-complete and of
unification type zero. The DL E L, which has the concept constructors
conjunction (u), existential restriction (9r:C), and top concept (&gt;), also has unification
type zero, but the complexity of the decision problem is lower than for F L0: it
is “only” NP-complete for E L [
        <xref ref-type="bibr" rid="ref11">11</xref>
        ].
      </p>
      <p>
        In [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ], we investigate two kinds of restrictions on unification in F L0. On the
one hand, we syntactically restrict the role depth (i.e., the maximal nesting of
value restrictions) in the concepts obtained by applying a unifier to be bounded
by a natural number k 1. This restriction was motivated by a similar restriction
used in research on least common subsumers (lcs) [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ], where imposing a bound
on the role depth guarantees the existence of the lcs also in the presence of a
(possibly cyclic) terminology. Also note that such a restriction was used in [
        <xref ref-type="bibr" rid="ref16">16</xref>
        ] for
the equational theory ACh, for which unification is known to be undecidable [
        <xref ref-type="bibr" rid="ref18">18</xref>
        ].
It is shown in [
        <xref ref-type="bibr" rid="ref16">16</xref>
        ] that the problem becomes decidable if a bound on the maximal
nesting of applications of homomorphisms is imposed. On the other hand, we
consider in [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] a semantic restriction where, when defining the semantics of
concepts, only interpretations for which the length of role paths is bounded by
a given number k are considered. A similar restriction (for k = 1) was employed
in [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ] to improve the unification type from type zero for the modal logic K [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ]
to finitary for K + ?, which means that unification problems always have a
finite complete set of unifiers in this extension of K. We show in [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] that both the
syntactic and the semantic restriction ensures that the unification type of F L0
improves from type zero to finitary. Regarding the decision problem, we show
that the complexity depends on whether the bound k is assumed to be encoded
in unary or binary. For binary encoding of k, the complexity stays ExpTime,
whereas for unary coding it drops from ExpTime to PSpace. This is again the
case both for the syntactic and the semantic restriction.
      </p>
      <p>In the present paper, we investigate whether similar improvements of the
unification type and the complexity of the decision problem can be obtained
for the DL E L. Surprisingly, the answer to this question is “no.” Both in the
syntactically and in the semantically restricted case, the unification type stays
zero, and the complexity of the decision problem stays NP-complete for EL. This
demonstrates that the reason for type zero and the complexity lower bound
to hold are different for F L0 and EL. Whereas in F L0 they depend on the
possibility of arbitrarily deep nesting of role restrictions, this is not the case for
EL. In fact, we will see that for EL already a nesting depth of k = 1 suffices to
obtain type zero and NP-hardness.
2</p>
      <sec id="sec-1-1">
        <title>The DL E L and Restrictions</title>
        <p>Starting with mutually disjoint countably infinite sets NC and NR of concept
and role names, the set of EL concepts is inductively defined as follows:
– &gt; (top concept) and every concept name A 2 NC is an EL concept,
– if C, D are EL concepts and r 2 NR is a role name, then C uD (conjunction)
and 9r:C (existential restriction) are EL concepts.
follows:
The semantics of EL concepts is defined using interpretations I = ( I; I)
consisting of a non-empty domain I and an interpretation function I that
assigns a set AI I to each concept name A, and a binary relation rI
I I to each role name r. This function is extended to EL concepts as
&gt;I = I and (C u D)I = CI \ DI;
(9r:C)I = fx 2 I j 9y 2 I: (x; y) 2 rI ^ y 2 CIg:
Given two EL concepts C and D, we say that C is subsumed by D (written
C v D) if CI DI holds for all interpretations I, and that C is equivalent to
D (written C D) if C v D and D v C.</p>
        <p>
          It is well known that subsumption (and thus also equivalence) of EL concepts
can be decided in polynomial time. This was first shown in [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ] based on the notion
of a homomorphism between trees representing concepts, but it is also an easy
consequence of the following recursive characterization of subsumption.
Lemma 1 ([
          <xref ref-type="bibr" rid="ref11">11</xref>
          ]). Let C = A1 u : : : u Ak u 9r1:C1 u : : : u 9rm:Cm and D =
B1 u : : : u B` u 9s1:D1 u : : : u 9sn:Dn, where A1; : : : ; Ak; B1; : : : ; B` are concept
names. Then C v D iff fB1; : : : ; B`g fA1; : : : ; Akg and for every j; 1 j n,
there exists an i; 1 i m, such that ri = sj and Ci v Dj.
2.1
        </p>
        <sec id="sec-1-1-1">
          <title>Syntactically Restricting the Role Depth</title>
          <p>The role depth of an EL concept is the maximal nesting of existential restrictions
in this concept. To be more precise, the role depth rd (C) of the EL concept C
is defined by induction:
– rd (&gt;) = rd (A) = 0 for all A 2 NC ,
– rd (C u D) = max(rd (C); rd (D)) and rd (9r:C) = 1 + rd (C).
Using Lemma 1, it is easy to see that C v D implies rd (C) rd (D). Thus, the
role depth of E L concepts is preserved under equivalence.</p>
          <p>We are now ready to define our first restricted version of subsumption and
equivalence in E L. For an integer k 1 and E L concepts C and D, we define
subsumption and equivalence restricted to concepts of role depth k as follows:
– C vskyn D if C v D and rd (C) k,
– C skyn D if C vskyn D and D vskyn C.</p>
          <p>The effect of this definition is that subsumption and equivalence can only hold
for concepts that satisfy the restriction of the role depth by k. For concepts
satisfying this syntactic restriction, the relations vskyn and skyn coincide with
the classical subsumption and equivalence relations on E L concepts.
2.2</p>
        </sec>
        <sec id="sec-1-1-2">
          <title>Semantically Restricting the Length of Role Paths</title>
          <p>For an integer n 1 and a given interpretation I = ( I ; I ), a role path of
length n is a sequence d0; r1; d1; : : : ; dn 1; rn; dn; where d0; : : : ; dn are elements
of I , r1; : : : ; rn are role names, and (di 1; di) 2 riI holds for all i = 1; : : : ; n.
The interpretation I is called k-restricted if it does not admit any role paths of
length &gt; k.</p>
          <p>For an integer k 1 and E L concepts C and D, we define subsumption and
equivalence restricted to interpretations with role paths of length k as follows:
– C vskem D if CI DI holds for all k-restricted interpretations I,
– C skem D if C vskem D and D vskem C.</p>
          <p>The effect of this semantic restriction is that concepts of role depth &gt; k are
always interpreted as empty sets, i.e., if I is a k-restricted interpretation and
C an E L concept such that rd (C) &gt; k, then CI = ;. The following lemma is
an easy consequence of this fact, where ? denotes the bottom concept, which is
interpreted as ?I = ; in every interpretation I.</p>
          <p>1 and C; D be E L concepts. Then C
k
sem ? iff rd (C) &gt; k,</p>
        </sec>
        <sec id="sec-1-1-3">
          <title>Lemma 2. Let k</title>
          <p>and C skem D iff
– rd (C) &gt; k and rd (D) &gt; k, or
– rd (C) k, rd (D) k, and C
In unification, we consider concepts that may contain variables, which can be
replaced by concepts. More formally, we introduce a countably infinite set NV
of concept variables, which is disjoint with NC and NR. An E L concept pattern
is an E L concept that is constructed using NC [ NV as concept names. The
semantics of concept patterns is defined as for concepts, i.e., concept variables
are treated like concept names when defining the semantics. This way, the notions
of subsumption and equivalence (both in the restricted and in the unrestricted
setting) transfer from concepts to concept patterns in the obvious way.</p>
          <p>A substitution is a mapping from NV into the set of all E L concept patterns
such that dom( ) := fX 2 NV j (X) 6= Xg is finite. This mapping is extended
to concept patterns in the obvious way:
–
–
(A) := A for all A 2 NC [ f&gt;g,
(C u D) := (C) u (D) and (9r:C) := 9r: (C).</p>
          <p>An E L unification problem is an equation of the form C ? D where C; D are
E L concept patterns. A unifier (or solution) of this equation is a substitution
such that (C) (D).</p>
          <p>Example 3. Consider the E L unification problem
9r:X u 9s:9r:A ?
9r:9s:Y u 9s:Y:
It is easy to see that (up to equivalence and restricted to the variables X; Y )
the substitution ex with dom( ex ) = fX; Y g, ex (X) = 9s:9r:A, and ex (Y ) =
9r:A is the only unifier of this problem.
3.1</p>
        </sec>
        <sec id="sec-1-1-4">
          <title>The Unification Type</title>
          <p>When considering the unification type of an equational theory or logic, one is
interested in the question of whether all unifiers of a given unification problem
can be represented as instances of a finite set of unifiers, where the instance
relation between unifiers is defined as follows: given unifiers ; of C ? D, we say
that is an instance of if there is a substitution such that (X) ( (X))
for all variables X occurring in C or D.</p>
          <p>
            A set of unifiers M of an E L unification problem C ? D is complete if any
unifier of C ? D is an instance of an element of M . This set is minimal if
no two distinct elements of M are comparable w.r.t. the instance relation. The
unification problem C ? D has type zero if it does not have a minimal complete
set of unifiers. Note that this implies that C ? D does not have a finite complete
set of unifiers since such a set could be made minimal by removing unifiers that
are instances of others [
            <xref ref-type="bibr" rid="ref13">13</xref>
            ]. Saying that E L has unification type zero means
that there is an E L unification problem that has type zero. Thus, the following
proposition implies that E L indeed has unification type zero.
          </p>
          <p>
            Proposition 4 ([
            <xref ref-type="bibr" rid="ref11">11</xref>
            ]). Let X; Y be concept variables. The E L unification
problem X u 9r:Y ? 9r:Y has unification type zero.
          </p>
          <p>
            The proof of this proposition given in [
            <xref ref-type="bibr" rid="ref11">11</xref>
            ], which shows that any complete
set of unifiers M of X u 9r:Y ? 9r:Y is non-minimal, proceeds as follows:
1. It observes that the substitution with (X) = 9r:A and (Y ) = A is a
unifier, and thus there must be an element of M such that is an instance
of . It shows that this unifier satisfies (X) 6 &gt; and (X) 6 9r:&gt;.
2. It then proves that the substitution b defined as
b(X) := (X) u 9r:Z;
b(Y ) := (Y ) u Z;
          </p>
          <p>where Z is a new variable,
is a unifier of X u 9r:Y ? 9r:Y that has as an instance.
3. Since M is complete, it concludes that there is a unifier in M such that b
is an instance of . Since the instance relation is transitive, this implies that
is an instance of .
4. Using the fact that (X) 6 &gt; and (X) 6 9r:&gt;, it proves that cannot be
equal to , and concludes non-minimality of M .</p>
          <p>We will show later that this proof also works in the restricted case.
3.2</p>
        </sec>
        <sec id="sec-1-1-5">
          <title>The Decision Problem</title>
          <p>
            NP-hardness already holds for the case of matching, where we call an E L
unification problem of the form C ? D a matching problem if D does not contain
concept variables. A unifier of a matching problem is also called matcher.
NPhardness of matching can be shown by a reduction from SAT, i.e., satisfiability
of propositional formulae. In the literature, one can actually find two such
reductions with different characteristics:
(R1) In [
            <xref ref-type="bibr" rid="ref6">6</xref>
            ], a given propositional formula is translated into an E L matching
problem C ? D such that the role depth of both C and D is 1, and the
number of different role names occurring in C and D is linear in the size
of .
(R2) In [
            <xref ref-type="bibr" rid="ref17">17</xref>
            ] (proof of Corollary 6.3.4, pages 185 and 186), a given propositional
formula is translated into an E L matching problem C ? D such that the
role depth of both C and D is linear in the size of , and C; D contain only
4 different role names.
          </p>
          <p>
            For the case of matching, an NP-upper bound was also shown in [
            <xref ref-type="bibr" rid="ref17 ref6">6,17</xref>
            ]. It
took almost ten years before an NP-upper bound for unification in E L could be
proved in [
            <xref ref-type="bibr" rid="ref11 ref9">9,11</xref>
            ].
          </p>
          <p>
            Theorem 5 ([
            <xref ref-type="bibr" rid="ref11 ref9">9,11</xref>
            ]). Unification in E L is NP-complete.
          </p>
          <p>
            Showing the NP-upper bound for unification in E L is more involved than
proving the lower bound, though the original proof given in [
            <xref ref-type="bibr" rid="ref11 ref9">9,11</xref>
            ] was simplified
in later work [
            <xref ref-type="bibr" rid="ref1 ref10">10,1</xref>
            ]. The basic idea underlying the proof is to show the following:
1. Every solvable E L unification problem C ? D has a local unifier, i.e., a
unifier that is a local substitution. Intuitively, local substitutions are built
from subconcepts of the concepts C; D (see below for more details).
2. Polynomially large representations of local substitutions can be guessed by
a non-deterministic procedure in polynomial time.
3. Given such a representation of a local substitution , it can be checked in
polynomial time whether is a unifier of C ? D.
To be more precise, it is shown in [
            <xref ref-type="bibr" rid="ref1 ref11 ref9">9,11,1</xref>
            ] that a given E L unification problem
C ? D determines a set of flat atoms At (C; D), whose cardinality is linear in
the size of the problem. A flat atom is a concept name, a concept variable, or
an existential restriction of the form 9r:E, where E is either a concept name
or a concept variable. Such an atom is called non-variable if it is not a concept
variable. The subset of non-variable atoms in At (C; D) is denoted as At nv (C; D).
          </p>
          <p>Local substitutions are induced by assignments S, which assign subsets SX
of At nv (C; D) to the concept variables occurring on C; D. To induce a local
substitution, such an assignment needs to be acyclic, which means that the
transitive closure &gt;S of</p>
          <p>OS := f(X; Y ) j X; Y are variables in C or D and Y occurs in SX g
is irreflexive (and thus a partial order). Any acyclic assignment S induces a
unique substitution S , which can be defined by induction along &gt;S :
– If X is a minimal variable w.r.t. &gt;S , then S (X) := dE2SX E.
– Assume that S (Y ) is already defined for all Y such that X &gt;S Y . Then</p>
          <p>S (X) := dE2SX S (E):
A substitution is called local if it is of this form, i.e., if there is an acyclic
assignment S such that = S . If the unifier of C ? D is a local substitution,
then it is called a local unifier.</p>
          <p>Whereas assignments are of size polynomial in the size of the input
unification problem C ? D (and thus can be guessed by an NP procedure), local
substitutions may assign exponentially large concepts to a variable.
Nevertheless, given an acyclic assignment S, one can check in polynomial time whether</p>
          <p>
            S is a unifier, basically by viewing the assignment as an acyclic TBox (see [
            <xref ref-type="bibr" rid="ref11">11</xref>
            ]
for details).
          </p>
          <p>
            The proof that every solvable E L unification problem C? D has a local unifier
given in [
            <xref ref-type="bibr" rid="ref11">11</xref>
            ] proceeds in two steps. First, it uses component-wise subsumption
to define an order on substitutions:
          </p>
          <p>
            6
iff (X) v (X) holds for all variables X occurring in C; D,
iff and :
The unifier of C ? D is called minimal if there is no unifier of C ? D
such that . It is then shown in [
            <xref ref-type="bibr" rid="ref11">11</xref>
            ] that the pre-order is well-founded,
which immediately implies that very solvable E L unification problem C ? D
has a minimal unifier. The second step, which is considerably more involved, is
then to prove that every minimal unifier is local (see Proposition 5.11 in [
            <xref ref-type="bibr" rid="ref11">11</xref>
            ]). A
direct proof that every solvable E L unification problem has a local unifier that
does not use minimal unifiers can be found in [
            <xref ref-type="bibr" rid="ref1">1</xref>
            ].
4
          </p>
        </sec>
      </sec>
      <sec id="sec-1-2">
        <title>Syntactically Restricted Unification in E L</title>
        <p>For an integer k 1, a syntactically k-restricted unification problem is an
equation of the form C ? k</p>
        <p>syn D, where C; D are E L concept patterns. A unifier of
this equation (also called syntactically k-restricted unifier ) is a substitution
such that (C) skyn (D).</p>
        <p>If we view the unification problem in Example 3 as a syntactically k-restricted
unification problem, then it does not have a solution for k 2, but the
substitution ex is a syntactically k-restricted unifier of this problem for all k 3.</p>
        <p>The following lemma is an immediate consequence of the definition of skyn
and the fact that rd ( (X)) rd ( (D)) for every substitution and every
concept variable X occurring in the E L concept D.</p>
        <sec id="sec-1-2-1">
          <title>Lemma 6. If</title>
          <p>unifier of C ?
C or D.</p>
          <p>is a syntactically k-restricted unifier of C ? skyn D, then is a</p>
          <p>D and rd ( (X)) k for every concept variable X occurring in
Consequently, the instance relation on syntactically k-restricted unifiers (which
is defined using skyn ) coincides with the instance relation on unifiers (which is
defined using ). However, the set of syntactically k-restricted unifiers may of
course be a strict subset of the set of unrestricted unifiers. For this reason, it is
not immediately clear that type zero transfers from unification to syntactically
k-restricted unification. To see that this is nevertheless the case, one needs to
look more closely at the proof of Proposition 4 sketched in the previous section.
Proposition 7. Let X; Y be concept variables. The syntactically k-restricted E L
unification problem X u9r:Y ? skyn 9r:Y has unification type zero for every k 1.
Proof. Similarly to the proof of Proposition 4, we consider an arbitrary complete
set M of syntactically k-restricted unifiers of X u 9r:Y ? k
syn 9r:Y . We show that
all the steps made in this proof also work in the syntactically k-restricted case.
1. The unifier with (X) = 9r:A and (Y ) = A considered in the first step of
that proof is clearly also a syntactically k-restricted unifier for every k 1.
Since M is complete for such unifiers, is an instance1 of an element 2 M .</p>
          <p>As before, we conclude that satisfies (X) 6 &gt; and (X) 6 9r:&gt;.
2. Since is a syntactically k-restricted unifier, the same is true for the
substitution b constructed in the second step. In fact, we already know that b is
a unifier, and the concepts
b(X u 9r:Y ) = (X) u 9r:Z u 9r:( (Y ) u Z) and b(9r:Y ) = 9r:( (Y ) u Z)
have role depth 1 since is a syntactically k-restricted unifier of Xu9r:Y ? k
syn
9r:Y , which implies rd ( (X)) 1 and rd ( (Y )) = 0.
3. The third step works as above, but we now also know that the unifier 2 M
that has as an instance is syntactically k-restricted.
4. The proof that and cannot be equal again works as for the unrestricted
case since the same notion of instance is employed, due to Lemma 6.
1 Recall that, by Lemma 6, we can assume that this is the classical instance relation.
This finishes the proof that M cannot be minimal. Since M was chosen as an
arbitrary complete set of syntactically k-restricted unifiers of X u9r:Y ? k
syn 9r:Y ,
this shows that this unification problem has unification type zero.
tu
Theorem 8. Syntactically k-restricted E L unification has unification type zero
for any k 1.</p>
          <p>Let us now turn to the complexity of the decision problem. In this context, one
can either assume that the bound k is fixed, or that it is part of the input. In the
latter case, one can distinguish between unary and binary coding of the number
k. We want to show that the same reductions from SAT as in the unrestricted
setting can be used to show NP-hardness of the matching problem. For this, the
observations made in the next lemma are useful.</p>
          <p>Lemma 9. Let C ? k</p>
          <p>syn D be a syntactically k-restricted E L matching problem.
1. If rd (D) &gt; k, then C ? k</p>
          <p>syn D does not have a solution.
2. Otherwise, a substitution</p>
          <p>D iff it is a matcher of C ?
is a syntactically k-restricted matcher of C ? k
syn</p>
          <p>D.</p>
          <p>Consequently, the reduction (R1) works for any fixed k 1 since the concept
D used in that reduction has role depth 1. However, this reduction requires an
unbounded supply of role names.</p>
          <p>Proposition 10. For every fixed k 1, syntactically k-restricted matching is
NP-hard if the number of available role names is not bounded by a finite number.</p>
          <p>The reduction (R2) requires only four role names, but the role depth of D is
linear in the size of the propositional formula. Thus, this reduction only works if
we assume the bound k to be part of the input, but the reduction is polynomial
even if unary representation of k is assumed.</p>
          <p>Proposition 11. Syntactically k-restricted matching is NP-hard even if only
four role names are available and k is encoded in unary.</p>
          <p>We show the NP-upper bound for the most complex case of unification where
k is part of the input and assumed to be encoded in binary. The idea is to employ
basically the same NP procedure as in the unrestricted case, but additionally
check whether the restriction of the role depth is satisfied. Given a syntactically
k-restricted unification problem C ? k</p>
          <p>syn D, we
1. guess a local substitution in non-deterministic polynomial time;
2. check whether (C) (D) and rd ( (C)) k.</p>
          <p>To see that the second test checking the bound on the role depth can also be
realized in polynomial time, it is sufficient to prove the following lemma.
Lemma 12. Let S be an acyclic assignment for the unification problem C ? D.
Then we can compute rd ( S (X)) for every concept variable X occurring in C; D
in time polynomial in the size of C ? D.
Proof. This can easily be shown by induction along &gt;S , following the inductive
definition of the substitution S .
tu</p>
          <p>It remains to show that this NP procedure is complete, i.e., that it is really the
case that any solvable syntactically k-restricted unification problem C ? k
syn D
has a local substitution as a solution. We already know (see Section 3) that, for
any unifier of C ? D, there is a minimal unifier of C ? D such that .
In addition, is local. Using the fact that E v F implies rd (E) rd (F ), we
can conclude that, if is a syntactically k-restricted unifier, then so is . This
completes the proof of completeness.</p>
          <p>Theorem 13. Syntactically k-restricted unification in E L is NP-complete.
5</p>
        </sec>
      </sec>
      <sec id="sec-1-3">
        <title>Semantically Restricted Unification in E L</title>
        <p>For an integer k 1, a semantically k-restricted unification problem is an
equation of the form C ? k</p>
        <p>sem D, where C; D are E L concept patterns. A unifier of
this equation (also called semantically k-restricted unifier ) is a substitution
such that (C) skem (D).</p>
        <p>In contrast to the syntactic case, solvability in the semantically k-restricted
setting does not imply solvability in the unrestricted setting. For example, 9r:X?
9s:X for distinct role names r; s clearly does not have a solution, but the
substitution with (X) := 9r:A is a solution if we view this equation as a semantically
1-restricted unification problem. More generally, the following holds.
Lemma 14. If C; D both contain concept variables, then C ? k
sem D always has
a solution.</p>
        <p>Proof. Assume that the variable X occurs in C and the variable Y occurs in D,
and let E be an E L concept with rd (E) &gt; k. Let be the substitution defined as
(X) := (Y ) := E and (Z) := &gt; for all variables Z in C; D that are different
from X and Y . Then (C) skem ? skem (D). tu</p>
        <p>We call a solution of C ? skem D trivial if (C) skem ? skem (D). The
nontrivial semantically k-restricted unifiers are just the syntactically k-restricted
unifiers. This is an easy consequence of Lemma 2.</p>
        <p>Lemma 15. The substitution is a non-trivial semantically k-restricted unifier
of C ? skem D iff is a syntactically k-restricted unifier of C ? skyn D.</p>
        <p>If we view the unification problem in Example 3 as a semantically k-restricted
unification problem, then it does not have a non-trivial solution for k 2,
but setting (X) := (Y ) := 9r:9r:A yields a trivial solution for k 2. The
substitution ex is a non-trivial semantically k-restricted unifier of this problem
for all k 3.</p>
        <p>Matching problems C ? k
sem D can only have trivial solutions if rd (D) &gt; k.
Lemma 16. Let C ? skem D be a matching problem such that rd (D) k. Then
the set of solutions of C ? k syn D.</p>
        <p>sem D coincides with the set of solutions of C ? k</p>
        <p>Using this lemma, it is easy to see that the NP-hardness results shown in the
previous section also hold in the semantically restricted case. We state here only
the general NP-hardness result, but note that the more fine-grained complexity
results given in Propositions 10 and 11 also apply.</p>
        <p>Proposition 17. Semantically k-restricted matching is NP-hard.</p>
        <p>To show the NP-upper bound for unification, we can proceed as follows for
a given semantically k-restricted unification problem C ? k
sem D:
1. Check whether C ? k</p>
        <p>sem D has a trivial solution. This is the case if the
following holds for all E 2 fC; Dg: E contains a variable or rd (E) &gt; k. If
this test succeeds, then answer “unifiable.” Otherwise, proceed with the next
step.
2. If C ? k</p>
        <p>sem D does not have a trivial solution, then check whether it has a
non-trivial solution by testing whether C ? k
syn D has a solution, using the</p>
        <p>NP procedure described in the previous section.</p>
        <p>Overall, this yields an NP procedure for testing solvability of semantically
krestricted unification problems.</p>
        <p>Theorem 18. Semantically k-restricted unification in E L is NP-complete.</p>
        <p>Unification type zero can be shown by a simple adaptation of the approach
employed above for the syntactically k-restricted case. The proof uses the fact
that, if is an instance of , then rd ( (X)) rd ( (X)) for all variables occurring
in the unification problem. Consequently, a trivial solution cannot have a
nontrivial solution as an instance.</p>
        <p>Theorem 19. Semantically k-restricted E L unification has unification type zero
for any k 1.
6</p>
      </sec>
    </sec>
    <sec id="sec-2">
      <title>Conclusion</title>
      <p>We have investigated both a semantically and a syntactically restricted variant
of unification in E L, where either the role depth of concepts or the length of role
paths in interpretations is restricted by a natural number k 1. In contrast to
the case of F L0, for E L these restrictions do not lead to an improvement of the
unification type or the complexity of the decision problem. For F L0, the “bad”
behaviour w.r.t. the unification type and the complexity of the decision problem
depends on the ability to nest value restrictions arbitrarily deep. In contrast,
for E L the “bad” behaviour already shows up for k = 1, where no nesting of
existential restrictions is allowed.</p>
      <p>
        Nevertheless, it may still make sense to consider the syntactically restricted
variant of unification also for E L. In fact, in our experiments with the system
UEL, which implements several unification algorithms for the DL E L [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ], we
have observed that the algorithms usually yield many different unifiers, and
it is hard to choose one that is appropriate for the application at hand (e.g.,
when generating new concepts using unification [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]). For this reason, we added
additional constraints to the unification problem to ensure that the generated
concepts are of a similar shape as the concepts already present in the ontology [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ].
It makes sense also to use a restriction on the role depth as such an additional
constraint since the role depth of the (unfolded) concepts occurring in real-world
ontologies is usually rather small. This claim is supported by our experiments
with the medical ontology SNOMED CT,2 which has a maximal role depth of
10, and the acyclic ontologies in Bioportal 2017,3 where a large majority also
has a role depth of at most 10. The NP procedure for syntactically k-restricted
unification described in Section 4 is, however, not very useful in this setting since
it basically first computes all local unifiers of the unrestricted problem, and then
throws away the ones that lead to a unified concept whose role depth is too large.
Thus, it would be interesting to find a procedure for syntactically k-restricted
unification in E L that directly generates the local unifiers that are syntactically
k-restricted, without first generating all local unifiers.
      </p>
      <p>Both for F L0 and for E L, decidability of unification in the presence of
terminologies (TBoxes) consisting of general concept inclusions is an open problem.
In the restricted setting, decidability should follow from the fact that, up to
equivalence, there can be only finitely many concepts of a bounded role depth if
only finitely many concept names and role names are available. However, for E L
the number of such concepts increase by one exponent with every increase of the
role depth bound. Thus, it would be interesting to see whether an elementary
decision procedure can be obtained for E L in the restricted setting.</p>
    </sec>
    <sec id="sec-3">
      <title>Acknowledgements</title>
      <p>Franz Baader was partially supported by DFG TRR 248 (cpec, grant 389792660),
and Maryam Rostamigiv by a DAAD Short-Term Grant, 2021 (57552336). The
authors should like to thank Patrick Koopmann for determining the maximal
role depth of concepts in ontologies from Bioportal 2017 and in SNOMED CT.
2 https://www.snomed.org/
3 https://zenodo.org/record/439510</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          , Stefan Borgwardt, and
          <string-name>
            <given-names>Barbara</given-names>
            <surname>Morawska</surname>
          </string-name>
          .
          <article-title>Extending unification in EL towards general TBoxes</article-title>
          .
          <source>In Proc. of the 13th Int. Conf. on Principles of Knowledge Representation and Reasoning (KR</source>
          <year>2012</year>
          ), pages
          <fpage>568</fpage>
          -
          <lpage>572</lpage>
          . AAAI Press/The MIT Press,
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          , Stefan Borgwardt, and
          <string-name>
            <given-names>Barbara</given-names>
            <surname>Morawska</surname>
          </string-name>
          .
          <article-title>Constructing SNOMED CT concepts via disunification</article-title>
          .
          <source>LTCS-Report 17-07</source>
          , Chair for Automata Theory, Institute for Theoretical Computer Science, Technische Universität Dresden, Dresden, Germany,
          <year>2017</year>
          . https://lat.inf.tu-dresden.de/research/reports/ 2017/BaBM-LTCS-
          <volume>17</volume>
          -07.pdf.
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          , Oliver Fernández Gil, and
          <string-name>
            <given-names>Maryam</given-names>
            <surname>Rostamigiv</surname>
          </string-name>
          .
          <article-title>Restricted unification in the description logic F L0</article-title>
          . In Boris Konev and Giles Reger, editors,
          <source>Proc. of the 13th International Symposium on Frontiers of Combining Systems (FroCoS</source>
          <year>2021</year>
          ), volume
          <volume>12941</volume>
          of Lecture Notes in Computer Science. Springer,
          <year>2021</year>
          .
          <article-title>To appear. A long version of this paper containing detailed proofs has been published</article-title>
          as
          <source>technical report [4].</source>
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          , Oliver Fernández Gil, and
          <string-name>
            <given-names>Maryam</given-names>
            <surname>Rostamigiv</surname>
          </string-name>
          .
          <article-title>Restricted unification in the DL F L0 (extended version)</article-title>
          .
          <source>LTCS-Report 21-02</source>
          , Chair of Automata Theory, Institute of Theoretical Computer Science, Technische Universität Dresden, Dresden, Germany,
          <year>2021</year>
          . https://lat.inf.tu-dresden.de/research/ reports/2021/BaGiRo21.pdf.
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Silvio</given-names>
            <surname>Ghilardi</surname>
          </string-name>
          .
          <article-title>Unification in modal and description logics</article-title>
          .
          <source>Log. J. IGPL</source>
          ,
          <volume>19</volume>
          (
          <issue>6</issue>
          ):
          <fpage>705</fpage>
          -
          <lpage>730</lpage>
          ,
          <year>2011</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Ralf</given-names>
            <surname>Küsters</surname>
          </string-name>
          .
          <article-title>Matching in description logics with existential restrictions</article-title>
          .
          <source>In Proc. of the 7th Int. Conf. on Principles of Knowledge Representation and Reasoning (KR</source>
          <year>2000</year>
          ), pages
          <fpage>261</fpage>
          -
          <lpage>272</lpage>
          ,
          <year>2000</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          , Ralf Küsters, and
          <string-name>
            <given-names>Ralf</given-names>
            <surname>Molitor</surname>
          </string-name>
          .
          <article-title>Computing least common subsumers in description logics with existential restrictions</article-title>
          .
          <source>In Proc. of the 16th Int. Joint Conf. on Artificial Intelligence (IJCAI'99)</source>
          , pages
          <fpage>96</fpage>
          -
          <lpage>101</lpage>
          ,
          <year>1999</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          , Julian Mendez, and
          <string-name>
            <given-names>Barbara</given-names>
            <surname>Morawska</surname>
          </string-name>
          . UEL:
          <article-title>Unification solver for the description logic EL - system description</article-title>
          .
          <source>In Proc. of the 6th International Joint Conference on Automated Reasoning (IJCAR</source>
          <year>2012</year>
          ), volume
          <volume>7364</volume>
          <source>of Lecture Notes in Artificial Intelligence</source>
          , pages
          <fpage>45</fpage>
          -
          <lpage>51</lpage>
          . Springer,
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Barbara</given-names>
            <surname>Morawska</surname>
          </string-name>
          .
          <article-title>Unification in the description logic EL</article-title>
          . In Ralf Treinen, editor,
          <source>Proc. of the 20th Int. Conf. on Rewriting Techniques and Applications (RTA</source>
          <year>2009</year>
          ), volume
          <volume>5595</volume>
          of Lecture Notes in Computer Science, pages
          <fpage>350</fpage>
          -
          <lpage>364</lpage>
          . Springer-Verlag,
          <year>2009</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Barbara</given-names>
            <surname>Morawska</surname>
          </string-name>
          .
          <article-title>SAT encoding of unification in EL</article-title>
          . In C.
          <article-title>Fermüller and A</article-title>
          . Voronkov, editors,
          <source>Proc. of the 17th Int. Conf. on Logic for Programming</source>
          ,
          <source>Artifical Intelligence, and Reasoning (LPAR-17)</source>
          , volume
          <volume>6397</volume>
          of Lecture Notes in Computer Science, pages
          <fpage>97</fpage>
          -
          <lpage>111</lpage>
          ,
          <string-name>
            <surname>Yogyakarta</surname>
          </string-name>
          (Indonesia),
          <year>2010</year>
          . Springer-Verlag.
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          11.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Barbara</given-names>
            <surname>Morawska</surname>
          </string-name>
          .
          <article-title>Unification in the description logic EL</article-title>
          .
          <source>Logical Methods in Computer Science</source>
          ,
          <volume>6</volume>
          (
          <issue>3</issue>
          ),
          <year>2010</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          12.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Paliath</given-names>
            <surname>Narendran</surname>
          </string-name>
          .
          <article-title>Unification of concept terms in description logics</article-title>
          .
          <source>J. Symbolic Computation</source>
          ,
          <volume>31</volume>
          (
          <issue>3</issue>
          ):
          <fpage>277</fpage>
          -
          <lpage>305</lpage>
          ,
          <year>2001</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          13.
          <string-name>
            <given-names>Franz</given-names>
            <surname>Baader</surname>
          </string-name>
          and
          <string-name>
            <given-names>Wayne</given-names>
            <surname>Snyder</surname>
          </string-name>
          .
          <article-title>Unification theory</article-title>
          .
          <source>In J.A. Robinson and A</source>
          . Voronkov, editors,
          <source>Handbook of Automated Reasoning</source>
          , volume I, pages
          <fpage>447</fpage>
          -
          <lpage>533</lpage>
          . Elsevier Science Publishers,
          <year>2001</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          14.
          <string-name>
            <surname>Philippe</surname>
            <given-names>Balbiani</given-names>
          </string-name>
          , Cigdem Gencer, Maryam Rostamigiv, and
          <string-name>
            <given-names>Tinko</given-names>
            <surname>Tinchev</surname>
          </string-name>
          .
          <article-title>About the unification type of K + ?</article-title>
          .
          <source>In Proc. of the 34th International Workshop on Unification (UNIF</source>
          <year>2020</year>
          ), pages
          <fpage>4</fpage>
          :
          <fpage>1</fpage>
          -
          <issue>4</issue>
          :
          <fpage>6</fpage>
          .
          <string-name>
            <surname>RISC-Linz</surname>
          </string-name>
          ,
          <year>2020</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          15.
          <string-name>
            <given-names>Emil</given-names>
            <surname>Jerabek</surname>
          </string-name>
          .
          <article-title>Blending margins: The modal logic K has nullary unification type</article-title>
          .
          <source>J. Logic and Computation</source>
          ,
          <volume>25</volume>
          (
          <issue>5</issue>
          ):
          <fpage>1231</fpage>
          -
          <lpage>1240</lpage>
          ,
          <year>2015</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          16. Ajay Kumar Eeralla and
          <string-name>
            <given-names>Christopher</given-names>
            <surname>Lynch</surname>
          </string-name>
          .
          <article-title>Bounded ACh unification</article-title>
          .
          <source>Math. Struct. Comput. Sci.</source>
          ,
          <volume>30</volume>
          (
          <issue>6</issue>
          ):
          <fpage>664</fpage>
          -
          <lpage>682</lpage>
          ,
          <year>2020</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          17.
          <string-name>
            <given-names>Ralf</given-names>
            <surname>Küsters</surname>
          </string-name>
          .
          <article-title>Non-standard Inferences in Description Logics</article-title>
          , volume
          <volume>2100</volume>
          <source>of Lecture Notes in Artificial Intelligence</source>
          . Springer-Verlag,
          <year>2001</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          18.
          <string-name>
            <given-names>Paliath</given-names>
            <surname>Narendran</surname>
          </string-name>
          .
          <article-title>Solving linear equations over polynomial semirings</article-title>
          .
          <source>In Proc. of the 11th Annual IEEE Symposium on Logic in Computer Science (LICS</source>
          <year>1996</year>
          ), pages
          <fpage>466</fpage>
          -
          <lpage>472</lpage>
          . IEEE Computer Society,
          <year>1996</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          19.
          <string-name>
            <given-names>Rafael</given-names>
            <surname>Peñaloza</surname>
          </string-name>
          and
          <string-name>
            <surname>Anni-Yasmin Turhan</surname>
          </string-name>
          .
          <article-title>A practical approach for computing generalization inferences in EL</article-title>
          . In Grigoris Antoniou, Marko Grobelnik, Elena Paslaru Bontas Simperl, Bijan Parsia, Dimitris Plexousakis, Pieter De Leenheer, and Jeff Z. Pan, editors,
          <source>Proc. of the 8th Extended Semantic Web Conference (ESWC</source>
          <year>2011</year>
          ), volume
          <volume>6643</volume>
          of Lecture Notes in Computer Science, pages
          <fpage>410</fpage>
          -
          <lpage>423</lpage>
          . Springer,
          <year>2011</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>