TRACE DESCRIPTION AND HAMMING WEIGHTS OF IRREDUCIBLE CONSTACYCLIC CODES

. Irreducible constacyclic codes constitute an important family of error-correcting codes and have applications in space communications. In this paper, we provide a trace description of irreducible constacyclic codes of length n over the ﬁnite ﬁeld F q of order q, where n is a positive integer and q is a prime power coprime to n. As an application, we determine Hamming weight distributions of some irreducible constacyclic codes of length n over F q . We also derive a weight-divisibility theorem for irreducible constacyclic codes, and obtain both lower and upper bounds on the non-zero Hamming weights in irreducible constacyclic codes. Besides illustrating our results with examples, we list some optimal irreducible constacyclic codes that attain the distance bounds given in Grassl’s Table [8].


Introduction
Irreducible constacyclic codes form an algebraically rich family of error-correcting codes, and can be easily encoded and decoded using linear shift registers. They are building blocks for all the constacyclic codes, which are generalizations of cyclic and negacyclic codes. Their error-performance relative to various communication channels is measured by their Hamming weight distributions. This motivated many authors to study Hamming weight distributions of irreducible constacyclic codes. However, Ding [5] pointed out that the problem of determination of Hamming weight distributions is notoriously difficult for irreducible cyclic codes, which form a special class of irreducible constacyclic codes. In fact, many authors have worked on this problem using various techniques and obtained weight distributions of irreducible cyclic codes in certain special cases ([1]- [3], [5,6,11,13,14,16], [18]- [22], [24]). On the other hand, extending the results derived in Sharma et al. [19,20], Grover and Bhandari [9] determined weight distributions of some irreducible constacyclic codes of length p n (n ≥ 1) over F q , where p is a prime and q is a prime power coprime to p. In another line of related work, Dong and Yin [7] provided a trace description of irreducible constacyclic codes over finite fields. As an application, they determined the weight distribution of a negacyclic code having a primitive polynomial as its check-polynomial. Therefore weight distributions of irreducible constacyclic codes are known only in a few cases.
In this paper, we provide a trace description for irreducible constacyclic codes over finite fields, which is different from the one given in [7]. With the help of this trace description, we further relate the problem of determination of weight distributions of irreducible constacyclic codes over finite fields with the evaluation of certain Gaussian periods. As a consequence, we determine weight distributions of irreducible constacyclic codes in certain special cases. We also derive a weightdivisibility theorem and obtain bounds on the Hamming weights of non-zero codewords in irreducible constacyclic codes.
This paper is organized as follows: In Section 2, we state some preliminaries. In Section 3, we provide a trace description of simple-root irreducible constacyclic codes over finite fields (Theorem 3.1). We also observe that in order to determine weight distributions of all the irreducible ξ i -constacyclic codes over F q , it is enough to determine the same for the non-degenerate irreducible ξ i -constacyclic code M (m,i) 1 of length m over F q for 0 ≤ i ≤ q − 2 (Theorem 3.2), where F q is the finite field of order q, ξ is a primitive element of F q and m is a positive integer with gcd(q, m) = 1. Furthermore, we relate the problem of determination of weight distribution of the irreducible constacyclic code M (m,i) 1 with the evaluation of Gaussian periods (Theorem 3.3) and determine weight distributions in certain special cases (Theorems 3.7-3.16). In Section 4, we derive a weight-divisibility theorem for irreducible constacyclic codes (Theorems 4.1) and obtain bounds on the non-zero Hamming weights in these codes (Theorem 4.3). In Section 5, we apply our results to determine the weight distribution of the code M (m,i) 1 over F q for some special values of q, m and i (Table 1). We also list some optimal irreducible constacyclic codes, which attain the distance bounds given in Grassl's Table [8] (Table 2).

