Introduction
Restrictions on the weights of a linear code can force strong algebraic and geometric structure. This principle is particularly visible for codes with only a few nonzero weights. In the Hamming metric, two-weight codes connect coding theory with point sets having two hyperplane intersection numbers and with strongly regular graphs; see the survey of Calderbank and Kantor [5 ] . Divisibility of weights provides another source of structural constraints, with a substantial theory of its own [20 ] . These connections motivate the study of how much of a code’s structure can be recovered from its weight spectrum and the arithmetic relations among its weights.
The rank metric offers a natural setting for this problem. Here the weight of a vector over a finite extension field is the dimension, over the base field, of the space generated by its coordinates. The foundational work of Delsarte and Gabidulin [9 , 10 ] established an algebraic theory of codes for this metric, which also plays a central role in error control for random network coding [18 ] . Since rank weight measures linear dependence over a chosen base field, restrictions on rank weights are closely connected with the interaction between different field structures.
Finite geometry makes this connection explicit. A linear code in the rank metric can be represented by a vector subspace over the base field, and codeword weights are determined by its intersections with hyperplanes [16 , 2 ] . The associated projective point sets are called linear sets ; their point weights record the dimensions of the intersections with the corresponding one-dimensional subspaces. Linear sets have been extensively studied in finite geometry [13 ] , and their duality theory provides a bridge between geometric intersection properties and rank-weight distributions [17 , 3 ] .
This geometric approach has been particularly effective for codes with few weights. Constant-weight rank-metric codes were classified in [16 ] , and two-weight rank-metric codes were described through scattered subspaces in [22 ] . Three-weight families associated with clubs were studied in [11 ] (see [19 , 21 ] for some extensions). These results suggest investigating which features of such descriptions persist when the entire weight spectrum is restricted, without prescribing a particular geometric configuration.
A central issue is whether divisibility of weights reveals an underlying structure over a larger field. Field expansion gives a natural source of divisible rank-metric codes: expanding a code from a larger base field multiplies all rank weights by the degree of the field extension. The converse is more delicate. In [14 ] the authors identified cases in which divisibility does imply such an origin, but also constructed counterexamples. Thus numerical divisibility alone does not determine the field structure. The problem is to find additional conditions, expressed in terms of the weight spectrum and the code parameters, that make this implication valid.
In this paper we approach this problem through linear sets with restricted point weights. If the defining subspace is linear over a larger subfield, then every point weight is divisible by the degree of that subfield over the base field. We investigate when the converse holds and, when it does not hold directly, how far the defining subspace is from one with a larger field of linearity. This distinction is essential: a point set may admit a representation over a larger field even when its original defining subspace is not linear over that field.
Our first main result quantifies this distinction. Let U U U be an F q \mathbb{F}_q F q -subspace of rank N N N defining a linear set L U L_U L U that spans P G ( h − 1 , q m ) \mathrm{PG}(h-1,q^m) PG ( h − 1 , q m ) , with h ≥ 2 h \ge2 h ≥ 2 , and U U U is a proper subset of that space. Assume that q ≥ m q \ge m q ≥ m and that the minimum positive point weight is a ≥ 2 a \ge2 a ≥ 2 . Building on the theorem of Csajbók, Marino and Pepe [6 ] , we show that there is a divisor t t t of m m m such that W = ⟨ U ⟩ F q t W = \langle U\rangle_{\mathbb{F}_{q^t}} W = ⟨ U ⟩ F q t defines the same point set, L W L_W L W admits a point of weight one over F q t \mathbb{F}_{q^t} F q t and
dim F q W = N + t − a . \dim_{\mathbb{F}_q} W = N + t - a. dim F q W = N + t − a .
Moreover, a ≤ t ≤ N − a a \le t \le N-a a ≤ t ≤ N − a (Theorem 3.7 ). The exact dimension follows by comparing an elementary counting bound with the lower bound of Adriaensen and Santonastaso [1 ] for linear sets containing a point of weight one; see also [7 ] .
This dimension formula yields a structural criterion. Let e e e be the greatest common divisor of the positive point weights. An elementary counting argument gives e ∣ N e \mid N e ∣ N . Under the preceding assumptions, if m m m has no divisor in the interval ( e , N − e ] (e,N-e] ( e , N − e ] , then t = a = e t=a=e t = a = e and W = U W=U W = U (Theorem 3.9 ). Consequently, the original subspace is F q e \mathbb{F}_{q^e} F q e -linear, and its minimum positive point weight equals the gcd of all its point weights. The arithmetic restriction therefore identifies the larger field and rules out the need to enlarge the defining subspace.
The first application concerns two-dimensional codes of length n n n with a codeword of weight n n n . The hyperplanes of P G ( 1 , q m ) \mathrm{PG}(1,q^m) PG ( 1 , q m ) are points, so by (5) the positive point weights of an associated system U U U are the differences n − d i n-d_i n − d i between the length and the nonzero weights d i < n d_i<n d i < n of the code, and the minimum one is the gap a = n − d r a=n-d_r a = n − d r between the two largest weights. A nontrivial F q \mathbb{F}_q F q -expansion of such a code always has a ≥ 2 a \ge2 a ≥ 2 . Conversely, if q ≥ m q \ge m q ≥ m and a ≥ 2 a \ge2 a ≥ 2 , applying Theorem 3.7 to U U U shows that the code is obtained by deleting t − a t-a t − a coordinates from the F q \mathbb{F}_q F q -expansion of a [ d r t + 1 , 2 ] q m / q t [\frac{d_r}{t}+1,2]_{q^m/q^t} [ t d r + 1 , 2 ] q m / q t code, for some divisor t t t of m m m with a ≤ t ≤ min { d r , m − d r } a \le t \le\min\{d_r,m-d_r\} a ≤ t ≤ min { d r , m − d r } . and t ∣ d r t \mid d_r t ∣ d r ; a codeword of rank w w w arises from a codeword of rank t ⌈ w / t ⌉ t\lceil w/t\rceil t ⌈ w / t ⌉ (Theorem 4.1 ). This gives congruence restrictions on the weights, the inequality d 1 + d r ≥ n d_1+d_r\ge n d 1 + d r ≥ n and, for three-weight codes with t > a t>a t > a , an explicit weight distribution (Corollary 4.3). We complement these results with several families of three-weight [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q codes, which exist for every prime power q q q . They show that, when a = 1 a=1 a = 1 , no arithmetic restriction survives, even if the gap between the two smallest weights is large, and that the case t > a t>a t > a really occurs: Family F 4 \mathcal{F}_4 F 4 provides codes whose first gap t − 1 t-1 t − 1 can be as large as m / 2 − 1 m/2-1 m /2 − 1 and which are not expansions from any larger field. This is in sharp contrast with the two-weight case, in which q ≥ m q\ge m q ≥ m and a ≥ 2 a\ge2 a ≥ 2 force the code itself to be an expansion (Theorem 6.4 ).
For rank-metric codes of larger dimension, the link with these results is provided by geometric duality: the positive point weights of the dual of an associated system are precisely the deficiencies m − w m-w m − w of the codeword ranks w < m w<m w < m . For a nondegenerate code of length at least m m m , a useful dichotomy is determined by the subcode generated by its codewords of rank smaller than m m m . If this subcode contains no codeword of rank m m m , we characterize the original code, up to equivalence, as the direct sum of a simplex code and a code of length smaller than m m m (Theorem 5.2 and Corollary 5.4). This reduces the determination of its weight spectrum to the study of the weights of a shorter code.
In the complementary case, that is when the subcode generated by its codewords of rank smaller than m m m contains a codeword of rank m m m , assume q ≥ m q\ge m q ≥ m and let a ≥ 2 a\ge2 a ≥ 2 be the difference between m m m and the largest nonmaximum rank weight. We prove that, after a rank-metric equivalence, deleting t − a t-a t − a suitable coordinates yields the F q \mathbb{F}_q F q -expansion of a code whose rank is measured over F q t \mathbb{F}_{q^t} F q t , for some divisor t t t of m m m . The effect on every codeword is explicit: a word of rank w w w becomes a word of rank t ⌊ w / t ⌋ t\lfloor w/t\rfloor t ⌊ w / t ⌋ (Theorem 5.6 ). This gives both congruence restrictions on the original weight spectrum and the weight distribution after puncturing. Under the corresponding divisor-gap condition, no coordinates need to be deleted, and the original code itself arises by field expansion.
We apply these results to codes with two or three nonzero weights. The two-weight case admits stronger conclusions: in the field-size range q ≥ m q\ge m q ≥ m , the relevant field-expansion results require no divisor-gap assumption, with the direct-sum case treated separately. A further simplification occurs when m m m divides the code length: the expansion theorem then holds without a divisor-gap condition or a restriction on q q q (Theorem 5.13 ). In § 6 we apply these results to codes with two or three nonzero weights. For two-weight codes no divisor-gap condition is needed: when q ≥ m q\ge m q ≥ m , a linear set whose points all have the same weight a ≥ 2 a\ge2 a ≥ 2 is forced to be F q a \mathbb{F}_{q^a} F q a -linear (Lemma 6.2 ). If the length is at least m m m , then either h ( C ) = 1 h(\mathcal{C})=1 h ( C ) = 1 and C \mathcal{C} C is the direct sum of a simplex code and a one-dimensional code, or h ( C ) ≥ 2 h(\mathcal{C})\ge2 h ( C ) ≥ 2 and, when q ≥ m q\ge m q ≥ m or m m m divides the length, C \mathcal{C} C is the F q a \mathbb{F}_{q^a} F q a -expansion of a code over F q a \mathbb{F}_{q^a} F q a , where a a a is the difference between the two weights (Theorem 6.3 ). If the length is at most m m m , the code is two-dimensional and, when q ≥ m q\ge m q ≥ m or the length equals m m m , it is again an expansion (Theorem 6.4 ). This recovers the results of [22 ] , shows that the description given there for length larger than m m m requires the additional assumption h ( C ) ≥ 2 h(\mathcal{C})\ge2 h ( C ) ≥ 2 , and removes the restriction on q q q when m m m divides the length. For three-weight codes of length at least m m m , the direct-sum case reduces to two-weight codes of length smaller than m m m , and its weight distribution is determined by the parameters (Theorem 6.6 ); in the remaining case we obtain the puncturing and rigidity statements described above (Theorem 6.7 ). Together with the families of § 4 , these results show that three-weight codes are much less rigid than two-weight codes. Our results thus identify parameter regimes in which the question raised in [14 ] , namely whether an e e e -divisible code arises from a code over F q e \mathbb{F}_{q^e} F q e , has a positive answer, under hypotheses stated directly in terms of the weight spectrum and the divisors of m m m .
Organization. § 2 collects the preliminaries on linear sets, rank-metric codes, q q q -systems and field expansion. In § 3 we prove Theorems 3.7 and 3.9 on the fields of linearity of linear sets with restricted point weights. § 4 deals with two-dimensional codes of length at most m m m and contains several families of three-weight examples. Section 5 translates the results of Section 3 to rank-metric codes, distinguishing between direct sums of a simplex code and a short code (Section 5.1) and the remaining codes (Section 5.2). Finally, Section 6 collects the results on codes with two or three nonzero weights.
Preliminaries
Throughout the paper, q q q is a prime power, m m m and k k k are positive integers, and V V V is a k k k -dimensional vector space over F q m \mathbb{F}_{q^m} F q m . We identify points of PG ( V , F q m ) = PG ( k − 1 , q m ) \operatorname{PG}(V,\mathbb{F}_{q^m}) = \operatorname{PG}(k-1,q^m) PG ( V , F q m ) = PG ( k − 1 , q m ) with one-dimensional F q m \mathbb{F}_{q^m} F q m -subspaces of V V V .
Linear sets
We begin by recalling the basic terminology and notation for F q \mathbb{F}_q F q -linear sets that will be used throughout the paper.
Definition 2.1. Let U U U be an F q \mathbb{F}_q F q -subspace of V V V . The F q \mathbb{F}_q F q -linear set defined by U U U is
L U = { ⟨ u ⟩ F q m : u ∈ U ∖ { 0 } } ⊆ PG ( V , F q m ) . L_U = \{\langle u\rangle_{\mathbb{F}_{q^m}} : u \in U \setminus\{0\}\} \subseteq\operatorname{PG}(V,\mathbb{F}_{q^m}). L U = {⟨ u ⟩ F q m : u ∈ U ∖ { 0 }} ⊆ PG ( V , F q m ) .
Its rank is dim F q U \dim_{\mathbb{F}_q} U dim F q U . For a point P = ⟨ v ⟩ F q m P = \langle v\rangle_{\mathbb{F}_{q^m}} P = ⟨ v ⟩ F q m , its weight with respect to U U U is
w U ( P ) = dim F q ( U ∩ ⟨ v ⟩ F q m ) . w_U(P) = \dim_{\mathbb{F}_q}(U \cap\langle v\rangle_{\mathbb{F}_{q^m}}). w U ( P ) = dim F q ( U ∩ ⟨ v ⟩ F q m ) .
We set w U ( P ) = 0 w_U(P) = 0 w U ( P ) = 0 when P ∉ L U P \notin L_U P ∈ / L U .
We refer to [13 ] for background on linear sets. The following vector-counting identity will be used repeatedly. If N i N_i N i denotes the number of points of weight i i i , then
q dim F q U − 1 = ∑ i ≥ 1 N i ( q i − 1 ) . (1) q^{\dim_{\mathbb{F}_q} U} - 1 = \sum_{i \ge1} N_i(q^i - 1). \tag*{(1)} q d i m F q U − 1 = i ≥ 1 ∑ N i ( q i − 1 ) . (1)
In particular, if every positive point weight is at least a a a , then
∣ L U ∣ ≤ q dim F q U − 1 q a − 1 . (2) |L_U| \le\frac{q^{\dim_{\mathbb{F}_q} U} - 1}{q^a - 1}. \tag*{(2)} ∣ L U ∣ ≤ q a − 1 q d i m F q U − 1 . (2)
We shall usually replace V V V with the F q m \mathbb{F}_{q^m} F q m -span of U U U . Thus, when convenient, we assume that
⟨ U ⟩ F q m = V . \langle U\rangle_{\mathbb{F}_{q^m}} = V. ⟨ U ⟩ F q m = V .
If h = dim F q m ⟨ U ⟩ F q m h = \dim_{\mathbb{F}_{q^m}}\langle U\rangle_{\mathbb{F}_{q^m}} h = dim F q m ⟨ U ⟩ F q m , then L U L_U L U spans a copy of PG ( h − 1 , q m ) \operatorname{PG}(h-1,q^m) PG ( h − 1 , q m ) . The next elementary lemma provides a characterization of when a linear set fills its span.
Lemma 2.2. Let S S S be an h h h -dimensional F q m \mathbb{F}_{q^m} F q m -vector space, h ≥ 1 h \ge1 h ≥ 1 , and let U ≤ F q S U \le_{\mathbb{F}_q} S U ≤ F q S . Then L U = PG ( S , F q m ) L_U = \operatorname{PG}(S,\mathbb{F}_{q^m}) L U = PG ( S , F q m ) if and only if dim F q U > ( h − 1 ) m \dim_{\mathbb{F}_q} U > (h-1)m dim F q U > ( h − 1 ) m .
Proof. If dim F q U > ( h − 1 ) m \dim_{\mathbb{F}_q} U > (h-1)m dim F q U > ( h − 1 ) m , then, for every one-dimensional F q m \mathbb{F}_{q^m} F q m -subspace P ≤ S P \le S P ≤ S , Grassmann’s formula gives
dim F q ( U ∩ P ) ≥ dim F q U + m − h m > 0 , \dim_{\mathbb{F}_q}(U \cap P) \ge\dim_{\mathbb{F}_q} U + m - hm > 0, dim F q ( U ∩ P ) ≥ dim F q U + m − hm > 0 , so P ∈ L U P \in L_U P ∈ L U . Conversely, if L U = PG ( S , F q m ) L_U = \operatorname{PG}(S,\mathbb{F}_{q^m}) L U = PG ( S , F q m ) , then every point has weight at least one, and (1) gives
dim F q U − 1 ≥ q h m − 1 q m − 1 ( q − 1 ) = ( q ( h − 1 ) m + ⋯ + q m + 1 ) ( q − 1 ) ≥ q ( h − 1 ) m > q ( h − 1 ) m − 1. \dim_{\mathbb{F}_q} U - 1 \ge\frac{q^{hm} - 1}{q^m - 1}(q - 1) = (q^{(h-1)m} + \cdots+ q^m + 1)(q - 1) \ge q^{(h-1)m} > q^{(h-1)m} - 1. dim F q U − 1 ≥ q m − 1 q hm − 1 ( q − 1 ) = ( q ( h − 1 ) m + ⋯ + q m + 1 ) ( q − 1 ) ≥ q ( h − 1 ) m > q ( h − 1 ) m − 1. Hence dim F q U > ( h − 1 ) m \dim_{\mathbb{F}_q} U > (h-1)m dim F q U > ( h − 1 ) m .
Fix a nondegenerate symmetric F q m \mathbb{F}_{q^m} F q m -bilinear form
σ : V × V ⟶ F q m \sigma: V \times V \longrightarrow\mathbb{F}_{q^m} σ : V × V ⟶ F q m
and define the nondegenerate F q \mathbb{F}_q F q -bilinear form
σ ′ ( x , y ) = Tr q m / q ( σ ( x , y ) ) . \sigma'(x,y)=\operatorname{Tr}_{q^m/q}(\sigma(x,y)). σ ′ ( x , y ) = Tr q m / q ( σ ( x , y )) .
We write ⊥ \perp ⊥ for orthogonality with respect to σ \sigma σ and ⊥ ′ \perp' ⊥ ′ for orthogonality with respect to σ ′ \sigma' σ ′ . Recall that X ⊥ ′ = X ⊥ X^{\perp'}=X^\perp X ⊥ ′ = X ⊥ for every F q m \mathbb{F}_{q^m} F q m -subspace X X X of V V V ; see [13 ] . When V = F q m k V=\mathbb{F}_{q^m}^k V = F q m k , we take σ \sigma σ to be the standard inner product σ ( x , y ) = ∑ i x i y i \sigma(x,y)=\sum_i x_i y_i σ ( x , y ) = ∑ i x i y i .
Proposition 2.3. [[13 ] , Property 2.6 ] Let U ≤ F q V U\leq_{\mathbb{F}_q} V U ≤ F q V have rank n n n , and let X ≤ F q m V X\leq_{\mathbb{F}_{q^m}} V X ≤ F q m V have F q m \mathbb{F}_{q^m} F q m -dimension s s s . Then
dim F q ( U ⊥ ′ ∩ X ⊥ ) = dim F q ( U ∩ X ) + k m − n − s m . (3) \dim_{\mathbb{F}_q}(U^{\perp'}\cap X^\perp)=\dim_{\mathbb{F}_q}(U\cap X)+km-n-sm. \tag*{(3)} dim F q ( U ⊥ ′ ∩ X ⊥ ) = dim F q ( U ∩ X ) + k m − n − s m . (3) In particular, for every F q m \mathbb{F}_{q^m} F q m -hyperplane H H H ,
w U ⊥ ′ ( H ⊥ ) = w U ( H ) + m − n . (4) w_{U^{\perp'}}(H^\perp)=w_U(H)+m-n. \tag*{(4)} w U ⊥ ′ ( H ⊥ ) = w U ( H ) + m − n . (4)
Remark 2.4. For every F q m \mathbb{F}_{q^m} F q m -hyperplane H H H , Grassmann’s formula yields
dim F q ( U ∩ H ) ≥ n − m , \dim_{\mathbb{F}_q}(U\cap H)\geq n-m, dim F q ( U ∩ H ) ≥ n − m ,
which is informative as soon as n > m n>m n > m . Formula (4) shows that the point weights of U ⊥ ′ U^{\perp'} U ⊥ ′ are exactly the excesses of the hyperplane weights of U U U above this baseline.
We shall repeatedly use that trace duality preserves linearity over subfields.
Lemma 2.5. Let s ∣ m s\mid m s ∣ m and let X X X be an F q s \mathbb{F}_{q^s} F q s -subspace of V V V . Then X ⊥ ′ X^{\perp'} X ⊥ ′ is also an F q s \mathbb{F}_{q^s} F q s -subspace of V V V .
Proof. Let u ∈ X ⊥ ′ u\in X^{\perp'} u ∈ X ⊥ ′ , λ ∈ F q s \lambda\in\mathbb{F}_{q^s} λ ∈ F q s and x ∈ X x\in X x ∈ X . Since λ x ∈ X \lambda x\in X λ x ∈ X and σ \sigma σ is F q m \mathbb{F}_{q^m} F q m -bilinear,
σ ′ ( λ u , x ) = Tr q m / q ( λ σ ( u , x ) ) = Tr q m / q ( σ ( u , λ x ) ) = σ ′ ( u , λ x ) = 0. \sigma'(\lambda u,x)=\operatorname{Tr}_{q^m/q}(\lambda\sigma(u,x))=\operatorname{Tr}_{q^m/q}(\sigma(u,\lambda x))=\sigma'(u,\lambda x)=0. σ ′ ( λ u , x ) = Tr q m / q ( λσ ( u , x )) = Tr q m / q ( σ ( u , λ x )) = σ ′ ( u , λ x ) = 0. Thus λ u ∈ X ⊥ ′ \lambda u\in X^{\perp'} λ u ∈ X ⊥ ′ .
Rank-metric codes and q q q -systems
We briefly recall the correspondence between linear rank-metric codes and q q q -systems, which allows us to translate rank weights of codewords into intersection dimensions with hyperplanes. This correspondence will be used repeatedly in the sequel.
For a vector c = ( c 1 , … , c n ) ∈ F q m n c=(c_1,\ldots,c_n)\in\mathbb{F}_{q^m}^n c = ( c 1 , … , c n ) ∈ F q m n , its rank weight is
w q ( c ) = dim F q ⟨ c 1 , … , c n ⟩ F q . w_q(c)=\dim_{\mathbb{F}_q}\langle c_1,\ldots,c_n\rangle_{\mathbb{F}_q}. w q ( c ) = dim F q ⟨ c 1 , … , c n ⟩ F q .
If q q q is clear from the context, we will just write w ( c ) w(c) w ( c ) . The rank distance on F q m n \mathbb{F}_{q^m}^n F q m n is defined by d R ( c , c ′ ) = w ( c − c ′ ) d_R(c,c')=w(c-c') d R ( c , c ′ ) = w ( c − c ′ ) . An [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q rank-metric code is an F q m \mathbb{F}_{q^m} F q m -subspace C ≤ F q m n C\leq\mathbb{F}_{q^m}^n C ≤ F q m n of dimension k k k . Its minimum rank distance is
d ( C ) = min { w ( c ) : c ∈ C ∖ { 0 } } . d(C)=\min\{w(c):c\in C\setminus\{0\}\}. d ( C ) = min { w ( c ) : c ∈ C ∖ { 0 }} .
Clearly, every codeword has rank weight at most min { n , m } \min\{n,m\} min { n , m } .
Let G ∈ F q m k × n G\in\mathbb{F}_{q^m}^{k\times n} G ∈ F q m k × n be a generator matrix of C C C , and write its columns as
G = ( u 1 ⋯ u n ) , u i ∈ F q m k . G=(u_1\ \cdots\ u_n),\qquad u_i\in\mathbb{F}_{q^m}^k. G = ( u 1 ⋯ u n ) , u i ∈ F q m k .
We say that C \mathcal{C} C is nondegenerate if the columns of G G G are linearly independent over F q \mathbb{F}_q F q . This condition does not depend on the choice of the generator matrix. Equivalently, if U = ⟨ u 1 , … , u n ⟩ F q ≤ F q m k U=\langle u_1,\ldots,u_n\rangle_{\mathbb{F}_q}\leq\mathbb{F}_{q^m}^k U = ⟨ u 1 , … , u n ⟩ F q ≤ F q m k , then dim F q U = n \dim_{\mathbb{F}_q}U=n dim F q U = n . Since G G G has rank k k k over F q m \mathbb{F}_{q^m} F q m , one also has ⟨ U ⟩ F q m = F q m k \langle U\rangle_{\mathbb{F}_{q^m}}=\mathbb{F}_{q^m}^k ⟨ U ⟩ F q m = F q m k .
An F q \mathbb{F}_q F q -subspace U ≤ F q m k U\leq\mathbb{F}_{q^m}^k U ≤ F q m k satisfying dim F q U = n \dim_{\mathbb{F}_q}U=n dim F q U = n and ⟨ U ⟩ F q m = F q m k \langle U\rangle_{\mathbb{F}_{q^m}}=\mathbb{F}_{q^m}^k ⟨ U ⟩ F q m = F q m k is called an [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q q q q -system . Thus every nondegenerate rank-metric code determines a q q q -system by taking the F q \mathbb{F}_q F q -span of the columns of a generator matrix. Conversely, given an [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q system U U U , choosing an F q \mathbb{F}_q F q -basis u 1 , … , u n u_1,\ldots,u_n u 1 , … , u n of U U U as the columns of a matrix G G G produces a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q rank-metric code.
Changing the F q \mathbb{F}_q F q -basis of U U U replaces G G G by G A GA G A , for some A ∈ GL ( n , q ) A\in\operatorname{GL}(n,q) A ∈ GL ( n , q ) . Accordingly, throughout the paper we regard codes related by such a transformation as equivalent. On the geometric side, changing the generator matrix of the same code by left multiplication with an element of GL ( k , q m ) \operatorname{GL}(k,q^m) GL ( k , q m ) replaces U U U by a projectively equivalent q q q -system. In this sense, the correspondence between nondegenerate rank-metric codes and q q q -systems is well defined up to the natural notions of equivalence; see [16 , 17 ] .
We now recall the basic relation between rank weights and hyperplane intersections. We use the nondegenerate F q m \mathbb{F}_{q^m} F q m -bilinear form σ \sigma σ fixed above. For x ∈ F q m k ∖ { 0 } x\in\mathbb{F}_{q^m}^k\setminus\{0\} x ∈ F q m k ∖ { 0 } , let
x ⊥ = { u ∈ F q m k : σ ( x , u ) = 0 } x^\perp=\{u\in\mathbb{F}_{q^m}^k:\sigma(x,u)=0\} x ⊥ = { u ∈ F q m k : σ ( x , u ) = 0 }
be the corresponding F q m \mathbb{F}_{q^m} F q m -hyperplane. If the columns of G G G form an F q \mathbb{F}_q F q -basis of U U U , then
x G = ( σ ( x , u 1 ) , … , σ ( x , u n ) ) xG=(\sigma(x,u_1),\ldots,\sigma(x,u_n)) x G = ( σ ( x , u 1 ) , … , σ ( x , u n ))
up to the choice of coordinates associated with σ \sigma σ . Therefore the rank weight of x G xG x G is the F q \mathbb{F}_q F q -dimension of the image of the map
φ x : U ⟶ F q m , u ⟼ σ ( x , u ) . \varphi_x:U\longrightarrow\mathbb{F}_{q^m},\qquad u\longmapsto\sigma(x,u). φ x : U ⟶ F q m , u ⟼ σ ( x , u ) .
Since ker φ x = U ∩ x ⊥ \ker\varphi_x=U\cap x^\perp ker φ x = U ∩ x ⊥ , the rank-nullity theorem gives
w ( x G ) = n − dim F q ( U ∩ x ⊥ ) . (5) w(xG)=n-\dim_{\mathbb{F}_q}(U\cap x^\perp). \tag*{(5)} w ( x G ) = n − dim F q ( U ∩ x ⊥ ) . (5)
Thus the rank-weight spectrum of C \mathcal{C} C is completely determined by the hyperplane-intersection spectrum of the associated q q q -system U U U . More precisely, if
N j ( U ) = # { H : H hyperplane of PG ( k − 1 , q m ) and dim F q ( U ∩ H ) = j } , N_j(U)=\#\{H:H\text{ hyperplane of }\operatorname{PG}(k-1,q^m)\text{ and }\dim_{\mathbb{F}_q}(U\cap H)=j\}, N j ( U ) = # { H : H hyperplane of PG ( k − 1 , q m ) and dim F q ( U ∩ H ) = j } ,
then, for i > 0 i>0 i > 0 , the number A i ( C ) A_i(\mathcal{C}) A i ( C ) of codewords of rank weight i i i satisfies
A i ( C ) = ( q m − 1 ) N n − i ( U ) . A_i(\mathcal{C})=(q^m-1)N_{n-i}(U). A i ( C ) = ( q m − 1 ) N n − i ( U ) .
Indeed, the nonzero vectors defining the same projective point differ by multiplication by an element of F q m \mathbb{F}_{q^m} F q m and hence determine the same hyperplane and codeword rank.
There is a second formulation of the correspondence which will be particularly useful in this paper. Combining (5) with (4) , applied to
H = x ⊥ , H ⊥ = ⟨ x ⟩ F q m , H=x^\perp,\qquad H^\perp=\langle x\rangle_{\mathbb{F}_{q^m}}, H = x ⊥ , H ⊥ = ⟨ x ⟩ F q m ,
gives
w U ⊥ ′ ( ⟨ x ⟩ F q m ) = m − w ( x G ) , (6) w_{U^{\perp'}}(\langle x\rangle_{\mathbb{F}_{q^m}})=m-w(xG), \tag*{(6)} w U ⊥ ′ (⟨ x ⟩ F q m ) = m − w ( x G ) , (6)
see [4 ] . Hence the point weights of the dual subspace U ⊥ ′ U^{\perp'} U ⊥ ′ are exactly the deficiencies of the rank weights of C \mathcal{C} C from m m m . In particular,
w ( x G ) < m ⟺ ⟨ x ⟩ F q m ∈ L U ⊥ ′ . w(xG)<m\quad\Longleftrightarrow\quad\langle x\rangle_{\mathbb{F}_{q^m}}\in L_{U^{\perp'}}. w ( x G ) < m ⟺ ⟨ x ⟩ F q m ∈ L U ⊥ ′ .
Formulas (5) and (6) remain valid for an arbitrary F q \mathbb{F}_q F q -subspace U ≤ F q m k U \leq\mathbb{F}_{q^m}^k U ≤ F q m k , with n = dim F q U n = \dim_{\mathbb{F}_q} U n = dim F q U , and for any matrix whose columns form an F q \mathbb{F}_q F q -basis of U U U ; in this more general situation U U U doesn’t need to span F q m k \mathbb{F}_{q^m}^k F q m k over F q m \mathbb{F}_{q^m} F q m .
The following consequence will be useful when studying few-weight codes. It determines exactly when the maximum possible rank weight m m m occurs.
Proposition 2.6. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q rank-metric code, and let U U U be an associated q q q -system. The following are equivalent:
(a) no codeword of C C C has rank weight m m m ;
(b) L U ⊥ ′ = P G ( k − 1 , q m ) L_{U^{\perp'}} = \mathrm{PG}(k-1,q^m) L U ⊥ ′ = PG ( k − 1 , q m ) ;
(c) n ≤ m − 1 n \leq m-1 n ≤ m − 1 .
Consequently, every nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code with n ≥ m n \geq m n ≥ m contains a codeword of rank weight m m m .
Proof. By (6) , a point ⟨ x ⟩ F q m \langle x\rangle_{\mathbb{F}_{q^m}} ⟨ x ⟩ F q m has positive weight with respect to U ⊥ ′ U^{\perp'} U ⊥ ′ if and only if w ( x G ) < m w(xG) < m w ( x G ) < m . Hence (a) and (b) are equivalent.
Put N = dim F q U ⊥ ′ = k m − n N = \dim_{\mathbb{F}_q} U^{\perp'} = km-n N = dim F q U ⊥ ′ = k m − n . By Lemma 2.2, applied with S = F q m k S = \mathbb{F}_{q^m}^k S = F q m k , one has L U ⊥ ′ = P G ( k − 1 , q m ) L_{U^{\perp'}} = \mathrm{PG}(k-1,q^m) L U ⊥ ′ = PG ( k − 1 , q m ) if and only if N > ( k − 1 ) m N > (k-1)m N > ( k − 1 ) m . Since N = k m − n N = km-n N = k m − n , this is equivalent to n < m n < m n < m , or, equivalently, n ≤ m − 1 n \leq m-1 n ≤ m − 1 .
The last assertion of Proposition 2.6 is a special case of [2 Proposition 3.11] , according to which every nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code contains a codeword of rank min { m , n } \min\{m,n\} min { m , n } .
Remark 2.7. In particular, if a nondegenerate rank-metric code has length n ≥ m n \geq m n ≥ m , then one of its nonzero weights is necessarily m m m . Under geometric duality, the weight m m m corresponds to the zero point weight of U ⊥ ′ U^{\perp'} U ⊥ ′ , whereas every nonmaximum codeword weight w < m w < m w < m corresponds to the positive point weight m − w m-w m − w of L U ⊥ ′ L_{U^{\perp'}} L U ⊥ ′ . Thus a code with nonzero weights d 1 < ⋯ < d r < m d_1 < \cdots< d_r < m d 1 < ⋯ < d r < m and m m m corresponds on the dual side to a linear set whose positive point weights are
d 1 < ⋯ < d r < m and m d_1 < \cdots< d_r < m \qquad\text{and} \qquad m d 1 < ⋯ < d r < m and m
corresponds on the dual side to a linear set whose positive point weights are
m − d r < ⋯ < m − d 1 . m-d_r < \cdots< m-d_1. m − d r < ⋯ < m − d 1 .
We finally recall the operation of field expansion, which provides the link between subfield linearity of a q q q -system and divisibility of rank weights.
Definition 2.8. Let e ∣ m e \mid m e ∣ m , and suppose that an [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q system U ≤ F q m k U \leq\mathbb{F}_{q^m}^k U ≤ F q m k is an F q e \mathbb{F}_{q^e} F q e -subspace. Then necessarily e ∣ n e \mid n e ∣ n , and
dim F q e U = n e . \dim_{\mathbb{F}_{q^e}} U = \frac{n}{e}. dim F q e U = e n .
Choose an F q e \mathbb{F}_{q^e} F q e -basis u 1 , … , u n / e u_1,\ldots,u_{n/e} u 1 , … , u n / e of U U U , and let G e G_e G e be the matrix having these vectors as columns. The code generated by G e G_e G e is an [ n / e , k ] q m / q e [n/e,k]_{q^m/q^e} [ n / e , k ] q m / q e rank-metric code.
Fix an F q \mathbb{F}_q F q -basis β 1 , … , β e \beta_1,\ldots,\beta_e β 1 , … , β e of F q e \mathbb{F}_{q^e} F q e . Replacing each column u i u_i u i of G e G_e G e by β 1 u i , … , β e u i \beta_1u_i,\ldots,\beta_eu_i β 1 u i , … , β e u i gives a matrix with n n n columns whose F q \mathbb{F}_q F q -span is U U U . The corresponding [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code is called the F q \mathbb{F}_q F q -expansion of the original code C e C_e C e generated by G e G_e G e and is denoted by Exp q e / q ( C e ) \operatorname{Exp}_{q^e/q}(C_e) Exp q e / q ( C e ) .
If c c c is a codeword before expansion and c ~ \widetilde{c} c is the corresponding codeword after expansion, then
w q ( c ~ ) = e w q e ( c ) . w_q(\widetilde{c}) = e\,w_{q^e}(c). w q ( c ) = e w q e ( c ) .
Consequently, every rank weight of an F q \mathbb{F}_q F q -expansion from F q e \mathbb{F}_{q^e} F q e is divisible by e e e . On the geometric side, this is reflected by the fact that, when U U U is F q e \mathbb{F}_{q^e} F q e -linear, every intersection U ∩ H U \cap H U ∩ H with an F q m \mathbb{F}_{q^m} F q m -subspace H H H is again an F q e \mathbb{F}_{q^e} F q e -subspace, and hence all the corresponding intersection dimensions over F q \mathbb{F}_q F q are multiples of e e e .
Remark 2.9. A simplex code is a nondegenerate [ m k , k ] q m / q [mk,k]_{q^m/q} [ mk , k ] q m / q code C C C . Its associated system has F q \mathbb{F}_q F q -dimension m k mk mk , hence it is the whole space U = F q m k U=\mathbb{F}_{q^m}^k U = F q m k , which is trivially F q m \mathbb{F}_{q^m} F q m -linear. Therefore simplex codes are particular expanded codes: C C C is, up to equivalence, the F q \mathbb{F}_q F q -expansion Exp q m / q ( C m ) \operatorname{Exp}_{q^m/q}(C_m) Exp q m / q ( C m ) of the [ k , k ] q m / q m [k,k]_{q^m/q^m} [ k , k ] q m / q m code C m = F q m k C_m=\mathbb{F}_{q^m}^k C m = F q m k , whose generator matrix is the identity matrix. Since every nonzero codeword of C m C_m C m has rank weight one over F q m \mathbb{F}_{q^m} F q m , every nonzero codeword of C C C has rank weight m m m ; this agrees with (5) , as dim F q ( F q m k ∩ H ) = ( k − 1 ) m \dim_{\mathbb{F}_q}(\mathbb{F}_{q^m}^k\cap H)=(k-1)m dim F q ( F q m k ∩ H ) = ( k − 1 ) m for every hyperplane H H H .
Fields of linearity of few-weight linear sets
We recall two results that are central to the paper.
Theorem 3.1. [6 Theorem 2] Let U U U define a linear set of rank N N N spanning P G ( h − 1 , q m ) \mathrm{PG}(h-1,q^m) PG ( h − 1 , q m ) , and assume
N ≤ ( h − 1 ) m , m ≤ q . N\leq(h-1)m,\qquad m\leq q. N ≤ ( h − 1 ) m , m ≤ q . If every point of L U L_U L U has weight at least a ≥ 2 a\geq2 a ≥ 2 , then there exists a divisor t t t of m m m , with t ≥ a t\geq a t ≥ a , such that
L U = L ⟨ U ⟩ F q t . L_U=L_{\langle U\rangle_{\mathbb{F}_{q^t}}}. L U = L ⟨ U ⟩ F q t . Repeated application produces a representation over a maximal subfield whose associated linear set contains a point of relative weight one.
Theorem 3.2. [1 Corollary 3.16] Let Q Q Q be a prime power and let L W L_W L W be an F Q \mathbb{F}_Q F Q -linear set of rank g ≥ 2 g\geq2 g ≥ 2 spanning a projective subspace of positive dimension. If L W L_W L W contains a point of F Q \mathbb{F}_Q F Q -weight one, then
∣ L W ∣ ≥ Q g − 1 + 1. |L_W|\geq Q^{g-1}+1. ∣ L W ∣ ≥ Q g − 1 + 1.
The above result gives the stronger bound ∣ L W ∣ ≥ Q g − 1 + I |L_W|\geq Q^{g-1}+I ∣ L W ∣ ≥ Q g − 1 + I , where I I I is the number of secant lines through a point of weight one. Since the set spans at least a line, I ≥ 1 I\geq1 I ≥ 1 . See also [7 ] for earlier results on the minimum size of linear sets.
The next known result treats ranks that are multiples of the extension degree.
Proposition 3.3. Let U U U define a linear set whose rank is a multiple of m m m , and let a a a be its minimum positive point weight. Then a ∣ m a\mid m a ∣ m and U U U is F q a \mathbb{F}_{q^a} F q a -linear. Consequently, a a a divides every point weight and
a = gcd { w U ( P ) : P ∈ L U } . a=\gcd\{w_U(P):P\in L_U\}. a = g cd{ w U ( P ) : P ∈ L U } . Moreover, F q a \mathbb{F}_{q^a} F q a is the maximum field of linearity of U U U .
Proof. For a > 1 a>1 a > 1 , the first assertion is [6 Theorem 1] ; for a = 1 a=1 a = 1 it is immediate. Once U U U is F q a \mathbb{F}_{q^a} F q a -linear, every intersection U ∩ P U\cap P U ∩ P is an F q a \mathbb{F}_{q^a} F q a -subspace, so every point weight is divisible by a a a . Since a a a itself occurs, it equals the gcd { w U ( P ) : P ∈ L U } \gcd\{w_U(P):P\in L_U\} g cd{ w U ( P ) : P ∈ L U } . If U U U is F q s \mathbb{F}_{q^s} F q s -linear, then s s s divides every point weight, hence s ∣ a s\mid a s ∣ a and F q s ⊆ F q a \mathbb{F}_{q^s}\subseteq\mathbb{F}_{q^a} F q s ⊆ F q a .
We next isolate the elementary gcd consequence of the vector-counting identity.
Lemma 3.4. Let U U U be an N N N -dimensional F q \mathbb{F}_q F q -subspace and assume that its positive point weights belong to A = { a 1 , … , a r } A=\{a_1,\ldots,a_r\} A = { a 1 , … , a r } . Put e = gcd ( a 1 , … , a r ) e=\gcd(a_1,\ldots,a_r) e = g cd( a 1 , … , a r ) . Then e ∣ N e\mid N e ∣ N .
Proof. By (1) ,
q N − 1 = ∑ i = 1 r N a i ( q a i − 1 ) . q^N-1=\sum_{i=1}^{r}N_{a_i}(q^{a_i}-1). q N − 1 = i = 1 ∑ r N a i ( q a i − 1 ) .
Since e ∣ a i e\mid a_i e ∣ a i , the integer q e − 1 q^e-1 q e − 1 divides every summand on the right. Hence q e − 1 ∣ q N − 1 q^e-1\mid q^N-1 q e − 1 ∣ q N − 1 , which is equivalent to e ∣ N e\mid N e ∣ N .
Definition 3.5. For positive integers e < N e<N e < N define D m ( e , N ) = { t : t ∣ m , e < t ≤ N − e } \mathcal{D}_m(e,N)=\{t:t\mid m,\ e<t\leq N-e\} D m ( e , N ) = { t : t ∣ m , e < t ≤ N − e } . We say that ( m , e , N ) (m,e,N) ( m , e , N ) satisfies the divisor-gap condition if D m ( e , N ) = ∅ \mathcal{D}_m(e,N)=\varnothing D m ( e , N ) = ∅ . Equivalently, if
d + ( m , e ) = min { t : t ∣ m , t > e } , d^{+}(m,e)=\min\{t:t\mid m,\ t>e\}, d + ( m , e ) = min { t : t ∣ m , t > e } , with d + ( m , e ) = + ∞ d^{+}(m,e)=+\infty d + ( m , e ) = + ∞ when the set is empty, then the condition is
d + ( m , e ) > N − e . d^{+}(m,e)>N-e. d + ( m , e ) > N − e .
Example 3.6. Take m = 12 m=12 m = 12 and e = 3 e=3 e = 3 . If N = 6 N=6 N = 6 , then
D 12 ( 3 , 6 ) = { t : t ∣ 12 , 3 < t ≤ 3 } = ∅ , \mathcal{D}_{12}(3,6)=\{t:t\mid12,\ 3<t\leq3\}=\varnothing, D 12 ( 3 , 6 ) = { t : t ∣ 12 , 3 < t ≤ 3 } = ∅ , so ( 12 , 3 , 6 ) (12,3,6) ( 12 , 3 , 6 ) satisfies the divisor-gap condition. Equivalently, the smallest divisor of 12 strictly larger than 3 is d + ( 12 , 3 ) = 4 d^{+}(12,3)=4 d + ( 12 , 3 ) = 4 , and 4 > N − e = 3 4>N-e=3 4 > N − e = 3 .
On the other hand, if N = 9 N=9 N = 9 , then
D 12 ( 3 , 9 ) = { t : t ∣ 12 , 3 < t ≤ 6 } = { 4 , 6 } , \mathcal{D}_{12}(3,9)=\{t:t\mid12,\ 3<t\leq6\}=\{4,6\}, D 12 ( 3 , 9 ) = { t : t ∣ 12 , 3 < t ≤ 6 } = { 4 , 6 } , so the divisor-gap condition does not hold.
We now combine the preceding results to show that a lower bound on the point weights not only forces a representation over a larger subfield, but also determines precisely the rank of such a representation.
Theorem 3.7. Let q ≥ m q\geq m q ≥ m , let U ≤ F q V U\leq_{\mathbb F_q}V U ≤ F q V , and put S = ⟨ U ⟩ F q m S=\langle U\rangle_{\mathbb F_{q^m}} S = ⟨ U ⟩ F q m , h = dim F q m S ≥ 2 h=\dim_{\mathbb F_{q^m}}S\geq2 h = dim F q m S ≥ 2 , N = dim F q U N=\dim_{\mathbb F_q}U N = dim F q U . Assume that N ≤ ( h − 1 ) m N\leq(h-1)m N ≤ ( h − 1 ) m , and let
a = min { w U ( P ) : P ∈ L U } . a=\min\{w_U(P):P\in L_U\}. a = min { w U ( P ) : P ∈ L U } . If a > 1 a>1 a > 1 , then there exists a divisor t ∣ m t\mid m t ∣ m , with t ≥ a t\geq a t ≥ a , such that, setting
W = ⟨ U ⟩ F q t , W=\langle U\rangle_{\mathbb F_{q^t}}, W = ⟨ U ⟩ F q t , one has L U = L W L_U=L_W L U = L W . Moreover, t t t may be chosen so that L W L_W L W , regarded as an F q t \mathbb F_{q^t} F q t -linear set, contains a point of F q t \mathbb F_{q^t} F q t -weight one. For such a choice,
dim F q W = N + t − a . \dim_{\mathbb F_q}W=N+t-a. dim F q W = N + t − a . In particular,
t ∣ N − a and a ≤ t ≤ N − a . t\mid N-a \qquad\text{and}\qquad a\leq t\leq N-a. t ∣ N − a and a ≤ t ≤ N − a .
Proof. Since h ≥ 2 h\geq2 h ≥ 2 , N ≤ ( h − 1 ) m N\leq(h-1)m N ≤ ( h − 1 ) m , m ≤ q m\leq q m ≤ q and every point of L U L_U L U has weight at least a ≥ 2 a\geq2 a ≥ 2 , Theorem 3.1 applies. Starting from U U U and enlarging the field of linearity whenever the resulting representation has no point of relative weight one, we obtain a divisor t ∣ m t\mid m t ∣ m and an F q t \mathbb F_{q^t} F q t -subspace W = ⟨ U ⟩ F q t W=\langle U\rangle_{\mathbb F_{q^t}} W = ⟨ U ⟩ F q t such that
L W = L U , (7) L_W=L_U, \tag*{(7)} L W = L U , (7)
t ≥ a t\geq a t ≥ a , and L W L_W L W , regarded as an F q t \mathbb F_{q^t} F q t -linear set, has a point of F q t \mathbb F_{q^t} F q t -weight one. Indeed, since N ≤ ( h − 1 ) m N\leq(h-1)m N ≤ ( h − 1 ) m , Lemma 2.2 shows that L U ≠ PG ( S , F q m ) L_U\neq\operatorname{PG}(S,\mathbb F_{q^m}) L U = PG ( S , F q m ) . By the same lemma, every F q \mathbb F_q F q -subspace of S S S defining the point set L U L_U L U has F q \mathbb F_q F q -dimension at most ( h − 1 ) m (h-1)m ( h − 1 ) m ; for an F q t \mathbb F_{q^t} F q t -subspace, this means F q t \mathbb F_{q^t} F q t -dimension at most ( h − 1 ) m / t (h-1)m/t ( h − 1 ) m / t , where m / t m/t m / t is the degree of F q m \mathbb F_{q^m} F q m over F q t \mathbb F_{q^t} F q t . Furthermore,
m t ≤ m ≤ q ≤ q t , \frac{m}{t}\leq m\leq q\leq q^t, t m ≤ m ≤ q ≤ q t ,
so Theorem 3.1 can be reapplied over the base field F q t \mathbb F_{q^t} F q t whenever the current representation has no point of relative weight one. Each application strictly increases the degree of the field of linearity, which is a divisor of m m m , so the process terminates.
Write
g = dim F q t W , N ′ = dim F q W = g t . g = \dim_{\mathbb{F}_{q^t}} W,\qquad N' = \dim_{\mathbb{F}_q} W = gt. g = dim F q t W , N ′ = dim F q W = g t .
Because U ⊆ W U \subseteq W U ⊆ W ,
N ′ ≥ N . (8) N' \ge N. \tag*{(8)} N ′ ≥ N . (8)
Moreover, W W W spans S S S over F q m \mathbb{F}_{q^m} F q m , and hence g ≥ h ≥ 2 g \ge h \ge2 g ≥ h ≥ 2 .
Apply Theorem 3.2 over the field F q t \mathbb{F}_{q^t} F q t . We obtain
∣ L U ∣ = ∣ L W ∣ ≥ ( q t ) g − 1 + 1 = q N ′ − t + 1. (9) |L_U| = |L_W| \ge(q^t)^{g-1}+1 = q^{N'-t}+1. \tag*{(9)} ∣ L U ∣ = ∣ L W ∣ ≥ ( q t ) g − 1 + 1 = q N ′ − t + 1. (9)
On the other hand, every point of L U L_U L U has weight at least a a a , so (2) yields
∣ L U ∣ ≤ q N − 1 q a − 1 . (10) |L_U| \le\frac{q^N-1}{q^a-1}. \tag*{(10)} ∣ L U ∣ ≤ q a − 1 q N − 1 . (10)
Combining (9) and (10) ,
q N ′ − t + 1 ≤ q N − 1 q a − 1 < q N − a + 1 . q^{N'-t}+1 \le\frac{q^N-1}{q^a-1} < q^{N-a+1}. q N ′ − t + 1 ≤ q a − 1 q N − 1 < q N − a + 1 .
Since the exponents are integers, it follows that
N ′ − t ≤ N − a . (11) N'-t \le N-a. \tag*{(11)} N ′ − t ≤ N − a . (11)
Now choose a point P ∈ L U P \in L_U P ∈ L U of minimum weight, so that w U ( P ) = a w_U(P)=a w U ( P ) = a . Since L U = L W L_U=L_W L U = L W , we have P ∈ L W P \in L_W P ∈ L W . Moreover, W W W is an F q t \mathbb{F}_{q^t} F q t -subspace, and therefore
w W ( P ) = ρ t w_W(P)=\rho t w W ( P ) = ρt
for some integer ρ ≥ 1 \rho\ge1 ρ ≥ 1 . Since U ∩ P ⊆ W ∩ P U \cap P \subseteq W \cap P U ∩ P ⊆ W ∩ P and ( W ∩ P ) ∩ U = U ∩ P (W \cap P) \cap U = U \cap P ( W ∩ P ) ∩ U = U ∩ P , the quotient ( W ∩ P ) / ( U ∩ P ) (W \cap P)/(U \cap P) ( W ∩ P ) / ( U ∩ P ) embeds into W / U W/U W / U . Hence
N ′ − N ≥ w W ( P ) − w U ( P ) = ρ t − a ≥ t − a . N'-N \ge w_W(P)-w_U(P)=\rho t-a \ge t-a. N ′ − N ≥ w W ( P ) − w U ( P ) = ρt − a ≥ t − a .
Combining this with (11) , which gives N ′ − N ≤ t − a N'-N \le t-a N ′ − N ≤ t − a , we obtain
N ′ = N + t − a . N'=N+t-a. N ′ = N + t − a .
Finally, N − a = N ′ − t = ( g − 1 ) t N-a=N'-t=(g-1)t N − a = N ′ − t = ( g − 1 ) t . Hence t ∣ N − a t \mid N-a t ∣ N − a , and t ≤ N − a t \le N-a t ≤ N − a because g ≥ 2 g \ge2 g ≥ 2 .
Remark 3.8. The proof of Theorem 3.7 extends the argument of [22 Corollary III.3] , which concerns F q \mathbb{F}_q F q -subspaces of F q m 2 \mathbb{F}_{q^m}^2 F q m 2 all of whose points have weight 0 0 0 or e e e . There, Theorem 3.1 is iterated until a point of relative weight one appears, and the bound of [7 Theorem 1.2] is compared with the exact size ( q n − 1 ) / ( q e − 1 ) (q^n-1)/(q^e-1) ( q n − 1 ) / ( q e − 1 ) of L U L_U L U , giving n − e = dim F q ⟨ U ⟩ F q t − t n-e=\dim_{\mathbb{F}_q}\langle U\rangle_{\mathbb{F}_{q^t}}-t n − e = dim F q ⟨ U ⟩ F q t − t , that is, the identity dim F q W = N + t − a \dim_{\mathbb{F}_q}W=N+t-a dim F q W = N + t − a in that special case. Here only the minimum weight a a a is prescribed and ∣ L U ∣ |L_U| ∣ L U ∣ is unknown: the exact count is replaced by (2) together with the inequality dim F q W − N ≥ t − a \dim_{\mathbb{F}_q}W-N \ge t-a dim F q W − N ≥ t − a , and Theorem 3.2 allows us to work directly in PG ( h − 1 , q m ) \operatorname{PG}(h-1,q^m) PG ( h − 1 , q m ) instead of restricting to lines as in [22 ] .
The divisor-gap condition introduced above allows us to strengthen the larger-field representation of Theorem 3.7 into a structural result, forcing the field of linearity to be determined by the gcd of the positive point weights.
Theorem 3.9. Let U ≤ F q V U \le_{\mathbb{F}_q} V U ≤ F q V satisfy the assumptions of Theorem 3.7, and suppose that the positive point weights of L U L_U L U are
A = { a 1 , … , a r } , 1 < a 1 < ⋯ < a r . A=\{a_1,\ldots,a_r\},\qquad1<a_1<\cdots<a_r. A = { a 1 , … , a r } , 1 < a 1 < ⋯ < a r .
Put e = gcd ( a 1 , … , a r ) e=\gcd(a_1,\ldots,a_r) e = g cd( a 1 , … , a r ) and N = dim F q U N=\dim_{\mathbb{F}_q} U N = dim F q U . Assume that D m ( e , N ) = ∅ \mathcal{D}_m(e,N)=\varnothing D m ( e , N ) = ∅ . Let t ∣ m t\mid m t ∣ m and W = ⟨ U ⟩ F q t W=\langle U\rangle_{\mathbb{F}_{q^t}} W = ⟨ U ⟩ F q t be as in Theorem 3.7 , with t t t chosen so that L W L_W L W has a point of F q t \mathbb{F}_{q^t} F q t -weight one. Then
a 1 = t = e and U = W . a_1=t=e\quad\text{and}\quad U=W. a 1 = t = e and U = W .
Consequently, U U U is an F q e \mathbb{F}_{q^e} F q e -subspace of V V V . In particular, e ∣ m e\mid m e ∣ m , e ∣ N e\mid N e ∣ N , the minimum positive point weight a 1 a_1 a 1 divides every a i a_i a i , and F q e \mathbb{F}_{q^e} F q e is the maximum field of linearity of U U U .
Proof. Theorem 3.7 , applied with a = a 1 a=a_1 a = a 1 , gives
e ≤ a 1 ≤ t ≤ N − a 1 ≤ N − e . (12) e\leq a_1\leq t\leq N-a_1\leq N-e. \tag*{(12)} e ≤ a 1 ≤ t ≤ N − a 1 ≤ N − e . (12)
The integer t t t divides m m m . If t > e t>e t > e , then (12) gives t ∈ D m ( e , N ) t\in\mathcal{D}_m(e,N) t ∈ D m ( e , N ) , contradicting the hypothesis. Hence t = e t=e t = e , and then (12) forces
In particular, e ∣ m e\mid m e ∣ m . Moreover,
dim F q W = N + t − a 1 = N . \dim_{\mathbb{F}_q}W=N+t-a_1=N. dim F q W = N + t − a 1 = N .
Since U ⊆ W U\subseteq W U ⊆ W , we conclude that U = W U=W U = W . Thus U U U is F q e \mathbb{F}_{q^e} F q e -linear, and e ∣ N e\mid N e ∣ N (this also follows from Lemma 3.4 ). Finally, if U U U were linear over F q s \mathbb{F}_{q^s} F q s , then every intersection U ∩ P U\cap P U ∩ P would be an F q s \mathbb{F}_{q^s} F q s -subspace, so s s s would divide every point weight and hence s ∣ e s\mid e s ∣ e . Therefore F q e \mathbb{F}_{q^e} F q e is the maximum field of linearity. □
Remark 3.10. The proof of Theorem 3.9 uses the divisor-gap condition only to exclude the divisor t t t produced by Theorem 3.7 , and this divisor is more constrained than an arbitrary element of D m ( e , N ) \mathcal{D}_m(e,N) D m ( e , N ) .
(i) The divisor t t t is a proper divisor of m m m . Indeed, if t = m t=m t = m , then W = ⟨ U ⟩ F q m = S W=\langle U\rangle_{\mathbb{F}_{q^m}}=S W = ⟨ U ⟩ F q m = S , so L U = L W = PG ( S , F q m ) L_U=L_W=\operatorname{PG}(S,\mathbb{F}_{q^m}) L U = L W = PG ( S , F q m ) , contradicting Lemma 2.2 since N ≤ ( h − 1 ) m N\leq(h-1)m N ≤ ( h − 1 ) m .
(ii) The divisor t t t satisfies a 1 ≤ t ≤ N − a 1 a_1\leq t\leq N-a_1 a 1 ≤ t ≤ N − a 1 and t ∣ N − a 1 t\mid N-a_1 t ∣ N − a 1 .
Consequently, the conclusions of Theorem 3.9 remain valid under the weaker hypothesis that no proper divisor s s s of m m m satisfies
a 1 < s ≤ N − a 1 and s ∣ N − a 1 . a_1<s\leq N-a_1\qquad\text{and}\qquad s\mid N-a_1. a 1 < s ≤ N − a 1 and s ∣ N − a 1 .
Indeed, under this hypothesis t = a 1 t=a_1 t = a 1 , so dim F q W = N \dim_{\mathbb{F}_q}W=N dim F q W = N and U = W U=W U = W is F q a 1 \mathbb{F}_{q^{a_1}} F q a 1 -linear; hence a 1 a_1 a 1 divides every point weight, and a 1 = e a_1=e a 1 = e . By (i), the divisor m m m itself never obstructs; this is relevant only when N ≥ m + e N\geq m+e N ≥ m + e , which, as N ≤ ( h − 1 ) m N\leq(h-1)m N ≤ ( h − 1 ) m , requires h ≥ 3 h\geq3 h ≥ 3 . These refinements are not used elsewhere in the paper.
We now record some consequences.
Corollary 3.11. Let U U U satisfy the assumptions of Theorem 3.7 , and suppose that the point weights are
0 , s 1 , s 2 , 1 < s 1 < s 2 . 0,s_1,s_2,\qquad1<s_1<s_2. 0 , s 1 , s 2 , 1 < s 1 < s 2 . Put e = gcd ( s 1 , s 2 ) e=\gcd(s_1,s_2) e = g cd( s 1 , s 2 ) and N = dim F q U N=\dim_{\mathbb{F}_q}U N = dim F q U . If D m ( e , N ) = ∅ \mathcal{D}_m(e,N)=\varnothing D m ( e , N ) = ∅ , then
so
s 1 ∣ m , s 1 ∣ N , s 1 ∣ s 2 , s_1\mid m,\qquad s_1\mid N,\qquad s_1\mid s_2, s 1 ∣ m , s 1 ∣ N , s 1 ∣ s 2 , and U U U is F q s 1 \mathbb{F}_{q^{s_1}} F q s 1 -linear.
Corollary 3.12. Let m m m be prime and q ≥ m q \geq m q ≥ m . Let U ≤ F q V U \leq_{\mathbb F_q} V U ≤ F q V be such that S = ⟨ U ⟩ F q m S = \langle U\rangle_{\mathbb F_{q^m}} S = ⟨ U ⟩ F q m has dimension h ≥ 2 h \geq2 h ≥ 2 , and assume that dim F q U ≤ ( h − 1 ) m \dim_{\mathbb F_q} U \leq(h-1)m dim F q U ≤ ( h − 1 ) m . Then L U L_U L U has a point of weight one.
Proof. Assume that every point of L U L_U L U has weight at least two. By Theorem 3.1 , there is a divisor t ≥ 2 t \geq2 t ≥ 2 of m m m with L U = L ⟨ U ⟩ F q t L_U = L_{\langle U\rangle_{\mathbb F_{q^t}}} L U = L ⟨ U ⟩ F q t . Since m m m is prime, t = m t = m t = m , and then ⟨ U ⟩ F q m = S \langle U\rangle_{\mathbb F_{q^m}} = S ⟨ U ⟩ F q m = S gives L U = PG ( S , F q m ) L_U = \operatorname{PG}(S,\mathbb F_{q^m}) L U = PG ( S , F q m ) . This contradicts Lemma 2.2 .
Remark 3.13. The proof of Corollary 3.12 uses only Theorem 3.1 and Lemma 2.2 , and it holds in arbitrary projective dimension.
The preceding results admit a natural dual formulation in terms of hyperplane weights. Indeed, trace duality identifies the excess of a hyperplane weight above the minimum possible value n − m n-m n − m with the corresponding point weight of the dual linear set. This allows us to translate the above structural result directly into a criterion for the hyperplane-weight spectrum.
Theorem 3.14. Let q ≥ m q \geq m q ≥ m , let U ≤ F q V U \leq_{\mathbb F_q} V U ≤ F q V have rank n n n , and put
W = U ⊥ ′ , N = dim F q W = k m − n . W = U^{\perp'}, \qquad N = \dim_{\mathbb F_q} W = km-n. W = U ⊥ ′ , N = dim F q W = k m − n . Assume that W W W spans an F q m \mathbb F_{q^m} F q m -subspace S S S of dimension h ≥ 2 h \geq2 h ≥ 2 and that N ≤ ( h − 1 ) m N \leq(h-1)m N ≤ ( h − 1 ) m . Assume that the hyperplane weights of U U U are precisely
n − m , n − m + a 1 , … , n − m + a r , 1 ≤ a 1 < ⋯ < a r , n-m,\ n-m+a_1,\ldots,n-m+a_r,\qquad1 \leq a_1 < \cdots< a_r, n − m , n − m + a 1 , … , n − m + a r , 1 ≤ a 1 < ⋯ < a r , and put e = gcd ( a 1 , … , a r ) e = \gcd(a_1,\ldots,a_r) e = g cd( a 1 , … , a r ) . If D m ( e , N ) = ∅ D_m(e,N) = \varnothing D m ( e , N ) = ∅ , then a 1 = e a_1 = e a 1 = e , and both W W W and U U U are F q e \mathbb F_{q^e} F q e -linear. In particular,
e ∣ m , e ∣ n , e \mid m,\qquad e \mid n, e ∣ m , e ∣ n , and every hyperplane weight of U U U is divisible by e e e .
Proof. By Proposition 2.3 , the point weights of L W L_W L W are
0 , a 1 , … , a r . 0,a_1,\ldots,a_r. 0 , a 1 , … , a r .
If a 1 = 1 a_1 = 1 a 1 = 1 , then e = 1 e = 1 e = 1 and there is nothing to prove. Otherwise, Theorem 3.9 applies to W W W , gives a 1 = e a_1 = e a 1 = e , and proves that W W W is F q e \mathbb F_{q^e} F q e -linear. By Lemma 2.5 , U = W ⊥ ′ U = W^{\perp'} U = W ⊥ ′ is also F q e \mathbb F_{q^e} F q e -linear. Hence e ∣ dim F q U = n e \mid\dim_{\mathbb F_q} U = n e ∣ dim F q U = n , and every intersection U ∩ H U \cap H U ∩ H with an F q m \mathbb F_{q^m} F q m -hyperplane H H H is an F q e \mathbb F_{q^e} F q e -subspace.
Remark 3.15. The hypothesis that U ⊥ ′ U^{\perp'} U ⊥ ′ spans a projective subspace of positive dimension is automatic as soon as at least two distinct positive excesses a i a_i a i occur. Indeed, if U ⊥ ′ U^{\perp'} U ⊥ ′ were contained in one F q m \mathbb F_{q^m} F q m -point, then its linear set would have only one positive point weight, namely N N N . Equivalently, U ⊥ ′ U^{\perp'} U ⊥ ′ is contained in a point precisely when U U U contains an F q m \mathbb F_{q^m} F q m -hyperplane. This exceptional case should be separated before applying Theorem 3.14 .
If ( k − 1 ) m < n < k m (k-1)m < n < km ( k − 1 ) m < n < k m and h ≥ 2 h \geq2 h ≥ 2 , then N < m ≤ ( h − 1 ) m N < m \leq(h-1)m N < m ≤ ( h − 1 ) m , so the rank hypothesis of Theorem 3.14 is automatic.
Corollary 3.16. Let the assumptions of Theorem 3.14 hold and suppose that the hyperplane weights are
n − m , n − m + s 1 , n − m + s 2 , 1 < s 1 < s 2 . n-m,\qquad n-m+s_1,\qquad n-m+s_2,\qquad1 < s_1 < s_2. n − m , n − m + s 1 , n − m + s 2 , 1 < s 1 < s 2 . Set e = gcd ( s 1 , s 2 ) e = \gcd(s_1,s_2) e = g cd( s 1 , s 2 ) . If D m ( e , k m − n ) = ∅ D_m(e,km-n) = \varnothing D m ( e , k m − n ) = ∅ , then e = s 1 e = s_1 e = s 1 , U U U is F q s 1 \mathbb F_{q^{s_1}} F q s 1 -linear, and
s 1 ∣ m , s 1 ∣ n , s 1 ∣ s 2 . s_1 \mid m,\qquad s_1 \mid n,\qquad s_1 \mid s_2. s 1 ∣ m , s 1 ∣ n , s 1 ∣ s 2 .
Antipodal 2-dimensional codes
We call a rank-metric code of length n n n antipodal if it contains a codeword of rank weight n n n . If C \mathcal{C} C is a nondegenerate [ n , 2 ] q m / q [n,2]_{q^{m}/q} [ n , 2 ] q m / q code with 0 < n ≤ m 0<n\le m 0 < n ≤ m and U U U is an associated system, then Lemma 2.2 , with h = 2 h=2 h = 2 , gives L U ≠ P G ( 1 , q m ) L_{U}\ne\mathrm{PG}(1,q^{m}) L U = PG ( 1 , q m ) ; if x ⊥ x^{\perp} x ⊥ is a point outside L U L_{U} L U , then (5) shows that x G xG x G has rank n n n . Hence every nondegenerate [ n , 2 ] q m / q [n,2]_{q^{m}/q} [ n , 2 ] q m / q code with n ≤ m n\le m n ≤ m is antipodal. More generally, by [2 Proposition 3.11] , every nondegenerate rank-metric code of length n ≤ m n\le m n ≤ m is antipodal, whatever its dimension; thus, below, the word antipodal is only a reminder of this property and imposes no extra condition.
Throughout this section, C \mathcal{C} C is a nondegenerate [ n , 2 ] q m / q [n,2]_{q^{m}/q} [ n , 2 ] q m / q code with n ≤ m n\le m n ≤ m , G G G is a generator matrix of C \mathcal{C} C and U ≤ F q m 2 U\le\mathbb{F}_{q^{m}}^{2} U ≤ F q m 2 is the associated system. We write the nonzero rank weights of C \mathcal{C} C as
d 1 < ⋯ < d r < n . d_{1}<\cdots<d_{r}<n. d 1 < ⋯ < d r < n .
Note that r ≥ 1 r\ge1 r ≥ 1 , since n > 0 n>0 n > 0 . For k = 2 k=2 k = 2 the hyperplanes of P G ( 1 , q m ) \mathrm{PG}(1,q^{m}) PG ( 1 , q m ) are points, and (5) reads
w U ( x ⊥ ) = n − w ( x G ) , x ∈ F q m 2 ∖ { 0 } . (13) w_{U}(x^{\perp})=n-w(xG),\qquad x\in\mathbb{F}_{q^{m}}^{2}\setminus\{0\}. \tag*{(13)} w U ( x ⊥ ) = n − w ( x G ) , x ∈ F q m 2 ∖ { 0 } . (13)
Hence the positive point weights of L U L_{U} L U are n − d r < ⋯ < n − d 1 n-d_{r}<\cdots<n-d_{1} n − d r < ⋯ < n − d 1 , and the minimum positive point weight of L U L_{U} L U is
a = n − d r , a=n-d_{r}, a = n − d r ,
the gap between the maximum weight and the second largest weight of C \mathcal{C} C .
For i ≥ 1 i\ge1 i ≥ 1 we denote by A i ( C ) A_{i}(\mathcal{C}) A i ( C ) the number of codewords of C \mathcal{C} C of rank weight i i i , and by N j ( U ) N_{j}(U) N j ( U ) the number of points of P G ( 1 , q m ) \mathrm{PG}(1,q^{m}) PG ( 1 , q m ) of weight j j j with respect to U U U . Since the hyperplanes of P G ( 1 , q m ) \mathrm{PG}(1,q^{m}) PG ( 1 , q m ) are its points, this agrees with the notation N j ( U ) N_{j}(U) N j ( U ) of Section 2. By (13), and since proportional nonzero vectors x x x give the same point x ⊥ x^{\perp} x ⊥ , we have A i ( C ) = ( q m − 1 ) N n − i ( U ) A_{i}(\mathcal{C})=(q^{m}-1)N_{n-i}(U) A i ( C ) = ( q m − 1 ) N n − i ( U ) for 1 ≤ i ≤ n 1\le i\le n 1 ≤ i ≤ n . Counting the nonzero codewords and applying (1) to U U U , we get, for every nondegenerate [ n , 2 ] q m / q [n,2]_{q^{m}/q} [ n , 2 ] q m / q code,
∑ i = 1 n A i ( C ) = q 2 m − 1 , ∑ i = 1 n A i ( C ) ( q n − i − 1 ) = ( q m − 1 ) ( q n − 1 ) . (14) \sum_{i=1}^{n}A_{i}(\mathcal{C})=q^{2m}-1,\qquad\sum_{i=1}^{n}A_{i}(\mathcal{C})(q^{n-i}-1)=(q^{m}-1)(q^{n}-1). \tag*{(14)} i = 1 ∑ n A i ( C ) = q 2 m − 1 , i = 1 ∑ n A i ( C ) ( q n − i − 1 ) = ( q m − 1 ) ( q n − 1 ) . (14)
These two relations will be used to compare the weight distribution of C \mathcal{C} C with the weight distributions of the codes obtained from it by puncturing or expansion.
Recall the F q \mathbb{F}_{q} F q -expansion of Definition Definition 2.8. Let t ∣ m t\mid m t ∣ m , let C t \mathcal{C}_{t} C t be an [ n t , 2 ] q m / q t \left[\frac{n}{t},2\right]_{q^{m}/q^{t}} [ t n , 2 ] q m / q t code and let C = Exp q t / q ( C t ) \mathcal{C}=\operatorname{Exp}_{q^{t}/q}(\mathcal{C}_{t}) C = Exp q t / q ( C t ) . If δ 1 < ⋯ < δ r \delta_{1}<\cdots<\delta_{r} δ 1 < ⋯ < δ r are the nonzero weights of C t \mathcal{C}_{t} C t smaller than its length n t \frac{n}{t} t n , then, since expansion multiplies every rank weight by t t t , the nonzero weights of C \mathcal{C} C are
d i = t δ i ( i = 1 , … , r ) and n . d_{i}=t\delta_{i}\quad(i=1,\ldots,r)\qquad\text{and}\qquad n. d i = t δ i ( i = 1 , … , r ) and n .
In particular,
n − d r = t ( n t − δ r ) ≥ t , n-d_{r}=t\left(\frac{n}{t}-\delta_{r}\right)\ge t, n − d r = t ( t n − δ r ) ≥ t ,
so that, if t > 1 t>1 t > 1 (that is, if the expansion is not trivial), the gap between the maximum weight and the second largest weight of C \mathcal{C} C is at least 2. The next result shows that, for q ≥ m q\ge m q ≥ m , this necessary condition is sufficient up to puncturing, i.e. every antipodal 2-dimensional code whose gap is at least 2 is obtained by deleting few coordinates from an F q \mathbb{F}_{q} F q -expansion.
Theorem 4.1. Let q ≥ m q\ge m q ≥ m and let C \mathcal{C} C be a nondegenerate [ n , 2 ] q m / q [n,2]_{q^{m}/q} [ n , 2 ] q m / q code, with 0 < n ≤ m 0<n\le m 0 < n ≤ m , whose nonzero weights are d 1 < ⋯ < d r < n d_{1}<\cdots<d_{r}<n d 1 < ⋯ < d r < n . Assume that
a = n − d r ≥ 2. a=n-d_{r}\ge2. a = n − d r ≥ 2.
Then there exists a divisor t t t of m m m with
a ≤ t ≤ min { d r , m − d r } and t ∣ d r , a \le t \le\min\{d_r,m-d_r\} \qquad\text{and}\qquad t \mid d_r, a ≤ t ≤ min { d r , m − d r } and t ∣ d r ,
and a nondegenerate antipodal [ d r + t , 2 ] q m / q [d_r+t,2]_{q^m/q} [ d r + t , 2 ] q m / q code C ′ C' C ′ , where d r + t = n + t − a ≤ m d_r+t=n+t-a\le m d r + t = n + t − a ≤ m , with the following properties.
(i) C ′ C' C ′ is, up to equivalence, the F q \mathbb{F}_q F q -expansion Exp q t / q ( C t ) \operatorname{Exp}_{q^t/q}(C_t) Exp q t / q ( C t ) of a [ d r t + 1 , 2 ] q m / q t [\frac{d_r}{t}+1,2]_{q^m/q^t} [ t d r + 1 , 2 ] q m / q t code C t C_t C t .
(ii) Up to equivalence, C C C is obtained from C ′ C' C ′ by deleting t − a t-a t − a coordinates: the map
π : C ′ ⟶ C \pi:C'\longrightarrow C π : C ′ ⟶ C
deleting the last t − a t-a t − a coordinates is an F q m \mathbb{F}_{q^m} F q m -linear bijection.
(iii) For every c ′ ∈ C ′ c'\in C' c ′ ∈ C ′ ,
w ( c ′ ) t = 1 + ⌊ w ( π ( c ′ ) ) − a t ⌋ . \frac{w(c')}{t}=1+\left\lfloor\frac{w(\pi(c'))-a}{t}\right\rfloor. t w ( c ′ ) = 1 + ⌊ t w ( π ( c ′ )) − a ⌋ .
(iv) For every c ′ ∈ C ′ c'\in C' c ′ ∈ C ′ ,
w ( c ′ ) − ( t − a ) ≤ w ( π ( c ′ ) ) ≤ w ( c ′ ) . w(c')-(t-a)\le w(\pi(c'))\le w(c'). w ( c ′ ) − ( t − a ) ≤ w ( π ( c ′ )) ≤ w ( c ′ ) .
Consequently w ( c ′ ) = t ⌈ w ( π ( c ′ ) ) / t ⌉ w(c')=t\lceil w(\pi(c'))/t\rceil w ( c ′ ) = t ⌈ w ( π ( c ′ )) / t ⌉ , every nonzero weight w w w of C C C satisfies
( w m o d t ) ∈ { 0 } ∪ { a , a + 1 , … , t − 1 } , (w\bmod t)\in\{0\}\cup\{a,a+1,\ldots,t-1\}, ( w mod t ) ∈ { 0 } ∪ { a , a + 1 , … , t − 1 } ,
and w ( π ( c ′ ) ) = n w(\pi(c'))=n w ( π ( c ′ )) = n if and only if w ( c ′ ) = d r + t w(c')=d_r+t w ( c ′ ) = d r + t .
(v) For i ≥ 1 i\ge1 i ≥ 1 , let A i ( C ) A_i(C) A i ( C ) , A i ( C ′ ) A_i(C') A i ( C ′ ) and A i ( C t ) A_i(C_t) A i ( C t ) be the numbers of codewords of rank weight i i i in C C C , C ′ C' C ′ and C t C_t C t , respectively (the weight of C t C_t C t being computed over F q t \mathbb{F}_{q^t} F q t ), and put A i ( C ) = 0 A_i(C)=0 A i ( C ) = 0 for i > n i>n i > n . Then A i ( C ′ ) = 0 A_i(C')=0 A i ( C ′ ) = 0 whenever t ∤ i t\nmid i t ∤ i and, for every j = 1 , … , ℓ j=1,\ldots,\ell j = 1 , … , ℓ , where ℓ = d r t + 1 \ell=\frac{d_r}{t}+1 ℓ = t d r + 1 ,
A j t ( C ′ ) = A j ( C t ) = ∑ i = ( j − 1 ) t + a j t A i ( C ) . (15) A_{jt}(C')=A_j(C_t)=\sum_{i=(j-1)t+a}^{jt}A_i(C). \tag*{(15)} A j t ( C ′ ) = A j ( C t ) = i = ( j − 1 ) t + a ∑ j t A i ( C ) . (15)
In particular, A d r + t ( C ′ ) = A n ( C ) A_{d_r+t}(C')=A_n(C) A d r + t ( C ′ ) = A n ( C ) , A i ( C ) ≤ A t ⌈ i / t ⌉ ( C ′ ) A_i(C)\le A_{t\lceil i/t\rceil}(C') A i ( C ) ≤ A t ⌈ i / t ⌉ ( C ′ ) for every i ≥ 1 i\ge1 i ≥ 1 , and the weight distribution of C C C satisfies, besides (14) , the relation
∑ i = 1 n A i ( C ) ( q d r + t − t ⌈ i / t ⌉ − 1 ) = ( q m − 1 ) ( q d r + t − 1 ) . (16) \sum_{i=1}^{n}A_i(C)\left(q^{d_r+t-t\lceil i/t\rceil}-1\right)=(q^m-1)(q^{d_r+t}-1). \tag*{(16)} i = 1 ∑ n A i ( C ) ( q d r + t − t ⌈ i / t ⌉ − 1 ) = ( q m − 1 ) ( q d r + t − 1 ) . (16)
(vi) If C ′ C' C ′ has s s s distinct nonzero weights, then C C C has at most ( s − 1 ) ( t − a + 1 ) + 1 (s-1)(t-a+1)+1 ( s − 1 ) ( t − a + 1 ) + 1 distinct nonzero weights.
Proof. Step 1: a larger field of linearity. Let U U U be an F q \mathbb{F}_q F q -system associated with C C C , so ⟨ U ⟩ F q m = F q m 2 \langle U\rangle_{\mathbb{F}_{q^m}}=\mathbb{F}_{q^m}^2 ⟨ U ⟩ F q m = F q m 2 and dim F q U = n ≤ m \dim_{\mathbb{F}_q}U=n\le m dim F q U = n ≤ m . By (13) , every point of L U L_U L U has weight at least a ≥ 2 a\ge2 a ≥ 2 , and a a a is attained. Since q ≥ m q\ge m q ≥ m and n ≤ m n\le m n ≤ m , Theorem 3.7 applies: there exists a divisor t ∣ m t\mid m t ∣ m such that
W = ⟨ U ⟩ F q t W=\langle U\rangle_{\mathbb{F}_{q^t}} W = ⟨ U ⟩ F q t
satisfies L W = L U L_W=L_U L W = L U and
dim F q W = n + t − a = d r + t , a ≤ t ≤ n − a = d r , t ∣ n − a = d r . \dim_{\mathbb{F}_q}W=n+t-a=d_r+t,\qquad a\le t\le n-a=d_r,\qquad t\mid n-a=d_r. dim F q W = n + t − a = d r + t , a ≤ t ≤ n − a = d r , t ∣ n − a = d r .
Since n ≤ m n \le m n ≤ m , Lemma 2.2 gives L W = L U ≠ P G ( 1 , q m ) L_W = L_U \ne\mathrm{PG}(1,q^m) L W = L U = PG ( 1 , q m ) , and applying the same lemma to W W W we get dim F q W ≤ m \dim_{\mathbb F_q} W \le m dim F q W ≤ m , that is t ≤ m − d r t \le m-d_r t ≤ m − d r . Put
ℓ = dim F q t W = d r + t t = d r t + 1 , so that n = ( ℓ − 1 ) t + a . \ell= \dim_{\mathbb F_{q^t}} W = \frac{d_r+t}{t} = \frac{d_r}{t}+1,
\qquad\text{so that}\qquad n = (\ell-1)t+a. ℓ = dim F q t W = t d r + t = t d r + 1 , so that n = ( ℓ − 1 ) t + a .
Step 2: the weights of W W W . We claim that, for every point Q Q Q of P G ( 1 , q m ) \mathrm{PG}(1,q^m) PG ( 1 , q m ) ,
w W ( Q ) = t ⌈ w U ( Q ) t ⌉ (17) w_W(Q)=t\left\lceil\frac{w_U(Q)}{t}\right\rceil \tag*{(17)} w W ( Q ) = t ⌈ t w U ( Q ) ⌉ (17)
where w W ( Q ) = dim q ( W ∩ Q ) w_W(Q)=\dim_q(W\cap Q) w W ( Q ) = dim q ( W ∩ Q ) . If Q ∉ L U = L W Q\notin L_U=L_W Q ∈ / L U = L W , both sides vanish. Otherwise, U ∩ Q ⊆ W ∩ Q U\cap Q\subseteq W\cap Q U ∩ Q ⊆ W ∩ Q , so ( W ∩ Q ) / ( U ∩ Q ) (W\cap Q)/(U\cap Q) ( W ∩ Q ) / ( U ∩ Q ) embeds into W / U W/U W / U , which has F q \mathbb F_q F q -dimension t − a t-a t − a . Therefore
w U ( Q ) ≤ w W ( Q ) ≤ w U ( Q ) + t − a . w_U(Q)\le w_W(Q)\le w_U(Q)+t-a. w U ( Q ) ≤ w W ( Q ) ≤ w U ( Q ) + t − a .
Since W W W is F q t \mathbb F_{q^t} F q t -linear and Q Q Q is an F q m \mathbb F_{q^m} F q m -subspace, W ∩ Q W\cap Q W ∩ Q is an F q t \mathbb F_{q^t} F q t -subspace, and w W ( Q ) w_W(Q) w W ( Q ) is a multiple of t t t . The least multiple of t t t which is at least w U ( Q ) w_U(Q) w U ( Q ) lies between w U ( Q ) w_U(Q) w U ( Q ) and w W ( Q ) w_W(Q) w W ( Q ) ; as the interval [ w U ( Q ) , w U ( Q ) + t − a ] [w_U(Q),w_U(Q)+t-a] [ w U ( Q ) , w U ( Q ) + t − a ] has length t − a < t t-a<t t − a < t , it contains at most one multiple of t t t , and (17) follows.
Step 3: construction of C ′ C' C ′ and proof of (i) and (ii). Let u 1 , … , u n u_1,\ldots,u_n u 1 , … , u n be an F q \mathbb F_q F q -basis of U U U and complete it to an F q \mathbb F_q F q -basis
u 1 , … , u n , w n + 1 , … , w n + t − a u_1,\ldots,u_n,w_{n+1},\ldots,w_{n+t-a} u 1 , … , u n , w n + 1 , … , w n + t − a
of W W W . Let G ′ ∈ F q m 2 × ( n + t − a ) G'\in\mathbb F_{q^m}^{2\times(n+t-a)} G ′ ∈ F q m 2 × ( n + t − a ) be the matrix having these vectors as columns, and let C ′ C' C ′ be the code generated by G ′ G' G ′ . Its columns are F q \mathbb F_q F q -linearly independent and span F q m 2 \mathbb F_{q^m}^2 F q m 2 over F q m \mathbb F_{q^m} F q m , so C ′ C' C ′ is a nondegenerate [ n + t − a , 2 ] q m / q [n+t-a,2]_{q^m/q} [ n + t − a , 2 ] q m / q code with associated system W W W ; since n + t − a ≤ m n+t-a\le m n + t − a ≤ m , it is antipodal. Since u 1 , … , u n u_1,\ldots,u_n u 1 , … , u n is an F q \mathbb F_q F q -basis of U U U , up to equivalence, the matrix G G G consisting of the first n n n columns of G ′ G' G ′ is a generator matrix of C C C . Then the map π \pi π deleting the last t − a t-a t − a coordinates satisfies
π ( x G ′ ) = x G , x ∈ F q m 2 , \pi(xG')=xG,\qquad x\in\mathbb F_{q^m}^2, π ( x G ′ ) = x G , x ∈ F q m 2 ,
and it is an F q m \mathbb F_{q^m} F q m -linear bijection, since both x ↦ x G ′ x\mapsto xG' x ↦ x G ′ and x ↦ x G x\mapsto xG x ↦ x G are isomorphisms from F q m 2 \mathbb F_{q^m}^2 F q m 2 onto C ′ C' C ′ and C C C , respectively. This proves (ii). Moreover, choosing an F q t \mathbb F_{q^t} F q t -basis of W W W and expanding it with respect to a fixed F q \mathbb F_q F q -basis of F q t \mathbb F_{q^t} F q t as in Definition 2.8, we obtain another F q \mathbb F_q F q -basis of W W W ; thus C ′ C' C ′ is equivalent to Exp q t / q ( C t ) \operatorname{Exp}_{q^t/q}(C_t) Exp q t / q ( C t ) , where C t C_t C t is the [ ℓ , 2 ] q m / q t [\ell,2]_{q^m/q^t} [ ℓ , 2 ] q m / q t code generated by the matrix whose columns are the chosen F q t \mathbb F_{q^t} F q t -basis of W W W . This proves (i).
Step 4: proof of (iii). Let x ∈ F q m 2 ∖ { 0 } x\in\mathbb F_{q^m}^2\setminus\{0\} x ∈ F q m 2 ∖ { 0 } , c ′ = x G ′ c'=xG' c ′ = x G ′ and c = π ( c ′ ) = x G c=\pi(c')=xG c = π ( c ′ ) = x G . Applying (5) to U U U and to W W W , and using (17) with Q = x ⊥ Q=x^\perp Q = x ⊥ , we get
w ( c ) = n − w U ( x ⊥ ) , w ( c ′ ) = ( n + t − a ) − w W ( x ⊥ ) = ℓ t − t ⌈ n − w ( c ) t ⌉ . w(c)=n-w_U(x^\perp),\qquad
w(c')=(n+t-a)-w_W(x^\perp)
=\ell t-t\left\lceil\frac{n-w(c)}{t}\right\rceil. w ( c ) = n − w U ( x ⊥ ) , w ( c ′ ) = ( n + t − a ) − w W ( x ⊥ ) = ℓ t − t ⌈ t n − w ( c ) ⌉ .
Since n = ( ℓ − 1 ) t + a n=(\ell-1)t+a n = ( ℓ − 1 ) t + a ,
⌈ n − w ( c ) t ⌉ = ( ℓ − 1 ) + ⌈ a − w ( c ) t ⌉ = ( ℓ − 1 ) − ⌊ w ( c ) − a t ⌋ , \left\lceil\frac{n-w(c)}{t}\right\rceil
=(\ell-1)+\left\lceil\frac{a-w(c)}{t}\right\rceil
=(\ell-1)-\left\lfloor\frac{w(c)-a}{t}\right\rfloor, ⌈ t n − w ( c ) ⌉ = ( ℓ − 1 ) + ⌈ t a − w ( c ) ⌉ = ( ℓ − 1 ) − ⌊ t w ( c ) − a ⌋ ,
and therefore
w ( c ′ ) = t + t ⌊ w ( c ) − a t ⌋ , w(c')=t+t\left\lfloor\frac{w(c)-a}{t}\right\rfloor, w ( c ′ ) = t + t ⌊ t w ( c ) − a ⌋ ,
which is (iii).
Step 5: proof of (iv). Deleting coordinates of a vector cannot increase its rank weight, hence w ( π ( c ′ ) ) ≤ w ( c ′ ) w(\pi(c'))\le w(c') w ( π ( c ′ )) ≤ w ( c ′ ) . On the other hand, by (iii),
w ( c ′ ) t ≤ 1 + w ( π ( c ′ ) ) − a t , \frac{w(c')}{t}\le1+\frac{w(\pi(c'))-a}{t}, t w ( c ′ ) ≤ 1 + t w ( π ( c ′ )) − a ,
that is, w ( c ′ ) − ( t − a ) ≤ w ( π ( c ′ ) ) w(c')-(t-a)\le w(\pi(c')) w ( c ′ ) − ( t − a ) ≤ w ( π ( c ′ )) . Now w ( c ′ ) = j t w(c')=jt w ( c ′ ) = j t for some integer j ≥ 0 j\ge0 j ≥ 0 , by (i). Then w ( π ( c ′ ) ) ∈ [ ( j − 1 ) t + a , j t ] w(\pi(c'))\in[(j-1)t+a,jt] w ( π ( c ′ )) ∈ [( j − 1 ) t + a , j t ] , and since 1 ≤ a ≤ t 1\le a\le t 1 ≤ a ≤ t this interval contains no multiple of t t t other than j t jt j t and is contained in ( ( j − 1 ) t , j t ] ((j-1)t,jt] (( j − 1 ) t , j t ] ; hence ⌈ w ( π ( c ′ ) ) / t ⌉ = j \lceil w(\pi(c'))/t\rceil=j ⌈ w ( π ( c ′ )) / t ⌉ = j , and ( w ( π ( c ′ ) ) mod t ) ∈ { 0 } ∪ { a , … , t − 1 } (w(\pi(c'))\mathbin{\operatorname{mod}} t)\in\{0\}\cup\{a,\ldots,t-1\} ( w ( π ( c ′ )) mod t ) ∈ { 0 } ∪ { a , … , t − 1 } . Since π \pi π is a bijection, every nonzero weight of C C C arises in this way. Finally, by (iii), w ( c ′ ) = ℓ t = d r + t w(c')=\ell t=d_r+t w ( c ′ ) = ℓ t = d r + t if and only if ⌊ ( w ( π ( c ′ ) ) − a ) / t ⌋ = ℓ − 1 = d r / t \lfloor(w(\pi(c'))-a)/t\rfloor=\ell-1=d_r/t ⌊( w ( π ( c ′ )) − a ) / t ⌋ = ℓ − 1 = d r / t , that is, if and only if w ( π ( c ′ ) ) ≥ d r + a = n w(\pi(c'))\ge d_r+a=n w ( π ( c ′ )) ≥ d r + a = n , i.e. w ( π ( c ′ ) ) = n w(\pi(c'))=n w ( π ( c ′ )) = n .
Step 6: proof of (v). By (i), every weight of C ′ C' C ′ is a multiple of t t t , so A i ( C ′ ) = 0 A_i(C')=0 A i ( C ′ ) = 0 if t ∤ i t\nmid i t ∤ i . Since equivalent codes have the same weight distribution and the expansion map C t → Exp q t / q ( C t ) C_t\to\operatorname{Exp}_{q^t/q}(C_t) C t → Exp q t / q ( C t ) is a bijection, multiplying every rank weight by t t t , we have A j t ( C ′ ) = A j ( C t ) A_{jt}(C')=A_j(C_t) A j t ( C ′ ) = A j ( C t ) . By (iv), w ( c ′ ) = t ⌈ w ( π ( c ′ ) ) / t ⌉ w(c')=t\lceil w(\pi(c'))/t\rceil w ( c ′ ) = t ⌈ w ( π ( c ′ )) / t ⌉ for every c ′ ∈ C ′ c'\in C' c ′ ∈ C ′ . Hence, for 1 ≤ j ≤ ℓ 1\le j\le\ell 1 ≤ j ≤ ℓ , the map π \pi π sends the codewords of C ′ C' C ′ of weight j t jt j t bijectively onto the codewords c ∈ C c\in C c ∈ C with ( j − 1 ) t < w ( c ) ≤ j t (j-1)t<w(c)\le jt ( j − 1 ) t < w ( c ) ≤ j t , and by the residue condition in (iv) the weights of these codewords lie in [ ( j − 1 ) t + a , j t ] [(j-1)t+a,jt] [( j − 1 ) t + a , j t ] . This gives (15) . For j = ℓ j=\ell j = ℓ the interval is [ n , d r + t ] [n,d_r+t] [ n , d r + t ] , because ( ℓ − 1 ) t + a = d r + a = n (\ell-1)t+a=d_r+a=n ( ℓ − 1 ) t + a = d r + a = n , and therefore A d r + t ( C ′ ) = A n ( C ) A_{d_r+t}(C')=A_n(C) A d r + t ( C ′ ) = A n ( C ) .
The inequality A i ( C ) ≤ A t ⌈ i / t ⌉ ( C ′ ) A_i(C)\le A_{t\lceil i/t\rceil}(C') A i ( C ) ≤ A t ⌈ i / t ⌉ ( C ′ ) is clear, since A i ( C ) A_i(C) A i ( C ) is one of the summands of the formula with j = ⌈ i / t ⌉ j=\lceil i/t\rceil j = ⌈ i / t ⌉ . Finally, C ′ C' C ′ is a nondegenerate [ d r + t , 2 ] q m / q [d_r+t,2]_{q^m/q} [ d r + t , 2 ] q m / q code, so the second relation in (14) applied to C ′ C' C ′ gives
∑ j = 1 ℓ A j t ( C ′ ) ( q d r + t − j t − 1 ) = ( q m − 1 ) ( q d r + t − 1 ) . \sum_{j=1}^{\ell} A_{jt}(C')\left(q^{d_r+t-jt}-1\right)=(q^m-1)\left(q^{d_r+t}-1\right). j = 1 ∑ ℓ A j t ( C ′ ) ( q d r + t − j t − 1 ) = ( q m − 1 ) ( q d r + t − 1 ) .
Replacing A j t ( C ′ ) A_{jt}(C') A j t ( C ′ ) by ∑ ⌈ i / t ⌉ = j A i ( C ) \sum_{\lceil i/t\rceil=j}A_i(C) ∑ ⌈ i / t ⌉ = j A i ( C ) we obtain (16) .
Step 7: proof of (vi). By (v), the codewords of C ′ C' C ′ of weight j t jt j t are mapped by π \pi π to codewords of C C C whose weights lie in { j t − ( t − a ) , … , j t } \{jt-(t-a),\ldots,jt\} { j t − ( t − a ) , … , j t } , a set of t − a + 1 t-a+1 t − a + 1 integers, while the codewords of maximum weight d r + t d_r+t d r + t are mapped exactly onto the codewords of weight n n n . Since π \pi π is a bijection, C C C has at most ( s − 1 ) ( t − a + 1 ) + 1 (s-1)(t-a+1)+1 ( s − 1 ) ( t − a + 1 ) + 1 distinct nonzero weights.
We now specialize to three-weight codes.
Corollary 4.3. Let q ≥ m q\ge m q ≥ m and let C C C be a nondegenerate [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code, with n ≤ m n\le m n ≤ m , whose nonzero weights are d < w < n d<w<n d < w < n , and assume that n − w ≥ 2 n-w\ge2 n − w ≥ 2 . Then there exists a divisor t t t of m m m with
n − w ≤ t ≤ min { w , m − w } and t ∣ w , n-w\le t\le\min\{w,m-w\}\qquad\text{and}\qquad t\mid w, n − w ≤ t ≤ min { w , m − w } and t ∣ w , such that the following hold.
(i) d ≥ n − w d \ge n-w d ≥ n − w .
(ii) Either t ∣ d t \mid d t ∣ d , or ( d m o d t ) ≥ n − w (d \bmod t) \ge n-w ( d mod t ) ≥ n − w .
(iii) C C C is obtained, up to equivalence, by deleting t − n + w t-n+w t − n + w coordinates from Exp q t / q ( C t ) \operatorname{Exp}_{q^t/q}(C_t) Exp q t / q ( C t ) , where C t C_t C t is a [ w t + 1 , 2 ] q m / q t \left[\frac{w}{t}+1,2\right]_{q^m/q^t} [ t w + 1 , 2 ] q m / q t code whose nonzero weights are the distinct values among
⌈ d t ⌉ , w t , w t + 1. \left\lceil\frac{d}{t}\right\rceil,\qquad\frac{w}{t},\qquad\frac{w}{t}+1. ⌈ t d ⌉ , t w , t w + 1.
More precisely, the puncturing map sends the codewords of Exp q t / q ( C t ) \operatorname{Exp}_{q^t/q}(C_t) Exp q t / q ( C t ) of weight w + t w+t w + t bijectively onto the codewords of C C C of weight n n n ; if d ≤ w − t d \le w-t d ≤ w − t , it sends those of weight t ⌈ d / t ⌉ t\lceil d/t\rceil t ⌈ d / t ⌉ and w w w bijectively onto those of weight d d d and w w w , respectively, whereas if d > w − t d>w-t d > w − t it sends the codewords of weight w w w bijectively onto the codewords of weight d d d or w w w . In particular, C t C_t C t has at most three nonzero weights, and exactly two if d > w − t d>w-t d > w − t .
(iv) Let C ′ = Exp q t / q ( C t ) C'=\operatorname{Exp}_{q^t/q}(C_t) C ′ = Exp q t / q ( C t ) and put
E = w + t − t ⌈ d t ⌉ . E=w+t-t\left\lceil\frac{d}{t}\right\rceil. E = w + t − t ⌈ t d ⌉ .
The weight distributions of C C C , C ′ C' C ′ and C t C_t C t are related by A j t ( C ′ ) = A j ( C t ) A_{jt}(C')=A_j(C_t) A j t ( C ′ ) = A j ( C t ) for every j j j , A w + t ( C ′ ) = A n ( C ) A_{w+t}(C')=A_n(C) A w + t ( C ′ ) = A n ( C ) , and
A t ⌈ d / t ⌉ ( C ′ ) = A d ( C ) , A w ( C ′ ) = A w ( C ) , if d ≤ w − t , A w ( C ′ ) = A d ( C ) + A w ( C ) , if d > w − t . \begin{aligned}
A_{t\lceil d/t\rceil}(C')&=A_d(C),\qquad A_w(C')=A_w(C), &&\text{if }d\le w-t,\\
A_w(C')&=A_d(C)+A_w(C), &&\text{if }d>w-t.
\end{aligned} A t ⌈ d / t ⌉ ( C ′ ) A w ( C ′ ) = A d ( C ) , A w ( C ′ ) = A w ( C ) , = A d ( C ) + A w ( C ) , if d ≤ w − t , if d > w − t .
If moreover t > n − w t>n-w t > n − w , that is, if at least one coordinate is deleted, then
Δ = ( q n − d − 1 ) ( q t − 1 ) − ( q n − w − 1 ) ( q E − 1 ) ≠ 0 \Delta=(q^{n-d}-1)(q^t-1)-(q^{n-w}-1)(q^E-1)\ne0 Δ = ( q n − d − 1 ) ( q t − 1 ) − ( q n − w − 1 ) ( q E − 1 ) = 0
and the weight distribution of C C C is determined by q , m , n , d , w q,m,n,d,w q , m , n , d , w and t t t :
A d ( C ) = q m − 1 Δ [ ( q n − 1 ) ( q t − 1 ) − ( q n − w − 1 ) ( q w + t − 1 ) ] , A_d(C)=\frac{q^m-1}{\Delta}\left[(q^n-1)(q^t-1)-(q^{n-w}-1)(q^{w+t}-1)\right], A d ( C ) = Δ q m − 1 [ ( q n − 1 ) ( q t − 1 ) − ( q n − w − 1 ) ( q w + t − 1 ) ] ,
A w ( C ) = q m − 1 Δ [ ( q n − d − 1 ) ( q w + t − 1 ) − ( q E − 1 ) ( q n − 1 ) ] , A_w(C)=\frac{q^m-1}{\Delta}\left[(q^{n-d}-1)(q^{w+t}-1)-(q^E-1)(q^n-1)\right], A w ( C ) = Δ q m − 1 [ ( q n − d − 1 ) ( q w + t − 1 ) − ( q E − 1 ) ( q n − 1 ) ] ,
A n ( C ) = q 2 m − 1 − A d ( C ) − A w ( C ) . A_n(C)=q^{2m}-1-A_d(C)-A_w(C). A n ( C ) = q 2 m − 1 − A d ( C ) − A w ( C ) .
In particular, if d > w − t d>w-t d > w − t , then E = t E=t E = t and A d ( C ) + A w ( C ) = ( q m − 1 ) q w + t − 1 q t − 1 A_d(C)+A_w(C)=(q^m-1)\frac{q^{w+t}-1}{q^t-1} A d ( C ) + A w ( C ) = ( q m − 1 ) q t − 1 q w + t − 1 .
(v) If n = m n=m n = m , or more generally if no divisor s s s of m m m satisfies n − w < s ≤ min { w , m − w } n-w<s\le\min\{w,m-w\} n − w < s ≤ min { w , m − w } and s ∣ w s\mid w s ∣ w , then t = n − w t=n-w t = n − w and
n − w ∣ m , n − w ∣ n , n − w ∣ d , n − w ∣ w ; n-w\mid m,\qquad n-w\mid n,\qquad n-w\mid d,\qquad n-w\mid w; n − w ∣ m , n − w ∣ n , n − w ∣ d , n − w ∣ w ;
moreover, C C C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n n − w , 2 ] q m / q n − w \left[\frac{n}{n-w},2\right]_{q^m/q^{n-w}} [ n − w n , 2 ] q m / q n − w code with nonzero weights
d n − w , w n − w , n n − w . \frac{d}{n-w},\qquad\frac{w}{n-w},\qquad\frac{n}{n-w}. n − w d , n − w w , n − w n .
Proof. Apply Theorem 4.1 with r = 2 r=2 r = 2 , d 1 = d d_1=d d 1 = d , d 2 = w d_2=w d 2 = w and a = n − w a=n-w a = n − w . Assertion (i) is Remark 4.2 (a), and (ii) is the residue condition of Theorem 4.1 (iv) applied to d d d . For (iii), Theorem 4.1 (iv) shows that a codeword c ′ c' c ′ with π ( c ′ ) \pi(c') π ( c ′ ) of weight d d d , w w w or n n n has weight t ⌈ d / t ⌉ t\lceil d/t\rceil t ⌈ d / t ⌉ , t ⌈ w / t ⌉ = w t\lceil w/t\rceil=w t ⌈ w / t ⌉ = w or t ⌈ n / t ⌉ = w + t t\lceil n/t\rceil=w+t t ⌈ n / t ⌉ = w + t , respectively, the last equality because n = w + a n=w+a n = w + a with t ∣ w t\mid w t ∣ w and 1 ≤ a ≤ t 1 \le a \le t 1 ≤ a ≤ t . Since π \pi π is a bijection and expansion multiplies weights by t t t , the weights of C t C_t C t are as stated. As ⌈ d / t ⌉ ≤ w / t \lceil d/t \rceil\le w/t ⌈ d / t ⌉ ≤ w / t , with equality if and only if d > w − t d > w-t d > w − t , the last claim of (iii) follows.
For (iv), recall that the nonzero weights of C C C are d d d , w w w and n = w + a n = w+a n = w + a , with a = n − w a = n-w a = n − w . By Theorem 4.1 (v), A j t ( C ′ ) = A j ( C t ) A_{jt}(C') = A_j(C_t) A j t ( C ′ ) = A j ( C t ) is the number of codewords of C C C whose weight lies in [ ( j − 1 ) t + a , j t ] [(j-1)t+a,jt] [( j − 1 ) t + a , j t ] . The weight d d d lies in the block j = ⌈ d / t ⌉ j = \lceil d/t \rceil j = ⌈ d / t ⌉ , the weight w w w in the block j = w / t j = w/t j = w / t and the weight n n n in the block j = w / t + 1 j = w/t+1 j = w / t + 1 ; the first two blocks coincide if and only if ⌈ d / t ⌉ = w / t \lceil d/t \rceil= w/t ⌈ d / t ⌉ = w / t , that is, if and only if d > w − t d > w-t d > w − t . This proves the relations between the weight distributions. Now put α = A d ( C ) / ( q m − 1 ) \alpha= A_d(C)/(q^m-1) α = A d ( C ) / ( q m − 1 ) , β = A w ( C ) / ( q m − 1 ) \beta= A_w(C)/(q^m-1) β = A w ( C ) / ( q m − 1 ) and D = n − d D = n-d D = n − d . The second relation in (14) and the last relation in Theorem 4.1 (v), where d r = w d_r = w d r = w , t ⌈ w / t ⌉ = w t\lceil w/t \rceil= w t ⌈ w / t ⌉ = w and t ⌈ n / t ⌉ = w + t t\lceil n/t \rceil= w+t t ⌈ n / t ⌉ = w + t , give the linear system
α ( q D − 1 ) + β ( q a − 1 ) = q n − 1 , α ( q E − 1 ) + β ( q t − 1 ) = q w + t − 1 \alpha(q^D-1)+\beta(q^a-1)=q^n-1,\qquad\alpha(q^E-1)+\beta(q^t-1)=q^{w+t}-1 α ( q D − 1 ) + β ( q a − 1 ) = q n − 1 , α ( q E − 1 ) + β ( q t − 1 ) = q w + t − 1
whose determinant is Δ \Delta Δ . Assume t > a t>a t > a . Since d < w d<w d < w and ⌈ d / t ⌉ ≤ w / t \lceil d/t \rceil\le w/t ⌈ d / t ⌉ ≤ w / t , we have D > a D>a D > a and E ≥ t > a E\ge t>a E ≥ t > a . If Δ = 0 \Delta=0 Δ = 0 , then expanding and dividing by q a q^a q a we would get
q D + t − a − q D − a − q t − a = q E − q E − a − 1 q^{D+t-a}-q^{D-a}-q^{t-a}=q^E-q^{E-a}-1 q D + t − a − q D − a − q t − a = q E − q E − a − 1
where all the exponents are positive; the left-hand side is divisible by q q q , while the right-hand side is congruent to − 1 -1 − 1 modulo q q q , a contradiction. Hence Δ ≠ 0 \Delta\ne0 Δ = 0 , and Cramer’s rule gives A d ( C ) A_d(C) A d ( C ) and A w ( C ) A_w(C) A w ( C ) ; A n ( C ) A_n(C) A n ( C ) follows from the first relation in (14) . If d > w − t d>w-t d > w − t , then t ⌈ d / t ⌉ = w t\lceil d/t\rceil=w t ⌈ d / t ⌉ = w , so E = t E=t E = t and the second equation reads ( α + β ) ( q t − 1 ) = q w + t − 1 (\alpha+\beta)(q^t-1)=q^{w+t}-1 ( α + β ) ( q t − 1 ) = q w + t − 1 . Note that, when t = a t=a t = a , the two equations coincide, since E = D E=D E = D and C = C ′ C=C' C = C ′ .
Finally, under the hypotheses of (v), Remark 4.2 (c),(d) gives t = n − w t=n-w t = n − w ; then (ii) forces t ∣ d t\mid d t ∣ d , because { a , … , t − 1 } = ∅ \{a,\ldots,t-1\}=\varnothing { a , … , t − 1 } = ∅ , and Remark 4.2 (b) gives the remaining assertions.
Families of three-weight antipodal 2-dimensional codes
In this subsection C C C is a nondegenerate three-weight [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code, with n ≤ m n\le m n ≤ m and nonzero weights d < w < n d<w<n d < w < n , and U U U is its associated q q q -system. We call
g 1 = n − w and g 2 = w − d g_1=n-w \qquad\text{and}\qquad g_2=w-d g 1 = n − w and g 2 = w − d
the first gap (between the maximum and the second largest weight) and the second gap (between the second largest and the minimum weight) of C C C . By Corollary 4.3, if q ≥ m q\ge m q ≥ m and g 1 ≥ 2 g_1\ge2 g 1 ≥ 2 , the first gap forces strong arithmetic restrictions: there is a divisor t t t of m m m with g 1 ≤ t ≤ min { w , m − w } g_1\le t\le\min\{w,m-w\} g 1 ≤ t ≤ min { w , m − w } and t ∣ w t\mid w t ∣ w , so that in particular gcd ( w , m ) ≥ 2 \gcd(w,m)\ge2 g cd( w , m ) ≥ 2 , and if t > g 1 t>g_1 t > g 1 the weight distribution of C C C is determined by its parameters. We now describe some families of examples, which exist for every prime power q q q , showing different behaviours of the two gaps. By (13) , constructing C C C amounts to constructing an n n n -dimensional F q \mathbb{F}_q F q -subspace U U U of F q m 2 \mathbb{F}_{q^m}^2 F q m 2 , with ( U / U ∩ F q m ) ≅ F q m 2 (U/U\cap\mathbb{F}_{q^m})\cong\mathbb{F}_{q^m}^2 ( U / U ∩ F q m ) ≅ F q m 2 , whose point weights take exactly the three values 0 < n − w < n − d 0<n-w<n-d 0 < n − w < n − d ; the weight distribution of C C C is then given by A i ( C ) = ( q m − 1 ) N n − i ( U ) A_i(C)=(q^m-1)N_{n-i}(U) A i ( C ) = ( q m − 1 ) N n − i ( U ) .
We shall use the following terminology. Let t ∣ m t\mid m t ∣ m . An F q t \mathbb{F}_{q^t} F q t -subspace U ′ U' U ′ of F q m 2 \mathbb{F}_{q^m}^2 F q m 2 is F q t \mathbb{F}_{q^t} F q t -scattered if dim F q t ( U ′ ∩ P ) ≤ 1 \dim_{\mathbb{F}_{q^t}}(U'\cap P)\le1 dim F q t ( U ′ ∩ P ) ≤ 1 for every point P P P of PG ( 1 , q m ) \operatorname{PG}(1,q^m) PG ( 1 , q m ) ; for t = 1 t=1 t = 1 we simply say that U ′ U' U ′ is scattered, that is, all its points have weight at most one. For i ≥ 2 i\ge2 i ≥ 2 , an i i i -club of rank N N N is an F q \mathbb{F}_q F q -linear set L U ′ ⊆ PG ( 1 , q m ) L_{U'}\subseteq\operatorname{PG}(1,q^m) L U ′ ⊆ PG ( 1 , q m ) of rank N N N having exactly one point of weight i i i , called its head , all the other points of L U ′ L_{U'} L U ′ having weight one.
For every t ∣ m t\mid m t ∣ m , the F q t \mathbb{F}_{q^t} F q t -subspace
{ ( x , x q t ) : x ∈ F q m } \{(x,x^{q^t}):x\in\mathbb{F}_{q^m}\} {( x , x q t ) : x ∈ F q m }
of F q m 2 \mathbb{F}_{q^m}^2 F q m 2 is F q t \mathbb{F}_{q^t} F q t -scattered: if ( x , x q t ) (x,x^{q^t}) ( x , x q t ) and ( y , y q t ) (y,y^{q^t}) ( y , y q t ) , with x y ≠ 0 xy\ne0 x y = 0 , define the same point, then ( y / x ) q t − 1 = 1 (y/x)^{q^t-1}=1 ( y / x ) q t − 1 = 1 , i.e. y / x ∈ F q t y/x\in\mathbb{F}_{q^t} y / x ∈ F q t . Since an F q t \mathbb{F}_{q^t} F q t -subspace of an F q t \mathbb{F}_{q^t} F q t -scattered subspace is again F q t \mathbb{F}_{q^t} F q t -scattered, for every ℓ ≤ m / t \ell\le m/t ℓ ≤ m / t there exist F q t \mathbb{F}_{q^t} F q t -scattered subspaces of F q m 2 \mathbb{F}_{q^m}^2 F q m 2 of F q t \mathbb{F}_{q^t} F q t -dimension ℓ \ell ℓ .
Example 4.4 (Family F 1 \mathcal{F}_1 F 1 : three consecutive weights). Let 3 ≤ n ≤ m 3 \le n \le m 3 ≤ n ≤ m . Let U ′ ≤ F q F q m 2 U' \le_{\mathbb{F}_q} \mathbb{F}_{q^m}^2 U ′ ≤ F q F q m 2 be a scattered subspace with dim F q U ′ = n − 1 \dim_{\mathbb{F}_q} U' = n - 1 dim F q U ′ = n − 1 , fix u ~ ∈ U ′ ∖ { 0 } \tilde{u} \in U' \setminus\{0\} u ~ ∈ U ′ ∖ { 0 } and λ ∈ F q m ∖ F q \lambda\in\mathbb{F}_{q^m} \setminus\mathbb{F}_q λ ∈ F q m ∖ F q . Since U ′ ∩ ⟨ u ~ ⟩ F q m = ⟨ u ~ ⟩ F q U' \cap\langle\tilde{u}\rangle_{\mathbb{F}_{q^m}} = \langle\tilde{u}\rangle_{\mathbb{F}_q} U ′ ∩ ⟨ u ~ ⟩ F q m = ⟨ u ~ ⟩ F q , we have λ u ~ ∉ U ′ \lambda\tilde{u} \notin U' λ u ~ ∈ / U ′ , and we put
U = U ′ ⊕ ⟨ λ u ~ ⟩ F q , dim F q U = n . U = U' \oplus\langle\lambda\tilde{u}\rangle_{\mathbb{F}_q}, \qquad\dim_{\mathbb{F}_q} U = n. U = U ′ ⊕ ⟨ λ u ~ ⟩ F q , dim F q U = n .
Then:
w U ( ⟨ u ~ ⟩ F q m ) = 2 w_U(\langle\tilde{u}\rangle_{\mathbb{F}_{q^m}}) = 2 w U (⟨ u ~ ⟩ F q m ) = 2 , since u ~ \tilde{u} u ~ and λ u ~ \lambda\tilde{u} λ u ~ are F q \mathbb{F}_q F q -independent;
w U ( P ) ≤ w U ′ ( P ) + 1 ≤ 2 w_U(P) \le w_{U'}(P) + 1 \le2 w U ( P ) ≤ w U ′ ( P ) + 1 ≤ 2 for every point P P P , since U ′ U' U ′ is an F q \mathbb{F}_q F q -hyperplane of U U U ;
there are points of weight zero, by Lemma 2.2 , since n ≤ m n \le m n ≤ m ;
there are points of weight one. Otherwise every point of L U L_U L U would have weight two, and ∣ L U ∣ = ( q n − 1 ) / ( q 2 − 1 ) |L_U| = (q^n - 1)/(q^2 - 1) ∣ L U ∣ = ( q n − 1 ) / ( q 2 − 1 ) ; moreover every 2 2 2 -dimensional subspace U ∩ P U \cap P U ∩ P would meet the hyperplane U ′ U' U ′ nontrivially, so that L U = L U ′ L_U = L_{U'} L U = L U ′ and ∣ L U ∣ = ( q n − 1 − 1 ) / ( q − 1 ) |L_U| = (q^{n-1} - 1)/(q - 1) ∣ L U ∣ = ( q n − 1 − 1 ) / ( q − 1 ) . These two values coincide only for n = 2 n = 2 n = 2 .
Since U ′ U' U ′ is scattered of rank n − 1 ≥ 2 n - 1 \ge2 n − 1 ≥ 2 , it is not contained in a point, so ⟨ U ⟩ F q m = F q m 2 \langle U\rangle_{\mathbb{F}_{q^m}} = \mathbb{F}_{q^m}^2 ⟨ U ⟩ F q m = F q m 2 . Therefore the code C C C associated with U U U is a nondegenerate [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code with nonzero weights
n − 2 , n − 1 , n , g 1 = g 2 = 1. n - 2,\qquad n - 1,\qquad n,\qquad g_1 = g_2 = 1. n − 2 , n − 1 , n , g 1 = g 2 = 1.
If ν = N 2 ( U ) ≥ 1 \nu= N_2(U) \ge1 ν = N 2 ( U ) ≥ 1 , then (1) gives N 1 ( U ) = q n − 1 − 1 q − 1 − ( q + 1 ) ν N_1(U) = \frac{q^{n-1} - 1}{q - 1} - (q + 1)\nu N 1 ( U ) = q − 1 q n − 1 − 1 − ( q + 1 ) ν , hence
A n − 2 ( C ) = ( q m − 1 ) ν , A n − 1 ( C ) = ( q m − 1 ) ( q n − 1 − 1 q − 1 − ( q + 1 ) ν ) . A_{n-2}(C) = (q^m - 1)\nu,\qquad A_{n-1}(C) = (q^m - 1)\left(\frac{q^{n-1} - 1}{q - 1} - (q + 1)\nu\right). A n − 2 ( C ) = ( q m − 1 ) ν , A n − 1 ( C ) = ( q m − 1 ) ( q − 1 q n − 1 − 1 − ( q + 1 ) ν ) .
Thus, for every q q q , every m ≥ 3 m \ge3 m ≥ 3 and every 3 ≤ n ≤ m 3 \le n \le m 3 ≤ n ≤ m , there exists an antipodal three-weight [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code with no gaps.
The next family relies on the following explicit club.
Example 4.5. Let m ≥ 3 m \ge3 m ≥ 3 , let λ ∈ F q m \lambda\in\mathbb{F}_{q^m} λ ∈ F q m with F q m = F q ( λ ) \mathbb{F}_{q^m} = \mathbb{F}_q(\lambda) F q m = F q ( λ ) , and let
U ′ = { ( a 0 + a 1 λ + ⋯ + a m − 2 λ m − 2 , a m − 2 + a m − 1 λ ) : a 0 , … , a m − 1 ∈ F q } . U' = \left\{\left(a_0 + a_1\lambda+ \cdots+ a_{m-2}\lambda^{m-2},\ a_{m-2} + a_{m-1}\lambda\right) : a_0,\ldots,a_{m-1} \in\mathbb{F}_q\right\}. U ′ = { ( a 0 + a 1 λ + ⋯ + a m − 2 λ m − 2 , a m − 2 + a m − 1 λ ) : a 0 , … , a m − 1 ∈ F q } .
Then dim F q U ′ = m \dim_{\mathbb{F}_q} U' = m dim F q U ′ = m , dim F q ( U ′ ∩ ⟨ ( 1 , 0 ) ⟩ F q m ) = m − 2 \dim_{\mathbb{F}_q}(U' \cap\langle(1,0)\rangle_{\mathbb{F}_{q^m}}) = m - 2 dim F q ( U ′ ∩ ⟨( 1 , 0 ) ⟩ F q m ) = m − 2 and w U ′ ( P ) ≤ 1 w_{U'}(P) \le1 w U ′ ( P ) ≤ 1 for every point P ≠ ⟨ ( 1 , 0 ) ⟩ F q m P \ne\langle(1,0)\rangle_{\mathbb{F}_{q^m}} P = ⟨( 1 , 0 ) ⟩ F q m . In particular, for m ≥ 4 m \ge4 m ≥ 4 , L U ′ L_{U'} L U ′ is an ( m − 2 ) (m - 2) ( m − 2 ) -club of rank m m m with head ⟨ ( 1 , 0 ) ⟩ F q m \langle(1,0)\rangle_{\mathbb{F}_{q^m}} ⟨( 1 , 0 ) ⟩ F q m (see [8 Lemma 2.12] ).
Example 4.6 (Family F 2 \mathcal{F}_2 F 2 : weights 2 2 2 , n − 1 n - 1 n − 1 , n n n ). Let 4 ≤ n ≤ m 4 \le n \le m 4 ≤ n ≤ m and let U ′ U' U ′ be as in Example 4.5. Put S m − 2 = U ′ ∩ ⟨ ( 1 , 0 ) ⟩ F q m S_{m-2} = U' \cap\langle(1,0)\rangle_{\mathbb{F}_{q^m}} S m − 2 = U ′ ∩ ⟨( 1 , 0 ) ⟩ F q m , choose an ( n − 2 ) (n - 2) ( n − 2 ) -dimensional F q \mathbb{F}_q F q -subspace S n − 2 ≤ S m − 2 S_{n-2} \le S_{m-2} S n − 2 ≤ S m − 2 , and choose u 1 , u 2 ∈ U ′ u_1,u_2 \in U' u 1 , u 2 ∈ U ′ with ⟨ u 1 , u 2 ⟩ F q ∩ S m − 2 = { 0 } \langle u_1,u_2\rangle_{\mathbb{F}_q} \cap S_{m-2} = \{0\} ⟨ u 1 , u 2 ⟩ F q ∩ S m − 2 = { 0 } (for instance u 1 = ( λ m − 2 , 1 ) u_1 = (\lambda^{m-2},1) u 1 = ( λ m − 2 , 1 ) and u 2 = ( 0 , λ ) u_2 = (0,\lambda) u 2 = ( 0 , λ ) ). Let
U n = S n − 2 ⊕ ⟨ u 1 , u 2 ⟩ F q . U_n = S_{n-2} \oplus\langle u_1,u_2\rangle_{\mathbb{F}_q}. U n = S n − 2 ⊕ ⟨ u 1 , u 2 ⟩ F q .
For instance, with the choices above and S n − 2 = { ( a 0 + ⋯ + a n − 3 λ n − 3 , 0 ) : a i ∈ F q } S_{n-2} = \{(a_0 + \cdots+ a_{n-3}\lambda^{n-3},0) : a_i \in\mathbb{F}_q\} S n − 2 = {( a 0 + ⋯ + a n − 3 λ n − 3 , 0 ) : a i ∈ F q } ,
U n = { ( a 0 + a 1 λ + ⋯ + a n − 3 λ n − 3 + a m − 2 λ m − 2 , a m − 2 + a m − 1 λ ) : a i ∈ F q } . U_n = \left\{\left(a_0 + a_1\lambda+ \cdots+ a_{n-3}\lambda^{n-3} + a_{m-2}\lambda^{m-2},\ a_{m-2} + a_{m-1}\lambda\right) : a_i \in\mathbb{F}_q\right\}. U n = { ( a 0 + a 1 λ + ⋯ + a n − 3 λ n − 3 + a m − 2 λ m − 2 , a m − 2 + a m − 1 λ ) : a i ∈ F q } .
Then dim F q U n = n \dim_{\mathbb{F}_q} U_n = n dim F q U n = n and U n ∩ ⟨ ( 1 , 0 ) ⟩ F q m = S n − 2 U_n \cap\langle(1,0)\rangle_{\mathbb{F}_{q^m}} = S_{n-2} U n ∩ ⟨( 1 , 0 ) ⟩ F q m = S n − 2 , because an element s + α u 1 + β u 2 s + \alpha u_1 + \beta u_2 s + α u 1 + β u 2 of U n U_n U n in ⟨ ( 1 , 0 ) ⟩ F q m \langle(1,0)\rangle_{\mathbb{F}_{q^m}} ⟨( 1 , 0 ) ⟩ F q m lies in S m − 2 S_{m-2} S m − 2 , which forces α u 1 + β u 2 ∈ S m − 2 \alpha u_1 + \beta u_2 \in S_{m-2} α u 1 + β u 2 ∈ S m − 2 , hence α = β = 0 \alpha= \beta= 0 α = β = 0 . Since U n ≤ U ′ U_n \le U' U n ≤ U ′ , every other point has weight at most one; the point ⟨ u 1 ⟩ F q m \langle u_1\rangle_{\mathbb{F}_{q^m}} ⟨ u 1 ⟩ F q m has weight one and, as n ≤ m n \le m n ≤ m , there are points of weight zero. So L U n L_{U_n} L U n is an ( n − 2 ) (n - 2) ( n − 2 ) -club of rank n n n , and the associated code C C C is a nondegenerate [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code with nonzero weights
2 , n − 1 , n , g 1 = 1 , g 2 = n − 3. 2,\qquad n - 1,\qquad n,\qquad g_1 = 1,\qquad g_2 = n - 3. 2 , n − 1 , n , g 1 = 1 , g 2 = n − 3.
By (1) , N n − 2 ( U n ) = 1 N_{n-2}(U_n)=1 N n − 2 ( U n ) = 1 and N 1 ( U n ) = q n − q n − 2 q − 1 = q n − 2 ( q + 1 ) N_1(U_n)=\frac{q^n-q^{n-2}}{q-1}=q^{n-2}(q+1) N 1 ( U n ) = q − 1 q n − q n − 2 = q n − 2 ( q + 1 ) , so
A 2 ( C ) = q m − 1 , A n − 1 ( C ) = ( q m − 1 ) q n − 2 ( q + 1 ) , A_2(C)=q^m-1,\qquad A_{n-1}(C)=(q^m-1)q^{n-2}(q+1), A 2 ( C ) = q m − 1 , A n − 1 ( C ) = ( q m − 1 ) q n − 2 ( q + 1 ) ,
and A n ( C ) = q 2 m − 1 − ( q m − 1 ) ( 1 + q n − 2 ( q + 1 ) ) A_n(C)=q^{2m}-1-(q^m-1)(1+q^{n-2}(q+1)) A n ( C ) = q 2 m − 1 − ( q m − 1 ) ( 1 + q n − 2 ( q + 1 )) . For n = 3 n=3 n = 3 the construction still works, but the weights 2 2 2 and n − 1 n-1 n − 1 coincide. For n ≥ 5 n\geq5 n ≥ 5 the second gap is at least two, and it can be as large as m − 3 m-3 m − 3 ; however, unlike the first gap in Corollary 4.3, a large second gap does not impose any restriction on the parameters: the construction is valid for every q q q and every 4 ≤ n ≤ m 4\leq n\leq m 4 ≤ n ≤ m .
Remark 4.7. More generally, if L U ′ L_{U'} L U ′ is an i i i -club of rank N ≤ m N\leq m N ≤ m in P G ( 1 , q m ) \mathrm{PG}(1,q^m) PG ( 1 , q m ) , with 2 ≤ i ≤ N − 1 2\leq i\leq N-1 2 ≤ i ≤ N − 1 , then by (13) the code associated with U ′ U' U ′ is a nondegenerate [ N , 2 ] q m / q [N,2]_{q^m/q} [ N , 2 ] q m / q code with nonzero weights
N − i , N − 1 , N , g 1 = 1 , g 2 = i − 1 , N-i,\qquad N-1,\qquad N,\qquad g_1=1,\qquad g_2=i-1, N − i , N − 1 , N , g 1 = 1 , g 2 = i − 1 ,
and, by (1) , A N − i = q m − 1 A_{N-i}=q^m-1 A N − i = q m − 1 and A N − 1 = ( q m − 1 ) q N − q i q − 1 A_{N-1}=(q^m-1)\frac{q^N-q^i}{q-1} A N − 1 = ( q m − 1 ) q − 1 q N − q i . The procedure of Example 4.6 produces new clubs from a given one: if L U ′ L_{U'} L U ′ is an i i i -club of rank m m m with head P P P , S ≤ U ′ ∩ P S\leq U'\cap P S ≤ U ′ ∩ P has dimension j ≥ 2 j\geq2 j ≥ 2 and T ≤ U ′ T\leq U' T ≤ U ′ has dimension s ≥ 1 s\geq1 s ≥ 1 with T ∩ P = { 0 } T\cap P=\{0\} T ∩ P = { 0 } (so that s ≤ m − i s\leq m-i s ≤ m − i ), then L S ⊕ T L_{S\oplus T} L S ⊕ T is a j j j -club of rank j + s j+s j + s . For instance, starting from the ( m − 1 ) (m-1) ( m − 1 ) -club { ( x , Tr q m / q ( x ) ) : x ∈ F q m } \{(x,\operatorname{Tr}_{q^m/q}(x)):x\in\mathbb{F}_{q^m}\} {( x , Tr q m / q ( x )) : x ∈ F q m } one obtains ( n − 1 ) (n-1) ( n − 1 ) -clubs of rank n n n , hence codes with weights 1 , n − 1 , n 1,n-1,n 1 , n − 1 , n , for every 3 ≤ n ≤ m 3\leq n\leq m 3 ≤ n ≤ m . For the existence of i i i -clubs of given rank in P G ( 1 , q m ) \mathrm{PG}(1,q^m) PG ( 1 , q m ) see [11 ] and the references therein.
Example 4.8 (Family F 3 \mathcal{F}_3 F 3 : weights a a a , 2 a − 1 2a-1 2 a − 1 , 2 a 2a 2 a ). Let m m m be even. By [12 Theorem 4.5] , for every q q q there exists an m m m -dimensional F q \mathbb{F}_q F q -subspace U ′ ≤ F q m 2 U'\leq\mathbb{F}_{q^m}^2 U ′ ≤ F q m 2 of complementary weights, that is,
w U ′ ( ⟨ ( 1 , 0 ) ⟩ F q m ) = w U ′ ( ⟨ ( 0 , 1 ) ⟩ F q m ) = m 2 , w U ′ ( P ) ≤ 1 for every other point P . w_{U'}(\langle(1,0)\rangle_{\mathbb{F}_{q^m}})=w_{U'}(\langle(0,1)\rangle_{\mathbb{F}_{q^m}})=\frac{m}{2},\qquad w_{U'}(P)\leq1\text{ for every other point }P. w U ′ (⟨( 1 , 0 ) ⟩ F q m ) = w U ′ (⟨( 0 , 1 ) ⟩ F q m ) = 2 m , w U ′ ( P ) ≤ 1 for every other point P .
Let 2 ≤ a ≤ m / 2 2\leq a\leq m/2 2 ≤ a ≤ m /2 , and let S 1 ≤ U ′ ∩ ⟨ ( 1 , 0 ) ⟩ F q m S_1\leq U'\cap\langle(1,0)\rangle_{\mathbb{F}_{q^m}} S 1 ≤ U ′ ∩ ⟨( 1 , 0 ) ⟩ F q m and S 2 ≤ U ′ ∩ ⟨ ( 0 , 1 ) ⟩ F q m S_2\leq U'\cap\langle(0,1)\rangle_{\mathbb{F}_{q^m}} S 2 ≤ U ′ ∩ ⟨( 0 , 1 ) ⟩ F q m be F q \mathbb{F}_q F q -subspaces with dim F q S 1 = dim F q S 2 = a \dim_{\mathbb{F}_q}S_1=\dim_{\mathbb{F}_q}S_2=a dim F q S 1 = dim F q S 2 = a . Put
U = S 1 ⊕ S 2 ( ≤ U ′ ) , dim F q U = 2 a . U=S_1\oplus S_2\ (\leq U'),\qquad\dim_{\mathbb{F}_q}U=2a. U = S 1 ⊕ S 2 ( ≤ U ′ ) , dim F q U = 2 a .
Then U ∩ ⟨ ( 1 , 0 ) ⟩ F q m = S 1 U\cap\langle(1,0)\rangle_{\mathbb{F}_{q^m}}=S_1 U ∩ ⟨( 1 , 0 ) ⟩ F q m = S 1 and U ∩ ⟨ ( 0 , 1 ) ⟩ F q m = S 2 U\cap\langle(0,1)\rangle_{\mathbb{F}_{q^m}}=S_2 U ∩ ⟨( 0 , 1 ) ⟩ F q m = S 2 have dimension a a a , every point ⟨ ( s 1 , s 2 ) ⟩ F q m \langle(s_1,s_2)\rangle_{\mathbb{F}_{q^m}} ⟨( s 1 , s 2 ) ⟩ F q m with s 1 s 2 ≠ 0 s_1s_2\ne0 s 1 s 2 = 0 , ( s 1 , s 2 ) ∈ U (s_1,s_2)\in U ( s 1 , s 2 ) ∈ U , has weight one, since U ≤ U ′ U\leq U' U ≤ U ′ , and there are points of weight zero, since 2 a ≤ m 2a\leq m 2 a ≤ m . By (1) , N a ( U ) = 2 N_a(U)=2 N a ( U ) = 2 and N 1 ( U ) = ( q a − 1 ) 2 / ( q − 1 ) N_1(U)=(q^a-1)^2/(q-1) N 1 ( U ) = ( q a − 1 ) 2 / ( q − 1 ) . Hence the code C C C associated with U U U is a nondegenerate [ 2 a , 2 ] q m / q [2a,2]_{q^m/q} [ 2 a , 2 ] q m / q code with nonzero weights
a , 2 a − 1 , 2 a , g 1 = 1 , g 2 = a − 1 , a,\qquad2a-1,\qquad2a,\qquad g_1=1,\qquad g_2=a-1, a , 2 a − 1 , 2 a , g 1 = 1 , g 2 = a − 1 ,
and
A a ( C ) = 2 ( q m − 1 ) , A 2 a − 1 ( C ) = ( q m − 1 ) ( q a − 1 ) 2 q − 1 , A 2 a ( C ) = q 2 m − 1 − A a ( C ) − A 2 a − 1 ( C ) . A_a(C)=2(q^m-1),\qquad A_{2a-1}(C)=(q^m-1)\frac{(q^a-1)^2}{q-1},\qquad A_{2a}(C)=q^{2m}-1-A_a(C)-A_{2a-1}(C). A a ( C ) = 2 ( q m − 1 ) , A 2 a − 1 ( C ) = ( q m − 1 ) q − 1 ( q a − 1 ) 2 , A 2 a ( C ) = q 2 m − 1 − A a ( C ) − A 2 a − 1 ( C ) .
Observe that in this family the second largest weight w = 2 a − 1 w=2a-1 w = 2 a − 1 may be coprime with m m m (for instance, m = 6 m=6 m = 6 and a = 3 a=3 a = 3 give the weights 3 , 5 , 6 3,5,6 3 , 5 , 6 ), whereas, when q ≥ m q\geq m q ≥ m and g 1 ≥ 2 g_1\geq2 g 1 ≥ 2 , Corollary 4.3 gives t ∣ gcd ( w , m ) t\mid\gcd(w,m) t ∣ g cd( w , m ) with t ≥ 2 t\geq2 t ≥ 2 .
The last family realizes the situation described in Corollary 4.3 with t > n − w t>n-w t > n − w , showing that the first gap can be large without C C C being an expansion.
Example 4.9 (Family F 4 \mathcal{F}_4 F 4 : weights ℓ t − t − 1 \ell t-t-1 ℓ t − t − 1 , ℓ t − t \ell t-t ℓ t − t , ℓ t − 1 \ell t-1 ℓ t − 1 ). Let m = t h m=th m = t h with 1 < t < m 1<t<m 1 < t < m , and let 2 ≤ ℓ ≤ h 2\leq\ell\leq h 2 ≤ ℓ ≤ h . Let U t U_t U t be an F q t \mathbb{F}_{q^t} F q t -scattered F q t \mathbb{F}_{q^t} F q t -subspace of F q m 2 = F ( q t ) h 2 \mathbb{F}_{q^m}^2=\mathbb{F}_{(q^t)^h}^2 F q m 2 = F ( q t ) h 2 with dim F q t U t = ℓ \dim_{\mathbb{F}_{q^t}}U_t=\ell dim F q t U t = ℓ , so that dim F q ( U t ∩ P ) ∈ { 0 , t } \dim_{\mathbb{F}_q}(U_t\cap P)\in\{0,t\} dim F q ( U t ∩ P ) ∈ { 0 , t } for every point P P P . The [ ℓ , 2 ] q m / q t [\ell,2]_{q^m/q^t} [ ℓ , 2 ] q m / q t code C t C_t C t associated with U t U_t U t has nonzero weights ℓ − 1 \ell-1 ℓ − 1 and ℓ \ell ℓ , so Exp q t / q ( C t ) \operatorname{Exp}_{q^t/q}(C_t) Exp q t / q ( C t ) is an [ ℓ t , 2 ] q m / q [\ell t,2]_{q^m/q} [ ℓ t , 2 ] q m / q code with nonzero weights t ( ℓ − 1 ) t(\ell-1) t ( ℓ − 1 ) and ℓ t \ell t ℓ t .
Let U ≤ F q U t U \leq_{\mathbb{F}_q} U_t U ≤ F q U t be an F q \mathbb{F}_q F q -hyperplane of U t U_t U t , so that
n = dim F q U = ℓ t − 1 ≤ m . n = \dim_{\mathbb{F}_q} U = \ell t - 1 \leq m. n = dim F q U = ℓ t − 1 ≤ m .
Choosing an F q \mathbb{F}_q F q -basis of U t U_t U t whose first n n n vectors form a basis of U U U , we see that the code C \mathcal{C} C associated with U U U is obtained, up to equivalence, by deleting one coordinate (for instance the last one) from Exp q t / q ( C t ) \operatorname{Exp}_{q^t/q}(\mathcal{C}_t) Exp q t / q ( C t ) . Since U U U is a hyperplane of U t U_t U t , every point of L U t L_{U_t} L U t has weight t − 1 t-1 t − 1 or t t t with respect to U U U , and the points outside L U t L_{U_t} L U t have weight zero. If x x x and y y y are the numbers of points of weight t t t and t − 1 t-1 t − 1 with respect to U U U , then x + y = ∣ L U t ∣ = q ℓ t − 1 q t − 1 x+y=|L_{U_t}|=\frac{q^{\ell t}-1}{q^t-1} x + y = ∣ L U t ∣ = q t − 1 q ℓ t − 1 and, by (1) , x ( q t − 1 ) + y ( q t − 1 − 1 ) = q ℓ t − 1 − 1 x(q^t-1)+y(q^{t-1}-1)=q^{\ell t-1}-1 x ( q t − 1 ) + y ( q t − 1 − 1 ) = q ℓ t − 1 − 1 ; hence
x = q ( ℓ − 1 ) t − 1 q t − 1 ≥ 1 , y = q ( ℓ − 1 ) t . x=\frac{q^{(\ell-1)t}-1}{q^t-1}\geq1,\qquad y=q^{(\ell-1)t}. x = q t − 1 q ( ℓ − 1 ) t − 1 ≥ 1 , y = q ( ℓ − 1 ) t .
Therefore C \mathcal{C} C is a nondegenerate [ ℓ t − 1 , 2 ] q m / q [\ell t-1,2]_{q^m/q} [ ℓ t − 1 , 2 ] q m / q code with nonzero weights
d = ℓ t − t − 1 = n − t , w = ℓ t − t = n − t + 1 , n = ℓ t − 1 , g 1 = t − 1 , g 2 = 1 , d=\ell t-t-1=n-t,\qquad w=\ell t-t=n-t+1,\qquad n=\ell t-1,\qquad g_1=t-1,\qquad g_2=1, d = ℓ t − t − 1 = n − t , w = ℓ t − t = n − t + 1 , n = ℓ t − 1 , g 1 = t − 1 , g 2 = 1 ,
and
A n − t ( C ) = ( q m − 1 ) q ( ℓ − 1 ) t − 1 q t − 1 , A n − t + 1 ( C ) = ( q m − 1 ) q ( ℓ − 1 ) t . A_{n-t}(\mathcal{C})=(q^m-1)\frac{q^{(\ell-1)t}-1}{q^t-1},\qquad A_{n-t+1}(\mathcal{C})=(q^m-1)q^{(\ell-1)t}. A n − t ( C ) = ( q m − 1 ) q t − 1 q ( ℓ − 1 ) t − 1 , A n − t + 1 ( C ) = ( q m − 1 ) q ( ℓ − 1 ) t .
If t ≥ 3 t\geq3 t ≥ 3 (so that g 1 = t − 1 ≥ 2 g_1=t-1\geq2 g 1 = t − 1 ≥ 2 ) and q ≥ m q\geq m q ≥ m , then this family is an instance of Corollary 4.3. Indeed, ⟨ U ⟩ F q t = U t \langle U\rangle_{\mathbb{F}_{q^t}}=U_t ⟨ U ⟩ F q t = U t , because ⟨ U ⟩ F q t ≤ U t \langle U\rangle_{\mathbb{F}_{q^t}}\leq U_t ⟨ U ⟩ F q t ≤ U t is an F q t \mathbb{F}_{q^t} F q t -subspace, so that its F q \mathbb{F}_q F q -dimension is a multiple of t t t , and it contains U U U , of dimension ℓ t − 1 \ell t-1 ℓ t − 1 . The divisor t t t satisfies n − w = t − 1 < t ≤ min { w , m − w } n-w=t-1<t\leq\min\{w,m-w\} n − w = t − 1 < t ≤ min { w , m − w } and t ∣ w t\mid w t ∣ w , exactly one coordinate is deleted, and d = w − 1 > w − t d=w-1>w-t d = w − 1 > w − t , so that C t \mathcal{C}_t C t has two weights and A w ( Exp q t / q ( C t ) ) = A d ( C ) + A w ( C ) = ( q m − 1 ) q w + t − 1 q t − 1 A_w(\operatorname{Exp}_{q^t/q}(\mathcal{C}_t))=A_d(\mathcal{C})+A_w(\mathcal{C})=(q^m-1)\frac{q^{w+t-1}}{q^t-1} A w ( Exp q t / q ( C t )) = A d ( C ) + A w ( C ) = ( q m − 1 ) q t − 1 q w + t − 1 ; the values of A d ( C ) A_d(\mathcal{C}) A d ( C ) and A w ( C ) A_w(\mathcal{C}) A w ( C ) above agree with the formulas of Corollary 4.3(iv). Moreover, gcd ( n − w , n − d ) = gcd ( t − 1 , t ) = 1 \gcd(n-w,n-d)=\gcd(t-1,t)=1 g cd( n − w , n − d ) = g cd( t − 1 , t ) = 1 , so C \mathcal{C} C is not the F q \mathbb{F}_q F q -expansion of a code over any proper extension of F q \mathbb{F}_q F q . For t = 2 t=2 t = 2 we get three consecutive weights 2 ℓ − 3 , 2 ℓ − 2 , 2 ℓ − 1 2\ell-3,2\ell-2,2\ell-1 2 ℓ − 3 , 2 ℓ − 2 , 2 ℓ − 1 , as in Family F 1 \mathcal{F}_1 F 1 ; in this case g 1 = 1 g_1=1 g 1 = 1 and Corollary 4.3 does not apply. The smallest instance with g 1 ≥ 2 g_1\geq2 g 1 ≥ 2 is m = 6 m=6 m = 6 , t = 3 t=3 t = 3 , ℓ = 2 \ell=2 ℓ = 2 : it gives a [ 5 , 2 ] q 6 / q [5,2]_{q^6/q} [ 5 , 2 ] q 6 / q code with nonzero weights 2 , 3 , 5 2,3,5 2 , 3 , 5 and first gap 2 2 2 , which is not an F q \mathbb{F}_q F q -expansion from any proper extension of F q \mathbb{F}_q F q and which, for q ≥ 7 q\geq7 q ≥ 7 , falls under Corollary 4.3 with t = 3 t=3 t = 3 .
Remark 4.10. The following table summarizes the families above.
Table 4.10.
All these families exist for every q q q . When g 1 = 1 g_1=1 g 1 = 1 (families F 1 \mathcal{F}_1 F 1 , F 2 \mathcal{F}_2 F 2 , F 3 \mathcal{F}_3 F 3 and clubs), Theorem 4.1 does not apply, and indeed no arithmetic restriction appears: for every q q q and every admissible length the second gap takes the values 1 1 1 (Family F 1 \mathcal{F}_1 F 1 ), n − 3 n-3 n − 3 (Family F 2 \mathcal{F}_2 F 2 ) and n − 2 n-2 n − 2 (the ( n − 1 ) (n-1) ( n − 1 ) -clubs of Remark 4.7), and more generally the value i − 1 i-1 i − 1 whenever a rank-i i i club exists; moreover, the weights need not share any common factor with m m m (Family F 3 \mathcal{F}_3 F 3 ). When g 1 ≥ 2 g_1\geq2 g 1 ≥ 2 and q ≥ m q\geq m q ≥ m , the situation is rigid: by Corollary 4.3 there is a divisor t t t of m m m with g 1 ≤ t ≤ min { w , m − w } g_1\leq t\leq\min\{w,m-w\} g 1 ≤ t ≤ min { w , m − w } dividing w w w , the residue d m o d t d\bmod t d mod t is either 0 0 0 or at least g 1 g_1 g 1 , and, if t > g 1 t>g_1 t > g 1 , the weight distribution is determined by the parameters. Family F 4 \mathcal{F}_4 F 4 shows that the case t > g 1 t>g_1 t > g 1 really occurs, with t = g 1 + 1 t=g_1+1 t = g 1 + 1 , that then C \mathcal{C} C need not be an expansion, and that the first gap g 1 = t − 1 g_1=t-1 g 1 = t − 1 can be as large as m 2 − 1 \frac{m}{2}-1 2 m − 1 ; in this family the second gap is equal to one.
Simplex summands and field expansion
In this section we state the consequences of § 3 for rank-metric codes. Throughout, C \mathcal{C} C is a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code with generator matrix G G G , so that every codeword is x G xG x G for a unique x ∈ F q m k x \in\mathbb{F}_{q^m}^{k} x ∈ F q m k , and we put N = k m − n N=km-n N = k m − n . By Proposition 2.6 , C \mathcal{C} C contains codewords of rank m m m if and only if n ≥ m n \ge m n ≥ m . The key object is the subcode generated by the codewords of nonmaximum rank,
C < m = ⟨ c ∈ C : 0 < w ( c ) < m ⟩ F q m , h ( C ) = dim F q m C < m . \mathcal{C}_{<m}=\left\langle c\in\mathcal{C}:0<w(c)<m\right\rangle_{\mathbb{F}_{q^m}},\qquad h(\mathcal{C})=\dim_{\mathbb{F}_{q^m}}\mathcal{C}_{<m}. C < m = ⟨ c ∈ C : 0 < w ( c ) < m ⟩ F q m , h ( C ) = dim F q m C < m .
Lemma 5.1. Let C \mathcal{C} C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code with h = h ( C ) ≥ 1 h=h(\mathcal{C})\ge1 h = h ( C ) ≥ 1 . Then C < m \mathcal{C}_{<m} C < m contains a codeword of rank m m m if and only if
n ≥ ( k − h + 1 ) m . n\ge(k-h+1)m. n ≥ ( k − h + 1 ) m .
Proof. If h = 0 h=0 h = 0 , then C < m = { 0 } \mathcal{C}_{<m}=\{0\} C < m = { 0 } contains no codeword of rank m m m , and n ≤ k m < ( k + 1 ) m n\le km<(k+1)m n ≤ k m < ( k + 1 ) m ; so we may assume h ≥ 1 h\ge1 h ≥ 1 . Let U U U be the system associated with G G G , and put W = U ⊥ W=U^{\perp} W = U ⊥ and S = ⟨ W ⟩ F q m S=\langle W\rangle_{\mathbb{F}_{q^m}} S = ⟨ W ⟩ F q m . By (6) , a nonzero vector x x x satisfies w ( x G ) < m w(xG)<m w ( x G ) < m if and only if ⟨ x ⟩ F q m ∈ L W \langle x\rangle_{\mathbb{F}_{q^m}}\in L_W ⟨ x ⟩ F q m ∈ L W . The points of L W L_W L W span PG ( S , F q m ) \operatorname{PG}(S,\mathbb{F}_{q^m}) PG ( S , F q m ) , and x ↦ x G x\mapsto xG x ↦ x G is an F q m \mathbb{F}_{q^m} F q m -linear isomorphism from F q m k \mathbb{F}_{q^m}^{k} F q m k onto C \mathcal{C} C ; hence
C < m = { x G : x ∈ S } and dim F q m S = h . (18) \mathcal{C}_{<m}=\{xG:x\in S\}\qquad\text{and}\qquad\dim_{\mathbb{F}_{q^m}}S=h. \tag*{(18)} C < m = { x G : x ∈ S } and dim F q m S = h . (18)
A codeword x G xG x G with x ∈ S ∖ { 0 } x\in S\setminus\{0\} x ∈ S ∖ { 0 } has rank m m m if and only if ⟨ x ⟩ F q m ∈ PG ( S , F q m ) ∖ L W \langle x\rangle_{\mathbb{F}_{q^m}}\in\operatorname{PG}(S,\mathbb{F}_{q^m})\setminus L_W ⟨ x ⟩ F q m ∈ PG ( S , F q m ) ∖ L W . Therefore C < m \mathcal{C}_{<m} C < m contains a codeword of rank m m m if and only if L W ≠ PG ( S , F q m ) L_W\ne\operatorname{PG}(S,\mathbb{F}_{q^m}) L W = PG ( S , F q m ) , which by Lemma 2.2 is equivalent to N ≤ ( h − 1 ) m N\le(h-1)m N ≤ ( h − 1 ) m , that is, to n ≥ ( k − h + 1 ) m n\ge(k-h+1)m n ≥ ( k − h + 1 ) m .
Accordingly, we distinguish two cases: either every nonzero codeword of C < m \mathcal{C}_{<m} C < m has rank smaller than m m m , equivalently n < ( k − h + 1 ) m n<(k-h+1)m n < ( k − h + 1 ) m (this includes the case h = 0 h=0 h = 0 ), or C < m \mathcal{C}_{<m} C < m contains codewords of rank m m m , equivalently n ≥ ( k − h + 1 ) m n\ge(k-h+1)m n ≥ ( k − h + 1 ) m . The first case is the subject of § 5.1 , and the second that of § 5.2 . If C \mathcal{C} C is generated by its codewords of nonmaximum rank, then h = k h=k h = k and the second case is simply n ≥ m n\ge m n ≥ m .
Direct sum of a simplex code and a short code
We begin with the case in which C < m \mathcal{C}_{<m} C < m contains no codeword of rank m m m . Geometrically, this means that the linear set L U ⊥ L_{U^{\perp}} L U ⊥ fills its span (see the proof of Lemma 5.1). We show that this happens precisely when C \mathcal{C} C splits off a simplex code, all of whose nonzero codewords have rank m m m , leaving a code of length smaller than m m m that carries all the nonmaximum weights. We first prove this in geometric terms (Theorem 5.2), and then express the condition through the parameters of $\mathcal{C} ({citet}Lemma 5.3 and {citet}Corollary 5.4`).
Theorem 5.2. Let C \mathcal{C} C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q rank-metric code and let U U U be an associated q q q -system. Then there exists an h ∈ { 0 , … , k } h\in\{0,\ldots,k\} h ∈ { 0 , … , k } such that
C ≅ C ~ × C ′ = { ( c ~ , c ′ ) : c ~ ∈ C ~ , c ′ ∈ C ′ } ≤ F q m ( k − h ) m × F q m ε \mathcal{C}\cong\widetilde{\mathcal{C}}\times\mathcal{C}'=\{(\widetilde{c},c'):\widetilde{c}\in\widetilde{\mathcal{C}},\ c'\in\mathcal{C}'\}\le\mathbb{F}_{q^m}^{(k-h)m}\times\mathbb{F}_{q^m}^{\varepsilon} C ≅ C × C ′ = {( c , c ′ ) : c ∈ C , c ′ ∈ C ′ } ≤ F q m ( k − h ) m × F q m ε where C ~ \widetilde{\mathcal{C}} C is an [ ( k − h ) m , k − h ] q m / q [(k-h)m,k-h]_{q^m/q} [( k − h ) m , k − h ] q m / q simplex code and C ′ \mathcal{C}' C ′ is an [ ε , h ] q m / q [\varepsilon,h]_{q^m/q} [ ε , h ] q m / q rank-metric code of short length 0 ≤ ε ≤ m − 1 0\le\varepsilon\le m-1 0 ≤ ε ≤ m − 1 if and only if
L U ⊥ = PG ( S , F q m ) L_{U^{\perp}}=\operatorname{PG}(S,\mathbb{F}_{q^m}) L U ⊥ = PG ( S , F q m ) for some F q m \mathbb{F}_{q^m} F q m -subspace S ⊆ F q m k S\subseteq\mathbb{F}_{q^m}^{k} S ⊆ F q m k with dim F q m ( S ) = h \dim_{\mathbb{F}_{q^m}}(S)=h dim F q m ( S ) = h . For h = 0 h=0 h = 0 (resp. h = k h=k h = k ), C ′ \mathcal{C}' C ′ (resp. C ~ \widetilde{\mathcal{C}} C ) is the zero code of length 0 0 0 . Moreover, in this case n = ( k − h ) m + ε n=(k-h)m+\varepsilon n = ( k − h ) m + ε and the code C ′ \mathcal{C}' C ′ is nondegenerate; furthermore, S = ⟨ U ⊥ ⟩ F q m S=\langle U^{\perp}\rangle_{\mathbb{F}_{q^m}} S = ⟨ U ⊥ ⟩ F q m and h = h ( C ) h=h(\mathcal{C}) h = h ( C ) .
Proof. We first observe that the condition on L U ⊥ ′ L_{U^{\perp\prime}} L U ⊥ ′ does not depend on the choice of the q-system U U U associated with C \mathcal{C} C . Any other such system is φ ( U ) \varphi(U) φ ( U ) , with φ ∈ GL ( k , q m ) \varphi\in\operatorname{GL}(k,q^m) φ ∈ GL ( k , q m ) ; if ψ ∈ GL ( k , q m ) \psi\in\operatorname{GL}(k,q^m) ψ ∈ GL ( k , q m ) is the adjoint of φ − 1 \varphi^{-1} φ − 1 with respect to σ \sigma σ , then φ ( U ) ⊥ ′ = ψ ( U ⊥ ′ ) \varphi(U)^{\perp^\prime}=\psi(U^{\perp^\prime}) φ ( U ) ⊥ ′ = ψ ( U ⊥ ′ ) , and ψ \psi ψ , being F q m \mathbb{F}_{q^m} F q m -linear, maps PG ( S , F q m ) \operatorname{PG}(S,\mathbb{F}_{q^m}) PG ( S , F q m ) onto PG ( ψ ( S ) , F q m ) \operatorname{PG}(\psi(S),\mathbb{F}_{q^m}) PG ( ψ ( S ) , F q m ) .
( ⇐ ) (\Leftarrow) ( ⇐ ) Suppose that S S S is an h h h -dimensional F q m \mathbb{F}_{q^m} F q m -subspace of F q m k \mathbb{F}_{q^m}^k F q m k with h ∈ { 0 , … , k } h \in\{0,\ldots,k\} h ∈ { 0 , … , k } such that
L U ⊥ ′ = PG ( S , F q m ) . L_{U^{\perp^\prime}}=\operatorname{PG}(S,\mathbb{F}_{q^m}). L U ⊥ ′ = PG ( S , F q m ) .
If h = 0 h=0 h = 0 , we get that U = F q m k U=\mathbb{F}_{q^m}^k U = F q m k and therefore C \mathcal{C} C is a simplex code. Let h ≥ 1 h\geq1 h ≥ 1 . Then we have that U ⊥ ′ U^{\perp^\prime} U ⊥ ′ is an F q \mathbb{F}_q F q -subspace of S S S and since dim F q ( U ) = n \dim_{\mathbb{F}_q}(U)=n dim F q ( U ) = n , we have that
k m − n = dim F q ( U ⊥ ′ ) ≤ dim F q ( S ) = h m . (19) km-n=\dim_{\mathbb{F}_q}(U^{\perp^\prime})\leq\dim_{\mathbb{F}_q}(S)=hm. \tag*{(19)} k m − n = dim F q ( U ⊥ ′ ) ≤ dim F q ( S ) = hm . (19)
and by Lemma 2.2
k m − n = dim F q ( U ⊥ ′ ) ≥ ( h − 1 ) m + 1. (20) km-n=\dim_{\mathbb{F}_q}(U^{\perp^\prime})\geq(h-1)m+1. \tag*{(20)} k m − n = dim F q ( U ⊥ ′ ) ≥ ( h − 1 ) m + 1. (20)
Combining (19) and (20) , we get the following:
( k − h ) m ≤ n ≤ ( k − h ) m + m − 1. (k-h)m\leq n\leq(k-h)m+m-1. ( k − h ) m ≤ n ≤ ( k − h ) m + m − 1.
So n = ( k − h ) m + ε n=(k-h)m+\varepsilon n = ( k − h ) m + ε for 0 ≤ ε ≤ m − 1 0\leq\varepsilon\leq m-1 0 ≤ ε ≤ m − 1 . The subspace S S S is F q m \mathbb{F}_{q^m} F q m -linear and U ⊥ ′ ≤ F q S U^{\perp^\prime}\leq_{\mathbb{F}_q}S U ⊥ ′ ≤ F q S . Hence
S ⊥ = S ⊥ ′ ≤ F q ( U ⊥ ′ ) ⊥ ′ = U , S^\perp=S^{\perp^\prime}\leq_{\mathbb{F}_q}(U^{\perp^\prime})^{\perp^\prime}=U, S ⊥ = S ⊥ ′ ≤ F q ( U ⊥ ′ ) ⊥ ′ = U ,
and dim F q m ( S ⊥ ) = k − h \dim_{\mathbb{F}_{q^m}}(S^\perp)=k-h dim F q m ( S ⊥ ) = k − h . We want to construct an ε \varepsilon ε -dimensional subspace U ′ U' U ′ such that
U = S ⊥ ⊕ U ′ and S ⊥ ∩ ⟨ U ′ ⟩ F q m = { 0 } . (21) U=S^\perp\oplus U' \quad\text{and}\quad S^\perp\cap\langle U'\rangle_{\mathbb{F}_{q^m}}=\{0\}. \tag*{(21)} U = S ⊥ ⊕ U ′ and S ⊥ ∩ ⟨ U ′ ⟩ F q m = { 0 } . (21)
We start the construction by taking any F q \mathbb{F}_q F q -subspace U ∗ U^* U ∗ of U U U such that
U = S ⊥ ⊕ U ∗ . U=S^\perp\oplus U^*. U = S ⊥ ⊕ U ∗ .
Then we get
⟨ U ⟩ F q m = S ⊥ + ⟨ U ∗ ⟩ F q m . \langle U\rangle_{\mathbb{F}_{q^m}}=S^\perp+\langle U^*\rangle_{\mathbb{F}_{q^m}}. ⟨ U ⟩ F q m = S ⊥ + ⟨ U ∗ ⟩ F q m .
Let g = dim F q m ( ⟨ U ∗ ⟩ F q m ) g=\dim_{\mathbb{F}_{q^m}}(\langle U^*\rangle_{\mathbb{F}_{q^m}}) g = dim F q m (⟨ U ∗ ⟩ F q m ) . We have dim F q m ( S ⊥ ) = k − h \dim_{\mathbb{F}_{q^m}}(S^\perp)=k-h dim F q m ( S ⊥ ) = k − h and since C \mathcal{C} C is nondegenerate, ⟨ U ⟩ F q m = F q m k \langle U\rangle_{\mathbb{F}_{q^m}}=\mathbb{F}_{q^m}^k ⟨ U ⟩ F q m = F q m k . Therefore g ≥ h g\geq h g ≥ h and dim F q m ( S ⊥ ∩ ⟨ U ∗ ⟩ F q m ) = g − h \dim_{\mathbb{F}_{q^m}}(S^\perp\cap\langle U^*\rangle_{\mathbb{F}_{q^m}})=g-h dim F q m ( S ⊥ ∩ ⟨ U ∗ ⟩ F q m ) = g − h . We define H ≤ F q m ⟨ U ∗ ⟩ F q m H\leq_{\mathbb{F}_{q^m}}\langle U^*\rangle_{\mathbb{F}_{q^m}} H ≤ F q m ⟨ U ∗ ⟩ F q m of dim F q m ( H ) = h \dim_{\mathbb{F}_{q^m}}(H)=h dim F q m ( H ) = h such that
H ∩ ( S ⊥ ∩ ⟨ U ∗ ⟩ F q m ) = { 0 } . H\cap\left(S^\perp\cap\langle U^*\rangle_{\mathbb{F}_{q^m}}\right)=\{0\}. H ∩ ( S ⊥ ∩ ⟨ U ∗ ⟩ F q m ) = { 0 } .
Over F q \mathbb{F}_q F q , we define the subspace
U ‾ = U ∩ ⟨ U ∗ ⟩ F q m , \overline{U}=U\cap\langle U^*\rangle_{\mathbb{F}_{q^m}}, U = U ∩ ⟨ U ∗ ⟩ F q m ,
since U + ⟨ U ∗ ⟩ F q m ≤ F q m k U+\langle U^*\rangle_{\mathbb{F}_{q^m}}\leq\mathbb{F}_{q^m}^k U + ⟨ U ∗ ⟩ F q m ≤ F q m k , we have that dim F q ( U ) + dim F q ( ⟨ U ∗ ⟩ F q m ) − dim F q ( U ‾ ) ≤ k m \dim_{\mathbb{F}_q}(U)+\dim_{\mathbb{F}_q}(\langle U^*\rangle_{\mathbb{F}_{q^m}})-\dim_{\mathbb{F}_q}(\overline{U})\leq km dim F q ( U ) + dim F q (⟨ U ∗ ⟩ F q m ) − dim F q ( U ) ≤ k m . In particular, we compute
dim F q ( U ‾ ) ≥ ( k − h ) m + ε + g m − k m = ( g − h ) m + ε . \dim_{\mathbb{F}_q}(\overline{U})\geq(k-h)m+\varepsilon+gm-km=(g-h)m+\varepsilon. dim F q ( U ) ≥ ( k − h ) m + ε + g m − k m = ( g − h ) m + ε .
We define the desired subspace U ′ U' U ′ as the intersection
U ′ = H ∩ U ‾ . U'=H\cap\overline{U}. U ′ = H ∩ U .
Since U ′ ⊆ H U'\subseteq H U ′ ⊆ H , also ⟨ U ′ ⟩ F q m ⊆ H \langle U'\rangle_{\mathbb{F}_{q^m}}\subseteq H ⟨ U ′ ⟩ F q m ⊆ H and therefore ⟨ U ′ ⟩ F q m ∩ S ⊥ = { 0 } \langle U'\rangle_{\mathbb{F}_{q^m}}\cap S^\perp=\{0\} ⟨ U ′ ⟩ F q m ∩ S ⊥ = { 0 } . Since U ′ ⊆ U ‾ ⊆ U U'\subseteq\overline{U}\subseteq U U ′ ⊆ U ⊆ U and S ⊥ ⊆ U S^\perp\subseteq U S ⊥ ⊆ U ,
dim F q ( U ′ ) + dim F q ( S ⊥ ) = dim F q ( U ′ + S ⊥ ) ≤ dim F q ( U ) ⇔ dim F q ( U ′ ) ≤ ( k − h ) m + ε − ( k − h ) m = ε . \begin{aligned}
\dim_{\mathbb{F}_q}(U')+\dim_{\mathbb{F}_q}(S^\perp)=\dim_{\mathbb{F}_q}(U'+S^\perp)\leq\dim_{\mathbb{F}_q}(U) \\
&\Leftrightarrow\dim_{\mathbb{F}_q}(U')\leq(k-h)m+\varepsilon-(k-h)m=\varepsilon.
\end{aligned} dim F q ( U ′ ) + dim F q ( S ⊥ ) = dim F q ( U ′ + S ⊥ ) ≤ dim F q ( U ) ⇔ dim F q ( U ′ ) ≤ ( k − h ) m + ε − ( k − h ) m = ε .
Furthermore, since H + U ‾ ⊆ ⟨ U ⟩ F q m H+\overline{U}\subseteq\langle U\rangle_{\mathbb{F}_{q^m}} H + U ⊆ ⟨ U ⟩ F q m , we compute
g m ≥ dim F q ( H + U ‾ ) ≥ h m + ( g − h ) m + ε − dim F q ( H ∩ U ‾ ) gm\geq\dim_{\mathbb{F}_q}(H+\overline{U})\geq hm+(g-h)m+\varepsilon-\dim_{\mathbb{F}_q}(H\cap\overline{U}) g m ≥ dim F q ( H + U ) ≥ hm + ( g − h ) m + ε − dim F q ( H ∩ U )
⟺ g m ≥ dim F q ( H + U ‾ ) ≥ g m + ε − dim F q ( H ∩ U ‾ ) . \Longleftrightarrow gm\geq\dim_{\mathbb{F}_q}(H+\overline{U})\geq gm+\varepsilon-\dim_{\mathbb{F}_q}(H\cap\overline{U}). ⟺ g m ≥ dim F q ( H + U ) ≥ g m + ε − dim F q ( H ∩ U ) .
Hence dim F q ( U ′ ) = dim F q ( H ∩ U ‾ ) = ε \dim_{\mathbb{F}_q}(U')=\dim_{\mathbb{F}_q}(H\cap\overline{U})=\varepsilon dim F q ( U ′ ) = dim F q ( H ∩ U ) = ε and we conclude that U = S ⊥ ⊕ U ′ U=S^\perp\oplus U' U = S ⊥ ⊕ U ′ . Moreover, F q m k = ⟨ U ⟩ F q m = S ⊥ + ⟨ U ′ ⟩ F q m \mathbb{F}_{q^m}^k=\langle U\rangle_{\mathbb{F}_{q^m}}=S^\perp+\langle U'\rangle_{\mathbb{F}_{q^m}} F q m k = ⟨ U ⟩ F q m = S ⊥ + ⟨ U ′ ⟩ F q m , and ⟨ U ′ ⟩ F q m ⊆ H \langle U'\rangle_{\mathbb{F}_{q^m}}\subseteq H ⟨ U ′ ⟩ F q m ⊆ H with dim F q m ( H ) = h \dim_{\mathbb{F}_{q^m}}(H)=h dim F q m ( H ) = h ; comparing dimensions, ⟨ U ′ ⟩ F q m = H \langle U'\rangle_{\mathbb{F}_{q^m}}=H ⟨ U ′ ⟩ F q m = H . Hence
F q m k = S ⊥ ⊕ ⟨ U ′ ⟩ F q m . \mathbb{F}_{q^m}^k=S^\perp\oplus\langle U'\rangle_{\mathbb{F}_{q^m}}. F q m k = S ⊥ ⊕ ⟨ U ′ ⟩ F q m .
and we may choose an F q m \mathbb{F}_{q^m} F q m -basis B = ( v 1 , … , v k − h , v k − h + 1 , … , v k ) B=(v_1,\ldots,v_{k-h},v_{k-h+1},\ldots,v_k) B = ( v 1 , … , v k − h , v k − h + 1 , … , v k ) of F q m k \mathbb{F}_{q^m}^k F q m k such that
S ⊥ = ⟨ v i : 1 ≤ i ≤ k − h ⟩ F q m and ⟨ U ′ ⟩ F q m = ⟨ v i : k − h + 1 ≤ i ≤ k ⟩ F q m . S^\perp=\langle v_i:1\leq i\leq k-h\rangle_{\mathbb{F}_{q^m}}\quad\text{and}\quad\langle U'\rangle_{\mathbb{F}_{q^m}}=\langle v_i:k-h+1\leq i\leq k\rangle_{\mathbb{F}_{q^m}}. S ⊥ = ⟨ v i : 1 ≤ i ≤ k − h ⟩ F q m and ⟨ U ′ ⟩ F q m = ⟨ v i : k − h + 1 ≤ i ≤ k ⟩ F q m .
Let ϕ ∈ GL ( k , q m ) \phi\in\operatorname{GL}(k,q^m) ϕ ∈ GL ( k , q m ) be the linear transformation mapping B B B to the canonical basis ( e 1 , … , e k ) (e_1,\ldots,e_k) ( e 1 , … , e k ) of F q m k \mathbb{F}_{q^m}^k F q m k . Since ϕ \phi ϕ induces an equivalence of codes, we have that
ϕ ( U ) = ϕ ( S ⊥ ) ⊕ ϕ ( U ′ ) . \phi(U)=\phi(S^\perp)\oplus\phi(U'). ϕ ( U ) = ϕ ( S ⊥ ) ⊕ ϕ ( U ′ ) .
is the system associated to a code equivalent to C C C , with ϕ ( S ⊥ ) = F q m k − h × { 0 } \phi(S^\perp)=\mathbb{F}_{q^m}^{k-h}\times\{0\} ϕ ( S ⊥ ) = F q m k − h × { 0 } and ϕ ( U ′ ) ⊆ { 0 } × F q m h \phi(U')\subseteq\{0\}\times\mathbb{F}_{q^m}^h ϕ ( U ′ ) ⊆ { 0 } × F q m h . Now we choose corresponding F q \mathbb{F}_q F q -bases B ϕ ( S ⊥ ) = { ( z ‾ 1 , 0 ) , … , ( z ‾ ( k − h ) m , 0 ) } B_{\phi(S^\perp)}=\{(\overline{z}_1,0),\ldots,(\overline{z}_{(k-h)m},0)\} B ϕ ( S ⊥ ) = {( z 1 , 0 ) , … , ( z ( k − h ) m , 0 )} of ϕ ( S ⊥ ) \phi(S^\perp) ϕ ( S ⊥ ) and B ϕ ( U ′ ) = { ( 0 , y ‾ 1 ) , … , ( 0 , y ‾ ε ) } B_{\phi(U')}=\{(0,\overline{y}_1),\ldots,(0,\overline{y}_\varepsilon)\} B ϕ ( U ′ ) = {( 0 , y 1 ) , … , ( 0 , y ε )} of ϕ ( U ′ ) \phi(U') ϕ ( U ′ ) , where z ‾ i ∈ F q m k − h \overline{z}_i\in\mathbb{F}_{q^m}^{k-h} z i ∈ F q m k − h and y ‾ j ∈ F q m h \overline{y}_j\in\mathbb{F}_{q^m}^h y j ∈ F q m h . With respect to these bases, the generator matrix of the code associated to U U U has the block form
G = ( z 1 ( 1 ) ⋯ z ( k − h ) m ( 1 ) 0 ⋯ 0 ⋮ ⋮ ⋮ ⋮ z 1 ( k − h ) ⋯ z ( k − h ) m ( k − h ) 0 ⋯ 0 0 ⋯ 0 y 1 ( 1 ) ⋯ y ε ( 1 ) ⋮ ⋮ ⋮ ⋮ 0 ⋯ 0 y 1 ( h ) ⋯ y ε ( h ) ) ∈ F q m k × n . G=
\begin{pmatrix}
z_1^{(1)}&\cdots&z_{(k-h)m}^{(1)}&0&\cdots&0\\
\vdots&&\vdots&\vdots&&\vdots\\
z_1^{(k-h)}&\cdots&z_{(k-h)m}^{(k-h)}&0&\cdots&0\\
0&\cdots&0&y_1^{(1)}&\cdots&y_\varepsilon^{(1)}\\
\vdots&&\vdots&\vdots&&\vdots\\
0&\cdots&0&y_1^{(h)}&\cdots&y_\varepsilon^{(h)}
\end{pmatrix}\in\mathbb{F}_{q^m}^{k\times n}. G = z 1 ( 1 ) ⋮ z 1 ( k − h ) 0 ⋮ 0 ⋯ ⋯ ⋯ ⋯ z ( k − h ) m ( 1 ) ⋮ z ( k − h ) m ( k − h ) 0 ⋮ 0 0 ⋮ 0 y 1 ( 1 ) ⋮ y 1 ( h ) ⋯ ⋯ ⋯ ⋯ 0 ⋮ 0 y ε ( 1 ) ⋮ y ε ( h ) ∈ F q m k × n .
The system ϕ ( S ⊥ ) = F q m k − h × { 0 } \phi(S^\perp)=\mathbb{F}_{q^m}^{k-h}\times\{0\} ϕ ( S ⊥ ) = F q m k − h × { 0 } is F q m \mathbb{F}_{q^m} F q m -linear of dimension k − h k-h k − h . Hence the code C ~ \widetilde{C} C generated by the block Z = ( z ‾ 1 ⋯ z ‾ ( k − h ) m ) Z=(\overline{z}_1\ \cdots\ \overline{z}_{(k-h)m}) Z = ( z 1 ⋯ z ( k − h ) m ) is a nondegenerate [ ( k − h ) m , k − h ] q m / q [(k-h)m,k-h]_{q^m/q} [( k − h ) m , k − h ] q m / q simplex code. The code C ′ C' C ′ generated by the block Y = ( y ‾ 1 ⋯ y ‾ ε ) Y=(\overline{y}_1\ \cdots\ \overline{y}_\varepsilon) Y = ( y 1 ⋯ y ε ) is a nondegenerate [ ε , h ] q m / q [\varepsilon,h]_{q^m/q} [ ε , h ] q m / q code, since y ‾ 1 , … , y ‾ ε \overline{y}_1,\ldots,\overline{y}_\varepsilon y 1 , … , y ε are F q \mathbb{F}_q F q -linearly independent and span F q m h \mathbb{F}_{q^m}^h F q m h over F q m \mathbb{F}_{q^m} F q m (because ϕ ( ⟨ U ′ ⟩ F q m ) = { 0 } × F q m h \phi(\langle U'\rangle_{\mathbb{F}_{q^m}})=\{0\}\times\mathbb{F}_{q^m}^h ϕ (⟨ U ′ ⟩ F q m ) = { 0 } × F q m h ). As G G G is block diagonal, the code generated by G G G is C ~ × C ′ \widetilde{C}\times C' C × C ′ , and therefore C ≅ C ~ × C ′ C\cong\widetilde{C}\times C' C ≅ C × C ′ . For h = k h=k h = k the same argument works with S ⊥ = { 0 } S^\perp=\{0\} S ⊥ = { 0 } and Z Z Z empty, and gives C ≅ C ′ C\cong C' C ≅ C ′ . This proves the first implication.
( ⇒ ) (\Rightarrow) ( ⇒ ) Conversely, suppose that there exists an h ∈ { 0 , … , k } h\in\{0,\ldots,k\} h ∈ { 0 , … , k } such that
C ≅ C ~ × C ′ ⊆ F q m ( k − h ) m × F q m h , C\cong\widetilde{C}\times C'\subseteq\mathbb{F}_{q^m}^{(k-h)m}\times\mathbb{F}_{q^m}^h, C ≅ C × C ′ ⊆ F q m ( k − h ) m × F q m h ,
with 0 ≤ ε ≤ m − 1 0\leq\varepsilon\leq m-1 0 ≤ ε ≤ m − 1 and dim F q m ( C ~ ) = k − h \dim_{\mathbb{F}_{q^m}}(\widetilde{C})=k-h dim F q m ( C ) = k − h and dim F q m ( C ′ ) = h \dim_{\mathbb{F}_{q^m}}(C')=h dim F q m ( C ′ ) = h . By the first paragraph, we may compute U U U from any generator matrix of C ~ × C ′ \widetilde{C}\times C' C × C ′ . Write an F q m \mathbb{F}_{q^m} F q m -basis of C ~ × C ′ \widetilde{C}\times C' C × C ′ where ( c 1 , 0 ) , … , ( c k − h , 0 ) ∈ F q m ( k − h ) m × { 0 } (c_1,0),\ldots,(c_{k-h},0)\in\mathbb{F}_{q^m}^{(k-h)m}\times\{0\} ( c 1 , 0 ) , … , ( c k − h , 0 ) ∈ F q m ( k − h ) m × { 0 } and ( 0 , c k − h + 1 ) , … , ( 0 , c k ) ∈ { 0 } × F q m h (0,c_{k-h+1}),\ldots,(0,c_k)\in\{0\}\times\mathbb{F}_{q^m}^h ( 0 , c k − h + 1 ) , … , ( 0 , c k ) ∈ { 0 } × F q m h , and let G ~ \widetilde{G} G and G ′ G' G ′ be the matrices with rows c 1 , … , c k − h c_1,\ldots,c_{k-h} c 1 , … , c k − h and c k − h + 1 , … , c k c_{k-h+1},\ldots,c_k c k − h + 1 , … , c k , respectively. Then diag ( G ~ , G ′ ) \operatorname{diag}(\widetilde{G},G') diag ( G , G ′ ) is a generator matrix of C ~ × C ′ \widetilde{C}\times C' C × C ′ , and the associated system is the F q \mathbb{F}_q F q -span of its columns:
U = ( U ~ × { 0 } ) ⊕ ( { 0 } × U ′ ) . U=(\widetilde{U}\times\{0\})\oplus(\{0\}\times U'). U = ( U × { 0 }) ⊕ ({ 0 } × U ′ ) .
where U ~ ≤ F q m k − h \widetilde{U} \leq\mathbb{F}_{q^m}^{k-h} U ≤ F q m k − h and U ′ ≤ F q m h U' \leq\mathbb{F}_{q^m}^{h} U ′ ≤ F q m h are the F q \mathbb{F}_q F q -spans of the columns of G ~ \widetilde{G} G and G ′ G' G ′ . Since C C C is nondegenerate, these n n n columns are F q \mathbb{F}_q F q -linearly independent, so n = ( k − h ) m + ε n = (k-h)m + \varepsilon n = ( k − h ) m + ε and C ′ C' C ′ is nondegenerate. Since C ~ \widetilde{C} C is a simplex code, the associated system U ~ = F q m k − h \widetilde{U} = \mathbb{F}_{q^m}^{k-h} U = F q m k − h is F q m \mathbb{F}_{q^m} F q m -linear. Let
S = { 0 } k − h × F q m h . S = \{0\}^{k-h} \times\mathbb{F}_{q^m}^{h}. S = { 0 } k − h × F q m h .
Then S S S is an h h h -dimensional F q m \mathbb{F}_{q^m} F q m -subspace such that U ′ ⊥ ⊆ ( U ~ × { 0 } ) ⊥ = ( U ~ × { 0 } ) ⊥ = S U'^{\perp} \subseteq(\widetilde{U} \times\{0\})^{\perp} = (\widetilde{U} \times\{0\})^{\perp} = S U ′ ⊥ ⊆ ( U × { 0 } ) ⊥ = ( U × { 0 } ) ⊥ = S , and
dim F q ( U ′ ⊥ ) = k m − n = k m − ( k − h ) m − ε = h m − ε ≥ h m − ( m − 1 ) = ( h − 1 ) m + 1. \dim_{\mathbb{F}_q}(U'^{\perp}) = km - n = km - (k-h)m - \varepsilon= hm - \varepsilon\geq hm - (m-1) = (h-1)m + 1. dim F q ( U ′ ⊥ ) = k m − n = k m − ( k − h ) m − ε = hm − ε ≥ hm − ( m − 1 ) = ( h − 1 ) m + 1.
So dim F q ( U ′ ⊥ ) > ( h − 1 ) m \dim_{\mathbb{F}_q}(U'^{\perp}) > (h-1)m dim F q ( U ′ ⊥ ) > ( h − 1 ) m and since U ′ ⊥ ≤ F q S U'^{\perp} \leq_{\mathbb{F}_q} S U ′ ⊥ ≤ F q S , if h ≥ 1 h \geq1 h ≥ 1 Lemma 2.2 gives L U ′ ⊥ = PG ( S , F q m ) L_{U'^{\perp}} = \operatorname{PG}(S,\mathbb{F}_{q^m}) L U ′ ⊥ = PG ( S , F q m ) . If h = 0 h = 0 h = 0 , then U ′ ⊥ ⊆ S = { 0 } U'^{\perp} \subseteq S = \{0\} U ′ ⊥ ⊆ S = { 0 } and L U ′ ⊥ = ∅ = PG ( S , F q m ) L_{U'^{\perp}} = \varnothing= \operatorname{PG}(S,\mathbb{F}_{q^m}) L U ′ ⊥ = ∅ = PG ( S , F q m ) .
Lemma 5.3. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code, let U U U be an associated system and put h = h ( C ) h = h(C) h = h ( C ) . Then
h ≥ k − ⌊ n m ⌋ (22) h \geq k - \left\lfloor\frac{n}{m} \right\rfloor \tag*{(22)} h ≥ k − ⌊ m n ⌋ (22) and the following are equivalent:
(a) C < m C_{<m} C < m contains no codeword of rank m m m ;
(b) n ≤ ( k − h + 1 ) m − 1 n \leq(k-h+1)m - 1 n ≤ ( k − h + 1 ) m − 1 ;
(c) h = k − ⌊ n / m ⌋ h = k - \lfloor n/m \rfloor h = k − ⌊ n / m ⌋ ;
(d) L U ′ ⊥ = PG ( ⟨ U ′ ⊥ ⟩ F q m , F q m ) L_{U'^{\perp}} = \operatorname{PG}(\langle U'^{\perp}\rangle_{\mathbb{F}_{q^m}},\mathbb{F}_{q^m}) L U ′ ⊥ = PG (⟨ U ′ ⊥ ⟩ F q m , F q m ) .
If h = k h = k h = k , these conditions mean that n ≤ m − 1 n \leq m-1 n ≤ m − 1 , and then C C C has no codeword of rank m m m .
Proof. Let S = ⟨ U ′ ⊥ ⟩ F q m S = \langle U'^{\perp}\rangle_{\mathbb{F}_{q^m}} S = ⟨ U ′ ⊥ ⟩ F q m . We use the setting of Lemma 5.1. We write C < m = { x G : x ∈ S } C_{<m} = \{xG : x \in S\} C < m = { x G : x ∈ S } and dim F q m S = h \dim_{\mathbb{F}_{q^m}} S = h dim F q m S = h . Since U ′ ⊥ U'^{\perp} U ′ ⊥ is a subspace of S S S , we have k m − n ≤ h m km-n \leq hm k m − n ≤ hm . Hence,
h ≥ k − ⌊ n m ⌋ . h \geq k - \left\lfloor\frac{n}{m} \right\rfloor. h ≥ k − ⌊ m n ⌋ .
(a) ⇔ \Leftrightarrow ⇔ (b): see Lemma 5.1.
(b) ⇔ \Leftrightarrow ⇔ (c): n ≤ ( k − h + 1 ) m − 1 ⇔ n < ( k − h + 1 ) m ⇔ n m < k − h + 1 ⇔ ⌊ n / m ⌋ ≤ k − h n \leq(k-h+1)m - 1 \Leftrightarrow n < (k-h+1)m \Leftrightarrow\frac{n}{m} < k-h+1 \Leftrightarrow\lfloor n/m \rfloor\leq k-h n ≤ ( k − h + 1 ) m − 1 ⇔ n < ( k − h + 1 ) m ⇔ m n < k − h + 1 ⇔ ⌊ n / m ⌋ ≤ k − h . Together with (22) , n ≤ ( k − h + 1 ) m − 1 ⇔ ⌊ n / m ⌋ = k − h n \leq(k-h+1)m - 1 \Leftrightarrow\lfloor n/m \rfloor= k-h n ≤ ( k − h + 1 ) m − 1 ⇔ ⌊ n / m ⌋ = k − h .
(b) ⇔ \Leftrightarrow ⇔ (d): n < ( k − h + 1 ) m ⇔ ( h − 1 ) m < k m − n = dim F q ( U ′ ⊥ ) ⇔ L U ′ ⊥ = PG ( S , F q m ) n < (k-h+1)m \Leftrightarrow(h-1)m < km-n = \dim_{\mathbb{F}_q}(U'^{\perp}) \Leftrightarrow L_{U'^{\perp}} = \operatorname{PG}(S,\mathbb{F}_{q^m}) n < ( k − h + 1 ) m ⇔ ( h − 1 ) m < k m − n = dim F q ( U ′ ⊥ ) ⇔ L U ′ ⊥ = PG ( S , F q m ) , see Lemma 2.2 .
If h = k h = k h = k ; (b) ⇒ n ≤ m − 1 \Rightarrow n \leq m-1 ⇒ n ≤ m − 1 . By Proposition 2.6 , we conclude that C C C has no codeword of rank m m m .
Corollary 5.4. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code, let U U U be an associated system and put h = h ( C ) h = h(C) h = h ( C ) . Suppose that the equivalent conditions in Lemma 5.3 hold, then, up to equivalence,
C = C ~ × C ′ , C = \widetilde{C} \times C', C = C × C ′ , where C ~ \widetilde{C} C is a [ ( k − h ) m , k − h ] q m / q [(k-h)m,k-h]_{q^m/q} [( k − h ) m , k − h ] q m / q simplex code (the zero code of length 0 0 0 if h = k h = k h = k ) and C ′ C' C ′ is a nondegenerate [ ε , h ] q m / q [\varepsilon,h]_{q^m/q} [ ε , h ] q m / q code with ε = n − ( k − h ) m ≤ m − 1 \varepsilon= n - (k-h)m \leq m-1 ε = n − ( k − h ) m ≤ m − 1 . Furthermore, C < m = { 0 } × C ′ C_{<m} = \{0\} \times C' C < m = { 0 } × C ′ , and the nonzero weights of C C C are the nonzero weights of C ′ C' C ′ , together with m m m if h ≤ k − 1 h \leq k-1 h ≤ k − 1 ; the weights of C ′ C' C ′ are at most ε ≤ m − 1 \varepsilon\leq m-1 ε ≤ m − 1 , and
A m ( C ) = q k m − q h m , A i ( C ) = A i ( C ′ ) for 1 ≤ i ≤ m − 1. A_m(C) = q^{km} - q^{hm}, \qquad A_i(C) = A_i(C') \quad\text{for } 1 \leq i \leq m-1. A m ( C ) = q k m − q hm , A i ( C ) = A i ( C ′ ) for 1 ≤ i ≤ m − 1.
Proof. If the conditions of Lemma 5.3 hold, then, by Theorem 5.2 , up to equivalence, C = C ~ × C ′ \mathcal{C}=\widetilde{\mathcal{C}}\times\mathcal{C}' C = C × C ′ , where C ~ \widetilde{\mathcal{C}} C is a [ ( k − h ) m , k − h ] q m / q [(k-h)m,k-h]_{q^m/q} [( k − h ) m , k − h ] q m / q simplex code (the zero code of length 0 0 0 if h = k h=k h = k ) and C ′ \mathcal{C}' C ′ is a nondegenerate [ ε , h ] q m / q [\varepsilon,h]_{q^m/q} [ ε , h ] q m / q code with ε = n − ( k − h ) m ≤ m − 1 \varepsilon=n-(k-h)m\le m-1 ε = n − ( k − h ) m ≤ m − 1 . Since every nonzero codeword of a simplex code has rank weight m m m , we get that for every ( c ~ , c ′ ) ∈ C ~ × C ′ (\widetilde{c},c')\in\widetilde{\mathcal{C}}\times\mathcal{C}' ( c , c ′ ) ∈ C × C ′
w ( c ~ , c ′ ) = { m if c ~ ≠ 0 , w ( c ′ ) if c ~ = 0. w(\widetilde{c},c')=
\begin{cases}
m & \text{if }\widetilde{c}\ne0,\\
w(c') & \text{if }\widetilde{c}=0.
\end{cases} w ( c , c ′ ) = { m w ( c ′ ) if c = 0 , if c = 0.
Every codeword of C ′ \mathcal{C}' C ′ has rank weight at most ε ≤ m − 1 \varepsilon\le m-1 ε ≤ m − 1 . Therefore, C < m = { 0 } × C ′ \mathcal{C}_{<m}=\{0\}\times\mathcal{C}' C < m = { 0 } × C ′ and A i ( C ) = A i ( C ′ ) A_i(\mathcal{C})=A_i(\mathcal{C}') A i ( C ) = A i ( C ′ ) for 1 ≤ i ≤ m − 1 1\le i\le m-1 1 ≤ i ≤ m − 1 . The nonzero weights of C \mathcal{C} C are the nonzero weights of C ′ \mathcal{C}' C ′ , together with m m m if h ≤ k − 1 h\le k-1 h ≤ k − 1 , since then dim F q m ( C ~ ) = ( k − h ) > 0 \dim_{\mathbb{F}_{q^m}}(\widetilde{\mathcal{C}})=(k-h)>0 dim F q m ( C ) = ( k − h ) > 0 . Counting the codewords gives the relation
∑ i = 1 m A i ( C ) = A m ( C ) + ∑ i = 1 m − 1 A i ( C ′ ) . \sum_{i=1}^{m} A_i(\mathcal{C})=A_m(\mathcal{C})+\sum_{i=1}^{m-1} A_i(\mathcal{C}'). i = 1 ∑ m A i ( C ) = A m ( C ) + i = 1 ∑ m − 1 A i ( C ′ ) .
Hence
A m ( C ) = ∑ i = 1 m A i ( C ) − ∑ i = 1 m − 1 A i ( C ′ ) = q k m − 1 − ( q h m − 1 ) = q k m − q h m . A_m(\mathcal{C})=\sum_{i=1}^{m}A_i(\mathcal{C})-\sum_{i=1}^{m-1}A_i(\mathcal{C}')=q^{km}-1-(q^{hm}-1)=q^{km}-q^{hm}. A m ( C ) = i = 1 ∑ m A i ( C ) − i = 1 ∑ m − 1 A i ( C ′ ) = q k m − 1 − ( q hm − 1 ) = q k m − q hm .
Codes that are not a direct sum of a simplex code and a short code
Throughout this subsection, the nonzero rank weights of C \mathcal{C} C are d 1 < ⋯ < d r < m d_1<\cdots<d_r<m d 1 < ⋯ < d r < m together with m m m , we put
h = h ( C ) , a = m − d r , N = k m − n , h=h(\mathcal{C}),\qquad a=m-d_r,\qquad N=km-n, h = h ( C ) , a = m − d r , N = k m − n ,
and we assume:
(H1) q ≥ m q\ge m q ≥ m ;
(H2) h ≥ 2 h\ge2 h ≥ 2 ;
(H3) C < m \mathcal{C}_{<m} C < m contains a codeword of rank m m m ; equivalently, n ≥ ( k − h + 1 ) m n\ge(k-h+1)m n ≥ ( k − h + 1 ) m , by Lemma 5.1;
(H4) a ≥ 2 a\ge2 a ≥ 2 , that is, d r ≤ m − 2 d_r\le m-2 d r ≤ m − 2 .
Note that (H2) forces r ≥ 1 r\ge1 r ≥ 1 , and (H3) forces the weight m m m to occur.
Remark 5.5. Assumption (H2) holds as soon as r ≥ 2 r\ge2 r ≥ 2 . Indeed, if h ≤ 1 h\le1 h ≤ 1 , then C < m \mathcal{C}_{<m} C < m is generated by a single codeword, and all nonzero F q m \mathbb{F}_{q^m} F q m -multiples of a codeword have the same rank, so at most one weight smaller than m m m occurs. If h = k h=k h = k , assumption (H3) is equivalent to n ≥ m n\ge m n ≥ m ; and if n > ( k − 1 ) m n>(k-1)m n > ( k − 1 ) m , then (H2) implies (H3), since ( k − h + 1 ) m ≤ ( k − 1 ) m (k-h+1)m\le(k-1)m ( k − h + 1 ) m ≤ ( k − 1 ) m . Finally, if (H4) fails, then d r = m − 1 d_r=m-1 d r = m − 1 , the greatest common divisor of the deficiencies m − d i m-d_i m − d i equals one, and no reduction to a larger field can be expected.
The first result shows that deleting a controlled number of coordinates turns C \mathcal{C} C into an expansion from a larger field, with an explicit effect on the ranks of the codewords.
Theorem 5.6. Assume (H1)–(H4). Then there exists a divisor t t t of m m m with
a ≤ t ≤ N − a and t ∣ n − d r , a\le t\le N-a\qquad\text{and}\qquad t\mid n-d_r, a ≤ t ≤ N − a and t ∣ n − d r , such that, after replacing C \mathcal{C} C by an equivalent code, the map
π : C ⟶ F q m n − t + a \pi:\mathcal{C}\longrightarrow\mathbb{F}_{q^m}^{n-t+a} π : C ⟶ F q m n − t + a deleting the last t − a t-a t − a coordinates has the following properties.
(i) The punctured code π ( C ) \pi(C) π ( C ) is, up to equivalence, the F q \mathbb{F}_q F q -expansion of a [ n − t + a t , k ′ ] q m / q t \left[\frac{n-t+a}{t},k'\right]_{q^m/q^t} [ t n − t + a , k ′ ] q m / q t code, where k ′ = dim F q m π ( C ) k'=\dim_{\mathbb{F}_{q^m}}\pi(C) k ′ = dim F q m π ( C ) .
(ii) For every c ∈ C c\in C c ∈ C ,
w ( π ( c ) ) = t ⌈ w ( c ) t ⌉ . w(\pi(c))=t\left\lceil\frac{w(c)}{t}\right\rceil. w ( π ( c )) = t ⌈ t w ( c ) ⌉ .
Equivalently, since t ∣ m t\mid m t ∣ m , the deficiency m − w ( π ( c ) ) m-w(\pi(c)) m − w ( π ( c )) is the least multiple of t t t which is at least m − w ( c ) m-w(c) m − w ( c ) . In particular, w ( π ( c ) ) = m w(\pi(c))=m w ( π ( c )) = m if and only if w ( c ) = m w(c)=m w ( c ) = m .
Proof. Let U U U be the system associated with G G G , and put W = U ⊥ ′ W=U^{\perp'} W = U ⊥ ′ and S = ⟨ W ⟩ F q m S=\langle W\rangle_{\mathbb{F}_{q^m}} S = ⟨ W ⟩ F q m . As in the proof of Lemma 5.1, dim F q m S = h ≥ 2 \dim_{\mathbb{F}_{q^m}}S=h\ge2 dim F q m S = h ≥ 2 , and (H3) gives N = dim F q W ≤ ( h − 1 ) m N=\dim_{\mathbb{F}_q}W\le(h-1)m N = dim F q W ≤ ( h − 1 ) m . By (6), the positive point weights of L W L_W L W are m − d r < ⋯ < m − d 1 m-d_r<\cdots<m-d_1 m − d r < ⋯ < m − d 1 , whose minimum is a ≥ 2 a\ge2 a ≥ 2 . By (H1), Theorem 3.7 applies to W W W : there are a divisor t ∣ m t\mid m t ∣ m and W t = ⟨ W ⟩ F q t W_t=\langle W\rangle_{\mathbb{F}_{q^t}} W t = ⟨ W ⟩ F q t such that
L W t = L W , dim F q W t = N + t − a , a ≤ t ≤ N − a , t ∣ N − a . L_{W_t}=L_W,\qquad\dim_{\mathbb{F}_q}W_t=N+t-a,\qquad a\le t\le N-a,\qquad t\mid N-a. L W t = L W , dim F q W t = N + t − a , a ≤ t ≤ N − a , t ∣ N − a .
Since N − a = ( k − 1 ) m − n + d r N-a=(k-1)m-n+d_r N − a = ( k − 1 ) m − n + d r and t ∣ m t\mid m t ∣ m , also t ∣ n − d r t\mid n-d_r t ∣ n − d r .
Put U t = W t ⊥ ′ U_t=W_t^{\perp'} U t = W t ⊥ ′ . Since W ⊆ W t W\subseteq W_t W ⊆ W t , we have U t ⊆ U U_t\subseteq U U t ⊆ U and
dim F q U t = k m − dim F q W t = n − t + a ; \dim_{\mathbb{F}_q}U_t=km-\dim_{\mathbb{F}_q}W_t=n-t+a; dim F q U t = k m − dim F q W t = n − t + a ;
by Lemma 2.5 , U t U_t U t is F q t \mathbb{F}_{q^t} F q t -linear. Choose an F q \mathbb{F}_q F q -basis of U U U whose first n − t + a n-t+a n − t + a vectors form a basis of U t U_t U t . The matrix having these vectors as columns is G A GA G A for some A ∈ GL ( n , q ) A\in\operatorname{GL}(n,q) A ∈ GL ( n , q ) , and it generates a code equivalent to C C C ; we replace G G G by G A GA G A . Then π ( x G ) = x G t \pi(xG)=xG_t π ( x G ) = x G t , where G t G_t G t consists of the first n − t + a n-t+a n − t + a columns of G G G , which form an F q \mathbb{F}_q F q -basis of U t U_t U t .
(i) The code π ( C ) \pi(C) π ( C ) is generated by the rows of G t G_t G t , whose rank is k ′ = dim F q m ⟨ U t ⟩ F q m k'=\dim_{\mathbb{F}_{q^m}}\langle U_t\rangle_{\mathbb{F}_{q^m}} k ′ = dim F q m ⟨ U t ⟩ F q m . If k ′ < k k'<k k ′ < k , we identify ⟨ U t ⟩ F q m \langle U_t\rangle_{\mathbb{F}_{q^m}} ⟨ U t ⟩ F q m with F q m k ′ \mathbb{F}_{q^m}^{k'} F q m k ′ , so that U t U_t U t becomes an [ n − t + a , k ′ ] q m / q [n-t+a,k']_{q^m/q} [ n − t + a , k ′ ] q m / q system to which Definition 2.8 applies. Choose an F q t \mathbb{F}_{q^t} F q t -basis of U t U_t U t and expand it with respect to a fixed F q \mathbb{F}_q F q -basis of F q t \mathbb{F}_{q^t} F q t , as in Definition 2.8. The resulting vectors form another F q \mathbb{F}_q F q -basis of U t U_t U t , so the matrix having them as columns generates a code equivalent to π ( C ) \pi(C) π ( C ) . Hence π ( C ) \pi(C) π ( C ) is, up to equivalence, an F q \mathbb{F}_q F q -expansion from F q t \mathbb{F}_{q^t} F q t .
(ii) The case c = 0 c=0 c = 0 is trivial. Let x ∈ F q m ∖ { 0 } x\in\mathbb{F}_{q^m}\setminus\{0\} x ∈ F q m ∖ { 0 } , P = ⟨ x ⟩ F q m P=\langle x\rangle_{\mathbb{F}_{q^m}} P = ⟨ x ⟩ F q m and c = x G c=xG c = x G . Applying (6) to U U U and to U t U_t U t gives
w ( c ) = m − w W ( P ) , w ( π ( c ) ) = m − w W t ( P ) . w(c)=m-w_W(P),\qquad w(\pi(c))=m-w_{W_t}(P). w ( c ) = m − w W ( P ) , w ( π ( c )) = m − w W t ( P ) .
If w ( c ) = m w(c)=m w ( c ) = m , then P ∉ L W = L W t P\notin L_W=L_{W_t} P ∈ / L W = L W t , and hence w ( π ( c ) ) = m w(\pi(c))=m w ( π ( c )) = m . Otherwise w W ( P ) = m − w ( c ) > 0 w_W(P)=m-w(c)>0 w W ( P ) = m − w ( c ) > 0 . Since ( W t ∩ P ) / ( W ∩ P ) (W_t\cap P)/(W\cap P) ( W t ∩ P ) / ( W ∩ P ) embeds into W t / W W_t/W W t / W , which has dimension t − a t-a t − a ,
m − w ( c ) ≤ w W t ( P ) ≤ m − w ( c ) + t − a . m-w(c)\le w_{W_t}(P)\le m-w(c)+t-a. m − w ( c ) ≤ w W t ( P ) ≤ m − w ( c ) + t − a .
As W t W_t W t is F q t \mathbb{F}_{q^t} F q t -linear, w W t ( P ) w_{W_t}(P) w W t ( P ) is a multiple of t t t ; since the interval above has length t − a < t t-a<t t − a < t , it contains at most one multiple of t t t . The least multiple of t t t which is at least m − w ( c ) m-w(c) m − w ( c ) lies between m − w ( c ) m-w(c) m − w ( c ) and w W t ( P ) w_{W_t}(P) w W t ( P ) , hence in the interval, and therefore equals w W t ( P ) w_{W_t}(P) w W t ( P ) . Thus
w ( π ( c ) ) = m − t ⌈ m − w ( c ) t ⌉ = t ⌊ w ( c ) t ⌋ , w(\pi(c))=m-t\left\lceil\frac{m-w(c)}{t}\right\rceil=t\left\lfloor\frac{w(c)}{t}\right\rfloor, w ( π ( c )) = m − t ⌈ t m − w ( c ) ⌉ = t ⌊ t w ( c ) ⌋ ,
where the last equality holds because t ∣ m t\mid m t ∣ m .
Remark 5.7. Theorems 4.1 and 5.6 go in opposite directions. In Theorem 4.1 , Theorem 3.7 is applied to the system U U U itself; the subspace ⟨ U ⟩ F q t \langle U\rangle_{\mathbb{F}_{q^t}} ⟨ U ⟩ F q t contains U U U , and C C C is obtained by deleting coordinates from an expansion. In Theorem 5.6 , it is applied to U ⊥ ′ U^{\perp'} U ⊥ ′ ; enlarging U ⊥ ′ U^{\perp'} U ⊥ ′ to W t W_t W t reduces U U U to U t = W t ⊥ ′ U_t=W_t^{\perp'} U t = W t ⊥ ′ , so that deleting coordinates of C C C produces an expansion. For two-dimensional codes of length n < m n<m n < m only the first approach is available, since dim F q U ⊥ ′ = 2 m − n > m \dim_{\mathbb{F}_q}U^{\perp'}=2m-n>m dim F q U ⊥ ′ = 2 m − n > m and hence L U ⊥ ′ = PG ( 1 , q m ) L_{U^{\perp'}}=\operatorname{PG}(1,q^m) L U ⊥ ′ = PG ( 1 , q m ) by Lemma 2.2 . For n = m n=m n = m and k = 2 k=2 k = 2 both apply, and both give t = a t=a t = a : for Theorem 4.1 see Remark 4.2 (c), and in Theorem 5.6 one has t ∣ n − d r = a t\mid n-d_r=a t ∣ n − d r = a .
The next proposition describes the punctured code explicitly.
Proposition 5.8. Assume (H1)–(H4), and let t t t and π \pi π be as in Theorem 5.6 .
(i) The map π \pi π is injective, so that π ( C ) \pi(C) π ( C ) is a nondegenerate [ n − t + a , k ] q m / q [n-t+a,k]_{q^{m}/q} [ n − t + a , k ] q m / q code, if and only if d 1 ≥ t d_1 \ge t d 1 ≥ t .
(ii) For every i = 1 , … , r i=1,\ldots,r i = 1 , … , r ,
d i mod t ≤ t − a . d_i \mathbin{\operatorname{mod}} t \le t-a. d i mod t ≤ t − a . Moreover, if a < t a<t a < t , then d r mod t = t − a d_r \mathbin{\operatorname{mod}} t=t-a d r mod t = t − a .
(iii) Suppose that d 1 ≥ t d_1 \ge t d 1 ≥ t . Then the nonzero weights of π ( C ) \pi(C) π ( C ) are m m m together with the distinct values among
d i ( t ) = t ⌊ d i t ⌋ , i = 1 , … , r ; d_i^{(t)}=t\left\lfloor\frac{d_i}{t}\right\rfloor,\qquad i=1,\ldots,r; d i ( t ) = t ⌊ t d i ⌋ , i = 1 , … , r ; they are all multiples of t t t , and d r ( t ) = m − t d_r^{(t)}=m-t d r ( t ) = m − t . Moreover,
A m ( π ( C ) ) = A m ( C ) , A_m(\pi(C))=A_m(C), A m ( π ( C )) = A m ( C ) , where A j A_j A j denotes the number of codewords of rank j j j , and for every j < m j<m j < m ,
A j ( π ( C ) ) = ∑ 1 ≤ i ≤ r d i ( t ) = j A d i ( C ) . A_j(\pi(C))=\sum_{\substack{1\le i\le r\\d_i^{(t)}=j}} A_{d_i}(C). A j ( π ( C )) = 1 ≤ i ≤ r d i ( t ) = j ∑ A d i ( C ) .
Proof. By Theorem 5.6 (ii), π ( c ) = 0 \pi(c)=0 π ( c ) = 0 if and only if w ( c ) < t w(c)<t w ( c ) < t . Hence π \pi π is injective if and only if d 1 ≥ t d_1\ge t d 1 ≥ t . The columns of the punctured generator matrix are F q \mathbb{F}_q F q -linearly independent, being columns of G G G ; so, when π \pi π is injective, π ( C ) \pi(C) π ( C ) is a nondegenerate code of dimension k k k . This proves (i).
Deleting t − a t-a t − a coordinates of a vector decreases its rank by at most t − a t-a t − a . Hence, for a codeword c c c of rank d i d_i d i , Theorem 5.6 (ii) gives
d i mod t = d i − t ⌊ d i t ⌋ = w ( c ) − w ( π ( c ) ) ≤ t − a . d_i \mathbin{\operatorname{mod}} t=d_i-t\left\lfloor\frac{d_i}{t}\right\rfloor=w(c)-w(\pi(c))\le t-a. d i mod t = d i − t ⌊ t d i ⌋ = w ( c ) − w ( π ( c )) ≤ t − a .
If a < t a<t a < t , then d r = m − a ≡ t − a ( m o d t ) d_r=m-a\equiv t-a\pmod t d r = m − a ≡ t − a ( mod t ) , because t ∣ m t\mid m t ∣ m and 0 < t − a < t 0<t-a<t 0 < t − a < t . This proves (ii).
Under the assumption of (iii), π \pi π is a bijection from C C C onto π ( C ) \pi(C) π ( C ) which, by Theorem 5.6 (ii), maps codewords of rank d i d_i d i to codewords of rank d i ( t ) d_i^{(t)} d i ( t ) and codewords of rank m m m to codewords of rank m m m . All these values are multiples of t t t , and d r ( t ) = t ⌊ ( m − a ) / t ⌋ = m − t d_r^{(t)}=t\lfloor(m-a)/t\rfloor=m-t d r ( t ) = t ⌊( m − a ) / t ⌋ = m − t because 1 ≤ a ≤ t 1\le a\le t 1 ≤ a ≤ t and t ∣ m t\mid m t ∣ m . The formulas for the multiplicities follow.
Puncturing may decrease the number of distinct nonzero weights, since different weights may have the same largest multiple of t t t below them. Proposition 5.8 (ii) is a genuine restriction on the weight spectrum of codes satisfying (H1)–(H4). For instance, if C C C has exactly three nonzero weights d < w < m d<w<m d < w < m , then there is a divisor t t t of m m m with
m − w ≤ t , t ∣ n − w , d mod t ≤ t − ( m − w ) . m-w\le t,\qquad t\mid n-w,\qquad d\mathbin{\operatorname{mod}}t\le t-(m-w). m − w ≤ t , t ∣ n − w , d mod t ≤ t − ( m − w ) .
Example 5.10
Suppose that m = 12 m=12 m = 12 , that a code C C C satisfying (H1)–(H4) has nonzero rank weights
5 , 6 , 8 , 10 , 12 , 5,\ 6,\ 8,\ 10,\ 12, 5 , 6 , 8 , 10 , 12 ,
and that t = 4 t = 4 t = 4 in Theorem 5.6 . Then a = 12 − 10 = 2 a = 12 - 10 = 2 a = 12 − 10 = 2 , so t − a = 2 t - a = 2 t − a = 2 coordinates are deleted. The residues of the nonmaximum weights modulo 4 4 4 are 1 , 2 , 0 , 2 1, 2, 0, 2 1 , 2 , 0 , 2 , all at most t − a = 2 t - a = 2 t − a = 2 , as required by Proposition 5.8 (ii). The ranks transform as
5 ↦ 4 , 6 ↦ 4 , 8 ↦ 8 , 10 ↦ 8 , 12 ↦ 12. 5 \mapsto4,\qquad6 \mapsto4,\qquad8 \mapsto8,\qquad10 \mapsto8,\qquad12 \mapsto12. 5 ↦ 4 , 6 ↦ 4 , 8 ↦ 8 , 10 ↦ 8 , 12 ↦ 12.
Since d 1 = 5 ≥ t d_1 = 5 \ge t d 1 = 5 ≥ t , the punctured code is a nondegenerate [ n − 2 , k ] q 12 / q [n-2,k]_{q^{12}/q} [ n − 2 , k ] q 12 / q code with nonzero weights 4 , 8 , 12 4, 8, 12 4 , 8 , 12 , and
A 4 ( π ( C ) ) = A 5 ( C ) + A 6 ( C ) , A 8 ( π ( C ) ) = A 8 ( C ) + A 10 ( C ) , A 12 ( π ( C ) ) = A 12 ( C ) . A_4(\pi(\mathcal{C})) = A_5(\mathcal{C}) + A_6(\mathcal{C}),\qquad A_8(\pi(\mathcal{C})) = A_8(\mathcal{C}) + A_{10}(\mathcal{C}),\qquad A_{12}(\pi(\mathcal{C})) = A_{12}(\mathcal{C}). A 4 ( π ( C )) = A 5 ( C ) + A 6 ( C ) , A 8 ( π ( C )) = A 8 ( C ) + A 10 ( C ) , A 12 ( π ( C )) = A 12 ( C ) .
Thus four distinct nonmaximum weights collapse to two. By contrast, 7 7 7 cannot be a weight of such a code: 7 m o d 4 = 3 > t − a 7 \bmod4 = 3 > t - a 7 mod 4 = 3 > t − a . Equivalently, a codeword of rank 7 7 7 would have to lose three units of rank when only two coordinates are deleted.
We now bring in the divisor-gap condition of Definition 3.5 .
Corollary 5.11. Assume (H1)–(H4), and put e = gcd ( m − d 1 , … , m − d r ) e = \gcd(m - d_1,\ldots,m - d_r) e = g cd( m − d 1 , … , m − d r ) . If D m ( e , N ) = ∅ D_m(e,N) = \varnothing D m ( e , N ) = ∅ , then e = m − d r e = m - d_r e = m − d r , and C \mathcal{C} C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / e , k ] q m / q e [n/e,k]_{q^m/q^e} [ n / e , k ] q m / q e rank-metric code. In particular,
e ∣ m , e ∣ n , e ∣ d i for every i . e \mid m,\qquad e \mid n,\qquad e \mid d_i\ \text{ for every } i. e ∣ m , e ∣ n , e ∣ d i for every i . Moreover, every divisor t t t as in Theorem 5.6 equals e e e , so that no coordinate is deleted.
Proof. Let t t t be as in Theorem 5.6 . Since e e e divides m − d r = a m - d_r = a m − d r = a ,
e ≤ a ≤ t ≤ N − a ≤ N − e . e \le a \le t \le N - a \le N - e. e ≤ a ≤ t ≤ N − a ≤ N − e .
As t ∣ m t \mid m t ∣ m and D m ( e , N ) = ∅ D_m(e,N) = \varnothing D m ( e , N ) = ∅ , we get t = e t = e t = e , and then e ≤ a ≤ t e \le a \le t e ≤ a ≤ t forces a = t = e a = t = e a = t = e . Thus t − a = 0 t - a = 0 t − a = 0 , the map π \pi π is the identity, and Theorem 5.6 (i) shows that C \mathcal{C} C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / e , k ] q m / q e [n/e,k]_{q^m/q^e} [ n / e , k ] q m / q e code; in particular e ∣ n e \mid n e ∣ n , and e ∣ m e \mid m e ∣ m because t ∣ m t \mid m t ∣ m . Since expansion multiplies all rank weights by e e e , every d i d_i d i is divisible by e e e . □
Corollary 5.12. Let C \mathcal{C} C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q rank-metric code with nonzero weights d < w < m d < w < m d < w < m satisfying (H1), (H3) and (H4); assumption (H2) is then automatic by Remark 5.5. Put e = gcd ( m − w , m − d ) e = \gcd(m - w,m - d) e = g cd( m − w , m − d ) . If D m ( e , k m − n ) = ∅ D_m(e,km - n) = \varnothing D m ( e , k m − n ) = ∅ , then e = m − w e = m - w e = m − w . Consequently,
m − w ∣ m − d , m − w ∣ m , m − w ∣ n , m - w \mid m - d,\qquad m - w \mid m,\qquad m - w \mid n, m − w ∣ m − d , m − w ∣ m , m − w ∣ n , and C \mathcal{C} C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n m − w , k ] q m / q m − w \left[\frac{n}{m-w},k\right]_{q^m/q^{m-w}} [ m − w n , k ] q m / q m − w rank-metric code whose nonzero weights are
d m − w , w m − w , m m − w . \frac{d}{m-w},\qquad\frac{w}{m-w},\qquad\frac{m}{m-w}. m − w d , m − w w , m − w m .
Proof. This is Corollary 5.11 with r = 2 r = 2 r = 2 , d 1 = d d_1 = d d 1 = d and d 2 = w d_2 = w d 2 = w . Since expansion multiplies all rank weights by e = m − w e = m - w e = m − w , the weights of the shorter code are obtained by dividing those of C \mathcal{C} C by m − w m - w m − w . □
Corollary 5.11 requires the divisor-gap condition. There is, however, an important case in which no such assumption is needed, namely when the length of the code is a multiple of m m m .
Theorem 5.13. Let C \mathcal{C} C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q rank-metric code whose nonzero rank weights are d 1 < ⋯ < d r < m d_1 < \cdots< d_r < m d 1 < ⋯ < d r < m , with r ≥ 1 r \ge1 r ≥ 1 , together with m m m . Assume that m ∣ n m \mid n m ∣ n , and put a = m − d r a = m - d_r a = m − d r . Then a ∣ m a \mid m a ∣ m , a ∣ n a \mid n a ∣ n , and C \mathcal{C} C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / a , k ] q m / q a [n/a,k]_{q^m/q^a} [ n / a , k ] q m / q a rank-metric code. In particular, every rank weight of C \mathcal{C} C is divisible by a a a .
Proof. Let U U U be an associated system and put W = U ⊥ ′ W = U^{\perp^{\prime}} W = U ⊥ ′ . Since dim F q W = k m − n \dim_{\mathbb{F}_q} W = km-n dim F q W = k m − n and m ∣ n m \mid n m ∣ n , the rank of W W W is a multiple of m m m . By (6) , the positive point weights of L W L_W L W are m − d r < ⋯ < m − d 1 m-d_r < \cdots< m-d_1 m − d r < ⋯ < m − d 1 , whose minimum is a a a . Proposition 3.3 yields a ∣ m a \mid m a ∣ m and shows that W W W is F q a \mathbb{F}_{q^a} F q a -linear, and by Lemma 2.5 so is U = W ⊥ ′ U = W^{\perp^{\prime}} U = W ⊥ ′ . Therefore a ∣ dim F q U = n a \mid\dim_{\mathbb{F}_q} U = n a ∣ dim F q U = n , and Definition 2.8 shows that C C C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / a , k ] q m / q a [n/a,k]_{q^m/q^a} [ n / a , k ] q m / q a code. Since expansion multiplies all rank weights by a a a , every rank weight of C C C is divisible by a a a .
Remark 5.14. For two-dimensional codes, the square case is already covered by [14 Proposition IV.1 and Corollary IV.4] . More precisely, let C C C be a nondegenerate [ m , 2 ] q m / q [m,2]_{q^m/q} [ m , 2 ] q m / q code and let m − e m-e m − e be its second largest nonzero rank weight. Then e ∣ m e \mid m e ∣ m , all rank weights of C C C are divisible by e e e , and C C C is equivalent to a code arising from F q e \mathbb{F}_{q^e} F q e . Thus, in the square case, no divisor-gap assumption is required.
Codes with two or three nonzero weights
In this section we collect the consequences of the previous sections for codes with two or three nonzero weights. By Proposition 2.6 and Remark 2.7, if a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code has length n ≥ m n \ge m n ≥ m , then m m m is one of its weights. For such codes, Lemmas 5.1 and 5.3 and Corollary 5.4 give a dichotomy:
either C < m C_{<m} C < m contains no codeword of rank m m m ; equivalently, h ( C ) = k − ⌊ n / m ⌋ h(C) = k - \lfloor n/m \rfloor h ( C ) = k − ⌊ n / m ⌋ , and C C C is the direct sum of a simplex code and a code of length smaller than m m m (§ 5.1 );
or C < m C_{<m} C < m contains codewords of rank m m m ; equivalently, n ≥ ( k − h ( C ) + 1 ) m n \ge(k-h(C)+1)m n ≥ ( k − h ( C ) + 1 ) m , and the results of § 5.2 apply.
Two-dimensional codes of length n ≤ m n \le m n ≤ m have no codeword of rank m m m unless n = m n=m n = m ; they are treated in § 4 . We first need two auxiliary results.
Lemma 6.1 can be deduced from the classification of constant rank-weight codes in [16 ] .
Lemma 6.1. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code with n ≤ m − 1 n \le m-1 n ≤ m − 1 whose nonzero codewords all have the same rank. Then k = 1 k=1 k = 1 .
The next lemma shows that, for linear sets with a single positive point weight, no divisor-gap condition is needed in Theorem 3.9 .
Lemma 6.2. Let q ≥ m q \ge m q ≥ m , let U ≤ F q V U \le_{\mathbb{F}_q} V U ≤ F q V , and put S = ⟨ U ⟩ F q m S = \langle U\rangle_{\mathbb{F}_{q^m}} S = ⟨ U ⟩ F q m , h = dim F q m S ≥ 2 h = \dim_{\mathbb{F}_{q^m}} S \ge2 h = dim F q m S ≥ 2 and N = dim F q U ≤ ( h − 1 ) m N = \dim_{\mathbb{F}_q} U \le(h-1)m N = dim F q U ≤ ( h − 1 ) m . Assume that all points of L U L_U L U have the same weight a ≥ 2 a \ge2 a ≥ 2 . Then a ∣ m a \mid m a ∣ m , a ∣ N a \mid N a ∣ N , U U U is F q a \mathbb{F}_{q^a} F q a -linear and
dim F q a ( U ∩ P ) = 1 for every P ∈ L U , \dim_{\mathbb{F}_{q^a}}(U \cap P) = 1 \qquad\text{for every } P \in L_U, dim F q a ( U ∩ P ) = 1 for every P ∈ L U , that is, U U U is F q a \mathbb{F}_{q^a} F q a -scattered. Moreover, every divisor t t t as in Theorem 3.7 equals a a a .
Proof. All the assertions except the last one are [22 Corollary III.3] , applied in S S S instead of V V V . Let t t t and W = ⟨ U ⟩ F q t W = \langle U\rangle_{\mathbb{F}_{q^t}} W = ⟨ U ⟩ F q t be as in Theorem 3.7 , so that L W = L U L_W = L_U L W = L U , dim F q W = N + t − a \dim_{\mathbb{F}_q} W = N+t-a dim F q W = N + t − a and a ≤ t ≤ N − a a \le t \le N-a a ≤ t ≤ N − a . For P ∈ L U P \in L_U P ∈ L U , the quotient ( W ∩ P ) / ( U ∩ P ) (W \cap P)/(U \cap P) ( W ∩ P ) / ( U ∩ P ) embeds into W / U W/U W / U , so a ≤ w W ( P ) ≤ a + ( t − a ) = t a \le w_W(P) \le a+(t-a)=t a ≤ w W ( P ) ≤ a + ( t − a ) = t ; as w W ( P ) w_W(P) w W ( P ) is a positive multiple of t t t , we get w W ( P ) = t w_W(P)=t w W ( P ) = t . Applying (1) to U U U and to W W W ,
q N − 1 q a − 1 = ∣ L U ∣ = ∣ L W ∣ = q N + t − a − 1 q t − 1 , \frac{q^N-1}{q^a-1}=|L_U|=|L_W|=\frac{q^{N+t-a}-1}{q^t-1}, q a − 1 q N − 1 = ∣ L U ∣ = ∣ L W ∣ = q t − 1 q N + t − a − 1 ,
that is, ( q N − a − 1 ) ( q t − q a ) = 0 (q^{N-a}-1)(q^t-q^a)=0 ( q N − a − 1 ) ( q t − q a ) = 0 . Since N − a ≥ t ≥ 1 N-a \ge t \ge1 N − a ≥ t ≥ 1 , we obtain t = a t=a t = a .
Two-weight codes
The study of two-weight rank-metric codes was initiated by Pratihar and Randrianarisoa [15 ] , who considered antipodal two-weight codes. They proved that such codes have dimension two [15 Theorem 2] and that n − d ∣ n n-d \mid n n − d ∣ n , where d < n d<n d < n is the other nonzero weight [15 Corollary 1] . Since every nondegenerate code contains a codeword of rank min { m , n } \min\{m,n\} min { m , n } [2 Proposition 3.11] , the nonzero weights of a nondegenerate two-weight code are d d d and min { m , n } \min\{m,n\} min { m , n } . Hence two-weight codes of length n ≤ m n\leq m n ≤ m are antipodal and two-dimensional, so the restriction k = 2 k=2 k = 2 in Theorem 6.4 below is no loss of generality. Two-weight codes of length n ≥ m n\geq m n ≥ m have nonzero weights d < m d<m d < m and m m m ; they are treated in Theorem 6.3 .
For q ≥ m q\geq m q ≥ m , both cases were studied in [22 ] . There it is shown that antipodal two-weight codes are F q n − d \mathbb{F}_{q^{n-d}} F q n − d -scattered codes [22 Theorem IV.8] , and that, for n > m n>m n > m , the system of a two-weight code is the dual of an F q m − d \mathbb{F}_{q^{m-d}} F q m − d -scattered subspace [22 Corollary IV.10 and Theorem IV.11] . Theorems 6.4 and 6.3 (ii) recover these results, and remove the assumption on q q q when m ∣ n m\mid n m ∣ n .
They also show that the second statement of [22 ] requires an additional hypothesis. The counting argument in the proofs of [22 Corollary IV.10 and Theorem IV.11] tacitly assumes h ( C ) ≥ 2 h(C)\geq2 h ( C ) ≥ 2 . When h ( C ) = 1 h(C)=1 h ( C ) = 1 , it yields k m − n = m − d km-n=m-d k m − n = m − d rather than a contradiction, and the conclusion m − d ∣ m m-d\mid m m − d ∣ m may fail. For instance, for every q q q and every k ≥ 2 k\geq2 k ≥ 2 , the direct sum of a [ 3 ( k − 1 ) , k − 1 ] q 3 / q [3(k-1),k-1]_{q^3/q} [ 3 ( k − 1 ) , k − 1 ] q 3 / q simplex code and a nondegenerate [ 1 , 1 ] q 3 / q [1,1]_{q^3/q} [ 1 , 1 ] q 3 / q code is a nondegenerate two-weight code with weights 1 and 3, although 3 − 1 ∤ 3 3-1\nmid3 3 − 1 ∤ 3 . Theorem 6.3 (i) shows that these direct sums are the only exceptions. Every two-weight code with h ( C ) = 1 h(C)=1 h ( C ) = 1 is the direct sum of a [ ( k − 1 ) m , k − 1 ] q m / q [(k-1)m,k-1]_{q^m/q} [( k − 1 ) m , k − 1 ] q m / q simplex code and a nondegenerate [ d , 1 ] q m / q [d,1]_{q^m/q} [ d , 1 ] q m / q code. Thus the classification of [22 ] holds precisely for the two-weight codes with h ( C ) ≥ 2 h(C)\geq2 h ( C ) ≥ 2 , that is, for those whose associated system contains no F q m \mathbb{F}_{q^m} F q m -hyperplane.
Theorem 6.3. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code whose nonzero weights are d < m d<m d < m and m m m , let U U U be an associated system, and put a = m − d a=m-d a = m − d and N = k m − n N=km-n N = k m − n . Then a ∣ N a\mid N a ∣ N ,
A d ( C ) = ( q m − 1 ) q N − 1 q a − 1 , A m ( C ) = q k m − 1 − A d ( C ) , A_d(C)=(q^m-1)\frac{q^N-1}{q^a-1},\qquad A_m(C)=q^{km}-1-A_d(C), A d ( C ) = ( q m − 1 ) q a − 1 q N − 1 , A m ( C ) = q k m − 1 − A d ( C ) , and exactly one of the following holds.
(i) h ( C ) = 1 h(C)=1 h ( C ) = 1 . Then k ≥ 2 k\geq2 k ≥ 2 , n = ( k − 1 ) m + d n=(k-1)m+d n = ( k − 1 ) m + d and, up to equivalence, C = C ~ × C ′ C=\widetilde{C}\times C' C = C × C ′ , where C ~ \widetilde{C} C is a [ ( k − 1 ) m , k − 1 ] q m / q [(k-1)m,k-1]_{q^m/q} [( k − 1 ) m , k − 1 ] q m / q simplex code and C ′ C' C ′ is a nondegenerate [ d , 1 ] q m / q [d,1]_{q^m/q} [ d , 1 ] q m / q code. Conversely, for every k ≥ 2 k\geq2 k ≥ 2 and 1 ≤ d ≤ m − 1 1\leq d\leq m-1 1 ≤ d ≤ m − 1 , every such code is a nondegenerate two-weight code with weights d d d and m m m and with h ( C ) = 1 h(C)=1 h ( C ) = 1 .
(ii) h ( C ) ≥ 2 h(C)\geq2 h ( C ) ≥ 2 . Then C < m C_{<m} C < m contains codewords of rank m m m , that is, n ≥ ( k − h ( C ) + 1 ) m n\geq(k-h(C)+1)m n ≥ ( k − h ( C ) + 1 ) m . If moreover q ≥ m q\geq m q ≥ m or m ∣ n m\mid n m ∣ n or d = n − 1 d=n-1 d = n − 1 , then
a ∣ m , a ∣ n , a ∣ d , a\mid m,\qquad a\mid n,\qquad a\mid d, a ∣ m , a ∣ n , a ∣ d , U U U and U ⊥ U^\perp U ⊥ are F q a \mathbb{F}_{q^a} F q a -linear, U ⊥ U^\perp U ⊥ is F q a \mathbb{F}_{q^a} F q a -scattered, and C C C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / a , k ] q m / q a [n/a,k]_{q^m/q^a} [ n / a , k ] q m / q a code with nonzero weights d / a d/a d / a and m / a m/a m / a .
Proof. Let W = U ⊥ W=U^\perp W = U ⊥ . Then dim F q W = N \dim_{\mathbb{F}_q}W=N dim F q W = N and since, by (6) , every point P ∈ L W P\in L_W P ∈ L W has weight u W ( P ) = m − d = a u_W(P)=m-d=a u W ( P ) = m − d = a , we have, by (1) , that ∣ L W ∣ = q N − 1 q a − 1 \lvert L_W\rvert=\frac{q^N-1}{q^a-1} ∣ L W ∣ = q a − 1 q N − 1 . So q a − 1 ∣ q N − 1 q^a-1\mid q^N-1 q a − 1 ∣ q N − 1 and a ∣ N a\mid N a ∣ N . Furthermore,
A d ( C ) = ( q m − 1 ) ∣ L W ∣ = ( q m − 1 ) q N − 1 q a − 1 , A_d(C)=(q^m-1)\lvert L_W\rvert=(q^m-1)\frac{q^N-1}{q^a-1}, A d ( C ) = ( q m − 1 ) ∣ L W ∣ = ( q m − 1 ) q a − 1 q N − 1 ,
and A m ( C ) = q k m − 1 − A d ( C ) A_m(C)=q^{km}-1-A_d(C) A m ( C ) = q k m − 1 − A d ( C ) . Since the weight d d d occurs, h ( C ) ≥ 1 h(C)\geq1 h ( C ) ≥ 1 , so exactly one of (i) and (ii) holds.
(i) Let h ( C ) = 1 h(C)=1 h ( C ) = 1 . Then C < m = { c ∈ C : w ( c ) = d } ∪ { 0 } C_{<m}=\{c\in C:w(c)=d\}\cup\{0\} C < m = { c ∈ C : w ( c ) = d } ∪ { 0 } is generated by one codeword c ∈ C c\in C c ∈ C of rank weight d = w ( c ) < m d=w(c)<m d = w ( c ) < m , so it contains no codeword of rank m m m . By Lemma 5.3 , (a)⇒ \Rightarrow ⇒ (c), we get that 1 = k − ⌊ n / m ⌋ 1=k-\lfloor n/m\rfloor 1 = k − ⌊ n / m ⌋ . Since C C C contains a codeword of weight m m m , we have n ≥ m n\ge m n ≥ m , so k ≥ 2 k\ge2 k ≥ 2 . By Corollary 5.4, we get up to equivalence, that
C = C ~ × C ′ , C=\widetilde{C}\times C', C = C × C ′ ,
where C ~ \widetilde{C} C is a [ ( k − 1 ) m , k − 1 ] q m / q [(k-1)m,k-1]_{q^m/q} [( k − 1 ) m , k − 1 ] q m / q simplex code and C ′ C' C ′ is a nondegenerate [ ε , 1 ] q m / q [\varepsilon,1]_{q^m/q} [ ε , 1 ] q m / q code with ε = n − ( k − 1 ) m = d \varepsilon=n-(k-1)m=d ε = n − ( k − 1 ) m = d ; indeed, the entries of a generator of C ′ C' C ′ are F q \mathbb{F}_q F q -linearly independent, so every nonzero codeword of C ′ C' C ′ has rank ε \varepsilon ε , and by Corollary 5.4 these are exactly the codewords of C C C of rank smaller than m m m , i.e. of rank d d d . Conversely, let k ≥ 2 k\ge2 k ≥ 2 , 1 ≤ d ≤ m − 1 1\le d\le m-1 1 ≤ d ≤ m − 1 and C = C ~ × C ′ C=\widetilde{C}\times C' C = C × C ′ as above. The system of C C C is F q m k − 1 × U ′ \mathbb{F}_{q^m}^{k-1}\times U' F q m k − 1 × U ′ , where U ′ ≤ F q m U'\le\mathbb{F}_{q^m} U ′ ≤ F q m is the d d d -dimensional F q \mathbb{F}_q F q -span of the entries of a generator of C ′ C' C ′ , so C C C is nondegenerate. A codeword ( c ~ , c ′ ) (\widetilde{c},c') ( c , c ′ ) has rank m m m if c ~ ≠ 0 \widetilde{c}\ne0 c = 0 , by Remark 2.9, and rank w ( c ′ ) = d w(c')=d w ( c ′ ) = d if c ~ = 0 ≠ c ′ \widetilde{c}=0\ne c' c = 0 = c ′ ; both cases occur, and C < m = { 0 } × C ′ C_{<m}=\{0\}\times C' C < m = { 0 } × C ′ is one-dimensional, so h ( C ) = 1 h(C)=1 h ( C ) = 1 .
(ii) Let h ( C ) ≥ 2 h(C)\ge2 h ( C ) ≥ 2 . Then dim F q m ( C < m ) ≥ 2 \dim_{\mathbb{F}_{q^m}}(C_{<m})\ge2 dim F q m ( C < m ) ≥ 2 , and since the only possible rank weights in C C C are d d d and m m m , we have that C < m C_{<m} C < m contains codewords of rank m m m . Indeed, put h = h ( C ) h=h(C) h = h ( C ) and S = ⟨ W ⟩ F q m S=\langle W\rangle_{\mathbb{F}_{q^m}} S = ⟨ W ⟩ F q m , so that dim F q m S = h \dim_{\mathbb{F}_{q^m}}S=h dim F q m S = h (see the proof of Lemma 5.1). If C < m C_{<m} C < m contained no codeword of rank m m m , then, by Lemma 5.3 , L W = PG ( S , F q m ) L_W=\operatorname{PG}(S,\mathbb{F}_{q^m}) L W = PG ( S , F q m ) and all its points have weight a a a , so (1) would give
q N − 1 = q h m − 1 q m − 1 ( q a − 1 ) , q^N-1=\frac{q^{hm}-1}{q^m-1}(q^a-1), q N − 1 = q m − 1 q hm − 1 ( q a − 1 ) ,
that is,
q N = q a ( 1 + q m − a q ( h − 1 ) m − 1 q m − 1 ( q a − 1 ) ) . q^N=q^a\left(1+q^{m-a}\frac{q^{(h-1)m}-1}{q^m-1}(q^a-1)\right). q N = q a ( 1 + q m − a q m − 1 q ( h − 1 ) m − 1 ( q a − 1 ) ) .
Since 1 ≤ a ≤ m − 1 1\le a\le m-1 1 ≤ a ≤ m − 1 and h ≥ 2 h\ge2 h ≥ 2 , the factor in brackets is larger than one and congruent to 1 1 1 modulo q q q , a contradiction. By Lemma 5.3 we get that n ≥ ( k − h ( C ) + 1 ) m n\ge(k-h(C)+1)m n ≥ ( k − h ( C ) + 1 ) m , that is, N ≤ ( h − 1 ) m N\le(h-1)m N ≤ ( h − 1 ) m . We may assume a ≥ 2 a\ge2 a ≥ 2 , the case a = 1 a=1 a = 1 being trivial. If q ≥ m q\ge m q ≥ m , Lemma 6.2 , applied to W W W in S S S , shows that a ∣ m a\mid m a ∣ m and that W W W is an F q a \mathbb{F}_{q^a} F q a -scattered F q a \mathbb{F}_{q^a} F q a -subspace; if m ∣ n m\mid n m ∣ n , the same follows from Proposition 3.3 , since N = k m − n N=km-n N = k m − n is a multiple of m m m and all points of L W L_W L W have weight a a a . By Lemma 2.5 , U = W ⊥ U=W^\perp U = W ⊥ is F q a \mathbb{F}_{q^a} F q a -linear; hence a ∣ n a\mid n a ∣ n , a ∣ d = m − a a\mid d=m-a a ∣ d = m − a and, by Definition 2.8, C C C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / a , k ] q m / q a [n/a,k]_{q^m/q^a} [ n / a , k ] q m / q a code with nonzero weights d / a d/a d / a and m / a m/a m / a .
For two-dimensional codes of length at most m m m , the same argument applied to the system itself gives the following result.
Theorem 6.4. Let C C C be a nondegenerate [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code, with n ≤ m n\le m n ≤ m , whose nonzero weights are d < n d<n d < n and n n n , let U U U be an associated system and put a = n − d a=n-d a = n − d . Then a ∣ n a\mid n a ∣ n and
A d ( C ) = ( q m − 1 ) q n − 1 q a − 1 , A n ( C ) = q 2 m − 1 − A d ( C ) . A_d(C)=(q^m-1)\frac{q^n-1}{q^a-1},\qquad A_n(C)=q^{2m}-1-A_d(C). A d ( C ) = ( q m − 1 ) q a − 1 q n − 1 , A n ( C ) = q 2 m − 1 − A d ( C ) . If moreover q ≥ m q\ge m q ≥ m or n = m n=m n = m or d = n − 1 d=n-1 d = n − 1 , then a ∣ m a\mid m a ∣ m , a ∣ d a\mid d a ∣ d , U U U is an F q a \mathbb{F}_{q^a} F q a -scattered F q a \mathbb{F}_{q^a} F q a -subspace of F q m 2 \mathbb{F}_{q^m}^2 F q m 2 , and C C C is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ n / a , 2 ] q m / q a [n/a,2]_{q^m/q^a} [ n / a , 2 ] q m / q a code with nonzero weights d / a d/a d / a and n / a n/a n / a . In particular, if q ≥ m q\ge m q ≥ m and a ≥ 2 a\ge2 a ≥ 2 , every divisor t t t as in Theorem 4.1 equals a a a , so that no coordinate has to be deleted.
Proof. Since dim F q ( U ) = n \dim_{\mathbb{F}_q}(U)=n dim F q ( U ) = n and w ( c ) = n − dim F q ( U ∩ x ⊥ ) w(c)=n-\dim_{\mathbb{F}_q}(U\cap x^\perp) w ( c ) = n − dim F q ( U ∩ x ⊥ ) for any codeword c = x G c=xG c = x G , we get that the hyperplane-intersection spectrum of the associated system U U U is given by { n − n , n − d } \{n-n,n-d\} { n − n , n − d } or { 0 , a } \{0,a\} { 0 , a } . Hence, for every point P P P in L U L_U L U , we have w ( P ) = dim F q ( U ∩ P ) = a w(P)=\dim_{\mathbb{F}_q}(U\cap P)=a w ( P ) = dim F q ( U ∩ P ) = a . Hence q n − 1 = ∣ L U ∣ ( q a − 1 ) q^n-1=|L_U|(q^a-1) q n − 1 = ∣ L U ∣ ( q a − 1 ) by (1) , so a ∣ n a\mid n a ∣ n and the number A d ( C ) A_d(C) A d ( C ) of codewords of rank weight d d d satisfies
A d ( C ) = ( q m − 1 ) ∣ L U ∣ = ( q m − 1 ) q n − 1 q a − 1 . (23) A_d(C)=(q^m-1)|L_U|=(q^m-1)\frac{q^n-1}{q^a-1}. \tag*{(23)} A d ( C ) = ( q m − 1 ) ∣ L U ∣ = ( q m − 1 ) q a − 1 q n − 1 . (23)
Moreover, A n ( C ) = q 2 m − 1 − A d ( C ) A_n(C)=q^{2m}-1-A_d(C) A n ( C ) = q 2 m − 1 − A d ( C ) by (14) . If n = m n=m n = m , then we use the previous Theorem 6.3 , with a = m − d = n − d a=m-d=n-d a = m − d = n − d : here h ( C ) = 2 h(C)=2 h ( C ) = 2 , since h ( C ) = 1 h(C)=1 h ( C ) = 1 would give n = m + d > m n=m+d>m n = m + d > m by Theorem 6.3 (i), so case (ii) applies with m ∣ n m\mid n m ∣ n and shows that a ∣ m a\mid m a ∣ m , a ∣ d a\mid d a ∣ d and U U U is F q a \mathbb{F}_{q^a} F q a -linear; as every point of L U L_U L U has weight a a a , U U U is F q a \mathbb{F}_{q^a} F q a -scattered. If q ≥ m q\ge m q ≥ m , we have the result in [22 Theorem IV.8] (whose hypothesis n = ℓ ( n − d ) n=\ell(n-d) n = ℓ ( n − d ) is a ∣ n a\mid n a ∣ n ) showing that a ∣ m a\mid m a ∣ m , a ∣ d a\mid d a ∣ d and U U U is an F q a \mathbb{F}_{q^a} F q a -scattered F q a \mathbb{F}_{q^a} F q a -subspace of F q m \mathbb{F}_{q^m} F q m . In particular, we have that C C C , up to equivalence, is the F q \mathbb{F}_q F q -expansion of an [ n / a , 2 ] q m / q a [n/a,2]_{q^m/q^a} [ n / a , 2 ] q m / q a code with nonzero weights d / a d/a d / a and n / a n/a n / a . Finally, if q ≥ m q\ge m q ≥ m and a ≥ 2 a\ge2 a ≥ 2 , the divisor t t t in Theorem 4.1 is one given by Theorem 3.7 applied to U U U (step 1 of its proof), so t = a t=a t = a by the last assertion of Lemma 6.2 , and no coordinate has to be deleted.
Remark 6.5. Theorems 6.3 and 6.4 show that no divisor-gap condition is needed for two-weight codes. Let a a a be the difference between the two nonzero weights. If q ≥ m q\ge m q ≥ m , every nondegenerate two-weight code of length n ≥ m n\ge m n ≥ m with h ( C ) ≥ 2 h(C)\ge2 h ( C ) ≥ 2 , as well as every nondegenerate two-weight [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code with n ≤ m n\le m n ≤ m , is, up to equivalence, an F q \mathbb{F}_q F q -expansion of a code over F q a \mathbb{F}_{q^a} F q a whose associated F q a \mathbb{F}_{q^a} F q a -linear set is F q a \mathbb{F}_{q^a} F q a -scattered (U ⊥ U^\perp U ⊥ in Theorem 6.3 , U U U in Theorem 6.4 ); the remaining two-weight codes of length n ≥ m n\ge m n ≥ m are the direct sums of Theorem 6.3 (i). Compare with the description of two-weight rank-metric codes through scattered subspaces in [22 ] . In contrast, Family F 4 \mathcal{F}_4 F 4 with t ≥ 3 t\ge3 t ≥ 3 (Example 4.9; for instance m = 6 m=6 m = 6 , t = 3 t=3 t = 3 , ℓ = 2 \ell=2 ℓ = 2 , which gives the weights 2 , 3 , 5 2,3,5 2 , 3 , 5 ) shows that the analogous statement fails for three weights: a three-weight [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code with n ≤ m n\le m n ≤ m and first gap at least two need not be an expansion.
Three-weight codes
For three-weight codes of length n ≥ m n\ge m n ≥ m , the weights are d < w < m d<w<m d < w < m together with m m m . We treat the two cases of the dichotomy separately.
Theorem 6.6. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code, with n ≥ m n\ge m n ≥ m , whose nonzero weights are d < w < m d<w<m d < w < m and m m m , and assume that C < m C_{<m} C < m contains no codeword of rank m m m . Put h = h ( C ) h=h(C) h = h ( C ) and ε = n − ( k − h ) m \varepsilon=n-(k-h)m ε = n − ( k − h ) m . Then 2 ≤ h ≤ k − 1 2\le h\le k-1 2 ≤ h ≤ k − 1 , 0 < ε ≤ m − 1 0<\varepsilon\le m-1 0 < ε ≤ m − 1 and, up to equivalence, C = C ~ × C ′ C=\widetilde{C}\times C' C = C × C ′ , where C ~ \widetilde{C} C is a [ ( k − h ) m , k − h ] q m / q [(k-h)m,k-h]_{q^m/q} [( k − h ) m , k − h ] q m / q simplex code and C ′ C' C ′ is a nondegenerate [ ε , h ] q m / q [\varepsilon,h]_{q^m/q} [ ε , h ] q m / q code with nonzero weights d < w ≤ ε d<w\le\varepsilon d < w ≤ ε . The weight distribution of C C C is determined by q , m , n , k , d , w q,m,n,k,d,w q , m , n , k , d , w : putting θ = q h m − 1 q m − 1 \theta=\frac{q^{hm}-1}{q^m-1} θ = q m − 1 q hm − 1 and N = k m − n = h m − ε N=km-n=hm-\varepsilon N = k m − n = hm − ε ,
A d ( C ) = q m − 1 q m − d − q m − w [ q N − 1 − θ ( q m − w − 1 ) ] , A_d(C)=\frac{q^m-1}{q^{m-d}-q^{m-w}}\left[q^N-1-\theta\left(q^{m-w}-1\right)\right], A d ( C ) = q m − d − q m − w q m − 1 [ q N − 1 − θ ( q m − w − 1 ) ] , A w ( C ) = q m − 1 q m − d − q m − w [ θ ( q m − d − 1 ) − ( q N − 1 ) ] , A_w(C)=\frac{q^m-1}{q^{m-d}-q^{m-w}}\left[\theta\left(q^{m-d}-1\right)-\left(q^N-1\right)\right], A w ( C ) = q m − d − q m − w q m − 1 [ θ ( q m − d − 1 ) − ( q N − 1 ) ] , A m ( C ) = q k m − q h m . A_m(C)=q^{km}-q^{hm}. A m ( C ) = q k m − q hm . If h = 2 h=2 h = 2 , then w = ε = n − ( k − 2 ) m w=\varepsilon=n-(k-2)m w = ε = n − ( k − 2 ) m ; if moreover q ≥ m q\ge m q ≥ m , then ε − d \varepsilon-d ε − d divides m m m , ε \varepsilon ε and d d d , and C ′ C' C ′ is, up to equivalence, the F q \mathbb{F}_q F q -expansion of an [ ε ε − d , 2 ] q m / q ε − d [\frac{\varepsilon}{\varepsilon-d},2]_{q^m/q^{\varepsilon-d}} [ ε − d ε , 2 ] q m / q ε − d code with nonzero weights d ε − d \frac{d}{\varepsilon-d} ε − d d and ε ε − d \frac{\varepsilon}{\varepsilon-d} ε − d ε .
Proof. By Lemma 5.3 (c), h = k − ⌊ n / m ⌋ ≤ k − 1 h=k-\lfloor n/m\rfloor\le k-1 h = k − ⌊ n / m ⌋ ≤ k − 1 , as n ≥ m n\ge m n ≥ m , and by Corollary 5.4, C = C ~ × C ′ C=\widetilde{C}\times C' C = C × C ′ with C ′ C' C ′ nondegenerate of length ε ≤ m − 1 \varepsilon\le m-1 ε ≤ m − 1 , whose nonzero weights are exactly d d d and w w w . In particular ε ≥ w > 0 \varepsilon\ge w>0 ε ≥ w > 0 . If h = 1 h=1 h = 1 , all nonzero codewords of C ′ C' C ′ would have the same rank; hence h ≥ 2 h\ge2 h ≥ 2 .
Let W = U ⊥ W=U^\perp W = U ⊥ for an associated system U U U . By Lemma 5.3 (d), L W L_W L W is the whole projective space PG ( W / F q m , F q m ) ≅ PG ( h − 1 , q m ) \operatorname{PG}(W/\mathbb{F}_{q^m},\mathbb{F}_{q^m})\cong\operatorname{PG}(h-1,q^m) PG ( W / F q m , F q m ) ≅ PG ( h − 1 , q m ) , whose points have weight m − d m-d m − d or m − w m-w m − w by (6) . If x x x and y y y denote the numbers of points of weight m − d m-d m − d and m − w m-w m − w , respectively, then x + y = θ x+y=\theta x + y = θ and, by (1) , x ( q m − d − 1 ) + y ( q m − w − 1 ) = q N − 1 x(q^{m-d}-1)+y(q^{m-w}-1)=q^N-1 x ( q m − d − 1 ) + y ( q m − w − 1 ) = q N − 1 . Solving this system and using A d ( C ) = ( q m − 1 ) x A_d(C)=(q^m-1)x A d ( C ) = ( q m − 1 ) x , $A_w(C)=(q^m-1)y gives the formulas; A m ( C ) A_m(C) A m ( C ) is given by Corollary 5.4. If h = 2 h=2 h = 2 , then C ′ C' C ′ is a nondegenerate [ ε , 2 ] q m / q [\varepsilon,2]_{q^m/q} [ ε , 2 ] q m / q code with ε ≤ m \varepsilon\le m ε ≤ m , hence it is antipodal (see the beginning of § 4 ), so ε \varepsilon ε is one of its weights and w = ε w=\varepsilon w = ε . The last assertion follows from Theorem 6.4 applied to C ′ C' C ′ .
When C < m C_{<m} C < m contains codewords of rank m m m , the results of § 5.2 specialize as follows.
Theorem 6.7. Let C C C be a nondegenerate [ n , k ] q m / q [n,k]_{q^m/q} [ n , k ] q m / q code whose nonzero weights are d < w < m d<w<m d < w < m and m m m , and assume that C < m C_{<m} C < m contains codewords of rank m m m , that is, n ≥ ( k − h ( C ) + 1 ) m n\ge(k-h(C)+1)m n ≥ ( k − h ( C ) + 1 ) m . Put N = k m − n N=km-n N = k m − n . Then h ( C ) ≥ 2 h(C)\ge2 h ( C ) ≥ 2 , and the following hold.
(i) Assume q ≥ m q\ge m q ≥ m and m − w ≥ 2 m-w\ge2 m − w ≥ 2 . Then there exists a proper divisor t t t of m m m with
m − w ≤ t ≤ N − ( m − w ) , t ∣ n − w , d m o d t ≤ t − ( m − w ) , m-w\le t\le N-(m-w), \qquad t\mid n-w, \qquad d\bmod t\le t-(m-w), m − w ≤ t ≤ N − ( m − w ) , t ∣ n − w , d mod t ≤ t − ( m − w ) , and w m o d t = t − ( m − w ) w\bmod t=t-(m-w) w mod t = t − ( m − w ) if t > m − w t>m-w t > m − w . Deleting t − ( m − w ) t-(m-w) t − ( m − w ) suitable coordinates of C C C yields the F q \mathbb F_q F q -expansion of a code over F q t \mathbb F_{q^t} F q t , and a codeword of rank d d d , w w w or m m m becomes a codeword of rank t ⌊ d / t ⌋ t\lfloor d/t\rfloor t ⌊ d / t ⌋ , m − t m-t m − t or m m m , respectively.
(ii) Assume q ≥ m q\ge m q ≥ m and m − w ≥ 2 m-w\ge2 m − w ≥ 2 , put e = gcd ( m − w , m − d ) e=\gcd(m-w,m-d) e = g cd( m − w , m − d ) , and assume D m ( e , N ) = ∅ \mathcal D_m(e,N)=\varnothing D m ( e , N ) = ∅ . Then e = m − w e=m-w e = m − w ; consequently
m − w ∣ m − d , m − w ∣ m , m − w ∣ n , m-w\mid m-d, \qquad m-w\mid m, \qquad m-w\mid n, m − w ∣ m − d , m − w ∣ m , m − w ∣ n , and C C C is, up to equivalence, the F q \mathbb F_q F q -expansion of an [ n m − w , k ] q m / q m − w \left[\frac{n}{m-w},k\right]_{q^m/q^{m-w}} [ m − w n , k ] q m / q m − w code with nonzero weights d m − w \frac{d}{m-w} m − w d , w m − w \frac{w}{m-w} m − w w and m m − w \frac{m}{m-w} m − w m .
(iii) If m ∣ n m\mid n m ∣ n , then the conclusion of (ii) holds without any assumption on q q q , on m − w m-w m − w or on the divisors of $m.
Proof. Since C C C has two distinct nonmaximum weights, h ( C ) ≥ 2 h(C)\ge2 h ( C ) ≥ 2 by Remark 5.5. Under the assumptions of (i) and (ii), (H1)–(H4) of § 5.2 hold with r = 2 r=2 r = 2 , d 1 = d d_1=d d 1 = d , d 2 = w d_2=w d 2 = w and a = m − w a=m-w a = m − w .
(i) Theorem 5.6 and Proposition 5.8 (ii) give the divisor t t t and all the stated properties except properness; t ≠ m t\ne m t = m by Remark 3.10(i), applied to U ⊥ U^\perp U ⊥ . By Theorem 5.6 (ii), codewords of rank d d d , w w w and m m m become codewords of rank t ⌊ d / t ⌋ t\lfloor d/t\rfloor t ⌊ d / t ⌋ , t ⌊ w / t ⌋ t\lfloor w/t\rfloor t ⌊ w / t ⌋ and m m m , and t ⌊ w / t ⌋ = m − t t\lfloor w/t\rfloor=m-t t ⌊ w / t ⌋ = m − t because w = m − a w=m-a w = m − a with 1 ≤ a ≤ t 1\le a\le t 1 ≤ a ≤ t and t ∣ m t\mid m t ∣ m .
(ii) This is Corollary 5.12 .
(iii) This is Theorem 5.13 with d r = w d_r=w d r = w : it gives m − w ∣ m m-w\mid m m − w ∣ m , m − w ∣ n m-w\mid n m − w ∣ n and the expansion; as all weights are divisible by m − w m-w m − w , also m − w ∣ d m-w\mid d m − w ∣ d .
Remark 6.8. Theorems 6.6 and 6.7 cover all nondegenerate three-weight codes of length n ≥ m n\ge m n ≥ m . In case (I), the problem is reduced to two-weight codes of length smaller than m m m , and for h = 2 h=2 h = 2 such codes are completely described by Theorem 6.4 when q ≥ m q\ge m q ≥ m . In case (II), without the divisor-gap condition, some coordinates may have to be deleted before obtaining an expansion; see Example 5.10. For three-weight codes of length n < m n<m n < m , which have no codeword of rank m m m , we only considered the two-dimensional case, discussed below. For n = m n=m n = m and k = 2 k=2 k = 2 , Theorem 6.7 (iii) applies for every q q q ; indeed h ( C ) = 2 h(C)=2 h ( C ) = 2 , since if h ( C ) = 1 h(C)=1 h ( C ) = 1 , then U ⊥ U^\perp U ⊥ , of F q \mathbb F_q F q -dimension m m m , would be a point P P P , and U = P ⊥ U=P^\perp U = P ⊥ would not span F q 2 m \mathbb F_{q}^{2m} F q 2 m ; hence N = m ≤ ( h ( C ) − 1 ) m N=m\le(h(C)-1)m N = m ≤ ( h ( C ) − 1 ) m , and C < m C_{<m} C < m contains codewords of rank m m m by Lemma 5.1.
Remark 6.9. Corollary 5.11 , Theorem 5.13 , Remark 4.2 (d) and Theorems 6.3 and 6.4 give positive parameter regimes for the problem studied in [14 ] : when does an e e e -divisible F q m \mathbb F_{q^m} F q m -linear rank-metric code arise from a code over F q e \mathbb F_{q^e} F q e ? Our hypotheses are stated directly in terms of the weight spectrum and the divisors of m m m . Already for two-dimensional codes of length n ≤ m n\le m n ≤ m , the families of § 4.1 show that three-weight codes are much less rigid than two-weight codes.
By Theorem 6.4 , if q ≥ m q \ge m q ≥ m , a nondegenerate two-weight [ n , 2 ] q m / q [n,2]_{q^m/q} [ n , 2 ] q m / q code with weights d < n d<n d < n is completely determined, up to the choice of an F q \mathbb{F}_q F q -scattered subspace, by its parameters: the gap a = n − d a=n-d a = n − d divides m m m , n n n and d d d , the code is the F q \mathbb{F}_q F q -expansion of a code over F q a \mathbb{F}_{q^a} F q a (no coordinate has to be deleted), and its weight distribution depends only on q q q , m m m , n n n and a a a . For three weights none of these properties survives, and the constructions of § 4.1 , which exist for every prime power q q q (in particular for q ≥ m q \ge m q ≥ m ), exhibit quite different behaviours (see also the table in Remark 4.10):
Family F 1 \mathcal{F}_1 F 1 (Example 4.4): weights n − 2 n-2 n − 2 , n − 1 n-1 n − 1 , n n n for every 3 ≤ n ≤ m 3 \le n \le m 3 ≤ n ≤ m , with g 1 = g 2 = 1 g_1=g_2=1 g 1 = g 2 = 1 ; here the counting relations do not determine the weight distribution from the weights, since A n − 2 ( C ) = ( q m − 1 ) ν A_{n-2}(C)=(q^m-1)\nu A n − 2 ( C ) = ( q m − 1 ) ν depends on the number ν ≥ 1 \nu\ge1 ν ≥ 1 of points of weight two, which is not fixed by the construction.
Family F 2 \mathcal{F}_2 F 2 (Example 4.6) and, more generally, i i i -clubs (Remark 4.7): weights N − i N-i N − i , N − 1 N-1 N − 1 , N N N , with g 1 = 1 g_1=1 g 1 = 1 and g 2 = i − 1 g_2=i-1 g 2 = i − 1 , for 2 ≤ i ≤ N − 1 2 \le i \le N-1 2 ≤ i ≤ N − 1 and N ≤ m N \le m N ≤ m ; the second gap can be as large as m − 3 m-3 m − 3 (Family F 2 \mathcal{F}_2 F 2 with n = m n=m n = m ), the minimum weight can be as small as 2, or even 1 (clubs obtained from { ( x , Tr q m / q ( x ) ) } \{(x,\operatorname{Tr}_{q^m/q}(x))\} {( x , Tr q m / q ( x ))} ), and there is, up to F q m \mathbb{F}_{q^m} F q m -multiples, a single codeword of minimum weight, A N − i ( C ) = q m − 1 A_{N-i}(C)=q^m-1 A N − i ( C ) = q m − 1 . No divisibility among N N N , m m m and the weights is forced.
Family F 3 \mathcal{F}_3 F 3 (Example 4.8): weights a a a , 2 a − 1 2a-1 2 a − 1 , 2 a 2a 2 a , for m m m even and 2 ≤ a ≤ m / 2 2 \le a \le m/2 2 ≤ a ≤ m /2 , with g 1 = 1 g_1=1 g 1 = 1 and g 2 = a − 1 g_2=a-1 g 2 = a − 1 ; the second largest weight can be coprime with m m m (weights 3, 5, 6 for m = 6 m=6 m = 6 , a = 3 a=3 a = 3 ).
Family F 4 \mathcal{F}_4 F 4 (Example 4.9): weights ℓ t − t − 1 \ell t-t-1 ℓ t − t − 1 , ℓ t − t \ell t-t ℓ t − t , ℓ t − 1 \ell t-1 ℓ t − 1 , for t ∣ m t \mid m t ∣ m , 1 < t < m 1<t<m 1 < t < m and 2 ≤ ℓ ≤ m / t 2 \le\ell\le m/t 2 ≤ ℓ ≤ m / t , with g 1 = t − 1 g_1=t-1 g 1 = t − 1 and g 2 = 1 g_2=1 g 2 = 1 ; the first gap can be as large as m / 2 − 1 m/2-1 m /2 − 1 , and yet C C C is not an expansion, since gcd ( g 1 , g 1 + g 2 ) = 1 \gcd(g_1,g_1+g_2)=1 g cd( g 1 , g 1 + g 2 ) = 1 : it is obtained by deleting one coordinate from an expansion over F q t \mathbb{F}_{q^t} F q t . This is exactly the phenomenon described by Theorem 4.1 with t > a t>a t > a , which Theorem 6.4 rules out for two-weight codes.
Thus, while a gap at least two in a two-weight code forces the code to come from a subfield, in a three-weight code a large gap is compatible both with the absence of any divisibility condition (second gap, Families F 2 \mathcal{F}_2 F 2 , F 3 \mathcal{F}_3 F 3 and clubs) and with a code that is only a punctured expansion (first gap, Family F 4 \mathcal{F}_4 F 4 ). Even when q ≥ m q \ge m q ≥ m , the only general restrictions known are those of Corollary 4.3, which come into play only when the first gap is at least two.
Declaration of Generative AI and AI-assisted Technologies in the Writing Process
The authors used AI-assisted tools exclusively for language editing and improving the clarity and readability of the manuscript. All mathematical results, proofs, and scientific conclusions are the authors’ own. The authors have carefully reviewed the entire manuscript and take full responsibility for its content.
Acknowledgements
The research of Olga Polverino and Ferdinando Zullo was partially supported by the Italian National Group for Algebraic and Geometric Structures and their Applications (GNSAGA - INdAM). This research was also partially supported by the Scientific Research Community of the Research Foundation Flanders (Belgium), Graphs, Association schemes and Geometries: structures, algorithms and computation (W003324N) and by the VUB-OZR project Discrete Structures, and their applications in Data Science (OZR3637). This work was partially written during the Opera 2026 conference in Bordeaux, and so we acknowledge the support from the International Research Laboratory LYSM in partnership between CNRS and INdAM.