9
Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length n = 2 k ± 1 and Weight 3 Shung-Liang Wu 1 and Hung-Lin Fu 2 1 Department of Computer Science and Information Engineering, National United University, Miaoli 36003, Taiwan, E-mail: [email protected] 2 Department of Applied Mathematics, National Chaio Tung University, Hsin Chu 30010, Taiwan, E-mail: [email protected] Received February 16, 2012; revised August 28, 2012 Published online 5 October 2012 in Wiley Online Library (wileyonlinelibrary.com). DOI 10.1002/jcd.21332 Abstract: For a k-subset X of Z n , the set of differences on X is the set X ={i j (mod n): i , j X, i = j } . A conflict-avoiding code CAC of length n and weight k is a collection C of k-subsets of Z n such that X Y =∅ for any distinct X, Y C. Let CAC(n, k) be the class of all the CACs of length n and weight k. The maximum size of codes in CAC(n, k) is denoted by M(n, k). A code C CAC(n, k) is said to be optimal if |C|= M(n, k). An optimal code C is tight equi-difference if XC X = Z n \{0} and each codeword in C is of the form {0, i , 2i ,..., ( k 1) i }. In this paper, the necessary and sufficient conditions for the existence problem of optimal tight equi-difference conflict-avoiding codes of length n = 2 k ± 1 and weight 3 are given. C 2012 Wiley Periodicals, Inc. J. Combin. Designs 21: 223–231, 2013 Keywords: conflict-avoiding codes; equi-difference; optimal codes 1. INTRODUCTION A protocol sequence set for a multiple-access collision channel without feedback has been investigated by many researchers [3, 5–7, 12, 15]. A set X ={X 1 ,X 2 ,...,X N } of N binary sequences is called an (N,k,n,σ ) protocol sequence set if any X i = (x i,0 ,x i,1 ,...,x i,n1 ) X is of length n and weight k and has the property that at least σ successful packet transmissions in a frame are guaranteed for each active user, provided that at most k out of N users are active. This (N,k,n,σ ) protocol sequence set with σ = 1 is said to be a conflict-avoiding code CAC of length n and weight k, and can be reformulated as a set X of binary sequences of length n and weight k with the Journal of Combinatorial Designs C 2012 Wiley Periodicals, Inc. 223

Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length n = 2 k ± 1 and Weight 3

Embed Size (px)

Citation preview

Page 1: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

Optimal Tight Equi-DifferenceConflict-Avoiding Codes of Lengthn = 2k ± 1 and Weight 3

Shung-Liang Wu1 and Hung-Lin Fu2

1Department of Computer Science and Information Engineering, National UnitedUniversity, Miaoli 36003, Taiwan, E-mail: [email protected]

2Department of Applied Mathematics, National Chaio Tung University, Hsin Chu30010, Taiwan, E-mail: [email protected]

Received February 16, 2012; revised August 28, 2012

Published online 5 October 2012 in Wiley Online Library (wileyonlinelibrary.com).DOI 10.1002/jcd.21332

Abstract: For a k-subset X of Zn, the set of differences on X is the set �X = {i − j (modn): i, j ∈ X, i �= j} . A conflict-avoiding code CAC of length n and weight k is a collection Cof k-subsets of Zn such that �X

⋂�Y = ∅ for any distinct X, Y ∈ C. Let CAC(n, k) be the

class of all the CACs of length n and weight k. The maximum size of codes in CAC(n, k) isdenoted by M(n, k). A code C ∈ CAC(n, k) is said to be optimal if |C| = M(n, k). An optimalcode C is tight equi-difference if

⋃X∈C �X = Zn \ {0} and each codeword in C is of the form

{0, i, 2i, . . . , (k − 1)i}. In this paper, the necessary and sufficient conditions for the existenceproblem of optimal tight equi-difference conflict-avoiding codes of length n = 2k ± 1 and weight3 are given. C© 2012 Wiley Periodicals, Inc. J. Combin. Designs 21: 223–231, 2013

Keywords: conflict-avoiding codes; equi-difference; optimal codes

1. INTRODUCTION

