title: protege compound class restrictions with some and only
body: <p>I've looked around and cannot really find an answer to why the following property restriction works in one case but does not work in the other. I am trying to combine &quot;some&quot; and &quot;only&quot; object property restrictions to require that a defined class have only a certain property+object <em>and</em> that it also have at least one such property+object defined. I cannot get this combination to produce the intended class inference. I want to use it to identify an instance with a certain combination of type and property assertions as the specified class. I do not intend to use it to assign an instance to be a type of that class (if that matters).</p>
  <p>The RDF/OWL file is at: <a href="https://pastebin.com/NZMCuZjE" rel="nofollow noreferrer">https://pastebin.com/NZMCuZjE</a><br/>
  I built it using Protege 5.5. Both reasoners (FaCT++ 1.6.5 and HermiT 1.4.3.456) give the same result.</p>
  <p>I expected that defining <strong>X_LetterThing</strong> as equivalent to<br/>
    <strong>LetterThing</strong> <em>and</em> (<strong>hasLetter</strong> <em>only</em> <strong>X</strong>) <em>and</em> (<strong>hasLetter</strong> <em>some</em> <strong>X</strong>)<br/>
  would have the effect of inferring that instance <strong>x_letter_thing_test</strong> is of Type <strong>X_LetterThing</strong> since <strong>x_letter_thing_test</strong> has asserted type <strong>LetterThing</strong> and has object property assertion <strong>hasLetter x</strong>, but there is no such inference.</p>
  <p>A second related problem is that the instance <strong>compound_letter_thing_test</strong> is not inferred to be of type <strong>Compound_LetterThing</strong> unless I include a covering axiom for class <strong>LetterThing</strong>, which I really can't have. (Also, adding the covering axiom has no effect on the first problem.)</p>
  <p>Is this OWA or something else?</p>
  <p>Thanks!</p>
  <pre><code>d.c
  </code></pre>