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] SWRL Temporal built-in problem

Martin O'Connor martin.oconnor at stanford.edu
Thu Apr 26 09:43:36 PDT 2007


Unfortunately you will have to manually add new individuals to an 
owl:allDifferents set when you create them. OWL has no way of saying 
that all individuals of a class must be distinct - you can only add a 
list of existing individuals to an allDifferents set.

Martin

>A quick question, the only way I can see to implement the owl:allDifferent
>restriction is manually creating a set through the OWL/edit
>owl:allDifferents menu, then it doesn't seem to show this restriction in the
>GUI under the classes or individuals tab, am I missing where it actually
>shows? 
>
>And would I need to manually redo the set each time an instance of the class
>is added before running the rule? Or can the owl:allDifferents restriction
>be implemented on a class for any future addition of an instance (in a
>similar fashion to the disjoint axiom)? 
>
>Cheers
>Trina
> 
>-----Original Message-----
>From: protege-owl-bounces at lists.stanford.edu
>[mailto:protege-owl-bounces at lists.stanford.edu] On Behalf Of Martin O'Connor
>Sent: Thursday, 26 April 2007 3:49 AM
>To: User support for the Protege-OWL editor
>Subject: Re: [protege-owl] SWRL Temporal built-in problem
>
>
>SWRL's differentFrom construct works only with OWL individuals: 
>http://protege.cim3.net/cgi-bin/wiki.pl?SWRLLanguageFAQ#nid8JM
>
>You are attempting to use it with datatypes.
>
>Also, as far as I can tell from your email, every Environment individual has
>only one Date_Time property value so ?xDate and?yDate will always refer to
>the same value (which is why temporal:equals evaluates to true). I presume
>what you intend to do is to compare datetimes from two different
>environments, e.g.,
>
>Environment(?e1) ^ Environment(?e2) ^ differentFrom(?e1, ?e2) ^
>hasDateTime(?e1, ?dt1) ^ hasDateTime(?e2, ?dt2) ^ temporal:duration(3, ?dt1,
>?dt2, temporal:Days) -> something...
>
>As mentioned in the link above, all individuals of class Environment must
>have the owl:allDifferents restriction defined if the differentFrom clause
>is to work properly with them.
>
>Martin
>
>Trina wrote:
>
>  
>
>>Hi All,
>>
>>Are there any further examples for the SWRL temporal built-ins besides 
>>the Wiki and Martin's paper on querying time-oriented data? I have been 
>>trying the latest implementation (build 395) and am not having a great 
>>deal of success with the rules I am using (which is purely a lack of
>>    
>>
>understanding on my part).
>  
>
>>I am trying to compare the date_time properties of an 'Environment' 
>>class to test if there has been a duration of 3 days. The rule I used was:
>>Environment(?x)  ?
>>Date_Time(?x, ?xDate)  ?
>>Date_Time(?x, ?yDate)  ?
>>differentFrom(?xDate, ?yDate)
>>temporal:duration(3, ?xDate, ?yDate, temporal:Days)
>> ? tempBoolean(?x, true)  **this being an arbitrary property to test 
>>the
>>consequence**
>>
>>The values of the Date_Time property has been set as:
>>(assert (Date_Time Environment_1 "2007-04-25T14:29:43")) (assert 
>>(Date_Time Environment_3 "2007-04-17T14:54:42")) (assert (Date_Time 
>>Environment_4 "2007-04-27T14:08:59")) (assert (Date_Time Environment_2 
>>"2007-04-28T14:30:20")) (assert (Date_Time Environment_5 
>>"2007-04-29T15:03:55"))
>>
>>When I run Jess, nil properties are asserted. If I take out the 
>>differentFrom restriction I get the same outcome.
>>
>>If I use the temporal:equals instead of duration (just to test e.g.
>>temporal:equals(?xDate, ?yDate, temporal:Days), all 'tempBoolean' 
>>properties are asserted to be true, even though they are all different
>>    
>>
>dates.
>  
>
>>Any advice would be appreciated
>>Cheers
>>Trina
>>
>>_______________________________________________
>>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 
>
>_______________________________________________
>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 
>
>  
>




More information about the protege-owl mailing list