Some preliminaries
Let F q denote the finite field with q elements. For a non-zero element λ ∈ F q , a λ-constacyclic code C of length n over F q is defined as an F q -linear subspace of F n q satisfying the following property: c = (c 0 , c 1 , · · · , c n−1 ) ∈ C implies that (λc n−1 , c 0 , c 1 , · · · , c n−2 ) ∈ C. Furthermore, under the standard vector space iso- x n − λ , one can identify each λ-constacyclic code C of length n over F q as an ideal of the quotient ring F q [x]/ x n − λ . As F q [x]/ x n − λ is also a principal ideal ring, there exists a unique monic polynomial g(x) ∈ C that generates the code C and is a factor of x n − λ in F q [x]. The zeros of g(x) are called zeros of C, while the zeros of x n −λ g(x) are called non-zeros of C. For each non-zero λ ∈ F q , minimal ideals of the quotient ring F q [x]/ x n − λ are called irreducible λ-constacyclic codes of length n over F q . Now we shall state some preliminaries that we need to determine weight distributions of simple-root irreducible constacyclic codes over finite fields.
Let q = p , where p is a prime and is a positive integer. Let N be a positive integer coprime to q and let k be the multiplicative order of q modulo N. Let r = q k and let us write r −1 = q k −1 = N L for some integer L ≥ 1. Then for 0 ≤ j ≤ L−1, the jth cyclotomic class of order L in F r is defined as C With cyclotomic classes of order L, there are associated certain character sums, which are called Gaussian periods and are defined as η where χ 1 is the canonical additive character of F r . Further, the period polynomial of order L, denoted by Ψ L,r (x), is defined as In the following lemma, we state some basic properties of Gaussian periods: is the (i, h)th cyclotomic number of order L and is defined as the number of elements in the set (C (L,r) i The Gaussian periods are further related to Gaussian sums, which are as discussed below: Let L be a positive divisor of r −1 and ψ be a multiplicative character of F r having order L. Then the Gaussian sum of order L is defined as where χ 1 is the canonical additive character of F r . For a non-trivial character ψ, we have (2) |G(ψ)| = r 1/2 .
Further for 0 ≤ j ≤ L − 1, the following relation is well-known: Henceforth we will follow the same notations as in Section 2.

Irreducible constacyclic codes and their (Hamming) weight distributions
Throughout this paper, let n be a positive integer coprime to q. Let ξ = θ r−1 q−1 be a primitive element of F q . Let 0 ≤ i ≤ q − 2 be a fixed integer and R n = F q [x]/ x n − ξ i be the ring of residue classes of polynomials in F q [x] modulo x n −ξ i . Then a ξ i -constacyclic code of length n over F q is an ideal of the principal ideal ring R n and an irreducible ξ i -constacyclic code of length n over F q is a minimal ideal of the ring R n . In order to describe irreducible ξ i -constacyclic codes of length n over F q more explicitly, we need to study q-cyclotomic cosets modulo N = n(q−1) gcd(i,q−1) . The q-cyclotomic coset modulo N containing an integer s is defined as the set C as the minimal polynomial of η s over F q for each s ∈ S N , where η is a primitive N th root of unity in some extension field of F q satisfying η n = ξ i (such an element η exists in F r ). From this, one can observe that x n − ξ i = s M s (x), where the product s runs over all s ∈ S N satisfying is ≡ i (mod q − 1). Then for each s ∈ S N satisfying is ≡ i (mod q − 1), the ideal generated by the polynomial x n −ξ i Ms(x) , being a minimal ideal in R n , is an irreducible ξ i -constacyclic code of length n over F q and is denoted by M are called codewords. Throughout this paper, we shall denote elements of R n by their representatives (in F q [x]) of degree less than n, and perform their addition and multiplication modulo x n − ξ i . We shall further identify elements of R n with n-tuples over F q , i.e., the element a 0 + a 1 x + a 2 x 2 + · · · + a n−1 x n−1 ∈ R n is identified with the n-tuple (a 0 , a 1 , a 2 , · · · , a n−1 ) ∈ F n q and vice versa. Under this identification, the Hamming weight of a codeword is defined as the number of its non-zero components. If A j (0 ≤ j ≤ n) denotes the number of codewords having Hamming weight j in a code of length n over F q , then the list A 0 , A 1 , A 2 , · · · , A n is called the (Hamming) weight distribution of the code. In order to determine weight distributions of irreducible constacyclic codes, we first provide a trace description of irreducible constacyclic codes in the following section.
3.1. Trace representation of irreducible constacyclic codes. In the following theorem, we first observe that all irreducible constacyclic codes over F q are finite fields. Moreover, we provide a trace description of all the irreducible constacyclic codes of length n over F q by establishing a one-one correspondence between codewords of an irreducible constacyclic code and elements of a certain finite field. 1 n T r q ks /q (γ) + T r q ks /q (γβ)x + · · · + T r q ks /q (γβ n−1 )x n−1 : γ ∈ F q ks , or equivalently, M (n,i) s = 1 n T r q ks /q (γ), T r q ks /q (γβ), · · · , T r q ks /q (γβ n−1 ) : γ ∈ F q ks , where T r q ks /q is the trace function from F q ks onto F q and β −1 is a non-zero of the code M  . It is clear that ϑ is a well-defined map and is a ring homomorphism. In order to show that ϑ is a bijection, we define another mapping ϕ : F q ks → M (n,i) s as (5) ϕ First of all, we will show that ϕ is a well-defined map. For this, we need to show that c γ (x) ∈ M (n,i) s for each γ ∈ F q ks . As {η j : j ∈ C , without any loss of generality, we can take is an nth root of unity over F q . From this, we see that . This shows that ϕ is a well-defined map. Further, it is easy to show that ϑ and ϕ are inverses of each other and that ϑ is an isomorphism. From this, it follows that M (n,i) s = 1 n T r q ks /q (γ) + T r q ks /q (γβ)x + · · · + T r q ks /q (γβ n−1 )x n−1 : γ ∈ F q ks , which completes the proof.
Remark 1. In particular, when i = 0, Theorem 3.1 provides a trace description of irreducible cyclic codes of length n over F q .

3.2.
Weight distributions of irreducible constacyclic codes. In this section, we observe that in order to determine weight distributions of all the irreducible ξ i -constacyclic codes of length n over F q , it is enough to determine the same for the irreducible ξ i -constacyclic code M (m,i) 1 corresponding to the q-cyclotomic coset modulo m(q−1) gcd(i,q−1) containing 1, where m runs over all the positive divisors of n. are permutation-equivalent, and hence have the same weight distribution.

is given by
Proof. Recall that the code M (n,i) s of length n over F q has the generator polynomial where η is a primitive N th root of unity over (a) To prove this, we first note that for each j ∈ C Further, it is easy to observe that the polynomial , which is given by To prove this, we see that as gcd(s, n) = 1 and is ≡ i (mod q − 1), we have gcd(s, N ) = 1. This implies that |C are isomorphic (as fields). Now if s −1 is the multiplicative inverse of s modulo N, then the map µ s −1 : R n → R n , defined as µ s −1 (c(x)) = c(x s −1 ) for every c(x) ∈ R n , is a ring automorphism. In order to show that µ s −1 is a weight-preserving isomorphism from M To illustrate the above theorem, we see that all the distinct negacyclic codes of length 10 over F 3 are given by M . As gcd(5, 10) = 2 > 1, by Theorem 3.2(a), we note that the weight distribution A 0 , A 1 , · · · , A 10 of the code M (10,1) 5 is given by It is easy to observe that B 0 = 1 and B 1 = B 2 = 4. From this, we obtain Further, as gcd(11, 10) = 1, we note, by Theorem 3.2(b), that the codes M In view of Theorem 3.2, we see that to determine weight distributions of all the irreducible constacyclic codes over F q , we need to determine the same for the irreducible constacyclic code M (m,i) 1 for each integer m ≥ 1.
. From now on, let m be a fixed positive integer coprime to q and r = q k , where k is the multiplicative order of q modulo . In this section, we shall relate the problem of determination of weight distribution of the irreducible constacyclic code M in terms of Gaussian periods of order L in the following theorem, whose proof comes after Lemmas 3.4 and 3.5. are given by . Then it is easy to observe that there exists an integer e satisfying gcd(e, r − 1) = 1 and θ emT = ξ i . Let us take = θ eT so that m = ξ i holds. From this, we see that is a primitive m(q−1) gcd(i,q−1) th root of unity over F q . Now by Theorem 3.1, we have where T r r/q is the trace function from F r onto F q . Next, for each γ ∈ F r , let Z(r, γ) be the number of solutions y ∈ F r of the trace equation T r r/q (γy eT ) = 0. In the following proposition, we relate the number Z(r, γ) with the Hamming weight of the corresponding codeword c γ = 1 m (T r r/q (γ), T r r/q (γ ), · · · , T r r/q (γ m−1 )) ∈ M (m,i) 1 . Lemma 3.4. For each γ ∈ F r , the Hamming weight of the codeword c γ = 1 m (T r r/q (γ), T r r/q (γ ), · · · , T r r/q (γ m−1 )) ∈ M (m,i) 1 is m r − Z(r, γ) r − 1 .
Proof. As = θ eT , we have c γ = 1 m (T r r/q (γ), T r r/q (γθ eT ), · · · , T r r/q (γθ eT (m−1) )). From this, it is clear that the Hamming weight of c γ is equal to m − h, where h equals the number of integers j (0 ≤ j ≤ m−1) satisfying T r r/q (γθ jeT ) = 0. In other words, h equals the number of solutions of the equation T r r/q (γy eT ) = 0 in the set {θ j : 0 ≤ j ≤ m−1}. Since y = 0 always satisfies T r r/q (γy eT ) = 0, the number of its non-zero solutions is Z(r, γ)−1. Next we observe that for all integers j and u, we have T r r/q (γθ (j+mu)eT ) = T r r/q (γθ jeT θ meT u ) = T r r/q (γθ jeT ξ iu ) = ξ iu T r r/q (γθ jeT ), as θ emT u = ξ iu ∈ F q . From this, it follows that T r r/q (γθ (j+mu)eT ) = 0 if and only if T r r/q (γθ jeT ) = 0. Thus if some θ j (0 ≤ j ≤ m − 1) is a solution of the equation T r r/q (γy eT ) = 0, then θ j+m , θ j+2m , · · · , θ j+( r−1 m −1)m are also its solutions. As This proves the lemma.
From the above lemma and using the fact that Z(r, 0) = r, we see that the , · · · , η (L,r) .
. As a consequence, if γ 1 , γ 2 ∈ C (L,r) j for some Proof. For proof, see Lemma 5 of Ding and Yang [6]. in certain special cases. For this, we need the following theorem, which generalizes Theorem 6 of Sharma et al. [21]. Theorem 3.6. Suppose that the integers α 1 , α 2 , · · · , α t are all the distinct zeros of the period polynomial Ψ L,r (x) with their algebraic multiplicities as a 1 , a 2 , · · · , a t , respectively. Then the weight distribution A 0 , A 1 , A 2 , · · · , A m of the irreducible ξ iconstacyclic code M (m,i) 1 over F q is given by otherwise.
(Note that the number of distinct non-zero weights of M in the semi-primitive case, i.e., when −1 ∈ p modulo L.  is given by

is given by
Proof. By Proposition 20 of Myerson [17], we see that when k /2b, p, (p b + 1)/L all are odd, Gaussian periods of order L are given by η

is given by
for some integer j, 1 ≤ j ≤ L; 0 otherwise, where A 0 = A λ+1 = B λ+1 = 0 and the integers P Proof. By Theorem 4.1 of Yang and Xia [25], for each integer t (1 ≤ t ≤ λ), we Using (3) and working in a similar way as in Theorem 11.7.9 of [4], we obtain η (L,r) j for 0 ≤ j ≤ L − 1. Now by applying Theorem 3.6, the desired result follows immediately.
We shall next consider some non-semiprimitive and non-quadratic cases, and determine the weight distribution of M is given by
In order to determine the weight distribution of the code M (m,i) 1 in the case when L = 5, let t, w, v, u be the integers satisfying the following Dickson's system: It is known [12] that there exist exactly four integral solutions (t, w, v, u) of the Dickson's system such that p does not divide t 2 − 125w 2 . Let us define a map σ : Z 4 → Z 4 as σ(t, w, v, u) = (t, −w, −u, v) for all (t, w, v, u) ∈ Z 4 . Note that σ is a non-singular Z-module homomorphism of order 4. Note that if (t 0 , w 0 , v 0 , u 0 ) is a solution of (8) such that p does not divide t 2 0 − 125w 2 0 , then σ i (t 0 , w 0 , v 0 , u 0 ) = (t i , w i , v i , u i ) (i = 1, 2, 3) are the remaining three integral solutions of (8) satisfying the property that p does not divide t 2 i −125w 2 i . In the following theorem, we consider the case L = 5 and determine the weight distribution of M is given by Proof. Here also, working in a similar way as in Theorems 3.11 and 3.12, one can show that k ≡ 0 (mod 5) in the case when p ≡ 1 (mod 5). Here by Theorem 1 of Hoshi [12], we see that the period polynomial Ψ 5.r (x) has five distinct zeros,  . Now by applying Theorem 3.6, we obtain the desired result.
Proof. Here also, working as above, one can observe that k ≡ 0 (mod 6) when p ≡ 1 (mod 6). Here by Proposition 3.2 of Gurak [10], we see that the period polynomial Ψ 6,r (x) has six distinct zeros, namely . Now by applying Theorem 3.6, the result follows.
(b) When p ≡ 3 (mod 8) and k ≡ 0 (mod 4), the weight distribution of the code M (m,i) 1 is given by where S k /2 and T k /2 are as defined by (11). is given by where P k /2 , Q k /2 , P k /4 , Q k /4 are as defined by (10).
Proof. Here also, working as above, we see that in the case p ≡ 1 (mod 8), we have k ≡ 0 (mod 8), which gives k ≡ 0 (mod 8). Now by using Proposition 3.3 of Gurak [10] and applying Theorem 3.6, the result follows.  is given by for some integer j, 1 ≤ j ≤ 12; 0 otherwise.