W3C home > Mailing lists > Public > public-rif-wg@w3.org > February 2009

ISSUE-80: Meta builtins

From: Chris Welty <cawelty@gmail.com>
Date: Fri, 27 Feb 2009 16:32:01 -0500
Message-ID: <49A85BD1.5070103@gmail.com>
To: "Public-Rif-Wg (E-mail)" <public-rif-wg@w3.org>

Issue-80 was prompted by DaveR's attempt at using RIF-Core to specify the rules 
in OWL-RL.  He suggested it would be much easier, and also promote datatype 
extensibility, if the builtins were more general.  We resolved to have a 
two-argument pred:isLiteralOfType (and its negation), and are currently 
considering literal equality, which is more complicated.

Basically we need a pred:literal-not-equal, or at the very least a not= for each 
datatype.  It seems to make sense to have a pred:literal-equal as well (for 
symmetry, if nothing else), but what does it do? Is it redundant with RIF's = 
predicate?  Does it do numeric comparison?  Is it simply lexical?

At the moment pred:literal-equal is defined to be subsumed by RIF's =.  It does 
not do xs:numeric-equal, which includes type promotion.  Thus we would need to 
keep that, unless this predicate were changed.  RIF= for datatype checks 
identity in the value space.

Jos believed he read somewhere that it is possible for a datatype to have 
multiple values in their value spaces that are identical.  Probably this is from 
dateTime, which is pretty hard to understand - I wasn't able to nail it down 
precisely (the spec says datetimes are compared based on their timeline values). 
  Thus if RIF= already provides value space identity, pred:literal-equal could 
provide the datatype specific equality that F&O specifies for e.g. numerics, 
date-times, etc.

Note:  [XS2] says "Equality" in this Recommendation is defined to be "identity" 
(i.e., values that are identical in the ˇvalue spaceˇ are equal and vice versa). 
Identity must be used for the few operations that are defined in this 
Recommendation. Applications using any of the datatypes defined in this 
Recommendation may use different definitions of equality for computational 
purposes; [IEEE 754-1985]-based computation systems are examples. Nothing in 
this Recommendation should be construed as requiring that such applications use 
identity as their equality relationship when computing.

Solutions:

1) Drop pred:literal-equal
2) Leave pred:literal-equal as is (redundant with RIF =)
3) Redefine pred:literal-equal to perform all the datatype specific equality 
tests including numeric, and remove those datatype specific tests from DTB.

-Chris

[Xs2] http://www.w3.org/TR/xmlschema-2/

-- 
Dr. Christopher A. Welty                    IBM Watson Research Center
+1.914.784.7055                             19 Skyline Dr.
cawelty@gmail.com                           Hawthorne, NY 10532
http://www.research.ibm.com/people/w/welty
Received on Friday, 27 February 2009 21:32:44 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 2 June 2009 18:34:03 GMT