A protocol sequence set for a multiple-access collision channel without feedback hasbeen investigated by many researchers [3, 5–7, 12, 15]. A set X = {X1, X2, . . . , XN }of N binary sequences is called an (N, k, n, σ ) protocol sequence set if any Xi =(xi,0, xi,1, . . . , xi,n−1) ∈ X is of length n and weight k and has the property that at least σ

successful packet transmissions in a frame are guaranteed for each active user, providedthat at most k out of N users are active. This (N, k, n, σ ) protocol sequence set withσ = 1 is said to be a conflict-avoiding code CAC of length n and weight k, and canbe reformulated as a set X of binary sequences of length n and weight k with the

Journal of Combinatorial DesignsC© 2012 Wiley Periodicals, Inc. 223

Page 2: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

224 WU AND FU

following property:

∑0≤r≤n−1

xi,rxj,r+q ≤ 1,

for any distinct Xi, Xj in X and every integer q, where the subscripts are taken modulon.

In mathematical terms, a conflict-avoiding code CAC of length n and weight k is aset C ⊆ {0, 1}n of binary vectors, or codewords, all of Hamming weight k, such thatthe Hamming distance between arbitrary cyclic shifts of distinct codewords is at least2k − 2. By identifying each codeword in C with a k-subset of Zn representing the indicesof its nonzero positions, where Zn is the group of residues modulo n, we can restate thedefinition of CAC the following.

For a k-subset X of Zn, the set of differences on X is defined to be the set

�X = {i − j (mod n) : i, j ∈ X, i �= j}.

A conflict-avoiding code CAC of length n and weight k is a set C of k-subsets, calledcodewords, of Zn such that �X

⋂�Y = ∅ for any distinct X, Y ∈ C. Codewords X, Y

in C are said to be equivalent if �X = �Y . Let CAC(n, k) denote the class of all theCACs of length n and weight k. The maximum size of codes in CAC(n, k) is denotedby M(n, k). A code C ∈ CAC(n, k) is optimal if |C| = M(n, k). Since for any codewordX in C, there is an integer r in Zn such that the translation X = {i + r ∈ Zn : i ∈ X}contains the element 0 of Zn and their set of differences is invariant under translation, i.e.,�X = �X, we can assume without loss of generality that each codeword in C includesthe element 0.

Suppose X is a codeword in CAC of length n and weight k. This codeword X is saidto be equi-difference if it is of the form

X = {0, i, 2i, . . . , (k − 1)i} (mod n).

Evidently, in this case, �X = {±ri : 1 ≤ r ≤ k − 1} and |�X| ≤ 2(k − 1). A codewordwith |�X| < 2(k − 1) is called exceptional. If all codewords in C are equi-difference,then C is called an equi-difference code. The maximum size of equi-difference codes inCACe(n, k) is defined in an analogous manner to M(n, k), i.e., Me(n, k) = max{|C| :C ∈ CACe(n, k)}, where CACe(n, k) is the class of all the equi-difference codes inCAC(n, k).

For convenience sake, CAC(n, 3), CACe(n, 3), M(n, 3), and Me(n, 3) are simplywritten as CAC(n), CACe(n), M(n), and Me(n), respectively. By �C, we mean the unionof sets of differences of codewords in C, that is, �C = ⋃

X∈C �X. A code C of length n

is tight if �C = Zn \ {0}.Several works have been done for M(n). Levenshtein and Tonchev [5, 6] show that

M(n) ≤ n+14 and M(n) = Me(n) = n−2

4 if n ≡ 2 (mod 4).

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 3: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

OPTIMAL TIGHT EQUI-DIFFERENCE CONFLICT-AVOIDING CODES 225

When n is a multiple of 4, Jimbo et al. [4] give a better upper bound on M(n) withn = 4t as follows.

M(n) ≤

⎧⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎨⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎪⎩

7n/32, if t ≡ 0 (mod 8),(7n + 4)/32, if t ≡ 1 (mod 8),(7n − 24)/32, if t ≡ 2, 10 (mod 24),(7n + 12)/32, if t ≡ 3 (mod 24),(7n − 16)/32, if t ≡ 4, 20 (mod 24),(7n − 12)/32, if t ≡ 5, 13 (mod 24),(7n − 8)/32, if t ≡ 6 (mod 8),(7n − 4)/32, if t ≡ 7 (mod 8),(7n − 20)/32, if t ≡ 11, 19 (mod 24),(7n + 16)/32, if t ≡ 12 (mod 24),(7n + 8)/32, if t ≡ 18 (mod 24),(7n + 20)/32, if t ≡ 21 (mod 24).

They also prove this upper bound is sharp if n ≡ 8 (mod 16). The remaining casesfor the problem of optimal conflict-avoiding code of even length n and weight 3 aredetermined by [1, 8]. The exact values of M(n) for n even now are completely given.However, known results for M(n) with n odd is far from being solved. Levenshtein [5]presented some M(n) where n ≤ 100 and n �= 31, 33, 43, 57, 73, 89, 93, and 99. Recently,[2] has completely found out M(n) with n odd and n < 500 and for certain class of primepowers n, M(n) is established. Some constructions of tight CACe of length n with n primeare obtained in [9,10], and studies of CAC(n, k) with k > 3 can be found in [11,13,14].

In this paper, we focus on the constructions of optimal tight equi-difference conflict-avoiding codes of length n = 2k ± 1 and weight 3 and we obtain the following conse-quences.

Theorem 1.1.

(1) Let n = 2k + 1 for k ≥ 2. Then there exists an optimal tight equi-difference codeC in CACe(n) with |C| = Me(n) = M(n) if and only if k ≡ 0 (mod 2).

(2) Let n = 2k − 1 for k ≥ 3. Then there exists an optimal tight equi-difference codeC in CACe(n) with |C| = Me(n) = M(n) if and only if k = 2t for t ≥ 2.

2. CONSTRUCTING OPTIMAL TIGHT EQUI-DIFFERENCE CODES

Throughout this paper, assume n to be an odd integer and Z∗n = Zn \ {0}. Given a positive

integer m with 1 ≤ m ≤ n−12 , a cycle C of length m, denoted m-cycle, is an m-tuple

(c1, c2, . . . , cm) of pairwise distinct elements c1, c2, . . . , cm in Z∗n and whose edges are

those connecting c1 with cm and ci with ci+1 for 1 ≤ i ≤ m − 1. An m-cycle is even ifm ≡ 0 (mod 2) or m = 1. That is, whenever we say that a cycle is odd, it always meansthat its length is greater than or equal to 3. Giving an m-cycle C = (c1, c2, . . . , cm), wewill use ∂C for the set of distinct elements ci(1 ≤ i ≤ m) in C and this cycle C is calleddoubling if for each i with 1 ≤ i ≤ m, ci+1 = min {2ci, n − 2ci}.

Given any odd integer n, let �n = {1, 2, . . . , n−12 } be a set of integers i with 1 ≤

i ≤ n−12 . By G(�n), we mean a graph G with vertex set V (G) = �n and edge set

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 4: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

226 WU AND FU

E(G) = {(x, y) : x, y ∈ �n, x �= y, y = min{2x, n − 2x}}. Since for each element x

with x ≡ 0 (resp. x ≡ 1) (mod 2) in �n, the edges (x, min{2x, n − 2x}), (x, x2 ) (resp.

(x, n−x2 )) are contained in G(�n), this implies that the degree of each vertex in G(�n)

is two, and we have the following consequence. It should be mentioned that the graphG(�n) has been used to find the set of equi-difference codewords in [2, 4–6].

Lemma 2.1. For any odd integer n, the graph G(�n) is a union of vertex-disjointmi-cycles (1 ≤ i ≤ k) satisfying that

∑ki=1 mi = n−1

2 .

Note that each mi-cycle in G(�n) is doubling. And if n = 3r for some integer r , thenthe graph G(�n) would contain just a 1-cycle (r), which corresponds to the exceptionalcodeword {0, r, 2r}. It is obvious that an exceptional codeword itself is also an equi-difference codeword. A doubling cycle C of G(�n) with 1 ∈ C is said to be base. In fact,it will be shown that the base cycle in G(�n) has the largest length in all cycles of G(�n).For any codeword X in C, it is easy to see that |�X| = 2, 4, or 6. Since an optimal codeof length n and weight 3 contains at most n − 1 differences and each codeword in it willprovide at least four differences except possibly for the exceptional codeword, we maymodify the inequality M(n) ≤ n+1

