home *** CD-ROM | disk | FTP | other *** search
/ Unix System Administration Handbook 1997 October / usah_oct97.iso / rfc / 1000s / rfc1003.txt < prev    next >
Text File  |  1987-03-12  |  19KB  |  412 lines

  1.  
  2. Network Working Group                                          Alan Katz
  3. Request for Comments: 1003                                       USC/ISI
  4.                                                               March 1987
  5.  
  6.  
  7.         Issues in Defining an Equations Representation Standard
  8.  
  9.  
  10. Status of This Memo
  11.  
  12.     This memo is intended to identify and explore issues in defining a
  13.     standard for the exchange of mathematical equations.  No attempt is
  14.     made at a complete definition and more questions are asked than are
  15.     answered.  Questions about the user interface are only addressed to
  16.     the extent that they affect interchange issues.  Comments are
  17.     welcome.  Distribution of this memo is unlimited.
  18.  
  19. I.  Introduction
  20.  
  21.     Since the early days of the Arpanet, electronic mail has been in
  22.     wide use and many regard it as an essential tool.  Numerous mailing
  23.     lists and newsgroups have sprung up over the years, allowing large
  24.     numbers of people all over the world to participate remotely in
  25.     discussions on a variety of topics.  More recently, multimedia mail
  26.     systems have been developed which allow users to not only send and
  27.     receive text messages, but also those containing voice, bitmaps,
  28.     graphics, and other electronic media.
  29.  
  30.     Most of us in the Internet community take electronic mail for
  31.     granted, but for the rest of the world, it is a brand new
  32.     capability.  Many are not convinced that electronic mail will be
  33.     useful for them and may also feel it is just an infinite time sink
  34.     (as we all know, this is actually true).  In particular, most
  35.     scientists (apart from computer scientists) do not yet use, or are
  36.     just beginning to use, electronic mail.
  37.  
  38.     The current NSF supercomputer initiative may change this.  Its
  39.     primary purpose is to provide remote supercomputer access to a much
  40.     greater number of scientists across the country.  However, doing
  41.     this will involve the interconnection of many university-wide
  42.     networks to NSF supercomputer sites and therefore to the NSF
  43.     backbone network.  Thus, in the very near future we will have a
  44.     large number of scientists in the country suddenly able to
  45.     communicate via electronic mail.
  46.  
  47.     Generally, text-only mail has sufficed up until now.  One can dream
  48.     of the day (not so far in the future) when everyone will have
  49.     bitmapped display workstations with multimedia mail systems, but we
  50.     can get by without it for now.  I believe, however, that the new NSF
  51.     user community will find one other capability almost essential in
  52.     making electronic mail useful to them, and that is the ability to
  53.  
  54.  
  55.  
  56. Katz                                                            [Page 1]
  57.  
  58. RFC 1003                                                      March 1987
  59.  
  60.  
  61.     include equations in messages.
  62.  
  63.     A glance through any scientific journal will demonstrate the
  64.     importance of equations in scientific communication.  Indeed, papers
  65.     in some fields seem to contain more mathematics than English.  It is
  66.     hard to imagine that when people in these fields are connected into
  67.     an electronic mail community they will be satisfied with a mail
  68.     system which doesn't allow equations.  Indeed, with the advent of
  69.     the NSF's Experimental Research in Electronic Submission (EXPRESS)
  70.     project, scientists will begin submitting manuscripts and project
  71.     proposals directly through electronic mail and the ability to handle
  72.     equations will be essential.
  73.  
  74.     Currently, there exists no standard for the representation of
  75.     equations.  In fact, there is not even agreement on what it is that
  76.     ought to be represented.  Users of particular equation systems (such
  77.     as LaTex or EQN) sometimes advocate just including source files of
  78.     that system in messages, but this may not be a good long-term
  79.     solution.  With the new NSF community coming on line in the near
  80.     future, I feel the time is now right to try to define a standard
  81.     which will meet the present and future needs of the user community.
  82.  
  83.     Such a standard should allow the interchange of equations via
  84.     electronic mail as well as be compatible with as many existing
  85.     systems as possible.  It should be as general as possible, but still
  86.     efficiently represent those aspects of equations which are most
  87.     commonly used.  One point to be kept in mind is that most equations
  88.     typesetting is currently being done by secretaries and professional
  89.     typesetters who do not know what the equations mean, only what they
  90.     look like.  Although this is mainly a user interface consideration,
  91.     any proposed standard must not require the user to understand an
  92.     equation in order to type it in.  We are not interested here in
  93.     representing mathematics, only displayed equations.
  94.  
  95.     In this memo, I will try to raise issues that will need to be
  96.     considered in defining such a standard and to get a handle on what
  97.     it is that needs to be represented.  Hopefully, this  will form the
  98.     basis of a discussion leading eventually to a definition.  Before
  99.     examining what it is that could be or should be represented in the
  100.     standard, we will first review the characteristics of some existing
  101.     systems.
  102.  
  103. 2.  Existing Systems
  104.  
  105.     There currently exist many incompatible systems which can handle
  106.     equations to a certain extent. Most of these are extensions to text
  107.     formatting systems to allow the inclusion of equations.  As such,
  108.     general representation and standards considerations were not a major
  109.     concern when these systems were initially designed.  We will examine
  110.     the three main types of systems: Directive systems, Symbolic
  111.     Language systems, and Full Display systems.
  112.  
  113.  
  114.  
  115. Katz                                                            [Page 2]
  116.  
  117. RFC 1003                                                      March 1987
  118.  
  119.  
  120.     Some text editing facilities simply allow an expanded font set which
  121.     includes those symbols typically used in mathematics.  I do not
  122.     consider these systems as truly able to handle equations since much
  123.     of mathematics cannot be represented.  It takes more than the Greek
  124.     alphabet and an integral and square root symbol to make an equations
  125.     system.
  126.  
  127.     Directive systems are those which represent equations and formating
  128.     information in terms of directives embedded in the text.  LaTex and
  129.     EQN are two examples.  LaTex is a more friendly version of Knuth's
  130.     Tex system, while EQN is a preprocessor for Troff, a document
  131.     preparation system available under Unix.
  132.  
  133.     With these Directive systems, it is usually necessary to actually
  134.     print out the document to see what the equations and formatted text
  135.     will look like, although there are on-screen previewers which run on
  136.     workstations such as the Sun.  Directive systems have the advantage
  137.     that the source files are just text and can be edited with standard
  138.     text editors (such as Emacs) and transferred as text in standard
  139.     electronic messages (a big advantage considering existing mail
  140.     interconnectivity of the various user communities).  Also, it is
  141.     relatively easy to make global changes with the help of your
  142.     favorite text editor (for example, to change all Greek letter
  143.     alpha's to beta's or all integrals to summation signs in a document.
  144.     This is generally impossible with the other types of systems
  145.     described below).
  146.  
  147.     The primary disadvantage of these systems is that writing an
  148.     equation corresponds to writing a portion of a computer program.
  149.     The equations are sometimes hard to read, generally hard to edit,
  150.     and one may make syntax errors which are hard to identify.  Also,
  151.     people who are not used to programming, and typesetters who do not
  152.     actually know what an equation means, only what it should look like,
  153.     find specifying an equation in this language very difficult and may
  154.     not be willing to put up with it.
  155.  
  156.     Full Display Systems are those such as Xerox STAR and VIEWPOINT.
  157.     The user enters an equation using the keyboard and sees exactly that
  158.     equation displayed as it is typed.  At all times, what is displayed
  159.     is exactly how things will look when it is printed out.
  160.     Unfortunately, VIEWPOINT does not allow the user to place any symbol
  161.     anywhere on the page.  There are many things (such as putting dots
  162.     on indices) which are not possible.  For those things which are
  163.     implemented, it works rather nicely.
  164.  
  165.     Hockney's Egg is a display system which was developed at the UCLA
  166.     Physics Department and runs on the IBM PC.  It has the advantage of
  167.     being able to put any character of any font anywhere on the screen,
  168.     thus allowing not only equations, but things like chemical diagrams.
  169.  
  170.  
  171.  
  172.  
  173.  
  174. Katz                                                            [Page 3]
  175.  
  176. RFC 1003                                                      March 1987
  177.  
  178.  
  179.     Interleaf's Workstation Publishing Software system is not strictly
  180.     speaking an equations system, but equations may be entered via a cut
  181.     and paste method.  At all times, what one sees is what will be
  182.     printed out and one may put any symbol anywhere on the page.  The
  183.     problem with this system is that one HAS TO put everything in a
  184.     certain place.  It sometimes takes an enormous amount of work to get
  185.     things to be positioned correctly and to look nice.
  186.  
  187.     Generally, Full Display Systems are specific to a particular piece
  188.     of hardware and the internal representation of the equations is not
  189.     only hidden from the user, but is in many cases proprietary.
  190.  
  191.     Symbolic Language systems, such as Macsyma and Reduce, also allow
  192.     the entry of equations.  These are in the form of program function
  193.     calls.  These are systems that actually know some mathematics.  One
  194.     can only enter the particular type of mathematics that the system
  195.     knows.
  196.  
  197.     We next will look at what should be represented in an equations
  198.     system.  We will want a representation standard general enough to
  199.     allow (almost) anything which comes up to be represented, but does
  200.     not require vast amounts of storage.
  201.  
  202. 3.  What Could be Represented?
  203.  
  204.     We will first examine what it is that could be represented.  At the
  205.     most primative level, one could simply store a bitmap of each
  206.     printed equation (expensive in terms of storage).  At the other end
  207.     of the spectrum, one could represent the actual mathematical
  208.     information that the equation itself represents (as in the input to
  209.     Macsyma).  In between, one could represent the mathematical symbols
  210.     and where they are, or represent a standard set of mathematical
  211.     notation, as in EQN.
  212.  
  213.     It is useful to think of an analogy with printed text.  Suppose we
  214.     have text printed in a certain font.  How could it be represented?
  215.     Well, we could store a bitmap of the printed text, store characters
  216.     and fonts, store words, or at the most abstract, we could store the
  217.     meaning behind the words.
  218.  
  219.     What we actually do, of course, is store characters (in ordinary
  220.     text) and sometimes fonts (in text intended to be printed).  We do
  221.     not attempt to represent the meaning of words, or even represent the
  222.     notion of a word.  We generally only have characters, separated by
  223.     spaces or carriage returns (which are also characters).  Even when
  224.     we specify fonts, if a slightly different one happened to be printed
  225.     out it would not matter greatly.
  226.  
  227.     Equations may be considered an extension of ordinary text, together
  228.     with particular fonts.  However, the choice of font may be extremely
  229.     important.  If the wrong font happens to be printed out, the meaning
  230.  
  231.  
  232.  
  233. Katz                                                            [Page 4]
  234.  
  235. RFC 1003                                                      March 1987
  236.  
  237.  
  238.     of the equation may be completely changed.  There are also items,
  239.     such as growing parentheses, fractions, and matrices, which are
  240.     particular to equations.
  241.  
  242.     We are not interested in representing the meaning of an equation,
  243.     even if we knew how to in general, but in representing a picture of
  244.     the equation.  Thus, we will not further consider the types of
  245.     representations made in the Symbolic Language systems.  We still
  246.     have Directive systems and the Full Display systems.  We shall
  247.     assume that both of these will continue to exist and that the
  248.     defined standard should be able to deal with existing systems of
  249.     either type.
  250.  
  251.     Assuming we do not want to just store a bitmap of the equation
  252.     (which would not allow any easy editing or interfacing with existing
  253.     systems), we are now left with the following possibilities:
  254.  
  255.          1.   Store characters, fonts and positions only.  Allow
  256.               anything to be anywhere (this is what Interleaf does).
  257.  
  258.          2.   Store characters, fonts, and positions, but only allow
  259.               discrete positions.  This makes it easier to place
  260.               subscripts and superscripts correctly (this is what
  261.               Hockney's Egg does).
  262.  
  263.          3.   Use a language similar to EQN or LaTex, which has ideas
  264.               such as subscripts, superscripts, fractions, and growing
  265.               parentheses.  Generally positioning is done automatically
  266.               when the typesetting occurs, but it is possible to do a
  267.               sort of relative positioning of symbols with some work.
  268.  
  269.          4.   Use a language such as Troff or Tex, which is what EQN and
  270.               Latex is translated into.
  271.  
  272.          5.   Some combination of the above.
  273.  
  274.     In the next section, I will argue for a particular combination of
  275.     the above as a tentative choice.  It may turn out, with more
  276.     information and experience, that this choice should be modified.
  277.  
  278. 4.  What I Think Should be Represented
  279.  
  280.     Let us now take a stab at what sort of standard we should have.
  281.     First of all, we would like our standard if at all possible to be
  282.     compatible with all of the existing systems described previously.
  283.     If the standard becomes widely accepted, it should be general enough
  284.     not to constrain severely the design of new user interfaces.  Thus,
  285.     while we should provide for efficiently representing those aspects
  286.     of equations which are commonly used (subscripts, parentheses, etc.)
  287.     we would like extensions to be possible which enable the
  288.     representation of any symbol anywhere.
  289.  
  290.  
  291.  
  292. Katz                                                            [Page 5]
  293.  
  294. RFC 1003                                                      March 1987
  295.  
  296.  
  297.     We would like standard mathematical symbols, as well as all Greek
  298.     and Latin letters to be available.  We would also like any required
  299.     typesetting knowledge to be in programs and not required of the
  300.     user.
  301.  
  302.     I feel that the exact position of a subscript or superscript should
  303.     not have to be specified by the user or be represented (unless the
  304.     user specifically wants it to be).  It is nice to be able to place
  305.     any symbol anywhere (and indeed the standard ought to allow for
  306.     this), but having to do this for everything is not good.  The
  307.     standard should be able to represent the idea of a subscript,
  308.     superscript, or growing fraction with no more specification.
  309.  
  310.     My suggestion, therefore, is for something like EQN, but with
  311.     extensions to allow positioning of symbols in some kind of absolute
  312.     coordinates as well as relative positioning (EQN does allow some
  313.     positioning relative to where the next symbol would normally go).
  314.     This has the advantage that the representation is in ordinary text,
  315.     which can be sent in messages, the Directive systems can map almost
  316.     directly into it, and it should allow representation for Full
  317.     Display systems.  The ideas of subscript and superscripts (without
  318.     having to specify a position), growing parentheses, fractions, and
  319.     matrices, and special fonts are already there.
  320.  
  321.     Most equations can be specified very compactly within EQN, and if
  322.     positioning is provided as an extension, exceptions can be handled.
  323.     (The same could be said for LaTex, however, I consider the syntax
  324.     there to be somewhat unreadable and prefer EQN.  Essentially, either
  325.     will do).
  326.  
  327.     User interfaces should be able to be easily constructed which would
  328.     allow one to type in an EQN style specification and have the
  329.     equation appear immediately on the screen.  For non-specialists, it
  330.     may be better to use existing Full Display systems which are then
  331.     translated in this EQN like standard (perhaps using a lot of the
  332.     absolute positioning facility).
  333.  
  334. 5.  Conclusions
  335.  
  336.     In summary:
  337.  
  338.  
  339.        1.   A standard for the efficient representation of mathematical
  340.             equations should be defined as soon as possible in order to
  341.             allow the interchange of equations in documents and mail
  342.             messages and the transfer of equations between various
  343.             existing internal representations.
  344.  
  345.        2.   Most equations entry is currently done by people who do not
  346.             know what the equations mean, and are not programmers.  It
  347.             may be that the optimal user interface for these people is
  348.  
  349.  
  350.  
  351. Katz                                                            [Page 6]
  352.  
  353. RFC 1003                                                      March 1987
  354.  
  355.  
  356.             different than for those who do know mathematics and/or are
  357.             programmers.  An equations standard should not preclude
  358.             this.
  359.  
  360.        3.   The standard should easily handle those aspects of equations
  361.             which are common, such as the set of things provided in EQN.
  362.  
  363.        4.   It should also be possible, however, to place any defined
  364.             symbol anywhere and the standard should allow this type of
  365.             specification when needed.
  366.  
  367.        5.   As many of the existing systems (all of them if possible)
  368.             should be able to be translated into the standard.
  369.  
  370.        6.   The standard should not make requirements on the user
  371.             interface such that the user must have much typesetting
  372.             knowledge.  This knowledge should be in the user interface
  373.             or printing routines.
  374.  
  375.        7.   Full Display systems may be best for non-specialists and for
  376.             non-programmers.  Directive systems, perhaps with the
  377.             ability to preview the final equation on one's screen, may
  378.             be best for the rest.
  379.  
  380.        8.   A distinction should be made between the representation of
  381.             an equation (which we are dealing with here) and the
  382.             mathematical knowledge it represents.
  383.  
  384.     I suggest something like EQN as a standard with extensions to allow
  385.     positioning of symbols in some kind of absolute coordinates as well
  386.     as relative positioning.  This has the advantage that the
  387.     representation is in ordinary text, which can be sent in messages,
  388.     the Directive systems can map almost directly into it, and it should
  389.     allow representation for Full Display systems.  The ideas of
  390.     subscript and superscripts (without having to specify a position),
  391.     growing parentheses, fractions, and matrices, and special fonts are
  392.     already there.
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.  
  404.  
  405.  
  406.  
  407.  
  408.  
  409.  
  410. Katz                                                            [Page 7]
  411.  
  412.