Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-owl] Problem with ProtegeReasoner.getIndividualsBelongingToClass(OWLClass) method

Mariusz Gwiazda mgwiazda at onet.eu
Mon May 5 02:53:04 PDT 2008


Tania,

Thanks You for reply.

I took a look at direct Pellet reasoner implementation and I created 
simple test case (attached ontology and Java program). Property 
"property_1" has as range union of  Class_1 and Class_2 classes, 
Property "property_2" has range intersection of  Class_3 and Class_4. 
Property "property_3" has range Class_5.

It works if I use ProtegePelletOWLAPIReasoner implementation. The output 
of the program is:

 >>> Individual Class_2_1 belong to range of property property_1
 >>> Individual Class_1_1 belong to range of property property_1
 >>> Individual Class_3_and_4_1 belong to range of property property_2
 >>> Individual Class_5_1 belong to range of property property_3

That is correct. But if I use ProtegePelletJenaReasoner, I got only:

 >>> Individual Class_5_1 belong to range of property property_3.

I'm using ProtegePelletJenaReasoner implementation because I want to run 
SWRL via Pellet.

It is possible that this bug will be fixed in next beta? or when 
ProtegePelletOWLAPIReasoner will support SWRL rules?

Best wishes,
Mariusz


Tania Tudorache wrote:
> Interesting. I've just did a test and it actually returned the inferred 
> individuals of an intersection.
>
> I used your example, and got the union class from the range of a 
> property. Then, I asked for the individuals belonging to that union and 
> it returned the expected results.
>
> This should work in the latest beta (build 130). I suppose this is what 
> you used, too.
>
> If you still have problems with this, can you please send me the 
> ontology that has this behavior, and write me also exactly for what 
> union class you were trying to get the individuals.
>
> Thanks,
> Tania
>
>
> Mariusz Gwiazda wrote:
>   
>> Dear All,
>>
>> I'm using 
>> ProtegePelletJenaReasoner.getIndividualsBelongingToClass(OWLClass) 
>> method to get all individuals that belong to the range of property. In 
>> my ontology ranges of properties are OWLNamedClass or union of this kind 
>> of classes. I'm getting property range as OWLClass on this way:
>>
>> RDFResource range = property.getRange(true);
>> OWLClass cls = (OWLClass) range;
>>
>> If cls object is exactly object of OWLNamedClass, method returns 
>> appropriate individuals. Problem starts when I pass to this method 
>> OWLUnionClass object (simple union of OWLNamedClass), it returns 
>> nothing. It happens also for OWLIntersectionClass.
>>
>> It is a bug?
>>
>> For now, I write some workaround. I get all operands of OWLUnionClass 
>> and for each operand I invoke getIndividualsBelongingToClass method, but 
>> this is not universal solution.
>>
>>
>> Best wishes,
>> Mariusz
>> _______________________________________________
>> protege-owl mailing list
>> protege-owl at lists.stanford.edu
>> https://mailman.stanford.edu/mailman/listinfo/protege-owl
>>
>> Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03 
>>
>>   
>>     
>
> _______________________________________________
> protege-owl mailing list
> protege-owl at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/protege-owl
>
> Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03 
>
>   

-------------- next part --------------
A non-text attachment was scrubbed...
Name: reasoning_from_prop_ranges_test.owl
Type: text/rdf
Size: 1610 bytes
Desc: not available
URL: <http://mailman.stanford.edu/pipermail/protege-owl/attachments/20080505/f89c5c01/attachment.owl>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ReasoningTest.java
Type: text/x-java
Size: 2624 bytes
Desc: not available
URL: <http://mailman.stanford.edu/pipermail/protege-owl/attachments/20080505/f89c5c01/attachment.java>


More information about the protege-owl mailing list