---
abstract: 'After a seminal paper by Shekeey (2016), a connection between maximum $h$-scattered ${{\mathbb F}_{q}}$-subspaces of $V(r,q^n)$ and maximum rank distance (MRD) codes has been established in the extremal cases $h=1$ and $h=r-1$. In this paper, we propose a connection for any $h\in\{1,\ldots,r-1\}$, extending and unifying all the previously known ones. As a consequence, we obtain examples of non-square MRD codes which are not equivalent to generalized Gabidulin or twisted Gabidulin codes. Up to equivalence, we classify MRD codes having the same parameters as the ones in our connection. Also, we determine the weight distribution of codes related to the geometric counterpart of maximum $h$-scattered subspaces.'
author:
- 'Giovanni Zini and Ferdinando Zullo[^1]'
title: Scattered subspaces and related codes
---

*Dedicated to the memory of Elisa Montanucci.\
We unite us to her family’s pain.*

51E20, 94B27, 15A04

rank metric code; scattered subspace; linear code; linear set

Introduction
============

An ${{\mathbb F}_{q}}$-subspace $U$ of an $r$-dimensional ${\mathbb{F}_{q^n}}$-vector space $V$ is said to be *$h$-scattered* if $U$ spans $V$ over ${\mathbb{F}_{q^n}}$ and, for any $h$-dimensional ${\mathbb{F}_{q^n}}$-subspace $H$ of $V$, $U$ meets $H$ in an ${{\mathbb F}_{q}}$-subspace of dimension at most $h$. This family of subspaces was introduced in [@CsMPZ] as a generalization of $1$-scattered subspaces, which are simply known as scattered subspaces and were originally presented in [@BL2000]. Since then, the theory of scattered subspaces has constantly increased its importance, mainly because of their applications to several algebraic and geometric objects, such as finite semifields, blocking sets, two-intersection sets; see [@Lavrauw; @LVdV2015; @Polverino]. After the seminal paper [@Sheekey] by Sheekey, the interest towards scattered subspaces was also boosted by their connections with the theory of rank metric codes, whose relevance in communication theory relies on its applications to random linear network coding and cryptography.

A $h$-scattered ${{\mathbb F}_{q}}$-subspace of highest dimension in $V(r,q^n)$ is called *maximum $h$-scattered*; its dimension is upper bounded by $\frac{rn}{h+1}$. This bound is known to be achieved in the following cases: $h=1$, $h=r-1$, $(h+1)\mid r$ or $h=n-3$; see Section \[sec:h-scatt\]. When $h=1$ or $h=r-1$, maximum $h$-scattered subspaces are strongly related to rank metric codes having the greatest correcting and detecting capabilities for fixed dimension and ambient space, that is, to maximum rank distance (MRD) codes. This has been shown in [@Sheekey; @CSMPZ2016; @PZ] for $h=1$ and in [@Lunardon2017; @ShVdV] for $h=r-1$, while no relation was known for $1<h<r-1$. In this paper we establish a connection between ${{\mathbb F}_{q}}$-subspaces of $V$ and rank metric codes. We start by generalizing the construction of rank-metric codes $\mathcal{C}_U$ provided in [@CSMPZ2016] and defined by an ${{\mathbb F}_{q}}$-subspace $U$ of $V$. We detect those $U$’s such that $\mathcal{C}_U$ is MRD; among these are the maximum $1$- and $(r-1)$-scattered subspaces. Actually, the code $\mathcal{C}_U$ is MRD exactly when $U$ is the dual of a $h$-scattered subspace of dimension $\frac{rn}{h+1}$, for some $1\leq h\leq r-1$. Therefore, our connection extends and unifies the ones in [@Sheekey; @CSMPZ2016; @PZ; @ShVdV; @Lunardon2017]. To this aim, we exhibit two characterizations of $h$-scattered subspaces of dimension $\frac{rn}{h+1}$, which are of independent interest. Moreover we prove that, up to equivalence, the MRD codes of type $\mathcal{C}_U$ are exactly the ${{\mathbb F}_{q}}$-linear MRD codes with parameters $(\frac{rn}{h+1},n,q;n-h)$ and maximum right idealiser.

An essential though difficult task is to decide whether or not two rank metric codes with the same parameters are equivalent (especially when they correspond to non-square matrices). A remarkable aspect of the MRD codes that we construct is that we are able to determine one of their idealisers; this allows to prove that some of them are not equivalent to punctured generalized Gabidulin codes nor to punctured generalized twisted Gabidulin codes.

The geometric counterparts of $h$-scattered subspaces of dimension $\frac{rn}{h+1}$ are called *$h$-scattered linear sets* of rank $\frac{rn}{h+1}$. They are known to have at most $h+1$ intersection numbers with respect to the hyperplanes, and hence are of interest in coding theory when regarded as projective systems. The intersection numbers w.r.t. the hyperplanes of $h$-scattered linear sets of rank $\frac{rn}{h+1}$ have been determined in [@BL2000] for $h=1$, in [@NZ] for $h=2$, and in [@ShVdV] for $h=r-1$. We determine them for any $1\leq h\leq r-1$, by using the connection between MRD codes and $h$-scattered subspaces of dimension $\frac{rn}{h+1}$ presented in Section \[sec:subMRD\]. As a byproduct, we compute the weight distribution of the arising codes; this answers a question posed by Randrianarisoa [@Ra].

The paper is organized as follows. Section \[sec:pre\] contains preliminary results on $h$-scattered subspaces (Section \[sec:h-scatt\]), dualities of subspaces, both ordinary and Delsarte (Section \[sec:dualities\]), linear codes, equipped with the Hamming distance or with the rank metric (Section \[sec:codes\]). In Section \[sec:subMRD\] we describe the connection between ${{\mathbb F}_{q}}$-subspaces and rank metric codes, characterizing those codes which are MRD, and showing that ${{\mathbb F}_{q}}$-linear MRD $(\frac{rn}{h+1},n,q;n-h)$-codes with maximum right idealiser are exactly the codes of type $\mathcal{C}_U$, up to equivalence. This connection is shown to extend and unify the previously known ones in Section \[sec:uni\]. Section \[sec:twocharact\] completes the connection between $h$-scattered subspaces of dimension $\frac{rn}{h+1}$ and MRD codes, by means of two characterizations which are proved through the ordinary and Delsarte dualities. Section \[sec:noGab\] provides families of MRD codes which are not equivalent to punctured generalized (twisted) Gabidulin codes. Section \[sec:h+1weights\] computes the weight distribution of the linear codes arising from $h$-scattered linear sets of rank $\frac{rn}{h+1}$, seen as projective systems. Finally, in Section \[sec:open\], we resume our results and state some open questions.

Preliminaries {#sec:pre}
=============

Scattered $\mathbb{F}_q$-subspaces with respect to $\mathbb{F}_{q^n}$-subspaces {#sec:h-scatt}
-------------------------------------------------------------------------------

Let $V=V(m,q)$ denote an $m$-dimensional ${{\mathbb F}}_q$-vector space. A $t$-spread of $V$ is a set ${{\mathcal S}}$ of $t$-dimensional ${{\mathbb F}}_q$-subspaces such that each vector of $V^*=V\setminus \{{\bf 0}\}$ is contained in exactly one element of ${{\mathcal S}}$. As shown by Segre in [@Segre], a $t$-spread of $V$ exists if and only if $t$ divides $m$.

Let $V$ be an $r$-dimensional ${{\mathbb F}}_{q^n}$-vector space and let ${{\mathcal S}}$ be an $n$-spread of $V$. An ${{\mathbb F}}_q$-subspace $U$ of $V$ is called *scattered* w.r.t. ${{\mathcal S}}$ if $U$ meets every element of ${{\mathcal S}}$ in an ${{\mathbb F}}_q$-subspace of dimension at most one; see [@BL2000]. If we consider $V$ as an $rn$-dimensional ${{\mathbb F}}_q$-vector space, then it is well-known that the one-dimensional ${{\mathbb F}}_{q^n}$-subspaces of $V$, viewed as $n$-dimensional ${{\mathbb F}}_q$-subspaces, form an $n$-spread of $V$. This spread is called the *Desarguesian spread*. In this paper scattered will always mean scattered w.r.t. the Desarguesian spread. Blokhuis and Lavrauw [@BL2000] showed that the dimension of such subspaces is bounded by $rn/2$. After a series of papers it is now known that when $rn$ is even there always exist scattered subspaces of dimension $rn/2$; they are called *maximum scattered* [@BBL2000; @BGMP2015; @BL2000; @CSMPZ2016].

In [@CsMPZ], the authors introduced a special family of scattered subspaces, named $h$-scattered subspaces. Let $V$ be an $r$-dimensional ${{\mathbb F}}_{q^n}$-vector space and $h\leq r-1$ be a positive integer. An ${{\mathbb F}}_q$-subspace $U$ of $V$ is called $h$-*scattered* (or scattered w.r.t. the $h$-dimensional ${\mathbb{F}_{q^n}}$-subspaces) if ${\langle}U {\rangle}_{{{\mathbb F}}_{q^n}}=V$ and each $h$-dimensional ${{\mathbb F}}_{q^n}$-subspace of $V$ meets $U$ in an ${{\mathbb F}}_q$-subspace of dimension at most $h$. The $1$-scattered subspaces are the scattered subspaces generating $V$ over ${{\mathbb F}}_{q^n}$. The same definition applied to $h=r$ describes the $n$-dimensional ${{\mathbb F}}_q$-subspaces of $V$ defining canonical subgeometries of ${\mathrm{PG}}(V,{{\mathbb F}}_{q^n})$. If $h=r-1$ and $\dim_{{{\mathbb F}}_q}(U)=n$, then $U$ is $h$-scattered exactly when $U$ defines a scattered ${{\mathbb F}}_q$-linear set with respect to the hyperplanes, introduced in [@ShVdV Definition 14]; see also [@Lunardon2017].

Theorem \[th:bound\] bounds the dimension of a $h$-scattered subspace.

\[th:bound\][[@CsMPZ Theorem 2.3]]{} If $U$ is a $h$-scattered ${{\mathbb F}}_q$-subspace of dimension $k$ in $V=V(r,q^n)$, then one of the following holds:

-   $k=r$ and $U$ defines a subgeometry ${\mathrm{PG}}(r-1,q)$ of ${\mathrm{PG}}(V,{{\mathbb F}}_{q^n})$;

-   $k\leq\frac{rn}{h+1}$.

A $h$-scattered ${{\mathbb F}}_q$-subspace of highest possible dimension is said to be a [*maximum $h$-scattered*]{} ${{\mathbb F}}_q$-subspace. Theorem \[th:inter\] bounds the dimension of the intersection between a $h$-scattered subspace of dimension $\frac{rn}{h+1}$ and an ${\mathbb{F}_{q^n}}$-subspace of codimension $1$.

[[@CsMPZ Theorem 2.8]]{} \[th:inter\] If $U$ is an $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}}_q$-subspace of a vector space $V=V(r,q^n)$, then for any $(r-1)$-dimensional ${{\mathbb F}}_{q^n}$-subspace $H$ of $V$ we have $$\frac{rn}{h+1}-n\leq \dim_{{{\mathbb F}}_q}(U \cap H) \leq \frac{rn}{h+1}-n+h.$$

Constructions of $h$-scattered ${{\mathbb F}}_q$-subspaces have been given in [@CsMPZ] and also in [@NPZZ]. A generalization of $h$-scattered subspaces has been recently introduced in [@BCsMT].

