aa r X i v : . [ c s . I T ] A p r Rank-metric codes and their duality theory
Alberto Ravagnani ∗ Institut de Math´ematiquesUniversit´e de NeuchˆatelEmile-Argand 11, CH-2000 Neuchˆatel, Switzerland
Abstract
We compare the two duality theories of rank-metric codes proposed by Delsarte andGabidulin, proving that the former generalizes the latter. We also give an elementary proofof MacWilliams identities for the general case of Delsarte rank-metric codes. The identitieswhich we derive are very easy to handle, and allow us to re-establish in a very concise way themain results of the theory of rank-metric codes first proved by Delsarte employing the theoryof association schemes and regular semilattices. We also show that our identities imply as acorollary the original MacWilliams identities established by Delsarte. We describe how theminimum and maximum rank of a rank-metric code relate to the minimum and maximumrank of the dual code, giving some bounds and characterizing the codes attaining them.Then we study optimal anticodes in the rank metric, describing them in terms of optimalcodes (namely, MRD codes). In particular, we prove that the dual of an optimal anticodeis an optimal anticode. Finally, as an application of our results to a classical problemin enumerative combinatorics, we derive both a recursive and an explicit formula for thenumber of k × m matrices over a finite field with given rank and h -trace. Introduction
In [6] Delsarte defines rank-metric codes as sets of matrices of given size over a finite field F q .The distance between two matrices is given by the rank of their difference. Interpreting matricesas bilinear forms, Delsarte studies rank-metric codes as association schemes, whose adjacencyalgebra yields the so-called MacWilliams transform of distance enumerators of codes. The resultsof [6] are based on the general theory of designs and codesigns in regular semilattices developedin [5].In [9] Gabidulin proposed a different definition of rank-metric code, in which the codewordsare vectors with entries in an extension field F q m . MacWilliams identities for Gabidulin codeswere obtained in [10]. As we will explain in details, one can naturally associate to any vectorwith entries in an extension field F q m a matrix of prescribed size over the base field F q . Therank of the vector (as defined by Gabidulin) coincides with the ordinary rank of the associatedmatrix. Hence there exists a natural way to associate to a Gabidulin code a Delsarte code withthe same metric properties. From this point of view, Gabidulin codes can be regarded as a ∗ E-mail: [email protected] . The author was partially supported by the Swiss National ScienceFoundation through grant no. 200021 150207. h -trace over a finite field F q . To the extent of our knowledge, formulas of this type are notavailable in the literature.The layout of the paper is as follows. Section 1 contains some preliminaries on Delsarterank-metric codes. In Section 2 we compare Delsarte and Gabidulin codes. In Section 3 wegive an elementary proof for MacWilliams identities for the general case of Delsarte rank-metric2odes, and use them to establish the main results of the theory of these codes. In Section 4 andin the last part of Section 5 we study how the minimum and the maximum rank of a rank-metriccode relate to the minimum and maximum rank of the dual code, proving some bounds on theinvolved parameters and characterizing the codes which attain them. Optimal anticodes in therank metric are studied in Section 5. In Section 6 we derive a recursive formula for the numberof rectangular matrices over F q of given rank and h -trace. In Appendix A we show how ourresults relate to the original work by Delsarte, giving in particular an explicit formula for thenumber of rectangular matrices over F q of given rank and h -trace. Throughout this paper, q denotes a fixed prime power, and F q the finite field with q elements.We also work with positive integers k and m . Notation 1.
We denote by Mat( k × m, F q ) the F q -vector space of k × m matrices with entriesin F q . Given a matrix M ∈ Mat( k × m, F q ), we write Tr( M ) for the trace of M , and M i forthe i -th column of M , i.e., the vector ( M i , M i , ..., M ki ) t ∈ F kq . The transpose of M is M t ,while rk( M ) denotes the rank of M . The vector space generated by the columns of a matrix M ∈ Mat( k × m, F q ) is colsp( M ) ⊆ F kq . When the size is clear from the context, we denote azero matrix simply by 0.Let us briefly recall the setup of [6]. Definition 2.
The trace product of matrices
M, N ∈ Mat( k × m, F q ) is denoted and definedby h M, N i := Tr( M N t ) . It is easy to check that the map h· , ·i : Mat( k × m, F q ) × Mat( k × m, F q ) → F q is a scalarproduct (i.e., symmetric, bilinear and non-degenerate). Definition 3.
A (
Delsarte rank-metric ) code of size k × m over F q is an F q -linear subspace C ⊆
Mat( k × m, F q ). The minimum rank of a non-zero code C is denoted and defined byminrk( C ) := min { rk( M ) : M ∈ C , rk( M ) > } , while the maximum rank of any code C isdenoted and defined by maxrk( C ) := max { rk( M ) : M ∈ C} . The dual of C is the Delsarte code C ⊥ := { N ∈ Mat( k × m, F q ) : h M, N i = 0 for all M ∈ C} . Remark 4.
We notice that Delsarte codes are by definition linear over F q , and that linearityis a crucial property for the results presented in this paper.The following lemma summarizes some straightforward properties of duality. Lemma 5.
Let C , D ⊆
Mat( k × m, F q ) be codes. We have: • ( C ⊥ ) ⊥ = C ; • dim F q ( C ⊥ ) = km − dim F q ( C ); • ( C ∩ D ) ⊥ = C ⊥ + D ⊥ , and ( C + D ) ⊥ = C ⊥ ∩ D ⊥ .Recall that for n ∈ N ≥ the standard inner product of vectors ( x , ..., x n ) , ( y , ..., y n ) ∈ F nq isdefined by ( x , ..., x n ) · ( y , ..., y n ) := P ni =1 x i y i . It is easy to see that the trace product h· , ·i onMat( k × m, F q ) and the standard inner product on F kq relate as follows.3 emma 6. Let
M, N ∈ Mat( k × m, F q ). We have h M, N i = P mi =1 M i · N i . Notation 7.
Lemma 6 says that the trace product of two matrices is the sum of the standardinner products of the columns of the two matrices. In particular, the trace product h· , ·i onMat( k × , F q ) ∼ = F kq coincides with the standard inner product on F kq . Hence from now on wedenote both products by h· , ·i . We also denote by U ⊥ the dual of a vector subspace U ⊆ F kq ,i.e., U ⊥ := { x ∈ F kq : h u, x i = 0 for all u ∈ U } .The following result, first proved by Delsarte, is well-known. Theorem 8 ([6], Theorem 5.4) . Let
C ⊆
Mat( k × m, F q ) be a non-zero code, and let d :=minrk( C ). We have dim F q ( C ) ≤ max { k, m } (min { k, m } − d + 1) . Moreover, for any 1 ≤ d ≤ min { k, m } there exists a non-zero code C ⊆
Mat( k × m, F q ) ofminimum rank d which attains the upper bound. Definition 9.
A code attaining the bound of Theorem 8 is said to be an optimal or maximumrank distance code ( MRD code in short). The zero code will be also considered MRD.
Remark 10.
Notice that Mat( k × m, F q ) is a trivial example of an MRD code with minimumrank 1 and dimension km . See [6], Section 6, for the construction of codes attaining the boundof Theorem 8 for any choice of the parameters. Definition 11.
Given a code C and an integer i ∈ N ≥ define A i ( C ) := |{ M ∈ C : rk( M ) = i }| .The collection ( A i ( C )) i ∈ N ≥ is said to be the rank distribution of C . Remark 12.
The minimum rank of a non-zero code
C ⊆
Mat( k × m, F q ) is the smallest i > A i ( C ) >
0. Notice that we define A i ( C ) for any i ∈ N ≥ , even if we clearly have A i ( C ) = 0 for all integers i > min { k, m } . This choice will simplify the statements in the sequel. A different definition of rank-metric code, proposed by Gabidulin, is the following.
Definition 13 (see [9]) . Let F q m / F q be a finite field extension. A Gabidulin ( rank-metric ) code of length k over F q m is an F q m -linear subspace C ⊆ F kq m . The rank of a vector α =( α , ..., α k ) ∈ F kq m is defined as rk( α ) := dim F q Span { α , ..., α k } . The minimum rank of aGabidulin code C = 0 is minrk( C ) := min { rk( α ) : α ∈ C, α = 0 } , and the maximum rank of any Gabidulin code C is maxrk( C ) := max { rk( α ) : α ∈ C } . The rank distribution of C isthe collection ( A i ( C )) i ∈ N ≥ , where A i ( C ) := |{ α ∈ C : rk( α ) = i }| . The dual of a Gabidulincode C is denoted and defined by C ⊥ := { β ∈ F kq m : h α, β i = 0 for all α ∈ C } , where h· , ·i is thestandard inner product of F kq m .It is natural to ask how Gabidulin and Delsarte codes relate to each other. Definition 14.
Let G = { γ , ..., γ m } be a basis of F q m over F q . The matrix associated to avector α ∈ F kq m with respect to G is the k × m matrix M G ( α ) with entries in F q defined by α i = P mj =1 M G ( α ) ij γ j for all i = 1 , ..., k . The Delsarte code associated to a Gabidulin code C ⊆ F kq m with respect to the basis G is C G ( C ) := { M G ( α ) : α ∈ C } ⊆ Mat( k × m, F q ).4otice that, in the previous definition, the i -th row of M G ( α ) is just the expansion of theentry α i over the basis G . The following result is immediate and well-known. We include it herefor completeness. Proposition 15.
Let C ⊆ F kq m be a Gabidulin code. For any basis G of F q m over F q , C G ( C ) ⊆ Mat( k × m, F q ) is a Delsarte rank-metric code withdim F q C G ( C ) = m · dim F qm ( C ) . Moreover, C G ( C ) has the same rank distribution as C . In particular we have maxrk( C ) =maxrk( C G ( C )), and if C = 0 then minrk( C ) = minrk( C G ( C )). Remark 16.
Proposition 15 shows that any Gabidulin code can be regarded as a Delsarte rank-metric code with the same cardinality and rank distribution. Clearly, since Gabidulin codes are F q m -linear spaces and Delsarte codes are F q -linear spaces, not all Delsarte rank-metric codesarise from a Gabidulin code in this way. In fact, only a few of them do. For example, a Delsartecode C ⊆
Mat( k × m, F q ) such that dim F q ( C ) m cannot arise from a Gabidulin code.In the remainder of the section we compare the duality theories of Delsarte and Gabidulincodes, proving in particular that the former generalizes the latter. Remark 17.
Given a Gabidulin code C ⊆ F kq m and a basis G of F q m over F q , it is natural to askwhether the Delsarte codes C G ( C ⊥ ) and C G ( C ) ⊥ coincide or not. The answer is unfortunatelynegative in general, as we show in the following example. Example 18.
Let q = 3, k = m = 2 and F = F [ η ], where η is a root of the irreducibleprimitive polynomial x + 2 x + 2 ∈ F [ x ]. Let ξ := η , so that ξ + 1 = 0. Set α := ( ξ, C ⊆ F be the 1-dimensional Gabidulin code generated by α over F . Take G := { , ξ } asbasis of F over F . One can easily check that C G ( C ) ⊆ Mat(2 × , F ) is generated over F bythe two matrices M G ( α ) = (cid:20) (cid:21) , M G ( ξα ) = (cid:20) − (cid:21) . Let β := ( ξ, ∈ F . We have h α, β i = 1 = 0, and so β / ∈ C ⊥ . It follows M G ( β ) / ∈ C G ( C ⊥ ). Onthe other hand, M G ( β ) = (cid:20) (cid:21) , and it is easy to see that M G ( β ) is trace-orthogonal to both M G ( α ) and M G ( ξα ). It follows M G ( β ) ∈ C G ( C ) ⊥ , and so C G ( C ) ⊥ = C G ( C ⊥ ).Although, for a fixed basis G , the duality notions for Delsarte and Gabidulin codes do notcoincide in general, we show that there is a simple relation between them via orthogonal basesof finite fields. Definition 19.
Let Trace : F q m → F q be the F q -linear trace map given by Trace( α ) := α + α q + · · · + α q m − for all α ∈ F q m . Bases G = { γ , ..., γ m } and G ′ = { γ ′ , ..., γ ′ m } of F q m over F q are said to be orthogonal (or dual ) if Trace( γ ′ i γ j ) = δ ij for all i, j ∈ { , ..., m } .The following result on orthogonal bases is well-known.5 roposition 20 ([19], page 54) . For every basis G of F q m over F q there exists a unique orthogonalbasis G ′ . Theorem 21.
Let C ⊆ F kq m be a Gabidulin code, and let G , G ′ be orthogonal bases of F q m over F q . We have C G ′ ( C ⊥ ) = C G ( C ) ⊥ . In particular, if we set C := C G ( C ), then C has the same rank distribution as C , and C ⊥ has thesame rank distribution as C ⊥ . Proof.
Let G = { γ , ..., γ m } and G ′ = { γ ′ , ..., γ ′ m } . Take any M ∈ C G ′ ( C ⊥ ) and N ∈ C G ( C ).There exist α ∈ C ⊥ and β ∈ C such that M = M G ′ ( α ) and N = M G ( β ). According toDefinition 14 we have0 = h α, β i = k X i =1 α i β i = k X i =1 m X j =1 M ij γ ′ j m X t =1 N it γ t = k X i =1 m X j =1 m X t =1 M ij N it γ ′ j γ t . (1)Applying the function Trace : F q m → F q to both sides of equation (1) we get0 = Trace k X i =1 m X j =1 m X t =1 M ij N it γ ′ j γ t = k X i =1 m X j =1 m X t =1 M ij N it Trace( γ ′ j γ t )= k X i =1 m X j =1 m X t =1 M ij N it δ jt = k X i =1 m X j =1 M ij N ij = Tr( M N t )= h M, N i . It follows C G ′ ( C ⊥ ) ⊆ C G ( C ) ⊥ . By Proposition 15 and Lemma 5, C G ′ ( C ⊥ ) and C G ( C ) ⊥ have thesame dimension over F q . Hence the two codes are equal. The second part of the statement easilyfollows from Proposition 15. Remark 22.
Theorem 21 shows that the duality theory of Delsarte rank-metric codes can beregarded as a generalization of the duality theory of Gabidulin rank-metric codes. In particular,we notice that all the results on Delsarte codes which we will prove in the following sections alsoapply to Gabidulin codes. Note that a relation between the trace-product of Mat( k × m, F q )and the standard inner product of F kq m involving orthogonal bases was also pointed out in [13].In the remainder of the paper we focus on the general case of Delsarte rank-metric codes.6 MacWilliams identities for rank-metric codes
In this section we give an elementary proof of certain MacWilliams identities for Delsarte rank-metric codes. MacWilliams identities for such codes were also obtained in [6] by Delsarte himselfusing the machinery of association schemes. The formulas which we derive are different fromthose of [6], but are significantly more straightforward. Indeed, the proof that we present iselementary and concise, and only employs linear algebra and a double counting argument. InAppendix A we also show how the original formulas by Delsarte can be obtained from ourformulas as a corollary. A different formulation of the identities of [6] can be found in [11].
Definition 23.
Let q be a prime power, and let s and t be integers. The q - binomial coefficient of s and t is denoted and defined by (cid:20) st (cid:21) q = s < t <
0, or t > s ,1 if t = 0 and s ≥ , Q ti =1 q s − i +1 − q i − otherwise.It is well-known that this number counts the number of t -dimensional F q -subspaces of an s -dimensional F q -space. In particular we have (cid:20) st (cid:21) q = (cid:20) ss − t (cid:21) q for all integers s, t . Since in this paper we work with a fixed prime power q , we omit the subscriptin the sequel. Remark 24.
Given any matrices
M, N ∈ Mat( k × m, F q ) we always have colsp( M + N ) ⊆ colsp( M ) + colsp( N ). As a consequence, if U ⊆ F kq is a vector subspace, then the set of matrices M ∈ Mat( k × m, F q ) with colsp( M ) ⊆ U is a vector subspace of Mat( k × m, F q ). Notation 25.
We denote the vector space { M ∈ Mat( k × m, F q ) : colsp( M ) ⊆ U } of Remark24 by Mat U ( k × m, F q ).We start with a series of preliminary results. Lemma 26.
Let U ⊆ F kq be a subspace. We have dim F q Mat U ( k × m, F q ) = m · dim F q ( U ). Proof.
Let s := dim F q ( U ). Define the s -dimensional space V := { x ∈ F kq : x i = 0 for i > s } ⊆ F kq . There exists an F q -isomorphism g : F kq → F kq that maps U into V . Let G ∈ Mat( k × k, F q )be the invertible matrix associated to g with respect to the canonical basis { e , ..., e k } of F kq , i.e., g ( e j ) = k X i =1 G ij e i for all j = 1 , ..., k. For any matrix M ∈ Mat( k × m, F q ) we have g (colsp( M )) = colsp( GM ), and it is easy to checkthat the map M GM is an F q -isomorphism Mat U ( k × m, F q ) → Mat V ( k × m, F q ). Now weobserve that Mat V ( k × m, F q ) is the vector space of matrices M ∈ Mat( k × m, F q ) whose last k − s rows equal zero. Hence dim F q Mat V ( k × m, F q ) = km − m ( k − s ) = ms , and the lemmafollows. 7 emma 27. Let U ⊆ F kq be a subspace. We have Mat U ( k × m, F q ) ⊥ = Mat U ⊥ ( k × m, F q ). Proof.
Let N ∈ Mat U ⊥ ( k × m, F q ) and M ∈ Mat U ( k × m, F q ). By definition, each column of N belongs to U ⊥ , and each column of M belongs to U . Hence by Lemma 6 we have h M, N i = m X i =1 h M i , N i i = 0 . This proves Mat U ⊥ ( k × m, F q ) ⊆ Mat U ( k × m, F q ) ⊥ . By Lemma 26, the two spaces of matricesMat U ⊥ ( k × m, F q ) and Mat U ( k × m, F q ) ⊥ have the same dimension over F q . Hence they areequal. Lemma 28.
Let
C ⊆
Mat( k × m, F q ) be a code, and let U ⊆ F kq be a subspace. Denote by s the dimension of U over F q . We have |C ∩ Mat U ( k × m, F q ) | = |C| q m ( k − s ) |C ⊥ ∩ Mat U ⊥ ( k × m, F q ) | . Proof.
Combining Lemma 5 and Lemma 27 we obtain(
C ∩
Mat U ( k × m, F q )) ⊥ = C ⊥ + Mat U ( k × m, F q ) ⊥ = C ⊥ + Mat U ⊥ ( k × m, F q ) . Hence by Lemma 5 we have |C ∩
Mat U ( k × m, F q ) | · |C ⊥ + Mat U ⊥ ( k × m, F q ) | = q km . (2)On the other hand, Lemma 26 givesdim F q ( C ⊥ + Mat U ⊥ ( k × m, F q )) = dim F q ( C ⊥ ) + m · dim F q U ⊥ − dim F q ( C ⊥ ∩ Mat U ⊥ ( k × m, F q )) , and so, again by Lemma 5, |C ⊥ + Mat U ⊥ ( k × m, F q ) | = q km · q m ( k − s ) |C| · |C ⊥ ∩ Mat U ⊥ ( k × m, F q ) | . (3)Combining equation (2) and equation (3) one easily obtains the lemma.The following result is well-known, but we include it for completeness. Lemma 29.
Let 0 ≤ t, s ≤ k be integers, and let X ⊆ F kq be a subspace of dimension t over F q .The number of subspaces U ⊆ F kq such that X ⊆ U and dim F q ( U ) = s is (cid:20) k − ts − t (cid:21) . Proof.
Let π : F kq → F kq /X denote the projection on the quotient vector space F kq modulo X .It is easy to see that π induces a bijection between the s -dimensional vector subspaces of F kq containing X and the ( s − t )-dimensional subspaces of F kq /X . The lemma follows from the factthat F kq /X has dimension k − t . 8 emma 30. Let
C ⊆
Mat( k × m, F q ) be a code. Denote by ( A i ) i ∈ N the rank distribution of C .Let 0 ≤ s ≤ k be an integer. We have X U ⊆ F kq dim F q ( U )= s |C ∩ Mat U ( k × m, F q ) | = k X i =0 A i (cid:20) k − ik − s (cid:21) . Proof.
Define the set A ( C , s ) := { ( U, M ) : U ⊆ F kq , dim( U ) = s, M ∈ C , colsp( M ) ⊆ U } . Wewill count the elements of A ( C , s ) in two different ways. On the one hand, using Lemma 29, wehave |A ( C , s ) | = X M ∈C |{ U ⊆ F kq , dim( U ) = s, colsp( M ) ⊆ U }| = k X i =0 X M ∈C rk ( M )= i |{ U ⊆ F kq , dim( U ) = s, colsp( M ) ⊆ U }| = k X i =0 X M ∈C rk ( M )= i (cid:20) k − is − i (cid:21) = k X i =0 A i (cid:20) k − is − i (cid:21) = k X i =0 A i (cid:20) k − ik − s (cid:21) . On the other hand, |A ( C , s ) | = X U ⊆ F kq dim( U )= s |{ M ∈ C : colsp( M ) ⊆ U }| = X U ⊆ F kq dim( U )= s |C ∩ Mat U ( k × m, F q ) | , and the lemma follows.Now we state our main result. Theorem 31.
Let
C ⊆
Mat( k × m, F q ) be a code. Let ( A i ) i ∈ N and ( B j ) j ∈ N be the rankdistributions of C and C ⊥ , respectively. For any integer 0 ≤ ν ≤ k we have k − ν X i =0 A i (cid:20) k − iν (cid:21) = |C| q mν ν X j =0 B j (cid:20) k − jν − j (cid:21) . Proof.
Lemma 30 applied to C with s = k − ν gives X U ⊆ F kq dim F q ( U )= k − ν |C ∩ Mat U ( k × m, F q ) | = k X i =0 A i (cid:20) k − iν (cid:21) . The map U U ⊥ is a bijection between the ν -dimensional and the ( k − ν )-dimensional subspacesof F kq . Hence we have X U ⊆ F kq dim F q ( U )= k − ν |C ⊥ ∩ Mat U ⊥ ( k × m, F q ) | = X U ⊆ F kq dim F q ( U )= ν |C ⊥ ∩ Mat U ( k × m, F q ) | = k X j =0 B j (cid:20) k − jk − ν (cid:21) , C ⊥ with s = ν . Lemma28 with s = k − ν gives k X i =0 A i (cid:20) k − iν (cid:21) = |C| q mν k X j =0 B j (cid:20) k − jν − j (cid:21) . By definition, for i > k − ν and for j > ν we have (cid:20) k − iν (cid:21) = (cid:20) k − jν − j (cid:21) = 0 , and the theorem follows. Remark 32.
Theorem 31 can be regarded as the q -analog of Lemma 2.2 of [17], which yieldsanalogous identities for the Hamming metric.Theorem 31 produces in particular MacWilliams-type identities that relate the rank distri-bution of a dual code C ⊥ to the rank distribution of C . The following result gives a recursivemethod to compute the rank distribution of C ⊥ from the rank distribution of C . Corollary 33.
Let
C ⊆
Mat( k × m, F q ) be a code. Let ( A i ) i ∈ N and ( B j ) j ∈ N be the rankdistributions of C and C ⊥ , respectively. For ν = 0 , ..., k define a kν := q mν |C| k − ν X i =0 A i (cid:20) k − iν (cid:21) . The B j ’s are given by the recursive formula B = 1 ,B ν = a kν − ν − X j =0 B j (cid:20) k − jν − j (cid:21) for ν = 1 , ..., k,B ν = 0 for ν > k. Proof.
Clearly, B = 1 and B ν = 0 for ν > k . For any fixed integer ν ∈ { , ..., k } Theorem 31gives a kν = ν − X j =0 B j (cid:20) k − jν − j (cid:21) + B ν , which proves the result. Remark 34.
Identities in the form of Theorem 31 are usually called “moments of MacWilliamsidentities” rather than “MacWilliams identities”. For convenience, in this paper we will call“MacWilliams identities” both the identities of Theorem 31 and Corollary 33.
Remark 35.
We notice that Theorem 31 implies Theorem 3.3 of [6] as a corollary (see AppendixA for details), producing MacWilliams identities for Delsarte codes in an explicit form employingan elementary argument. 10 emark 36.
Identities in the form of Theorem 31 were recently proved for Gabidulin codes(see [10], Proposition 3). The proof of [10] is based on the Hadamard transform, q -products, q -derivatives and q -transforms of polynomials. In [11], Corollary 1 and Proposition 3, the authorsshow that such identities also apply to Delsarte codes. Their proof is based on the results of [6]by Delsarte.Theorem 31 and Corollary 33 allow us to re-establish the main results of the duality theoryof rank-metric codes in a very concise way. Corollary 37.
The rank distribution of a code C determines the rank distribution of the dualcode C ⊥ . Proof.
This immediately follows from Corollary 33.
Remark 38.
Corollary 37 was first proved by Delsarte using the theory of association schemes.See [6], Theorem 3.3 for details.
Example 39.
Let q = 3, k = 3, m = 4. Consider the code C ⊆
Mat(3 × , F ) generated by thefollowing three matrices: , , . It can be checked that dim F C = 3 and that the rank distribution of C is A = 1, A = 2, A = 0, A = 24. If ( B j ) j ∈ N denotes the rank distribution of C ⊥ , then the recursive formula ofCorollary 33 allows us to compute: B = 1 , B = 50 , B = 3432 , B = 16200 . Notice that P i =0 B i = 19683 = 3 = |C ⊥ | , as expected. Remark 40.
For a code
C ⊆
Mat( k × m, F q ) define C t := { M t : M ∈ C} ⊆ Mat( m × k, F q ).Clearly, C and C t have the same dimension and rank distribution. Moreover, one can check that( C t ) ⊥ = ( C ⊥ ) t . As a consequence, up to a transposition, without loss of generality in the sequelwe will always assume k ≤ m in the proofs of our results. Corollary 41.
If a code C is MRD, then C ⊥ is also MRD. Proof.
Let
C ⊆
Mat( k × m, F q ) be MRD. If C = { } or C = Mat( k × m, F q ) the result followsfrom Definition 9 and Remark 10. Hence we assume 0 < dim F q ( C ) < km . Assume k ≤ m without loss of generality. Denote by d the minimum rank of C , so that |C| = q m ( k − d +1) . Let( A i ) i ∈ N and ( B j ) j ∈ N be the rank distributions of C and C ⊥ , respectively. We have A = B = 1and A i = 0 for 1 ≤ i ≤ d −
1. Theorem 31 with ν = k − d + 1 gives (cid:20) kk − d + 1 (cid:21) = (cid:20) kk − d + 1 (cid:21) + k − d +1 X j =1 B j (cid:20) k − jk − d + 1 − j (cid:21) , i.e., k − d +1 X j =1 B j (cid:20) k − jk − d + 1 − j (cid:21) = 0 . d ≥
1, for 1 ≤ j ≤ k − d + 1 we have k − j ≥ k − d + 1 − j ≥
0, and so (cid:20) k − jk − d + 1 − j (cid:21) > B j = 0 for 1 ≤ j ≤ k − d + 1, i.e., minrk( C ⊥ ) ≥ k − d + 2. On the other hand,Theorem 8 gives dim F q ( C ⊥ ) = m ( d − ≤ m ( k − minrk( C ⊥ ) + 1), i.e., minrk( C ⊥ ) ≤ k − d + 2.It follows minrk( C ⊥ ) = k − d + 2, and so C ⊥ is MRD. Remark 42.
Corollary 41 was first proved by Delsarte using the theory of designs and codesignsin regular semilattices ([6], Theorem 5.5). Theorem 31 allows us to give a short proof for thesame result. Notice also that, by Remark 22, Corollary 41 generalizes the analogous result forGabidulin codes of [9].
In this section we investigate the minimum and the maximum rank of a Delsarte code C , andshow how they relate to the minimum and maximum rank of its dual code C ⊥ . As an application,we give a recursive formula for the rank distribution of an MRD code. Proposition 43.
Let C ( Mat( k × m, F q ) be a non-zero code. We haveminrk( C ⊥ ) ≤ min { k, m } − minrk( C ) + 2 . Moreover, the bound is attained if and only if C is MRD. Proof.
Assume k ≤ m without loss of generality. Theorem 8 applied to the code C givesdim F q ( C ) ≤ m ( k − minrk( C ) + 1). The same theorem applied to C ⊥ gives dim F q ( C ⊥ ) ≤ m ( k − minrk( C ⊥ ) + 1), i.e., dim F q ( C ) ≥ m (minrk( C ⊥ ) − m (minrk( C ⊥ ) − ≤ dim F q ( C ) ≤ m ( k − minrk( C ) + 1) . (4)In particular, minrk( C ⊥ ) − ≤ k − minrk( C ) + 1, and the bound follows. Let us prove thesecond part of the statement. Assume that C is MRD, and let d := minrk( C ). We havedim F q ( C ) = m ( k − d + 1), and so dim F q ( C ⊥ ) = m ( d − C ⊥ is also MRD, andso m ( d −
1) = m ( k − minrk( C ⊥ ) + 1). It follows minrk( C ⊥ ) = k − d + 2. On the other hand, ifminrk( C ⊥ ) = k − minrk( C ) + 2 then both the inequalities in (4) are in fact equalities, and so C is MRD. Corollary 44.
The rank distribution of a non-zero MRD code
C ⊆
Mat( k × m, F q ) only dependson k , m and minrk( C ). Proof.
Assume k ≤ m without loss of generality. Let d := minrk( C ), and let ( A i ) i ∈ N denote therank distribution of C . By Proposition 43, C ⊥ has minimum rank k − d + 2. Hence the equationsof Theorem 31 for 0 ≤ ν ≤ k − d reduce to (cid:20) kν (cid:21) + k − ν X i = d A i (cid:20) k − iν (cid:21) = |C| q mν (cid:20) kν (cid:21) , ≤ ν ≤ k − d. These identities give a linear system of k − d +1 equations in the k − d +1 unknowns A d , ..., A k . Itis easy to see that the matrix associated to the system is triangular with all 1’s on the diagonal.In particular, the solution to the system is unique. Hence A d , ..., A k are uniquely determined by k , m and d . Since A = 1 and A i = 0 for 0 < i < d and for i > k , the thesis follows.12 emark 45. Corollary 44 was first proved by Delsarte by computing explicitly the rank dis-tribution of an MRD code, and then observing that the obtained formulas only depend on theparameters m , k , d (see [6], Theorem 5.6). Corollary 44 allows us to give a concise proof for thesame result. The rank distribution of Delsarte MRD codes was also computed in [8] employingelementary techniques. Remark 46.
Using the same argument as Corollary 33 it is easy to derive a recursive formulafor the rank distribution ( A i ) i ∈ N of a non-zero MRD code C ⊆
Mat( k × m, F q ) of given minimumrank d : A = 1 , A d = ( q m − (cid:20) kk − d (cid:21) ,A d + ℓ = ( q m (1+ ℓ ) − (cid:20) kk − d − ℓ (cid:21) − d + ℓ − X i = d A i (cid:20) k − ik − d − ℓ (cid:21) for 1 ≤ ℓ ≤ k − d .We do not go into the details of the proof.The following result is the analogue of Theorem 8 for the maximum rank. Proposition 47.
Let
C ⊆
Mat( k × m, F q ) be a code. We havedim F q ( C ) ≤ max { k, m } · maxrk( C ) . Moreover, for any choice of 0 ≤ D ≤ min { k, m } there exists a code C ⊆
Mat( k × m, F q ) withmaximum rank equal to D and attaining the upper bound. Proof.
Assume k ≤ m without loss of generality. Fix 0 ≤ D ≤ k . The set of all k × m matriceshaving the last k − D rows equal to zero is an example of a code of maximum rank D anddimension mD over F q . Now we prove the first part of the statement. Let C ⊆
Mat( k × m, F q )be a code with maxrk( C ) = D . If D = k then the bound is trivial. Hence we assume D ≤ k − D ⊆
Mat( k × m, F q ) with minrk( D ) = D + 1 and dim F q ( D ) = m ( k − D ).We clearly have C ∩ D = { } and C ⊕ D ⊆
Mat( k × m, F q ). Hence dim F q ( C ) ≤ km − dim F q ( D ) = mD . Definition 48.
A code
C ⊆
Mat( k × m, F q ) which attains the upper bound of Proposition 47is said to be a ( Delsarte ) optimal anticode .We conclude the section with a result that relates the minimum rank of a code with themaximum rank of the dual code. Proposition 49.
Let
C ⊆
Mat( k × m, F q ) be a non-zero code. We haveminrk( C ) ≤ maxrk( C ⊥ ) + 1 . Proof.
Assume k ≤ m without loss of generality. Applying Theorem 8 to C we obtain dim F q ( C ) ≤ m ( k − minrk( C ) + 1), while Proposition 47 applied to C ⊥ gives dim F q ( C ⊥ ) ≤ m · maxrk( C ⊥ ), i.e.,dim F q ( C ) ≥ m ( k − maxrk( C ⊥ )). Hence we have m ( k − maxrk( C ⊥ )) ≤ dim F q ( C ) ≤ m ( k − minrk( C ) + 1) , and the thesis follows. 13 Optimal anticodes
In this section we provide a new characterization of optimal anticodes in terms of their inter-section with MRD codes. As an application of such a description, we prove that the dual of anoptimal anticode is an optimal anticode.Let us first briefly recall some notions which we will need in the sequel. See [19], Section 3.4for details.
Definition 50.
Let F q m / F q be a finite field extension. A linearized polynomial p over F q m is a polynomial of the form p ( x ) = α x + α x q + α x q + · · · + α s x q s , α i ∈ F q m , i = 0 , ..., s. The degree of p , denoted by deg( p ), is the largest i ≥ α i = 0. Remark 51.
It is well known ([19], Theorem 3.50) that the roots of a linearized polynomial p over F q m form an F q -vector subspace of F q m , which we denote by V ( p ) ⊆ F q m . Notice that forany linearized polynomial p we have dim F q V ( p ) ≤ deg( p ). Lemma 52.
Let
C ⊆
Mat( k × m, F q ) be a non-zero MRD code with minimum rank d , and let( A i ) i ∈ N be the rank distribution of C . Then A d + ℓ > ≤ ℓ ≤ min { k, m } − d . Proof.
Assume k ≤ m without loss of generality. By Corollary 44, we shall prove the lemma fora given MRD code C ⊆
Mat( k × m, F q ) of our choice with minimum rank d . We first construct aconvenient MRD code with the prescribed parameters, and we essentially follow the constructionof [9].Let γ , ..., γ k ∈ F q m be linearly independent over F q . Denote by L ( F q m , k − d ) the F q m -vector space of linearized polynomials over F q m of degree less than or equal to k − d . We havedim F qm L ( F q m , k − d ) = k − d + 1. Let ev : L ( F q m , k − d ) → F kq m be the evaluation map definedby ev ( p ) := ( p ( γ ) , ..., p ( γ k )) for any p ∈ L ( F q m , k − d ). Then the image of ev is a Gabidulincode C ⊆ F kq m with minimum rank d and dimension k − d + 1 over F q m ([15], Theorem 14).Let G be any basis of F q m over F q . By Proposition 15, C := C G ( C ) ⊆ Mat( k × m, F q ) is aDelsarte rank-metric code with dim F q ( C ) = m ( k − d + 1) and the same rank distribution as C .In particular, C is a non-zero MRD code with minimum rank d .Now we prove the lemma for the MRD code C that we constructed. Fix 0 ≤ ℓ ≤ k − d .Define t := k − d − ℓ , and let U ⊆ F q m be the F q -subspace generated by { γ , ..., γ t } . If t = 0 weset U to be the zero space. By [19], Theorem 3.52, p U := Y β ∈ U ( x − β ) ∈ F q m [ x ]is a linearized polynomial over F q m of degree t = k − d − ℓ ≤ k − d . Hence p U ∈ L ( F q m , k − d ).By Proposition 15 it suffices to prove that ev ( p U ) = ( p U ( γ ) , ..., p U ( γ k )) has rank d + ℓ = k − t .Clearly, V ( p U ) = U . In particular we have ev ( p U ) = (0 , ..., , p U ( γ t +1 ) , ..., p U ( γ k )). We will provethat p U ( γ t +1 ) , ..., p U ( γ k ) are linearly independent over F q . Assume that there exist a t +1 , ..., a k ∈ F q such that P ki = t +1 a i p U ( γ i ) = 0. Then we have p U (cid:16)P ki = t +1 a i γ i (cid:17) = 0, i.e., P ki = t +1 a i γ i ∈ V ( p U ) = U . It follows that there exist a , ..., a t ∈ F q such that P ti =1 a i γ i = P ki = t +1 a i γ i , i.e., P ti =1 a i γ i − P ki = t +1 a i γ i = 0. Since γ , ..., γ k are linearly independent over F q , we have a i = 0for all i = 1 , ..., k . In particular a i = 0 for i = t + 1 , ..., k . Hence p U ( γ t +1 ) , ..., p U ( γ k ) are linearlyindependent over F q , as claimed. 14n the following result we give a necessary and sufficient condition for a Delsarte code C ⊆
Mat( k × m, F q ) with dim F q ( C ) ≡ m to be an optimal anticode. Proposition 53.
Let 0 ≤ D ≤ min { k, m } − C ⊆
Mat( k × m, F q ) be an F q -subspace with dim F q ( C ) = max { k, m } · D . The following facts are equivalent.1. C is an optimal anticode.2. C ∩ D = { } for all non-zero MRD codes D ⊆
Mat( k × m, F q ) with minrk( D ) = D + 1. Proof. If C is an optimal anticode, then by Definition 48 we have D = maxrk( C ). Hence if D is any non-zero code with minrk( D ) = D + 1 we clearly have C ∩ D = { } . So (1) ⇒ (2) istrivial. Let us prove (2) ⇒ (1). By contradiction, assume that C is not an optimal anticode.Since maxrk( C ) ≥ D (see Proposition 47), we must have s := maxrk( C ) ≥ D + 1. Let N ∈ C with rk( N ) = s . Let D ′ be a non-zero MRD code with minrk( D ′ ) = D + 1 (see Theorem 8 forthe existence of such a code). By Lemma 52 there exists A ∈ D ′ with rk( A ) = s . There existinvertible matrices P and Q of size k × k and m × m (respectively) such that N = P AQ . Define D := P D ′ Q := { P M Q : M ∈ D ′ } . Then
D ⊆
Mat( k × m, F q ) is a non-zero MRD code withminrk( D ) = D + 1 and such that N ∈ C ∩ D . Since rk( N ) = s ≥ D + 1 ≥ N cannot be thezero matrix. This contradicts the hypothesis.The following result may be regarded as the analogue of Corollary 41 for anticodes in therank metric. Theorem 54. If C is an optimal anticode, then C ⊥ is also an optimal anticode. Proof.
Let
C ⊆
Mat( k × m, F q ) be an optimal anticode with D := maxrk( C ). Assume k ≤ m without loss of generality. If D = k then the result is trivial. Hence from now on we assume0 ≤ D ≤ k −
1. By Definition 48 we have dim F q ( C ) = mD , and so dim F q ( C ⊥ ) = m ( k − D ). By Proposition 53 it suffices to prove that C ⊥ ∩ D = { } for all non-zero MRD codes D ⊆
Mat( k × m, F q ) with minrk( D ) = k − D + 1. If D is such an MRD code, then we havedim F q ( D ) = m ( k − ( k − D + 1) + 1) = mD < mk . Hence, by Proposition 43, D ⊥ is an MRDcode with minrk( D ⊥ ) = k − ( k − D + 1) + 2 = D + 1. Proposition 53 gives C ∩ D ⊥ = { } . Sincedim F q ( C ) + dim F q ( D ⊥ ) = mD + m ( k − ( D + 1) + 1) = mk , it follows C ⊕ D ⊥ = Mat( k × m, F q ).Hence by Lemma 5 we have C ⊥ ∩ D = { } , as claimed.The following result shows how the maximum rank of a code C and the maximum rank ofthe dual code C ⊥ relate to each other. Proposition 55.
Let
C ⊆
Mat( k × m, F q ) be a code. We havemaxrk( C ) ≥ min { k, m } − maxrk( C ⊥ ) . Moreover, the bound is attained if and only if C is an optimal anticode. Proof.
Assume k ≤ m without loss of generality. Proposition 47 applied to C ⊥ gives dim F q ( C ⊥ ) ≤ m · maxrk( C ⊥ ), i.e., dim F q ( C ) ≥ m ( k − maxrk( C ⊥ )). The same proposition applied to C givesdim F q ( C ) ≤ m · maxrk( C ). Hence we have m ( k − maxrk( C ⊥ )) ≤ dim F q ( C ) ≤ m · maxrk( C ) . (5)In particular, k − maxrk( C ⊥ ) ≤ maxrk( C ). Given the inequalities in (5), it is easy to see thatthe bound is attained if and only if both C and C ⊥ are optimal anticodes, which occurs preciselywhen C is an optimal anticode by Theorem 54.15 Matrices with given rank and h -trace In this section we apply Corollary 33, i.e., the MacWilliams identities for Delsarte codes, toclassical problems in enumerative combinatorics, deriving a recursive formula for the number of k × m matrices over F q with prescribed rank and h -trace. Definition 56.
Let M ∈ Mat( k × m, F q ), and let 1 ≤ h ≤ min { k, m } be an integer. The h -trace of M is defined by Tr h ( M ) := h X i =1 M ii . Remark 57.
Since for any matrix M we have Tr h ( M ) = Tr h ( M t ), without loss of generalityin the following we only treat the case k ≤ m . Notice also that when k = m we have Tr k ( M ) =Tr( M ). Hence the h -trace generalizes the trace of a matrix. Notation 58.
Given integers 1 ≤ k ≤ m , 0 ≤ r ≤ k and 1 ≤ h ≤ k , we denote by n q ( k × m, r, h )the number of matrices M ∈ Mat( k × m, F q ) such that rk( M ) = r and Tr h ( M ) = 0. We alsodenote by n q ( k × m, r,
0) the number of matrices in Mat( k × m, F q ) of rank r . Lemma 59.
Let 1 ≤ k ≤ m and 0 ≤ r ≤ k be integers. We have n q ( k × m, r,
0) = (cid:20) mr (cid:21) · r − Y i =0 ( q k − q i ) . Sketch of proof.
For a given vector subspace U ⊆ F mq with dim F q ( U ) = r , the number of matrices M ∈ Mat( k × m, F q ) whose row space equals U is precisely the number of full-rank r × k matrices,which is Q r − i =0 ( q k − q i ). The thesis follows from the fact that the number of subspaces U ⊆ F mq with dim F q ( U ) = r is (cid:20) mr (cid:21) . Remark 60.
We notice that if one has the number of matrices in Mat( k × m, F q ) of rank r andzero h -trace, then he can also determine the number of matrices in Mat( k × m, F q ) of rank r and h -trace equal to α , for any α in F q . Since the number of k × m matrices over F q of rank r is given by Lemma 59, this fact is trivial when q = 2. On the other hand, if q > α = β are non-zero elements of F q , then the map Mat( k × m, F q ) → Mat( k × m, F q ) defined by M α − βM gives a bijection between the rank r matrices with h -trace equal to α and therank r matrices with h -trace equal to β . It follows that for any α ∈ F q \ { } the number ofmatrices in Mat( k × m, F q ) with rank r and h -trace equal to α is n q ( k × m, r, − n q ( k × m, r, h ) q − , where n q ( k × m, r,
0) is explicitly given by Lemma 59.
Remark 61.
The usual way of computing n q ( k × k, k, k ) involves the Bruhat decompositionof GL k ( F q ) and the theory of q -analogues (see [24], Proposition 1.10.15). A different approachproposed in [16] is based on Gauss sums over finite fields and properties of the Borel subgroup ofGL k ( F q ). In [2] Buckheister derived a recursive description for n q ( k × k, r, k ) using an elementaryargument, and in [1] Bender applied the results of [2] to provide a closed formula for n q ( k × k, r, k ).As Stanley observed ([24], page 100), the description of [2] is quite complicated. The followingTheorem 62 provides a new recursive formula for the numbers n q ( k × m, r, h ) which easily followsfrom Corollary 33. An explicit version of the same formula can be found in Appendix A.16 heorem 62. Let 1 ≤ k ≤ m and 1 ≤ h ≤ k be integers. For all 0 ≤ r ≤ k the numbers n q ( r, h ) := n q ( k × m, r, h ) are recursively computed by the following formulas. n q ( r, h ) = r = 0, q mr − (cid:18)(cid:20) kr (cid:21) + ( q − (cid:20) k − hr (cid:21)(cid:19) − r − X j =0 n q ( j, h ) (cid:20) k − jr − j (cid:21) if 1 ≤ r ≤ k − h , q mr − (cid:20) kr (cid:21) − r − X j =0 n q ( j, h ) (cid:20) k − jr − j (cid:21) if k − h + 1 ≤ r ≤ k . Proof.
We fix 1 ≤ h ≤ k . Let M ∈ Mat( k × m, F q ) be the matrix defined by M ij := (cid:26) i = j ≤ h ,0 otherwise.Let C := h M i ⊆ Mat( k × m, F q ) be the Delsarte code generated by M over F q . It is easy tocheck that for any matrix N ∈ Mat( k × m, F q ) we have Tr h ( N ) = Tr( M N t ) = h M, N i . As aconsequence, the set of matrices in Mat( k × m, F q ) with zero h -trace is precisely C ⊥ . Hence, wehave n q ( r, h ) = B r for all 0 ≤ r ≤ k , where ( B j ) j ∈ N is the rank distribution of C ⊥ . If ( A i ) i ∈ N denotes the rank distribution of C , then we clearly have A = 1, A h = q −
1, and A i = 0 for i / ∈ { , h } . The theorem now follows from Corollary 33. Example 63.
Let q = 4, k = 3, m = 4. Theorem 33 allows us to compute all the values of n (3 × , r, h ) as in Table 1. r = 0 r = 1 r = 2 r = 3 h = 1 1 2283 381780 3810240 h = 2 1 1515 336468 3856320 h = 3 1 132 337428 3855552Table 1: Values of n (3 × , r, h ). Conclusions
In this paper we prove that the duality theory of linear Delsarte codes generalizes the dualitytheory of linear Gabidulin codes. The relation between the two duality theories is describedthrough trace-orthogonal bases of finite fields. We also give an elementary proof of MacWilliamsidentities for the general case of Delsarte codes, and show how to employ them to re-establishin a very concise way the main results of the theory of rank-metric codes. This also proves thatMacWilliams identities may be taken as a starting point for the theory of rank-metric codes.We also investigate optimal Delsarte anticodes, and characterize them in terms of MRD codes.Finally, we show an application of our results solving a problem in enumerative combinatoricsin an elementary way.
Acknowledgement
The author is grateful to Elisa Gorla and to the Referees for many useful suggestions thatimproved the presentation of the paper. 17
Explicit form of Theorem 31 and 62
Using known properties of binomial coefficients one can show that Theorem 31 implies Theorem3.3 of [6] as an easy corollary. The following result, first proved by Delsarte using the theory ofassociation schemes, may be regarded as the explicit version of Theorem 31.
Theorem 64.
Let
C ⊆
Mat( k × m, F q ) be a code. Let ( A i ) i ∈ N and ( B j ) j ∈ N be the rankdistributions of C and C ⊥ , respectively. We have B j = 1 |C| k X i =0 A i k X s =0 ( − j − s q ms + ( j − s ) (cid:20) k − sk − j (cid:21) (cid:20) k − is (cid:21) for j = 0 , ..., k . Proof.
Throughout this proof the rows and columns of matrices are labeled from 0 to k forconvenience (instead of from 1 to k + 1). Define the matrix P ∈ Mat( k + 1 × k + 1 , F q ) by P ji := 1 |C| k X s =0 ( − j − s q ms + ( j − s ) (cid:20) k − sk − j (cid:21) (cid:20) k − is (cid:21) for j, i ∈ { , ..., k } . We can write the statement in matrix form as ( B , ..., B k ) t = P · ( A , ..., A k ) t .Define matrices S, T ∈ Mat( k + 1 × k + 1 , F q ) by S ij := (cid:20) k − ji − j (cid:21) , T ij := q mi |C| (cid:20) k − ji (cid:21) for i, j ∈ { , ..., k } . We notice that S is invertible, since it is lower-triangular and S ii = 1for i = 0 , ..., k . Theorem 31 reads S · ( B , ..., B k ) t = T · ( A , ..., A k ) t , i.e., ( B , ..., B k ) t = S − T · ( A , ..., A k ) t . Hence it suffices to prove P = S − T , i.e., T = SP . Fix arbitrary integers i, j ∈ { , ..., k } . We have( SP ) ij = 1 |C| k X r =0 (cid:20) k − ri − r (cid:21) k X s =0 ( − r − s q ms + ( r − s ) (cid:20) k − sk − r (cid:21) (cid:20) k − js (cid:21) = 1 |C| k X s =0 q ms (cid:20) k − js (cid:21) k X r =0 (cid:20) k − ri − r (cid:21) ( − r − s q ( r − s ) (cid:20) k − sk − r (cid:21) . Clearly, (cid:20) k − ri − r (cid:21) = (cid:20) k − rk − i (cid:21) , and using the definition of Gaussian binomial coefficient one finds (cid:20) k − sk − r (cid:21) (cid:20) k − rk − i (cid:21) = (cid:20) k − sk − i (cid:21) (cid:20) i − sr − s (cid:21) . k X r =0 (cid:20) k − ri − r (cid:21) ( − r − s q ( r − s ) (cid:20) k − sk − r (cid:21) = k X r =0 (cid:20) k − sk − i (cid:21) (cid:20) i − sr − s (cid:21) ( − r − s q ( r − s )= (cid:20) k − sk − i (cid:21) k X r =0 (cid:20) i − sr − s (cid:21) ( − r − s q ( r − s )= (cid:20) k − sk − i (cid:21) k − s X r = − s (cid:20) i − sr (cid:21) ( − r q ( r )= (cid:20) k − sk − i (cid:21) i − s X r =0 (cid:20) i − sr (cid:21) ( − r q ( r )= (cid:26) s = i ,0 otherwise,where the last equality follows from the q -Binomial Theorem ([24], page 74). It follows( SP ) ij = 1 |C| q mi (cid:20) k − ji (cid:21) = T ij , as claimed.Arguing as in the proof of Theorem 62 and replacing Corollary 33 with Theorem 64 we easilyobtain the following explicit version of Theorem 62. Theorem 65.
Let 1 ≤ k ≤ m , 1 ≤ h ≤ k and 0 ≤ r ≤ k be integers. The number of k × m matrices over F q having rank r and zero h -trace is n q ( k × m, r, h ) = 1 q k X s =0 ( − r − s q ms + ( r − s ) (cid:20) k − sk − r (cid:21) (cid:18)(cid:20) ks (cid:21) + ( q − (cid:20) k − hs (cid:21)(cid:19) . Remark 66.
Theorem 65 generalizes the works cited in Remark 61.
References [1] E. A. Bender,
On Buckhiesters enumeration of n × n matrices , Journal of CombinatorialTheory, Series A, 17 (1974), pp. 273 – 274.[2] P. G. Buckhiester, The number of n × n matrices of rank r and trace α over a finite field ,Duke Mathematical Journal, 39 (1972), pp. 695 – 699.[3] P. Camion, Codes and association schemes . In V. S. Pless and W. C. Huffman (editors),Handbook of Coding Theory, Vol. II, pp. 1441 – 1566. Elsevier (1998).[4] P. Delsarte,
An algebraic approach to the association schemes of coding theory . PhilipsResearch Report, Supplement, 10 (1973).[5] P. Delsarte,
Association schemes and t -designs in regular semilattices . Journal of Combi-natoria Theory, Series A, 20 (1976), pp. 230 – 243.196] P. Delsarte, Bilinear forms over a finite field, with applications to coding theory . Journal ofCombinatorial Theory, Series A, 25 (1978), 3, pp. 226 – 241.[7] P. Delsarte, V. Levenshtein,
Association schemes and coding theory . IEEE Transactions onInformation Theory, 44 (1988), pp. 2477 –2504.[8] J. G. Dumas, R. Gow, G. McGuire, J. Sheekey,
Subspaces of matrices with special rankproperties . Linear Algebra and Its Applications, 433 (2010), pp. 191 – 202.[9] E. Gabidulin
Theory of codes with maximum rank distance . Problems of Information Trans-mission, 1 (1985), 2, pp. 1 – 12.[10] M. Gadouleau, Z. Yan
MacWilliams Identities for the Rank Metric . ISIT 2007 (Nice,France), pp. 36 – 40.[11] M. Gadouleau, Z. Yan,
MacWilliams identity for Codes with the Rank Metric . EURASIPJournal on Wireless Communications and Networking, 2008.[12] H. Gluesing-Luerssen,
Fourier-reflexive partitions and MacWilliams identities for ad-ditive codes . Designs, Codes and Cryptography (to appear). Preprint available at http://arxiv.org/pdf/1304.1207.pdf .[13] D. Grant, M. Varanasi,
Duality theory for space-time codes over finite fields . Advances inMathematics of Communications, 2 (2005), 1, pp. 35 – 54.[14] D. Grant, M. Varanasi,
Weight enumerators and a MacWilliams-type identity for space-time rank codes over finite fields . Proceedings of the 43rd Annual Allerton Conference onCommunication, Control, and Computing (2005), pp. 2137 – 2146.[15] R. K¨otter, F. R. Kschischang,
Coding for Errors and Erasures in Random Network Coding .IEEE Transactions on Information Theory, 54 (2008), 8, pp. 3579 – 3591.[16] Y. Li, S. Hu,
Gauss sums over some matrix groups . Journal of Number Theory, 132 (2012),12, pp. 2967 – 2976.[17] F. J. MacWilliams,
A Theorem on the Distribution of Weights in a Systematic Code . BellSystem Technical Journal, 42 (1963), 1, pp. 79 – 94.[18] F. J. MacWilliams, N. J. A. Sloane,
The Theory of Error-Correcting Codes . North HollandMathematical Library.[19] R. Lidl, H. Niederreiter,
Finite Fields . Addison-Wesley Publishing Company (1983).[20] D. Jungnickel, A. J. Menezes, S. A. Vanston,
The number of self-dual bases of GF ( q m ) over GF ( q ). Proceedings of the American Mathematical Society, 109 (1990), 1, pp. 23-29.[21] D. Silva, F. R. Kschishang, On metrics for error correction in network coding . IEEE Trans-actions on Information Theory, 55 (2009), 12, pp. 5479 – 5490.[22] D. Silva, F. R. Kschischang,
Universal Secure Network Coding via Rank-Metric Codes .IEEE Transactions on Information Theory, 57 (2011), 2, pp. 1124 – 1135.2023] D. Silva, E. S. Rogers, F. R. Kschishang, R. Koetter,
A Rank-Metric Approach to ErrorControl in Random Network Coding . IEEE Transactions on Information Theory, 54 (2008),9, pp. 3951 – 3967.[24] P. Stanley,