Recognizing Two-Sided Contexts in Cubic Time

  • Max Rabkin
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 8476)


Barash and Okhotin (“Grammars with two-sided contexts”, Tech. Rep. 1090, Turku Centre for Computer Science, 2013) recently introduced conjunctive grammars with two-sided contexts, and gave a variant of Valiant’s algorithm which recognizes the languages they generate in O(|G|2·n 3.3727) time and O(|Gn 2) space. We use a new normal form and techniques from logic programming to improve this to O(|Gn 3), without increasing the space usage.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. Barash, M., Okhotin, A.: Defining contexts in context-free grammars. In: Dediu, A.-H., Martín-Vide, C. (eds.) LATA 2012. LNCS, vol. 7183, pp. 106–118. Springer, Heidelberg (2012)CrossRefGoogle Scholar
  2. Barash, M., Okhotin, A.: Grammars with two-sided contexts. Tech. Rep. 1090, Turku Centre for Computer Science (2013),
  3. Dowling, W.F., Gallier, J.H.: Linear-time algorithms for testing the satisfiability of propositional Horn formulae. The Journal of Logic Programming 1(3), 267–284 (1984)CrossRefzbMATHMathSciNetGoogle Scholar
  4. Kowalski, R.: Logic for problem-solving. North-Holland Publishing Co. (1979),
  5. Okhotin, A.: Conjunctive and boolean grammars: the true general case of the context-free grammars. Computer Science Review 9, 27–59 (2013)CrossRefzbMATHGoogle Scholar
  6. Shieber, S.M., Schabes, Y., Pereira, F.C.N.: Principles and implementation of deductive parsing. The Journal of Logic Programming 24(1-2), 3–36 (1995)CrossRefzbMATHMathSciNetGoogle Scholar
  7. Valiant, L.G.: General context-free recognition in less than cubic time. Journal of Computer and System Sciences 10(2), 308–315 (1975)CrossRefzbMATHMathSciNetGoogle Scholar
  8. Williams, V.V.: Multiplying matrices faster than Coppersmith-Winograd. In: Proceedings of the 44th Symposium on Theory of Computing, STOC 2012, pp. 887–898. ACM (2012)Google Scholar

Copyright information

© Springer International Publishing Switzerland 2014

Authors and Affiliations

  • Max Rabkin
    • 1
  1. 1.Saarland UniversityGermany

Personalised recommendations