From: Erik Naggum <erik@naggum.no>
Reply-To: Erik Naggum <enag@ifi.uio.no>
Date: 31 Jul 1992 03:56:43 +0200
Subject: Venn diagrams

I have been unable to define the exact location of the heads and tails
of Darrell's argumentation, and the more I have (re-)read his articles,
the more evident it has become that Darrell does not know SGML, although
he argues as if he does.  I'll try to address some of the questions he
has posed, and some of the problems in his argumentation which stem
purely from lack of an understanding of SGML.  First to go is the Venn
diagram problem which seems to have caused a lot of trouble, mostly
because people have argued against Darrell on his premises.

My solution to this problem uses the fact that SGML does, indeed, not
specify any semantics for the individual elements or for the element
structure.  Relatively intuitive, however, are some relations between
elements, such as "precedes", "succeeds", "contains", and "is contained
by".  Each distinct element is also seen as a separate instance of the
element type.  Further, the content of one element is not also the
content of parent elements, although the child element itself is.

I have chosen to redefine the semantics of the relations between
elements in a particular element, which I call "Venn".  First, the
element type is considered to be the name of a set.  Set members are
words ("sequence of non-blanks separated by blanks").  "Precedes" and
"succeeds" have no meaning.  The relations "contains" and "is contained
by" have separate definitions for sub-elements and data, where they for
data mean "has member" and "is member of", respectively, and for
elements mean "imports members from", and "exports members to",
respectively.  Space only serve to separate the words, and have no
meaning.

In SGML, this is expressed as follows:

    <!ENTITY % sets "X | Y | Z" >

    <!ELEMENT Venn  (%sets)+ >
    <!ELEMENT %sets (#PCDATA | %sets)* >

Considering the data provided by Darrell, we have the following sets:

    <Venn>
    <X>now is the for</X>
    <Y>is time for all</Y>
    <Z>the for all good</Z>
    </Venn>

which merely lists the members of each set, and all relations are
implicit on the condition that a word is the unique name of a member.
The Venn diagram with all possible intersections, and one word in each
intersection can be expressed thus:

    <Venn>
    <X>now<Y>is</Y><Z>the</Z></X><Y>time<Z><X>for</X>all</Z></Y><Z>good</Z>
    </Venn>

or, alternatively, to show the relationships better:

    <Venn>
    <X>      now         </X>
    <X><Y>   is      </Y></X>
    <X>   <Z>the </Z>    </X>
       <Y>   time    </Y>
    <X><Y><Z>for </Z></Y></X>
       <Y><Z>all </Z></Y>
          <Z>good</Z>
    </Venn>

Note that these two examples are identical under the semantics defined
by the "Venn" application.

The problem, as posed, was one of overlaps.  It wasn't really about
overlaps at all, but about set relations.  I think, consequently, I have
solved the problem, by redefining the solution space from what Darrell
wanted it to be, because he had intentionally made it empty by the form
of his question.  What else can you expect from somebody who prepares to
publish an article with the title "Markup considered harmful"?  Maybe I
should call this article "markup considered harmful considerd harmful"?

Best regards,
</Erik>
--
Erik Naggum             |  ISO  8879 SGML     |      +47 295 0313
                        |  ISO 10744 HyTime   |
<erik@naggum.no>        |  ISO 10646 UCS      |      Memento, terrigena.
<enag@ifi.uio.no>       |  ISO  9899 C        |      Memento, vita brevis.