Zero-One Law for Regular Languages and Semigroups with Zero

A regular language has the zero-one law if its asymptotic density converges to either zero or one. We prove that the class of all zero-one languages is closed under Boolean operations and quotients. Moreover, we prove that a regular language has the zero-one law if and only if its syntactic monoid has a zero element. Our proof gives both algebraic and automata characterisation of the zero-one law for regular languages, and it leads the following two corollaries: (i) There is an O(n log n) algorithm for testing whether a given regular language has the zero-one law. (ii) The Boolean closure of existential first-order logic over finite words has the zero-one law.

[1]  Arto Salomaa,et al.  Automata-Theoretic Aspects of Formal Power Series , 1978, Texts and Monographs in Computer Science.

[2]  Jan Schwinghammer,et al.  Effciently Computing the Density of Regular Languages , 2004, LATIN.

[3]  Jean Berstel Sur la densité asymptotique de langages formels , 1972, ICALP.

[4]  Ondrej Klíma,et al.  On Varieties of Automata Enriched with an Algebraic Structure (Extended Abstract) , 2014, AFL.

[5]  Paul Gastin,et al.  A Survey on Small Fragments of First-Order Logic over Finite Words , 2008, Int. J. Found. Comput. Sci..

[6]  M. Schützenberger,et al.  Sur Le Produit De Concatenation Non Ambigu , 1976 .

[7]  Marcel Paul Schützenberger,et al.  On Finite Monoids Having Only Trivial Subgroups , 1965, Inf. Control..

[8]  I. K. Rystsov,et al.  Reset Words for Commutative and Solvable Automata , 1997, Theor. Comput. Sci..

[9]  Samuel Eilenberg,et al.  Automata, languages, and machines. A , 1974, Pure and applied mathematics.

[10]  Jan Reiterman,et al.  The Birkhoff theorem for finite algebras , 1982 .

[11]  Dominique Perrin,et al.  Finite Automata , 1958, Philosophy.

[12]  Imre Simon,et al.  Piecewise testable events , 1975, Automata Theory and Formal Languages.

[13]  Philippe Flajolet,et al.  Analytic Combinatorics , 2009 .

[14]  Leonid Libkin,et al.  Elements of Finite Model Theory , 2004, Texts in Theoretical Computer Science.

[15]  Jacques Sakarovitch,et al.  Elements of Automata Theory , 2009 .

[16]  Serge Grigorieff,et al.  Duality and Equational Theory of Regular Languages , 2008, ICALP.