A Topological View of Reed–Solomon Codes

: We studied a particular class of well known error-correcting codes known as Reed–Solomon codes. We constructed RS codes as algebraic-geometric codes from the normal rational curve. This approach allowed us to study some algebraic representations of RS codes through the study of the general linear group GL ( n , q ) . We characterized the coefﬁcients that appear in the decompostion of an irreducible representation of the special linear group in terms of Gromov–Witten invariants of the Hilbert scheme of points in the plane. In addition, we classiﬁed all the algebraic codes deﬁned over the normal rational curve, thereby providing an algorithm to compute a set of generators of the ideal associated with any algebraic code constructed on the rational normal curve (NRC) over an extension F q n of F q .


Introduction
Let us denote by F q the finite field of q elements with q a power of prime number p. One can consider field extensions F q of F p as q varies through powers of the prime p. Any F p n field extension of F p is a vector space over F p of dimension n and an (n − 1)−dimensional projective space PG(n − 1, p).
Let V be an n + 1 dimensional vector space over the field F q ; we denote by PG(n, q) or P(V) the n-dimensional projective space over V and by P 1 , the projective line. The set of all subspaces of dimension r in V is a Grassmannian, and it is denoted by G r,n (F q ) or by PG r (n, q). The dual of an r−space in PG(n, q) is an (n − r − 1)−space.
Consider the F q −rational points of G r,n (F q ) as a projective system; we obtain a qary linear code, called the Grassmann code, which we denote [n, r] q code. The length l and the dimension k of G(r, n) are given by the q binomial coefficient l = n r q = (q n+1 −1)(q n+1 −q)...(q n+1 −q r ) (q r+1 −1)(q r+1 −q)...(q r+1 −q r ) , and k = ( n r ), respectively. We study the relation between codes constructed from vector bundles and the representation theory of the general linear group GL(n, F q ). Following [1], we consider the right action of the general linear group GL(n, F q ) on G k,n (F q ): G k,n (F q ) × GL(n, F q ) → G k,n (F q ) (1) (U , A) → U A.
Observe that the action is defined independently of the choice of the representation matrix U ∈ F k×n q . Let U ∈ G k,n (F q ) and G < GL(n, F q ) be a subgroup; then C = {U A| A ∈ G} is an orbit in G k,n (F q ) of the induced action.
In order to classify all the orbits, we need to classify all the conjugacy classes of subgroups of GL(n, F q ). In [2], we studied cyclic coverings of the projective line that correspond to orbits defined by a cyclic subgroup of order p as the multiplicative group of p th roots of unity or the additive group of integers modulo p for some prime number p. In particular, we showed that any irreducible cyclic plane cover of the projective line can be given by a prime ideal This ideal defines an affine curve in A 2 (F q ) which has singularities, if d k > 1 for some 1 ≤ k ≤ n. There exists a unique projective curve birationally equivalent to this affine curve obtained by homogenization of the polynomial. Here we study the connection between ideal sheaves on F q [x, y] and its numerical invariants together with the combinatorics of partitions of n and the representation theory of the general linear group GL(F q , n). In other words, we want to understand which subspaces are invariant by the action of elements of the general linear group or finite subgroups of GL(n, F q ) and how the GL(n, F q ) group's action on the Grassmannian changes the Grassmann code, as this action simply permutes basis elements of the Grassmann code.
When one considers as an alphabet a set P = {P 1 , . . . , P N } of F q −rational points lying on a smooth projective curve defined over a finite field, algebraic codes are constructed by evaluation of the global sections of a line bundle or a vector bundle on the curve. Any cyclic cover of P 1 which is simply ramified corresponds to an unordered tuple of n points on P 1 . More generally, in Section 4 we consider configurations of n points in a d−dimensional projective space PG(d, q) which generically lies on a rational normal curve (NRC) and we study the algebraic codes defined on it, providing a complete classification in terms of divisors defined over the NRC; see Theorem 2. These are the so called Reed-Solomon codes. Moreover, in the last section as an application of the Horn problem, we provide a set of generators of the ideal associated with any algebraic code constructed on the NRC over an extension F n q of F q . From now on, F q will be a field with q = p n elements and C a non-singular, projective, irreducible curve defined over F q with q elements.

