On the Hamming Distance of Repeated-Root Cyclic Codes of Length 6ps

Let <inline-formula> <tex-math notation="LaTeX">$p$ </tex-math></inline-formula> be an odd prime, <inline-formula> <tex-math notation="LaTeX">$s$ </tex-math></inline-formula>, <inline-formula> <tex-math notation="LaTeX">$m$ </tex-math></inline-formula> be positive integers such that <inline-formula> <tex-math notation="LaTeX">$p^{m}\equiv 2 \pmod 3$ </tex-math></inline-formula>. In this paper, using the relationship about Hamming distances between simple-root cyclic codes and repeated-root cyclic codes, the Hamming distance of all cyclic codes of length <inline-formula> <tex-math notation="LaTeX">$6p^{s}$ </tex-math></inline-formula> over finite field <inline-formula> <tex-math notation="LaTeX">$\mathbb F_{p^{m}}$ </tex-math></inline-formula> is obtained. All maximum distance separable (MDS) cyclic codes of length <inline-formula> <tex-math notation="LaTeX">$6p^{s}$ </tex-math></inline-formula> are established.


I. INTRODUCTION
Cyclic codes over finite fields have been well studied since the late 1950s because of their rich algebraic structures and practical implementations. Many well known codes, such as BCH, Kerdock, Golay, Reed-Muller, Preparata, Justesen, and binary Hamming codes, are either cyclic codes or constructed from cyclic codes. All of those explain their preferred role in engineering.
Let F p m be a finite field. Cyclic codes of length n over F p m are classified as the ideals g(x) of the quotient ring F p m [x]/ x n − 1 , where the generator polynomial g(x) is the unique monic polynomial of minimum degree in the code, which is a divisor of x n − 1. In general, cyclic codes are grouped into two classes: simple-root cyclic codes, where the generator polynomial g(x) has no repeated irreducible factors; and repeated-root cyclic codes, where the generator polynomial g(x) has repeated roots. Repeated-root cyclic codes were first initiated in the most generality by Castagnoli et al. in [1] and Van Lint in [21], where it was proved that they are asymptotically bad, nevertheless, it turns out that optimal repeated-root cyclic codes still exist, which have motivated the researchers to further study these codes (see, for example, [14], [20].) The classification of codes plays an important role in studying their structures, but in general, it is very difficult. In a series of paper [4]- [8], Dinh determined the algebraic structure in terms of polynomial generators of all cyclic codes The associate editor coordinating the review of this manuscript and approving it for publication was Xueqin Jiang . over finite field F p m of length p s , 2p s , 3p s , 4p s and 6p s . Since then, these results have been extended to more general code lengths (see, for example, [2], [3], [11], [19].) However, litter work has been done on determining the Hamming distance of cyclic codes as it is a very hard task in general. By now, only a few results have been obtained. In [4], Dinh determined the Hamming distance of cyclic codes of length p s over F p m . Later, in [16] the authors computed the Hamming distance of cyclic codes of length 2p s by using the result of [1]. Recently, based on the relationship of Hamming distances between simple-root cyclic codes and repeated-root cyclic codes, the Hamming distance of cyclic codes of length 3p s were determined for the case gcd (3, p m − 1) = 1 in [11]. Motivated by these, in this paper, we get all Hamming distance of cyclic codes of length 6p s over the finite field F p m for the case p m ≡ 2 (mod 3). As an application, all such MDS cyclic codes of length 6p s are obtained, which can be used to construct quantum MDS codes using well known constructions such as CSS construction.
The remainder of this paper is organized as follows. Section 2 recalls some preliminary results. In Section 3, the Hamming distance of cyclic codes of length 6p s are given for the case p m ≡ 2 (mod 3). Using that, Section 4 identifies all MDS codes among such cyclic codes. Section 5 concludes the paper.

