aa r X i v : . [ c s . I T ] M a y New families of self-dual codes
Lin Sok ∗ Abstract
In the recent paper entitled “Explicit constructions of MDS self-dual codes” accepted in IEEE Transactions on Information Theory,doi: 10.1109/TIT.2019.2954877, the author has constructed families ofMDS self-dual codes from genus zero algebraic geometry (AG) codes,where the AG codes of length n were defined using two divisors G and D = P + · · · + P n . In the present correspondence, we exploremore families of optimal self-dual codes from AG codes. New familiesof MDS self-dual codes with odd characteristics and those of almostMDS self-dual codes are constructed explicitly from genus zero andgenus one curves, respectively. More families of self-dual codes areconstructed from algebraic curves of higher genus.
Keywords:
Self-orthogonal codes, self-dual codes, MDS codes, almost MDScodes, optimal codes, algebraic curves, algebraic geometry codes, differentialalgebraic geometry codes
Self-dual codes are one of the most interesting classes of linear codes thatfind diverse applications in cryptographic protocols (secret sharing schemes)introduced in [4, 5, 18] and combinatorics [17]. It is well-known that binaryself-dual codes are asymptotically good [16].MDS codes form an optimal family of classical codes. They are closelyrelated to combinatorial designs [17, p. 328], and finite geometries [17, p. ∗ School of Mathematical Sciences, Anhui University, Hefei, Anhui, 230601, soklin [email protected] n, k, n − k + 1] MDS codeover F q , if 1 < k < q, then n ≤ q + 1 , except when q is even and k = 3 or k = q − , in which cases n ≤ q + 2 . The conjecture was proved by Ball [1]for q a prime. However, for self-dual case, the conjecture may not be true.Due to the reasons mentioned above, MDS self-dual codes have been ofmuch interest to many researchers. As we have already known that determin-ing the parameters of a given linear code is a challenging problem in codingtheory. However, the parameters of an MDS self-dual code are completelydetermined by its length. Constructions of MDS self-dual codes are valuable.For classical constructions of MDS self-dual codes, we refer to [2, 8, 14, 11].Existing families of MDS self-dual codes can be described as follows. Grassl et al. [10] constructed MDS codes of all lengths over F m and of all highestpossible length over finite fields of odd characteristics. Jin et al. [13] provedthe existence of MDS self-dual codes over F q in odd characteristic for q ≡ q a square of a prime for some restricted lengths. Usingthe same technique developed in [13], more families of MDS self-dual codeshave been constructed in [24, 7]. Tong et al. [23] gave constructions of MDSEuclidean self-dual codes through cyclic duadic codes. The families of knownMDS self-dual codes are summarized in Table 1.The discovery of algebraic geometry codes in 1981 was due to Goppa [9],where they were also called geometric Goppa codes. Goppa showed in hispaper [9] how to construct linear codes from algebraic curves over a finitefield. Despite a strongly theoritical construction, algebraic geometry (AG)codes have asymptotically good parameters, and it was the first time thatlinear codes improved the so-called Gilbert-Vasharmov bound. Self-dual AGcodes were studied by Stichtenoth [20] and Driencourt et al. [6], where theyfirst characterized such codes. However, the construction of MDS self-dualAG codes with odd characteristics or almost MDS self-dual AG codes wasnot considered there.On the contrary to the MDS case, almost MDS codes exist more fre-quently, and it is thus worth exploring families of self-dual codes in such acase and those of optimal self-dual codes. In [20], Stichtenoth gave construc-tions of self-orthogonal AG codes (and self-dual AG codes for some specialcases) but did not consider an embedding the self-orthogonal codes into the2able 1: Existing families of MDS self-dual codes, η : the quadratic characterof F qq n References q = 2 m n ≤ qq = p m , p odd prime n = q + 1 [10] q = r n ≤ rq = r , r ≡ n = 2 tr, t ≤ ( r − / q ≡ n ≡ , ( n − | ( q − q ≡ n − | ( q −
1) [23] q ≡ n | ( q − , n < q − q odd ( n − | ( q − , η (1 − n ) = 1 q odd ( n − | ( q − , η (2 − n ) = 1 q = r , r odd n = tr, t even , ≤ t ≤ rq = r , r odd n = tr + 1 , t odd , ≤ t ≤ rq = r s , r odd , s ≥ n = lr, l even , l | ( r −
1) [24] q = r s , r odd , s ≥ n = lr, l even , ( l − | ( r − , η (1 − l ) = 1 q = r s , r odd , s ≥ n = lr + 1 , l odd , l | ( r − , η ( l ) = 1 q = r s , r odd , s ≥ n = lr + 1 , l odd , ( l − | ( r − , η ( l −
1) = η ( −
1) = 1 q = p m , p odd prime n = pr + 1 , r | mq = p m , p odd prime n = 2 p e , ≤ e < m, η ( −
1) = 1 q = p m n | ( q − , ( q − /n even q = p m , m even , r = p s , s | m n = 2 tr ℓ , ≤ ℓ < m/s, ≤ t ≤ ( r − / q = p m , q ≡ n = 2 p ℓ , ≤ ℓ < mq = p m , m even , r = p s , s | m n = (2 t + 1) r ℓ + 1 , ≤ ℓ < m/s, ≤ t ≤ ( r − / ℓ, t ) = ( m/s,
0) [7] q = p m , q ≡ n = p ℓ + 1 , ≤ ℓ ≤ mq = p m ( n − | ( q − , η (2 − n ) = 1 q = p m n = n , p | n , ( n − | ( q − q = p m , q ≡ n = n + 1 , p | n , ( n − | ( q − q = p m , q ≡ n = p r + 1 , ≤ r ≤ m, r | mq = p m , q a square n = n , ( n − | ( q − q = p m , q a square n = n + 1 , ( n − | ( q − q = p m , q a square n = 2 n , n odd , ( n − | ( q − q = p m n = n , n | ( q − q = p m , q ≡ n = n + 1 , n | ( q − q = p m , q ≡ n = 2 p r , ≤ r < m, r | m [19] q = p m , m = 2 m n = ( t + 1) n + 2 , n = p m − , n ≡ , t odd , < t ≤ n + 1 q = p m , m = 2 m n = ( t + 1) n + 2 , n = p m − , n ≡ , < t ≤ n q = p m , q a square n = ( t + 1) n + 2 , n = q − p r +1 even , ≤ r < m, n ( p r +1)2( p r − odd , t odd , ≤ t ≤ p r q = p m , q a square n = ( t + 1) n + 2 , n = q − p r +1 even , ≤ r < m, n ( p r +1)2( p r − even , ≤ t ≤ p r q = p m , q a square n = ( t + 1) n + 2 , n = q − p r − even , ≤ r < m, r | m , ≤ t ≤ p r − F q with q a prime (see Theorem 2) and also give explictconstructions of the cosets of F q with desired properties (see Lemma 10and Lemma 11). Due to Lemma 6 and Lemma 7, new classes of self-dual codes with prescribed minimum distance are constructed. Addition-ally, we construct MDS self-dual codes with new parameters [24 , , ,[32 , , , [26 , , , [42 , , , [50 , , , [24 , , , almostMDS self-dual codes with new parameters [16 , , , [16 , , , [18 , , ,[20 , , , [22 , , , [24 , , and optimal self-dual codes with newparameters [28 , , , [26 , , , [28 , , , [30 , , , [32 , , . The paper is organized as follows: Section 2 gives preliminaries and back-ground on algebraic geometry codes. Section 3 provides explicit constructionsof self-dual codes from various algebraic curves. New families of self-dualcodes are presented as well some numerical examples are also given. We endup with concluding remark in Section 4.
Let F q be the finite field with q elements. A linear code of length n anddimension k over F q , denoted as q -ary [ n, k ] code, is a k -dimensional subspaceof F nq . The (Hamming) weight wt( x ) of a vector x = ( x , . . . , x n ) is thenumber of nonzero coordinates in it. The minimum distance ( or minimumweight) d ( C ) of C is d ( C ) := min { wt( x ) | x ∈ C, x = } . The parameters ofan [ n, k ] code with minimum distance d are written [ n, k, d ]. If C is an [ n, k, d ]code, then from the Singleton bound, its minimum distance is bounded aboveby d ≤ n − k + 1 . A code meeting the above bound is called
Maximum Distance Separable (MDS). A code is called almost
MDS if its minimum distance is one unitless than the MDS case. A code is called optimal if it has the highest pos-sible minimum distance for its length and dimension. The
Euclidean innerproduct of x = ( x , . . . , x n ) and y = ( y , . . . , y n ) in F nq is x · y = P ni =1 x i y i .The dual of C , denoted by C ⊥ , is the set of vectors orthogonal to every4odeword of C under the Euclidean inner product. A linear code C is called self-orthogonal if C ⊂ C ⊥ and self-dual if C = C ⊥ . It is well-known that aself-dual code can only exist for even lengths.We refer to Stichtenoth [21] for undefined terms related to algebraic func-tion fields.Let X be a smooth projective curve of genus g over F q . The field ofrational functions of X is denoted by F q ( X ) . Function fields of algebraiccurves over a finite field can be characterized as finite separable extensionsof F q ( x ). We identify points on the curve X with places of the function field F q ( X ) . A point on X is called rational if all of its coordinates belong to F q . Rational points can be identified with places of degree one. We denote theset of F q -rational points of X by X ( F q ).A divisor G on the curve X is a formal sum P P ∈X n P P with only finitelymany nonzeros n P ∈ Z . The support of G is defined as supp ( G ) := { P | n P =0 } . The degree of G is defined by deg( G ) := P P ∈X n P deg( P ). For two divisors G = P P ∈X n P P and H = P P ∈X m P P , we say that G ≥ H if n P ≥ m P for allplaces P ∈ X .It is well-known that a nonzero polynomial f ( x ) ∈ F q ( x ) can be factorizedinto irreducible factors as f ( x ) = α s Q i =1 p i ( x ) e i , with α ∈ F ∗ q . Moreover, anyirreducible polynomial p i ( x ) corresponds to a place, say P i . We define thevaluation of f at P i as v P i ( f ) := t if p i ( x ) t | f ( x ) but p i ( x ) ( t +1) f ( x ) . For a nonzero rational function f on the curve X , we define the “principal”divisor of f as ( f ) := X P ∈X v P ( f ) P. If Z ( f ) and N ( f ) denotes the set of zeros and poles of f respectively, wedefine the zero divisor and pole divisor of f , respectively by( f ) := P P ∈ Z ( f ) v P ( f ) P, ( f ) ∞ := P P ∈ N ( f ) − v P ( f ) P. Then ( f ) = ( f ) − ( f ) ∞ , and it is well-known that the principal divisor f has degree 0 . We say that two divisors G and H on the curve X are equivalent if G = H + ( z ) for some rational function z ∈ F q ( X ) . G on the curve X , we define L ( G ) := { f ∈ F q ( X ) \{ }| ( f ) + G ≥ } ∪ { } , and Ω( G ) := { ω ∈ Ω \{ }| ( ω ) − G ≥ } ∪ { } , where Ω := { f dx | f ∈ F q ( X ) } , the set of differential forms on X . It is well-known that, for a differential form ω on X , there exists a unique a rationalfunction f on X such that ω = f dt, where t is a local uniformizing parameters. In this case, we define the divisorassociated to ω by ( ω ) = X P ∈X v P ( ω ) P, where v P ( ω ) := v P ( f ) . Through out the paper, we let D = P + · · · + P n , called the ratio-nal divisor, where ( P i ) ≤ i ≤ n are places of degree one, and G a divisor with supp ( D ) ∩ supp ( G ) = ∅ . Define the algebraic geometry code by C L ( D, G ) := { ( f ( P ) , . . . , f ( P n )) | f ∈ L ( G ) } , and the differential algebraic geometry code as C Ω ( D, G ) := { (Res P ( ω ) , . . . , Res P n ( ω )) | ω ∈ Ω( G − D ) } , where Res P ( ω ) denotes the residue of ω at point P. The parameters of an algebraic geometry code C L ( D, G ) is given as fol-lows.
Theorem 1. [21, Corollary 2.2.3] Assume that g − < deg ( G ) < n. Thenthe code C L ( D, G ) has parameters [ n, k, d ] satisfying k = deg( G ) − g + 1 and d ≥ n − deg( G ) . (1)The dual of the algebraic geometry code C L ( D, G ) can be described asfollows.
Lemma 1. [21, Theorem 2.2.8] With above notation, the two codes C L ( D, G ) and C Ω ( D, G ) are dual to each other. C Ω ( D, G ) is determined as follows.
Lemma 2. [21, Proposition 2.2.10] With the above notation, assume thatthere exists a differential form ω satisfying1. v P i ( ω ) = − , ≤ i ≤ n and2. Res P i ( ω ) = Res P j ( ω ) for ≤ i ≤ n. Then C Ω ( D, G ) = a · C L ( D, D − G + ( ω )) for some a ∈ ( F ∗ q ) n . In this section, we will construct self-dual codes from algebraic geometrycodes. Self-dual codes can be constructed directly from Lemma 3 or fromtheir self-orthogonal subcodes by extending the basis of the existing codes.
Lemma 3. [20, Corollary 3.4] With the above notation, assume that thereexists a differential form ω satisfying1. v P i ( ω ) = − , ≤ i ≤ n and2. Res P i ( ω ) = Res P j ( ω ) = a i , ≤ i ≤ n, for some a i ∈ F ∗ q . Then the following statements hold.1. If G ≤ D + ( ω ) , then there exists a divisor G ′ such that C L ( D, G ) ∼ C L ( D, G ′ ) , and C L ( D, G ′ ) is self-orthogonal.2. If G = D + ( ω ) , then there exists a divisor G ′ such that C L ( D, G ) ∼ C L ( D, G ′ ) , and C L ( D, G ′ ) is self-dual. The existence of self-dual algebraic geometry codes can be given as fol-lows.
Proposition 1. [22, Corollary 3.1.49, p.292] With the above notation, as-sume that N = |X ( F q ) | > g. Then there exists a self-dual code with param-eters [ n, n , ≥ n − g + 1] over F q for some n even such that n ≥ N − g − . The following lemma will be applied many times for constructing a q -aryself-dual code of length n (if it exists for such a length).7 emma 4. Let n be an odd positive integer and C a q -ary self-orthogonal codewith parameters [ n, n − ] . Then there exists a self-orthogonal code C withparameters [ n + 1 , n − ] and a self-dual code C ′ with parameters [ n + 1 , n +12 ] such that C ⊂ C ′ ⊂ C ⊥ . Proof.
Let G be the generator matrix of C and C be a self-orthogonal codeobtained from C by lengthening one zero coordinate. Clearly, the code C has parameters [ n + 1 , n − ], and C ⊥ has parameters [ n + 1 , n +12 + 1]. Denote G the generator matrix of C , that is, G = G ...0 . Let x be a nonzero element in the quotient space C ⊥ /C such that x · x = 0 . Then the code C ′ with its following generator matrix G ′ is self-dual withparameters [ n + 1 , n +12 ] : G ′ = G ...0 x . Moreover, we have the following inclusion C ⊂ C ′ ⊂ C ⊥ . Similarly, we have the following embedding.
Lemma 5.
Let n be an even positive integer and C a q -ary self-orthogonalcode with parameters [ n, n − . Then there exists a self-dual code C ′ (if itexists for such a length) with parameters [ n, n ] such that C ⊂ C ′ ⊂ C ⊥ . Lemma 6.
Let X be a smooth projective curve having genus g. Let n be anodd positive integer and D = P + · · · + P n be a divisor on X . Assume thatthere exists a differential form ω satisfying1. v P i ( ω ) = − , for i = 1 , . . . , n and . Res P i ( ω ) = Res P j ( ω )) = a i with a i ∈ F ∗ q for ≤ i, j ≤ n. If G = (2 g − n )2 P ∞ with supp ( G ) ∩ supp ( D ) = ∅ , then there exists a self-orthogonal code C L ( D, G ) with parameters [ n, n − , n +32 − g ] . Moreover, thecode C L ( D, G ) can be embedded into a self-dual [ n + 1 , n +12 , ≥ n +12 − g ] code C ′ (if a self-dual code exists for such a length n ).Proof. Choose U as a subset of F q with its size | U | = n so that ω = dxh , where h ( x ) = Q α ∈ U ( x − α ) , satisfying the above two conditions. Then thedivisor ( ω ) = (2 g − n ) P ∞ − D , and thus 2 G ≤ ( ω ) + D . From Lemma 3and Theorem 1, there exists a self-orthogonal code C L ( D, G ) with parameters[ n, n − , ≥ n +32 − g ]. The second assertion follows from Lemma 4. First notethat C L ( D, G ) ⊥ = a · C L ( D, D − G + ( ω )) (from Lemma 2)= a · C L (cid:16) D, (2 g − n )2 P ∞ (cid:17) (2)We now calculate the lower bound on the minimum distance of the dual code. d ( C L ( D, G ) ⊥ ) ≥ n − (2 g − n )2 (due to (2) and Theorem 1)= n +12 − g. The minumum distance of C ′ follows from the fact that C ′ ⊂ C ⊥L ( D, G ), andthis completes the proof.
Lemma 7.
Let X be a smooth projective curve having genus g. Let n be aneven positive integer and D = P + · · · + P n be a divisor on X . Assume thatthere exists a differential form ω satisfying1. v P i ( ω ) = − , for i = 1 , . . . , n and2. Res P i ( ω ) = Res P j ( ω )) = a i with a i ∈ F ∗ q for ≤ i, j ≤ n. If G = (2 g − n )2 P ∞ with supp ( G ) ∩ supp ( D ) = ∅ , then there exists a self-orthogonal code C L ( D, G ) with parameters [ n, n , n + 1 − g ] .Proof. The result follows from the same reasoning as that in Lemma 6.9 .1 Self-dual codes from projective lines
In this subsection, we will discover new families of MDS self-dual codes basedon the work from [19]. In what follows, we let for a ∈ F q , η ( a ) := 1 if a is asquare in F q , and η ( a ) := − a is not a square in F q . The following two lemmas [19] will be used to construct self-dual codesof genus zero.
Lemma 8. [19, Lemma 6] For G = sP ∞ with s ≤ ⌊ n − ⌋ , if ( h ′ ( P i )) ≤ i ≤ n aresquares in F ∗ q , then C L ( D, G − (1 / √ h ′ )) is an MDS self-orthogonal code. The following lemma is useful for constructing a self-dual code from itsself-orthogonal subcode.
Lemma 9. [19, Lemma 7] Let q ≡ . Assume that G = ( k − P ∞ , n = 2 k + 1 , and ( h ′ ( P i )) ≤ i ≤ n are squares in F ∗ q . Then the q -ary self-orthogonal code C L ( D, G − (1 / √ h ′ )) with parameters [ n, k ] can be embeddedinto a q -ary MDS self-dual [ n + 1 , k + 1] code. Now, we construct MDS self-dual codes from Lemma 8 and Lemma 9.
Theorem 2.
Let q = p m be an odd prime power. If η ( −
1) = η ( n ) = 1 , n | ( q − and n even, then there exists an [2 n +2 , n +1 , n +2] self-dual code over F q . Proof.
Let U n = { α ∈ F ∗ q | α n = 1 } . Let β ∈ F ∗ q such that β n − F q . Put U = U n ∪ β U n ∪ { } , and write h ( x ) = Y β ∈ U ( x − β ) . Then we have that h ′ ( x ) = (( n + 1) x n − x n − β n ) + nx n ( x n − . Consider the following quadratic equation a + b = 1 . (3)For any q , (3) has T = ( q − − a , ± b ) , . . . , ( a T , ± b T ),with ( a i , b i ) = (0 , ± , ( ± , β = n p a i for some 1 ≤ i ≤ t, ( t < T ) . Then we get 1 − β n = 1 − a i = b i which are squares in F ∗ q .
10e have that − , n are squares in F q . Moreover, since β n and ( β n −
1) aresquares in F ∗ q , it implies that h ′ ( β ) is a square in F ∗ q for any β ∈ U. Now, thefact that all the roots of h ( x ) are simple gives rise to a self-orthogonal codewith parameters [2 n + 1 , n, n + 2]. Thus, by Lemma 9, it can be embeddedinto a q -ary self-dual code with parameters [2 n + 2 , n + 1 , n + 2] . Example 1.
We construct MDS self-dual codes with new parameters as fol-lows.1. Taking q = 37 , n = 12 , we obtain a self-dual code over F with param-eters [26 , , .
2. Taking q = 61 , n = 12 , we obtain self-dual code over F with param-eters [26 , , , [42 , , , respectively.3. Taking q = 73 , n = 24 , we obtain a self-dual code over F with param-eters [50 , , . Remark 1.
In the proof of Theorem 2, we have found many values of β i such that − β ni is a square. Furthermore, if there exist β and β such that β n − β n is again a square, then we can construct an MDS self-dual code oflength n + 2 over F q . For example, taking q = 41 , n = 10 and consideringtwo non-zero multiplicative cosets of U n yields a self-dual code over F withparameters [32 , , . The generator matrix of the self-dual code over F isgiven as follows.
20 15 20 11 6 11 22 10 39 15 5 9 20 31 33 4037 5 11 12 3 15 4 10 37 18 35 8 3 26 32 812 29 9 14 13 11 8 30 16 20 17 22 3 9 13 102 17 11 25 14 3 1 27 38 5 1 15 36 2 1 2127 21 21 13 20 7 36 15 29 30 25 20 1 11 2 3239 7 2 1 26 25 5 38 38 13 33 20 17 15 7 3640 39 34 15 18 12 6 28 25 10 21 23 8 35 26 26 I
30 36 28 2 1 11 12 28 2 27 34 35 4 4 20 222 18 5 24 5 40 23 9 34 40 12 34 9 34 33 3120 13 9 12 31 35 37 33 26 37 23 39 29 18 25 1911 19 18 16 38 40 2 29 8 30 30 10 12 2 20 3034 13 10 13 18 28 19 14 28 31 4 34 24 9 31 3524 31 21 40 12 23 25 4 17 27 13 4 31 40 23 3040 31 36 35 28 38 21 31 14 20 16 36 20 37 34 219 10 23 11 36 23 30 9 16 22 27 32 37 26 39 2636 4 32 32 4 4 10 14 12 14 20 30 29 34 8 21 . The two following lemmas play the key role in determining whether thedifference of two special elements in F q is a square or not and also in deter-mining the number of cosets of a multiplicate subgroup of F ∗ q . emma 10. Let q = p m with p an odd prime, n = q − p r +1 and for α i , α j ∈ F q with α i = α j , denote α ij = α ni − α nj . Then for ω a primitive element of F q ,we have the following equality: α ij = ω n ( pr +1)2( pr − α i α j . (4) Proof.
Raising α ij to the power p r − , we get α p r − ij = ( α ni − α nj ) pr α ni − α nj = ( α npri − α nprj ) α ni − α nj = ( α q − − ni − α q − − nj ) α ni − α nj = αni − αnj α ni − α nj = ω n ( pr +1)2 α ni α nj , where the last equality come from the fact that ω q − = − . By taking the ( p r − Lemma 11.
Let q = p m with p an odd prime, r | m , n = q − p r − and for α i , α j ∈ F q with α i = α j , denote α ij = α ni − α nj . Then for ω a primitive element of F q , we have the following: α ij ∈ F p r . (5) Proof.
Raising α ij to the power p r , we get α p r ij = ( α np r i − α np r j ) = ( α q − ni − α q − nj ) = α ni − α nj = α ij . Thus the result follows.
Theorem 3.
Let q = p m be an odd square and n even. Put s = ( t + 1) n.
1. If n ( p r +1)2( p r − is even, then there exists a self-dual code over F q with param-eters [ s, s , s + 1] , with n = q − p r +1 , for ≤ t ≤ p r .
2. If n ( p r +1)2( p r − is odd, then there exists a self-dual code over F q with param-eters [ s, s , s + 1] , with n = q − p r +1 , for t odd and ≤ t ≤ p r .
3. There exists a self-dual code over F q with parameters [ s, s , s + 1] , with n = q − p r − , r | m , for ≤ t ≤ p r − . roof. Let U n be a multiplicative subgroup of F ∗ q of order n , say U n = { u , . . . , u n } . Let α U n , . . . , α t U n be t nonzero cosets of U n , where ( α i ) ≤ i ≤ t will be determined later. Put U = U n ∪ (cid:18) t S i =1 α i U n (cid:19) , and write h ( x ) = Y α ∈ U ( x − α ) . Clearly, all the roots of h ( x ) are simple. The derivative of h ( x ) is given by h ′ ( x ) = nx n − t Y i =1 ( x n − α ni ) + nx n − ( x n − t X i =1 t Y j =1 ,j = i ( x n − α nj ) ! . For 1 ≤ j ≤ t, ≤ s ≤ n , we have h ′ ( u s ) = nu n − s ( α nj − t Q i =1 ,i = j (1 − α ni ) ,h ′ ( α j u s ) = n ( α j u s ) n − ( α nj − t Q i =1 ,i = j ( α nj − α ni ) . For 1 ≤ i, j ≤ t and n = q − p r +1 , we have from (4) α ij = α ni − α nj = ω n ( pr +1)2( pr − α i α j , where ω is a primitive element of F q . Fixing j and taking all the product of α ij for 1 ≤ i ≤ t, i = j , we get that t Y i =1 ,i = j ( α nj − α ni ) = n Y i =1 ,i = j ω n ( pr +1)2( pr − α i α j . Obviously, n and ( u s ) ≤ s ≤ n are squares in F q for q a square. Now, thesquareness of h ′ ( u s ) and h ′ ( α j u s ) depend on the parity of T = n ( p r +1)2( p r − . If T is even, then α i is chosen to be a square element in F q , and thus(1 − α ni ) and ( α nj − α ni ) are square elements in F q due to (4) of Lemma 10.If T is odd, then α i is chosen to be a non-square element in F q , and thus(1 − α ni ) and ( α nj − α ni ) are again square elements in F q due to (4).In conclusion, we have 13. If n ( p r +1)2( p r − is even, then h ′ ( u s ) and h ′ ( α j u s ) are squares in F ∗ q for 1 ≤ s ≤ n and 1 ≤ j ≤ t with t ∈ { , . . . , p r } .2. If n ( p r +1)2( p r − is odd, then h ′ ( u s ) and h ′ ( α j u s ) are squares in F ∗ q for 1 ≤ s ≤ n and 1 ≤ j ≤ t with t odd and t ∈ { , . . . , p r } .For 1 ≤ i, j ≤ t and n = q − p r − , from (5) in Lemma 11, we get that α ij = α ni − α nj ∈ F p r , and hence it is a square if r | m . We have shown that h ′ ( α )is a nonzero square in F q for any α ∈ U, and thus the constructed code isself-dual by Lemma 8. Example 2.
Taking q = 9 , n = − = 8 , t = 2 , we get an MDS self-dualwith parameters [24 , , . These parameters are new. The generator matrixof the code is given as follows. w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w I w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w . Theorem 4.
Let q be an odd prime power with q ≡ , ≤ r 1. If n ( p r +1)2( p r − is odd, then there exists a self-dual code over F q with param-eters [ s, s , s + 1] , with n = q − p r +1 , for t odd and ≤ t ≤ p r . 2. If n ( p r +1)2( p r − is even, then there exists a self-dual code over F q with param-eters [ s, s , s + 1] , with n = q − p r +1 , for ≤ t ≤ p r . 3. There exists a self-dual code over F q with parameters [ s, s , s + 1] , with n = q − p r − , r | m , for ≤ t ≤ p r − . Proof. The proof follows from that of Theorem 3.14able 2: Numbers of rational points of elliptic curvesElliptic curve E ,b,c m E ,b,c ( F m ) m odd q + 1 − √ qy + y = x m ≡ q + 1 − √ qm ≡ q + 1 + 2 √ qy + y = x + x m ≡ , q + 1 + 2 √ qm ≡ , q + 1 − √ qy + y = x + x + 1 m ≡ , q + 1 + 2 √ qm ≡ , q + 1 − √ qy + y = x + bx ( T r m ( b ) = 1) m even q + 1 y + y = x + c ( T r m ( c ) = 1) m ≡ q + 1 + 2 √ qm ≡ q + 1 − √ q In this subsection, we will consider elliptic curves and hyper-elliptic curvesover F q , q even.First, we will consider elliptic curves in Weierstrass form to constructself-dual codes. Let q = p m and an elliptic curve defined by the equation E a,b,c : y + ay = x + bx + c, (6)where a, b, c ∈ F q . Let S be the set of x -components of the affine points of E a,b,c over F q , that is, S a,b,c := { α ∈ F q |∃ β ∈ F q such that β + aβ = α + bα + c } . (7)For q = 2 m , any α ∈ S ,b,c gives exactly two points with x -component α ,and we denote these two points corresponding to α by P (1) α and P (2) α . Thenthe set of all rational points of E ,b,c over F q is { P (1) α | α ∈ S ,b,c } ∪ { P (2) α | α ∈ S ,b,c } ∪ { P ∞ } . The numbers of rational points of elliptic curves E over F q aregiven in Table 2. Lemma 12 (Hilbert’s Theorem 90) . Let q = p m . The equation y p − y = k has solutions over F q if and only if Tr F q / F p ( k ) = 0 . emma 13. Let q = 2 m , m ≥ and q = q . If α is an element in F q , thenTr F q / F ( α ) = 0 , and Tr F q / F ( α + α ) = 0 . Proof. For any α ∈ F q , we haveTr F q / F ( α ) = Tr F q / F (cid:0) Tr F q / F q ( α ) (cid:1) = Tr F q / F ( α + α q )= Tr F q / F ( α ) + Tr F q / F ( α q )= 0 , where the first and second equality come from the properties of the tracefunction and the last one from the fact that α ∈ F q . Since F ∗ q is a multi-plicative group, the second part follows. Proposition 2. Let q = 2 m and q = q . Then there exists a [2 q , q , d ≥ q ] self-dual code over F q . Proof. Consider the elliptic curve defined by E , , : y + y = x + x. From Lemma 13, we get that F q is a subset of S , , . Put U = F q and h ( x ) = Q α ∈ U ( x − α ). Then the residue Res P α ( ω ) = h ′ ( P α ) is a square for any α ∈ U , and by Lemma 3, the constructed code a · C L ( D, G ) is self-dual, where a i = Res P i ( ω ) . Theorem 5. Let q = 2 m and U = { α ∈ F q | Tr ( α + α ) = 0 } . Then thereexists a self-dual code over F q with parameters [2 n, n, d ≥ n ] for ≤ n ≤ | U | . Proof. Let U be defined as in the theorem. Put h ( x ) = Y α ∈ U ( x − α ) . Since any element in F q ( q even) is a square in F q , we conclude that h ′ ( α ) isa nonzero square in F q for any α ∈ U. Consider the elliptic curve defined by E , , : y + y = x + x. U is a subset of S , , . Put D = X α ∈ U ⊂ U (cid:0) P (1) α + P (2) α (cid:1) = P + · · · + P s , s = 2 | U | , G = s P ∞ , ω = dxh . Then the residue Res P α ( ω ) = h ′ ( P α ) is a square for any α ∈ U , and by Lemma3, the constructed code a · C L ( D, G ) is self-dual, where a i = Res P i ( ω ) . Example 3. The elliptic curve E , , : y + y = x + x, has rational points in the set { P ∞ = (1 : 0 : 0) , (1 : 0 : 1) , (1 : 1 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w :1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) } .Put D = P + · · · + P , G = 9 P ∞ . The code C L ( D, G ) is self-dual. The set { x i y j z i + j | ( i, j ) ∈ { (0 , , (0 , , (0 , , (0 , , (1 , , (1 , , (1 , , (2 , , (2 , }} is abasis for C L ( D, G ) , and thus its generator matrix is given by G = w w w w w w ww ww w w w w w w w w w w w w w w w w w ww ww w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w ww w w . By Magma [3], the code with generator matrix a · G is self-dual, and it hasparameters [18 , , over F , where a = ( w , w , w , w , w , w , , , w , w ,w , w , w , w , w , w , w , w ) . This code is an almost MDS code. We also find almost MDS self-dualcodes over F with parameters [20 , , , [22 , , , [24 , , . Corollary 1. Let q = 2 m and U = { α ∈ F q | Tr ( α ) = 0 } . Then there existsa self-dual code over F q with parameters [2 n, n, d ≥ n ] for ≤ n ≤ | U | . Theorem 6. Let q = 2 m , m ≥ and U = { α ∈ F q | Tr ( α ) = 0 } . Thenthere exists a self-dual code over F q with parameters [2 n, n, d ≥ n − for ≤ n ≤ | U | . roof. Let U be defined as in the theorem. Put h ( x ) = Y α ∈ U ( x − α ) . Since any element in F q ( q even) is a square in F q , we conclude that h ′ ( α ) isa nonzero square in F q for any α ∈ U. Consider the hyper-elliptic curve defined by X : y + y = x . (8)From Lemma 12, we get that U is a subset of the solution to (8). Put D = P α ∈ U ⊂ U (cid:16) P (1) α + P (2) α (cid:17) = P + · · · + P s , s = 2 | U | , G = ( s + 1) P ∞ and ω = dxh . Then the residue Res P α ( ω ) = h ′ ( P α ) is a square for any α ∈ U , andby Lemma 3, the constructed code a · C L ( D, G ) is a [ s, s , d ≥ s − 1] self-dualcode, where a i = Res P i ( ω ) . Example 4. The hyper-elliptic curve defined by y + y = x , has rational points in the set { P ∞ = (1 : 0 : 0) , ( w : 0 : 1) , ( w : 1 : 1) , ( w :0 : 1) , ( w : 1 : 1) , ( w : 0 : 1) , ( w : 1 : 1) , ( w : 0 : 1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w :1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w :1) , ( w : w : 1) } . Put D = P + · · · + P , G = 14 P ∞ . The set { x i y j z i + j | ( i, j ) ∈{ (0 , , (0 , , (0 , , (1 , , (1 , , (1 , , (2 , , (2 , , (2 , , (3 , , (3 , , (4 , , (4 , }} is a basis for C L ( D, G ) , and thus its generator matrix G is given by = ww ww ww ww w w w w w w w w w w w w w w w w w w w ww ww ww ww ww w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w ww w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w ww w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w . By Magma [3], the code with generator matrix a · G is self-dual, and it hasparameters [26 , , over F , where a = ( w , w , w, w, w , w , w , w , w ,w , w , w , w , w , w , w , w , w , w , w , w , w , w, w, w , w ) . We also findself-dual codes over F with parameters [28 , , , [30 , , , [32 , , . Next, we will consider hyper-elliptic curves over F q , q = p m with p an oddprime. Theorem 7. Let q = p m and t be a positive odd integer such that gcd ( t, q − 1) = 1 . If η ( n ) = 1 and n | ( q − , then there exists a self-dual code withparameters [2 n, n, d ≥ n + t − ] . Proof. Denote C j = { j × i (mod q − | i = 0 , , . . . } . For θ a primitive elementof F q , let U n = { θ i | i ∈ C q − n } , and label the elements of U n as α , . . . , α n .Under the condition 4 n | ( q − U n is a multiplicative subgroup of F ∗ q of order n. Put h ( x ) = Y α ∈ U n ( x − α ) . Clearly, all the roots of h ( x ) are simple, and the derivative h ′ ( x ) = nx n − ,and thus for any α ∈ U n , we have that h ′ ( α ) is a square. Consider the ellipticcurve defined by X : y = x t . t, q − 1) = 1, the set { x t | x ∈ F q } is in bijection with F q . For any α ∈ U n , there are two places, say P (1) α and P (2) α , arising from x -component α. Put D = P α ∈ U n P (1) α + P (2) α = P + · · · + P s , s = 2 n, G = nP ∞ and ω = dxh . With the choice of α i ∈ U n and β i = α ti , the residue Res P αi ( ω ) = β i h ′ ( α i ) is asquare for any α i ∈ U n , and by Lemma 3, the constructed code a · C L ( D, G )is self-dual, where a i = Res P i ( ω ) . Corollary 2. Let q = p m . Then we have the following:1. if gcd (3 , q − 1) = 1 , η ( n ) = 1 and n | ( q − , then there exists a self-dualcode with parameters [2 n, n, d ≥ n ]; 2. If gcd (5 , q − 1) = 1 , η ( n ) = 1 and n | ( q − , then there exists a self-dualcode with parameters [2 n, n, d ≥ n − . Example 5. The hyper-elliptic curve over F defined by y = x , has rational points in the set { P ∞ = (1 : 0 : 0) , (1 : 1 : 1) , (1 : 4 :1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , (4 :2 : 1) , (4 : 3 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w : 1) , ( w : w ) } . Put D = P + · · · + P and G = 7 P ∞ . The set { x i y j z i + j | ( i, j ) ∈{ (0 , , (0 , , (1 , , (1 , , (2 , , (3 , }} is a basis for C L ( D, G ) , and thus itsgenerator matrix is given by G = w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w . By Magma [3], the code with generator matrix a · G is self-dual, and it hasparameters [12 , , over F , where a = (1 , , w , w , , , w , w , , , w , w ) . By considering curves in higher genus, we can release the gcd conditionin Theorem 7. 20 heorem 8. Let q = p m with p an odd prime.1. If n is odd, η ( n ) = 1 and n | ( q − , then there exists a self-dual codewith parameters [2 n, n, d ≥ n + 2] . 2. If n is even, η ( n ) = 1 and n | ( q − , then there exists a self-dual codewith parameters [2 n, n, d ≥ n + 2] . Proof. Assume that n is odd. Let U n and h ( x ) be defined as in Theorem 7.Consider an algebraic curve given by X : y = x n . Take ω = dxh and G = n − P ∞ . Then by Lemma 3, the code a · C L ( D, G ),where a i = Res P i ( ω ), is self-dual with parameters [2 n, n, n + 2] , and thisproves point 1).For point 2), we put U n = { a | a ∈ F q , a n = 1 } . The rest follows from thesame reasoning as the first part. In this subsection, we will construct self-dual codes over F q from algebraiccurves of high genus.Let q = p m , q = q and X be the Hermitian curve over F q defined by X : y q + y = x q +1 . The Hermitian curve X has genus g = q ( q − , and for any α ∈ F q , x − α has q zeros of degree one in X . All rational points of the curve X different fromthe point at infinity are obtained in this way. Self-orthogonal AG codes fromHermitian curves were already considered in [20]. In what follows, we embedthose codes into the self-dual ones and provide the parameters of the lattercodes. We also construct new families of self-dual codes from this curve. Theorem 9. Let p be an odd prime, q = p m , q = q , g = q ( q − . Put d = s + 1 − g, s ′ = s + 1 , d ′ = s ′ − g. 1. If p | n, ( n − | ( q − , then there exists a q -ary self-dual code withparameters [ s, s , d ≥ d ] (resp. [ s ′ , s ′ , d ≥ d ′ ] ), where s = q n with n even (resp. n odd). . If r | m , then there exists a q -ary self-dual code with parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q p r . 3. If ( n − | ( q − , then there exists a q -ary self-dual code with parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q (2 n − . 4. If n | q − , then there exists a q -ary self-dual code with parameters [ s, s , d ≥ d ] (resp. [ s ′ , s ′ , d ≥ d ′ ] ), where s = q n with n even (resp. n odd).5. If ≤ r < m , then there exists a q -ary self-dual code with parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q (2 p r − . 6. If n = q − , n ≡ , then there exists a q -ary self-dual codewith parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q ( n ( t + 1) + 1) , for t odd, ≤ t ≤ n + 1 . 7. If n = q − , n ≡ , then there exists a q -ary self-dual codewith parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q ( n ( t + 1) + 1) , ≤ t ≤ n . 8. If ≤ r < m and n ( p r +1)2( p r − is odd, then there exists a q -ary self-dual codewith parameters [ s, s , d ≥ d ] (resp. [ s ′ , s ′ , d ≥ d ′ ] ), where s = q ( t +1) n (resp. s = q (( t + 1) n + 1) + 1 ), n = q − p r +1 , for t odd , ≤ t ≤ p r . 9. If ≤ r < m and n ( p r +1)2( p r − is even, then there exists a q -ary self-dual codewith parameters [ s, s , d ≥ d ] (resp. [ s ′ , s ′ , d ≥ d ′ ] ), where s = q ( t +1) n (resp. s = q (( t + 1) n + 1) + 1 ), n = q − p r +1 , for ≤ t ≤ p r . 10. If ≤ r < m , then there exists a q -ary self-dual code with parameters [ s, s , d ≥ d ] (resp. [ s ′ , s ′ , d ≥ d ′ ] ), where s = q ( t + 1) n (resp. s = q (( t + 1) n + 1) + 1 ), n = q − p r − , r | m , for ≤ t ≤ p r − . 11. If t is even such that ≤ t ≤ q , then there exists a q -ary self-dual codewith parameters [ s, s , d ≥ d ] , where s = q ( q t ) . 12. If t is odd such that ≤ t ≤ q , then there exists a q -ary self-dual codewith parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q ( q t ) . 13. If r = p k , k | m, ≤ ℓ < m/k, ≤ t ≤ ( r − / , then there exists a q -aryself-dual code with parameters [ s, s , d ≥ d ] , where s = q (2 tr ℓ ) . 4. If ≤ ℓ < m , then there exists a q -ary self-dual code with parameters [ s, s , d ≥ d ] , where s = q (2 p ℓ ) . 15. If r = p k , k | m, ≤ ℓ < m/k, ≤ t ≤ ( r − / or ( ℓ, t ) = ( m/k, ,then there exists a q -ary self-dual code with parameters [ s ′ , s ′ , d ≥ d ′ ] ,where s = q (2 t + 1) r ℓ . 16. If ≤ ℓ < m , then there exists a q -ary self-dual code with parameters [ s ′ , s ′ , d ≥ d ′ ] , where s = q p ℓ . Proof. It should be noted that each x -component α ∈ F q gives q places ofdegree one. Let U be a subset of { α ∈ F q | β q + β = α q +1 } such that q | U | = s. Put h ( x ) = Y α ∈ U ( x − α ) and ω = dxh . For each case, it is enough to prove that the residue Res P α ( ω ) of ω at place P α is a nonzero square for any α ∈ U , that is, h ′ ( α ) is a nonzero square in F q . Take U as follows. • for 1), U = { α ∈ F q | α n = α } , • for 2), U = { α ∈ F q | α p r = α } , • for 3), U = U n − ∪ α U n − , where U n − = { α ∈ F q | α n − = 1 } and α ∈ F q \ U n − such that 1 − α n − is a square, • for 4), U = { α ∈ F q | α n = 1 } , • for 5), U = U n ∪ α U n ∪ { } , where n = p r − , U n = { α ∈ F q | α n = 1 } and α ∈ F q \ U n such that 1 − α n is a square, • for 6)–10), take U = { } ∪ V or U = V, where V = U n ∪ α U n ∪ · · · ∪ α t U n , U n = { α ∈ F q | α n = 1 } and α , . . . , α t ∈ F q \ U n as in Theorem 3, • for 10)–12), label the elements of F q as a , . . . , a q . For some fixedelement β ∈ F q \ F q , take U = { a k β + a j | ≤ k, j ≤ q } , • for 13)–16), label the element of F r as a , . . . , a r − , take H as an F r -subspace and set H i = H + a i β for some fixed element β ∈ F q \ F r . Put U = H ∪ · · · ∪ H t − or U = H ∪ · · · ∪ H t .23or 1)–5), it can be easily checked that h ′ ( α ) is a square for any α ∈ U. For 6)–10), it has been already checked, in Theorem 3, that h ′ ( α ) is asquare for any α ∈ U. For 11)–12), it was proved in [24, Theorem 2] that h ′ ( α ) is a square forany α ∈ U. For 13)–16), it was proved in [7, Theorem 4] that h ′ ( α ) is a square forany α ∈ U. Example 6. The Hermitian curve defined over F has all rational points inthe set { P ∞ = (1 : 0 : 0) , (0 : 0 : 1) , (0 : w : 1) , (0 : w : 1) , (1 : w : 1) , (1 : w : 1) , (1 : 2 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : 2 : 1) , (2 : w : 1) , (2 : w : 1) , (2 : 2 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : 2 : 1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w : 1) } . Put D = P + · · · + P , G = 15 P ∞ . The code C L ( D, G ) has parameters [27 , , . The set { x i y j z i + j | ( i, j ) ∈ { (0 , , (0 , , (0 , , (0 , , (1 , , (1 , , (1 , , (1 , , (2 , , (2 , , (2 , , (3 , , (3 , }} is a basis for the code C L ( D, G ) , and thus its generatormatrix is given by G = w w ww ww ww ww w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w ww w w w w w w ww ww w w w w w w w w w w w w ww w w w ww w w w ww w w w w w w w ww w w w w w w w w w w w w w w w w w w w w w ww w w ww w w w w ww w w w w ww w w w w w w w w w w w w w w w w w w w w w w w w w w w w ww w ww w w w w w w w ww w w w w . Take G ′ = (cid:18) G g (cid:19) , where g = (0 , , , , , , , , , , , , , , , , , , , , , , , , , , , . By Magma [3], the code with generator matrix a · G ′ isan optimal [28 , , self-dual code with new parameters, where a i = w , ≤ i ≤ . Other parameters from different constructions in Theorem 9 are givenin Table 3. Theorem 10. Let q = p m , q = q be an odd prime power, g = ( q − and s = q q +12 . Then,1. there exists a [ s, s , d ≥ s − g + 1] self-dual code if s is even, and2. there exists a [ s + 1 , s +12 , d ≥ s +12 − g ] self-dual code if s is odd. s from Hermitian curves defined over F s Distance Lower bound Extended length Distance Lower bound1) 3 . . . . − 1) 6 6 16 6 54) 3 . − − − . − − − 5) 3(1 + 1)2 4 4 − − − 6) 3 ((1 + 1)2 + 1) 6 6 16 6 511) 3 (3 . 2) 7 7 − − − Proof. Consider an algebraic curve defined by X : y q + y = x q . The curve has genus g = ( q − . Put U = { α ∈ F q |∃ β ∈ F q such that β q + β = α q } . The set U is the set of x -component solutions to the Hermitian curve whoseelements are squares in F q . There are q +12 square elements in F q , and thisgives rise to q q +12 rational places. Write h ( x ) = Y α ∈ U ( x − α ) and ω = dxh . Then h ( x ) = x n − x , where n = q +12 , and thus h ′ ( x ) = nx n − − 1. Since q is a square, we have that h ′ ( α ) = n − α ∈ U \{ } . Put D = P α ∈ U (cid:16) P (1) α + · · · + P ( q ) α (cid:17) = P + · · · + P s , s = q q +12 . Set G = ( ( g − s ) P ∞ if s is even,( g − s − ) P ∞ if s is odd.Then the residue Res P α ( ω ) = h ′ ( P α ) is a square for any α ∈ U , and by Lemma3, the constructed code a · C L ( D, G ) is self-orthogonal, where a i = Res P i ( ω ) . If s is even, then point 1) follows, otherwise the self-orthogonal code can beembedded into a self-dual code using Lemma 6, and thus point 2) follows.25 xample 7. There exist self-dual codes with parameters [16 , , ≥ , [66 , , ≥ , [176 , , ≥ , [370 , , ≥ , [672 , , ≥ , [1106 , , ≥ , [2466 , , ≥ , [3440 , , ≥ , [7826 , , ≥ .We now calculate the exact distance of the self-dual code over F . The alge-braic curve over F defined by y + y = x has all rational points in the set { P ∞ = (1 : 0 : 0) , (0 : 0 : 1) , (0 : w :1) , (0 : w : 1) , (1 : w : 1) , (1 : w : 1) , (1 : 2 : 1) , (2 : w : 1) , (2 : w : 1) , (2 : 2 :1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w : 1) , ( w : 1 : 1) , ( w : w : 1) , ( w : w :1) } . Put D = P + · · · + P , G = 7 P ∞ . The code C L ( D, G ) has parameters [15 , , .The set { x i y j z i + j | ( i, j ) ∈ { (0 , , (0 , , (0 , , (0 , , (1 , , (1 , , (1 , }} is abasis for the code C L ( D, G ) , and thus its generator matrix is given by G = w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w w . Take G ′ = (cid:18) a · G g (cid:19) , where a = ( w , w , w , , , , , , , , , , , , , g = (0 , w, , , , , , , w , , w , w , w , w , w , . By Magma [3], the code with generator matrix G ′ isa [16 , , self-dual code, which is optimal and has new parameters. Theorem 11. Let q = p m , q = q be an odd prime power, g = ( q − and s = q q − . Then,1. there exists a [ s, s , d ≥ s − g + 1] self-dual code if s is even, and2. there exists a [ s + 1 , s +12 , d ≥ s +12 − g ] self-dual code if s is odd. roof. Consider the same setting as the proof of Theorem 10. Take U ′ = U \{ } , and write h ( x ) = Y α ∈ U ′ ( x − α ) and ω = dxh . The rest follows with the same reasoning as that in Theorem 10. Example 8. There exist self-dual codes with parameters [12 , , , [60 , , ≥ , [168 , , ≥ , [360 , , ≥ , [660 , , ≥ , [1092 , , ≥ , [2448 , , ≥ , [3420 , , ≥ , [7800 , , ≥ . We update parameters of MDS self-dual codes from the previous con-structions in Table 4. In this correspondence, we have constructed new families of optimal q -aryEuclidean self-dual codes from algebraic curves. With the same spirit, con-structing more families of Euclidean self-dual codes from genus zero and genusone curves (over F q with q a prime) is worth considering. Characterizationand constructions of Hermitian self-dual codes from algebraic geometry codesare also valuable. References [1] S. Ball, “On sets of vectors of a finite space in which every subset ofbasis size is a basis,” J. Eur. Soc. 14 (2012), 733-748.[2] K. Betsumiya, S. Georgiou, T. A. Gulliver, M. Harada and C. Koukou-vinos, “On self-dual codes over some prime fields,” Discrete Math. Handbook of Magma Functions , Sydney, 1995.[4] R. Cramer, V. Daza, I. Gracia, J. J. Urroz, G. Leander, J. Marti-Farreand C. Padro, “On codes, matroids, and secure multiparty computationfrom linear secret-sharing schemes,” IEEE Trans. Inform. Theory , vol.54(6), pp. 2647–2657, 2008. 27able 4: MDS self-dual codes of length n over F q , − : no self-dual code existswith such a pair ( n, q ), +: known parameters, ?: unknown parameters, ∗ :new parameters n/q 11 13 16 17 19 23 25 27 29 31 32 37 41 43 47 49 53 61 73 812 − + + + − − + − + − + + + − − + + + + +4 + + + + + + + + + + + + + + + + + + + +6 − + + + − − + − + − + + + − − + + + + +8 + + + + + + + + + + + + + + + + + + + +10 − + + + − − + − + − + + + − − + + + + +12 + 6 + + + + + + + + + + + + + + + + + +14 − + + ? − − + − + − + + + − − + + + + +16 + ? ? + + + + + + + + + + + ? + ? +18 + − − + − + − + + + − − + ? ? + +20 + ? + ? ? + + ? + + + + ? + + +22 − − − ? − ? − + ? + ? ? + ? + ? +24 + ? ? ? + + ? ? + + + ? ? + ∗ − − − + − ? − + ∗ ? − − + + ∗ + +28 + ? ? + ? ? ? ? + ? ? ? +30 − − − + + ? ? − − ? ? + ? +32 + + ? ∗ ? ? ? ? ? ? +34 − − − − − ? ? − − + ? ? ? +36 ? ? ? ? + ? ? + +38 − − − − − + ? − − + ? ? + ?40 ? ? ? ? ? ? ? +42 − − − − − + − − + ? ∗ ? +44 + ? ? ? ? ? ?46 − − − − − − − ? ? ? ? +48 + ? ? ? ? ?50 − − − − − − − + ? ? ∗ +52 ? ? ? +62 − − − − − − − + ? +72 ? ? + [5] S. T. Dougherty, S. Mesnager, and P. Sol´e, “Secret-sharing schemesbased on self-dual codes,” in Proc. Inf. Theory Workshop, May 2008,pp. 338–342.[6] Y. Driencourt and H. Stichtenoth, “A criterion for self-duality of geomet-ric codes,” Communications in Algebra, IEEE Trans. In-form. Theory , vol. 65(9), pp. 5574–5579, 2019.288] S. Georgiou and C. Koukouvinos, “MDS Self-Dual Codes over LargePrime Fields,” Finite Fields and Their Applications, vol. 8, pp. 455–470, 2002.[9] V. D. Goppa, “Algebraico-geometric codes,” Math. USSR-lvz. ISIT 2008 ,Toronto, Canada, July 6 –11, 2008.[11] K. Guenda, “New MDS self-dual codes over finite fields,” Des. CodesCryptogr. (2012) 62:31–42.[12] W. C. Huffman and V. Pless, Fundamentals of Error-Correcting Codes, Cambridge University Press, 2003.[13] L. F. Jin and C. P. Xing, “New MDS self-dual codes from generalizedReed-Solomon codes,” IEEE Trans. Inform. Theory, vol. 63(3) , pp.1434 –1438, 2017.[14] J-L. Kim and Y. Lee, “Construction of MDS self-dual codes over Galoisrings,” Des. Codes Cryptogr. (2007) 45:247–258.[15] J-L. Kim and Y. Lee, “Euclidean and Hermitian self-dual MDS codesover large finite fields,” J. Combin. Theory, Ser. A, vol. 105, pp. 79–95,2004.[16] F. J. MacWilliams, N. J. A. Sloane and J.G. Thompson, “Good self-dualcodes exist,” Discrete Math. , vol. 3, pp. 153–162, 1972.[17] F. J. MacWilliams and N. J. A. Sloane, The Theory of Error-CorrectingCodes, Amsterdam, The Netherlands: North Holland, 1977.[18] J. Massey, “Some applications of coding theory in cryptography,” in Proc. 4th IMA Conf. Cryptogr. Coding, IEEE Trans.Inform. Theory , DOI: 10.1109/TIT.2019.2954877.[20] H. Stichtenoth, “Self-dual Goopa codes,” Journal of Pure and AppliedAlgebra, 55 (1988), pp. 199–211.2921] H. Stichtenoth, “Algebraic function fields and codes,” Springer, 2008.[22] M.A. Tsfasman and S.G. Vladut, “Algebraic-Geometric Codes” Mathe-matics and Its Applications , Springer, 1991.[23] H. Tong and X. Wang, “New MDS Euclidean and Hermitian self-dualcodes over finite fields,” Adv. in Pure Math. , vol. 7, pp. 325–333, May.2017.[24] H. Yan, “A note on the constructions of MDS self-dual codes,”