Ontology: OWL - creating relationships between classes

I have an ontology written in OWL with Protege. But I did not find a solution to create relationships between classes. Of course, there is a subclass relationship, but I want to define my own relationships. Therefore, I have a class hierarchy (which consists of a β€œsubclass” of links), but I want to create a relation, that is, has_Relation, to connect the two classes.

My goal is to write a java program in which I can get the information "which class is the parent class of the class?" and "to which class has_Relation connection?"

(I'm not talking about people - I'm just talking about classes)

Thanks so much for your help in advance!

Best regards Nathan

+7
source share
2 answers

The easiest way to do this is to use the annotation property. In ProtΓ©gΓ©, select the class you want to associate with another class, then click + next to Annotations in the Annotations tab. Then add the has_Relation property with the second button in the upper left corner of the window. Then select the IRI Entity tab and the Classes subtitle, select another class that you want to associate with, and you are done.

However, you should not do this if has_Relation is an object property or a data type property. If so, you can use "punning", that is, you can create new people on the "Individuals" tab with the same names as the classes you want to link. Then you classify them as if they were normal people. Please note that this is allowed and valid in OWL 2 DL.

+8
source

a little late, but:

You can also go to the tab menu and activate the object properties tab (Window> Tabs β†’ Object Properties).

Then you can create your own property of the object and assign its domain and range to the classes that you need (description area of ​​an individual property).

0
source

Source: https://habr.com/ru/post/919132/


All Articles