类=概念,个体=实例(一个类,你实例化一个类来得到一个个体)
我将继续假设您考虑这些类/概念。
如果只想说 Encryption 是 Cryptography 的一种,那么只需要声明 Ecryption subClassOf Cryptography 即可。根本不需要对象属性。
如果您想使用其他类型的关系,请说“hasRelationYTo”,您将编写公理,例如
加密和 hasRelationYTo 某些/仅加密(曼彻斯特语法)
正如伊格纳齐奥所说,
在 OWL 中,域类表达式和范围类表达式之间没有特定的关系
属性的范围和域 (=relation=function) 是通用的,旨在防止错误。这意味着您不能指定
Domain1 - propA - Range1(但不是,比如 Domain2 - propA - Range1)
Domain2-propA-Range2
对象属性声明只允许您使用{Domain1 U Domain2} - propA - {Range1 U Range2} 之类的声明。如果您真的需要执行上述操作,则必须使用 2 个不同的对象属性 propA 和 propB。通常情况并非如此,将多个域和范围放在一起就足够了。
这是建模的 OWL 文件
“AUTHENTIFICATION”是一种“VALIDATION”
“加密”是一种“加密”
此外,您可能想看看 protege Pizza 教程,以更好地了解 OWL 。如果我没记错的话,它只需要大约20分钟。
<?xml version="1.0"?>
<!DOCTYPE rdf:RDF [
<!ENTITY owl "http://www.w3.org/2002/07/owl#" >
<!ENTITY xsd "http://www.w3.org/2001/XMLSchema#" >
<!ENTITY rdfs "http://www.w3.org/2000/01/rdf-schema#" >
<!ENTITY rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#" >
]>
<!--
///////////////////////////////////////////////////////////////////////////////////////
//
// Object Properties
//
///////////////////////////////////////////////////////////////////////////////////////
-->
<!-- http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#is_a_kind_of -->
<owl:ObjectProperty rdf:about="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#is_a_kind_of"/>
<!--
///////////////////////////////////////////////////////////////////////////////////////
//
// Classes
//
///////////////////////////////////////////////////////////////////////////////////////
-->
<!-- http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#AUTHENTIFICATION -->
<owl:Class rdf:about="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#AUTHENTIFICATION">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#is_a_kind_of"/>
<owl:someValuesFrom rdf:resource="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Validation"/>
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Cryptography -->
<owl:Class rdf:about="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Cryptography">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#is_a_kind_of"/>
<owl:someValuesFrom rdf:resource="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Encryption"/>
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Encryption -->
<owl:Class rdf:about="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Encryption"/>
<!-- http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Validation -->
<owl:Class rdf:about="http://www.semanticweb.org/tudose/ontologies/2014/3/untitled-ontology-59#Validation"/>