Two dualities for $\mathbb{F}_q$-subspaces {#sec:dualities}
------------------------------------------

In this paper we need both ordinary and Delsarte dualities.

### Ordinary duality {#sec:classicalduality}

Let $\sigma \colon V\times V \rightarrow \mathbb{F}_{q^n}$ be a non-degenerate reflexive sesquilinear form over $V=V(r,q^n)$ and define $\sigma' \colon V \times V \rightarrow \mathbb{F}_q, \, (\mathbf{u},\mathbf{v})\mapsto \mathrm{Tr}_{q^n/q}(\sigma(\mathbf{u},\mathbf{v}))$. Once we regard $V$ as an $rn$-dimensional ${{\mathbb F}}_q$-vector space, $\sigma^\prime$ turns out to be a non-degenerate reflexive sesquilinear form over $V=V(rn,q)$. Let $\perp$ and $\perp'$ be the orthogonal complement maps defined by $\sigma$ and $\sigma'$ on the lattices of the ${{\mathbb F}}_{q^n}$-subspaces and the ${{\mathbb F}}_q$-subspaces of $V$, respectively. The following properties hold (see [@Polverino Section 2] for the details).

-   $\dim_{{{\mathbb F}}_{q^n}}(W)+\dim_{{{\mathbb F}}_{q^n}}(W^\perp)=r$, for every ${{\mathbb F}}_{q^n}$-subspace $W$ of $V$.

-   $\dim_{{{\mathbb F}}_{q}}(U)+\dim_{{{\mathbb F}}_{q}}(U^{\perp'})=nr$, for every ${{\mathbb F}}_{q}$-subspace $U$ of $V$.

-   $W^\perp=W^{\perp'}$, for every ${{\mathbb F}}_{q^n}$-subspace $W$ of $V$.

-   Let $W$ and $U$ be an ${{\mathbb F}}_{q^n}$-subspace and an ${{\mathbb F}}_q$-subspace of $V$ of dimension $s$ and $t$, repsectively. Then $$\label{eq:dualweight} \dim_{{{\mathbb F}}_q}(U^{\perp'}\cap W^{\perp'})-\dim_{{{\mathbb F}}_q}(U\cap W)=rn-\dim_{{{\mathbb F}}_q}(U)-sn.$$

-   Let $\sigma$, $\sigma_1$ be non-degenerate reflexive sesquilinear forms over $V$ and define $\sigma^\prime$, $\sigma_1^\prime$, $\perp$, $\perp_1$, $\perp'$ and $\perp_1'$ as above. Then there exists an invertible ${{\mathbb F}}_{q^n}$-linear map $f$ such that $f(U^{\perp'})=U^{\perp_1'}$, i.e. $U^{\perp'}$ and $U^{\perp_1'}$ are $\mathrm{GL}(V)$-equivalent.

When $U$ is an ${{\mathbb F}}_q$-subspace of $V$, we denote by $U^{\perp_O}$ one of the ${{\mathbb F}}_q$-subspaces $U^{\perp'}$, where $\perp'$ is defined by the restriction to ${{\mathbb F}}_q$ of any non-degenerate reflexive sesquilinear form over $V$, as defined at the beginning of this section.

### Delsarte duality {#sec:Delsarteduality}

Let $U$ be a $k$-dimensional ${{\mathbb F}}_q$-subspace of a vector space $V=V(r,q^n)$, with $k>r$. By [@LuPo2004 Theorems 1, 2] (see also [@LuPoPo2002 Theorem 1]), there is an embedding of $V$ in $\operatorname{\mathbb{V}}=V(k,q^n)$ with $\operatorname{\mathbb{V}}=V \oplus \Gamma$ for some $(k-r)$-dimensional ${{\mathbb F}}_{q^n}$-subspace $\Gamma$ such that $U={\langle}W,\Gamma{\rangle}_{{{\mathbb F}}_{q}}\cap V$, where $W$ is a $k$-dimensional ${{\mathbb F}}_q$-subspace of $\operatorname{\mathbb{V}}$ satisfying $\langle W\rangle_{{{\mathbb F}}_{q^n}}=\operatorname{\mathbb{V}}$ and $W\cap \Gamma=\{{\bf 0}\}$. Then $ \varphi:V\to\operatorname{\mathbb{V}}/\Gamma$, $\mathbf{v}\mapsto \mathbf{v}+\Gamma$, is an ${\mathbb{F}_{q^n}}$-isomorphism such that $\varphi(U)=W+\Gamma$.

Following [@CsMPZ Section 3], let $\beta'\colon W\times W\rightarrow{{\mathbb F}}_{q}$ be a non-degenerate reflexive sesquilinear form on $W$. Then $\beta'$ can be extended to a non-degenerate reflexive sesquilinear form $\beta\colon \operatorname{\mathbb{V}}\times\operatorname{\mathbb{V}}\rightarrow{{\mathbb F}}_{q^n}$. Let $\perp$ and $\perp'$ be the orthogonal complement maps defined by $\beta$ and $\beta'$ on the lattices of ${{\mathbb F}}_{q^n}$-subspaces of $\operatorname{\mathbb{V}}$ and of ${{\mathbb F}}_q$-subspaces of $W$, respectively. For an ${{\mathbb F}}_q$-subspace $S$ of $W$ the ${{\mathbb F}}_{q^n}$-subspace ${\langle}S {\rangle}_{{{\mathbb F}}_{q^n}}$ of $\operatorname{\mathbb{V}}$ will be denoted by $S^*$. In this case, $(S^*)^{\perp}=(S^{\perp'})^*$.

\[deffff\] Let $U$ be a $k$-dimensional ${{\mathbb F}}_q$-subspace of $V=V(r,q^n)$ such that $k>r$ and $\dim_{{{\mathbb F}}_q}(M\cap U)<k-1$ for every $(r-1)$-dimensional ${\mathbb{F}_{q^n}}$-subspace $M$ of $V$. Then the $k$-dimensional ${{\mathbb F}}_q$-subspace $W+\Gamma^{\perp}$ of the quotient space $\operatorname{\mathbb{V}}/\Gamma^{\perp}$ will be denoted by $ U^{\perp_{D}}$ and will be called the *Delsarte dual* of $U$ (w.r.t. $\perp$).

The Delsarte duality preserves the property of being scattered w.r.t. ${\mathbb{F}_{q^n}}$-subspaces, in the following sense.

[@CsMPZ Theorem 3.3] \[thm:dual\] Let $U$ be a $k$-dimensional $h$-scattered ${{\mathbb F}}_q$-subspace of a vector space $V=V(r,q^n)$ with $n\geq h+3$. Then $U^{\perp_{D}}$ is an $\frac{rn}{h+1}$-dimensional $(n-h-2)$-scattered ${{\mathbb F}_{q}}$-subspace of $\operatorname{\mathbb{V}}/\Gamma^\perp=V(k-r,q^n)$.

Proposition \[prop:property\] points out some properties of the Delsarte duality.

\[prop:property\] Let $U$, $W$, $V$, $\Gamma$, $\operatorname{\mathbb{V}}$, $\perp$ and $\perp_D$ be defined as above. The following properties hold:

-   $(U^{\perp_D})^{\perp_D}=W+\Gamma=\varphi^{-1}(U)$;

-   under the assumption $n\geq h+3$, $U$ is an $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspace of $V$ if and only if $U^{\perp_D}$ is an $\frac{rn}{h+1}$-dimensional $(n-h-2)$-scattered ${{\mathbb F}_{q}}$-subspace of $\operatorname{\mathbb{V}}/\Gamma^{\perp}$.

The first property easily follows from the definition of Delsarte duality. Together with Theorem \[thm:dual\] applied to $U^{\perp_D}$, this yields the second property.

Generalities on codes {#sec:codes}
---------------------

In this section we recall some properties of codes that will be used in the paper. In Section \[sec:Hamming\] we consider ${{\mathbb F}_{q}}$-linear codes with respect to the Hamming metric in ${{\mathbb F}}_{q}^N$, while in Section \[sec:rank\] we consider ${{\mathbb F}_{q}}$-linear codes with respect to the rank metric in ${{\mathbb F}}_{q}^{m\times n}$.

### Projective systems and linear codes {#sec:Hamming}

Let $\mathcal{C}\subseteq{{\mathbb F}}_q^N$ be an ${{\mathbb F}_{q}}$-linear code of length $N$, dimension $k$ and minimum distance $d$ over the alphabet ${{\mathbb F}_{q}}$; we denote by $[N,k,d]_q$ the parameters of $\mathcal{C}$. A generator matrix of $\mathcal{C}$ is a matrix $G\in{{\mathbb F}}_q^{k\times N}$ whose rows form a basis of $\mathcal{C}$. The weight of a codeword $\mathbf{c}\in\mathcal{C}$ is the number of nonzero components of $\mathbf{c}$, and $A_i^H$ will denote the number of codewords of weight $i$ in $\mathcal{C}$. The $N$-tuple $(A_0^H=1,A_1^H,\ldots,A_N^H)$ is called the weight distribution of $\mathcal{C}$, and the polynomial $\sum_{i=0}^{N}A_i^H z^i$ is the weight enumerator of $\mathcal{C}$.

A projective $[N,k,d]_q$-system is a point subset $\mathcal{P}$ of $\Omega={\mathrm{PG}}(k-1,q)$ of size $N$, not contained in any hyperplane of $\Omega$, such that $$d= N - \max\{|\mathcal{P}\cap\mathcal{H}|\colon \mathcal{H}\,\mbox{ is a hyperlane of }\,\Omega\}.$$ The matrix $G\in{{\mathbb F}}_q^{k\times N}$ whose columns are the coordinates of the points of a projective $[N,k,d]_q$-system $\mathcal{P}$ is the generator matrix of a linear code with parameters $[N,k,d]_q$. Different choices of the coordinates yield linear codes which are equivalent by means of a diagonal matrix; we denote one of them by $\mathcal{C}_{\mathcal{P}}$.

\[prop:projsyst\] Let $\mathcal{P}$ be a projective $[N,k,d]_q$-system of $\Omega$ and $\mathcal{C}_{\mathcal{P}}$ be a corresponding linear $[N,k,d]_q$-code. Then the weights of $\mathcal{C}_{\mathcal{P}}$ are the values $N-i$, where $i=|\mathcal{P}\cap\mathcal{H}|$ and $\mathcal{H}$ runs over the hyperplanes of $\Omega$. The number $A_i^H$ of codewords of $\mathcal{C}_{\mathcal{P}}$ with weight $i$ is equal to the number of hyperplanes $\mathcal{H}$ of $\Omega$ such that $|\mathcal{P}\cap\mathcal{H}|=i$.

### Rank metric codes {#sec:rank}

Rank metric codes were introduced by Delsarte [@Delsarte] in 1978 and they have been intensively investigated in recent years because of their applications; we refer to [@sheekey_newest_preprint] for a survey on this topic. The set ${{\mathbb F}_{q}}^{m\times n}$ of $m \times n$ matrices over ${{\mathbb F}_{q}}$ may be endowed with a metric, called *rank metric*, defined by $$d(A,B) = \mathrm{rk}\,(A-B).$$ A subset $\operatorname{\mathcal{C}}\subseteq {{\mathbb F}_{q}}^{m\times n}$ equipped with the rank metric is called a *rank metric code* (shortly, an *RM code*). The minimum distance of $\operatorname{\mathcal{C}}$ is defined as $$d = \min\{ d(A,B) \colon A,B \in \operatorname{\mathcal{C}},\,\, A\neq B \}.$$ Denote the parameters of an RM code $\operatorname{\mathcal{C}}\subseteq{{\mathbb F}_{q}}^{m\times n}$ with minimum distance $d$ by $(m,n,q;d)$. We are interested in ${{\mathbb F}_{q}}$-*linear* RM codes, i.e. ${{\mathbb F}_{q}}$-subspaces of ${{\mathbb F}_{q}}^{m\times n}$. Delsarte showed in [@Delsarte] that the parameters of these codes must obey a Singleton-like bound.

\[th:Singleton\] If $\operatorname{\mathcal{C}}$ is an RM code of ${{\mathbb F}}_q^{m\times n}$ with minimum distance $d$, then $$|\operatorname{\mathcal{C}}| \leq q^{\max\{m,n\}(\min\{m,n\}-d+1)}.$$

When equality holds, we call $\operatorname{\mathcal{C}}$ a *maximum rank distance* (*MRD* for short) code. Examples of MRD codes are resumed in [@PZ; @sheekey_newest_preprint], see also the paper [@SheekeyLondon].

For an RM code ${{\mathcal C}}\subseteq {{\mathbb F}}_{q}^{m \times n}$, the *adjoint code* of $\operatorname{\mathcal{C}}$ is $$\operatorname{\mathcal{C}}^\top =\{C^t \colon C \in \operatorname{\mathcal{C}}\},$$ where $C^t$ is the transpose matrix of $C$. Define the symmetric bilinear form $\langle\cdot,\cdot\rangle$ on ${{\mathbb F}}_q^{m \times n}$ by $$\langle M,N \rangle= \mathrm{Tr}(MN^t).$$ The *Delsarte dual code* of an ${{\mathbb F}}_q$-linear RM code $\operatorname{\mathcal{C}}\subseteq {{\mathbb F}}_{q}^{m \times n}$ is $$\operatorname{\mathcal{C}}^\perp = \{ N \in {{\mathbb F}}_q^{m\times n} \colon \langle M,N \rangle=0 \; \text{for each} \; M \in \operatorname{\mathcal{C}}\}.$$

\[rk:dualMRD\] If $\mathcal{C}\subseteq {{\mathbb F}}_{q}^{m \times n}$ is an MRD code with minimum distance $d$, then $\operatorname{\mathcal{C}}^\top$ and $\mathcal{C^\perp}$ are MRD codes with minimum distances $d$ and $\min\{m,n\}-d+2$, respectively; see [@Delsarte; @Ravagnani].

Given an RM code $\mathcal{C}$ in $\mathbb{F}_{q}^{m\times n}$ and an integer $i \in \mathbb{N}$, define $A_i=|\{M \in \mathcal{C} \colon \mathrm{rk}(M)=i\}|$. The *rank distribution* of $\mathcal{C}$ is the vector $(A_i)_{i \in \mathbb{N}}$. MacWilliams identities for RM codes are stated in Theorem \[th:MacWilliams\] and were first obtained by Delsarte in [@Delsarte] using the machinery of association schemes; see also [@Ravagnani] for a different approach. Recall that the $q$-binomial coefficient of two integers $s$ and $t$ is $${s \brack t}_q=\left\{ \begin{array}{lll} 0 & \text{if}\,\, s<0,\,\,\text{or}\,\,t<0,\,\, \text{or}\,\, t>s,\\ 
1 & \text{if}\,\, t=0\,\, \text{and}\,\, s\geq 0,\\
\displaystyle\prod_{i=1}^t \frac{q^{s-i+1}-1}{q^i-1} & \text{otherwise}. \end{array} \right.$$

([@Delsarte Theorem 3.3],[@Ravagnani Theorem 31])\[th:MacWilliams\] Let $\mathcal{C}$ be an RM code in $\mathbb{F}_q^{m\times n}$. Let $(A_i)_{i\in \mathbb{N}}$ and $(B_j)_{j\in \mathbb{N}}$ be the rank distribution of $\mathcal{C}$ and $\mathcal{C}^\perp$, respectively. For any integer $\nu \in \{ 0,\ldots,m \}$ we have $$\sum_{i=0}^{m-\nu} A_i  {m-i \brack \nu}_q = \frac{|\mathcal{C}|}{q^{n\nu}} \sum_{j=0}^\nu B_j {m-j \brack \nu -j}_q.$$

As a consequence, Delsarte in [@Delsarte] and later Gabidulin in [@Gabidulin] determined precisely the weight distribution of MRD codes.

\[th:weightdistribution\] Let $\mathcal{C}$ be an MRD code in $\mathbb{F}_q^{m\times n}$ with minimum distance $d$. Let $m'=\min\{m,n\}$ and $n'=\max\{m,n\}$. Then $$A_{d+\ell}={m'\brack d+\ell}_q \sum_{t=0}^\ell (-1)^{t-\ell}{\ell+d \brack \ell-t}_q q^{\binom{\ell-t}{2}}(q^{n'(t+1)}-1)$$ for any $\ell \in \{0,1,\ldots,n'-d\}$.

In particular, Lemma \[lemma:weight\] holds.

([@LTZ2 Lemma 2.1],\[lemma:weight\][@Ravagnani Lemma 52])\[lemma:complete weight\] Let $\mathcal{C}$ be an MRD code in $\mathbb{F}_q^{m\times n}$ with minimum distance $d$. Let $m'=\min\{m,n\}$ and $n'=\max\{m,n\}$. Assume that the null matrix $O$ is in $\mathcal{C}$. Then, for any $0 \leq \ell \leq m'-d$, we have $A_{d+\ell}>0$, i.e. there exists at least one matrix $C \in \mathcal{C}$ such that $\mathrm{rk} (C) = d + \ell$.

Theorem \[th:dualrelations\] follows from the MacWilliam identities.

\[th:dualrelations\]([@Ravagnani Proof of Corollary 44]) Let $\mathcal{C}$ be an MRD code in $\mathbb{F}_q^{m\times n}$ with minimum distance $d$. Let $m'=\min\{m,n\}$ and $n'=\max\{m,n\}$. Then for any $\nu \in \{0,\ldots,m'-d \}$ we have $$\label{eq:identities} {m' \brack \nu}_q+\sum_{i=d}^{m'-\nu} A_i {m'-i \brack \nu}_q=\frac{|\mathcal{C}|}{q^{n'\nu}} {m' \brack \nu}_q.$$

By Remark \[rk:dualMRD\], the minimum distance of $\mathcal{C}^\perp$ is $m'-d+2$. Thus, Theorem \[th:MacWilliams\] proves the claim.

Two RM codes $\operatorname{\mathcal{C}}$ and $\operatorname{\mathcal{C}}'$ in $\mathbb{F}_q^{m\times n}$ are *equivalent* if and only if there exist $X \in \mathrm{GL}(m,q)$, $Y \in \mathrm{GL}(n,q)$, $Z \in {{\mathbb F}}_q^{m\times n}$ and a field automorphism $\sigma$ of ${{\mathbb F}}_q$ such that $$\operatorname{\mathcal{C}}'=\{XC^\sigma Y + Z \colon C \in \operatorname{\mathcal{C}}\}.$$ The *left* and *right idealisers* $L(\operatorname{\mathcal{C}})$ and $R(\operatorname{\mathcal{C}})$ of an RM code $\mathcal{C}\subseteq{{\mathbb F}}_{q}^{m\times n}$ are defined as $$L(\operatorname{\mathcal{C}})=\{ Y \in {{\mathbb F}}_q^{m \times m} \colon YC\in \operatorname{\mathcal{C}}\hspace{0.1cm} \text{for all}\hspace{0.1cm} C \in \operatorname{\mathcal{C}}\},$$ $$R(\operatorname{\mathcal{C}})=\{ Z \in {{\mathbb F}}_q^{n \times n} \colon CZ\in \operatorname{\mathcal{C}}\hspace{0.1cm} \text{for all}\hspace{0.1cm} C \in \operatorname{\mathcal{C}}\}.$$ The notion of idealisers have been introduced by Liebhold and Nebe in [@LN2016 Definition 3.1]; they are invariant under equivalences of rank metric codes. Further invariants have been introduced in [@GiuZ; @NPH2]. In [@LTZ2], idealisers have been studied in details and the following result has been proved.

\[th:propertiesideal\] Let $\mathcal{C}$ and $\mathcal{C}^\prime$ be ${{\mathbb F}_{q}}$-linear RM codes of ${{\mathbb F}_{q}}^{m\times n}$.

-   If $\mathcal{C}$ and $\mathcal{C}^\prime$ are equivalent, then their left and right idealisers are isomorphic as ${{\mathbb F}_{q}}$-algebras ([@LTZ2 Proposition 4.1]).

-   $L(\operatorname{\mathcal{C}}^\top)=R(\operatorname{\mathcal{C}})^\top$ and $R(\operatorname{\mathcal{C}}^\top)=L(\operatorname{\mathcal{C}})^\top$ ([@LTZ2 Proposition 4.2]).

-   Let $\mathcal{C}$ have minimum distance $d>1$. If $m \leq n$, then $L(\operatorname{\mathcal{C}})$ is a finite field with $|L(\operatorname{\mathcal{C}})|\leq q^m$. If $m \geq n$, then $R(\operatorname{\mathcal{C}})$ is a finite field with $|R(\operatorname{\mathcal{C}})|\leq q^n$. In particular, when $m=n$, $L(\operatorname{\mathcal{C}})$ and $R(\operatorname{\mathcal{C}})$ are both finite fields ([@LTZ2 Theorem 5.4 and Corollary 5.6]).

Let $\mathcal{C}$ be an RM code in ${{\mathbb F}_{q}}^{n\times n}$, and $A\in{{\mathbb F}_{q}}^{m\times n}$ be a matrix of rank $m\leq n$. The RM code $A\mathcal{C}=\{AM\colon M\in\mathcal{C}\}\subseteq{{\mathbb F}_{q}}^{m\times n}$ is a *punctured code* obtained by *puncturing $\mathcal{C}$ with $A$*.

\[th:punct\]([@BR Corollary 35], [@CsS Theorem 3.2]) Let $\operatorname{\mathcal{C}}$ be an MRD code with parameters $(n,n,q;d)$, $A \in {{\mathbb F}}_q^{m\times n}$ be a matrix of rank $m$, and $n-d\leq m\leq n$. Then the punctured code $A\operatorname{\mathcal{C}}$ is an MRD code with parameters $(m,n,q;d+m-n)$ and $(A\operatorname{\mathcal{C}})^\top$ is an MRD code with parameters $(n,m,q;d+m-n)$.

In the literature equivalent representations of RM codes are used, other than the matrix representation that has been described above, and some of them will be used in this paper. In particular, we see the elements of an ${{\mathbb F}_{q}}$-linear RM code $\mathcal{C}$ with parameters $(m,n,q;d)$ as:

-   matrices of ${{\mathbb F}}_q^{m\times n}$ having rank at least $d$;

-   ${{\mathbb F}_{q}}$-linear maps $V\to W$ where $V=V(n,q)$ and $W=V(m,q)$, having usual map rank at least $d$;

-   when $m=n$, elements of the ${{\mathbb F}_{q}}$-algebra $\mathcal{L}_{n,q}$ of $q$-polynomials over ${\mathbb{F}_{q^n}}$ modulo $x^{q^n}-x$, having rank at least $d$ as an ${{\mathbb F}_{q}}$-linear map ${\mathbb{F}_{q^n}}\to{\mathbb{F}_{q^n}}$.

Connection between ${{\mathbb F}_{q}}$-vector spaces and rank metric codes {#sec:subMRD}
==========================================================================

In this section, an ${{\mathbb F}_{q}}$-linear RM code with parameters $(m,n,q;d)$ is regarded as a set of ${{\mathbb F}_{q}}$-linear maps $W_1=V(n,q)\to W_2=V(m,q)$. The following notation will be used.

-   $\omega_{\alpha}:{\mathbb{F}_{q^n}}\to{\mathbb{F}_{q^n}}$, $x\mapsto\alpha x$, for any $\alpha\in{\mathbb{F}_{q^n}}$.

-   $\mathcal{F}_n=\{\omega_{\alpha}\colon\alpha\in{\mathbb{F}_{q^n}}\}$, which is a field isomorphic to ${\mathbb{F}_{q^n}}$.

-   $\mathcal{F}_{n,q}=\{\omega_{\alpha}\colon \alpha\in{{\mathbb F}_{q}}\}$, which is a subfield of $\mathcal{F}_n$ isomorphic to ${{\mathbb F}_{q}}$.

-   $\tau_{\mathbf{v}}:{\mathbb{F}_{q^n}}\to W_1$, $\lambda\mapsto \lambda \mathbf{v}$, for any $\mathbf{v}\in W_1$.

We define a family of ${{\mathbb F}_{q}}$-linear RM codes associated with an ${{\mathbb F}_{q}}$-vector space $U$.

Let $n,r,k$ be positive integers with $k<rn$, $U$ be a $k$-dimensional ${{\mathbb F}_{q}}$-subspace of an $r$-dimensional ${\mathbb{F}_{q^n}}$-vector space $V$, $W$ be an $(rn-k)$-dimensional ${{\mathbb F}_{q}}$-vector space, and $G:V\to W$ be an ${{\mathbb F}_{q}}$-linear map with kernel $U$. For any $\mathbf{v} \in V$ define the ${{\mathbb F}_{q}}$-linear map $\Gamma_{\mathbf{v}}=G\circ\tau_{\mathbf{v}}$.

\[th:construction\] Let $V=V(r,q^n)$ and $W=V(rn-k,q)$. Let $U=V(k,q)$ be an ${{\mathbb F}_{q}}$-subspace of $V$, and $G:V\to W$ be an ${{\mathbb F}_{q}}$-linear map with $\ker(G)=U$. Define $$\iota=\max\{\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}}) \colon \mathbf{v}\in V^*  \}.$$ If $\iota<n$, then the pair $(U,G)$ defines an ${{\mathbb F}_{q}}$-linear RM code $$\label{eq:rd}
    \mathcal{C}_{U,G}=\left\{ \Gamma_{\mathbf{v}}=G\circ \tau_{\mathbf{v}} \colon \mathbf{v} \in V \right\}$$ of dimension $rn$ with parameters $(rn-k,n,q;n-\iota)$, whose right idealiser contains $\mathcal{F}_n$.

For any $\mathbf{v},\mathbf{w}\in V$ and $\alpha\in{{\mathbb F}_{q}}$ we have $\Gamma_{\mathbf{v}}+\Gamma_{\mathbf{w}}=\Gamma_{\mathbf{v}+\mathbf{w}}$ and $\alpha\,\Gamma_{\mathbf{v}}=\Gamma_{\alpha\mathbf{v}}$, and hence $\mathcal{C}_{U,G}$ is an ${{\mathbb F}_{q}}$-vector space.

For any $\mathbf{v}\in V$, let $R_{\mathbf{v}}=\{ \lambda \in {\mathbb{F}_{q^n}}\colon \lambda \mathbf{v} \in U \}$. Clearly $\ker (\Gamma_{\mathbf{v}})=R_{\mathbf{v}}$ and, when $\mathbf{v}\ne\mathbf{0}$, $\dim_{{{\mathbb F}_{q}}}(R_{\mathbf{v}})=\dim_{{{\mathbb F}_{q}}}(U\cap\langle \mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})$. Then $\dim_{{{\mathbb F}_{q}}}(\ker(\Gamma_{\mathbf{v}}))\leq\iota$ and there exists $\mathbf{u}\in V^*$ such that $\dim_{{{\mathbb F}_{q}}}(\ker(\Gamma_{\mathbf{u}}))=\iota$, so that the minimum distance of $\mathcal{C}_{U,G}$ is $n-\iota$.

For any $\mathbf{v},\mathbf{w}\in V$, we have $\Gamma_{\mathbf{v}}=\Gamma_{\mathbf{w}}$ if and only if $\mathbf{v}=\mathbf{w}$. In fact, if $\Gamma_{\mathbf{v}}=\Gamma_{\mathbf{w}}$, then $G(\lambda(\mathbf{v}-\mathbf{w}))=\mathbf{0}$ for every $\lambda\in{\mathbb{F}_{q^n}}$, whence $\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}-\mathbf{w}\rangle_{{\mathbb{F}_{q^n}}})=n>\iota$ and hence $\mathbf{v}=\mathbf{w}$. Therefore, $\dim_{{{\mathbb F}_{q}}}(\mathcal{C}_{U,G})=rn$.

Finally, for any $\alpha\in{\mathbb{F}_{q^n}}$ and $\mathbf{v}\in V$ we have $\Gamma_{\mathbf{v}}\circ \omega_{\alpha}=\Gamma_{\alpha\mathbf{v}}$. Then $R(\mathcal{C}_{U,G})$ contains $\mathcal{F}_n$.

We now characterize the codes $\mathcal{C}_{U,G}$ which are MRD.

\[th:MRDiff\] Let $V=V(r,q^n)$ and $W=V(rn-k,q)$. Let $U=V(k,q)$ be an ${{\mathbb F}_{q}}$-subspace of $V$, $G:V\to W$ be an ${{\mathbb F}_{q}}$-linear map with $\ker(G)=U$, $\iota=\max\{\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}}) \colon \mathbf{v}\in V^*  \}$ with $\iota<n$, and $\mathcal{C}_{U,G}=\left\{ \Gamma_{\mathbf{v}} \colon \mathbf{v} \in V \right\}$.

Then $\mathcal{C}_{U,G}$ is an ${{\mathbb F}_{q}}$-linear MRD code if and only if $$(\iota+1)\mid rn\quad\textrm{and}\quad k=\frac{\iota rn}{\iota+1}\leq(r-1)n.$$ In this case,

-   the parameters of $\mathcal{C}_{U,G}$ are $\left(\,\frac{rn}{\iota+1}\,,\,n\,,\,q\,;\,n-\iota\,\right)$;

-   the right idealiser of $\mathcal{C}_{U,G}$ is $\mathcal{F}_n$;

-   the weight distribution of $\mathcal{C}_{U,G}$ is $$A_{n-s}={n \brack s}_q \sum_{j=0}^{\iota-s} (-1)^{j}{n-s \brack j}_q q^{\binom{j}{2}}\left(q^\frac{rn(\iota-s-j+1)}{\iota+1}-1\right),$$ for $s \in \{0,1,\ldots,\iota\}$.

If $k>(r-1)n$, then for every $\mathbf{v}\in V^*$ we have $\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})\geq1$ and hence $\dim_{{{\mathbb F}_{q}}}(\ker(\Gamma_{\mathbf{v}}))=\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})\geq1$, so that $\mathcal{C}_{U,G}$ has no elements of rank $n$. Thus, by Lemma \[lemma:weight\], $\mathcal{C}_{U,G}$ is not an MRD code.

