Avoiding 5/4-powers on the alphabet of nonnegative integers

We identify the structure of the lexicographically least word avoiding 5/4-powers on the alphabet of nonnegative integers. Specifically, we show that this word has the form $p \tau(\varphi(z) \varphi^2(z) \cdots)$ where $p, z$ are finite words, $\varphi$ is a 6-uniform morphism, and $\tau$ is a coding. This description yields a recurrence for the $i$th letter, which we use to prove that the sequence of letters is 6-regular with rank 188. More generally, we prove $k$-regularity for a sequence satisfying a recurrence of the same type.


Introduction
Avoidance of patterns is a major area of study in combinatorics on words [6], which finds its origins in the work of Thue [5,12,13]. In particular, lexicographically least words avoiding some patterns have gained interest over the years. Often, words of interest that avoid a pattern can be described by a morphism. A morphism on an alphabet Σ is a map µ : Σ → Σ * . (Here Σ * denotes the set of finite words on Σ.) A morphism extends naturally to finite and infinite words by concatenation. We say that a morphism µ on Σ is k-uniform if |µ(c)| = k for all c ∈ Σ. A 1-uniform morphism is also called a coding. If there exists a letter c ∈ Σ such that µ(c) starts with c, then iterating µ on c gives a word µ ω (c), which is a fixed point of µ beginning with c. In this paper we index letters in finite and infinite words starting with 0.
In the context of combinatorics on words, fractional powers were first studied by Dejean [7]. Such a power is a partial repetition, defined as follows.
Definition 1. Let a and b be relatively prime positive integers. If v = v 0 v 1 · · · v −1 is a nonempty word whose length is divisible by b, the a/b-power of v is the word where {a/b} = a/b − a/b is the fractional part of a/b. Note that |v a/b | = a b |v|. If a/b > 1, then a word w is an a/b-power if and only if w can be written v e u where e is a positive integer, u is a prefix of v, and |w| |v| = a b .
Date: May 6, 2020. The second-named author is supported by a Francqui Foundation Fellowship of the Belgian American Educational Foundation.
Elsewhere in the literature, researchers have been interested in words with no α-power factors for all α ≥ a/b. In this paper, we consider a slightly different notion, and we say that a word is a/b-power-free if none of its factors is an (exact) a/b-power.
Notation. Let a and b be relatively prime positive integers such that a/b > 1. Define w a/b to be the lexicographically least infinite word on Z ≥0 avoiding a/bpowers.
Guay-Paquet and Shallit [8] started the study of lexicographically least powerfree words on the alphabet of nonnegative integers. They identified the structure of w a for each integer a ≥ 2. In particular, the lexicographically least 2-power-free word [11, A007814] w 2 = 01020103010201040102010301020105 · · · is the fixed point of the 2-uniform morphism ϕ on the alphabet of nonnegative integers defined by ϕ(n) = 0(n + 1) for all n ≥ 0. Additionally they identified the structure of the lexicographically least overlap-free word. The first-named author and Shallit [10] studied the structure of the lexicographically least 3/2-power-free word [11, A269518] w 3/2 = 0011021001120011031001130011021001140011031 · · · , which is the image under a coding of a fixed point of a 6-uniform morphism. Let Σ 2 be the infinite alphabet {n j : n ∈ Z, 0 ≤ j ≤ 1} with 2 types of letters. For example, 0 0 and 0 1 are the 2 different letters of the form 0 j . Let ϕ : Σ * 2 → Σ * 2 be the morphism defined by ϕ(n 0 ) = 0 0 0 1 1 0 1 1 0 0 (n + 2) 1 ϕ(n 1 ) = 1 0 0 1 0 0 1 1 1 0 (n + 2) 1 for all n ∈ Z, where the subscript j determines the first five letters of ϕ(n j ). Let τ be the coding defined by τ (n j ) = n for all n j ∈ Σ 2 . Then w 3/2 = τ (ϕ ω (0 0 )). A prefix of this word appears on the left in Figure 1. The letter 0 is represented by white cells, 1 by slightly darker cells, and so on. The first five columns are periodic, and the sixth column satisfies w(6i + 5) = w(i) + 2 for all i ≥ 0 where w(i) is the ith letter of w 3/2 .
Pudwell and Rowland [9] undertook a large study of w a/b for rational numbers in the range 1 < a b < 2, and identified many of these words as images under codings of fixed points of morphisms. The number a b in this range with smallest b for which the structure of w a/b was not known is 5 4 . In this paper, we give a morphic description for the lexicographically least 5/4-power-free word [11, A277144] w 5/4 = 00001111020210100101121200001311 · · · .
Let w(i) be the ith letter of w 5/4 . For the morphic description of w 5/4 , we need 8 letters, n 0 , n 1 , . . . , n 7 for each integer n ∈ Z. The subscript j of the letter n j will determine the first five letters of ϕ(n j ), which correspond to the first five columns on the right in Figure 1. The definition of ϕ below implies that these columns are eventually periodic with period length 1 or 4. Figure 1. Portions of w 3/2 (left) and w 5/4 (middle and right), partitioned into rows of width 6. The word w 3/2 is shown from the beginning. The word w 5/4 = w(0)w(1) · · · is shown beginning from w(i) i≥6756 (middle) and w(i) i≥6758 (right). In middle image, we have chopped off the first 6756/6 = 1126 rows to show where five columns become periodic. The term w(6759) (top row, second column on the right) is the last entry in w(6i + 3) i≥0 that is not 1.
We suggest keeping a copy of the definition of ϕ handy, since we refer to it many times in the rest of the paper.
The subscripts in each image ϕ(n j ) increase by 1 modulo 8 from one letter to the next and also from the end of each image to the beginning of the next. We also define the coding τ (n j ) = n for all n j ∈ Σ 8 . In the rest of the paper, we think about the definitions of ϕ and τ • ϕ as 8 × 6 arrays of their letters. In particular, we will refer to letters in images of ϕ and τ • ϕ by their columns (first through sixth).
The following gives the structure of w 5/4 .
Theorem 4 also implies that five of the six columns of w 5/4 are eventually periodic, and the last column satisfies the following recurrence. There are 20510 transient rows before the self-similarity repeats, hence the value 123061 = 6·20510+1 in Corollary 5. We show that the sequence w(i) i≥0 is 6-regular in the sense of Allouche and Shallit [2]. More generally, we prove the following. Theorem 6. Let k ≥ 2 and ≥ 1. Let d(i) i≥0 and u(i) i≥0 be periodic integer sequences with period lengths and k , respectively. Let r, s be nonnegative integers such that r − s + k − 1 ≥ 0. Let w(i) i≥0 be an integer sequence such that, for all 0 ≤ m ≤ k − 1 and all i ≥ 0, Then w(i) i≥0 is k-regular.
To prove Theorem 4, we must show that (1) p τ (ϕ(z)ϕ 2 (z) · · · ) is 5/4-power-free, and (2) p τ (ϕ(z)ϕ 2 (z) · · · ) is lexicographically least (by showing that decreasing any letter introduces a 5/4-power ending in that position). The word w 5/4 is more complicated than previously studied words w a/b in three major ways. First, unlike all words w a/b whose structures were previously known, the natural description of w 5/4 is not as a morphic word, that is, as an image under a coding of a fixed point of a morphism. This can be seen in Corollary 5. Namely, when w(i) i≥0 reappears as a modified subsequence of w 5/4 , it does not appear in its entirety; instead, only w(i) i≥5920 appears. In other words, there is a second kind of transient, represented by 5920 = 0, which had not been observed before. Second, the value of d in the images ϕ(n j ) = u (n + d) i varies with j. The sequence 3, 2, 3, 2, 1, 2, 1, 2, . . . of d values is periodic with period length 8, hence the 8 types of letters. Third, the morphism ϕ does not preserve the property of 5/4-power-freeness, as we discuss in Section 4. These features make the proofs significantly more intricate. We use Mathematica to carry out several computations required in the proofs. In particular, we explicitly use the length-331040 prefix of w 5/4 . A notebook containing the computations is available from the websites 1 of the authors. This paper is organized as follows. Section 2 gives some useful preliminary properties of the words p and z from Theorem 4. In Section 3, we show that 5/4-powers in images under ϕ have specific lengths. As the morphism ϕ does not preserve 5/4-power-freeness, we introduce the concept of pre-5/4-power-freeness in Section 4 and we show that the word zϕ(z) · · · is pre-5/4-power-free. We prove Theorem 4 in two steps. First, in Section 5, we show that pτ (ϕ(z)ϕ 2 (z) · · · ) is 5/4-power-free using the pre-5/4-power-freeness of zϕ(z) · · · . Second, in Section 6, we show that pτ (ϕ(z)ϕ 2 (z) · · · ) is lexicographically least. In Section 7, we study the regularity of words whose morphic structure is similar to that of w 5/4 , and we prove Theorem 6. In particular, we prove that the sequence of letters in w 5/4 is 6-regular, and we establish that its rank is 188. We finish up with some open questions in Section 8, including conjectural recurrences for w 7/6 and several other words.
In the remainder of this section, we outline how the structure of w 5/4 was discovered.
1.1. Experimental discovery. If the previous words studied in [10] and [9] are any indication, the structure of w a/b can be identified when the letters of w a/b are partitioned into rows of width k such that exactly one column is not eventually periodic. We then look for the letters of w a/b appearing self-similarly in this column. For w 5/4 , the largest such k appears to be k = 72. Figure 2 shows the partition of a prefix of w 5/4 into rows of width 72.
A longer prefix reveals that the sought nonperiodic column is w(72i + 31) i≥0 . Figure 3 plots the first several thousand terms of the sequences w(72i + 31) i≥0 and w(i) i≥0 . The peaks in these plots suggest that the occurrences of the letter 8 in w(72i + 31) i≥0 are related to the occurrences of the letter 6 in w(i) i≥0 . Specifically, the intervals between instances of 6 in w(i) i≥0 seem to be twelve times as long as the corresponding intervals between instances of 8 in w(72i + 31) i≥0 . Lining up the peaks suggests (1) w(72i + 163183) = w(12i + 12607) + 2  Figure 3. A plot of prefixes of the sequences w(72i + 31) i≥0 (left) and for all i ≥ 0. If possible, we would like a conjecture of the form where the coefficient of i on the right side is 1, since such a recurrence would relate a subsequence of the letters in w 5/4 to a suffix of w 5/4 . Here r represents the "usual" transient seen in other words w a/b (related to r in Theorem 6 by r = r +k −1), and s represents a new kind of transient. If s = 0, the recurrence does not look back to the beginning of w 5/4 . Toward Equation (2), we examine the termwise difference of w(6i + 163183) i≥0 and w(i + 12607) i≥0 , which is 2, 3, 2, 3, 2, 1, 2, 1, 2, 3, 2, 3, 2, 1, 2, 1, 2, 3, 2, 3, 2, 1, 2, 1, . . . .
This sequence is not constant, so the d in Equation (2) is in fact a function of i; however, it appears to be periodic with period length 8. Moreover, although we obtained this sequence by looking at positions of 8 and 6, in fact this periodic difference begins 6687 terms earlier, before the first occurrences of 8 and 6. This gives Corollary 5, which in turn suggests the definition of ϕ in Notation 3. The 8 residue classes in Corollary 5 correspond to the 8 types of letters. Note there is some flexibility in the definition of ϕ. To parallel morphisms in [8,9,10], we have chosen ϕ such that the last letter in ϕ(n j ) depends on n.