Notation
For d a positive integer, α = (α 1 , . . . , α m ) is a partition of d into m parts if the α i are positive and decreasing integers summing to n. We will denote as P (d) the set of all partitions of d. We set l(α) = m for the length of α, that is, the number of cycles in α, and l i for the length of α i . The notation (a 1 , . . . , a k ) stands for a permutation in S d that sends a i to a i+1 . For λ ∈ P (d), we write [λ] for the corresponding character of S n . We write PGL(2, k) = GL(2, k)/k * , where k is field of arbitrary characteristic and elements of PGL(2, k), which will be represented by equivalence classes of matrices a b c d , with ad − bc = 0. A q−ary constant weight code of length n, distance d and weight w will be denoted as an [n, d, w] q code.

Horn Problem: An Application to Convolutional Codes
In this section we present a description of the Horn problem, i.e., the study of the eigenvalues of the sum C = A + B of two matrices, given the spectrum of A and B, in the context of polynomial matrices with polynomial entries associated with torsion modules or dually submodules of a polynomial ring with coefficients in a field. Next, we introduce some important matrices that define a linear error-correcting code.
Let R be any complete valued field R with a closed coefficient field k of an arbitrary characteristic, for example, a finite field or the ring R = C{x} of convergent power series. If f ∈ R is a nonzero divisor, then we define the encoder A as the matrix associated with the corresponding torsion module R/ f R. The matrix A can be diagonalized by elementary row and column operations with diagonal entries x α 1 , x α 2 , . . . , x α n , for unique non-negative integers α 1 ≥ . . . ≥ α n . More precisely, these matrices are in correspondence with endomorphisms of R n , with cokernels being torsion modules with at most n generators. Such a module is isomorphic to a direct sum The set (α 1 , . . . , α n ) of invariant factors of A defines a partition α of size d = |λ|. Reciprocally, when R = C{x} is the ring of convergent power series, any partition λ defines a rank one torsion-free sheaf on C by setting I λ = (x λ 1 , x λ 2 , x λ 3 , . . . , x λ n ). In particular, the ideal sheaf corresponding to the identity partition (1) n , defines a maximal . The Horn problem is then equivalent to the following question: which partitions α, β, γ can be the invariant factors of matrices A, B and C if In the case of convergent power series, this problem was proposed by I. Gohberg and M.A. Kaashoek. By denoting the cokernels of A, B and C as A, B and C, respectively, one has a short exact sequence: i.e., B is a submodule of C with C/B ∼ = A; such an exact sequence corresponds to matrices A, B and C with A · B = C.
If we specialize C to be the identity matrix I, by the correspondence between partitions and ideal sheaves above, the invariant factors of the identity matrix are defined by the partition (1) n , then the question becomes: which partitions α, β can be the invariant factors of matrices A, B if A · B = I? The case of interest for us will be the case in which R is an F q [x]-module with q a prime power of p.
Duly, the code can be defined as an R−submodule of R n , where R = F[z] is a polynomial ring with coefficients in a field F and z is a uniformizing parameter in R (see [3]). When F is a finite field, these are known as convolutional codes which have been very well studied; see, for example, [4]. A full row rank matrix G(z) ∈ F[z] k×n with the property that is called a generator matrix. The degree d of a convolutional code C is the maximum of the degrees of the determinants of the k × k submatrices of one, and hence any generator matrix of C. The main difference between block and convolutional codes is that at the encoder, in a convolutional code we may have different states. Linear block codes may be considered as a particular case of convolutional codes with only one state. In next section we describe an example of block codes known as Reed-Solomon codes.

Remark 1.
The set of convolutional codes of a fixed degree is parametrized by the Grothendieck Quot scheme of degree d, rank n − k coherent sheaf quotients of O n on a curve X defined over F. If the degree is zero, these schemes describe a Grassmann variety and constitute the so called class of block codes of parameters (n, k). Namely, the space of all matrix divisors D k (r, d) of rank r and degree d can be identified with the set of rational points of Quot m O X (D) n /X/k parametrizing torsion quotients of O X (D) n and having degree m = r · deg D − d, see [5].
An Example with Algebraic-Geometric Codes: Reed-Solomon Codes Let X be a smooth projective curve defined over a finite field F q with q elements. The classical algebraic-geometric (AG) code due to Goppa is defined by evaluating rational functions associated with a divisor D at a finite set of F q -rational points. From another point of view, we are considering the evaluation of sections of the corresponding line bundle O X (D) on X. Namely, let P := {P 1 , . . . , P n } be a configuration of distinct F q -rational points of X, the usual algebraic-geometric code is defined to be the image of the evaluation map: where L(D) denotes the vector space of sections associated with the line bundle O X . The parameters of these codes, the length n, the dimension k and the minimum distance d are determined by the theorem of Riemann-Roch and it is easy to see that they satisfy the following bound k + d ≥ n + 1 − g, where g is the genus of the curve X. Using this definition, the notion of AG codes is easily generalized for varieties of higher dimension.
Namely, let E be a vector bundle of rank r on X defined over F q . The Goppa code C(X, D, G) takes as input a divisor D supported on the finite set P of F q -rational points and a divisor G associated with the vector bundle E and evaluates each section σ ∈ L(G) in the linear series attached to the divisor G: Observe that C(X, P, E) is an F q -linear subspace of F n q r and thus a point of the Grassmannian G r,n (F q ). Moreover, for the same subset of evaluation points and any r ≤ k, we to which we associate the partition λ = (λ 1 , . . . , λ r ) of n. In this way, each partition λ of n determines a variety F λ = F λ (F q ) of partial flags of F q -vector spaces.
The representation theory of the special linear group SL(n, F q ) can be viewed as a form of Gale duality first proven by Goppa in the context of algebraic coding theory.
Let D and G be effective divisors supported over a smooth projective curve X defined over F q such that Supp(G) ∩ Supp(D) = ∅, then the geometric Goppa code associated with the divisors D and G is defined by where L(G) denotes the linear system associated with the divisor G. Definition 1. Let C 1 and C 2 be the corresponding codes obtained by evaluating non-constant rational functions f (x) and g(x) with non common roots on X over the support of the divisor D. We define the quotient code of C 1 and C 2 to be the code associated with the quotient rational function ϕ = f /g.
Since f and g take the value ∞, they are defined by non constant polynomials f (x) and As ϕ is a finite morphism, one may associate to each rational point x ∈ X(F q ) a local degree or multiplicity m ϕ (x) defined as: With each non-constant rational function ϕ over X, one can associate a matrix A with entries in the ring F q [x]. Namely, let us call f 0 := f (x) and call f 1 the divisor polynomial g(x), and f 2 the remainder polynomial; then by repeated use of the Euclid's algorithm, we construct a sequence of polynomials f 0 , f 1 , . . . , f k , and quotients q 1 , . . . q k , K ≤ n. Then the quotient matrix A is defined to be the diagonal matrix with entries q 1 , . . . , q k corresponding to the continued fraction expansion of the rational function ϕ.
Here we include a SAGE code [6] which implements the algorithm.
def euclid(f, g): r = f % g q = f // g while r.degree() >= 0: yield q f = g g = r r = f % g q = f // g Let λ i be the partition of the integer k, defining the degree multiplicities of the polynomial q i . Then the Horn problem applied to this situation reads: Which partitions α, β and γ can be the degree multiplicities of polynomials q A , q B and q C such that the corresponding diagonal matrices A, B, and C satisfy C = A · B?
Another important family of Goppa codes is obtained considering the normal rational curve C n defined over F q : The points are distinct elements of F q and L is the vector space of polynomials of degree at most k − 1 and with coefficients in F q . Such polynomials have at most k − 1 zeros, so nonzero codewords have at least n − k + 1 non-zeros. Hence, this is a [n, k, n − k + 1] q code whenever k ≤ n. Any codeword (c 0 , c 1 , . . . , c n−1 ) can be expressed into a q-ary k-vector with respect to the basis {1, α, . . . , α k−1 }.These codes are just generalized Reed-Solomon In other words, the GRS code is an ideal in the ring F q [x]/(x k − x − 1) generated by a polynomial g(x) with roots in the splitting field F l q of x k − x − 1, where k|q l − 1. Since the NRC is a genus 0 curve, it is easy to see that these codes satisfy the Singleton bound d ≥ n − k + 1.
Construction of Reed-Solomon codes over F q only employs elements of F q , hence their lengths are at most q. In order to get longer codes, one can make use of elements of an extension of F q , for instance considering subfield subcodes of Reed-Solomon codes.
As in [2], where we considered a variant of the Horn problem in the context of cyclic coverings of the projective line defined over an arbitrary field k, the problem is reduced to study the representation theory of the general linear group GL(n, F q ).

Representation Theory of GL(n, F q )
We focus on Grassman codes G k,n (F q ) that were described in the introduction as [n, k] q −codes by considering an action (1) of the general linear group GL(n, q) on the Grassmannian. The study of the representation theory of GL(n, q) will allow us to understand better the orbits of this action that will be characterized in Section 5.
The multiplication in the finite field F q n is a bilinear map from F q n × F q n into F q n . Thus it corresponds to a linear map from the tensor product m : F q n ⊗ F q n → F q n . The symmetric group S n acts on F q n via the permutation matrix: The d-Veronese embedding of P n (F q ) maps the line spanned by the vector v ∈ F q n to the line spanned by v ⊗d = v ⊗ . . . ⊗ v. Thus the symmetric group S n acts diagonally on the basis of simple tensors of F q n .
For each partition λ = (λ 1 , . . . , λ k ) we consider its Young diagram. The diagram of λ is an array of boxes, lined up at the left, with λ i boxes in the i th row, with rows arranged from top to botton. For example, is the Young diagram of the partition λ = (5, 3, 3, 1) with l(λ) = 4 and |λ| = 12. We define the Schur projection: Let S n be the symmetric group of permutations over d elements. Any permutation σ ∈ S n acts on a given Young diagram by permuting the boxes. Let R λ ⊆ S n be the subgroup of permutations preserving each row. Let C λ ⊆ S n be the subgroup of permutations preserving each column, let The image of c λ is an irreducible GL(n, F q )-module, which is nonzero iff the number of rows is less or equal than dimV λ . All irreducible GL(n, F q )-modules can be obtained in this way. Every GL(n, F q )−module is a sum of irreducible ones.
In terms of irreducible representations of GL(n, F q ), a partition η corresponds to a finite irreducible representation that we denote as V(η). Since GL(n, F q ) is reductive, any finite dimensional representation decomposes into a direct sum of irreducible representations, and the structure constant c η λ,µ is the number of times that a given irreducible representation V(η) appears in an irreducible decomposition of the tensor product of the representations V(λ) ⊗ V(µ). These are known as Littlewood-Richardson coefficients, since they were the first to give a combinatorial formula encoding these numbers (see [7]). In terms of the Hopf algebra Λ of Schur functions, let s λ be the Schur function indexed by the partition λ, we have s λ · s µ = ∑ ν k ν λµ s ν for the product and we get the coefficients k η λµ as the structure constants of the dual Hopf algebra Λ * . These are known as Kronecker coefficients (see [8,9]) since they appear as expansion coefficients in the Kronecker product [λ][µ] = ∑ ν k λµ [ν] of characters of the symmetric group S n , as the authors proved in Proposition 4.3 of [2]. Recall that the Schur function s λ attached to the partition λ = (λ 1 , . . . , λ n ) of length less or equal than n is defined by the quotient: It is a homogeneous polynomial of degree |λ| in x 1 , . . . , x n . It easily seen that s λ (x 1 , . . . , x n , 0) = s λ (x 1 , . . . , x n ). Moreover we can define the Schur function s λ as the unique symmetric function with this property for all n ≥ l(λ). It is well known that the Schur functions constitute a basis for the ring Λ of symmetric functions. In addition, there are at least other three well known bases for the ring Λ of symmetric functions. The basis e k of k-elementary symmetric functions, the h k complete homogeneous symmetric functions of degree k and the power sums p k = z k 1 + z k 2 + . . .. This has been applied in Reed-Solomon coding, that is, for AG codes defined on the projective line P 1 , as a way to encode information words. Namely, for each codeword a = (a 0 , a 1 , . . . , a n ), a i ∈ F q , let us define a n+1 = ∑ n i=1 a i ∈ F q which is nothing but the first elementary symmetric function e 1 . If we consider the variables x 1 , . . . , x r as a fixed list of nonzero elements in F q , then the information word a can be encoded into the codeword d = (d 1 , . . . , d r ), where d i = ∑ n j=1 a j x j i . The secret is a 0 = − ∑ r i=1 d i , while the pieces of the secret are the d i s.

Relation between Littlewood-Richardson Coefficients and Kronecker Coefficients
One can stack Littlewood-Richardson coefficients c ν λµ in a 3D matrix or 3-dimensional matrix. Intuitively a 3D matrix is a stacking of boxes in the corner of a room. The elements of the principal diagonal are called rectangular coefficients and are indexed by triples (λ, µ, ν) = ((i n ), (i n ), (i n )) of partitions (i n ) with all their parts equal to the same integer 1 ≤ i ≤ n.
Consider B and C, two 3D matrices, then we define the product matrix B · C as the 3D matrix Namely, for each index ν fixed, λ and µ run over all partitions P (n) of n. Thus the coefficients c ν λ,µ λ,µ∈P (n) are encoded in a matrix of order p(n) × p(n), where p(n) denotes the number of unrestricted partitions of n, that is, the number of ways of writing the integer n as a sum of positive integers without regard to order. Thus the product matrix B ν · C ν is the standard product of square matrices in M p(n)×p(n) (Q). In particular, the property of associativity follows easily from the associativity in the vector space M p(n)×p(n) (Q). Proposition 1. Let C be the 3D matrix whose entries are the Littlewood-Richardson coefficients, and K the 3D matrix of Kronecker coefficients. Then the matrices are inverse one to each other.
Proof. Since c ν λµ and k ν λµ correspond to the structure constants of the Hopf algebra of Schur functions and its dual one respectively (see Proposition 4.3 of [2]), and the Hopf algebra of Schur functions is self-dual (see [9]), one gets that the product matrix C · K is the identity 3D matrix I, that is, the matrix whose rectangular coefficients are identically 1. Thus both matrices are inverse one to each other. (λ, µ, η) for Which c η λ,µ Is Positive The convex hull in R 3 of all triples (λ, µ, ν) with c ν λ,µ > 0 is the Newton polytope of f (x, y, z) = ∑ λ,µ,ν c ν λ,µ x λ y µ z ν ∈ C[x, y, z]. Here x λ denotes the monomial x λ 1 · · · x λ n of partition degree λ. In particular, when λ = (1 r ), we have x (1) r = e r = ∑ i 1 <...<i r x i 1 . . . x i r , the r−th elementary symmetric function. At the other extreme, when λ = (r) we have x (r) = p r = ∑ x r i , the r−power sum. As we have seen in the previous section, it is clear that every symmetric function f ∈ Λ is uniquely expressible as a finite linear combination of the (x λ ) λ∈P . Moreover, the following theorem shows that f is the the generating series for the Gromov-Witten invariant N d,g (λ, µ, ν) counting irreducible plane curves of given degree and genus g passing through a generic configuration of 3d − 1 + g points on P 2 (C) with ramification type at 0, ∞ and 1 described by the partitions λ, µ and ν and simple ramification over other specified points with |λ| + |µ| + |ν| = d, and these have been computed by Fomin and Mikhalkin in [10].
Proof. Whenever the coefficient c ν λ,µ > 0 is positive consider the corresponding ideal sheaves I λ , I µ and I ν in C[x, y, z] associated with the partitions λ, µ and ν respectively. Each ideal sheaf determines a curve in C[x, y] via homogenization of the corresponding monomial ideals. Thus each coefficient represents the number of ideal sheaves on C 3 of colength n and degree d equal to the size of the partition, that is the corresponding 3-point Gromov-Witten invariant λ, µ, ν 0,3,d of the Hilbert scheme Hilb n of n = 2d − 1 + |ν| + |µ| + |λ| + g distinct points in the plane, or the relative Gromov-Witten invariant N d,g (λ, µ, ν) counting irreducible plane curves of given degree d and genus g passing through a generic configuration of 3d − 1 + g points on P 2 (C) with ramification type at 0, ∞ and 1 respectively, described by the partitions λ, µ and ν of n (see section 4 of [2]).

Remark 2.
The Euler characteristic of each ideal sheaf is fixed and coincides with the Euler characteristic χ of the polyhedra described in R 3 by the convex hull of all triples (λ, µ, ν) with c ν λ,µ > 0, that is, the Newton polytope of f (x, y, z) = ∑ λ,µ,ν c ν λ,µ x λ y µ z ν ∈ R[x, y, z]. Thus each coefficient represents the number of ideal sheaves on C 3 of fixed Euler characteristic χ = n and degree d equal to the size of the partition, that is the corresponding Donaldson-Thomas invariant of the blow-up of the plane P 1 × (C 2 ) with discrete invariants χ = n and degree d.

Remark 3.
The Hilbert scheme Hilb n of n points in the plane C 2 parametrizing ideals J ⊂ C[x, y] of colength n contains an open dense set in the Zariski topology parametrizing ideals associated with configurations of n distinct points. Moreover there is an isomorphism Hilb n ∼ = (C 2 ) n /S n . In particular, as we showed in [2], any conjugacy class in the symmetric group S n determines a divisor class in the T−equivariant cohomology H 4n T (Hilb n , Q), for the standard action of the torus T = (C * ) 2 on C 2 . The T−equivariant cohomology of Hilb n has a canonical Nakajima basis indexed by P (n). The map λ → J λ is a bijection between the set of partitions P (n) and the set of T−fixed points Hilb T n ⊂ Hilb n .

Remark 4.
If we choose the partition ν to be the empty partition ∅, we recover the relative Gromov-Witten invariants N d,g (λ, µ) studied by Fomin and Mikhalkin in [10], and by Caporaso and Harris in [12].

Configurations of Points over a Normal Rational Curve
In this section, we study codes defined from a linear series attached to a divisor on the normal rational curve NRC or equivalently Goppa codes on P 1 and hence generalized Reed-Solomon codes. Assume V is a vector space of dimension n + 1 over a field k equipped with a linear action, that is, G acts via a representation G → GL(V). We denote by S d V the d-th symmetric power of V.
Consider the d-Veronese embedding of P n In particular, the homogeneous coordinate ring for the natural projective embedding of the geometric invariant theory (GIT) quotient (P d ) n //SL d+1 is the ring of invariants for n ordered points in the projective space up to, projectivity, i.e, if one considers the function field k(x 1 , . . . , x d ) of the projective space (P) d , the ring of invariants is defined by: Generators for this ring are given by tableau functions, which appear in many areas of mathematics, particularly representation theory and Schubert calculus. Consider the hypersimplex: for any 1 ≤ d ≤ n − 3 and choose a linearization c ∈ (d + 1, n), there is a morphism ϕ :M 0,n → (P d ) n // c SL d+1 , sending a configuration of distinct points on P 1 to the corresponding configuration under the d th Veronese map.
The symmetric power Sym n C d of the curve C d is the quotient of the configuration space C n d of n unordered tuples of points on the normal rational curve C d by the symmetric group S n . Furthermore, we can identify the set of effective divisors of degree d on C d with the set of k-rational points of the symmetric power Sym n C, that is, Sym n C represents the functor of families of effective divisors of degree n on C.

Lee-Sullivan List-Decoding Algorithm of Reed-Solomon Codes
By definition, the rational normal curve C d is the image by the d−Veronese embedding of PV * = P 1 where V is a 2-dimensional vector space, therefore it is isomorphic to any curve of genus 0. The action of PGL(2, k) on P d preserves the rational normal curve C d . Conversely, any automorphism of P d fixing C d pointwise is the identity. It follows that the group of automorphisms of P d that preserves C d is precisely PGL(2, k). These codes are just generalized RS codes and they come with efficient decoding algorithms once we choose a metric consistent with channel errors and search of a set of vectors with given metric properties as a correcting code. In particular, these codes are consistent with the Hamming metric ( [13,14]). Recall that given two vectors of length n, say U and V, the Hamming distance d H (U, V) between U and V is the number of coordinates in which they differ.
Given a [n, k] RS code C of length n and dimension k, we call d the minimum (Hamming distance) which attains the Singleton bound n − k + 1. We shall identify the code with the set of its codewords. A codeword of C is viewed as a polynomial c 0 + c 1 x + . . . + c n−1 x n−1 in the F−vector space F[x], where F is a finite field. In the communication process, when a codeword is transmitted, it can be affected by errors and erasures. An error occurs when one codeword component is changed into another field element and an erasure occurs when the received component has an unknown value. The problem of minimum distance decoding is to find, for any given vector v, the set C v of all codewords c ∈ C at minimum distance from v. If C v contains just one element c, then the sent codeword coincides with the received codeword and no decoding is needed. The codewords of minimum weight are the points lying in the intersection of any line and the curve. K. Lee and M.E. O'Sullivan in [15] describe a list decoding algorithm consisting of two steps: the interpolation step and the root-finding step. Starting with a set of generators of the module induced from the ideal for the n points {P 1 , . . . , P n }, they convert the generators to a Gröbner basis of the module in which the minimal polynomial is found. This results in an efficient algorithm solving the interpolation problem.
Let v be the received vector, and fix n distinct points α 1 , . . . , α n from F, for each 1 ≤ i ≤ n, let P i denote the point (α i , v i ) by Lagrange interpolation we get the polynomial , and 0 otherwise. Now for m ≥ 1, we define the ideal For f ∈ F[x, y] and u ≥ 1, denoted by deg u ( f ), the (1, u)−weighted degree of f , that is, the variables x and y, are assigned weights 1 and u, respectively, and for a monomial x i y j , we define deg u (x i y j ) = i + uj.
The goal of the interpolation step is to find a polynomial in I v,m having the smallest is a set of generators of I v,m . Let Q be the minimal polynomial of I v,m with respect to the monomial order > k−1 of F[x, y]. We can find Q by computing a Gröbner basis of I v,m with respect to > k−1 . In Appendix A, we provide Horn's algorithm to compute sets of indices which are admissible for the Horn problem. As a result, we provide a set of generators for the algebraic code induced on the NRC.

