Re: Rule-based approach to conclude owl:intersectionOf

The rules look cool. Is it called.. backward-chaining? The drawback I can see is that it generates some more facts which can be as many as n*(n-1)/2. Sticking back to the original 5 facts.. then they should entail 3 owl:oneOf restrictions..

<#A> rdf:type <#X> , <#Y> , <#Z> .
<#B> rdf:type <#Y> .
<#C> rdf:type <#Z> .

# entail

<#X> owl:oneOf ( <#A> ) .
<#Y> owl:oneOf ( <#A> <#B> ) .
<#Z> owl:oneOf ( <#A> <#C> ) .

Here comes the problem of collection generation and attaching the owl:oneOf vocabulary to the head of the list. Can rules generate a collection? (Thinking...)

By the way, what is the "filter" for?


Jeremy

----- Original Message ----- 
From: <jos.deroo@agfa.com>
To: <jos.deroo@agfa.com>
Cc: "Jeremy Wong 黃泓量" <50263336@student.cityu..edu.hk>; "Chris Purcell" <cjp39@cam.ac.uk>; <semantic-web@w3.org>
Sent: Wednesday, April 06, 2005 6:55 AM
Subject: Re: Rule-based approach to conclude owl:intersectionOf


> did some slight changes and also tested with cwm
> 
> ### given
> 
> @prefix owl: <http://www.w3.org/2002/07/owl#>.
> @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
> @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
> @prefix : <http://example.org/eg#>.
> 
> :X owl:oneOf ( :A ).
> :Y owl:oneOf ( :A :B ).
> :Z owl:oneOf ( :A :C ).
> 
> 
> {?B has owl:oneOf ?Y.
> ?A has owl:oneOf ?X.
> ?Y :includes ?X}
> =>
> {?A rdfs:subClassOf ?B}.
> 
> 
> {?X a rdf:List}
> =>
> {?X :includes rdf:nil}.
> 
> {?S rdf:first ?A;
>    a rdf:List.
> ?X :item ?A.
> ?S rdf:rest ?B;
>    a rdf:List.
> ?X :includes ?B}
> =>
> {?X :includes ?S}.
> 
> 
> {?L rdf:first ?I;
>    a rdf:List}
> =>
> {?L :item ?I}.
> 
> {?L rdf:rest ?R;
>    a rdf:List.
> ?R :item ?I}
> =>
> {?L :item ?I}.
> 
> 
> {?S owl:oneOf ?X}
> =>
> {?X a rdf:List}.
> 
> {?L rdf:rest ?X;
>    a rdf:List}
> =>
> {?X a rdf:List}.
> 
> 
> ### filter
> 
> @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
> @prefix : <http://example.org/eg#>.
> 
> {:X rdfs:subClassOf :Y, :Z} => {:X rdfs:subClassOf :Y, :Z}.
> 
> 
> ### gives
> 
>     @prefix : <http://example.org/eg#> .
>     @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
> 
>    :X     rdfs:subClassOf :Y,
>                :Z .
> 
> 
> -- 
> Jos De Roo, AGFA http://www.agfa.com/w3c/jdroo/
> 
> 
> 
> 
> Jos De_Roo
> 05/04/2005 22:06
> 
> 
>        To:     Jeremy Wong 黃泓量 <50263336@student.cityu.edu.hk>@AGFASMTP
>        cc:     Chris Purcell <cjp39@cam.ac.uk>, semantic-web@w3.org
>        Subject:        Re: Rule-based approach to conclude owl:intersectionOf
> 
>> Oh my God.. i'd not make mistake again if it's in set..
> 
> :)
> 
>> CEXT(S(#X)) = {<#A>}
>> CEXT(S(#Y)) = {<#A>,<#B>}
>> CEXT(S(#Z)) = {<#A>,<#C>}
>> i.e.
>> <#A> rdf:type <#X> , <#Y> , <#Z> .
>> <#B> rdf:type <#Y> .
>> <#C> rdf:type <#Z> .
>> =>
>> <#X> rdfs:subClassOf <#Y> , <#Z> .
>> =>
>> <#X> owl:intersectionOf (<#Y>,<#Z>) .
>>
>> I admit that this kind of inference requires a condition that the 
> collection 
>> of facts is complete. Otherwise the inference results may be ruined if a 
> 
>> fact like <#B> rdf:type <#X> is asserted. However, it is not a too bad 
>> interpretation because the OWL interpretation still satisifies the RDF 
> graph 
>> above.
> 
> One could say
> :X owl:oneOf ( :A ).
> :Y owl:oneOf ( :A :B ).
> :Z owl:oneOf ( :A :C ).
> 
> and then
> :X rdfs:subClassOf :Y, :Z.
> 
> easily follows, using such rules as
> 
> { ?B has owl:oneOf ?Y.
>  ?A has owl:oneOf ?X.
>  ?Y :includes ?X }
>  =>
> { ?A rdfs:subClassOf ?B }.
> 
> 
> { }
>  =>
> { ?X :includes rdf:nil }.
> 
> { ?S rdf:first ?A.
>  ?X :item ?E.
>  ?E has owl:equivalentClass ?A.
>  ?S rdf:rest ?B.
>  ?X :includes ?B }
>  =>
> { ?X :includes ?S }.
> 
> 
> { ?S rdf:first ?X }
>  =>
> { ?S :item ?X }.
> 
> { ?S rdf:rest ?B.
>  ?B :item ?X }
>  =>
> { ?S :item ?X }.
> 
> 
> At this moment, I can't find proof for
> :X owl:intersectionOf ( :Y :Z ).
> 
> i.e. probably have to add some more owl-rules..
> 
> 
>> In addition, my main concern is the use of the universal quantification 
> and 
>> the existential quantification. It is because N3 Rules cannot express 
> the 
>> inference described in the above example. My work of rules shows that N3 
> 
>> Rules is very weak to model OWL restrictions, anyway. I hope to discuss 
> or 
>> to find out the use of the quantification facilities so that the 
> rule-based 
>> approach becomes more powerful as expected.
> 
> You can have look at
> http://www.w3.org/2000/10/swap/doc/Rules
> and convince yourself that it can be easily done :)
> 
>> :)
>> Jeremy
> 
> -- 
> Jos De Roo, AGFA http://www.agfa.com/w3c/jdroo/
> 
> 
> 
>

Received on Wednesday, 6 April 2005 02:31:40 UTC