Basic properties of the words p and z
The following definition is motivated by the morphism ϕ in Notation 3, where the subscripts increase by 1 modulo 8. Note that if w is a subscript-increasing word on Σ 8 , then so is ϕ(w). For every subscript-increasing word w on Σ 8 , it follows from Notation 3 that the subsequence of letters with even subscripts in ϕ(w) is a factor of (0 0 0 2 1 4 1 6 ) ω .
Iterating ϕ on any nonempty word on Σ 8 will eventually give a word containing letters n j with arbitrarily larger n. Indeed, after one iteration, we see a letter with subscript 3 or 7, so after two iterations we see a letter with subscript 7. Since ϕ(n 7 ) contains (n + 2) 7 , the alphabet grows without bound.
Before position 6764, we cannot expect the prefix of w 5/4 to be the image of another word under the morphism ϕ because the five columns have not become periodic yet (recall Figure 1 where w(6759) is the last term of w(6i + 3) before a periodic pattern appears).
The following lemma states several properties of p, z, and s. We have the following properties.
(2) The word z is a subscript-increasing finite word whose alphabet is the 32letter set In particular, z is a word on the alphabet Σ 8 \ Γ. The last letter of the form −1 j in z appears in position 80.
The word s is a subscript-increasing infinite word on Σ 8 \ Γ. Moreover, the subsequence of letters in s with even subscripts starting at position 86 is (0 0 0 2 1 4 1 6 ) ω . (4) For all words w on Σ 8 , the set of letters with even subscripts in ϕ(w) is a subset of {0 0 , 0 2 , 1 4 , 1 6 }. Moreover, if w is subscript-increasing, then the subsequence of letters with even subscripts in ϕ(w) is a factor of (0 0 0 2 1 4 1 6 ) ω . (5) For each n j ∈ Σ 8 \ Γ, the last letter of ϕ(n j ) is not of the form 0 i or 1 i .
Proof. Parts 1 and 2 follow from computing p and z. Part 4 follows from inspection of ϕ. To see Part 5, for each j we set the last letter (n + d) i of ϕ(n j ) equal to 0 i and 1 i , solve each for n, and observe that n j ∈ Γ.
For Part 3, recall that z is a prefix of s. First we prove that s is a subscriptincreasing infinite word on Σ 8 \ Γ. The letters 5 3 and 6 3 arise from letters 3 1 , 3 5 , 4 1 , and 4 5 in z. As previously mentioned, letters with subscript 7 appear when iterating ϕ on any nonempty word. One checks by induction that these are the only letters in s. Therefore the alphabet of s is Alph(z) ∪ {5 3 , 6 3 } ∪ {n 7 : n ≥ 5}. To show that s is subscript-increasing, note that z ends with 3 3 and ϕ(z) starts with ϕ(0 2 ) = 1 4 · · · . The other boundaries follow inductively by applying ϕ.

Lengths of 5/4-powers
Pudwell and Rowland introduced the notion of locating lengths as a tool to prove that morphisms preserve the property of a/b-power-freeness [9]. We use this notion in Section 4 to show that ϕ has a weaker property.
Definition 10. Let k ≥ 2 and ≥ 1. Let µ be a k-uniform morphism on an alphabet Σ. We say that µ locates words of length if for each word u of length on Σ there exists an integer m such that, for all v ∈ Σ * , every occurrence of the factor u in µ(v) begins at a position congruent to m modulo k.
If µ locates words of length , then µ also locates words of length + 1, since if |u| = + 1 then the positions of the length-prefix of u in an image under µ is determined modulo k.
Lemma 11. The 6-uniform morphism ϕ : Σ * 8 → Σ * 8 locates words of length 6. Proof. Let v be a word in Σ * 8 . Note that v is not necessarily subscript-increasing. We look at occurrences of length-6 factors in ϕ(v). There are eight cases, depending on the subscript of the initial letter. We write out the details for the subscript 2. There are four possible forms for the length-6 factor in this case. The other cases are analogous, some of which involve five possible forms.
Consider a length-6 factor of ϕ(v) whose initial letter is of the form n 2 . Then in fact the initial letter is 0 2 , since this is the only letter in ϕ(v) with subscript 2. There are four forms depending on which column the letter 0 2 is, namely If 0 2 appears in the third column, then the definition of ϕ implies that the factor is of the form u orū. If 0 2 appears in the fifth column, then it is of the formū. If 0 2 appears in the first column, then it is of the formū. For each pair of these factors, we show that either they are unequal or they occur at positions that are equivalent modulo 6. If u =ū, then they only occur at positions that are equivalent modulo 6 because they are in the same column.
We directly see that the letters with subscript 3 in u (resp.,ū) andū do not match, so they are different length-6 factors.
Next we compare u (resp.,ū) withū. For them to be equal, we have to attach, inū, a prefix of one of the length-6 images of ϕ starting with 1 4 , namely ϕ(m 2 ) or ϕ(m 6 ). Both cases give For u orū to be equal toū, we must have We now see that the letters with subscript 7 of u (resp.,ū) andū are not the same, so they are different length-6 factors.
Finally we compareū withū. For them to be equal, the same argument shows The letters with subscript 5 ofū andū do not match, so they are different length-6 factors.
Lemma 12. Let ≥ 6 be an integer. Let w be a subscript-increasing word on Σ 8 . If ϕ(w) contains a 5/4-power of length 5 , then is divisible by 6.
Proof. Assume that ϕ(w) contains a 5/4-power xyx with |x| = and |y| = 3 . Since the first letters of the two occurrences of x are the same, their subscripts are equal.

Pre-5/4-power-freeness
A morphism µ on an alphabet Σ is a/b-power-free if µ preserves a/b-powerfreeness, that is, for all a/b-power-free words w on Σ, µ(w) is also a/b-power-free. Previously studied words w a/b [8,10,9] have all been described by a/b-power-free morphisms. However, the morphism ϕ defined in Notation 3 is not 5/4-power-free. Indeed for any integers n,n ∈ Z, the word 0 4 n 5n6 is 5/4-power-free, but ϕ(0 4 n 5n6 ) contains the length-10 factor which is a 5/4-power. Therefore, to prove that w 5/4 is 5/4-power-free, we use a different approach. We still need to guarantee that there are no 5/4-powers in certain images ϕ(w). Specifically, we would like all factors xyx of w with |x| = 1 3 |y| = |x | to satisfy ϕ(x) = ϕ(x ). We use the following concept. Definition 13. A word w on Σ 8 is a pre-5/4-power if ϕ(w) is a 5/4-power.
A nonempty word w on Σ 8 is a pre-5/4-power if and only if w = xyx for some x, y, x with |x| = 1 3 |y| = |x | such that ϕ(x) = ϕ(x ). The next lemma follows from the definition of ϕ.
Lemma 15. A nonempty subscript-increasing word w on Σ 8 is a pre-5/4-power if and only if w = xyx for some x, y, x with |x| = 1 3 |y| = |x | such that (1) if the sequences of subscripts in x and x are equal, then x = x , and (2) if the sequences of subscripts in x and x differ by 4, then the mth letters x(m) and x (m) satisfy Proof. Let x, y, x be nonempty words on Σ 8 such that xyx is subscript-increasing, |x| = 1 3 |y| = |x |, and ϕ(x) = ϕ(x ). Since |xy| = 4|x|, the sequences of subscripts in x and x are equal or differ by 4. By Lemma 14, xyx is a pre-5/4-power if and only if, for each m ∈ {0, 1, . . . , |x| − 1}, we have if their subscripts are equal {−2, 2} if their subscripts are even and differ by 4 {0} if their subscripts are odd and differ by 4.
This is equivalent to Conditions 1 and 2 in the statement.
Proposition 16 implies that if a word w is pre-5/4-power-free then w is 5/4power-free.
Let Γ be the alphabet in Lemma 9. For all subscript-increasing words w on Σ 8 \Γ, the combination of Lemmas 17 and 18 shows that, if w is pre-5/4-power-free, then ϕ(w) is 5/4-power-free. (We include Lemma 18 because it complements Lemma 17, even though we will not use it to prove that pτ (ϕ(s)) is 5/4-power-free.) Lemma 17. If w is a pre-5/4-power-free subscript-increasing word on Σ 8 , then ϕ(w) contains no 5/4-power of length greater than or equal to 30.
Proof. Proceed toward a contradiction and assume that there exists a 5/4-power in ϕ(w) of the form xyx with |x| = and |y| = 3 and ≥ 6. Let j be the initial position of xyx in ϕ(w). Write j = 6i 1 + r with 0 ≤ r ≤ 5. Since w is subscript-increasing, Lemma 12 implies that = |x| is divisible by 6. Then y begins at position j +|x| = 6i 2 +r and the second occurrence of x begins at position j + |xy| = 6i 3 + r for some i 2 , i 3 . Now we shift if necessary so that r = 0; let x y x be the word of length |xyx| starting at position 6i 1 in ϕ(w). Let uvu be the factor of w of length 1 6 |xyx| starting at position i 1 such that |u| = 1 3 |v| = |u |. Then ϕ(uvu ) = x y x , so uvu is a pre-5/4-power. This contradicts the hypothesis that w is a pre-5/4-power-free word.
Lemma 18. Let Γ be the alphabet in Lemma 9. If w is a subscript-increasing word on Σ 8 \ Γ, then ϕ(w) contains no 5/4-power of length less than or equal to 25.
Proof. Given (n + d) i where d ∈ {1, 2, 3} and 0 ≤ i ≤ 7, we will need to know the values of j ∈ {0, 1, . . . , 7} for which the letter (n + d) i is the last letter of ϕ(n j ). This is given by the following table.
As in the proof of Lemma 12, is even. It suffices to look at = 2 and = 4. Since w is subscript-increasing, we may consider the word ϕ(n 0 )ϕ(n 1 )ϕ(n 2 )ϕ(n 3 )ϕ(n 4 )ϕ(n 5 )ϕ(n 6 )ϕ(n 7 ) circularly and slide a window of length 5 through this word. Here n is a symbol, not an integer. For each factor of length 5 , we compare its prefix of length to its suffix of length . If they are elements of Σ * 8 (that is, they do not involve n), then we check that they are unequal. Otherwise, for each pair of letters that involves n, we solve for n, and we use Table (3) to determine the possible subscripts j of n. The set Γ is precisely the set of letters n j that arise.
We need a stronger result than Lemmas 17 and 18 provide. Namely, since we iterate ϕ, we need that images under ϕ are not just 5/4-power-free but are in fact pre-5/4-power-free.
Proof. Since w is subscript-increasing, so is ϕ(w). Let xyx be a nonempty factor of ϕ(w) with |x| = 1 3 |y| = |x |. We show that xyx is not a pre-5/4-power. We consider two cases depending on the parity of |x|.
Case 1. Suppose that |x| is odd. Then the sequences of subscripts in x and x differ by 4.
If x does not contain a letter with an even subscript, then |x| = 1, so x and x are letters with odd subscripts. Then (x, x ) is of one of the forms Since w is a word on Σ 8 \ Γ, we have τ (x) = τ (x ) thanks to Part 5 of Lemma 9. Therefore xyx is not a pre-5/4-power by Lemma 15. Case 2. Assume that |x| ≥ 2 is even. Then the sequences of subscripts in x and x are equal. By Part 4 of Lemma 9, each pair of corresponding letters in x and x with even subscripts belongs to To show that xyx is not a pre-5/4-power, we use Lemma 15 and show that there exists a pair (x(m), x (m)) of corresponding letters with odd subscript j such that x(m) = x (m). Since |x| is even and |xy| = 4|x|, then |xy| ≡ r mod 6 with r ∈ {0, 2, 4}. We break the remainder of the proof into two cases, depending on the value of r.
Case 2.1. Suppose that |xy| ≡ r mod 6 with r ∈ {2, 4}. If r = 2, then x contains a letter in the second (respectively, fourth or sixth) column if and only if x contains the corresponding letter in the fourth (respectively, sixth or second) column. If r = 4, then x contains a letter in the second (respectively, fourth or sixth) column if and only if x contains the corresponding letter in the sixth (respectively, second or fourth) column. Therefore it suffices to compare the second, fourth, and sixth columns, and we have pairs of the forms we have x(m) = x (m) thanks to Part 5 of Lemma 9. Therefore xyx is not a pre-5/4-power by Lemma 15.
Case 2.2. Assume that |xy| ≡ 0 mod 6, which implies |x| ≥ 6 since |xy| = 4|x| and |x| is even. Since |xy| ≡ 0 mod 6, x and x agree on their backgrounds, that is, letters in the first five columns. For instance, we may have as a factor of ϕ(n 0n1 · · ·n 5 ). Recall that we need to exhibit a pair of corresponding letters in x and x with odd subscript j such that x(m) = x (m). The only possibility is that x(m) and x (m) both belong to the sixth column. Toward a contradiction, suppose that such a pair does not exist, and so x and x also agree on their letters belonging to the sixth column. In particular, x = x . We have thus found a 5/4-power in ϕ(w). This violates Lemma 17 since w is pre-5/4-power-free by assumption. Therefore there is a pair with x(m) = x (m), so xyx is not a pre-5/4-power by Lemma 15. Now we return to studying the particular words z and s = zϕ(z)ϕ 2 (z) · · · from Definition 8. First we show that s is pre-5/4-power-free. As a consequence, we will show that pτ (ϕ(s)) is 5/4-power-free in Section 5. The words p and τ (z) have a common suffix 0003. Since this suffix is a factor of τ (ϕ(1 1 )) = τ (ϕ(1 5 )), this requires extra consideration in Theorem 20 and several other results.
If x overlaps the last 5 letters of z, then x contains the suffix 2 7 0 0 0 1 0 2 3 3 of z. If the subscripts in x and x differ by 4, then x being a factor of ϕ(z) · · · ϕ e+1 (z) implies that the factor 2 7 0 0 0 1 0 2 3 3 of x corresponds to a factor n 3 1 4n5 1 6n7 of x . So xyx is not a pre-5/4-power by Lemma 15. If the subscripts in x and x line up, then the factor 2 7 0 0 0 1 0 2 3 3 of x corresponds to a factor n 7 0 0n1 0 2n3 of x . Since 2 7 0 0 0 1 0 2 3 3 is not a factor of ϕ(z) · · · ϕ e+1 (z), we must have n 7 = 2 7 orn 1 = 0 1 or n 3 = 3 3 . Therefore xyx is not a pre-5/4-power by Lemma 15. Suppose x overlaps fewer than the last 5 letters of z. If |x| is odd, then the subscripts in x and x differ by 4. Since x contains the factor 3 3 1 4 , then x being a factor of ϕ(z) · · · ϕ e+1 (z) implies that the factor 3 3 1 4 of x corresponds to a factor n 7 0 0 of x , and xyx is not a pre-5/4-power by Lemma 15. If |x| is even, then the subscripts in x and x line up. The words x and x agree on even subscripts (by Part 3 of Lemma 9 because the length-4 suffix of z is 0 0 0 1 0 2 3 3 ). For odd subscripts, if the corresponding letters of x and x belong to different columns (that is, their positions are not congruent modulo 6), then, as in Case 2.1 in the proof of Proposition 19, they form one of the pairs with j odd and d ∈ {1, 2, 3}. Part 5 of Lemma 9 implies that xyx is not a pre-5/4-power by Lemma 15. If the corresponding letters belong to the same column, then x and x agree everywhere except maybe in the sixth column. Let j be the initial position of x in ϕ(z)ϕ 2 (z) · · · ϕ e+1 (z). Let u be the word of minimal length starting at position j 6 in zϕ(z) · · · ϕ e (z) such that x is a factor of ϕ(u ). If |u | ≤ 3, then |x| ≤ |ϕ(u )| ≤ 18, so |xyx | = 5|x| ≤ 90 < |zϕ(z)|, which means that xyx is a factor of zϕ(z). Due to the base case, we already know that xyx is not a pre-5/4-power.
Finally, consider the case |u | ≥ 4. Toward a contradiction, suppose x = x . Since x = x is a prefix of the word u is one of the two preimages Recall that u is a factor of zϕ(z) · · · ϕ e (z). By Part 3 of Lemma 9, the fourth letters 3 4 and 1 0 do not occur in ϕ(z) · · · ϕ e (z), so they must occur in z. Therefore neither 1 1 0 2 0 3 3 4 nor 1 5 2 6 0 7 1 0 is a factor of z. It follows that x = x .
Since the sequences of subscripts in x and x are equal, this implies that xyx is not a pre-5/4-power by Lemma 15.

5/4-power-freeness
In this section we show that pτ (ϕ(s)) is 5/4-power-free. As a consequence of Theorem 20, we obtain the following.
First assume is even. Assume toward a contradiction that x = x . Since |uv| = 4 is a multiple of 8, the sequences of subscripts in u and u line up. Then τ (u) = x = τ (u ) implies that u = u , and uvu is a 5/4-power in ϕ(s). This violates Proposition 21.
Recall that s is a word on Σ 8 \ Γ by Part 3 of Lemma 9.
If = 1, it is sufficient to check that the letter in position i in τ (ϕ(s)) is different from the letter in position i + 4 since Table (4) lists the letters in images of τ • ϕ. We do this by looking at six pairs of columns, each separated by 3 columns, in Table (4). The first and fifth columns are unequal row by row. For the second and sixth columns, several potential problems occur. For instance, in the fifth row, τ (ϕ(0 4 )) = 010011 contains the 5/4-power 10011, but fortunately 0 4 never appears in s. Similarly, −2 0 , −1 1 , −2 2 , −1 3 , −1 5 , 0 6 , −1 7 create 5/4-powers but never appear in s. For the third and first columns, we have to compare letters that are offset by 1 row. In particular, the last letter of the third column has to be compared with the first letter in the first column. We do the same for the remaining three pairs of columns and find that there are no 5/4-powers of length 5 in τ (ϕ(s)).
Suppose that ≥ 3. Each occurrence of u in ϕ(s) contains a letter with an even subscript, that is, a letter that falls either in the first, third, or fifth column in Table (4). Since the subscripts in u and u differ by 4, the pair of corresponding letters in u and u belongs to by Part 3 of Lemma 9, as in the proof of Proposition 19. This shows that τ (u) = τ (u ), which implies x = x .
Remark 23. Note that the previous argument works more generally to show that if w is a subscript-increasing pre-5/4-power-free word on Σ 8 \ Γ then τ (ϕ(w)) is 5/4-power-free.
The last step in showing that pτ (ϕ(s)) is 5/4-power-free is to prove that prepending p to τ (ϕ(s)) also yields a 5/4-power-free word. To that aim, we introduce the following notion.
Definition 24. Let N be a set of integers, and let α, β ∈ Z ∪ {n + 1, n + 2, n + 3}, where n is a symbol. Then α and β are possibly equal with respect to N if there exist m, m ∈ N such that α| n=m = β| n=m .
Two letters α, β are possibly equal with respect to N if we can make them equal by substituting integers from N for the symbol n. In particular, for every nonempty set N , two integers α, β are possibly equal if and only if α = β. The definition of possibly equal letters extends to words on Z ∪ {n + 1, n + 2, n + 3} in the natural way. The next two lemmas will be used to prove Theorem 27.
Proof. The set X α is the set of integer letters c such that the letter α is possibly equal to c with respect to N . Suppose the letters α, β ∈ {0, 1, . . . , 5} ∪ {n + 1, n + 2, n + 3} are possibly equal with respect to N . There are three cases to consider depending on the nature of these letters.
The computation took about a minute.
Here we abuse notation; namely, the n's are not necessarily equal. Observe that |ϕ(n 2 )ϕ(n 3 ) · · · ϕ(n 0 )ϕ(n 1 )| = 48. We use a method to distinguish factors based on . We also need to specify a set N of integers that, roughly speaking, represent the possible values that each symbolic n can take. Let S be a set of positions, and let N be a set of integers. As in Lemma 26, the set N represents values of n such that the last letter of τ (ϕ(n j )), namely n + d for some d ∈ {1, 2, 3}, is a letter in pτ (ϕ(s)). We maintain classes of positions corresponding to possibly equal factors starting at those positions. Start with = 0, for which all length-0 factors are equal. Then all positions belong to the same class S. At each step, we increase by 1, and for each position i we consider the factor of length starting at position i, extended from the previous step by one letter to the right. We break each class into new classes according to the last letter of each extended factor, as described in the following paragraph. We stop once each class contains exactly one position, because then each factor occurs at most once. Note that this procedure does not necessarily terminate, depending on the inputs. If it terminates, then we record .
For each class I, we build subclasses I c indexed by integers c. For each position i ∈ I, we consider the extended factor of length starting at position i. If 0 ≤ i ≤ |p| − 1, then the new letter is in Z because i + − 1 represents a particular position in pτ (ϕ(s)). If i ≥ |p|, then the new letter is either in Z or symbolic in n because i + − 1 represents all sufficiently large positions congruent to i + − 1 modulo 48. Now there are two cases. If the new letter is an integer c, we add the position i to the class I c . If the new letter is n + d where d ∈ {1, 2, 3}, then we add the position i to the class I n +d for each n ∈ N . We do this for all classes I and we use the union I {I c : c ∈ Z} as our new set of classes for the next length + 1.
It remains to show that using the set N = {0, 1, 2, 3, 4} is sufficient to guarantee that, since the procedures terminated, each length-952 factor x starting in p only occurs once in pτ (ϕ(s)). Since pτ (ϕ(s)) is a word on the alphabet N, it suffices to choose a subset N of N − {1, 2, 3} = {−3, −2, . . . }. There exist letters in pτ (ϕ(s)) that arise as the last letter of τ (ϕ(n j )) for arbitrarily large n, but the procedure cannot use an infinite set N . We use Lemmas 25 and 26 to show that N need not contain any integer greater than 4.
To remove −1, we run the procedure on the sets S 1 and S 2 again. However, this time we use the set {−1, 0, 1, 2, 3, 4} and we artificially stop the procedure at = 952.

Lexicographic-leastness
In this section we show that pτ (ϕ(s)) is lexicographically least by showing the following.
If i − |p| − 6|z| ≡ 5 mod 6, then the letter in position i belongs to one of the first five columns. Any 0 letters cannot be decreased. Observe that the fourth column is made of letters 0. Since each letter in the second column is 1, decreasing any letter 1 to 0 in the second column produces a new 5/4-power of length 5 of the form 0y0 between the fourth and second columns. Since the even-subscript letters in ϕ(s) form the word (1 4 1 6 0 0 0 2 ) ω by the proof of Part 3 in Lemma 9, then decreasing any letter 1 to 0 in the first, third, or fifth column introduces a 5/4-power of length 5.
If we decrease n + d to 1, then we create a new 5/4-power of length 5 because each letter in the second column is 1.
It remains to show that decreasing the letter n + d in position i in τ (ϕ 2 (s)) to a letter c ∈ {2, 3, . . . , n + d − 1} introduces a 5/4-power ending at that position. Intuitively, this operation corresponds to decreasing a letter n j in the preimage ϕ(s) to (c − d) j for some 0 ≤ j ≤ 7. In particular, the last letter of τ (ϕ((c − d) j )) is c. We examine three cases according to the value of d.
Case 1. If d = 1, then Notation 3 implies that the corresponding letter in position i in ϕ 2 (s) is (n + 1) 5 or (n + 1) 1 . We see that (n + 1) 5 and (n + 1) 1 appear in the images of n 4 and n 6 under ϕ. By Parts 3 and 4 of Lemma 9, the only letters with subscripts 4 and 6 in ϕ(s) are 1 4 and 1 6 . Therefore n = 1, and there is nothing to check since {2, 3, . . . , n + d − 1} is the empty set.
Let w be the word obtained by decreasing the last letter n + 2 in w to c, and let u be the word obtained by decreasing the last letter n j in u to (c − 2) j . Then τ (ϕ(u )) = w . By the induction hypothesis, pτ (u ) contains a 5/4-power suffix xyx. Now we consider two subcases, depending on where xyx starts in pτ (u ) as depicted below. (Case 2.2 contains two possibilities, but we show that the first does not actually occur.) p τ (u ) x y x Case 2.1 Case 2.2 x y x x y x Case 2.1. Suppose that xyx starts after p in pτ (u ), that is, xyx is a suffix of τ (u ). Write x = τ (x ) = τ (x ) and y = τ (y ) where x y x is the corresponding subscript-increasing suffix of u . Since |xy| is divisible by 4, the subscripts in x and x are either equal or differ by 4. Since d = 2, the subscripts of the last letters of x and x are odd. If |x| = 1, then x = c − 2 and ϕ(x ) = ϕ(x ) by definition of ϕ. Now if |x| ≥ 2, the subscripts of the penultimate letters of x and x are even and either equal each other or differ by 4. Since the subscripts cannot differ by 4 by Part 3 of Lemma 9, they must be equal. Since τ (x ) = τ (x ), we have x = x , so ϕ(x ) = ϕ(x ). Then pτ (ϕ(z))w = pτ (ϕ(zu )) contains the 5/4-power τ (ϕ(x y x )) as a suffix. Therefore, decreasing n + 2 to c introduces a 5/4-power in pτ (ϕ(s)) ending at position i.
Case 2.2. Suppose that xyx starts before τ (u ) in pτ (u ). In particular, τ (u ) is a suffix of xyx. Since i ≥ 331040 = 31|p| + 6|z|, 5|p| < i − |p| − 6|z| + 1 6 = |u| = |τ (u )| ≤ |xyx| = 5|x|, which implies |p| < |x|. Therefore the first x overlaps p but is not a factor of p. Suppose the overlap length is at least 5. Then the first x contains 20003 as a factor. But since 20003 is never a factor of an image under τ • ϕ, so the overlap length of x and p is at most 4. Then the first x = sv is made of a nonempty suffix s of 0003 followed by a nonempty prefix v of τ (u ) such that vyx = τ (u ). Write v = τ (v ), x = τ (x ), and y = τ (y ) where v y x = u . To get around the fact that p does not have subscripts, we use z instead to obtain a preimage of s under τ . Recall that 0003 is a common suffix of p and τ (z), and the corresponding suffix in z is 0 0 0 1 0 2 3 3 . So let s be the suffix of 0 0 0 1 0 2 3 3 such that s = τ (s ). Now observe that x = s v is a subscript-increasing factor of zu , overlapping z. Thus ϕ(x y x ) is a subscript-increasing suffix of ϕ(zu ), overlapping ϕ(z). By Part 3 of Lemma 9 again, since τ (x ) = τ (s v ) = sv = x = τ (x ) and |x| ≥ 2, the subscripts in x and x are equal. Consequently, x = x and ϕ(x ) = ϕ(x ). Then pτ (ϕ(z))w = pτ (ϕ(zu )) contains the 5/4-power τ (ϕ(x y x )) as a suffix. Therefore, decreasing n + 2 to c introduces a 5/4-power in pτ (ϕ(s)) ending at position i.

The sequence of letters in w 5/4
In this section we prove Corollary 5, which states that the sequence w(i) i≥0 of letters in w 5/4 satisfies (5) w(6i + 123061) = w(i + 5920) + for all i ≥ 0. Then we prove Theorem 6, which states that a sequence satisfying a certain recurrence is k-regular. In particular, the sequence of letters in w 5/4 is 6-regular.
Corollary 5 gives a recurrence for letters w(6i + 1) for sufficiently large i. Letters in the other residue classes modulo 6 are given by the next proposition, which follows directly from Theorem 4, the definition of ϕ, and the fact that w(6 · 1127 + 0) = 0.
Proposition 29. For all i ≥ 1127 = |p|−2 6 , the letters of the word w 5/4 satisfy Recall the definition of a k-regular sequence [2].
Definition 30. Let k ≥ 2 be an integer. For any sequence s(i) i≥0 , the set of subsequences {s(k e i + j) i≥0 : e ≥ 0 and 0 ≤ j ≤ k e − 1} is called the k-kernel of s(i) i≥0 . A sequence s(i) i≥0 is k-regular if the Q-vector space generated by its kkernel is finitely generated. The rank of s(i) i≥0 is the dimension of this vector space.
The following theorem is a generalization of [9,Theorem 8], which is the special case s = 0 and = 1.
Theorem 6. Let k ≥ 2 and ≥ 1. Let d(i) i≥0 and u(i) i≥0 be periodic integer sequences with period lengths and k , respectively. Let r, s be nonnegative integers such that r − s + k − 1 ≥ 0. Let w(i) i≥0 be an integer sequence such that, for all 0 ≤ m ≤ k − 1 and all i ≥ 0, Then w(i) i≥0 is k-regular.
In proving Theorem 6, we obtain an upper bound on the rank of w(i) i≥0 as a k-regular sequence.
Two integers k, ≥ 2 are said to be multiplicatively dependent if there exist positive integers α and β such that k α = β . They are multiplicatively independent if such integers do not exist. Bell [4] showed that if a sequence w(i) i≥0 is both kregular and -regular for multiplicatively independent integers k and then w(i) i≥0 is an eventual quasi-polynomial sequence. Since the ith letter in w a/b satisfies w(i) = O( √ i) [9, Theorem 9], this implies that the value of k for which the sequence of letters in w a/b is k-regular is unique up to multiplicative dependence.
The proof of Theorem 6 relies on the following technical lemma, which identifies kernel sequences on which Recurrence (6) can be iterated.
Lemma 31. Assume the hypotheses of Theorem 6. For every e ≥ 0, let For all sufficiently large e, if j ≡ j e mod k h where 0 ≤ h ≤ e, then we can iteratively apply the case m = k − 1 of Recurrence (6) at least h times to w(k e i + j) for all i ≥ r−s k−1 + 1.
Proof. The proof consists of two steps. First, we will show that the statement holds for all sufficiently large i. Second, we establish the lower bound on i, which is independent of e for sufficiently large e. We would like to iterate the case m = k − 1 of Recurrence (6), namely which will be useful to describe iterations of Recurrence (7). One checks that f e,t,j (i)+s = kf e,t+1,j (i)+r+k−1. Observe that if f e,t+1,j (i) ≥ 0, then f e,t,j (i) ≥ 0 since r − s + k − 1 ≥ 0 by assumption. Recurrence (7) gives w(f e,t,j (i) + s) = w(kf e,t+1,j (i) + r + k − 1) = w(f e,t+1,j (i) + s) + d(f e,t+1,j (i)) (8) if f e,t+1,j (i) ≥ 0. We proceed by induction on h. If h = 0, then the statement of the lemma is clear. Let j ≡ j e mod k h+1 with 0 ≤ h ≤ e − 1, and inductively assume that we can iteratively apply Recurrence (7) h times to w(k e i + j) for all sufficiently large i. By the induction hypothesis, iteratively applying Recurrence (8) to w(k e i + j) for t = 0, . . . , t = h − 1 yields for all sufficiently large i. We claim we can apply Recurrence (7) (in the form of Recurrence (8)) one more time to obtain that w(k e i + j) is equal to for all sufficiently large i. Indeed, j − s k h+1 − (1 + k + · · · + k h )(r − s + k − 1) k h+1 is an integer since, by assumption, It remains to establish the bound i ≥ r−s k−1 +1. To apply Recurrence (7) h times to w(k e i + j), we need f e,t,j (i) ≥ 0 for all t ∈ {1, . . . , h}. It follows by definition of f e,t,j (i) that f e,t,j (i) ≥ f e,t,0 (i). If follows from f e,t,0 (i) + s = kf e,t+1,0 (i) + r + k − 1 that f e,t,j (i) ≥ f e,e,0 (i) since t ≤ h ≤ e. We have As e gets large, the right side of the previous inequality approaches the finite limit r−s+k−1 k−1 . Therefore, for all sufficiently large e and for all integers i ≥ r−s+k−1 k−1 , we can apply Recurrence (7) h times to w(k e i + j), as desired.
We now prove Theorem 6. We will define a sequence (j e ) e≥0 , where each j e is the unique residue modulo k e for which we can apply Recurrence (6) the maximal number of times to w(k e i + j e ). For w 5/4 , the sequence (j e ) e≥0 is 0 , 1, 31, 31, 895, 7375, 38479, 38479, 318415, 1998031, . . . .
We will see in the proof of Theorem 33 that applying the recurrence to w(k e i + j e ) for large e produces w(k e−1 i + j e−1 ).
Proof of Theorem 6. We show that the Q-vector space generated by the k-kernel of w(i) i≥0 is finitely generated. We will see that subsequences w(k e i + j) i≥0 for certain values of j behave differently than others. Namely, for most sequences, iteratively applying Recurrence (6) to all but finitely many terms brings us into the periodic background u (this is Case 1 below), but for certain sequences we stay in the self-similar column (Case 2).
For every e ≥ 0, we let where j e is defined as in Lemma 31 and q e is the unique integer such that 0 ≤ j e − k e q e < k e . Since r − s + k − 1 ≥ 0, q e is nonnegative. Since 0 ≤ je k e < 1, we In particular, q e = Q e . As e gets large, Q e approaches the finite limit r−s+k−1 k−1 , so the integers q e are the same for all e ≥ E for some integer E ≥ 0. We take E to be minimal. We show that there exists M ≥ 0 such that, for all e ≥ 0 and 0 ≤ j ≤ k e − 1, w(k e i + j) i≥0 belongs to the Q-vector space generated by the finite set {w(k e i + j) i≥0 : 0 ≤ e ≤ E − 1 and 0 ≤ j ≤ k e − 1} ∪ {w(k e i + j e ) i≥0 : 0 ≤ e ≤ M } and finitely many eventually periodic sequences.
As in the proof of Lemma 31, define Case 1. First, we consider subsequences w(k e i + j) i≥0 with 0 ≤ j ≤ k e − 1 and j = j e . We show that all but finitely many have tails that can be expressed in terms of u by iterating Recurrence (6). Let h be maximal such that j ≡ j e mod k h . By Lemma 31, we can iteratively apply Recurrence (7) h times to w(k e i + j) for all e ≥ E and i ≥ q E + 1, giving from Equation (9). Since h is maximal, we cannot apply Recurrence (7) an additional time. If i ≥ q E + 1, then f e,h,j (i) + s ≥ kf e,e,0 (i) + r + k − 1 ≥ r, as in the proof of Lemma 31. So we can apply the case m = k − 1 of Recurrence (6) instead to w(f e,h,j (i) + s). Therefore (10) w(k e i + j) = u(f e,h,j (i) + s − r) + h−1 t=0 d(f e,t+1,j (i)), so w(k e i + j) i≥q E +1 is a periodic sequence with period length at most k since u and d are periodic sequences with period lengths dividing k . Therefore w(k e i + j) i≥0 is an eventually periodic sequence with preperiod length at most q E + 1, which is independent of e and j. It suffices to include generators for eventually periodic sequences with preperiod length q E + 1. Let G k be the standard basis for periodic sequences with period length k (that is, with periods of the form 0, . . . , 0, 1, 0, . . . , 0). For all m ≥ 0, let v m (i) i≥0 be the sequence defined by v m (m) = 1 and v m (i) = 0 for all i = m.
Each sequence w(k e i+j) i≥0 for e ≥ 0 and j = j e belongs to the Q-vector space generated by which is finite-dimensional. Case 2. Second, we examine subsequences w(k e i + j e ) i≥0 . We show that these sequences do not depend on u and that all but finitely many of them are essentially generated by one. We defined j e in such a way that k e i + j e = f e,0,je (i) + s. From Equation (9), e applications of Recurrence (6)  for all i ≥ q e , after expanding f e,e,je (i). However, we would like to get a relation of this form that holds for all i ≥ 0. It is possible that e applications of the recurrence are too many, and in such cases we use h applications and choose h accordingly. For h ≤ e, Equation (9) with j = j e gives (11) w(k e i + j e ) = w(f e,h,je (i) + s) + h−1 t=0 d(f e,t+1,je (i)), as long as f e,h,je (i) ≥ 0. We consider two cases, because if r−s k−1 is an integer then the integers j e are the same when e is sufficiently large.
Case 2.1. Suppose r−s k−1 is not an integer. The sequence (Q e ) e≥0 approaches its limit from either above or below; in either case q e = Q e < r−s+k−1 k−1 for sufficiently large e. (Note the strict inequality, since r−s k−1 is not an integer.) We would like f e,h,je (i) ≥ 0. Since f e,h,je (i) is an increasing function of i, it suffices to guarantee that f e,h,je (0) ≥ 0. We get Since q e < r−s+k−1 k−1 , the argument of the log k is in the interval (0, 1). We use the largest integer h satisfying the inequality, namely We conclude that, for all e ≥ E, is independent of e (recall that q e = q E for all e ≥ E). Therefore each sequence w(k e i + j e ) i≥0 for e ≥ 0 belongs to the Q-vector space generated by  Therefore each sequence w(k e i + j e ) i≥0 for e ≥ 0 belongs to the Q-vector space generated by where σ is the right shift operator, which prepends a 0 to the front of a sequence. Again this vector space is finite-dimensional. We have shown that the k-kernel is contained in the Q-vector space generated by if r−s k−1 is not an integer and is an integer is the constant mentioned at the beginning of the proof.
Corollary 32. The sequence of letters in w 5/4 is a 6-regular sequence with rank at most 79472.
In fact the rank is much smaller.
Theorem 33. The sequence of letters in w 5/4 is a 6-regular sequence with rank 188.
To prove Theorem 33, we first reduce the bound from Corollary 32 to 4078.
Proposition 34. The sequence of letters in w 5/4 is a 6-regular sequence with rank at most 4078.
Proof. We use the value of the constants k, , r, s, u, d, E, and q E from the previous proof. Recall from the proof of Corollary 32 that the k-kernel of w 5/4 is a subset of the Q-vector space generated by (13).
First, we show that we can omit the generators Let 0 ≤ e ≤ E − 1, let 0 ≤ j ≤ k e − 1 such that j = j e , and let h be maximal such that j ≡ j e mod k h . As stated, Lemma 31 applies for large e, but we show that we can apply the end of the proof to small e. For the word w 5/4 , (Q e ) e≥0 approaches its limit from below: (q e ) 0≤e≤E−1 = 5920, 20510, 22941, 23347, 23414, 23425, 23427.
In particular, q e ≤ q E = 23428 for all e ≥ 0. Therefore, for all i ≥ q E + 1, we can see from the end of the proof of Lemma 31 that f e,e,0 (i) ≥ 0, so Equation (9) holds, namely w(k e i + j) = w(f e,h,j (i) + s) + h−1 t=0 d(f e,t+1,j (i)).
Furthermore, from Case 1 in the proof of Theorem 6, i ≥ q E + 1 also implies that Equation (10) holds, namely Thus w(k e i + j) i≥0 belongs to the Q-vector space generated by G k ∪ H q E +1 . Additionally, we just need half the generators in G k since u agrees with τ (ϕ(0 0 0 1 0 2 0 3 ) 2 ) ω except on positions congruent to 5 modulo 6. Let G 24 be the standard basis for periodic sequences with period length 24. Since divides 24, each sequence d(f e,h,j (i)) i≥0 belongs to the Q-vector space generated by G 24 .
Finally, we show that we do not need all generators in H q E +1 . Recall that H q E +1 was constructed with q E + 1 generators since, for all 0 ≤ j ≤ k e − 1 such that j = j e , the sequence w(k e i + j) i≥0 is eventually periodic with preperiod length at most q E + 1. For all i ≥ q E + 1 we can apply Corollary 5 h times to w(k e i + j), where h is maximal such that j ≡ j e mod k h , followed by the case m = k − 1 of Theorem 6. We show that we can lower the bound on i by using Proposition 29 instead of the case m = k − 1 of Theorem 6; namely, for all i ≥ 4046, we can apply Corollary 5 h times to w(k e i + j), followed by Proposition 29. This will imply that we can replace H q E +1 with H 4046 . We consider large e and small e separately.
Let e ≥ E, and let 0 ≤ j ≤ k e − 1 such that j = j e . Let h be maximal such that j ≡ j e mod k h . In the proof of Lemma 31, we were able to apply Corollary 5 h times to w(k e i + j) by choosing i so that f e,e,0 (i) ≥ 0. Let i ≥ 4046. Then |p| − 2 − s k since the right side of the previous inequality approaches 4045 + 1 30 from below as e gets large. By definition of f , this implies f e,e−1,0 (i) + s ≥ |p| − 2. Since |p| − 2 − s > 0, this also implies f e,e−1,0 (i) ≥ 0. Since j = j e in our current case, we have h = e, and therefore f e,e−1,0 (i) ≥ 0 is sufficient to apply Corollary 5 h times. This gives w(k e i + j) = w(f e,h,j (i) + s) + h−1 t=0 d(f e,t+1,j (i)) as in Case 1 of the proof of Theorem 6. Since h is maximal, we cannot apply Corollary 5 an additional time. Instead, we apply Proposition 29 to w(f e,h,j (i) + s), since f e,h,j (i) + s ≥ |p| − 2 (as opposed to f e,h,j (i) + s ≥ r as in Case 1). This gives so w(k e i + j) i≥4046 is a periodic sequence with period length at most k . Therefore w(k e i+j) i≥0 is an eventually periodic sequence with preperiod length at most 4046. For 0 ≤ e ≤ E − 1, it is sufficient to check that f e,h,j (i) + s ≥ |p| − 2, since the rest of the argument is the same as the case when e ≥ E. A finite check shows that this inequality holds for all i ≥ 4046.
We have shown that the 6-kernel of w 5/4 is a subset of the Q-vector space generated by which has dimension at most 24 + 4046 + (E + 1) = 4078.
Proof of Theorem 33. We continue to use the constants k = 6, = 8, r = 123056, s = 5920, E = 7, and so on. Let j e be defined as in the proof of Theorem 6. Let be the vector space generated by the kernel sequences w(k e i + j) i≥0 with 0 ≤ e ≤ E and j = j e , and let We show that dim V = 179, dim W = 8, and the vector space generated by the kkernel of w(i) i≥0 is the direct sum V ⊕W ⊕ w(k E+1 i+j E ) i≥0 , which has dimension 188. Let e ≥ 0 and 0 ≤ j ≤ k e − 1 such that j = j e . We claim that the first 4050 terms of the sequence w(k e i + j) i≥0 determine it uniquely. From the proof of Proposition 34, w(k e i + j) i≥4046 is periodic. Since we used Proposition 29 to obtain the bound 4046, the period length of w(k e i + j) i≥4046 is a divisor of 4. Therefore the first 4046 + 4 terms determine it uniquely.
In particular, the first 4050 terms of each generator of V determine the sequence uniquely. Therefore we obtain the dimension of V by row-reducing the matrix containing the first 4050 terms of each sequence w(k e i + j) i≥0 with 0 ≤ e ≤ E, 0 ≤ j ≤ k e − 1, and j = j e . This gives dimension 179 and took about a half hour using 8 parallel threads.
In computing the dimension of V , we computed a basis of V consisting of kernel sequences. We claim that all periodic sequences with period length 4 and the sequence 1, 0, 0, . . . belong to V . For m ∈ {0, 1, 2, 3}, define g m (i) = 1 if i ≡ m mod 4 and g m (i) = 0. Let G 4 = {g m (i) i≥0 : 0 ≤ m ≤ 3}, and let H 1 = {v 0 (i) i≥0 }, where v 0 (i) i≥0 is the eventually 0 sequence as defined in the proof of Proposition 34. Each sequence in G 4 ∪ H 1 is eventually periodic with preperiod length ≤ 4046 (in fact ≤ 1) and period length dividing 4, so row-reducing a 184-row matrix using the first 4050 terms shows that G 4 ∪ H 1 ⊂ V . This computation took less than a second and finds the relations In particular, since G 4 ⊂ V , the constant sequence (1) i≥0 is an element of V .
We show that w(k e i + j e ) i≥0 / ∈ V for 0 ≤ e ≤ E, that w(k E+1 i + j E ) i≥0 / ∈ V , and that all 188 sequences are linearly independent of each other, by using the first 4050 terms of the 179 basis elements of V and row-reducing the appropriate 188-row matrix. This computation took less than a second. In particular, dim W = E + 1 = 8.
By definition, the kernel sequences w(k e i + j) i≥0 for all 0 ≤ e ≤ E belong to V ⊕ W . We have proved that this vector space has dimension 187. It remains to show that for e ≥ E + 1 all the kernel sequences w(k e i + j) i≥0 belong to V ⊕ W ⊕ w(k E+1 i + j E ) i≥0 . First we consider j = j e . We show that w(k e i + j e ) = w(k E i + j E ) + 2(e − E).
In Equation (14), t + 1 ≤ h e = e − E, so e − t − 1 ≥ E = 7. Therefore k e−t−1 ≡ 0 mod , so we get f e,t+1,je (i) ≡ −1 k − 1 (r − s + k − 1) ≡ 7 mod for all i ≥ 0. Since d(7) = 2, the sum on the right side of (14) is = w k e−he i + k e−he − 1 k − 1 (r − s + k − 1) − q E k e−he + s + 2(e − E) as desired. Therefore w(k e i + j e ) i≥0 is a linear combination of the kernel sequence w(k E i + j E ) i≥0 ∈ W and the constant sequence (1) i≥0 ∈ V . Now let 0 ≤ j ≤ k e − 1 such that j = j e . We use induction on e, so assume that w(k e−1 i + j ) i≥0 ∈ V ⊕ W ⊕ w(k E+1 i + j E ) i≥0 for all 0 ≤ j ≤ k e−1 − 1. If j ≡ 1 mod k, then Proposition 29 implies that w(k e i+j) i≥1 is periodic with period length dividing 4. Therefore w(k e i + j) i≥0 is a linear combination of sequences in G 4 ∪ H 1 ⊂ V . Now assume j ≡ 1 mod k. From Equations (8) and (9), we have w(k e i + j) = w(f e,0,j (i) + s) = w(f e,1,j (i) + s) + d(f e,1,j (i)).

