define the Galois closure of $ C $ as $ C^* = \sum_{i=0}^{m-1} C^{[i]} $, and we say that it is Galois closed if $ C = C^* $.

The next lemma is [@silva-universal Lemma 6]. Throughout the paper, $ I(X;Y) $ denotes the mutual information of the random variables $ X $ and $ Y $, taking logarithms with base $ q^m $.

\[lemma silva\] Denote by $ S $ the uniform random variable in $ \mathbb{F}_{q^m}^k $, $ X $ its coset encoding using an $ \mathbb{F}_{q^m} $-linear code $ C \subseteq \mathbb{F}_{q^m}^n $ according to Definition \[definition ozarow\], and denote $ W = XB^T $, where $ B \in \mathbb{F}_q^{\mu \times n} $. Then $$\label{leaked info}
I(S;W) = \dim(C \cap V),$$ where $ V \subseteq \mathbb{F}_{q^m}^n $ is the $ \mathbb{F}_{q^m} $-linear vector space with generator matrix $ B $.

Since Galois closed spaces in $ \mathbb{F}_{q^m}^n $ are those $ \mathbb{F}_{q^m} $-linear spaces with a generator matrix over $ \mathbb{F}_q $ [@stichtenoth Lemma 1], the previous lemma motivates the definition of generalized rank weights, introduced independently in [@oggier] for $ n \leq m $, and in [@rgrw Def. 2] for the general case:

Given an $ 