Suppose $k\leq (r-1)n$. Then $rn-k\geq n$ and the Singleton-like bound of Theorem \[th:Singleton\] reads $$rn\leq(rn-k)(n-(n-\iota)+1).$$ Therefore, $\mathcal{C}_{U,G}$ is an MRD code if and only if $\iota+1$ divides $rn$ and $k=\frac{\iota rn}{\iota+1}$.

In this case, the parameters of $\mathcal{C}_{U,G}$ are provided by Theorem \[th:construction\] and the weight distribution of $\mathcal{C}_{U,G}$ follows from Theorem \[th:weightdistribution\]. Also, the right idealiser of $\mathcal{C}_{U,G}$ contains $\mathcal{F}_n$ by Theorem \[th:construction\], and hence is equal to $\mathcal{F}_n$ by Theorem \[th:propertiesideal\].

Different choices of the map $G$ yield equivalent codes, i.e. $\mathcal{C}_{U,G}$ is uniquely determined by $U$, up to equivalence.

Let $V=V(r,q^n)$ and $W=V(rn-k,q)$. Let $U=V(k,q)$ be an ${{\mathbb F}_{q}}$-subspace of $V$, $G:V\to W$ and $\overline{G}:V\to W$ be two ${{\mathbb F}_{q}}$-linear maps with $\ker(G)=\ker(\overline{G})=U$. Then the codes $\mathcal{C}_{U,G}$ and $\mathcal{C}_{U,\overline{G}}$ are equivalent.