4 the following.

Lemma 2.2.

(1) Me(n) ≤ M(n) ≤ n−14 , if n �≡ 0 (mod 3).

(2) Me(n) ≤ M(n) ≤ n+14 , if n ≡ 0 (mod 3).

A matching M in a graph is a set of pairwise nonadjacent edges, i.e., no two edgesshare a common vertex. A perfect matching is a matching such that every vertex of thegraph is incident to exactly one edge of the matching. A path in a graph is a sequence ofedges (v1, v2), (v2, v3), . . . , (vm−1, vm). This path is from vertex v1 to vertex vm and haslength m − 1, denoted by P = [v1, v2, . . . , vm].

Proposition 2.3. If C is an even m-cycle with m > 1 in G(�n), then there is anequi-difference code C in CACe(n) with |C| = m

2 and �C = ±∂C.

Proof. Since C is even, there are two perfect matchings in C, and choose one perfectmatching M = {(a1, b1), (a2, b2), . . . , (am/2, bm/2)} arbitrarily. Since C is also doubling,we may assume that bi = 2ai or n − 2ai for 1 ≤ i ≤ m/2. For each edge (ai, bi) in M with1 ≤ i ≤ m/2, define a codeword Xi as Xi = {0, ai, 2ai} and set C = {Xi : 1 ≤ i ≤ m/2},where �Xi = ±{ai, bi}.

The proof then follows since each codeword Xi in C is equi-difference and �C =⋃m/2i=1 �Xi = ±∂C. �

Proposition 2.4. If C = (c1, c2, . . . , cm) is an odd m-cycle in G(�n), then there is anequi-difference code C in CACe(n) with |C| = m−1

2 and �C = ±(∂C \ {ci}) for some i

with 1 ≤ i ≤ m.

Proof. Removing any vertex ci and edges incident with it from C, we have an oddpath P = [ci+1, ci+2, . . . , ci−1] of length m − 2, and so there exists a perfect matchingM in P . The rest of the proof is analogous to that in Proposition 2.3 and we leave it tothe reader. �

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 5: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

OPTIMAL TIGHT EQUI-DIFFERENCE CONFLICT-AVOIDING CODES 227

Note that in Propositions 2.3 and 2.4, if G(�n) is just an m-cycle, then there exists anoptimal equi-difference code C in CACe(n) with |C| = Me(n) = M(n) = �m

2 �.Theorem 2.5. There exists an optimal tight equi-difference code C in CACe(n) with|C| = Me(n) = M(n) if and only if the graph G(n) contains no odd cycles.

By Lemma 2.1, G(�n) is a union of vertex-disjoint even mi-cycles Ci(1 ≤ i ≤ r),i.e., G(�n) = ⋃r

i=1 Ci . Since any cycles Ci, Cj (i �= j ) in G(�n) are pairwise disjoint,it follows that

⋃ri=1 ∂Ci = �n. Let C be the code obtained from the union of codes Ci

for 1 ≤ i ≤ r . The proof of Theorem 2.5 then follows by Propositions 2.3 and 2.4 andLemma 2.2. In fact, |C| = n−1

4 if n �≡ 0 (mod 3), and |C| = n+14 if n ≡ 0 (mod 3).

3. THE CONSTRUCTIONS OF DOUBLING CYCLES IN G(�n)

Let n be an odd integer (≥5). The order of 2 modulo n, denoted by o(n), is the leastpositive integer r for which 2r ≡ 1 (mod n). It is well known that o(n) divides φ(n) whereφ(n) is the Euler phi-function. Unless otherwise specified, throughout we shall assumeC = (2, 22, . . . , 2o(n)) (mod n) to be the base cycle on Z∗

n and tC = (2t, 22t, . . . , 2o(n)t)(mod n) to be the cycle obtained from C by multiplying each vertex in C by the elementt ∈ Z∗

n. Recall that in Lemma 2.1, the graph G(�n) is a union of disjoint mi-cycleswith