Open questions
We end this paper with several open questions. Regarding finite alphabets, the structure of the lexicographically least square-free infinite word on {0, 1, 2} is still unknown [3, Open Problem 2 in Section 1.10].
The following table presents the known information about w a/b for simple rational numbers a/b. Here k is the smallest value for which the sequence of letters in w a/b is k-regular, and we include the values of d which arise in the morphism. The values of r and s are as in Recurrence (2) and are chosen to be minimal. The rank of each sequence for which s = 0 can be determined from the recurrence it satisfies. This table emphasizes the extent to which w 5/4 is more complicated than other words. Previous work on w a/b has suggested that the structure of the word w a/b is generally more complicated for even denominators b than for odd b. This trend is supported by the structure of w 5/4 . An obvious question is whether the proof strategy for w 5/4 can be applied to other words w a/b . It seems likely that it can, but we leave this an open question. The major difficulties are that identifying the structure of w a/b potentially requires computing a huge number of terms and that we do not have a systematic way of guessing the structure even if we have many terms.
Ordered by denominator, the simplest words whose structure is not yet known are w 7/5 , w 7/6 , and w 11/6 . Pudwell and the first-named author [9,Conjecture 6] conjectured that the letters of w 7/5 satisfy w(80874i + 173978) = w(i) + 1 for all i ≥ 0. Here we conjecture the structure of five additional words.
For all i ≥ 0, the letters of w 8/7 satisfy w(340i + 52670) = w(i) + 3.  However, we still do not have a conjecture for w 11/6 and w 11/8 . Based on w 3/2 and w 5/4 , one might guess that w 7/6 and w 9/8 have similar structure. In Conjecture 35, the recurrence for w 7/6 has a single value of d and s = 0, so it does not seem to be part of the same family. For w 9/8 , we do not have a conjectural recurrence, but experiments suggest that k = 156 is promising.
Additionally, there are other natural notions of pattern avoidance for fractional powers on N. For a/b > 1, we define two additional words. Let w ≥a/b be the lexicographically least infinite word on N avoiding p/q-powers for all p/q ≥ a/b, and let w >a/b be the lexicographically least infinite word on N avoiding p/q-powers for all p/q > a/b.
Guay-Paquet and Shallit [8] asked whether w ≥5/2 is in fact a word on {0, 1, 2}. This question is still open. Pudwell and Rowland [9, Theorem 71] proved that w 27/23 is a word on the finite alphabet {0, 1, 2}, showing that there exist lexicographically least pattern-avoiding words defined on N that only use a finite alphabet.
Pudwell and Rowland [9, Conjecture 13] conjectured that w ≥4/3 (336i + 1666) = w 4/3 (56i + 17) + 4 for all i ≥ 0. This suggests that the structure of w ≥a/b is slightly more complicated than that of w a/b . However, not much is known about w ≥a/b . Guay-Paquet and Shallit [8] showed that the overlap-free word [11, A161371] w >2 = 001001100100200100110010021001002001001100 · · · is generated by a non-uniform morphism, which leads us to believe that the structure of w >a/b is even more complicated than that of w a/b . The biggest question remains the following. For each a/b, is there an integer k ≥ 2 such that the sequence of letters in w a/b is k-regular? Similarly, one could ask about w ≥a/b . Finally, which words w >a/b are k-regular for some k?