0

So I was reading this and it says:

As an example of a necessary and sufficient condition, take a look at the following definition:

:RedThing a owl:Class ; owl:equivalentClass [ a owl:Restriction ; owl:onProperty :color ; owl:hasValue red^^<http://www.w3.org/2001/XMLSchema#string> ]

What I interpret this to mean is that if something is red, then that thing must be a RedThing.Also, if something is a RedThing, then it must be the color red.

When I added this code snippet to Protege, and I write:

:test_subject :color red^^<http://www.w3.org/2001/XMLSchema#string>

Then the following is inferred by the reasoner:

:test_subject rdf:type :RedThing

What this covers is the necessary part of the restriction definition, i.e. if something is red, then that thing must be a RedThing.

When I add the following to an ontology (again using Protege):

test_subject_2 rdf:type :RedThing

Then the following SHOULD be inferred by the reasoner:

:test_subject_2 :color red^^<http://www.w3.org/2001/XMLSchema#string>

Because this is the sufficient part of the condition. i.e if something is a RedThing, then it must be the color red.

BUT it is NOT inferred. What am I missing here?

sam_peels
  • 71
  • 1
  • 4
  • Which reasoner are you using? – Ignazio Apr 23 '16 at 07:20
  • I tried faCT++ and Hermit 1.3.8 - same results – sam_peels Apr 23 '16 at 15:06
  • Data type property inferences aren't shown by default. You may need to check the setting to display them. See the next to last image in [this answer](http://stackoverflow.com/a/21499584/1281433). – Joshua Taylor Apr 23 '16 at 16:22
  • Okay I did that, restarted the reasoner, and I get the same results. BUT I just realized now that when I do a DL query, it says the test_subject_2 instance color is "red". So I think I'm all good and there must be some other reason why the data type inference isn't showing up – sam_peels Apr 24 '16 at 15:41

0 Answers0