∑mi = n−1

2 . Hence, it is very important to confirm the odd/even length of eachdoubling cycle in G(�n). Moreover, despite the fact that Levenshtein and Tonchev [6]has mentioned that the graph G(�n) is a union of disjoint doubling cycles tiC for someelements ti ∈ Z∗

n, for the sake of the completeness and self-containedness of this paper, weshall entirely characterize the structure of cycles in G(�n). In fact, these consequencescan be utilized further to set up an optimal code CAC of length n with n any oddinteger.

The base cycle C plays a vital role for the constructions of doubling cycles in G(�n).Because we can use the base cycle C to establish all doubling cycles in G(�n), we shallrefer to the base cycle C as a member of G(�n). Similarly, the cycle tC is also viewed asa member of G(�n). To avoid the complicated notations, we will use (c1, c2, . . . , co(n))to denote a cycle where ci ∈ Z∗

n and <c1, c2, . . . , co(n)> to denote a doubling cycle inG(�n); it is always clear from the context.

Proposition 3.1. If C is a base doubling m-cycle of G(�n), then m = o(n)2 or o(n).

Proof. Since C is base and doubling, it means that 1 ∈ C and 2 ∈ C and so we mayassume

C = (2, 22, . . . , 2o(n)) (mod n), where 2o(n) ≡ 1 (mod n).

By virtue of the fact that 2o(n) ≡ 1 (mod n), it follows that if o(n) ≡ 0 (mod 2), then2o(n)/2 �≡ −1 (mod n) or 2o(n)/2 ≡ −1 (mod n).

If o(n) ≡ 1 (mod 2) or 2o(n)/2 �≡ −1 (mod n), then

C = (c1 = 2, c2, . . . , co(n) = 1), where 2i ≡ ci(mod n);C = <d1 = 2, d2, . . . , do(n) = 1>, where di = ci, if ci ≤ n−1

2 ,

and di = n − ci, if ci > n−12 .

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 6: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

228 WU AND FU

If 2o(n)/2 ≡ −1 (mod n), then

C = (c1 = 2, c2, . . . , co(n)/2 = −1, co(n)/2+1 = −2, . . . , co(n) = 1),where 2i ≡ ci(mod n);

C = <d1 = 2, d2, . . . , do(n)/2 = 1>, where di = ci, if ci ≤ n−12 ,

and di = n − ci, if ci > n−12 .

It is clear that the base doubling cycle C in G(�n) has length o(n)2 or o(n), as

desired. �

Suppose C = (c1, c2, . . . , cm) is an m-cycle where ci ∈ Z∗n. The λ-fold of C is the

multicycle Cλ

that is a union of λ copies of C, i.e., Cλ = (d1, d2, . . . , dλm) with djm+i = ci

for 0 ≤ j ≤ λ − 1 and 1 ≤ i ≤ m. We usually say that λ is the edge multiplicity of Cλ.

Given t ∈ Z∗n, by tC = (2t, 22t, . . . , 2o(n)t) (mod n), we mean a multicycle C

λwith

edge multiplicity λ (≥1). It is obvious that if λ = 1, then tC itself is a cycle, and if λ ≥ 2,

then this multicycle Cλ = (c1, c2, . . . , co(n)) where 2i t ≡ ci (mod n) for 1 ≤ i ≤ o(n)

corresponds to the cycle tC = (c1, c2, . . . , co(n)/λ). The cycle tC = (c1, c2, . . . , co(n)/λ)is said to be full if there does not exist ci, cj (i �= j ) in tC such that ci + cj = n, thatis, cj is the additive inverse of ci , and short, otherwise. For example, the cycle C inProposition 3.1 with length o(n) (resp. o(n)/2) is full (resp. short). Note that whether thecycle tC is full or short, by using the same method mentioned in Proposition 3.1, tC canbe transformed into a doubling cycle in G(�n).

Lemma 3.2. Let s, t be distinct elements in Z∗n.

(1) sC = C if and only if s ∈ C.

(2) sC = tC if and only if there exists an element 2j s in sC such that 2j s ≡ t (mod

n).(3) If s ∈ tC, then sC = tC.

