Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
article
Free access

Operations on sparse relations

Published: 01 March 1977 Publication History
  • Get Citation Alerts
  • Abstract

    Various computations on relations, Boolean matrices, or directed graphs, such as the computation of precedence relations for a context-free grammar, can be done by a practical algorithm that is asymptotically faster than those in common use. For example, how to compute operator precedence or Wirth-Weber precedence relations in O(n2) steps is shown, as well as how to compute linear precedence functions in O(n) steps, where n is the size of a grammar. The heart of the algorithms is a general theorem giving sufficient conditions under which an expression whose operands are sparse relations and whose operators are composition, transitive closure, union, and inverse, can be computed efficiently.

    References

    [1]
    Aho, A.V., and Ullman, J.D. The Theory of Parsing, Translation and Compiling. Prentice Hall, Englewood Cliffs, N.J., 1972 and 1973.
    [2]
    Aho, A.V., Hopcroft, J.E., and Ullman, J.D. The Design and Analysis of Computer Algorithms. Addison-Wesley, Reading, Mass., 1974.
    [3]
    Bell, J.R. A new method for determining linear precedence functions for precedence grammars. Comm. ACM 12, 10 (Oct. 1969), 567-569.
    [4]
    DeRemer, F.L. Simple LR(k) grammars. Comm. ACM 14, 7 (July 1971), 453--460.
    [5]
    Floyd, R.W. Syntactic analysis and operator precedence. J. ACM 10, 3 (1963), 316-333.
    [6]
    Gray, J.N., and Harrison, M.A. Single pass precedence analysis. IEEE Conf. Rec. 10th Ann. Symp. Switching and Automata Theory, 1969, pp. 106-117.
    [7]
    Gries, D. Compiler Construction Jbr Digital Computers. Wiley, New York, 1971.
    [8]
    Hunt III, H.B, Szymanski, T.G., and Ullman, J.D. Operations on sparse relations and efficient algcrithms for grammar problems. Proc. 15th Ann. Symp. Switching and Automata Theory, 1974, pp. 127-132.
    [9]
    Martin, D.F. Boolean matrix methods for the detection of simple precedence grammars. Comm. ACM 11, 10 (Oct. 1968), 685-687.
    [10]
    Martin, D.F. A Boolean matrix method for the computation of linear precedence functions. Comm. ACM 15, 6 (June 1972), 448-454.
    [11]
    Szymanski, T.G., and Ullman, J.D. Evaluating relational expressions with dense and sparse arguments. Proc. 16th Ann. IEEE Symp. Foundations of Comptr. Sci., 1975, pp. 90-97. To appear in Siam. J. Comput.
    [12]
    Tarjan, R.E. Depth first search and linear graph algorithms. SIAMJ. Comptng. 1, 2 (1972), 146-160.
    [13]
    Wirth, N., and Weber, H. EULER, a generalization of ALGOL and its formal definition, part I. Comm. ACM9, 1 (Jan. 1966), 13-23.

    Cited By

    View all

    Index Terms

    1. Operations on sparse relations
      Index terms have been assigned to the content through auto-classification.

      Recommendations

      Comments

      Information & Contributors

      Information

      Published In

      cover image Communications of the ACM
      Communications of the ACM  Volume 20, Issue 3
      March 1977
      80 pages
      ISSN:0001-0782
      EISSN:1557-7317
      DOI:10.1145/359436
      Issue’s Table of Contents
      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      Published: 01 March 1977
      Published in CACM Volume 20, Issue 3

      Permissions

      Request permissions for this article.

      Check for updates

      Author Tags

      1. Boolean matrix
      2. SLR grammar
      3. T-canomical precedence relation
      4. Wirth-Weber precedence relation
      5. computational complexity
      6. directed graph
      7. linear precedence function
      8. sparse relation

      Qualifiers

      • Article

      Contributors

      Other Metrics

      Bibliometrics & Citations

      Bibliometrics

      Article Metrics

      • Downloads (Last 12 months)52
      • Downloads (Last 6 weeks)16
      Reflects downloads up to 11 Aug 2024

      Other Metrics

      Citations

      Cited By

      View all
      • (2003)On predictive parsing and extended context-free grammarsComputer Science in Perspective10.5555/865449.865456(69-87)Online publication date: 1-Jan-2003
      • (2003)On Predictive Parsing and Extended Context-Free GrammarsComputer Science in Perspective10.1007/3-540-36477-3_6(69-87)Online publication date: 28-Feb-2003
      • (1996)Perspectives on database theoryACM SIGACT News10.1145/235666.23567027:3(25-49)Online publication date: 1-Sep-1996
      • (1995)Perspectives on database theoryProceedings of IEEE 36th Annual Foundations of Computer Science10.1109/SFCS.1995.492479(224-246)Online publication date: 1995
      • (1991)Efficient evaluation for a subset of recursive queriesJournal of Logic Programming10.1016/0743-1066(91)90039-R10:3-4(301-332)Online publication date: 1-Mar-1991
      • (1990)Graph-theoretic methods in database theoryProceedings of the ninth ACM SIGACT-SIGMOD-SIGART symposium on Principles of database systems10.1145/298514.298576(230-242)Online publication date: 2-Apr-1990
      • (1987)Efficient evaluation for a subset of recursive queriesProceedings of the sixth ACM SIGACT-SIGMOD-SIGART symposium on Principles of database systems10.1145/28659.28690(284-293)Online publication date: 1-Jun-1987
      • (1985)A new method of generating LL(1) lookahead setsACM SIGPLAN Notices10.1145/988336.98833820:6(16-19)Online publication date: 1-Jun-1985
      • (1985)On the use of relational expressions in the design of efficient algorithmsAutomata, Languages and Programming10.1007/BFb0015771(456-464)Online publication date: 1985
      • (1983)On the complexity of LL(k) testingJournal of Computer and System Sciences10.1016/0022-0000(83)90015-626:2(244-268)Online publication date: Apr-1983
      • Show More Cited By

      View Options

      View options

      PDF

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader

      Get Access

      Login options

      Full Access

      Media

      Figures

      Other

      Tables

      Share

      Share

      Share this Publication link

      Share on social media