Let $B_U \cup\{\mathbf{w}_1,\ldots,\mathbf{w}_{rn-k}\}$ be an ${{\mathbb F}_{q}}$-basis of $V$ such that $B_U$ is an ${{\mathbb F}_{q}}$-basis of $U$. Clearly, $G(\mathbf{w}_1),\ldots,G(\mathbf{w}_{rn-k})$ are ${{\mathbb F}_{q}}$-linearly independent, as well as $\overline{G}(\mathbf{w}_1),\ldots,\overline{G}(\mathbf{w}_{rn-k})$. Then there exists an invertible ${{\mathbb F}_{q}}$-linear map $L:V\to V$ such that $L(U)=U$ and $L(G({{\mathbf w}}_i))=\overline{G}({{\mathbf w}}_i)$ for every $i=1,\ldots,rn-k$, i.e. $L\circ G=\overline{G}$. Therefore, by choosing $R={\rm Id}_{{\mathbb{F}_{q^n}}}$ and $\sigma={\rm Id}_{{\rm Aut}({{\mathbb F}_{q}})}$, we have $$L\circ\mathcal{C}_{U,G}^{\sigma}\circ R = \left\{L\circ(G\circ\tau_{\mathbf{v}})\colon \mathbf{v} \in V\right\} =\mathcal{C}_{U,\overline{G}}.$$ The claim is proved.

We recall the following conjugacy property of Singer cycles of ${\rm GL}(n,q)$.

\[rem:singer\] The cyclic subgroups of $\mathrm{GL}(n,q)$ of order $q^n-1$ are called Singer cycles; it is well-known that any two Singer cycles $S_1=\langle g_1\rangle$ and $S_2=\langle g_2\rangle$ are conjugate in $\mathrm{GL}(n,q)$.

In fact, let $p_{g_1}(x)$ be the minimal polynomial of $g_1$ over $\mathbb{F}_q$, and $\gamma$ be a primitive element of ${\mathbb{F}_{q^n}}$ with minimal polynomial $p_{g_1}(x)$ over ${{\mathbb F}_{q}}$. The set $\overline{S}_1=S_1\cup\{\mathbf{0}\}$ is an ${{\mathbb F}_{q}}$-subalgebra of ${{\mathbb F}_{q}}^{n\times n}$, isomorphic to ${\mathbb{F}_{q^n}}$ by the ${{\mathbb F}_{q}}$-linear map $\varphi$ mapping $(1,g_1,\ldots,g_1^{n-1})$ to $(1,\gamma,\ldots,\gamma^{n-1})$. Also, $\overline{S}_1$ is a field of order $q^n$ and $\varphi$ is a field ${{\mathbb F}_{q}}$-isomorphism. The same holds for $\overline{S}_2=S_2\cup\{\mathbf{0}\}$, so that there exists a field ${{\mathbb F}_{q}}$-isomorphism $\psi:\overline{S}_1\to\overline{S}_2$. Therefore, there exists $\hat{\psi}\in\mathrm{GL}(n,q)$ which conjugates $S_1$ to $S_2$. See also [@Huppert pag. 187] and [@Hiss Section 1.2.5 and Example 1.12].

Also the converse of Theorem \[th:MRDiff\] holds, in the sense that any MRD code as in the claim of that theorem is equivalent to $\mathcal{C}_{U,G}$ for some $U$ as in the assumption of Theorem \[th:MRDiff\].

\[th:MRDconverse\] Let $\mathcal{C}$ be an ${{\mathbb F}_{q}}$-linear MRD code with parameters $(t,n,q;n-\iota)$ such that $t\geq n$ and $|R(\mathcal{C})|=q^n$, contained in ${\rm Hom}({\mathbb{F}_{q^n}},W)$ with $W=V(t,q)$. Let $r=\dim_{R(\mathcal{C})}(\mathcal{C})$. Then the following holds.

-   $\iota+1$ divides $rn$ and $t=\frac{rn}{\iota+1}$.

-   $\mathcal{C}$ is equivalent to an ${{\mathbb F}_{q}}$-linear MRD code $\mathcal{C}^\prime$ such that $R(\mathcal{C}^\prime)=\mathcal{F}_n$.

-   The set $$U=\{f\in\mathcal{C}^\prime\colon f(1)=0\}\subseteq\mathcal{C}^\prime$$ is a $\frac{\iota rn}{\iota+1}$-dimensional $\mathcal{F}_{n,q}$-subspace of $\mathcal{C}^\prime$, and satisfies [^2] $$\label{eq:iota} \max\left\{\dim_{\mathcal{F}_{n,q}}\left(U\cap\langle f\rangle_{\mathcal{F}_n}\right)\colon f\in\mathcal{C}^\prime\right\}=\iota.$$

-   $\mathcal{C}^\prime$ is equal to $\mathcal{C}_{U,G}$, where $G:\mathcal{C}^\prime\to W$, $f\mapsto f(1)$.

Since $|\mathcal{C}|=q^{rn}$ and $t\geq n$, the Singleton-like bound of Theorem \[th:Singleton\] reads $rn\leq t(n-(n-\iota)+1)$. As $\mathcal{C}$ is MRD, this implies that $\iota+1$ divides $t$, and $t=\frac{rn}{\iota+1}$.

Since $R(\mathcal{C})\setminus\{\mathbf{0}\}$ and $\mathcal{F}_n\setminus\{\omega_0\}$ are Singer cycles of $\mathrm{GL}(n,q)$, there exists by Remark \[rem:singer\] an invertible $\mathbb{F}_q$-linear map $H\colon \mathbb{F}_{q^n}\rightarrow\mathbb{F}_{q^n}$ such that $R(\mathcal{C})= H\circ\mathcal{F}_n\circ H^{-1}$. Thus, $\mathcal{C}^\prime = \mathcal{C}\circ H$.

Clearly, $U$ is an $\mathcal{F}_{n,q}$-subspace of $\mathcal{C}^\prime$. For every $i\in\{1,\ldots,\iota\}$, we determine the size of $U_i=\{ f \in U \colon \dim_{{{\mathbb F}}_q}(\ker f)=i \}$. Let $g \in \mathcal{C}'$ be such that $\dim_{{{\mathbb F}}_q}(\ker g)=i$. As $\dim_{{{\mathbb F}}_q}(\ker g)>0$, there exists $\alpha \in {{\mathbb F}}_{q^n}^*$ such that $g(\alpha)=0$, that is $g\circ \omega_\alpha (1)=0$. As $\operatorname{\mathcal{C}}'$ is a right vector space over $\mathcal{F}_n$, it follows that $g\circ \omega_\alpha \in \operatorname{\mathcal{C}}'$ and, in particular, $g\circ \omega_\alpha \in U_i$. This implies that $$\{ f \circ \omega_\alpha \colon f \in U_i,\,\,\alpha \in {{\mathbb F}}_{q^n}^* \}$$ coincides with the set of all the elements in $\operatorname{\mathcal{C}}'$ of rank $n-i$. Also, for any $f \in U_i$ and $\alpha\in{\mathbb{F}_{q^n}}$, we have $f \circ \omega_\alpha \in U_i$ if and only if $\alpha \in \ker f$. Thus, $$A_{n-i}= \frac{|U_i| (q^n-1)}{q^i-1}.$$ By Lemma \[lemma:complete weight\] $A_{n-\iota}\ne0$, and follows. Furthermore, $$|U|=1+ A_{n-1}\frac{q-1}{q^n-1}+\ldots+A_{n-\iota}\frac{q^\iota -1}{q-1},$$ i.e. $$(q^n-1)(|U|-1)= A_{n-1}(q-1)+\ldots+A_{n-\iota}(q^\iota -1).$$ By Theorem \[th:dualrelations\] applied to $\mathcal{C}'$ with $\nu=1$, we get $$A_{n-1}(q-1)+\ldots+A_{n-\iota}(q^\iota -1)=(q^n-1)(q^{\frac{\iota rn}{\iota+1}}-1),$$ whence $\dim_{\mathcal{F}_{n,q}}(U)=\frac{\iota rn}{\iota +1}$.

Finally, choosing $G:\mathcal{C}^\prime\to W$, $f\mapsto f(1)$ and recalling that $\tau_{f}\colon {{\mathbb F}}_{q^n}\rightarrow \operatorname{\mathcal{C}}'$, $\alpha \mapsto f\circ \omega_{\alpha}$ for any $f \in \operatorname{\mathcal{C}}^\prime$, we obtain $\operatorname{\mathcal{C}}'=\operatorname{\mathcal{C}}_{U,G}$.

Theorems \[th:MRDiff\] and \[th:MRDconverse\] provide a correspondence between:

-   ${{\mathbb F}_{q}}$-subspaces $U=V(\frac{\iota rn}{\iota+1},q)$ of $V=V(r,q^n)$ such that $\iota=\max\{\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})\colon \mathbf{v}\in V^*\}$; and

-   ${{\mathbb F}_{q}}$-linear MRD codes $\mathcal{C}$ with parameters $\left(\frac{rn}{\iota+1},n,q;n-\iota\right)$ and right idealiser isomorphic to ${\mathbb{F}_{q^n}}$.

When $W={{\mathbb F}}_{q^{{nr}/{(\iota+1)}}}$ and $R(\mathcal{C})=\mathcal{F}_n$, Theorem \[th:MRDconverse\] reads as follows.

Let $\iota,r,n$ be positive integers such that $\iota<n$, $\,\iota<r$ and $(\iota+1)\mid rn$. Let $f_1,\ldots,f_r\colon {\mathbb{F}_{q^n}}\rightarrow {{\mathbb F}}_{q^{{nr}/{(\iota+1)}}}$ be $\mathcal{F}_n$-linearly independent (on the right) ${{\mathbb F}_{q}}$-linear maps. Then the RM code $$\operatorname{\mathcal{C}}_{f_1,\ldots,f_r}=\{f_1\circ \omega_{\alpha_1}+\ldots+f_r\circ \omega_{\alpha_r} \colon \alpha_1,\ldots,\alpha_r \in {\mathbb{F}_{q^n}}\}$$ is an MRD code if and only if $$\dim_{{{\mathbb F}_{q}}} (\ker(f_1\circ \omega_{\alpha_1}+\ldots+f_r\circ \omega_{\alpha_r})) \leq \iota$$ for every $\alpha_1,\ldots,\alpha_r \in {\mathbb{F}_{q^n}}$. In this case, $\mathcal{C}_{f_1,\ldots,f_r}$ has parameters $\left(\frac{rn}{\iota+1},n,q;n-\iota\right)$ and $R(\operatorname{\mathcal{C}}_{f_1,\ldots,f_r})=\mathcal{F}_n$. Also, the $\mathcal{F}_{n,q}$-subspace $U_{f_1,\ldots,f_r}$ of $C_{f_1,\ldots,f_r}$ given by $$U_{f_1\ldots,f_r}=\{ f_1\circ \omega_{\alpha_1}+\ldots+f_r\circ \omega_{\alpha_r} \in \operatorname{\mathcal{C}}_{f_1,\ldots,f_r} \colon f_1(\alpha_1)+\ldots+f_r(\alpha_r)=0 \}$$ has dimension $\frac{\iota rn}{\iota +1}$, and $\iota=\max\{\dim_{{{\mathbb F}_{q}}}(U_{f_1,\ldots,f_r}\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})\colon \mathbf{v}\in \operatorname{\mathcal{C}}_{f_1,\ldots,f_r}^*\}$.

Let $\iota,n,r$ be positive integers such that $\iota<n$ and $(\iota+1)\mid r$. Define $t=r/(\iota+1)$. The code $$\mathcal{C}=\left\{x\in{{\mathbb F}}_{q^{nt}}\mapsto a_0 x+a_1 x^q+\ldots+a_{\iota}x^{q^\iota}\in{{\mathbb F}}_{q^{nt}}\;\colon\; a_0,\ldots,a_{\iota}\in{{\mathbb F}}_{q^{nt}}\right\}$$ is an MRD code with parameters $(nt,nt,q;nt-\iota)$, known as Gabidulin code; see Section \[sec:noGab\] below. Consider the code $$\mathcal{C}|_{{\mathbb{F}_{q^n}}}=\left\{f|_{{\mathbb{F}_{q^n}}}:{\mathbb{F}_{q^n}}\to{{\mathbb F}}_{q^{nt}}\colon f\in\mathcal{C}\right\}.$$ By Theorem \[th:punct\], $\mathcal{C}|_{{\mathbb{F}_{q^n}}}$ is an MRD code with parameters $(nt,n,q;n-\iota)$. Also, $R(\mathcal{C}|_{{\mathbb{F}_{q^n}}})=\mathcal{F}_n$ and an $\mathcal{F}_n$-basis of $\mathcal{C}|_{{\mathbb{F}_{q^n}}}$ (seen as a right vector space) is $$\left\{ f_{j,i} \colon x\in{\mathbb{F}_{q^n}}\mapsto \xi^{i}x^{q^j}\in{{\mathbb F}}_{q^{nt}}\;\mid\; 0\leq i\leq t-1,\,0\leq j\leq \iota \right\},$$ where $\{1,\xi,\ldots,\xi^{t-1}\}$ is an ${\mathbb{F}_{q^n}}$-basis of ${{\mathbb F}}_{q^{nt}}$. Moreover, the set of the elements $f\in\mathcal{C}|_{{\mathbb{F}_{q^n}}}$ vanishing at $1$ is equal to $$U=\left\{x\in{\mathbb{F}_{q^n}}\mapsto -(a_1+\ldots+a_{\iota}) x+a_1 x^q+\ldots+a_{\iota}x^{q^\iota}\in{{\mathbb F}}_{q^{nt}}\;\colon\; a_1,\ldots,a_{\iota}\in{{\mathbb F}}_{q^{nt}} \right\},$$ and $\iota=\max\left\{\dim_{\mathcal{F}_{n,q}}\left(U\cap\langle f\rangle_{\mathcal{F}_n}\right)\colon f\in\mathcal{C}|_{{\mathbb{F}_{q^n}}}^{\,*}\right\}$. Let $$B=\left(f_{j,i}\,\colon\, j=0,\ldots,\iota,\;i=0,\ldots,t-1\right).$$ The coordinates of a vector in $U$ with respect to $B$ are $$\left( -\sum_{k=1}^{\iota}a_{k,0}\;,\ldots,-\sum_{k=1}^{\iota}a_{k,0}\;,\;a_{1,0}^{q^{n-1}},\ldots,a_{1,t-1}^{q^{n-1}}\;,\;\ldots\ldots,\;a_{\iota,0}^{q^{n-\iota}},\ldots,a_{\iota,t-1}^{q^{n-\iota}} \right),$$ where $a_{k,i}\in {\mathbb{F}_{q^n}}$ are such that $a_k=\sum_{i=0}^{t-1}a_{k,i}\xi^{i}$. Denote by $\overline{U}$ the set of the coordinates of the vectors in $U$. Let $\sigma^{\prime}:\mathbb{F}_{q^n}^{t(\iota+1)}\times \mathbb{F}_{q^n}^{t(\iota+1)}\to\mathbb{F}_q$, $(\mathbf{u},\mathbf{v})\mapsto\mathrm{Tr}_{q^n/q}(\langle\mathbf{u},\mathbf{v}\rangle)$, where $\langle\cdot,\cdot\rangle$ is the standard inner product. Then the vectors of $\overline{U}^{\perp^\prime}$ are $$(y_0,\ldots,y_{t-1},y_0^{q^{n-1}},\ldots,y_{t-1}^{q^{n-1}},\ldots \ldots, y_0^{q^{n-\iota}},\ldots,y_{t-1}^{q^{n-\iota}}),$$ where $y_0,\ldots,y_{t-1}\in\mathbb{F}_{q^n}$. Note that $\overline{U}^{\perp^\prime}$ is the direct sum of $t$ copies of $$\{ (z,z^{q},\ldots,z^{q^\iota})\colon z\in\mathbb{F}_{q^n} \}$$ which is a $\iota$-scattered ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}^{\iota+1}$.

Therefore, when $\iota+1$ divides $r$, the restriction to ${\mathbb{F}_{q^n}}$ of a Gabidulin code is associated with the direct sum of $t$ copies of a $\iota$-scattered ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}^{\iota+1}$ (which is a $\iota$-scattered ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}^r$); see Section \[sec:twocharact\].

Previously known connections {#sec:uni}
============================

In this section, we show that the connection between ${{\mathbb F}_{q}}$-vector spaces and ${{\mathbb F}_{q}}$-linear MRD codes established in Section \[sec:subMRD\] generalizes those presented in [@Sheekey; @ShVdV; @Lunardon2017; @CSMPZ2016].

Sheekey’s connection {#sec:sheekey}
--------------------

The first connection was pointed out by Sheekey in its seminal paper [@Sheekey]. Let $U$ be an ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}\times{\mathbb{F}_{q^n}}$, so that $$U=U_{f_1,f_2}=\{(f_1(x),f_2(x))\colon x\in{\mathbb{F}_{q^n}}\}$$ for some $f_1(x),f_2(x)$ in $\mathcal{L}_{n,q}$. Consider the ${{\mathbb F}_{q}}$-linear RM code $$\mathcal{S}_{f_1,f_2}=\{a_1 f_1(x)+a_2 f_2(x)\colon a_1,a_2\in{\mathbb{F}_{q^n}}\}\subset\mathcal{L}_{n,q},$$ whose left idealiser is isomorphic to ${\mathbb{F}_{q^n}}$. Then $U_{f_1,f_2}$ is a maximum scattered ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}\times{\mathbb{F}_{q^n}}$ if and only if $\mathcal{S}_{f_1,f_2}$ is an MRD code with parameters $(n,n,q;n-1)$; see [@Sheekey Section 5].

A generalization to maximum $(r-1)$-scattered ${{\mathbb F}_{q}}$-subspaces of ${\mathbb{F}_{q^n}}^r$ {#sec:r-1}
-----------------------------------------------------------------------------------------------------

Sheekey’s connection was extended by Sheekey and Van de Voorde in [@ShVdV] as follows; see also [@Lunardon2017]. Let $U$ be an ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}^r$, so that $$U=U_{f_1,\ldots,f_r}=\{(f_1(x),\ldots,f_r(x))\colon x\in{\mathbb{F}_{q^n}}\}$$ for some $f_1(x),\ldots,f_r(x)\in\mathcal{L}_{n,q}$, and consider the ${{\mathbb F}_{q}}$-linear RM code $$\label{eq:Cf1fr} \mathcal{S}_{f_1,\ldots,f_r}=\{a_1 f_1(x)+\cdots+a_r f_r(x)\colon a_1,\ldots,a_r\in{\mathbb{F}_{q^n}}\},$$ whose left idealiser is isomorphic to ${\mathbb{F}_{q^n}}$. Then $U_{f_1,\ldots,f_r}$ is a maximum $(r-1)$-scattered ${{\mathbb F}_{q}}$-subspace of ${\mathbb{F}_{q^n}}^r$ if and only if $\mathcal{S}_{f_1,\ldots,f_r}$ is an MRD code with parameters $(n,n,q;n-r+1)$; see [@ShVdV Corollary 5.7]. Clearly, when $r=2$ this connection coincides with the one of Section \[sec:sheekey\].

A generalization to maximum scattered ${{\mathbb F}_{q}}$-subspaces {#sec:JACO}
-------------------------------------------------------------------

Sheekey’s connection was extended by Csajbók, Marino, Polverino and the last author in [@CSMPZ2016] by considering maximum scattered ${{\mathbb F}_{q}}$-subspaces of $V=V(r,q^n)$ for any $r\geq2$ with $rn$ even; see [@CSMPZ2016 Theorem 3.2].

Let $U=V(\frac{rn}{2},q)$ be an ${{\mathbb F}_{q}}$-subspace of $V$, $W=V(\frac{rn}{2},q)$, $G:V\to W$ be an ${{\mathbb F}_{q}}$-linear map with $\ker(G)=U$, and $\iota=\max\{\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})\colon \mathbf{v}\in V^*\}$ with $\iota<n$. Then $\mathcal{C}_{U,G}=\{\Gamma_{\mathbf{v}}\colon \mathbf{v}\in V\}$ is an ${{\mathbb F}_{q}}$-linear RM code of dimension $rn$ with parameters $(\frac{rn}{2},n,q;n-\iota)$. Moreover, $U$ is a maximum scattered ${{\mathbb F}_{q}}$-subspace of $V$ if and only if $\mathcal{C}_{U,G}$ is an MRD code. In this case, the right idealiser of $\mathcal{C}_{U,G}$ is isomorphic to ${\mathbb{F}_{q^n}}$.

