Search code examples
rdfowlrdfsturtle-rdf

If I have a annotation property has and each child (Y,Z) has property canDo, how can the Y inherit all the canDo?


I am working with Turtle and OWL.

Say X is a class has a number of properties that it includes. How can I make the X have the same properties as all its children classes (Y and Z)?

:has a owl:ObjectProperty
:canDo a owl:ObjectProperty

:X :has :Y
:X :has :Z

:Y :canDo :thingA
:Y :canDo :thingB

:Z :canDo :thingC
:Z :canDo :thingD

I want the reasoner to infer :X :canDo :thingA.

Is this a transitive property, even if the classes are different?


Solution

  • I found the answer. You can use property chaining.

    [] rdfs:subPropertyOf :canDo;
       owl:propertyChain (
         :has
         :canDo
    ).
    

    see OWL 2 in Action – Property Chains