The Height of Piecewise-Testable Languages with Applications in Logical Complexity

Authors Prateek Karandikar, Philippe Schnoebelen

Thumbnail PDF


  • Filesize: 0.59 MB
  • 22 pages

Document Identifiers

Author Details

Prateek Karandikar
Philippe Schnoebelen

Cite AsGet BibTex

Prateek Karandikar and Philippe Schnoebelen. The Height of Piecewise-Testable Languages with Applications in Logical Complexity. In 25th EACSL Annual Conference on Computer Science Logic (CSL 2016). Leibniz International Proceedings in Informatics (LIPIcs), Volume 62, pp. 37:1-37:22, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2016)


The height of a piecewise-testable language L is the maximum length of the words needed to define L by excluding and requiring given subwords. The height of L is an important descriptive complexity measure that has not yet been investigated in a systematic way. This paper develops a series of new techniques for bounding the height of finite languages and of languages obtained by taking closures by subwords, superwords and related operations. As an application of these results, we show that FO^2(A^*, subword), the two-variable fragment of the first-order logic of sequences with the subword ordering, can only express piecewise-testable properties and has elementary complexity.
  • Descriptive complexity


  • Access Statistics
  • Total Accesses (updated on a weekly basis)
    PDF Downloads


  1. G. Bachmeier, M. Luttenberger, and M. Schlund. Finite automata for the sub- and superword closure of CFLs: Descriptional and computational complexity. In Proc. LATA 2015, volume 8977 of Lecture Notes in Computer Science, pages 473-485. Springer, 2015. URL:
  2. M. Bojańczyk, L. Segoufin, and H. Straubing. Piecewise testable tree languages. Logical Methods in Comp. Science, 8(3), 2012. URL:
  3. H. Comon. Solving symbolic ordering constraints. Int. J. Foundations of Computer Science, 1(4):387-412, 1990. URL:
  4. V. Diekert, P. Gastin, and M. Kufleitner. A survey on small fragments of first-order logic over finite words. Int. J. Foundations of Computer Science, 19(3):513-548, 2008. URL:
  5. V. Ganesh, M. Minnes, A. Solar-Lezama, and M. C. Rinard. Word equations with length constraints: What’s decidable? In Proc. HVC 2012, volume 7857 of Lecture Notes in Computer Science, pages 209-226. Springer, 2013. URL:
  6. L. H. Haines. On free monoids partially ordered by embedding. Journal of Combinatorial Theory, 6(1):94-98, 1969. URL:
  7. J. Harrison. Handbook of Practical Logic and Automated Reasoning. Cambridge University Press, 2009. URL:
  8. G. Higman. Ordering by divisibility in abstract algebras. Proc. London Math. Soc. (3), 2(7):326-336, 1952. URL:
  9. P. Hofman and W. Martens. Separability by short subsequences and subwords. In Proc. ICDT 2015, volume 31 of Leibniz International Proceedings in Informatics, pages 230-246, 2015. URL:
  10. P. Hooimeijer and W. Weimer. StrSolve: solving string constraints lazily. Autom. Softw. Eng., 19(4):531-559, 2012. URL:
  11. P. Karandikar, M. Kufleitner, and Ph. Schnoebelen. On the index of Simon’s congruence for piecewise testability. Information Processing Letters, 115(4):515-519, 2015. URL:
  12. P. Karandikar, M. Niewerth, and Ph. Schnoebelen. On the state complexity of closures and interiors of regular languages with subwords and superwords. Theoretical Computer Science, 610:91-107, 2016. URL:
  13. P. Karandikar and Ph. Schnoebelen. On the index of Simon’s congruence for piecewise testability (v2), October 2013. This version available at arxiv:1310.1278v2. URL:
  14. P. Karandikar and Ph. Schnoebelen. Decidability in the logic of subsequences and supersequences. In Proc. FST&TCS 2015, volume 45 of Leibniz International Proceedings in Informatics, pages 84-97, 2015. URL:
  15. O. Klíma. Piecewise testable languages via combinatorics on words. Discrete Mathematics, 311(20):2124-2127, 2011. URL:
  16. O. Klíma and L. Polák. Alternative automata characterization of piecewise testable languages. In Proc. DLT 2013, volume 7907 of Lecture Notes in Computer Science, pages 289-300. Springer, 2013. URL:
  17. L. Kontorovich, C. Cortes, and M. Mohri. Kernel methods for learning languages. Theoretical Computer Science, 405(3):223-236, 2008. URL:
  18. J. B. Kruskal. The theory of well-quasi-ordering: A frequently discovered concept. Journal of Combinatorial Theory, Series A, 13(3):297-305, 1972. URL:
  19. D. Kuske. Theories of orders on the set of words. RAIRO Theoretical Informatics and Applications, 40(1):53-74, 2006. URL:
  20. D. Kuske. Private communication, September 2015. Google Scholar
  21. T. Masopust. Piecewise testable languages and nondeterministic automata. arXiv:1603.00361 [cs.FL], March 2016. URL:
  22. T. Masopust and M. Thomazo. On the complexity of k-piecewise testability and the depth of automata. In Proc. DLT 2015, volume 9168 of Lecture Notes in Computer Science, pages 364-376. Springer, 2015. URL:
  23. O. Matz. On piecewise testable, starfree, and recognizable picture languages. In Proc. FOSSACS'98, volume 1378 of Lecture Notes in Computer Science, pages 203-210. Springer, 1998. URL:
  24. D. Perrin and J.-É. Pin. Infinite words: Automata, Semigroups, Logic and Games, volume 141 of Pure and Applied Mathematics Series. Elsevier Science, 2004. Google Scholar
  25. J.-É. Pin. Varieties of Formal Languages. Plenum, New-York, 1986. Google Scholar
  26. J. Rogers, J. Heinz, M. Fero, J. Hurst, D. Lambert, and S. Wibel. Cognitive and sub-regular complexity. In Proc. FG 2012 & 2013, volume 8036 of Lecture Notes in Computer Science, pages 90-108. Springer, 2013. URL:
  27. J. Sakarovitch and I. Simon. Subwords. In M. Lothaire, editor, Combinatorics on Words, volume 17 of Encyclopedia of Mathematics and Its Applications, chapter 6, pages 105-142. Cambridge Univ. Press, 1983. Google Scholar
  28. A. Salomaa, D. Wood, and Sheng Yu. On the state complexity of reversals of regular languages. Theoretical Computer Science, 320(2-3):315-329, 2004. URL:
  29. I. Simon. Piecewise testable events. In Proc. 2nd GI Conf. on Automata Theory and Formal Languages, volume 33 of Lecture Notes in Computer Science, pages 214-222. Springer, 1975. URL:
  30. I. Simon. Words distinguished by their subwords. In Proc. WORDS 2003, 2003. Google Scholar
  31. G. Zetzsche. An approach to computing downward closures. In Proc. ICALP 2015, volume 9135 of Lecture Notes in Computer Science, pages 440-451. Springer, 2015. URL: