Given a binary word relation $\tau$ onto A * and a finite language X $\subseteq$ A * , a $\tau$-Gray cycle over X consists in a permutation w [i] 0$\le$i$\le$|X|--1 of X such that each word w [i] is an image under $\tau$ of the previous word w [i--1]. We define the complexity measure $\lambda$A,$\tau$ (n), equal to the largest cardinality of a language X having words of length at most n, and st. some $\tau$-Gray cycle over X exists. The present paper is concerned with $\tau$ = $\sigma$ k , the so-called k-character substitution, st. (u, v) $\in$ $\sigma$ k holds if, and only if, the Hamming distance of u and v is k. We present loopless (resp., constant amortized time) algorithms for computing specific maximum length $\sigma$ k-Gray cycles.
翻译:给定一个定义在A*上的二元词关系τ以及一个有限语言X ⊆ A*,若存在X的一个排列w[i](0≤i≤|X|-1),使得每个词w[i]是前一词w[i-1]在τ下的像,则称该排列为X上的τ-格雷循环。我们定义复杂度度量λA,τ(n),其值等于存在某个τ-格雷循环的语言X(所有词长度不超过n)的最大基数。本文关注τ = σk,即所谓的k字符替换关系,满足(u, v) ∈ σk当且仅当u与v的汉明距离为k。我们提出了计算特定最大长度σk-格雷循环的无环算法(以及常数平摊时间算法)。