(4) Either sC = tC or sC⋂

tC = ∅.

Proof. We just give the proofs of (1) and (4), and leave the rest to the reader.

(1) If sC = C, then there is an element 2j s with 1 ≤ j ≤ o(n) in sC satisfying that2j s = 2o(n) ≡ 1 (mod n), so s = 2o(n)−j ∈ C since gcd(2j , n) = 1. Conversely, ifs ∈ C, we may assume that s = 2i with 1 ≤ i ≤ o(n), and

sC = (2 · 2i , 22 · 2i , . . . , 2o(n) · 2i) (mod n)

= (2i+1, 2i+2, . . . , 2o(n), 2, . . . , 2i) (mod n)

= C.

(4) If sC⋂

tC �= ∅, we show that sC = tC. If x ∈ sC⋂

tC, let x ≡ 2j s ≡ 2kt (modn), where 2j s ∈ sC and 2kt ∈ tC. We may assume k < j . Since gcd(2k, n) = 1,2j−ks ≡ t (mod n) and it follows from (2) that sC = tC. �

Remark that each doubling cycle of G(�n) can be obtained from the base cycle C,which indicates that the length of the base doubling cycle is the largest in all doublingcycles of G(�n). And if sC �= tC, then sC and tC are disjoint by Lemma 3.2(3). In otherwords, distinct cycles in G(�n) are pairwise disjoint, and these distinct cycles are the

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 7: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

OPTIMAL TIGHT EQUI-DIFFERENCE CONFLICT-AVOIDING CODES 229

cells of a partition of �n. If w ∈ sC and for any t ∈ sC, w ≤ t , we can use wC as therepresentative of the cycle sC. Then for each element t ∈ �n, there is exactly one cycle,say wC, in G(�n) such that t ∈ wC. Note that if C is full, then wC may be full or short,but if C is short, then wC must be short.

Lemma 3.3. If the base cycle C is short, then for any t ∈ Z∗n, the cycle tC is also

short.

Proof. For any t ∈ �n, tC = (2t, 22t, . . . , 2o(n)t) (mod n), where 2o(n)/2t ≡ −t (mod

n) and 2o(n)t ≡ t (mod n) is a multicycle Cλ

since C is short. It is enough to consideronly the case where t ∈ �n since we can use (n − t)C instead of tC, if t > n−1

2 .If λ = 1, then tC is a short o(n)-cycle.

If λ ≥ 2, let Cλ = (c1, c2, . . . , co(n)) where 2i t ≡ ci (mod n) for 1 ≤ i ≤ o(n)

and cj ·o(n)/λ+k = ck for 0 ≤ j ≤ λ − 1 and 1 ≤ k ≤ o(n)/λ. There exists an inte-ger r such that r · o(n)/λ + 1 ≤ o(n)/2 < (r + 1) · o(n)/λ, and so we may assumetC = (cr·o(n)/λ+1, cr·o(n)/λ+2, . . . , c(r+1)·o(n)/λ). Since cr·o(n)/λ+1 = 2t , co(n)/2 ≡ −t (modn), and c(r+1)·o(n)/λ ≡ t (mod n), it would force that co(n)/2 = cw ≡ −t (mod n), wherew is the middle number between the integer interval [r · o(n)/λ + 1, (r + 1) · o(n)/λ].Therefore, we have tC is a short o(n)/λ-cycle. �

Proposition 3.4. Let tC be any doubling m-cycle of G(�n) for some t ∈ Z∗n. Then m

divides o(n).

Suppose the length of the base cycle C is o(n). The proof of Proposition 3.4 followsby virtue of Lemma 3.2.

Based on the above results, we further characterize the structure of the graph G(�n)in Lemma 2.1 as follows.

Theorem 3.5. Suppose siC for 1 ≤ i ≤ r are pairwise distinct doubling cycles with⋃ri=1 ∂siC = �n. Then G(�n) is the union of siC (1 ≤ i ≤ r).

4. OPTIMAL TIGHT EQUI-DIFFERENCE CACS OF LENGTH n = 2k ± 1AND WEIGHT 3

In this section, we concentrate ourselves on the constructions of optimal tight equi-difference codes C in CACe(n) with n = 2k ± 1.