II. PRELIMINARIES
Let F p m be the finite field of order p m . A code C of length n over F p m is a nonempty subset of F n p m . A linear code C over the finite field F p m is a linear subspace of F n p m . In addition, a linear code C of length n, dimension k and minimum Hamming distance d H over F p m is often called a [n, k, d H ] code. A linear code C of length n over F p m is called cyclic code if (c n−1 , c 0 , c 1 , · · · , c n−2 ) ∈ C for every (c 0 , c 1 , · · · , c n−1 ) ∈ C. It is well-known that any cyclic code C of length n over F p m corresponds to an ideal of F p m [x]/ x n − 1 and it can be expressed as C = g(x) , where g(x) is monic and has the least degree in the code.
For a codeword a = (c 0 , c 1 , · · · , c n−1 ) ∈ C, the Hamming weight of x is the number of nonzero components c i for 0 ≤ i ≤ n − 1. Clearly, for a linear code C, the smallest Hamming weight and the Hamming distance d H (C) are the same, i.e., From that, we can get the following simple lemma. Lemma 2.1: Let C be a nonzero cyclic code and C = F p m [x]/ x n − 1 . Then d H (C) ≥ 2. Let C = g(x) be a cyclic code of length ηp s over F p m , where η is a positive integer such that gcd(η, p) = 1 and s is a positive integer. Suppose of multiplicity e i . LetC z = ḡ(x) be a simple-root cyclic code of length η over F p m , whereḡ z (x) is defined as the product of those irreducible factors m i (x) of g(x) that occur with times z < e i in g(x) (If z ≥ e i for i = 1, 2, · · · , t, thenḡ z (x) = 1.) Then we have the following result.
where c is a nonzero element in F p m . Obviously, for any positive integer s and 0 Then, combining with Theorem 7.5 of [12], we have the following result, which is the key lemma for us to determine the Hamming distance of cyclic codes of length 6 p s over F p m for the case p m ≡ 2 (mod 3).

