# Re: N3/CWM formulae, how they relate to graph nodes, and graph comparison

From: Graham Klyne <gk@ninebynine.org>
Date: Fri, 25 Apr 2003 11:59:10 +0100
Message-Id: <5.1.0.14.2.20030425113712.02e23dc8@127.0.0.1>
To: Karsten Otto <otto@math.fu-berlin.de>
Cc: RDF interest group <www-rdf-interest@w3.org>
```
At 11:15 25/04/2003 +0200, Karsten Otto wrote:
>Consider a more simple example: Let's say you had stated
>
>_:x :- { ex:s1 ex:p1 ex:o1 . } .
>_:x :- { ex:s2 ex:p2 ex:o2 . } .
>
>or, for that matter
>
>{ ex:s1 ex:p1 ex:o1 . } :- { ex:s2 ex:p2 ex:o2 . } .
>
>This works nicely in accordance to my interpretation above, you simply
>combine the two nodes together, and basically get
>
>{ ex:s1 ex:p1 ex:o1 . ex:s2 ex:p2 ex:o2 . } .
>
>This also works if you have [] nodes instead of {}.

OK, that looks like another possible interpretation, which overcomes some
of the problems I was having.  It even seems to play reasonably with the
style existing RDF semantics, in that if we say:

ex:f :- { ex:s1 ex:p1 ex:o1 . ex:s2 ex:p2 ex:o2 . } .

then whenever ex:f is true, then so are:

ex:f1 :- { ex:s1 ex:p1 ex:o1 . } .
and
ex:f2 :- { ex:s2 ex:p2 ex:o2 . } .

so the subgraph lemma [1] continues to work even when RDF is extended to
allow nested formulae.

[1] http://www.w3.org/TR/rdf-mt/#entail

It also seems to follow the open-world approach of RDF; i.e. asserting that
some statements are true,        does not deny the truth of additional
information.   Or, if formulae are used (as in CWM) to describe simple
inference rules:

[r1]   { ex:s1 ex:p1 ex:o1 . ex:s2 ex:p2 ex:o2 . } log:implies { exc:s1
exc:p1 exc:o1 . } .
would entail:
[r2]   { ex:s1 ex:p1 ex:o1 . } log:implies { exc:s1 exc:p1 exc:o1 . } .
(i.e. it's always safe to draw the conclusion in [r2] when it holds in [r1]

Similarly
[r3]   { ex:s1 ex:p1 ex:o1 . } log:implies { exc:s1 exc:p1 exc:o1 . exc:s2
exc:p2 exc:o2 . } .
would entail:
[r4]   { ex:s1 ex:p1 ex:o1 . } log:implies { exc:s1 exc:p1 exc:o1 . } .

So how does this play with my graph-matching question?  I don't think it
provides a complete answer, but it suggests some possible lines to think

Because formulae are not a standard part of RDF (even though I personally
believe they are potentially very useful), I don't want to invest too much
effort in following a line that is incompatible with what other folks are
doing.  I'd be interested to hear from folks who are actually using
formulae in applications.

>Now, if you use a non-anonymous node with the :- operator, matters
>become difficult. It means that your anonymous node is not anonymous at
>all, but in fact a named node! The mechanism still works, but it is
>somewhat counter-intuitive. Consider:
>
>ex:a :- [ ex:p1 ex:o1 . ] .
>
>becomes
>
>ex:a ex:p1 ex:o1 .

Yes, that's exactly how I would expect :- to work with [...] (and my N3
parser would return identical graphs for both cases).

#g

-------------------
Graham Klyne
<GK@NineByNine.org>
PGP: 0FAA 69FF C083 000B A2E9  A131 01B9 1C7A DBCA CB5E
```
Received on Friday, 25 April 2003 08:04:19 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:44:41 UTC