Suppose I have
:hasParent rdfs:subPropertyOf :hasAncestor .
:hasAncestor rdf:type owl:TransitiveProperty .
This has the satisfying result of inferring all true ancestor relationships given the parentage. But I'm surprised it doesn't have the negative side-effect of making :hasParent
effectively transitive too. Doesn't p rdfs:subPropertyOf q
mean p "inherits" q's meta-properties, including a owl:TransitiveProperty
?
Seemingly asymmetrically, we see with A rdfs:subClassOf B
and B :hasFriend C
that A :hasFriend C
also since A rdf:type B
. Why doesn't this happen with sub-properties too?
Stanislav has already given a good answer to this question. What I want to address here is the idea mentioned in the comment that "inheritance of classes" are asymmetric with "inheritance of properties".
Object Orientation
(1) In object oriented programming languages, when class A
inherits from class B
, it means that the set of all the instances of class A
is a subset of the set of all the instances of class B
. Moreover, because attributes belong to a specific class, it means class A
will have all the attributes of class B
(i.e.
class A
inherits all the attributes of class B
).
(2) When class A
has an attribute c
of type C
, it states (more or less) that there is an association c
between classes A
and C
.
OWL/RDFS
(1) A big difference with OWL/RDFS is that properties do not belong to a class. When we say that A rdfs:subClassOf B
, we say that the set A
is a subset of B
. It says nothing more. As an example if we have
B a rdfs:Class .
B rdfs:label "Label for class B" .
A a rdfs:Class .
A rdfs:subClassOf B .
class A
will not "inherit" the label of class B
.
(2) Properties in OWL/RDFS are specified between instances, not between classes. I have written about this in detail on my blog. When you state that P rdfs:subProperty R
it means that the set of pairs of individuals in P
is a subset of the set of pairs of individuals in R
.
But Functional Properties are inherited...
No, they are not. It just seems so due to the semantics of functional properties. If we have a property R
that is functional it means a satisfying assignment for R
can be {(a,1), (b,2)}
. That is the same subject cannot be linked to 2 different objects. I.e. you cannot have {(a,1), (a,2)}
.
Now, if you have that P rdfs:subPropertyOf R
, P
is subset of R
and thus P
will be functional as well. I.e. if R = {(a,1), (b,2)}
any subset of R
will be functional as well.