Generating key points…
Answers are grounded in this paper and cite their sources.
Which overlaps must two patterns share for a bijection to carry their occurrences to exactly the same positions? For finite words, equal border lengths suffice to carry the complete set of starts of one pattern to that of the other. To exchange both patterns' start sets simultaneously on a circle or an infinite line, the construction uses compatibility of both self-overlaps and directed overlaps between the patterns. The circular swap respects rotations, and the bi-infinite swap respects translations. Let \(p,q\) be nonempty words of equal length \(m\) over a finite alphabet \(Σ\). Write \(Occ_r(w)\) for the set of starts at which the consecutive letters of the host \(w\) spell the pattern \(r\). For a length-\(m\) word \(a\), write \(pre_k(a)\) and \(suf_k(a)\) for its first and last \(k\) letters. Define the proper ordered overlap lengths by \[B(a,b)=\{k∈\{1,…,m-1\}:suf_k(a)=pre_k(b)\}. \] Thus \(B(a,a)\) records the proper border lengths of \(a\). Including the full length \(m\) gives the same test for equality of self-border sets. For a simultaneous pair swap, compatibility means \(B(p,p)=B(q,q)\) and \(B(p,q)=B(q,p)\). Carrigan, Hollars and Rowland asked for a natural, directly computable avoidance bijection for every pair with the same border lengths. Earlier enumeration gave equal avoidance counts, and their construction covered a proper subfamily. For every such pair and every integer \(n≥ 0\), the explicit map \(Fp,q:Σ^n→Σ^n\) satisfies \[Occ_q(Fp,q(w))=Occ_p(w), Fp,q⁻¹=Fq,p. \] Taking the start set to be empty gives the requested avoidance bijection. The map fixes common avoiders and commutes with a simultaneous renaming of the alphabet in the patterns and host. Carrigan, Hollars and Rowland, §1 motivation and Theorem 3.1 To compute this map, protect the set \(S=Occ_p(w)\) and initialise the marked starts to \(M=S\). Alternate two operations. First replace the letters in the union of the marked windows by the other pattern at those same starts, leaving the remaining letters as they are. On the receiving side, if there is an occurrence of its pattern outside \(S\), toggle the mark at the leftmost such start, keeping the letters fixed, and repeat. Otherwise return the current word. Equal self-border lengths make all overlapping marked prescriptions consistent. This finite form of the classical involution principle terminates on the opposite side with exactly \(S\) as its start set. Exchanging the pattern roles reverses the operations. Each step takes \(O(nm)\) time for a host of positive length, and the number of steps can be exponential. Hosts shorter than \(m\) are fixed. The guarantee concerns one start set. For example, \(0110\) and \(1011\) have the same proper border length \(1\) and occur at starts \(0\) and \(2\) in \(011011\). Exchanging both at those starts would require the shared two letters to be both \(11\) and \(01\). Naimi's circular question asks whether a compatible pair's two exact start sets can be exchanged in a single circular alignment, even when two windows meet along two separate arcs. For every circumference \(n≥ 1\), there is an involution \(F\) on indexed words with sites in \( Z/n Z\) such that \[Occ_p(F(w))=Occ_q(w), Occ_q(F(w))=Occ_p(w). \] Each window reads forward from its start, with indices reduced modulo \(n\). Under the single-turn convention, patterns longer than \(n\) have no occurrences. Under periodic reading, the same theorem allows a window to revisit sites. The indexed map commutes with rotation, so it induces an involution on words up to rotation and preserves each word's rotational stabiliser, the rotations that fix it. For instance, exchanging \(102\) and \(201\) sends the indexed word \(1020\) to \(2010\), exchanging starts \(0\) and \(2\) within the same rotation class. Naimi, §8, 'Circular words', p. 33 For the circular construction, record the complete set of labelled starts and let \(U\) be the sites they cover. A word with no starts is fixed. Swap the labels and fill \(U\) with the resulting prescribed letters. To check consistency, choose integer representatives \(s,t\) of two starts and test the window at \(s\) against all relevant lifts \(t+kn\), \(k∈ Z\). A nonzero displacement \(d=t+kn-s\) with \(|d|<m\) is tested using overlap length \(m-|d|\), taking the suffix from the earlier window. This includes a window's overlaps with its own translates. A candidate wholly in \(U\) occurs exactly when its prescription is consistent with the recorded ones. Every other candidate meets only one uncovered gap, since the covered components separating gaps each contain at least \(m\) sites. For a gap of length \(h\) whose first site in the forward direction is \(g\), examine starts in the order \(g+1-m,…,g+h-1\) modulo \(n\). Run the same replacement and toggle procedure with the recorded starts protected and the optional marks initially empty. Replacement rewrites only the marked sites within the gap, using the prescribed covered letters on each side. Toggle the first actual occurrence meeting the gap and stop when there is none. The gap filling is computed independently of the other gaps, and the procedure can take exponentially many steps within a gap. The construction also gives inverse circular maps for a permutation \(ρ\) of finitely many distinct length-\(m\) patterns \(p_i\), provided \(B(p_i,p_j)=B(pρ(i),pρ(j))\) for every ordered pair of types \(i,j\). The inverse uses \(ρ⁻¹\). Naimi also asked for the simultaneous exchange on all one-sided and bi-infinite words. For every finite alphabet and compatible pair, the same two exact start-set identities hold for Borel involutions on \(ΣN\) and \(ΣZ\), with \( N=\{0,1,…\}\). Borel measurability refers to the product of the discrete alphabet topologies. On \( Z\) the involution commutes with every integer translation. Covered sites are filled by the swapped prescriptions. Finite gaps use the same finite procedure, scanning valid starts in increasing order and respecting the left endpoint of a one-sided host. Equal patterns act by the identity. Naimi, §8, 'Countable infinite words' An unbounded right gap needs a bijection of entire legal tails. Its anchor \(u∈\{p,q\}\) is the last actual occurrence before the gap. Define \[T_u=\{x∈ΣN: ux has no occurrence of p or q starting after 0\}. \] For every integer \(L≥ 0\), the finite construction with the start at zero protected gives equal numbers of length-\(L\) tails for which the anchor is the sole occurrence. If the two length-\((m-1)\) prefixes agree, no occurrence crosses the end of either anchor, and the same tail can be used on both sides. Otherwise, at most one next letter is forbidden at each step, so every legal finite tail extends to an infinite one. The finite counts then give the exact numbers of realised prefixes of each length on the two sides. To construct the tail pairing, fix an alphabet order and use the directed graph whose states are the last \(m-1\) letters, starting at the suffix of the anchor. Each allowed next letter gives a labelled edge to the updated suffix. If neither graph has a reachable strongly connected component with two internal edges leaving one state, each infinite path eventually stays on a simple cycle. Match equal ranks in lexicographic order for finite tail sets. For countably infinite tail sets, order by length and then lexicographically the finite paths ending at the first entry to their final cycle, and match equal ranks. The common prefix counts distinguish these two cases. The other possibility occurs for both anchors and gives continuum-sized tail sets. Two internal edges at one state give two return loops with distinct first letters, so choosing loops by successive bits embeds binary sequences into the legal tails. Fixed-length binary encodings of letters and these loop embeddings give continuous injections \(f:T_p→ T_q\) and \(g:T_q→ T_p\). Set \[A_0=T_p g(T_q), A=j≥0(g∘ f)^j(A_0), \] where the zeroth iterate is the identity. Use \(f\) on \(A\) and \(g⁻¹\) on \(T_p A\). This gives a Borel bijection with a Borel inverse. Use the pairing in the direction set by the input anchor. For a left-unbounded gap, reverse the tail and its adjoining pattern, apply the corresponding right-tail rule for the reversed patterns, and reverse back. Each tail is thereby matched within its full legal language, including the constraint across its anchor.
No takes yet. Share an insight, caveat, or question.
Zixuan He (2026) studied this question.
Synapse has enriched 8 closely related papers on similar clinical questions. Consider them for comparative context: