Let
R be a finite commutative chain ring and let
\(r\ge 1\) be such that the unique maximal ideal
\(\mathfrak {m}\) of
R satisfies
\(\mathfrak {m}^{r-1}\ne 0\) and
\(\mathfrak {m}^r=0\). Let
\(\pi \in R\) satisfy
\(\mathfrak {m}=R\pi \) and let
\(V_r\) be a free
R-module of rank
\(d\ge 2\), that is
\(V_r\cong R^d\). Write
\(\mathcal {L}(V_r)\) for the set of all
R-submodules of
\(V_r\) and
\(\partial \mathcal {L}(V_r)\) for the
boundary of
\(\mathcal {L}(V_r)\):
$$\begin{aligned} \partial \mathcal {L}(V_r)=\{U\in \mathcal {L}(V_r) \mid \pi ^{r-1}V_r\not \subseteq U\not \subseteq \pi V_r\}. \end{aligned}$$
Defining the map
\({{\,\textrm{dist}\,}}:\partial \mathcal {L}(V_r)\times \partial \mathcal {L}(V_r)\rightarrow \mathbb {Z}\) by
$$\begin{aligned} (U_1,U_2)\mapsto {{\,\textrm{dist}\,}}(U_1,U_2)=\min \{m\in \mathbb {Z}_{\ge 0} \mid \pi ^{m}U_1\subseteq U_2\}+\min \{n\in \mathbb {Z}_{\ge 0} \mid \pi ^{n}U_2\subseteq U_1\} \end{aligned}$$
gives
\(\partial \mathcal {L}(V_r)\) the additional structure of a metric space. The last distance can be extended to the whole of
\(\mathcal {L}(V_r)\) modulo
homothety; cf. Sect.
2. Moreover, for
\(r=1\), one can see that
\({{\,\textrm{dist}\,}}\) does not coincide with the subspace metric or the injection metric on
\(\mathcal {L}(V_1)\); cf. [
30, Section 1]. A
spherical code in
\(V_r\) is then a subset
\({{\,\mathrm{\mathcal {C}}\,}}\) of
\(\partial \mathcal {L}(V_r)\) of cardinality at least 2 and its
minimum distance is
$$\begin{aligned} {{\,\textrm{dist}\,}}({{\,\mathrm{\mathcal {C}}\,}})=\min \{{{\,\textrm{dist}\,}}(U_1,U_2)\mid U_1,U_2\in {{\,\mathrm{\mathcal {C}}\,}},\, U_1\ne U_2\}. \end{aligned}$$
Spherical codes in
\(V_r\) are natural generalizations of subspace codes, though the attribute “spherical” comes from interpreting
\(\partial \mathcal {L}(V_r)\) as a sphere of modules, cf. Proposition
2.6. In this manuscript, we address and give answers to the following question:
$$\begin{aligned}{} & {} { For \; a \; given\; integer \; } \psi ,{ \; what\; are\; the\; largest \; spherical \; codes \; } \mathcal {C} { in } V_r \\{} & {} \quad {\; with\; the \; property\; that\; } {{\,\textrm{dist}\,}}({{\,\mathrm{\mathcal {C}}\,}})\ge \psi ? \end{aligned}$$
The largest codes associated to a given minimum distance are called
optimal. If
\(\psi =1\), then there is a unique optimal code of minimum distance 1, namely
\(\partial \mathcal {L}(V_r)\): we compute its cardinality in Sect.
8. In general, good candidates for optimal codes are the
Sperner codes that we define in Sect.
4 using Grassmannians of
R-modules. Such codes are defined starting from the parameters
\((d, R,\alpha )\) where
\(\psi =2\alpha \) is taken to be even. In Theorem
4.5, we compute the cardinality and minimum distance of a Sperner code with parameters
\((d,R,\alpha )\), yielding general bounds on the maximal size of codes of minimum distance
\(2\alpha \); cf. Corollary
4.6. In Sect.
5, we use results from extremal combinatorics to prove that Sperner codes are optimal when
\(\alpha =r\) or
\(d=2\); cf. Theorems
5.4 and
5.6. We move on to the construction, in Sect.
6, of optimal codes in a subfamily of
\(\partial \mathcal {L}(V_r)\) indexed by tuples of positive integers. More concretely, let
\(\partial \mathcal {L}_\textbf{e}(V_r)\) denote the collection of boundary
R-submodules of
\(V_r\) that can be generated
compatibly with a basis
\(\textbf{e}=(e_1,\ldots ,e_d)\) of
\(V_r\) over
R, i.e. modules of the form
$$\begin{aligned} U=R\pi ^{\delta _1}e_1\oplus \cdots \oplus R\pi ^{\delta _d}e_d, where 0\le \delta _i\le r,\ \{0,r\}\subseteq \{\delta _1,\ldots ,\delta _d\}. \end{aligned}$$
Generalizing [
21, Chapter 4], a
permutation code is a spherical code in
\(V_r\) that is contained in
\(\partial \mathcal {L}_\textbf{e}(V_r)\) and whose elements form one orbit under the natural action of the symmetric group
\({{\,\textrm{Sym}\,}}(d)\) on
\(\partial \mathcal {L}_\textbf{e}(V_r)\). In Theorem
6.9 we give bounds on minimum distance and cardinality of a permutation code in terms of its defining parameters.