- From: Eric Prud'hommeaux <eric@w3.org>
- Date: Mon, 1 Sep 2014 09:05:56 -0400
- To: Victor Porton <porton@narod.ru>
- Cc: Hm Hrm <unixprog@googlemail.com>, "semantic-web@w3.org" <semantic-web@w3.org>
* Victor Porton <porton@narod.ru> [2014-09-01 15:28+0300] > 01.09.2014, 10:07, "Hm Hrm" <unixprog@googlemail.com>: > > On 08/31/2014 06:43 PM, Victor Porton wrote: > >> Suppose P is a precedence of operation X. Should I write "X a P ." or > >> "X :precedence P ." (in Turtle format)? > >> > >> What are (dis)advantages of both variants? > > > > Assuming that the property should link instance P to instance X, both of > > class :Operation, then you should use "X :precedence P". > > > > "X a P", a shortcut for "X rdf:type P", would imply that P is an > > rdf:Class and X an instance of said class P. Extending the semantics of > > 'rdf:type' and using an instance as a class seems a bad idea. > > P is a class (because I want rdf:subClassOf for properties. > > But I yet doubt whether an operation should be an instance of precedence. I wouldn't advise it, but you could always say that Addition is an instance of a thing with precedence 2 and Multiplication ... 6 (from <http://en.wikipedia.org/wiki/Operators_in_C_and_C%2B%2B#Arithmetic_operators>). My guess is that instead you want to model more like this: :precedenceIncludes a owl:ObjectProperty . :PrecedenceAtLeast1 a owl:Class . :PrecedenceAtLeast2 rdfs:subClassOf a :PrecedenceAtLeast1 . :PrecedenceAtLeast3 rdfs:subClassOf a :PrecedenceAtLeast2 . # ... :Operation a owl:Class; rdfs:subClassOf [ owl:onProperty :precedenceIncludes ; owl:someValuesFrom :PrecedenceAtLeast1 ] . :Addition rdfs:subClassOf :Operation , [ owl:onProperty :precedenceIncludes ; owl:someValuesFrom :PrecedenceAtLeast2 ] :Multiplication rdfs:subClassOf :Operation , [ owl:onProperty :precedenceIncludes ; owl:someValuesFrom :PrecedenceAtLeast6 ] That way you can apply the T-box to an A-box (e.g. a parse graph over which you are doing static analysis) and leverage inferences from the ontology. > -- > Victor Porton - http://portonvictor.org > -- -ericP office: +1.617.599.3509 mobile: +33.6.80.80.35.59 (eric@w3.org) Feel free to forward this message to any list for any purpose other than email address distribution. There are subtle nuances encoded in font variation and clever layout which can only be seen by printing this message on high-clay paper.
Received on Monday, 1 September 2014 13:06:02 UTC