Skip to main content
Log in

The word problem for visibly pushdown languages described by grammars

  • Published:
Formal Methods in System Design Aims and scope Submit manuscript

Abstract

Visibly pushdown languages are an interesting subclass of deterministic context-free languages that can model nonregular properties of interest in program analysis. Such class properly contains typical classes of parenthesized languages such as “parenthesis”, “bracketed”, “balanced” and “input-driven” languages. It is closed under boolean operations and has decidable decision problems such as emptiness, inclusion and universality. We study the membership problem for visibly pushdown languages, and show that it can be solved in time linear in both the size of the input grammar and the length of the input word. The algorithm relies on a reduction to the reachability problem for game graphs. We also discuss the time complexity of the membership problem for the class of balanced languages which is the largest among those cited above. Besides the intrinsic theoretical interest, we further motivate our main result showing an application to the validation of XML documents against Schema and Document Type Definitions (DTDs).

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Institutional subscriptions

Similar content being viewed by others

References

  1. Aho A, Ullman J (1973) The theory of parsing, translation and compiling, vol I. Prentice-Hall, Englewood Cliffs

    Google Scholar 

  2. Alur R, Benedikt M, Etessami K, Godefroid P, Reps TW, Yannakakis M (2005) Analysis of recursive state machines. ACM Trans Program Lang Syst 27(4):786–818

    Article  Google Scholar 

  3. Alur R, Kumkar V, Madhusudan P, Viswanathan M (2005) Congruences for visibly pushdown languages. In: Proceedings of the 32nd international colloquium of automata, languages and programming (ICALP’05). Lecture notes in computer science, vol 3580. Springer, Berlin, pp 1102–1114

    Google Scholar 

  4. Alur R, Madhusudan P (2004) Visibly pushdown languages. www.cis.upenn.edu/~alur/. A preliminary version appears in: Proceedings of the 36th ACM symposium on theory of computing (STOC’04), pp 201–211

  5. Brggemann-Klein A (1993) Regular expression into finite automaton. Theor Comput Sci 120(2):197–213

    Article  Google Scholar 

  6. Ball T, Rajamani S (2000) Bebop: a symbolic model checker for boolean programs. In: Proceedings of the 7th international workshop on model checking of software (SPIN 2000). Lecture notes in computer science, vol 1885. Springer, Berlin, pp 113–130

    Google Scholar 

  7. Berstel J, Boasson L (2002) Balanced grammars and their languages. In: Formal & natural computing: essay dedicated to Grzegorz Rozenberg. Lecture notes in computer science, vol 2300. Springer, Berlin, pp 3–25

    Google Scholar 

  8. Berstel J, Boasson L (2002) Formal properties of XML grammars and languages. Acta Inform 38:649–671

    Article  MATH  MathSciNet  Google Scholar 

  9. Bouajjani A, Esparza J, Maler O (1997) Reachability analysis of pushdown automata: application to model-checking. In: Proceedings of the 8th international conference on concurrency theory (CONCUR’97). Lecture notes in computer science, vol 1243. Springer, Berlin, pp 135–150

    Google Scholar 

  10. Burkart O, Steffen B (1992) Model checking for context-free processes. In: Proceedings of the 3rd international conference on concurrency theory (CONCUR’92). Lecture notes in computer science, vol 620. Springer, Berlin, pp 123–137

    Google Scholar 

  11. Dymond PW (1988) Input-driven languages are recognized in log n space. Inf Process Lett 26:2472250

    MathSciNet  Google Scholar 

  12. Esparza J, Kucera A, Schwoon S (2003) Model checking LTL with regular valuations for pushdown systems. Inform Comput 186(2):355–376

    Article  MATH  MathSciNet  Google Scholar 

  13. Glushkov VM (1961) The abstract theory of automata. Russ Math Surv 16:1–53

    Article  Google Scholar 

  14. Ginsburg S, Harrison MA (1967) Bracketed context-free languages. J Comput Syst Sci 1:1–23

    MATH  MathSciNet  Google Scholar 

  15. Henzinger TA, Jhala R, Majumdar R, Necula GC, Sutre G, Weimer W (2002) Temporal-safety proofs for systems code. In: Proceedings of the 14th international conference on computer-aided verification (CAV 2002). Lecture notes in computer science, vol 2404. Springer, Berlin, pp 526–538

    Chapter  Google Scholar 

  16. Hopcroft JE, Motwani R, Ullman JD (2001) Introduction to automata theory, languages, and computation. Addison–Wesley, Reading

    MATH  Google Scholar 

  17. Knuth DE (1967) A characterization of parenthesis languages. Inf Control 11(3):269–289

    Article  MATH  Google Scholar 

  18. Kumkar V, Madhusudan P, Viswanathan M (2006) Visibly pushdown languages for XML. Technical Report UIUCDCS-R-2006-2704, UIUC

  19. Lynch N (1977) Log space recognition and translation of parenthesis languages. J ACM 24(4):583–590

    Article  MATH  MathSciNet  Google Scholar 

  20. McNaughton R (1967) Parenthesis grammars. J ACM 14(3):490–500

    Article  MATH  MathSciNet  Google Scholar 

  21. McNaughton R, Yamada H (1960) Regular expressions and state graphs for automata. IRE Trans Electron Comput 9:39–47

    Article  Google Scholar 

  22. Mehlhorn K (1980) Pebbling mountain ranges and its application of DCFL-recognition. In: Proceeding of the 7th international colloquium of automata, languages and programming (ICALP’80). Lecture notes in computer science, vol 85. Springer, Berlin, pp 422–435

    Google Scholar 

  23. Reps TW, Horowitz S, Sagiv S (1995) Precise interprocedural dataflow analysis via graph reachability. In: Proceeding of the 22nd symposium on principles of programming languages (POPL’95), pp 49–61

  24. Thomas W (1995) On the synthesis of strategies in infinite games. In: 12th annual symposium on theoretical aspects of computer science (STACS’95). Lecture notes in computer science, vol 900. Springer, Berlin, pp 1–13

    Google Scholar 

  25. von Braunmhl B, Verbeek R (1983) Input-driven languages are recognized in log n space. In: Proceeding of FCT. Lecture notes in computer science, vol 158. Springer, Berlin, p 4051

    Google Scholar 

  26. W3C recommendation (2000) Extensible markup language (XML) 1.0, 2nd edn. http://www.w3.org/TR/REC-xml. Accessed 6 October 2000

  27. W3C recommendation (2001) XML schema part 0,1 and 2. http://www.w3.org/TR/xmlschema-0,1,2. Accessed 2 May 2001

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Salvatore La Torre.

Additional information

Work partially supported by funds for the research from MIUR 2006, grant “Metodi Formali per la verifica di sistemi chiusi ed aperti”, Università di Salerno.

A preliminary version of this paper was published in the Proceedings of the 4th International Symposium Automated Technology for Verification and Analysis (ATVA 2006), Lecture Notes in Computer Science 4218, pp. 96–109, 2006.

Rights and permissions

Reprints and permissions

About this article

Cite this article

La Torre, S., Napoli, M. & Parente, M. The word problem for visibly pushdown languages described by grammars. Form Methods Syst Des 31, 265–279 (2007). https://doi.org/10.1007/s10703-007-0040-7

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10703-007-0040-7

Keywords

Navigation