III. HAMMING DISTANCE OF REPEATED-ROOT CYCLIC CODES OF LENGTH 6P S OVER F p m
In this section, we aim to determine the Hamming distance of all cyclic codes of length 6 p s over F p m for the case p m ≡ 2 (mod 3). From [8], we have that when p m ≡ 2 (mod 3), all cyclic codes of length 6p s have the form Let e z,t = 1 if t > z, otherwise, e z,t = 0, where t = i, j, u, v and min{i, j, u, v} ≤ z ≤ p s − 1. Then the generator polynomial of simple-root cyclic codeC z can be expressed as whereC z is defined in Proposition 2.2.
We start with the following proposition.
Proof: There are 4 possibilities.
In this case, clearly,C z = 1 . Then d H (C z ) = 1. VOLUME 8, 2020 By the Division Algorithm, we can assume l < 6. Let ζ be a 6th root of unity, then ζ and ζ 2 are solutions of x 4 + x 2 + 1 = 0. It follows that ζ and ζ 2 are solutions of x l − a, i.e., ζ l = 1, which is contradict to l < 6. So, Obviously, the elements ofC z are precisely r( Combining all the cases, the result follows.
We here state the Hamming distance of C for the case v = 0.
Proof: By Proposition 2.2 and Proposition 3.1, we have So, d H (C) = 1, 2, 3, 4, 5 or 6. Thus, we only need to find out what values of i, j, u such that d H (C) = 1, 2 3, 4 or 5 (the remaining values of i, j, u will give d H (C) = 6.) We consider 2 cases. Case 1: z = 0. In this case, by Proposition 3.1, we have and wt H ((x 6 − 1) 0 ) · d H (C 0 ) = 6 for the other values of i, j, u.
Proof: There are 4 possibilities.
In this case, we get d H (C z ) = 1. By Lemma 2.4, we have wt H (( In this case, we get d H (C z ) = 2. By Lemma 2.4, we have wt H (( In this case, we get d H (C z ) = 6. By Lemma 2.4, we have wt H (( By similar arguments as Lemma 3.2, we obtain the following lemmas immediately. Then Then d H (C) = min{3(β 2 + 2)p τ 2 , 6(β 3 + 2)p τ 3 }. Lemma 3.6: Let i = j = u = p s , u be an integer such that Then d H (C) = 6(β 3 + 2)p τ 3 . Now, we summarize the Hamming distance d H (C) for the case 0 ≤ v ≤ u ≤ j ≤ i ≤ p s as follows.

Remark 3.8: Using the above technique, it is easy to check that the corresponding cases
Example 3.9: Let p = 5, s = i = j = 1 and u = v = 0, then C is an [30, 26, 3] code by Theorem 3.7, which is optimal respect to the tables of best codes known maintained at http://www.codetables.de.

Case
Using the similar way as we show the Proof: There are 4 possibilities.
Combining all the cases, the result follows. We now state the Hamming distance of C for the case 0 Proof: By Proposition 2.1 and Proposition 3.10, we have and wt H (( and wt H (( (4) and (5), the result follows.
In the following, we consider the Hamming distance of C for the case Then Proof: By similar arguments as Lemma 3.2, it is easy for us to get d H As v ≥ i, one can verify that τ 1 > τ 2 , or τ 1 = τ 2 and β 1 ≥ β 2 . This means that 2(β 1 Using the same arguments as Lemma 3.2 and Lemma 3.3, we can get the Hamming distance of C for the case 0 < j ≤ i ≤ v ≤ u ≤ p s . We here omit the proof. The Hamming distance of C for the case 0 ≤ j ≤ i ≤ v ≤ u ≤ p s is shown as follows.
Theorem 3.13: Remark 3.14: Using the above technique, it is easy to check that the corresponding cases Example 3.15: Let p = 5, j = 0, s = i = v = 1 and u = 3, then C is an [30, 24, 4] code by Theorem 3.13, which is almost optimal respect to the tables of best codes known maintained at http://www.codetables.de.

Case 3:
Using the similar way as we show the Hamming distance of C for the case 0 ≤ v ≤ u ≤ j ≤ i ≤ p s , we first determine the Hamming distance ofC z for the case 0 Proof: There are 4 possibilities.
In this case, we have, Combining all the cases, the result follows. We here state the Hamming distance of C for the case v = 0. Lemma 3.17: Let v = 0 and 0 ≤ j ≤ u ≤ i ≤ p s . Then, and wt H ((x 6 − 1) 0 ) · d H (C 0 ) = 6 for the other values of i, j, u.
By the similar arguments as we determine the Hamming distance of C for the case 0 ≤ v ≤ u ≤ j ≤ i ≤ p s . Combining with Proposition 3.16 and Lemma 3.17, we show the Hamming distance of C for the case 0 ≤ v ≤ j ≤ u ≤ i ≤ p s , immediately.

Remark 3.19: Using the above technique, it is easy to check that the corresponding cases
Example 3.20: Let p = 5, v = 0, s = u = j = 1 and i = 3, then C is an [30, 19,5] code by Theorem 3.18.

Case 4:
Using the similar way as we show the Hamming distance of C for the case 0 ≤ v ≤ u ≤ j ≤ i ≤ p s , we first determine the Hamming distance ofC z for the case Proof: There are 4 possibilities.
In this case, clearly,C z = 1 .
In this case, we have, C z = (x 2 + x + 1)(x + 1) . Let c(x) be an arbitrary nonzero codeword inC z , then we consider the following 4 cases.
Obviously, at most one of a + 2c and 2a + c is zero. Hence, wt H (c(x)) ≥ 5. Combining all the cases, the result follows. We now compute the Hamming distance of C for the case j = 0.
Similar to the process as we compute the Hamming distance of C for the case 0 ≤ v ≤ u ≤ j ≤ i ≤ p s and 0 ≤ j ≤ i ≤ v ≤ u ≤ p s , combining with Proposition 3.21 and Lemma 3.22, we here summarize the Hamming distance d H (C) for the case 0

Remark 3.24: Using the above technique, it is easy to check that the corresponding cases
Example 3.25: Let p = 5, j = u = 0, s = v = 1 and i = 2, then C is an [30, 25, 3] code by Theorem 3.23, which is almost optimal respect to the tables of best codes known maintained at http://www.codetables.de.
3.5. Case 5: and Proposition 3.21, we get the following proposition, immediately.
Proposition 3.26: We now compute the Hamming distance of C for the case u = 0. Lemma 3.27: Let u = 0 and 0 ≤ j ≤ v ≤ i ≤ p s be integers. Then, Proof: By Proposition 2.2 and Proposition 3.26, we have So, d H (C) = 1, 2, 3, 4, 5 or 6. Thus, we only need to find out what values of i, j, v such that d H (C) = 1, 2 3, 4 or 5 (the remaining values of i, j, v will give d H (C) = 6.) This means that we only need to find out values of 0 ≤ z ≤ p s − 1 such that wt H ((x 6 − 1) z ) · d H (C z ) < 6. We consider 2 cases. 39954 VOLUME 8, 2020 Case 1: z = 0. In this case, by Proposition 3.26, we have and wt H ((x 6 − 1) 0 ) · d H (C 0 ) = 6 for the other values of i, j, v. and where t = 2, 3, 4, 5.
and wt H ((x 6 − 1) z ) · d H (C z ) ≥ 6 for the other values of i, j, v.
Using a similar way as we compute the Hamming distance of C for the case 0 ≤ v ≤ u ≤ j ≤ i ≤ p s and 0 ≤ j ≤ i ≤ v ≤ u ≤ p s , combining with Proposition 3.22 and Lemma 3.23, we here summarize the Hamming distance d H (C) for the case Theorem 3.28: Let 0 ≤ β 0 , β 1 , β 2 , β 3 ≤ p − 2, and Example 3.30: Let p = 5, j = u = 0, s = v = 1 and i = 3, then C is an [30,23,4] code by Theorem 3.28, which is almost optimal respect to the tables of best codes known maintained at http://www.codetables.de.

IV. MDS CYCLIC CODES OF LENGTH 6P S OVER F p m
It is well known that constructing MDS codes is one of the central topics in coding theory. In this section, we use the determination of the Hamming distance of cyclic codes in Section 3, under the same hypothesis, p m ≡ 2 (mod 3), to identify all MDS cyclic codes of length 6p s . We start with Then the code C is an MDS code if and only if one of the following conditions holds: The Hamming distance of C has been given in Theorem 3.7, then we can consider the conditions for the equations hold from the following 11 cases. In these cases, we always assume that 0 ≤ β 0 , β 1 , β 2 , β 3 ≤ p − 2, and 0 ≤ τ 3 ≤ τ 2 ≤ τ 1 ≤ τ 0 ≤ s − 1.
Then d sp (C) = 6(β 3 + 2)p τ 3 , and Therefore, 2i + 2j + u + v ≥ 6(β 3 + 2)p τ 3 − 1 with equality when p = β 3 + 2 and Using the same technique as above, combining with the Hamming distance of cyclic codes of length 6 p s given in Section 3, we can determine the sufficient and necessary conditions for such codes to be MDS codes.
Here, we show the main steps for the proof and omit the details. Without losing the generality, we use the code C for 0 ≤ j ≤ i ≤ v ≤ u ≤ p s as an example.
Proposition 4.2: Procedure to obtain MDS codes among cyclic codes of length 6 p s of the form C for 0 ≤ j ≤ i ≤ v ≤ u ≤ p s .
Step 1. Using the same way as Theorem 4.1, by definition, one can verify that C is an MDS code if and only if 2i + 2j + u + v = d H (C) − 1.
Step 3. For the non-trivial cases, we always let τ i = s − 1 and β j = p − 2 in the proof, where 0 ≤ i, j ≤ 3. The details for the proof are similar to Case 7, Case 8, Case 9 and Case 10 of Theorem 4.1. Then, we can get that there is no MDS code. From above, the degrees of generator polynomials of all MDS cyclic codes of length 6 p s over F p m can be shown as follows.

V. CONCLUSION
In this paper, based on the relationship of the Hamming distances between simple-root cyclic codes and repeated-root cyclic codes, the Hamming distance of cyclic codes of length 6p s are obtained for the case p m ≡ 2 (mod 3). Moreover, we determine all MDS cyclic codes of length 6p s for the case p m ≡ 2 (mod 3). When p m ≡ 1 (mod 3), from [8], we know that all cyclic codes of length 6p s have the form where 0 ≤ i 1 , i 2 , i 3 , i 4 , i 5 , i 6 ≤ p s and ξ ∈ F p m is a primitive (p m − 1)th root of unity. Our computation technique here can be used to determine the Hamming distances of all such cyclic codes. His research interests include algebra and coding theory. He has also been a well-known invited/keynote speaker at numerous international conferences and mathematics colloquium. Other than universities in the USA, he also gave many honorary tutorial lectures at international universities in China, Indonesia, Kuwait, Mexico, Singapore, Thailand, and Vietnam.
XIAOQIANG WANG received the Ph.D. degree from the School of Mathematics and Statistics, Central China Normal University, China, in 2019. His Ph.D. was on algebraic techniques of encoding/decoding cyclic codes over finite fields and rings. Since 2019, he has been a Postdoctoral Researcher with the Faculty of Mathematics and Statistics, Hubei University, China. His research interests include algebra and coding theory. He has published ten articles in high-ranked peer review journals, such as Designs, Codes and Cryptography, Discrete Mathematics, and Finite Fields and Their Applications.
PARAVEE MANEEJUK has been working as a Lecturer with the Faculty of Economics, Chiang Mai University, Thailand, since 2018. Her research interests include information theory, economic development, growth, and applied econometrics. She has also worked with a research team from the Centre of Excellence in Econometrics, and has published about 50 articles in SCOPUS/ISI. She is currently working with the research team in applying the econometric models to solve several economic issues.