TWO-D(ID:5956/two001)

Flow-chart driven compiler 


for 2-dimensional input

Programming by manipulating flowcharts etc, outputs FORTRAN


References:
  • Haag, James N.; Kelly, Michael A.; Sherman, Paul F. "TWO-D: The USF Beginner's Two-Dimensional Programming System" view details Abstract: A programming system, permitting the user to think 100% that he is programming with flowchart symbols, is described. This description includes the TWO-D syntax, the user's view-point, the CRT-terminal output, the overall structure of the simply-designed programming system, the file structure used, some design decisions faced, and the flowchart of the supervisory program. Extract: INTRODUCTION
    INTRODUCTION
    TWO-D is a simply-designed interactive two-dimensional programming system. It is CRT-terminal oriented, verb-driven, and is designed for the casual or unsophisticated user. The system is highly modular in design and coded wherever feasible in a higher level language, ANSI Fortran in the current implementation, to facilitate modification, transportability, and later conversion to fourth-generation computers.

    All communication with the operating system of the host computer is provided via five additional modules coded in a total of 888 lines of 360 assembly language with a few readily-converted UNIVAC Series 70 Input/ Output macros. At all times with TWO-D, the user has the impression that he is programming in and manipulating a flowchart.
    Extract: DESIGN RATIONALE AND SOME FACTS
    DESIGN RATIONALE AND SOME FACTS
    The TWO-D system, consisting of about 100,000 bytes (about 1/3 of which consists of data areas), does not have a separate syntax for system commands and problemprogramming commands. The advice followed in reaching this decision is summarized in the following"... control language should be, to the largest extent possible, the same as the actual language used to write the solutions to problems." In passing, it should not go unnoted that there are good arguments on the other side of this question. However, for the naive user, our decision seemed Justifiable.

    Using a flowchart symbol and its contents as the basic entity of the language was based upon the assumption that such an arrangment can be treated mentally by the user readily as a single "chunk" and, secondly, upon the fact that such an arrangement carries with it not only the full semantics of a single one-dimensional programming language instruction, but also (due to the connectors emanating from the symbol) a visual indication of the context in which the symbol appears. One well-kuaown theory of human problem solving holds that we are information processing systems limited by the number of symbols/second that we can process. As a result, if one can increase the amount of information/symbol, then the rate of information processing will increase. This theory makes the following interesting claim: "Any stimulus configuration that becomes a recognizable configuration (chunk) is designated in long-term memory by a symbol. Writing a new symbol structure that contains K familiar symbols takes about 5K to 10K seconds of processing time. Accessing and reading a symbol out of long-term memory takes a few hundred milliseconds."

    Although the current prototype version of TWO-D is not reentrant, the design has been so chosen as to make a pure procedure version attainable in the future. It is roughly estimated that each additional user would increase the memory requirements on the order of 500 bytes/user TWO-D instruction required to be always in core, plus a few thousand bytes of data areas held in core. Even though the current version yields an eventual Fortran program (transparently to the user) for execution, only two modules of the nineteen-module system need be changed to yield a final program embodied in another similar target language. It should be noted here that others modifying the TWO-D system might wish to change these two modules to cause the system to behave as an interpreter or as a compiler, instead of as a translator in the current version. Viewed as a translator, the TWO-D system with its current 3,756 lines of source code, of which 76~ is Fortran with the remainder in assembly language, falls in between two other "something-to-Fortran" translators as regards the percentage of Fortran source code used in coding the system. The "GOTRAN-to-Fortran" translator is 100% Fortran. On the other hand, the "ASP (Artificial Scientific Programming)-to- Fortran" translator is 47% Fortran and 53% SNOBOL.

    Finally, it is hoped that eventually a software system in the same class as TWO-D will be to CRT-terminal users as Basic is now to the typewriter-terminal user. The comments on the one-dlmension versus two-dimension matter with respect to both human I/O and different I/O devices give some hope that this will be a fact. Limited experience with a few TWO-D users on a system implemented on a UNIVAC Series 70 Time-Sharing System at the University of San Francisco temporarily confirms the author's feelings that TWO-D, while not the goal, is on the track leading to the goal.

          in Proceedings of the SIGPLAN symposium on Two-dimensional man-machine communication 1972 , Los Alamos, New Mexico, United States view details
  • Wells, Mark B. "A review of two-dimensional programming languages" pp1-10 view details Extract: Two-D
    A system called Two-D [Haag, 1972] recently
    developed at the University of San Francisco utilizes
    flow diagrams in a slightly different way.
    This is a scope based, keyboard language in which
    the user works in the context of a flow diagram
    built and modified by the user but drawn on the
    scope (or printer) by the system. Text isstrictly
    one-dimensional.
          in Proceedings of the SIGPLAN symposium on Two-dimensional man-machine communication 1972 , Los Alamos, New Mexico, United States view details