OWL: How to get inheritance of property relations between two classes from those of superclasses?

戏子无情 提交于 2019-12-02 06:12:58

问题


Let's say we have two classes named People and Disease. These classes are related by the Object Property has.

:People :has :Disease

People has subclass (or individual) John, and Disease has subclass (or individual) Cancer.

:John a :People
:Cancer a :Disease

How can we get the relationship between these subclasses by inference?

:John :has :Cancer

回答1:


Before you can get to an answer, there are a number of misconceptions you'll need to resolve.

First, subclass and individual are very different concepts. Individuals (instances) are members of classes. Subclass denotes a class is a subset of another class, meaning that an implication (via inference) is that all members of a subclass are members of the (super)class. (Just for reference: there is no concept of inheritance in OWL.)

Second class-level properties, such as :People :has :Disease have no meaning for class individuals. The way to define a property's relationships to classes is to set the domain and range of the property. (Just using :has as a property name indicates a wide set of misconceptions, possibly from other types of languages.) So I'd suggest the name :hasDisease and the assertions:

:hasDisease rdfs:domain :People .
:hasDisease rdfs:range :Disease .

Third, you can assert that :John :hasDisease :Cancer and infer that John has a disease, given that :Cancer is a subclass of :Disease. This requires a standard RDFS reasoner. Also, given the domain and range definitions above, and an assertion :Joy :hasDisease :Gout, an RDFS reasoner will infer that :Joy a :Person and :Gout a :Disease.

There are a few OWL primers out there that you can find via Google. I'd suggest going over some of these to get a basic understanding of how OWL and reasoning profiles work.



来源:https://stackoverflow.com/questions/37141784/owl-how-to-get-inheritance-of-property-relations-between-two-classes-from-those

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!