Conversely, in [@PZ] the authors prove that any ${{\mathbb F}_{q}}$-linear MRD code with parameters $(\frac{rn}{2},n,q;n-1)$ and right idealiser isomorphic to ${\mathbb{F}_{q^n}}$ is equivalent to an MRD code $\mathcal{C}^\prime$ containing a maximum scattered ${{\mathbb F}_{q}}$-subspace $U$ such that $\mathcal{C}^\prime=\mathcal{C}_{U,G}$ with $G:\mathcal{C}^\prime\to W$, $f\mapsto f(1)$; see [@PZ Theorem 4.7].

This family contains the adjoint codes of the codes $\mathcal{S}_{f_1,f_2}$ presented in Section \[sec:sheekey\]; see [@CSMPZ2016 Example 3.5].

A unified connection
--------------------

When $\iota=1$ and $U$ is a maximum scattered ${{\mathbb F}_{q}}$-subspace of $V=V(r,q^n)$, the connection established in Theorems \[th:construction\] and \[th:MRDiff\] coincides with the one of Section \[sec:JACO\], and hence generalizes the one of Section \[sec:sheekey\]. Also, Theorem \[th:MRDconverse\] extends the result of [@PZ].

When $\iota=r-1$ and $U$ is a maximum $(r-1)$-scattered ${{\mathbb F}_{q}}$-subspace of $V=V(r,q^n)$, our connection contains the adjoint codes of the MRD codes provided in Section \[sec:r-1\]. Indeed, let $\mathcal{C}$ be as in Equation with parameters $(n,n,q;n-r+1)$ and left idealiser isomorphic to ${\mathbb{F}_{q^n}}$. By Theorem \[th:propertiesideal\], the adjoint code $\mathcal{C}^\top$ is MRD with parameters $(n,n,q;n-r+1)$ and right idealiser isomorphic to ${\mathbb{F}_{q^n}}$. Thus, by Theorem \[th:MRDconverse\], $\mathcal{C}^\top$ is equivalent to $\mathcal{C}_{U,G}$ for some $U$ and $G$.

Two characterizations of $h$-scattered subspaces {#sec:twocharact}
================================================

The ${{\mathbb F}_{q}}$-subspaces $U$ of $V=V(r,q^n)$ defining an MRD code with parameters $(\frac{rn}{h+1},n,q;n-h)$ and right idealiser isomorphic to ${\mathbb{F}_{q^n}}$ are exactly those of dimension $\frac{hrn}{h+1}$ such that $h=\max\{\dim_{{{\mathbb F}_{q}}}(U\cap\langle\mathbf{v}\rangle_{{\mathbb{F}_{q^n}}})\colon\mathbf{v}\in V^*\}$. Examples of such $U$’s are provided by the ordinary duals of $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspaces of $V$, for which several constructions are known; see [@CsMPZ; @NPZZ]. We prove that, whenever $n\geq h+3$, such $U$’s are exactly the ordinary duals of $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspaces of $V$. To this aim we provide two characterizations of these objects, namely Corollaries \[cor:caratterizzazione\] and \[cor:caratterizzazione2\], by means of ordinary and Delsarte dualities.

\[th:condhyper\] Let $r,n,h,k$ be positive integers such that $n\geq h+3$ and $k>r$. Let $U$ be a $k$-dimensional ${{\mathbb F}_{q}}$-subspace of $V=V(r,q^n)$ such that $$\label{eq:intersection} \dim_{{{\mathbb F}_{q}}}(H\cap U)\leq k-n+h$$ for every $(r-1)$-dimensional ${\mathbb{F}_{q^n}}$-subspace $H$ of $V$. Let $\Gamma,\operatorname{\mathbb{V}},\perp,\perp_D$ be as in Section \[sec:Delsarteduality\]. Then $U^{\perp_D}$ is an $(n-h-2)$-scattered subspace of $\operatorname{\mathbb{V}}/\Gamma^\perp$.

As noted in Section \[sec:Delsarteduality\], there exist $\operatorname{\mathbb{V}}=V(k,q^n)$, an ${\mathbb{F}_{q^n}}$-subspace $\Gamma=V(k-r,q^n)$ of $\operatorname{\mathbb{V}}$, and an ${{\mathbb F}_{q}}$-subspace $W=V(k,q)$ of $\operatorname{\mathbb{V}}$ such that $\operatorname{\mathbb{V}}=V\oplus\Gamma$, $\langle W\rangle_{{\mathbb{F}_{q^n}}}=\operatorname{\mathbb{V}}$, $W\cap\Gamma=\{\mathbf{0}\}$, and $U=\langle W,\Gamma\rangle_{{{\mathbb F}_{q}}}\cap V$.

Let $\perp^\prime$ and $\perp$ be the orthogonal complement maps which act respectively on the ${{\mathbb F}_{q}}$-subspaces of $W$ and on the ${\mathbb{F}_{q^n}}$-subspaces of $\operatorname{\mathbb{V}}$, which are defined by non-degenerate reflexive sesquilinear forms $\beta^\prime :W\times W\to{{\mathbb F}_{q}}$ and $\beta:\operatorname{\mathbb{V}}\times\operatorname{\mathbb{V}}\to{\mathbb{F}_{q^n}}$ respectively, such that $\beta$ coincides with $\beta^\prime$ on $W\times W$.

Since $n\geq h+3$, $k>r$ and holds, the Delsarte duality can be applied to $U$. Then $U^{\perp_D}=W+\Gamma^{\perp}$ is a $k$-dimensional ${{\mathbb F}_{q}}$-subspace of $\operatorname{\mathbb{V}}/\Gamma^{\perp}$.

Suppose that there exists an $(n-h-2)$-dimensional subspace $M$ of $\operatorname{\mathbb{V}}/\Gamma^\perp$ such that $\dim_{{{\mathbb F}_{q}}}(M\cap U^{\perp_D})\geq n-h-1$. Write $M=N+\Gamma^\perp$, where $N$ is an $(n-h-2+r)$-dimensional subspace of $\operatorname{\mathbb{V}}$ satisfying $\Gamma^\perp \subseteq N$, so that $$\dim_{{{\mathbb F}_{q}}}(N\cap W)=\dim_{{{\mathbb F}_{q}}}(M\cap U^{\perp_D})\geq n-h-1.$$ Let $S$ be an $(n-h-1)$-dimensional ${{\mathbb F}_{q}}$-subspace of $N\cap W$. As $S\subseteq W$, we have $\dim_{{\mathbb{F}_{q^n}}}(S^*)=\dim_{{{\mathbb F}_{q}}}(S)$; see [@Lun99 Lemma 1]. Since $N$ contains both $S$ and $\Gamma^\perp$, we have $N^\perp\subseteq (S^*)^\perp \cap \Gamma$, whence $$\dim_{{\mathbb{F}_{q^n}}}((S^*)^\perp \cap \Gamma)\geq \dim_{{\mathbb{F}_{q^n}}}(N^\perp) = k-(n-h-2+r).$$ This implies that $\langle(S^*)^\perp,\Gamma\rangle_{{\mathbb{F}_{q^n}}}$ is contained in an ${\mathbb{F}_{q^n}}$-subspace $T$ of $\operatorname{\mathbb{V}}$ of dimension $k-1$.

Let $\hat{T}=T\cap V$. As $T$ contains $\Gamma$, we have $\dim_{{\mathbb{F}_{q^n}}}(\hat{T})=r-1$. Using $U=\langle W,\Gamma\rangle_{{{\mathbb F}_{q}}}\cap V$ and $T\cap\langle W,\Gamma\rangle_{{{\mathbb F}_{q}}}=\langle\Gamma,T\cap W\rangle_{{{\mathbb F}_{q}}}$, we obtain $$\dim_{{{\mathbb F}_{q}}}(\hat{T}\cap U)=\dim_{{{\mathbb F}_{q}}}(T\cap W).$$ As $S^{\perp^\prime}= W\cap (S^*)^\perp\subseteq W\cap T$ and $\dim_{{{\mathbb F}_{q}}}(S^{\perp^{\prime}})=k-(n-h-1)$, we obtain $$\dim_{{{\mathbb F}_{q}}}(\hat{T}\cap U)\geq k-n+h+1,$$ a contradiction to . Therefore $U^{\perp_D}$ is an $(n-h-2)$-scattered ${{\mathbb F}_{q}}$-subspace of $\operatorname{\mathbb{V}}/\Gamma^\perp$.

Note that Theorem \[th:condhyper\] can also be obtained as a consequence of [@BCsMT Theorem 3.5]. By Theorem \[th:condhyper\], the following characterization is obtained.

\[cor:caratterizzazione\] Let $r,n,h$ be positive integers such that $h+1$ divides $rn$ and $n\geq h+3$. Let $U$ be an $\frac{rn}{h+1}$-dimensional ${{\mathbb F}_{q}}$-subspace of $V=V(r,q^n)$. Then $U$ is an $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspace of $V$ if and only if $$\label{eq:intermax} \dim_{{{\mathbb F}_{q}}}(H\cap U)\leq\frac{rn}{h+1}-n+h$$ for every $(r-1)$-dimensional ${\mathbb{F}_{q^n}}$-subspace $H$ of $V$.

Assume that holds. By Theorem \[th:condhyper\], $U^{\perp_D}$ is a $\frac{rn}{h+1}$-dimensional $(n-h-2)$-scattered ${{\mathbb F}_{q}}$-subspace in $\operatorname{\mathbb{V}}/\Gamma^\perp$. By Proposition \[prop:property\], $U$ is a $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspace of $V$. The converse follows from Theorem \[th:inter\].

\[rem:nonallargarti\] If $n>2$, $k<\frac{rn}{h+1}$ and $h=1$, then there exist $k$-dimensional $1$-scattered ${{\mathbb F}_{q}}$-subspaces of $V=V(r,q^n)$ such that does not hold. Therefore, Corollary \[cor:caratterizzazione\] cannot be extended to all $h$-scattered subspaces which are not $\frac{rn}{h+1}$-dimensional $h$-scattered subspaces.

Indeed, let $U^\prime$ be a scattered $k^\prime$-dimensional ${{\mathbb F}_{q}}$-subspace such that $H=\langle U^\prime\rangle_{{\mathbb{F}_{q^n}}}$ is a $(r-1)$-dimensional ${\mathbb{F}_{q^n}}$-subspace of $V$, and $\mathbf{v}\in V\setminus H$. Then $U=U^\prime\oplus\langle\mathbf{v}\rangle_{{{\mathbb F}_{q}}}$ is a $1$-scattered ${{\mathbb F}_{q}}$-subspace of $V$ of dimension $k=k^\prime+1$ such that $\dim_{{{\mathbb F}_{q}}}(U\cap H)=k-1>k-n+1$, as $n>2$.

By using Corollary \[cor:caratterizzazione\], a further characterization of $\frac{rn}{h+1}$-dimensional $h$-scattered subspaces is proved.

\[cor:caratterizzazione2\] Let $r,n,h$ be positive integers such that $h+1$ divides $rn$ and $n\geq h+3$. Let $U$ be an $\frac{rn}{h+1}$-dimensional ${{\mathbb F}_{q}}$-subspace of $V=V(r,q^n)$. Then $U$ is an $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspace of $V$ if and only if $U^{\perp_O}$ satisfies $$\label{eq:intermaxpoint} \dim_{{{\mathbb F}_{q}}}(\langle \mathbf{v}\rangle_{{{\mathbb F}}_{q^n}}\cap U^{\perp_O})\leq h$$ for every $\mathbf{v}\in V\setminus\{\mathbf{0}\}$.

If $U$ is an $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}}_q$-subspace of $V$, then the assertion follows from Theorem \[th:inter\] and Equation . Conversely, $\dim_{{{\mathbb F}_{q}}}(U)=\frac{rn}{h+1}$ implies $\dim_{{{\mathbb F}}_q}(U^{\perp_O})=\frac{hrn}{h+1}$. Together with the assumption and Equation , this yields $$\dim_{{{\mathbb F}_{q}}}(H\cap U)\leq \frac{rn}{h+1}-n+h$$ for every $(r-1)$-dimensional ${{\mathbb F}}_{q^n}$-subspace $H$ of $V$. The claim now follows from Corollary \[cor:caratterizzazione\].

Theorems \[th:MRDiff\] and \[th:MRDconverse\], together with Corollary \[cor:caratterizzazione2\], provide a correspondence between the following objects, under the assumption $n\geq h+3$:

-   $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspaces of $V(r,q^n)$; and

-   ${{\mathbb F}_{q}}$-linear MRD codes with parameters $\left(\frac{rn}{h+1},n,q;n-h\right)$ and right idealiser isomorphic to ${\mathbb{F}_{q^n}}$.

MRD codes inequivalent to generalized (twisted) Gabidulin codes {#sec:noGab}
===============================================================

In this section we prove that the family of RM codes described in Section \[sec:subMRD\] contains MRD codes which are not equivalent to punctured generalized Gabidulin codes nor to punctured generalized twisted Gabidulin codes.

Let $N,k,s$ be positive integers with $k<N$ and $\gcd(s,N)=1$. The *generalized Gabidulin code* $\mathcal{G}_{k,s}$ is defined as $$\mathcal{G}_{k,s}=\left\{ x\in{{\mathbb F}}_{q^N}\mapsto a_0 x+ a_1 x^{q^s}+\ldots+a_{k-1}x^{q^{s(k-1)}}\in{{\mathbb F}}_{q^N}\,\colon\, a_0,\ldots,a_{k-1}\in{{\mathbb F}}_{q^N} \right\}$$ and is an ${{\mathbb F}_{q}}$-linear MRD code with parameters $(N,N,q;N-k+1)$. The codes $\mathcal{G}_{k,s}$ were first introduced in [@Delsarte; @Gabidulin] for $s=1$ and generalized in [@kshevetskiy_new_2005].

Let $0\leq c<N$ and $\eta\in{{\mathbb F}}_{q^N}$ be such that $\eta^{(q^N-1)/(q-1)}\ne(-1)^{Nk}$. The *generalized twisted Gabidulin code* $\mathcal{H}_{k,s}(\eta,c)$ is defined as $$\mathcal{H}_{k,s}(\eta,c)=\left\{ x\in{{\mathbb F}}_{q^N}\mapsto a_0 x+ a_1 x^{q^s}+\ldots+a_{k-1}x^{q^{s(k-1)}}+a_0^{q^c}\eta x^{q^{sk}}\in{{\mathbb F}}_{q^N}\,\colon\, a_i\in{{\mathbb F}}_{q^N} \right\}$$ and is an ${{\mathbb F}_{q}}$-linear MRD code with parameters $(N,N,q; N-k+1)$. The codes $\mathcal{H}_{k,s}(\eta,c)$ were first introduced in [@Sheekey] and investigated in [@LTZ].

As a consequence of [@TZ Theorem 3.8], the left idealisers of punctured generalized (twisted) Gabidulin codes satisfy the following property.

\[lemma:TZ\] Let $g:{{\mathbb F}}_{q^N}\to{{\mathbb F}}_{q^M}$ be an ${{\mathbb F}_{q}}$-linear map of rank $M\leq N$, and consider the punctured code $\mathcal{C}$, where either $\mathcal{C}=g\circ\mathcal{G}_{k,s}$ or $\mathcal{C}=g\circ\mathcal{H}_{k,s}(\eta,c)$. If $M>k+1$ and $(M,k)\ne(4,2)$, then $|L(\mathcal{C})|=q^\ell$ where $\ell$ divides $N$.

In Theorem \[th:new\] we investigate the equivalence issue between the codes $\mathcal{C}$ as in having parameters $(M,N,q;d)$ with $M\geq N$, and punctured generalized (twisted) Gabidulin codes. As the punctured $(M,N,q;d)$-codes $\mathcal{D}$ arising from Lemma \[lemma:TZ\] satisfy $M\leq N$, we need to consider the adjoint code $\mathcal{D}^{\top}$ of $\mathcal{D}$, having parameters $(N,M,q;d)$. In this sense, whenever $\mathcal{C}$ and $\mathcal{D}^\top$ are not equivalent, we will say that $\mathcal{C}$ is not equivalent to a punctured generalized (twisted) Gabidulin code.

We show in Theorem \[th:new\] that the condition $(h+1)\nmid r$ is sufficient for the MRD codes of Section \[sec:subMRD\] to be inequivalent to punctured generalized (twisted) Gabidulin codes. Afterwards, we provide examples.

\[th:new\] Let $r,n,h$ be positive integers such that $(h+1)$ divides $rn$, $n\geq h+3$, and $(n,h)\ne(4,1)$. Let $\mathcal{C}=\mathcal{C}_{U,G}$ be the MRD code with parameters $\left(\frac{rn}{h+1},n,q;n-h\right)$ defined in Theorem \[th:MRDiff\]. If $(h+1)$ does not divide $r$, then $\mathcal{C}$ is not equivalent to any punctured generalized Gabidulin code nor to any punctured generalized twisted Gabidulin code.

Suppose that $\mathcal{C}$ is equivalent to $\mathcal{D}$, where $\mathcal{D}$ is either $(g\circ \mathcal{G}_{k,s})^\top$ or $(g\circ\mathcal{H}_{k,s}(\eta,c))^\top$. Then $k=h+1$, $N=\frac{rn}{h+1}$ and $M=n$. Since $n>h+2$ and $(n,h)\ne(4,1)$, we can apply Lemma \[lemma:TZ\] and Theorem \[th:propertiesideal\] to get $|R(\mathcal{D})|=q^\ell$, where $\ell$ divides $\frac{rn}{h+1}$. As $\mathcal{C}$ and $\mathcal{D}$ are equivalent, by Theorem \[th:propertiesideal\] we have $|R(\mathcal{C})|=|R(\mathcal{D})|=q^\ell$. Then $n=\ell$ and hence $n\mid\frac{rn}{h+1}$, a contradiction to $(h+1)\nmid r$.

Let $n\geq 6$ be even and $r^\prime\geq 3$ be odd. By [@CsMPZ Theorem 3.6], there exist $\frac{rn}{2}$-dimensional $(n-3)$-scattered ${{\mathbb F}_{q}}$-subspaces $U^\prime$ of $V=V\left(\frac{r^\prime(n-2)}2,q^n \right)$. Let $h=n-3$ and $r=\frac{r^\prime(n-2)}2$, and consider $U=U^{\prime\perp_O} \subseteq V$. Note that $(h+1)\nmid r$. Choose $G$ as in Theorem \[th:construction\]. By Theorems \[th:MRDiff\] and \[th:new\], the MRD code $\operatorname{\mathcal{C}}_{U,G}$ with parameters $\left(\frac{r^\prime n}{2},n,q;3\right)$ is not equivalent to any punctured generalized Gabidulin code nor to any punctured generalized twisted Gabidulin code.

Let $n\geq6$ be even and $r\geq3$ be odd. Examples 3.11, 3.12 and 3.13 in [@CSMPZ2016] provide MRD codes with parameters $\left(\frac{rn}{2},n,q;n-1\right)$ which are not equivalent to any punctured generalized Gabidulin code nor to any punctured generalized twisted Gabidulin code.

$h$-scattered linear sets: intersection with hyperplanes and codes with $h+1$ weights {#sec:h+1weights}
=====================================================================================

Let $V=V(r,q^n)$. A point set $L$ of $\Omega={\mathrm{PG}}(V,{{\mathbb F}}_{q^n})\allowbreak={\mathrm{PG}}(r-1,q^n)$ is an *${{\mathbb F}}_q$-linear set* of $\Omega$ of rank $k$ if it is defined by the non-zero vectors of a $k$-dimensional ${{\mathbb F}}_q$-subspace $U$ of $V$, i.e. $$L=L_U:=\{{\langle}{\bf u} {\rangle}_{\mathbb{F}_{q^n}} \colon {\bf u}\in U^* \}\}.$$ We denote the rank of $L_U$ by $\mathrm{rk}(L_U)$. Let $\mathcal{S}={\mathrm{PG}}(S,{{\mathbb F}}_{q^n})$ be a subspace of $\Omega$ and $L_U$ be an ${{\mathbb F}}_q$-linear set of $\Omega$. Then $\mathcal{S} \cap L_U=L_{S\cap U}$. If $\dim_{{{\mathbb F}}_q} (S\cap U)=i$, i.e. if $\mathcal{S} \cap L_U=L_{S\cap U}$ has rank $i$, we say that $\mathcal{S}$ has *weight* $i$ in $L_U$, and we write $w_{L_U}(\mathcal{S})=i$. Note that $0 \leq w_{L_U}(\mathcal{S}) \leq \min\{{\rm rk}(L_U),n(\dim(\mathcal{S})+1)\}$. In particular, a point $P$ belongs to an ${{\mathbb F}}_q$-linear set $L_U$ if and only if $w_{L_U}(P)\geq 1$. If $U$ is a (maximum) scattered ${{\mathbb F}}_q$-subspace of $V$, then we say that $L_U$ is (maximum) scattered. In this case, $$|L_U| = \theta_{k-1}=\frac{q^k-1}{q-1},$$ where $k$ is the rank of $L_U$; equivalently, all of its points have weight one.

If $U$ is a (maximum) $h$-scattered ${{\mathbb F}}_q$-subspace of $V$, $L_U$ is said to be a (maximum) $h$-scattered ${{\mathbb F}}_q$-linear set in $\Omega={\mathrm{PG}}(V,{{\mathbb F}}_{q^n})$. Therefore, an ${{\mathbb F}}_q$-linear set $L_U$ of $\Omega$ is $h$-scattered if

-   $\langle L_U \rangle= \Omega$;

-   for every $(h-1)$-subspace $\mathcal{S}$ of $\Omega$, we have $$w_{L_{U}}(\mathcal{S}) \leq h.$$

When $h=r-1$ and $\dim_{{{\mathbb F}}_q}(U)=n$, we obtain the scattered linear sets with respect to the hyperplanes introduced in [@Lunardon2017] and in [@ShVdV].

By Theorem \[th:inter\], if $L_U$ is a $h$-scattered ${{\mathbb F}}_q$-linear set of rank $\frac{rn}{h+1}$ in $\Omega$, then for every hyperplane $\mathcal{H}$ of $\Omega$ we have $$\frac{rn}{h+1}-n\leq w_{L_U}(\mathcal{H})\leq \frac{rn}{h+1}-n+h.$$ The following question arises:

for any $j \in \{\frac{rn}{h+1}-n,\ldots,\frac{rn}{h+1}-n+h\}$, how many hyperplanes of $\Omega$ have weight $j$ in $L_U$?

The answer is known for $h=1$, $h=2$ and $h=r-1$; see [@BL2000; @NZ; @ShVdV]. Theorem \[th:intersectionhyper\] gives a complete answer for any admissible values of $h$, $r$ and $n$.

\[th:intersectionhyper\] Let $L_U$ be a $h$-scattered ${{\mathbb F}}_q$-linear set of rank $\frac{rn}{h+1}$ in $\Omega={\mathrm{PG}}(r-1,q^n)$. For every $i\in\left\{0,\ldots,h\right\}$, the number of hyperplanes of weight $\frac{rn}{h+1}-n+i$ in $L_U$ is $$\label{eq:ti} t_i=\frac{1}{q^n-1}{n \brack i}_q \sum_{j=0}^{h-i} (-1)^{j}{n-i \brack j}_q q^{\binom{j}{2}}\left(q^\frac{rn(h-i-j+1)}{h+1}-1\right).$$ In particular, $t_i>0$ for every $i\in\left\{0,\ldots,h\right\}$.

Let $\sigma,\sigma^\prime,\perp,\perp^\prime$ be defined as in Section \[sec:classicalduality\], and $\mathcal{H}={\mathrm{PG}}(H,{{\mathbb F}}_{q^n})$ be a hyperplane of $\Omega$ with weight $\frac{rn}{h+1}-n+i$ in $L_U$. By Equation , $$\dim_{{{\mathbb F}_{q}}}(U^{\perp^\prime}\cap H^\perp)=\dim_{{{\mathbb F}_{q}}}(U\cap H) +rn-\frac{rn}{h+1}-(r-1)n = i\leq h.$$ Thus, the ${{\mathbb F}}_q$-linear set $L_{U^{\perp^\prime}}$ of $\Omega$ has rank $\frac{hrn}{h+1}$, the weight in $L_{U^{\perp^\prime}}$ of a point of $\Omega$ is at most $h$, and the number of points of $\Omega$ with weight $i$ in $L_{U^{\perp^\prime}}$ equals the number $t_i$ of hyperplanes with weight $\frac{rn}{h+1}-n+i$ in $L_U$, for every $i\in \{0,\ldots,h\}$. Let $W=V(\frac{rn}{h+1},q)$ and $G\colon V \rightarrow W$ be an ${{\mathbb F}}_q$-linear map with $\ker(G)=U$. By Theorem \[th:MRDiff\], the code $\mathcal{C}_{U^{\perp^\prime},G}=\{\Gamma_{\mathbf{v}} \colon \mathbf{v}\in V\}$ is an MRD code.

Note that, for every $i \in \{0,\ldots,h\}$, $t_i$ is equal to the number of maps in $\operatorname{\mathcal{C}}_{U^{\perp^\prime},G}$ having rank $n-i$, divided by $q^n-1$. In fact, if $P=\langle \mathbf{v}\rangle_{{{\mathbb F}}_{q^n}}$ is a point of weight $i$ in $L_{U^{\perp^\prime}}$, then $\Gamma_{\lambda\mathbf{v}}$ has rank $n-i$ for every $\lambda\in{{\mathbb F}}_{q^n}^*$; conversely, if $\mathbf{v}\in V^*$ is such that $\Gamma_{\mathbf{v}}$ has rank $n-i$, then $\langle\mathbf{v}\rangle_{{{\mathbb F}}_{q^n}}$ has weight $i$ in $L_{U^{\perp^\prime}}$.

Thus, $t_i=A_{n-i}/(q^n-1)$. By Theorem \[th:MRDiff\], Equation follows. As $\mathcal{C}_{U^{\perp^\prime},G}$ is an MRD code, $t_i>0$ by Lemma \[lemma:complete weight\].

Under the assumptions of Theorem \[th:intersectionhyper\], the property of being scattered determines completely the intersection numbers w.r.t. the hyperplanes.

\[cor:intersec\] Let $L_U$ be a $h$-scattered ${{\mathbb F}_{q}}$-linear set of rank $\frac{rn}{h+1}$ in $\Omega={\mathrm{PG}}(r-1,q^n)$. For every hyperplane $\mathcal{H}$ of $\Omega$, we have $$|\mathcal{H}\cap L_U| \in \left\{ \theta_{\frac{rn}{h+1}-n-1},\ldots,\theta_{\frac{rn}{h+1}-n+h-1} \right\}.$$ For every $i\in\{0,\ldots,h\}$, the number of hyperplanes $\mathcal{H}$ of $\Omega$ satisfying $|\mathcal{H}\cap L_U|=\theta_{\frac{rn}{h+1}-n+i-1}$ is $t_i$, as in Equation .

We now consider $h$-scattered ${{\mathbb F}_{q}}$-linear sets $L_U$ of rank $\frac{rn}{h+1}$ as projective systems in $\Omega$, and the related linear codes (with the Hamming metric). By means of Theorem \[th:intersectionhyper\] we determine the weight distribution and the weight enumerator.

Let $L_U$ be a $h$-scattered ${{\mathbb F}_{q}}$-linear set of rank $\frac{rn}{h+1}$ in $\Omega={\mathrm{PG}}(r-1,q^n)$, and $\mathcal{C}_{L_U}$ be the corresponding linear code over ${{\mathbb F}}_{q^n}$, having length $N=\theta_{\frac{rn}{h+1}-1}$ and dimension $k=r$.

Then $\mathcal{C}_{L_U}$ has minimum distance $d=\theta_{\frac{rn}{h+1}-1}-\theta_{\frac{rn}{h+1}-n+h-1}$ and exactly $h+1$ weights, namely $w_i=\theta_{\frac{rn}{h+1}-1}-\theta_{\frac{rn}{h+1}-n+i-1}$ with $i=0,\ldots,h$. The weight enumerator of $\mathcal{C}_{L_U}$ is $$1+\sum_{i=0}^{h}A_{w_i}^H z^{w_i},$$ where $A_{w_i}^H=t_i$, as in Equation .

From ${\rm rk}(L_U)=\frac{rn}{h+1}$ follows the length $N=\theta_{\frac{rn}{h+1}-1}$, and from $\langle L_U\rangle = \Omega$ follows the dimension $k=r$. By Corollary \[cor:intersec\] and Proposition \[prop:projsyst\], the minimum distance of $\mathcal{C}_{L_U}$ is $d=\theta_{\frac{rn}{h+1}-1}-\theta_{\frac{rn}{h+1}-n+h-1}$. Also, the weight distribution and the weight enumerator of $\mathcal{C}_{L_U}$ are as in the claim.

Randrianarisoa in [@Ra] introduced the concept of $[N,k,d]$ $q$-system over ${\mathbb{F}_{q^n}}$ as an $N$-dimensional ${{\mathbb F}_{q}}$-subspace $U$ of ${\mathbb{F}_{q^n}}^k$ such that $\langle U\rangle_{{\mathbb{F}_{q^n}}}={\mathbb{F}_{q^n}}^k$ and $N-d=\max\left\{\dim_{{{\mathbb F}_{q}}}(U\cap H)\colon H=V(k-1,q^n)\subset {\mathbb{F}_{q^n}}^k\right\}$. For any positive integers $r,n,h$ such that $(h+1)\mid rn$ and $n\geq h+3$, Corollary \[cor:caratterizzazione\] implies that the $[\frac{rn}{h+1},r,n-h]$ $q$-systems over ${\mathbb{F}_{q^n}}$ are exactly the $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspaces of ${\mathbb{F}_{q^n}}^r$. In this case, the code $\mathcal{C}$ considered in [@Ra Section 3] has a generator matrix $G$ whose columns form an ${{\mathbb F}_{q}}$-basis of $U$. The code $\mathcal{C}$ turns out to be obtained by $\mathcal{C}_{L_U}$ by deleting all but $\frac{rn}{h+1}$ positions (corresponding to an ${{\mathbb F}}_q$-basis of $U$). Together with [@Ra Theorem 2], this answers the question posed in [@Ra Section 8] about the correspondence between $h$-scattered linear sets and RM codes of this type.

Conclusions and open questions {#sec:open}
==============================

Several connections between between MRD codes and scattered ${{\mathbb F}_{q}}$-subspaces (linear sets) have been introduced in the literature. In this paper we propose a unified approach which generalizes all of these connections. To this aim, we give useful characterizations of $\frac{rn}{h+1}$-dimensional $h$-scattered subspaces. This allows to use the known constructions of $\frac{rn}{h+1}$-dimensional $h$-scattered subspaces in order to define MRD codes, and conversely. The family we construct is very large and contains some ”new” MRD codes, in the sense that they cannot be obtained by puncturing generalized (twisted) Gabidulin codes; this property is in general quite difficult to establish. We conclude the paper by determining the intersection numbers of $h$-scattered linear sets of rank $\frac{rn}{h+1}$ w.r.t. the hyperplanes and the weight distribution of the code obtained by regarding the linear set as a projective system.

Several remarkable problems remain open; we list some of them.

-   The main open problem about $\frac{rn}{h+1}$-dimensional $h$-scattered ${{\mathbb F}_{q}}$-subspaces of $V(r,q^n)$ is their existence for every admissible values of $r$, $n$ and $h$. This would imply the existence of possibly new MRD codes. Conversely, constructions of MRD codes with parameters $(\frac{rn}{h+1},n,q;n-h)$ and right idealiser isomorphic to ${\mathbb{F}_{q^n}}$, when $(h+1)\nmid r$ and $h< n-3$, give new examples of $\frac{rn}{h+1}$-dimensional $h$-scattered subspaces.

-   Corollary \[cor:caratterizzazione2\] characterizes $\frac{rn}{h+1}$-dimensional $h$-scattered subspaces whenever $n\geq h+3$. Is this characterization true also for $n<h-3$?

-   Are there other families of MRD codes which can be characterized in terms of ${{\mathbb F}_{q}}$-subspaces defining linear sets with a special behaviour?

[100]{}

Linear $(q+1)$-fold blocking sets in ${\mathrm{PG}}(2,q^4)$, *Finite Fields Appl.* [**6 (4)**]{} (2000), 294–301.

Maximum scattered linear sets and complete caps in Galois spaces, *Combinatorica* [**38**]{}(2) (2018), 255–278.

Evasive subspaces, [arXiv:2005.08401](https://arxiv.org/abs/2005.08401).

Scattered spaces with respect to a spread in $\mathrm{PG}(n,q)$, *Geom. Dedicata* [**81**]{} (2000), 231–243.

Covering Radius of Matrix Codes Endowed with the Rank Metric, *SIAM J. Discrete Math.* [**31**]{} (2017), 927–944.

A special class of scattered subspaces, [arXiv:1906.10590](https://arxiv.org/abs/1906.10590).

Maximum scattered linear sets and MRD-codes, [*J. Algebraic Combin.*]{} [**46**]{} (2017), 1–15.

Puncturing maximum rank distance codes, *J. Algebraic Combin.* [**49**]{} (2019), 507–534.

Bilinear forms over a finite field, with applications to coding theory, [*J. Combin. Theory Ser. A*]{} [**25**]{} (1978), 226–241.

Theory of codes with maximum rank distance, *Problems of information transmission*, [**21(3)**]{} (1985), 3–16.

Identifiers for MRD-codes, *Linear Algebra Appl.* **575** (2019), 66–86.

Finite groups of Lie type and their representations, in C.M. Campbell, M.R. Quick, E.F. Robertson, C.M. Roney-Dougal, G.C. Smith, G. Traustason (Eds.), *Groups St Andrews 2009 in Bath*, Cambridge University Press, Cambridge (2011), pp. 1–40.

Endliche Gruppen, volume 1, *Springer Berlin-Heidelberg-New York*, 1967.

The new construction of rank codes, *International [Symposium]{} on [Information]{} [Theory]{}*, 2005. [ISIT]{} 2005. [Proceedings]{}, pages 2105–2108, Sept. 2005.

Scattered spaces in Galois Geometry, [*Contemporary Developments in Finite Fields and Applications*]{} (2016), 195–216.

Field reduction and linear sets in finite geometry, In: *Topics in Finite Fields*, AMS Contemporary Math, vol. 623, pp. 271-–293. American Mathematical Society, Providence (2015).

: Automorphism groups of Gabidulin-like codes, [*Arch. Math.*]{} [**107(4)**]{} (2016), 355–366.

MRD-codes and linear sets, [*J. Combin. Theory Ser. A*]{} [**149**]{} (2017), 1–20.

Normal spreads, [*Geom. Dedicata*]{} [**75**]{} (1999), 245–261.

A geometric characterisation of linear k-blocking sets, [*J. Geom.*]{} [**74 (1-2)**]{} (2002), 120–122.

Translation ovoids of orthogonal polar spaces, [*Forum Math.*]{} [**16**]{} (2004), 663–669.

Generalized Twisted Gabidulin Codes, *J. Combin. Theory Ser. A* [**159**]{} (2018), 79–106.

On kernels and nuclei of rank metric codes, [*J. Algebraic Combin.*]{} [**46**]{} (2017), 313–340.

Linear sets from projection of Desarguesian spreads, [arXiv:2001.08685](https://arxiv.org/abs/2001.08685).

Codes with few weights arising from linear sets, [arXiv:2002.07241](https://arxiv.org/abs/2002.07241).

Equivalence and Characterizations of Linear Rank-Metric Codes Based on Invariants, [arXiv:1911.13059](https://arxiv.org/abs/1911.13059).

Linear sets in finite projective spaces, *Discrete Math.* [**310(22)**]{} (2010), 3096–3107.

Connections between scattered linear sets and MRD-codes, *Bulletin of the ICA* [**89**]{} (2020), 46-74.

A geometric approach to rank metric codes and a classification of constant weight codes, [*Des. Codes Cryptogr.*]{} [**80(1)**]{} (2020), <https://doi.org/10.1007/s10623-020-00750-x>.

Rank-metric codes and their duality theory, [*Des. Codes Cryptogr.*]{} [**80(1)**]{} (2016), 197–216.

Teoria di Galois, fibrazioni proiettive e geometrie non Desarguesiane, *Ann. Mat. Pura Appl.* [**64**]{} (1964), 1–76.

A new family of linear maximum rank distance codes, [*Adv. Math. Commun.*]{} [**10(3)**]{} (2016), 475–488.

New semifields and new MRD codes from skew polynomial rings, [*J. Lond. Math. Soc. (2)*]{} [**101(1)**]{} (2020), 432–456.

MRD codes: constructions and connections, *Combinatorics and finite fields: Difference sets, polynomials, pseudorandomness and applications*, Radon Series on Computational and Applied Mathematics [**23**]{}, K.-U. Schmidt and A. Winterhof (eds.), De Gruyter (2019).

Rank-metric codes, linear sets and their duality, [*Des. Codes Cryptogr.*]{} (2019), <https://doi.org/10.1007/s10623-019-00703-z>.

Nuclei and automorphism groups of generalized twisted Gabidulin codes, *Linear Algebra Appl.* [**575**]{} (2019), 1–26.

Giovanni Zini and Ferdinando Zullo\
Dipartimento di Matematica e Fisica,\
Università degli Studi della Campania “Luigi Vanvitelli”,\
I–81100 Caserta, Italy\
[[*{giovanni.zini,ferdinando.zullo}@unicampania.it*]{}]{}

[^1]: The first author is funded by the project ”Attrazione e Mobilità dei Ricercatori” Italian PON Programme (PON-AIM 2018 num. AIM1878214-2). The research was supported by the project ”VALERE: VAnviteLli pEr la RicErca" of the University of Campania ”Luigi Vanvitelli”, and by the Italian National Group for Algebraic and Geometric Structures and their Applications (GNSAGA - INdAM).

[^2]: Recall that $\langle f\rangle_{\mathcal{F}_n}=\{f\circ\omega_{\alpha}\colon\alpha\in{\mathbb{F}_{q^n}}\}$.