Lemma 4.1.

(1) Suppose n = 2k + 1 for k ≥ 1. Then 2k ≡ −1 (mod n) and o(n) = 2k.

(2) Suppose n = 22q+1 + 1 for q ≥ 0. Then n ≡ 0 (mod 3).(3) Suppose n = 22q + 1 for q ≥ 1. Then n �≡ 0 (mod 3).

By Lemma 4.1 and Proposition 3.1, we have the following consequence.

Proposition 4.2. Suppose n = 2k + 1, where k ≥ 3 and k ≡ 1 (mod 2). Then thegraph G(�n) contains an odd k-cycle. In particular, it also contains a 1-cycle.

Theorem 4.3. Let n = 2k + 1 for k ≥ 3. Then there exists an optimal tight equi-difference code C in CACe(n) with |C| = Me(n) = M(n) if and only if k ≡ 0 (mod 2).

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 8: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

230 WU AND FU

Proof. By Proposition 4.2, it is enough to show the sufficient condition. Suppose tC

for t ∈ Z∗n is any m-cycle obtained from the base cycle C. By Lemma 4.1, C is short, and

by Lemma 3.3, tC is also short. Moreover, we have that m | o(n) = 2k by Proposition3.4.

Claim: m � k and m ≡ 0 (mod 4).Suppose, on the contrary, that m | k, say k = am for some positive integer a. Then

2k ≡ 1a = 1 (mod n), contradicting the fact that 2k ≡ −1 (mod n). Now, since k is even,if m is not a multiple of 4, then m | k, a contradiction.

By utilizing the fact that m ≡ 0 (mod 4), if tC is full (resp. short), then tC is an evendoubling m-cycle (resp. m/2-cycle) of G(�n). This means that all doubling cycles inG(�n) are even. Note that in this case, G(�n) contains no 1-cycle since n �≡ 0 (mod 3)by Lemma 4.1.

Now, by virtue of Theorem 2.5, there exists an optimal tight equi-difference code C inCACe(n) with |C| = Me(n) = M(n) = n−1

4 = 2k−2. �

Next, we investigate the second case where n = 2k − 1, and get the analogous resultslike Lemma 4.1.

Lemma 4.4.

(1) Suppose n = 2k − 1 for k ≥ 3. Then o(n) = k and 2o(n)/2 �≡ −1 (mod n) if k ≡ 0(mod 2).

(2) Suppose n = 22q+1 − 1 for q ≥ 1. Then n �≡ 0 (mod 3).(3) Suppose n = 22q − 1 for q ≥ 1. Then n ≡ 0 (mod 3).

Proposition 4.5. Suppose n = 2k − 1 (k ≥ 3), where k ≡ 1 (mod 2) or k ≡ 0 (mod

2) and k �= 2p for p ≥ 2. Then the graph G(�n) contains an odd cycle. In particular, ifk ≡ 0 (mod 2), it also contains a 1-cycle.

Proof. If k ≡ 1 (mod 2), by Lemma 4.4 and Proposition 3.1, we have that thebase doubling cycle in G(�n) is full with odd length k. If k ≡ 0 (mod 2) and k �= 2p

for p ≥ 2, we may assume that k = 2t q, where t ≥ 1 and q is odd with q ≥ 3, and son = 2k − 1 = 22t q − 1 = (2q − 1)w for some integer w.

Consider the multicycle wCk/q given as

wCk/q = (2w, 22w, . . . , 2qw, 2q+1w, . . . , 2kw) (mod n)

= (2w, 22w, . . . , w, 2w, . . . , w) (mod n)

= (c1, c2, . . . , ck) (mod n),

where ciq+j = 2jw and ciq+q = w for 1 ≤ j ≤ q − 1 and 0 ≤ i ≤ 2t − 1.Note that 2qw = (2q − 1 + 1)w ≡ w (mod n). Corresponding to the multicycle wCk/q ,

we have that there is an odd doubling q-cycle wC in G(�n). �

Theorem 4.6. Let n = 2k − 1 for k ≥ 3. Then there exists an optimal tight equi-difference code C in CACe(n) with |C| = Me(n) = M(n) if and only if k = 2p for p ≥ 2.

