Let $q = p^s$ and $r = q^m$, where $p$ is a prime, $s$ and $m$ are positive integers. Let $N>1$ be an integer dividing $r - 1$, and put $n = (r - 1)/N$.

Let $\alpha$ be a primitive element of $\mathbb{F}_r$, $\theta = \alpha^N$, and $Tr_{r/q}$ be the trace function from $\mathbb{F}_r$ to $\mathbb{F}_q$. The set

$$C(r,N) = \{ (Tr_{r/q}(\beta), Tr_{r/q} (\beta \theta),\dots, Tr_{r/q}(\beta \theta^{n-1})) : \beta \in \mathbb{F}_r\}$$

is an irreducible cyclice code of length $n$ over $\mathbb{F}_q$.

Let's define the set

$$Z(r,a) = \#\{x \in \mathbb{F}_r: \text{Tr}_{r/q}(x) = 0 \}.$$

The paper "The weight distribution of some irreducible cyclic codes" by Cunsheng Ding makes the following statement:

Hence, for any $\beta \in \mathbb{F}_r^*$ the Hamming weight of the codeword

$$c(\beta) = (Tr_{r/q}(\beta), Tr_{r/q} (\beta \theta),\dots, Tr_{r/q}(\beta \theta^{n-1}))$$

of the code $C(r,N)$ is equal to

$$n - \frac{Z(r, \beta) - 1}{N}.$$

Can anyone provide any proof for this statement?

  • $\begingroup$ That's surely $Z(r,a)$ isn't it? $\endgroup$
    – kodlu
    Mar 14, 2023 at 16:49
  • $\begingroup$ I meant $Z(r,a)=\{x:Tr(x)=a\}$ isn't it? $\endgroup$
    – kodlu
    Mar 14, 2023 at 17:04
  • $\begingroup$ did you see my answer? $\endgroup$
    – kodlu
    Mar 20, 2023 at 14:07

1 Answer 1


The codeword $c(\beta)$ in your question is defined on a set via the trace map that does not include the zero element. Thus its number of nonzero elements is simply the length minus the number of $k\in \{0,1,\ldots,n-1\}$ which give $Tr(\beta \theta^k)=0.$

From the equidistribution properties of the trace function and the fact that we are considering a subfield of index $N$ the number of zeroes of the trace function minus 1, in the extension field, needs to be divided by $N$ when projected into the subfield.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.