Abstract
A classic result in formal language theory is the equivalence among aperiodic finite automata, star-free regular expressions, and first-order logic on words. Extending these results to structured subclasses of context-free languages, such as tree languages, did not work as smoothly: there are star-free tree languages that are counting. We argue that investigating the same properties within the family of operator precedence languages (OPLs) by going back to string languages rather than tree languages may lead to equivalences that perfectly match those on regular languages. We define operator precedence expressions; we show that they define exactly the class of OPLs and that, when restricted to the star-free subclass, coincide with first-order definable OPLs and are aperiodic.
Since operator precedence languages strictly include other classes of structured languages such as visibly pushdown languages, the same results given in this paper hold as trivial corollary for that family too.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
This is a minor deviation from [12], where it was assumed that grammars have only one axiom.
- 2.
See Fig. 3.
- 3.
Note that the G produced by the construction is BD if so are \(G_1\) and \(G_2\), but it could be not necessarily BDR; however, if a BDR OPG has a counting derivation, any equivalent BD grammar has also a counting derivation.
- 4.
\(\Xi := \{ (x,y) \mid A \rightarrow x B y \in P \} \,\cup \, \{ z \mid A \rightarrow z \in P \} \).
References
Alur, R., Arenas, M., Barceló, P., Etessami, K., Immerman, N., Libkin, L.: First-order and temporal logics for nested words. In: Logical Methods in Computer Science, vol. 4, no. 4 (2008)
Alur, R., Madhusudan, P.: Adding nesting structure to words. J. ACM 56(3), 1–43 (2009)
Alur, R., Bouajjani, A., Esparza, J.: Model checking procedural programs. Handbook of Model Checking, pp. 541–572. Springer, Cham (2018). https://doi.org/10.1007/978-3-319-10575-8_17
Alur, R., Chaudhuri, S., Madhusudan, P.: Software model checking using languages of nested trees. ACM Trans. Program. Lang. Syst. 33(5), 15:1–15:45 (2011). https://doi.org/10.1145/2039346.2039347
Autebert, J.-M., Berstel, J., Boasson, L.: Context-free languages and pushdown automata. In: Rozenberg, G., Salomaa, A. (eds.) Handbook of Formal Languages, pp. 111–174. Springer, Heidelberg (1997). https://doi.org/10.1007/978-3-642-59136-5_3
Bozzelli, L., Sánchez, C.: Visibly linear temporal logic. In: Demri, S., Kapur, D., Weidenbach, C. (eds.) IJCAR 2014. LNCS (LNAI), vol. 8562, pp. 418–433. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-08587-6_33
von Braunmühl, B., Verbeek, R.: Input-driven languages are recognized in log n space. In: Karpinski, M. (ed.) FCT 1983. LNCS, vol. 158, pp. 40–51. Springer, Heidelberg (1983). https://doi.org/10.1007/3-540-12689-9_92
Büchi, J.R.: Weak second-order arithmetic and finite automata. Math. Log. Q. 6(1–6), 66–92 (1960)
Chiari, M., Mandrioli, D., Pradella, M.: Temporal logic and model checking for operator precedence languages. In: Orlandini, A., Zimmermann, M. (eds.) Proceedings Ninth International Symposium on Games, Automata, Logics, and Formal Verification, GandALF 2018, Saarbrücken, Germany, 26–28th September 2018. EPTCS, vol. 277, pp. 161–175 (2018). https://doi.org/10.4204/EPTCS.277.12
Crespi Reghizzi, S., Guida, G., Mandrioli, D.: Noncounting context-free languages. J. ACM 25, 571–580 (1978)
Crespi Reghizzi, S., Guida, G., Mandrioli, D.: Operator precedence grammars and the noncounting property. SICOMP: SIAM J. Comput. 10, 174–191 (1981)
Crespi Reghizzi, S., Mandrioli, D.: Operator precedence and the visibly pushdown property. J. Comput. Syst. Sci. 78(6), 1837–1867 (2012)
Crespi Reghizzi, S., Mandrioli, D., Martin, D.F.: Algebraic properties of operator precedence languages. Inf. Control 37(2), 115–133 (1978)
Crespi Reghizzi, S., Pradella, M.: Beyond operator-precedence grammars and languages. J. Comput. Syst. Sci. (2020). to appear
Crespi Reghizzi, S., Mandrioli, D.: A class of grammar generating non-counting languages. Inf. Process. Lett. 7(1), 24–26 (1978). https://doi.org/10.1016/0020-0190(78)90033-9
Diekert, V., Gastin, P.: First-order definable languages. In: Logic and Automata: History and Perspectives, Texts in Logic and Games, pp. 261–306. Amsterdam University Press (2008)
Elgot, C.C.: Decision problems of finite automata design and related arithmetics. Trans. Am. Math. Soc. 98(1), 21–52 (1961)
Ésik, Z., Iván, S.: Aperiodicity in tree automata. In: Bozapalidis, S., Rahonis, G. (eds.) CAI 2007. LNCS, vol. 4728, pp. 189–207. Springer, Heidelberg (2007). https://doi.org/10.1007/978-3-540-75414-5_12
Floyd, R.W.: Syntactic analysis and operator precedence. J. ACM 10(3), 316–333 (1963)
Harrison, M.A.: Introduction to Formal Language Theory. Addison Wesley, Boston (1978)
Heuter, U.: First-order properties of trees, star-free expressions, and aperiodicity. ITA 25, 125–145 (1991). https://doi.org/10.1051/ita/1991250201251
Langholm, T.: A descriptive characterisation of linear languages. J. Log. Lang. Inf. 15(3), 233–250 (2006). https://doi.org/10.1007/s10849-006-9016-z
Lautemann, C., Schwentick, T., Thérien, D.: Logics for context-free languages. In: Pacholski, L., Tiuryn, J. (eds.) CSL 1994. LNCS, vol. 933, pp. 205–216. Springer, Heidelberg (1995). https://doi.org/10.1007/BFb0022257
Lonati, V., Mandrioli, D., Panella, F., Pradella, M.: First-order logic definability of free languages. In: Beklemishev, L.D., Musatov, D.V. (eds.) CSR 2015. LNCS, vol. 9139, pp. 310–324. Springer, Cham (2015). https://doi.org/10.1007/978-3-319-20297-6_20
Lonati, V., Mandrioli, D., Panella, F., Pradella, M.: Operator precedence languages: their automata-theoretic and logic characterization. SIAM J. Comput. 44(4), 1026–1088 (2015)
Mandrioli, D., Pradella, M.: Generalizing input-driven languages: theoretical and practical benefits. Comput. Sci. Rev. 27, 61–87 (2018). https://doi.org/10.1016/j.cosrev.2017.12.001
McNaughton, R.: Parenthesis grammars. J. ACM 14(3), 490–500 (1967)
McNaughton, R., Papert, S.: Counter-Free Automata. MIT Press, Cambridge (1971)
Nowotka, D., Srba, J.: Height-deterministic pushdown automata. In: Kučera, L., Kučera, A. (eds.) MFCS 2007. LNCS, vol. 4708, pp. 125–134. Springer, Heidelberg (2007). https://doi.org/10.1007/978-3-540-74456-6_13
Pin, J.: Logic on words. In: Current Trends in Theoretical Computer Science, pp. 254–273 (2001)
Floyd, C.: Theory and practice of software development. In: Mosses, P.D., Nielsen, M., Schwartzbach, M.I. (eds.) CAAP 1995. LNCS, vol. 915, pp. 25–41. Springer, Heidelberg (1995). https://doi.org/10.1007/3-540-59293-8_185
Rabinovich, A.: A proof of Kamp’s theorem. Log. Methods Comput. Sci. 10(1), 1–16 (2014). https://doi.org/10.2168/LMCS-10(1:14)2014
Salomaa, A.K.: Formal Languages. Academic Press, New York (1973)
Thatcher, J.: Characterizing derivation trees of context-free grammars through a generalization of finite automata theory. J. Comput. Syst. Sci. 1, 317–322 (1967)
Thomas, W.: Logical aspects in the study of tree languages. In: Courcelle, B. (ed.) 9th Colloquium on Trees in Algebra and Programming, CAAP 1984, Bordeaux, France, March 5–7, 1984, Proceedings, pp. 31–50. Cambridge University Press (1984)
Trakhtenbrot, B.A.: Finite automata and logic of monadic predicates. Doklady Akademii Nauk SSR 140, 326–329 (1961). (in Russian)
Acknowledgments
We are grateful to the reviewers for their careful reading and suggestions.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2020 Springer Nature Switzerland AG
About this paper
Cite this paper
Mandrioli, D., Pradella, M., Crespi Reghizzi, S. (2020). Star-Freeness, First-Order Definability and Aperiodicity of Structured Context-Free Languages. In: Pun, V.K.I., Stolz, V., Simao, A. (eds) Theoretical Aspects of Computing – ICTAC 2020. ICTAC 2020. Lecture Notes in Computer Science(), vol 12545. Springer, Cham. https://doi.org/10.1007/978-3-030-64276-1_9
Download citation
DOI: https://doi.org/10.1007/978-3-030-64276-1_9
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-64275-4
Online ISBN: 978-3-030-64276-1
eBook Packages: Computer ScienceComputer Science (R0)