Proof. It suffices to prove the sufficient condition by Proposition 4.5. According toLemma 4.4, o(n) = k = 2p for p ≥ 2. It is clear that the length of each doubling m-cyclein G(�n) must be even, i.e., exactly one of 1, 2, and a multiple of 4 by Proposition 3.4,and in view of Theorem 2.5, the proof follows. �

Journal of Combinatorial Designs DOI 10.1002/jcd

Page 9: Optimal Tight Equi-Difference Conflict-Avoiding Codes of Length               n               = 2               k                              ± 1 and Weight 3

OPTIMAL TIGHT EQUI-DIFFERENCE CONFLICT-AVOIDING CODES 231

Remark. The construction of CAC of length n = 222p − 1 using a recursive methodcan be found in [9, 11].

Now, combining Theorem 4.3 with Theorem 4.6, we have the main consequences ofthis paper, i.e., Theorem 1.1.

ACKNOWLEDGMENTS

The authors would like to appreciate the referees for their useful comments, especially,one of the referees provides some techniques which simplify the proof of Theorem 4.3.

REFERENCES

[1] H. L. Fu, Y. H. Lin, and M. Mishima, Optimal conflict-avoiding codes of even length and weight3, IEEE Trans Inform Theory 56(11) (2010), 5747–5756.

[2] H. L. Fu, Y. H. Lo, and K. W. Shum, Optimal conflict-avoiding codes of odd length and weight3, Des Codes Cryptogr (2012), preprint.

[3] L. Gyorfi and I. Vajda, Constructions of protocol sequences for multiple access collision channelwithout feedback, IEEE Trans Inform Theory 39(5) (1993), 1762–1765.

[4] M. Jimbo, M. Mishima, S. Janiszewski, A. Y. Teymorian, and V. D. Tonchev, On conflict-avoiding codes of length n = 4m for three active users, IEEE Trans Inform Theory 53(8)(2007), 2732–2742.

[5] V. I. Levenshtein, Conflict-avoiding codes for three active users and cyclic triple systems, ProblInf Transm 43(3) (2007), 199–212.

[6] V. I. Levenshtein and V. D. Tonchev, Optimal conflict-avoiding codes for three active users,Proceedings of the IEEE International Symposium on Information Theory, Adelaide, Australia,4–9 September 2005, pp. 535–537.

[7] P. Mathys, A class of codes for a T active users out of N multiple-access communicationsystem, IEEE Trans Inform Theory 36(6) (1990), 1206–1219.

[8] M. Mishima, H. L. Fu, and S. Uruno, Optimal conflict-avoiding codes of length n ≡ 0 (mod16) and weight 3, Des Codes Cryptogr 52(3) (2009), 275–291.

[9] K. Momihara, Necessary and sufficient conditions for tight equi-difference conflict-avoidingcodes of weight three, Des Codes Cryptogr 45(3) (2007), 379–390.

[10] K. Momihara, On cyclic 2(k − 1)-support (n, k)k−1 difference families, Finite Fields Appl 15(2009), 415–427.

[11] K. Momihara, M. Muller, J. Satoh, and M. Jimbo, Constant weight conflict-avoiding codes,SIAM J Discrete Math 21(4) (2007), 959–979.

[12] Q. A. Nguyen, L. Gyorfi, and J. L. Massey, Constructions of binary constant-weight cycliccodes and cyclically permutable codes, IEEE Trans Inform Theory 38(3) (1992), 940–949.

[13] K. W. Shum and W. S. Wong, A tight asymptotic bound on the size of constant-weight conflict-avoiding codes, Des Codes Cryptogr 57(1) (2010), 1–14.

[14] K. W. Shum, W. S. Wong, and C. S. Chen, A general upper bound on the size of constant-weightconflict avoiding codes, IEEE Trans Inform Theory 56(7) (2010), 3265–3276.

[15] B. S. Tsybakov and A. R. Rubinov, Some constructions of conflict-avoiding codes, Probl InformTransm 38(4) (2002), 268–279.

Journal of Combinatorial Designs DOI 10.1002/jcd