Proposition 2.
If we consider the set of orbits of C n d by the action of finite subgroups of the symmetric group S n , we get all possible divisor classes in the group Div n (C d ) of degree n divisors on C d .

Proof.
Since the symmetric group S n is generated by 3 elements, a reflection of order 2, a symmetry of order 3 and a rotation of order n, we get all the divisor classes by quotienting the configuration space C n d of n points on the normal rational curve, by the cyclic group generated by the rotation, or one of the triangle groups, the dihedral group D n , the alternated groups A 4 , A 5 or the symmetric group S 4 .

Notion of Collinearity on the Normal Rational Curve
A permutation matrix σ ∈ GL(n, F q ) acts on the Grassmannian by multiplication on the right of the corresponding representation matrix. In particular, we are interested in understanding the orbits by the action of any permutation matrix of GL(n, F q ) and moreover of any subgroup G contained in GL(n, F q ). Further, it is possible to count the orbits of the action in several cases and this is established by the correspondence given in Theorem 2 between sets of points satisfying certain geometrical conditions and partitions. Definition 2. An incidence structure S on V is a triple (P, B, I), where P is a set whose elements are smooth, reduced points in V, B is a set whose elements are subsets of points called blocks (or lines in several specific cases) endowed with a relation of collinearity, and an incidence relation I ⊂ P × B. If (P, L) ∈ I, then we say that P is incident with L or L is incident with P, or P lies in L or L contains P.
When the collinearity relation is a symmetric ternary relation defined on triples (p, q, r) ∈ P × P × P by the geometric condition (p, q, r) ∈ B if either p + q + r is the full intersection cycle of C d with a k-line l ⊂ P n (k) with the right multiplicities, or else if there exists a k-line l ⊂ V such that, p, q, r ∈ l, then the triple (p, q, r) is called a plane section.

1.
For any (p, q) ∈ P 2 (V * ), there exists an r ∈ P (S d V * ) such that (p, q, r) ∈ l. The triple (p, q, r) is strictly collinear if r is unique with this property, and p, q, r are pairwise distinct. The subset of strictly collinear triples is a symmetric ternary relation. When k is a field algebraically closed of characteristic 0, then r is unique with this property, and we recover the euclidean axioms.

2.
Assume that p = q and that there are two distinct r 1 , r 2 ∈ P with (p, q, r 1 ) ∈ B and (p, q, r 2 ) ∈ B. Denote by l = l(p, q) the set of all such rs, then l 3 ∈ B-that, is any triple (r 1 , r 2 , r 3 ) of points in which l is collinear. Such sets l are called lines in B.
If V is a 3-dimensional vector space defined over the finite field F p , then the projective plane P 2 (F p ) on V is defined by the incidence structure PG(2, p) = (P (V), L(V), I).

1.
A (k; r)-arc K in PG(2, p) is a set of k points such that some r, but not r + 1 of them are collinear. In other words, some line of the plane meets K in r points and no more than r points. A (k; r)−arc is complete if there is no (k + 1; r) arc containing it.

