In combinatorics of words, a concatenation of k consecutive equal blocks is called a power of order k. In this paper we take a different point of view and define an anti-power of order k as a concatenation of k consecutive pairwise distinct blocks of the same length. As a main result, we show that every infinite word contains powers of any order or anti-powers of any order. That is, the existence of powers or anti-powers is an unavoidable regularity. Indeed, we prove a stronger result, which relates the density of anti-powers to the existence of a factor that occurs with arbitrary exponent. From these results, we derive that at every position of an aperiodic uniformly recurrent word start anti-powers of any order. We further show that any infinite word avoiding anti-powers of order 3 is ultimately periodic, and that there exist aperiodic words avoiding anti-powers of order 4. We also show that there exist aperiodic recurrent words avoiding anti-powers of order 6, and leave open the question whether there exist aperiodic recurrent words avoiding anti-powers of order k for k=4,5.
[1]
M. Lothaire.
Combinatorics on words, Second Edition
,
1997
.
[2]
Aldo de Luca,et al.
Finiteness and Regularity in Semigroups and Formal Languages
,
1999,
Monographs in Theoretical Computer Science An EATCS Series.
[3]
Markus L. Schmid.
Computing equality-free and repetitive string factorisations
,
2016,
Theor. Comput. Sci..
[4]
Henning Fernau,et al.
Pattern Matching with Variables: Fast Algorithms and New Hardness Results
,
2015,
STACS.
[5]
M. Lothaire.
Algebraic Combinatorics on Words
,
2002
.
[6]
Jeffrey Shallit,et al.
The Ubiquitous Prouhet-Thue-Morse Sequence
,
1998,
SETA.