2.
A k-arc is a set of k points, such that, every subset of s points with s ≤ n points is linearly independent.
Let q denote some power of the prime p and PG(n, p) be the n-dimensional projective space (F p ) n+1 ∼ = F q , where n ≥ 2.The normal rational curve C is defined as: If q ≥ n + 2, the NRC is an example of a (q + 1)−arc. It contains q + 1 rational points, and every set of n + 1 points are linearly independent. For each a ∈ (F p ) n+1 , the mapping: F p (x 0 , . . . , x n ) → F p (a 0 x 0 , . . . , a n x n ), describes an automorphic collineation of the NRC.
Both Ω and Ψ are closure operators on {0, 1, . . . , n}. Likewise the projective collineation F p (x 0 , x 1 , . . . , x n ) → F p (x n , x n−1 , . . . , x 0 ) leaves the NRC invariant whence Λ has to be closed with respect to Ψ. Any algebraic-geometric code constructed by evaluation of a function over the NRC with values in F q is a generalized Reed-Solomon code of length at most q. In order to get longer codes, one needs to use elements from any finite extension F r q of F q .

Proposition 3. Each subspace invariant under collineation of the NRC is indexed by a partition in P (t).
If the ground field k is sufficiently large, then every subspace which is invariant under all collineations of the NRC is spanned by base points kc λ , where λ ∈ P (t).
Proof. Let E t n := {(e 0 , e 1 , . . . , e n ) ∈ N n+1 | e 0 + e 1 + . . . + e n = t}, be the set of partitions of t of n parts and let Y be the ( n t )−dimensional vector space over F p with basis {c e 0 ,e 1 ,...,e n ∈ F q : (e 0 , e 1 , . . . , e n ) ∈ E t n }. Let us call V t n the Veronese image under the Veronese mapping given by: n c e 0 ,...,e n x e 0 x e 1 1 · · · c e n n ), The Veronese image of each r-dimensional subspace of PG(n, p) is a sub-Veronesean variety V t r of V t n , and all those subspaces are indexed by partitions in P (t). Thus by a Theorem due to Gmainer are invariant under the collineation group of the normal rational curve (see [16]).
The k-rational points (p 0 , p 1 , · · · , p n ) of the normal rational curve C correspond to collinear points on C that are defined over some Galois extension l of k and permuted by Gal(l/k).

An Application: Three-Point Codes on the Normal Rational Curve
As we showed in Proposition 3, each subspace invariant under collineation of the NRC is indexed by a partition λ ∈ P (d). Let us call the base point associated with the partition λ as P λ . As we are considering that the ground field is F q , the F q -points might be defined over a finite extension F q r of F q . Observe that for any divisor r of n, one easily obtains a extension field of F q of degree r. Namely, let ξ a non-trivial r−root of unity, one can consider the symbols ξ q r , . . . , ξ q , ξ and the polynomial which has them as roots, q(x) = ∏ i=r i=0 (1 − ξ q i ) gives an extension field of F q of degree r.

Theorem 2.
Let σ 1 , σ 2 , σ 3 be three generators for the symmetric group S d and let λ 1 , λ 2 and λ 3 be the partitions of d indexing the corresponding irreducible representations in the special linear group SL(n, F q ). Then any algebraic code defined over the NRC is covered by a divisor defined as linear combination of the base points (P λ i ) 1≤i≤3 on the NRC, where the λ i are LR coefficients.
Proof. Consider the divisors associated with the rational maps f (x, y, z) = nx + my + lz defined over the normal rational curve C d defined over F q , with n, m and l integer numbers. In particular, if d| q 2 − 1, the points P = (α, 0, 0), Q = (0, β, 0) and R = (0, 0, γ) with α d = 1, β d = 1 and γ d = 1, are F q 2 −rational points on C d , and the divisors nP, mQ and lR define codes on it. Reciprocally, given a code on the NRC, by Proposition 2, the corresponding divisor defining the code is defined by a finite subgroup in the symmetric group. Since the symmetric group is generated by the 3 elements σ 1 , σ 2 and σ 3 , the divisor is a linear combination of the base points (P λ i ) 1≤i≤3 on the NRC.

•
The sorted() mapping function in getUnr() is necessary because the order of elements in Subsets is unknown; • There is a 1-offset between index in Python lists and index sets we use; • The recursion in getTnr() is factored out in getTillR() call; • The cache decorator mitigates the perils of performing the same calculation several times in a function that is already heavily recursive; • Results are limited by constraints Python has on recursive function calls; • The filtering performed on U n r to get T n r is implemented by two nested calls to all().