Next Article in Journal
Passenger Flow Prediction for Rail Transit Stations Based on an Improved SSA-LSTM Model
Previous Article in Journal
Assessing Overall Performance of Sports Clubs and Decomposing into Their On-Field and Off-Field Efficiency
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Linear Codes and Self-Polarity

by
Iliya Bouyukliev
1,*,
Stefka Bouyuklieva
2,
Mariya Dzhumalieva-Stoeva
2 and
Dushan Bikov
3
1
Institute of Mathematics and Informatics, Bulgarian Academy of Sciences, 1113 Sofia, Bulgaria
2
Faculty of Mathematics and Informatics, St. Cyril and St. Methodius University of Veliko Tarnovo, 5003 Veliko Tarnovo, Bulgaria
3
Faculty of Computer Science, Goce Delcev University, 2000 Stip, North Macedonia
*
Author to whom correspondence should be addressed.
Mathematics 2024, 12(22), 3555; https://doi.org/10.3390/math12223555
Submission received: 2 October 2024 / Revised: 10 November 2024 / Accepted: 12 November 2024 / Published: 14 November 2024
(This article belongs to the Special Issue Discrete Mathematics in Coding Theory)

Abstract

:
This work studies projective self-dual (PSD) and self-polar linear codes over finite fields with q elements, where q is a power of a prime. The possible parameters for which PSD codes may exist are presented, and many examples are provided. Algorithms for checking whether a q-ary linear code is self-polar are described. Many PSD and self-polar codes over fields with two, three, four, and five elements with two and three nonzero weights are constructed.

1. Introduction

In the words of Michael Atiyah, duality in mathematics is not a theorem but a “principle” [1]. It appears in many subjects in mathematics and has been adapted and modified in different situations. We use a duality that comes from the finite geometry and apply it to the linear codes.
Whenever an object is equivalent to its own dual, then it is said to be self-dual, but, if it is equal to its dual, it is self-polar. Self-duality and self-polarity can be viewed as different degrees of symmetry. In this work, we use the duality between points and hyperplanes in the projective geometry P G ( k 1 , q ) . Usually, the transform is defined constructively in terms of the projective geometry [2,3,4] by matrices [2,5] or by a characteristic vector [6]. Any point a = ( a 1 , a 2 , , a k ) defines a hyperplane H a , which consists of all the points x = ( x 1 , x 2 , , x k ) such that ( a , x ) = a i x i = 0 . This duality (known as projective duality or Delsarte duality) is useful in the study of two-weight codes (see [2,7,8]). A generalization of the projective duality was provided by Dodunekov and Simonis in [3].
Projective self-dual (PSD) and self-polar codes are related to other combinatorial structures, such as two-weight codes [2], divisible codes, self-dual bent Boolean functions [9], strongly regular graphs [7], association schemes, etc. [10]. This motivates us to study these codes. Furthermore, we associate them with square matrices and, especially in the case of self-polar codes, symmetric matrices.
The main problems related to the equivalence of combinatorial objects refer to answering the question of whether two objects are equivalent, to classifying structures with given properties, to finding automorphism groups or the canonical form, etc. Checking whether a given incidence structure is self-polar is related to these problems. We associate the self-polarity with solving the following problem: can a square matrix be reduced to a symmetric form with only permutations of rows and columns? If so, what is an efficient algorithm for this?
This work studies projective self-dual and self-polar linear codes over a finite field. The family of self-polar codes forms a subclass of the class of PSD codes over F q for a given prime power q. We study two main problems. The first one is to determine the parameters regarding which the existence of a q-ary PSD code is possible. The second is related to the question of how to check whether a given projective self-dual code is self-polar. The first problem is solved with theoretical arguments, and, for some of the obtained families of codes, it is directly established that they consist of self-polar codes. To answer the question from the second problem, we use an algorithmic approach. The first step in this direction is to check whether a square matrix defined in a special way, related to the considered code, can be reduced to a symmetric form by permutations of rows and columns and, if so, to find the corresponding symmetric matrix. The second step is to find a characteristic vector of the code that proves its self-polarity. At the end of the paper, we also present classification results for PSD and self-polar codes with two and three nonzero weights.
This paper is organized as follows. We provide the main definitions in Section 2. Section 3 is devoted to the projective self-dual codes. In that section, we present the possible parameters for which PSD codes may exist and provide many examples. In Section 4, we associate PSD codes with square binary matrices and present an algorithm to check whether such a matrix is a permutation equivalent to a symmetric matrix, thus checking whether the corresponding code is self-polar. Some computational results and applications are provided in Section 5.

2. Preliminaries

Let q be a prime power and F q be a finite field with q elements. A linear q-ary code of length n and dimension k is a subspace of the vector space F q n . If q = 2 , the code is called binary, if q = 3 , the code is ternary, and, if q = 4 , it is quaternary. A k × n matrix G with elements from F q , whose rows form a basis of C is called a generator matrix of the code. If G does not have zero columns, the code has full length, and, if the columns of G are pairwise nonproportional, the code is called projective. In this work, we consider only linear codes of full length as later in the paper under linear code we will mean a code of full length. The columns of the matrix G can be considered as points in the projective geometry P G ( k 1 , q ) . If we put all points of P G ( k 1 , q ) in a matrix S k , q as columns, then S k , q generates the simplex code S k , q of length θ ( k , q ) = q k 1 q 1 .
The (Hamming) weight of a vector v F q n is the number of its nonzero coordinates. If the nonzero codewords of the linear code C have exactly t different weights, C is a t-weight code. The simplex and replicated simplex codes are the only 1-weight linear codes [3]. All nonzero codewords in S k , q have weight q k 1 . The weight enumerator of a linear code of length n is the polynomial W ( y ) = i = 0 n A i y i , where A i is the number of codewords of weight i. The weight enumerator of the simplex code S k , q is W ( y ) = 1 + ( q k 1 ) y q k 1 . The minimum nonzero weight of a codeword in C is called the minimum weight of the code. If C has length n, dimension k, and minimum weight d, it is said to be an [ n , k , d ] q code.
Two linear [ n , k , d ] q codes C 1 and C 2 are equivalent if there is a monomial n × n matrix M and an automorphism of the field γ such that v M γ C 2 for each codeword v C 1 . The pair ( M , γ ) is called an automorphism of the code C if v M γ C for all v C . All automorphisms of C form its automorphism group denoted by Aut ( C ) . The permutation automorphism group PAut ( C ) consists of all permutations of the coordinates that preserve the code. Obviously, PAut ( C ) is a subgroup of the symmetric group S n . We also require a definition for an automorphism of a square matrix. We say that the permutation of the rows of the square matrix A is an automorphism of A if it maps its columns into columns of the same matrix.
Using the matrix S k , q and a generator matrix G of the linear code C, we define a characteristic vector of C.
Definition 1. 
The characteristic vector of [ n , k ] q code C with respect to matrix G is
χ ( C , G ) = ( χ 1 , χ 2 , , χ θ ( k , q ) ) Z θ ( k , q )
where χ i is the number of columns of G that are equal or proportional (with nonzero coefficients) to the i-th column of matrix S k , q .
A code C can have different characteristic vectors depending on the matrix G and the considered generator matrix S k , q of the simplex code S k , q . We fix the matrix S k , q to consist of all vectors in F q k whose first nonzero coordinate is 1, ordered lexicographically. If we permute the columns of the matrix G, we obtain a permutation equivalent code to C having the same characteristic vector. Moreover, from a characteristic vector, one can restore the columns of the generator matrix G, possibly in a different order and/or multiplied by nonzero elements of the field. Therefore, without loss of generality, we can suppose that the columns in G are ordered lexicographically and belong to the set of columns of the matrix S k , q . When the code C and the matrix G are clear from the context, we will write briefly χ . Note that the sum of the coordinates of a characteristic vector of C is equal to the length of the code.
Further, we consider the matrix M k = S k , q T · S k , q , where the multiplication is over F q . The rows of M k are nonproportional codewords in the simplex code S k , q . Since M k T = ( S k , q T · S k , q ) T = S k , q T · S k , q = M k , M k is a symmetric q-ary θ ( k , q ) × θ ( k , q ) matrix. By N ( M k ) , we denote the matrix obtained from M k by replacing all nonzero elements by 1. Calculating the square and the determinant of this matrix, we obtain N ( M k ) 2 = q k 2 ( q J θ ( k , q ) I θ ( k , q ) ) , where I θ ( k , q ) and J θ ( k , q ) are the identity and the all-ones matrix of order θ ( k , q ) , respectively, and det ( N ( M k ) 2 ) = q k + θ ( k , q ) ( k 2 ) . Hence N ( M k ) is an invertible matrix.
We use the matrix N ( M k ) and a characteristic vector of the linear code C to define its projective dual code.
Definition 2. 
Let α and β be rational numbers such that α w i + β is a non-negative integer for any nonzero weight w of a codeword in C. The projective dual code D α , β , k ( C ) of C is the linear code with characteristic vector χ α , β = α χ N ( M k ) + β 1 , where 1 is the all-ones vector of the corresponding length.
As described in [6], the i-th coordinate of χ α , β is equal to α wt ( v i ) + β , where v i C is the i-th row of the matrix S k , q T G .
If two linear codes are equivalent, then their projective dual codes for the given α , β and k are also equivalent [5]. The length of D α , β , k ( C ) is n D = α n q k 1 + β θ ( k , q ) [5]. If C is a projective linear code, then its projective dual code has at most two nonzero weights, namely w 1 = α q k 2 ( q 1 ) n + β q k 1 and w 2 = α q k 2 + w 1 . In the general case, the weights in D α , β , k ( C ) are q k 2 ( α χ i + α ( q 1 ) n + β q , where χ i represents the coordinates of the characteristic vector, i = 1 , , θ ( k , q ) .

3. Projective Self-Dual (PSD) and Self-Polar Codes

The projective self-dual codes were studied first by Dodunekov and Simonis in [3], but they called the codes σ self-dual. We used the term projective self-duality in our work [6], but here we propose to call these codes PSD codes in order to distinguish them from the well-known self-dual codes with respect to orthogonality.
Definition 3. 
The linear code C is projective self-dual (PSD) if it is equivalent to its projective dual code D α , β for some α and β. The code is self-polar if it has a characteristic vector χ such that χ α , β = χ for some α and β.
If C is an [ n , k ] q code with a characteristic vector χ , and t C = ( C | C | | C ) is the code C, repeated t times, then the characteristic vector of t C is t χ and therefore its projective dual for the same α and β = t β is
χ α , t β = α t χ N ( M k ) + t β 1 = t χ α , β .
It follows that, if C is PSD (resp. self-polar), the same is t C . Consider now the code C + 1 = ( C | S k , q ) . This code has a characteristic vector χ + 1 = χ + 1 . Then, its projective dual code D α , β has a characteristic vector
χ + 1 , α , β = α ( χ + 1 ) N ( M k ) + β 1 = χ α , β + α 1 N ( M k ) + ( β β ) 1 = χ α , β + α q k 1 1 + ( β β ) 1 = χ α , β + ( α q k 1 + β β ) 1 .
If we take β = 1 + β α q k 1 , then χ + 1 = χ α , β + 1 , so, if C is PSD (resp. self-polar), the same is C + 1 . Therefore, we will concentrate on linear codes for which the characteristic vector has zero coordinates and the greatest common divisor of the coordinates is 1.
Consider one more code, related to C, namely its projective complementary code C ¯ . If C is a projective code, C ¯ is the code with characteristic vector χ ¯ = 1 χ . If G is the corresponding generator matrix of C, the generator matrix of C ¯ consists of all columns of S k , q that do not belong to G. Then,
χ α , β = α ( 1 χ ) N ( M k ) + β 1 = α 1 N ( M k ) α χ N ( M k ) + β 1 = α q k 1 1 α χ N ( M k ) β 1 + ( β + β ) 1 = ( α q k 1 + β + β ) 1 χ α , β .
We can take β = 1 β α q k 1 , and then, if C is PSD (resp. self-polar), the same is C ¯ . Therefore, for the projective codes of length n and dimension k, it is enough to check for projective self-duality only the codes with n θ k , q / 2 = q k 1 2 ( q 1 ) .
In the case of non-projective codes, for C ¯ , we take the code with a characteristic vector χ ¯ = t 1 χ , where t is the largest integer among the coordinates of χ .
The following theorem provides the possible parameters α and β for which the projective dual D α , β ( C ) could be equivalent to the code C ([3] Proposition 6).
Theorem 1. 
Let C be q-ary [ n , k , d ] projective self-dual code. If C is not a replicated simplex code, then
α = ± q 1 k 2 , β = q 1 1 + q k 1 α n .
After converting formula (2), we obtain
α = ϵ q k 2 1 , β = q 1 1 + q k 1 ϵ q k 2 1 n = q 1 1 + ϵ q k 2 n ,
where ϵ = ± 1 .
It follows that
( i ) α = 1 q k 2 1 , β = q 1 1 + q k 2 n , or ( i i ) α = 1 q k 2 1 , β = q 1 q k 2 1 n .
Since α is a rational number, then q k 2 1 should be integer, so, if k is odd, then q is an even power of a prime. Moreover,
ϵ w q k 2 1 q 1 1 + ϵ q k 2 n Z
for any nonzero weight of a codeword in C. Since gcd ( q k 2 1 , 1 + ϵ q k 2 ) = 1 , the above number is an integer only if q k 2 1 w and ( 1 + ϵ q k 2 ) ( q 1 ) n . Hence, we can write the nonzero weights of the code in the form w = q k / 2 1 a , where a is a positive integer.
If the projective linear code C is projective self-dual, it must be a two-weight code with two nonzero weights w 1 and w 2 = w 1 + α q k 2 . We can calculate the weight distribution of C using the Pless power moments [11]
1 + A 1 + A 2 = q k , w 1 A 1 + w 2 A 2 = q k 1 ( q 1 ) n .
Solving this system with unknowns A 1 and A 2 , we obtain that A 2 = ( q 1 ) n if ϵ = 1 and A 1 = ( q 1 ) n if ϵ = 1 . In both cases, the maximal number of nonproportional codewords with one of the weights (say w) is equal to the length of the code, and, if we put these nonproportional codewords as rows in a matrix, this matrix will be an n × n square matrix. Denote this matrix by M ( G ) . As we mentioned after Definition 2, if v i is the ith row in S k , q T G , then χ α , β , i = α wt ( v i ) + β ; hence, the coordinates of the characteristic vector χ α , β , which are equal to 1, correspond to codewords of C with weight w, and, furthermore, all these coordinates correspond to a maximal set of nonproportional codewords with this weight. As ( χ α , β ) i = 1 shows, the i-th row of the matrix S k , q appears in the considered generator matrix G α , β of the projective dual code, M ( G ) = G α , β T G , and it can also be obtained by intersecting the columns and rows of M k corresponding to the coordinates equal to 1 in the characteristic vectors χ and χ α , β , respectively.
If the code is self-polar, then G α , β = G , and therefore the matrix M ( G ) = G T G is symmetric. This proves the following theorem.
Theorem 2. 
Let C be a projective linear PSD [ n , k , { w 1 , w 2 } ] code with a characteristic vector χ with respect to the generator matrix G. If G α , β is the generator matrix corresponding to the characteristic vector χ α , β , then M ( G ) = G α , β T G is a square n × n matrix whose rows have the same weight w, where w = w 1 or w 2 . Moreover, these rows form a maximal set of nonproportional codewords with this weight in the code C. If C is a self-polar code, the matrix M ( G ) is symmetric.
Consider now a non-projective PSD code of length n and dimension k with a characteristic vector χ with respect to its generator matrix G. Suppose that χ has zero coordinates. If G α , β is the generator matrix that corresponds to the characteristic vector χ α , β , we consider the matrix M ( G ) = G α , β T G . As the code is PSD, this is a square matrix of order n. The following theorem generalizes Theorem 2. The PSD codes are divisible by Δ = q k / 2 1 .
Theorem 3. 
Let C be a PSD [ n , k , d ] q code with a characteristic vector χ with respect to its generator matrix G, and χ α , β defines a code that is equivalent to C. Suppose that χ contains at least one zero coordinate and W ( y ) = 1 + A 1 y w 1 + + A s y w s is the weight enumeration of C, where A i 0 for all i = 1 , , s , s > 1 , w 1 = d , w 2 = d + Δ , , w s = d + ( s 1 ) Δ n . Then, A 2 + 2 A 3 + + ( s 1 ) A s = ( q 1 ) n or ( s 1 ) A 1 + ( s 2 ) A 2 + + A s 1 = ( q 1 ) n . Moreover, if χ α , β = χ , then M ( G ) is a symmetric matrix.
Proof. 
As we mentioned above, if v i is the i-th row in S k , q T G , then ( χ α , β ) i = α wt ( v i ) + β . As χ α , β has zero coordinates, then α wt ( v i ) + β = 0 if wt ( v i ) = d or w s . Take α wt ( v i ) + β = 0 for wt ( v i ) = d , which means that α w 1 + β = 0 . It follows that α w j + β = j 1 , j = 1 , , s .
As ( χ α , β ) i = j shows that the i-th row of the matrix S k , q appears in the considered generator matrix G α , β of the projective dual code repeated j times, the corresponding vector from S k , q T G appears as a row in M ( G ) = G α , β T G also repeated j times. Moreover, i = 1 θ ( k , q ) ( χ α , β ) i = n and therefore A 2 + 2 A 3 + + ( s 1 ) A s = ( q 1 ) n , bearing in mind that in addition to the rows that belong to S k , q T G we must also count all their proportional vectors. Here, we also use the fact that the code C is equivalent to its projective dual, so they share the same weight enumerator. Similarly, if α w s + β = 0 , then ( s 1 ) A 1 + ( s 2 ) A 2 + + A s 1 = ( q 1 ) n .
Obviously, if χ α , β = χ , then the two generator matrices coincide (recall that we take the columns in G in lexicographic order) and therefore M ( G ) = G T G is symmetric. □
Next, we provide some restrictions on the parameters of the PSD codes. We separately consider the two cases presented in (4) for even and odd values of the dimension k.
First, let k = 2 k 1 be even.
( i e )
In this case, α = 1 q k 1 1 and β = q 1 q k 1 + 1 n . Since β is an integer, q k 1 + 1 must divide ( q 1 ) n . If q is even, gcd ( q 1 , q k 1 + 1 ) = 1 and therefore q k 1 + 1 will divide the length n. If q is odd, gcd ( q 1 , q k 1 + 1 ) = 2 and it is enough that n is a multiple of ( q k 1 + 1 ) / 2 . So, we have two subcases:
( i 1 )
Let q be even. Now, β = ( q 1 ) t and n = ( q k 1 + 1 ) t , where t is a positive integer. Since α w + β = a ( q 1 ) t 0 , we have a ( q 1 ) t . Then, the parameters of the code are [ ( q k 1 + 1 ) t , 2 k 1 , q k 1 1 ( q 1 ) t ] .
Applying the Griesmer bound to these parameters, we obtain
( q k 1 + 1 ) t i = 0 2 k 1 1 q k 1 1 ( q 1 ) t q i = i = 0 k 1 1 q k 1 1 i ( q 1 ) t + i = k 1 2 k 1 1 ( q 1 ) t q i k 1 + 1
( q k 1 + 1 ) t ( q k 1 1 ) t + i = 1 k 1 ( q 1 ) t q i
2 t i = 1 k 1 ( q 1 ) t q i k 1 .
According this inequality, t k 1 2 . We will provide some examples.
Example 1. 
Let q = 2 . We are looking for [ ( 2 k 1 + 1 ) t , 2 k 1 , 2 k 1 1 t } ] binary PSD codes for several values of k 1 .
*
k 1 = 2 ) In this case, C is a binary even [ 5 t , 4 , 2 t ] code. The code can be a projective two-weight PSD code only for t < 3 . The parity-check [ 5 , 4 , 2 ] binary code is a projective self-dual two-weight code. Its projective complement is a two-weight [ 10 , 4 , 4 ] code with weight enumerator 1 + 5 y 4 + 10 y 6 . There is at least one self-polar [ 15 , 4 , 6 ] code with weight enumerator W ( y ) = 1 + 5 y 6 + 5 y 8 + 5 y 10 , as an example, which is the code with characteristic vector ( 0 , 1 , 0 , 1 , 2 , 0 , 1 , 0 , 2 , 2 , 2 , 0 , 2 , 1 , 1 ) . This code is interesting also as a code with balanced weight distribution; i.e., it has the same number of codewords for each nonzero weight. This code is not projective and therefore is different from the codes with balanced weight distributions presented in [12].
*
k 1 = 3 ) In this case, C is a binary doubly even [ 9 t , 6 , 4 t ] code, t 2 . There are one [ 18 , 6 , 8 ] and five [ 27 , 6 , 12 ] projective self-dual two-weight codes. Their weight enumerators are 1 + 45 y 8 + 18 y 12 and 1 + 36 y 8 + 27 y 12 , respectively. The complement codes have parameters [ 36 , 6 , 16 ] and [ 45 , 6 , 20 ] .
*
k 1 = 4 ) In this case, C is a binary [ 17 t , 8 , 8 t ] code divisible by 8, t 2 . There is one two-weight [ 51 , 8 , 24 ] code that is PSD and 41 two-weight [ 68 , 8 , { 32 , 40 } ] codes, 29 of which are PSD [13].
*
k 1 = 5 ) In this case, C is a binary [ 33 t , 10 , 16 t ] code divisible by 16, t 3 . There is a two-weight [ 198 , 10 , 96 ] code.
Four families with binary two-weight codes have been studied in [14]. The codes in the family Φ k have parameters [ ( 2 k 1 + 1 ) ( 2 k 1 1 1 ) , 2 k 1 , { 2 2 k 1 2 2 k 1 1 , 2 2 k 1 2 } ] . The presented [ 5 , 4 , 2 ] 2 and [ 27 , 6 , 12 ] 2 two-weight codes belong to this family. The codes in the family Φ k + are projective complementary to the codes from Φ k and have parameters [ ( 2 k 1 + 1 ) t , 2 k 1 , 2 k 1 1 t } ] for t = 2 k 1 1 .
Example 2. 
Let q = 4 . The two-weight codes in this case have parameters [ ( 4 k 1 + 1 ) t , 2 k 1 , { 4 k 1 1 t , 4 k 1 t } ] .
*
k 1 = 2 ) Now, C is a quaternary [ 17 t , 4 , 4 t ] code. According to [13], there are 1 [ 17 , 4 , 12 ] 4 and 38 [ 34 , 4 , 24 ] 4 projective two-weight PSD codes.
*
k 1 = 3 ) In this case, C is a binary doubly even [ 65 t , 6 , 16 t ] code, t 2 .
( i 2 )
Let q be odd. Now, β = q 1 2 t and n = q k 1 + 1 2 t , where t is a positive integer. Since α w + β = a q 1 2 t 0 , we have a q 1 2 t . The parameters of the codes in this case are [ q k 1 + 1 2 t , 2 k 1 , q k 1 1 q 1 2 t ] . According to the Griesmer bound,
q k 1 + 1 2 t i = 0 2 k 1 1 q k 1 1 ( q 1 ) t 2 q i = i = 0 k 1 1 q k 1 1 i q 1 2 t + i = k 1 2 k 1 1 ( q 1 ) t 2 q i k 1 + 1
q k 1 + 1 2 t q k 1 1 2 t + i = 1 k 1 ( q 1 ) t 2 q i
t i = 1 k 1 ( q 1 ) t 2 q i k 1 .
Example 3. 
Let q = 3 . The ternary two-weight codes in this family have parameters [ 3 k 1 + 1 2 t , 2 k 1 , { 3 k 1 1 t , 3 k 1 t } ] . If k 1 = 2 , C is a ternary self-orthogonal [ 5 t , 4 , 3 t ] code, t 2 . There are one [ 10 , 4 , 6 ] 3 , two [ 15 , 4 , 9 ] 3 , and four [ 20 , 4 , 12 ] 3 projective two-weight codes, and all of them are PSD [13]. If k 1 = 3 , C is a ternary [ 28 t , 6 , 18 t ] code, t 2 . The only projective two-weight [ 56 , 6 , 36 ] 3 code is PSD.
( i i e )
In this case, n = q k 2 1 q 1 β = q k 1 1 q 1 β = θ ( k 1 , q ) β = ( q k 1 1 + + q + 1 ) β , β N . Since α w + β = a + β 0 , we have a β . It follows that the nonzero weights of the code belong to the following set of positive integers { q k 1 1 , 2 q k 1 1 , , β q k 1 1 } . This means that, if C is not the replicated simplex code, then β 2 .
If C is a projective PSD two-weight code of length n = θ ( k 1 , q ) β and dimension 2 k 1 , its nonzero weights are q k 1 1 ( β 1 ) and q k 1 1 β . For the binary field, the codes have parameters [ ( 2 k 1 1 ) β , 2 k 1 , { 2 k 1 1 ( β 1 ) , 2 k 1 1 β } ] ; for example, for β = 2 , the parameters are [ 6 , 4 , { 2 , 4 } ] , [ 14 , 6 , { 4 , 8 } ] , [ 30 , 8 , { 8 , 16 } ] , [ 62 , 10 , { 16 , 32 } ] , [ 126 , 12 , { 32 , 64 } ] , etc.
Example 4. 
There are two even [ 6 , 4 , 2 ] 2 codes of full length, namely codes C 1 and C 2 , with characteristic vectors χ 1 , χ 2 , and weight enumerators W 1 and W 2 , respectively, where
χ 1 = ( 2 , 1 , 0 , 1 , 0 , 0 , 0 , 1 , 0 , 0 , 0 , 0 , 0 , 1 , 0 ) , W 1 ( y ) = 1 + 7 y 2 + 7 y 4 + y 6 ,
χ 2 = ( 1 , 1 , 1 , 1 , 0 , 0 , 0 , 1 , 0 , 0 , 0 , 1 , 0 , 0 , 0 ) , W 2 ( y ) = 1 + 6 y 2 + 9 y 4 .
For this length, we take α = 1 / 2 , β = 2 . Since 1 2 · 6 + 2 < 0 , we cannot consider a projective dual code of C 1 , which means that C 1 is not projective self-dual. But, for C 2 , we have
1 2 χ 2 N ( M 4 ) + ( 2 , 2 , , 2 ) = ( 1 , 1 , 1 , 1 , 0 , 0 , 0 , 1 , 0 , 0 , 0 , 1 , 0 , 0 , 0 ) = χ 2 .
Hence, this code is not only PSD but self-polar.
Example 5. 
The codes in the family Φ k from [14] have parameters [ ( 2 k 1 1 ) 2 k 1 1 , 2 k 1 , { 2 2 k 1 2 2 k 1 1 , 2 2 k 1 2 } ] and can be obtained in this case for β = 2 k 1 1 . The two-weight code from the previous example belongs to this family. There are exactly seven inequivalent [ 28 , 6 , { 12 , 16 } ] 2 codes in Φ 6 .
Example 6. 
For a positive integer k 1 and a prime power q, S k 1 , q S k 1 , q is a projective two-weight code with parameters [ 2 q k 1 1 q 1 , 2 k 1 , q k 1 1 ] and weight enumerator W ( y ) = 1 + 2 ( q k 1 1 ) y q k 1 1 + ( q 2 k 1 2 q k 1 + 1 ) y 2 q k 1 1 . Its characteristic vector is
χ = ( 11 1 θ ( k 1 , q ) 10 0 q k 1 10 0 q k 1 10 0 q k 1 ) .
Computing χ α , β = 1 2 k 1 1 χ + 2 = χ , we see that this code is self-polar. Thus, we obtain an infinite family of q-ary projective self-polar codes. If we take the code C t S k 1 , q ( β t ) S k 1 , q , 1 t < β , where t S k 1 , q = ( S k 1 , q | S k 1 , q | | S k 1 , q ) is the concatenation of t copies of S k 1 , q , then C is a 3-weight self-polar code.
We will also provide an example for a projective self-dual 4-weight binary code.
Example 7. 
Let C be the binary [ 12 , 4 , 2 ] code with a generator matrix
G = 100000001000 111111100100 111111100010 111100010001 .
This code has a weight enumerator W ( y ) = 1 + 2 y 2 + y 4 + 4 y 6 + 8 y 8 and characteristic vector (with respect to the given generator matrix)
χ = ( 2 , 1 , 0 , 1 , 0 , 3 , 3 , 1 , 0 , 0 , 0 , 0 , 0 , 0 , 1 ) .
For the projective dual code, we obtain χ = ( 1 , 0 , 1 , 0 , 1 , 3 , 0 , 3 , 1 , 0 , 0 , 0 , 0 , 2 , 0 ) and
G = 000000111111 001111000011 010111000011 111000000100 .
It is easy to verify that these two codes are equivalent, and therefore C is a 4-weight projective self-dual code.
If k is odd ( k 3 ), then q must be an even power of a prime, or q = p 2 s , where p is prime and s is a positive integer. Then, q k / 2 = p s k . Now,
α = ϵ p s ( k 2 ) , β = p 2 s 1 1 + ϵ p s k n ,
and the weights have the form w = p s ( k 2 ) a .
Now, we again consider two cases according to (4).
( i o )
Now, α = 1 p s ( k 2 ) and β = ( p s 1 ) ( p s + 1 ) 1 + p s k n . Since p s k + 1 p s + 1 = θ ( k , p s ) is a positive integer, we have β = ( p s 1 ) n θ ( k , p s ) Z , and thus n = θ ( k , p s ) t , β = ( p s 1 ) t , a ( p s 1 ) t . In this case, the codes have parameters [ p s k + 1 p s + 1 t , k , p s ( k 2 ) ( p s 1 ) t ] .
Example 8. 
Let q = 4 and C be a [ 2 k + 1 3 t , k , 2 ( k 2 ) t ] 4 code. One [ 6 , 3 , 4 ] 4 and one [ 9 , 3 , 6 ] 4 two-weight PSD codes are presented in [13].
( i i o )
If α = 1 p s ( k 2 ) and β = ( p s 1 ) ( p s + 1 ) p s k 1 n = ( p s + 1 ) n θ ( k , p s ) , we have p s k 1 p s 1 Z , but gcd ( p s k 1 p s 1 , p s + 1 ) = 1 . Hence, n = p s k 1 p s 1 t = θ ( k , p s ) t and β = ( p s + 1 ) t for a positive integer t. Since α w + β = a + ( p s + 1 ) t 0 , then a ( p s + 1 ) t .
Example 9. 
Let C again be a quaternary code, p = 2 , s = 1 . In this case, C is a code of dimension k and length ( 2 k 1 ) t . There is one two-weight quaternary [ 7 , 3 , 4 ] 4 code, and it is projective self-dual [13].

4. Self-Polar Codes—Computational Aspects

Let C be a linear PSD [ n , k ] q code with a characteristic vector χ . First, we consider only projective codes, and in such a case the vector χ is binary. To check whether the code C is self-polar, we use the following matrices: N χ = χ N ( M k ) and N χ , α , β = 0 χ χ α , β T N ( M k ) . Obviously, if χ α , β = χ , this matrix is symmetric, as well as the matrix M ( G ) defined in Theorem 2.
We take a PSD code, which means that for some parameters α and β the codes with characteristic vectors χ and χ α , β are equivalent. From the previous section, we know that α and β depend on the code parameters and are fixed for a given PSD [ n , k ] q code. Therefore, to verify that the code is self-polar, we need to prove that there are characteristic vectors of C and its projective dual code C α , β such that the corresponding matrix N χ , α , β is symmetric.
If we consider N χ , α , β as an incidence matrix of an incidence structure, this structure is self-polar if there exists a permutation matrix P such that P N χ , α , β = N χ , α , β T P T [15]. The matrix P permutes the rows of N χ , α , β , and P T permutes the columns of the transpose matrix. According to [16], two projective linear [ n , k ] q codes are equivalent if and only if their characteristic vectors belong to one orbit under the action of Aut k on the set of all characteristic vectors of the projective linear [ n , k ] q codes, where Aut k is the subgroup of the symmetric group S θ ( k , q ) , which consists of all permutation automorphisms of the rows of the matrix N ( M k ) . This means that, if σ Aut k , applying σ to the rows of N ( M k ) , we obtain a matrix whose columns are the same but possibly in a different order. If P is the permutation matrix corresponding to σ , then there is another θ ( k , q ) × θ ( k , q ) permutation matrix Q such that P N ( M k ) = N ( M k ) Q .
Consider the characteristic vector χ P for P Aut k . Then,
α χ P N ( M k ) + β 1 = α χ N ( M k ) Q + β 1 = ( α χ N ( M k ) + β 1 ) Q = χ α , β Q ,
which proves that ( χ P ) α , β = χ α , β Q .
Let P ¯ = 1 0 0 T P and Q ¯ = 1 0 0 T Q . Then,
Q ¯ T N χ , α , β P ¯ = 0 χ P Q T χ α , β T Q T N ( M k ) P = 0 χ P ( χ P ) α , β T N ( M k ) = N χ P , α , β .
Hence, if the code C is self-polar, the matrix N χ , α , β is equivalent to a symmetric matrix.
The above reasoning shows that we need an algorithm to check whether a given square matrix is equivalent to a symmetric matrix.

4.1. An Algorithm for Checking Whether a Given Square Matrix Is Equivalent to a Symmetric Matrix

We only consider binary matrices that are equivalent to their transpose matrices. Let A be a square n × n binary matrix of this type. Since we use canonical forms in the equivalence test, without loss of generality, we can assume that A is in canonical form. Let P n be the group of all n × n permutation matrices. As already mentioned in this paper, we consider the following equivalence in the set M n ( F 2 ) of all n × n binary matrices: two matrices A , B M n ( F 2 ) are equivalent if the matrix B can be obtained after permuting the rows and columns of A. This means that B = P A Q for two permutation matrices P , Q P n . This equivalence corresponds to an action of the group P n × P n on the set M n ( F 2 ) , and the equivalence classes are the orbits under this action. The canonical representative of an orbit is a unique matrix from the orbit, and the canonical form of a matrix is the canonical representative of its equivalence class (orbit). So, all matrices in one equivalence class have the same canonical form. Description and references regarding the canonical form are provided in [16].
Consider the following automorphism group of A:
PAut ( A ) = { ( P 1 , P 2 ) P n × P n : P 1 A P 2 = A } .
If PAut ( A ) is trivial, there is only one pair ( T 1 , T 2 ) P n × P n such that T 1 A T 2 = A T . If A is equivalent to a symmetric matrix, then P 3 A = A T P 3 T for a permutation matrix P 3 . Hence, P 3 A P 3 = A T and T 1 = P 3 = T 2 . It follows that A is equivalent to a symmetric matrix if and only if T 1 = T 2 and this symmetric matrix is T 1 A . If the group PAut ( A ) is not trivial, PAut ( A T ) = { ( P 2 T , P 1 T ) ( P 1 , P 2 ) PAut ( A ) } . If P 3 A = A T P 3 T , then P 3 P 1 A P 2 P 3 T = A T for any ( P 1 , P 2 ) PAut ( A ) . These considerations prove the correctness of the algorithm presented below.
We present the transformation of a matrix to a symmetric form in the following Algorithm 1.
Algorithm 1. Checking for equivalence to a symmetric matrix
Input: A square binary matrix B.
Output: If B is equivalent to a symmetric matrix, the output is B a B ; otherwise, the answer is negative.
  • Compute the canonical form of B, and let this be matrix A.
  • We find the canonical map ( T 1 , T 2 ) and the automorphism group PAut ( A T ) . The canonical map sends the matrix into its canonical form, which is T 1 A T T 2 . If this canonical form is not the matrix A, the given matrix cannot be equivalent to a symmetric matrix. Only if T 1 A T T 2 = A , we continue the algorithm.
  • For all matrices Q for which ( P , Q ) PAut ( A T ) for a matrix P P n , do the following: Check whether the matrix B s = ( Q T 2 ) T A is symmetric. If yes, B is equivalent to the symmetric matrix B s and the algorithm terminates with a positive answer.
  • If ( Q T 2 ) T A is not symmetric for all matrices Q, then B is not equivalent to a symmetric matrix and the algorithm terminates with a negative answer.
The complexity of this algorithm depends on the order of the automorphism group PAut ( A T ) . If the group is not trivial and the matrix B is equivalent to a symmetric matrix, there are actually more symmetric matrices equivalent to B.

4.2. Algorithm for Checking the Self-Polarity

For the following algorithm, we require an equivalence relation in the set of all symmetric binary matrices that is similar to the graph isomorphism. If we consider the symmetric matrices A 1 and A 2 as adjacency matrices of the undirected graphs G 1 and G 2 , respectively, the two graphs are isomorphic if and only if there is a permutation matrix P such that A 2 = P T A 1 P [17]. In this case, we will say that the matrices A 1 and A 2 are graph-equivalent.
It is important to check when the characteristic vector χ has the same weight as some of the rows of the matrix N χ , α , β . The weights of the vector rows in N χ , α , β are
wt ( 0 , χ ) = n , wt ( 0 , u ) = q k 1 , wt ( 1 , u ) = q k 1 + 1 ,
where u is a vector row in N ( M k ) . The possible values of the length n are provided in Section 3. In each of these cases, n cannot be equal to a power of q. But, there are a few possibilities when n = q k 1 + 1 .
  • Let k = 2 k 1 . It is easy to see that, if d is the greatest common divisor of q k 1 + 1 or q k 1 1 with q k 1 + 1 = q 2 k 1 1 + 1 , then d divides q + 1 . If k 1 = 1 , then n = q + 1 , and thus C must be a projective [ q + 1 , 2 ] code. The only such code is the simplex code S 2 , q . Let k 1 2 . In the case ( i 1 ) , if n = ( q k 1 + 1 ) t = n = q k 1 + 1 , then d = q k 1 + 1 q + 1 , which is not possible. If q and t are odd and n = q k 1 + 1 2 t for an odd positive integer t (case ( i 2 ) ), d = q k 1 + 1 2 or q k 1 + 1 , but, in both cases, n q k 1 + 1 .
    If n = q k 1 1 q 1 β , k 1 2 , the needed equality holds only for k 1 = 2 , t = q 2 q + 1 , and n = q 3 + 1 . These codes have parameters [ q 3 + 1 , 4 , { q ( q 2 q ) , q ( q 2 q + 1 ) } ] , and they are complements of the [ q 2 + q , 4 , { q 2 q , q 2 } ] codes (the codes denoted by SU2 in [10] for l = 2 and i = q have these parameters). Since q 2 + q < q 3 + 1 , we can study only the code SU2, for which the first row of the matrix N χ , α , β has a different weight compared to the other rows of the same matrix.
  • Let k be odd, k 3 , q = p 2 s , and n = p s k ± 1 p s ± 1 t . As in the previous case, if d = gcd ( p s k ± 1 p s ± 1 , p 2 s ( k 1 ) + 1 ) , then d q + 1 . But, when n = p s k ± 1 p s ± 1 t = p 2 s ( k 1 ) + 1 , d = p s k ± 1 p s ± 1 p 2 s + 1 , which is impossible for k 3 .
Hence, without loss of generality, we can suppose that wt ( χ ) { q k 1 , q k 1 + 1 } .
Next, we are looking for a characteristic vector χ ( s ) of the self-polar code C such that χ α , β ( s ) = χ ( s ) . Let N χ , α , β be equivalent to the symmetric matrix A ¯ . Without loss of generality, we can consider wt ( χ ) = n q k 1 + 1 (as described above) and can take A ¯ = 0 a a T A , where wt ( a ) = wt ( χ ) . The matrix A is also symmetric and is equivalent to the symmetric matrix N ( M k ) , but we need to check if these two matrices are graph-equivalent. If yes, there is a permutation matrix P such that P T A P = N ( M k ) . Let P ¯ = 1 0 0 T P . For the symmetric matrix P ¯ T A ¯ P ¯ , the following holds:
P ¯ T A ¯ P ¯ = 1 0 0 T P T 0 a a T A 1 0 0 T P = 0 a P P T a T P T A P = 0 a P P T a T N ( M k ) .
Hence, a P is the required characteristic vector.
However, if A and N ( M k ) are not graph-equivalent, we repeat the algorithm with another symmetric matrix B ¯ that is equivalent to N χ , α , β but not graph-equivalent to A ¯ .
The described algorithm proceeds in the following steps:
  • Checking whether the matrix N χ , α , β is equivalent to a symmetric matrix, say A ¯ . If no, the algorithm terminates with the answer that the code is not self-polar. If yes, then we need all symmetric matrices, equivalent to A ¯ , that are representatives of different equivalent classes according to the graph-equivalence.
  • If the matrices A and N ( M k ) are not graph-equivalent, then we take another matrix from the representatives of equivalent classes from the previous step. If neither of these representatives is graph-equivalent to N ( M k ) , the algorithm terminates with negative answer.
  • Let A be graph-equivalent to N ( M k ) , finding a permutation matrix P such that P T A P = N ( M k ) (described in the above paragraph).
  • The vector a P is the needed characteristic vector.
In this algorithm, we need to prove that the codes with characteristic vectors χ and a P are equivalent. Since the first row and column have specific weights, different from the other rows and columns, we have
A ¯ = Q 1 ¯ N χ , α , β Q 2 ¯ = 1 0 0 T Q 1 0 χ χ α , β T N ( M k ) 1 0 0 T Q 2 = 0 χ Q 2 Q 1 χ α , β T Q 1 N ( M k ) Q 2 .
Hence, a = χ Q 2 and P T Q 1 N ( M k ) Q 2 P = N ( M k ) . It follows that Q 2 P Aut k , and therefore a code with characteristic vector χ Q 2 P is equivalent to the considered code C [16].
If the code is not projective, we construct matrices N χ and N χ , α , β in the following way. To obtain matrix N χ , we append N ( M k ) with s more rows, where s is the maximal value of a coordinate in χ . The j-th coordinate of the i-th added row is 1 if χ j i and 0 otherwise. Similarly, we construct N χ , α , β , by expanding N χ by the corresponding number of columns.

5. Applications

The most natural study of code self-polarity is related to projective two-weight codes. The reasons for this are as follows. These codes are related to many other interesting combinatorial structures, such as strongly regular graphs, bent functions, etc. and the self-polarity property has a direct relation to some properties of these objects. For example, some self-polar two-weight codes correspond to self-dual bent functions [6].
Information about SRGs, their properties, and their connection to linear codes can be found in [18]. The parameters of the SRGs associated with the listed projective two-weight binary and ternary codes are also provided in [13]. A strongly regular graph (SRG) is a regular graph G = ( V , E ) with v vertices and degree k such that, for some given non-negative integers λ and μ , every two adjacent vertices have λ common neighbors and every two non-adjacent vertices have μ common neighbors. Such a strongly regular graph is denoted by srg ( v , k , λ , μ ) .
A survey on two-weight codes was provided by Calderbank and Kantor [10]. An overview with additional families and examples was presented in [18].
When studying projective two-weight codes with small parameters, it is found that a large number of them are PSD. It is natural to ask how many of these PSD codes are also self-polar. Therefore, in this section, we examine for self-polarity all the two-weight codes classified in [13]. Along with this, we extend these results with new classification results, such as finding all [ 36 , 4 , 25 ] 5 codes.
It is known that to every two-weight code there corresponds a strongly regular graph with q k vertices. By examining the self-polarity, it was found that some of the codes also correspond to strongly regular graphs with n vertices, where n is the length of the code, and degree equal to one of the weights. The question remains, is there a relationship between the two graphs corresponding to the given code, and what is it?
From the study, it became clear that many non-projective codes are also self-polar. In Section 3, we presented some three- and even four-weight self-polar codes. In this section, we investigate binary and ternary three-weight codes, which are related to the presented projective two-weight codes. More precisely, for a given two-weight [ n , k , { w 1 , w 2 } ] q code, we consider the three-weight codes of the same length and dimension and three weights, w 1 , w 2 , and w 3 .
The classification results were obtained using the program Generation, and the algorithms described in the previous section were implemented on the base of functions from the software package LCEquivalence, v. 1.1. These programs are freely available and can be downloaded from http://www.moi.math.bas.bg/moiuser/~data/Software/QextNewEdition.html (accessed on 1 September 2024).
Most of the binary two-weight codes, provided in Table 1, Table 2 and Table 3, are known, as well as their self-duality. These codes are fully classified in [13], but some examples were previously provided in [10,19,20].
The first columns of the tables contain the parameters of the code, and the second ones contain the numbers of all the inequivalent codes of the corresponding length and dimension. In the third columns, we put the weight enumerators of the codes, but if there are no PSD codes they are omitted. PSD codes exist for all parameters of two-weight codes but not for all studied cases of three-weight codes. After the weight enumerators, the number of PSD and self-polar codes of the corresponding parameters are provided. The last columns of the tables contain additional information concerning the particular code. It is indicated which of the codes correspond to a certain example of q, k 1 , and t (Section 3).
In the following example, we provide more details about one of the two-weight self-polar codes.
Example 10. 
Let C be the binary [ 18 , 6 , 8 ] code. There exists one code with these parameters and it is a self-polar code. The weight enumerator of C is W ( y ) = 1 + 45 y 8 + 18 y 12 . The generator matrix for which C and its dual code have the same characteristic vector is
G = 000000111111111111 001111000000001111 000011000011110011 010100000100110111 111111001101010011 011101010010010001 .
The complementary code C ¯ is a binary [ 45 , 6 , 20 ] code with weight enumerator W ( y ) = 1 + 18 y 20 + 45 y 24 , and it has a generator matrix
G ¯ = 000000000000000000000000011111111111111111111 000000000000011111111111100000000111111111111 000001111111100000011111100001111000000111111 001110000111100011100111101110011000111000011 010010011001100100100001110010101011011001100 110100101010101001001010110110110101101010101 .
Recall that the columns of G ¯ are all columns of S 6 , 2 , which does not belong to the matrix G. As we proved in the previous section, C ¯ is also a self-polar code.
Using G, we obtain the following symmetric matrix:
M ( G ) = G T G = 111111001101010011 110110011011110101 101101011111001101 111001011011111010 110011001110101111 101110011100111110 000000111111111111 011101101101101110 111111110010101100 101011110110011011 011110101110011101 111100110001011111 010111111000111011 110101100111111001 001111111111110000 011011111011000111 100111110101100111 111010100111110110 .
Each row and column of G T G has weight 12. What is more, in this case, the main diagonal also has 12.
The studied three-weight codes are listed in Table 4 and Table 5. In the binary case, we are looking for codes with weights d, d + t , d + 2 t , when the codes are divisible by t. The PSD and self-polar codes with these parameters have weight enumerators W ( y ) = 1 + A 1 y d + A 2 y d + t + A 3 y d + 2 t , such that either A 2 + 2 A 3 = n or 2 A 1 + A 2 = n .
Example 11. 
We consider one [ 7 , 3 , 2 ] quaternary three-weight code that is self-polar. Its weight enumerator is 1 + 3 z 2 + 15 z 4 + 45 z 6 . The generator matrix G and the matrix G T G have the following structures:
G = 0111111 1000123 0233222
M ( G ) = G T G = 1000123 0200222 0033000 0033000 1200301 2200013 3200130
The third and fourth columns of G are equal. This corresponds to two equal rows in G T G .
We list some new projective two-weight codes over F 5 . Classification results, as well as the number of PSD and self-polar codes, are provided in Table 6.
Finally, in Table 7, we list the parameters of some known SRGs that are derived from two-weight self-polar codes.

6. Conclusions

In this paper, we present an extended study on the projective self-dual (PSD) and self-polar codes. The self-polar code can be used for constructing other combinatorial structures, such as strongly regular graphs (SRGs), association schemes, bent Boolean functions, etc.
Two algorithms, connected to the problem of the self-polarity, are proposed. The first algorithm checks whether a binary square matrix can be reduced to a symmetric matrix by row and column permutations. If so, the algorithm provides the symmetric matrix (or matrices) itself. The second algorithm concerns checking the self-polarity of a PSD code. If one code is self-polar, then the algorithm returns such a generator matrix that provides one and the same characteristic vector of the code and its dual.
Using these two algorithms and the provided theoretical properties, the self-polarity of some projective two-weight (PTW) codes over fields with two, three, four, and five elements is investigated. It is shown that some of the known strongly regular graphs can be constructed using self-polar codes. The research is extended by constructing and testing for the self-polarity regarding some non-projective linear codes with three different weights. The parameters for which no PSD codes were found are not listed in the tables above, but all the studied structures are available online.
Finally, we will pose two open problems:
  • In our examples, if there exists a projective PSD code of length n for which the number of codewords of the weight w is equal to ( q 1 ) n and there are also integers λ and μ according to the parameters ( n , w , λ , μ ) listed in Chapter 12 in [18], then there exists a strongly regular ( n , w , λ , μ ) graph. Does this apply to all projective PSD codes with these properties?
  • To investigate for self-polarity, other combinatorial structures are applied using the presented algorithms.

Author Contributions

Conceptualization, I.B. and S.B.; methodology, I.B. and S.B.; software, I.B.; validation, I.B., S.B., M.D.-S. and D.B.; formal analysis, I.B. and S.B.; investigation, I.B., S.B., M.D.-S. and D.B.; resources, I.B., S.B., M.D.-S. and D.B.; data curation, I.B., M.D.-S. and D.B.; writing—original draft preparation, S.B. and M.D.-S.; writing—review and editing, S.B. and M.D.-S.; visualization, S.B. and M.D.-S.; supervision, I.B.; project administration, I.B. and S.B.; funding acquisition, I.B. All authors have read and agreed to the published version of the manuscript.

Funding

The work of the first author is partially supported by the Bulgarian Ministry of Education and Science, grant no. DO1-325/01.12.2023 for NCHDC. The work of second and fourth authors is partially supported by Bulgarian National Science Fund, grant number KP-06-H62/2/13.12.2022.

Data Availability Statement

All studied structures are available at http://www.moi.math.bas.bg/moiuser/~data/Results/LinearCodes/psd.html (accessed on 27 September 2024). For classification of linear codes, we use the program Generation, available at http://www.moi.math.bas.bg/moiuser/~data/Software/QextNewEdition.html (accessed on 1 September 2024 ). Equivalence check was conducted by using the program LCequivalence, available at http://www.moi.math.bas.bg/moiuser/~data/Software/QextNewEditionLCequiv.html (accessed on 1 September 2024).

Conflicts of Interest

The authors declare no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
PTWprojective two-weight
PSDprojective self-dual
SRGstrongly regular graph

References

  1. Atiyah, M. Duality in Mathematics and Physics. In Michael Atiyah Collected Works; Oxford University Press: Oxford, UK, 2014; Volume 7, pp. 215–240. [Google Scholar]
  2. Brouwer, A.E.; Van Eupen, E. The correspondence between projective codes and 2-weight codes. Des. Codes Crypt. 1997, 11, 262–266. [Google Scholar] [CrossRef]
  3. Dodunekov, S.; Simonis, J. Codes and projective multisets. Electron. J. Combin. 1998, 5, 1–23. [Google Scholar] [CrossRef] [PubMed]
  4. Nogin, D. Weight/multiplicity duality. In Proceedings of the Sixth International Workshop, Algebraic and Combinatorial Coding Theory, Pskov, Russia, 6–12 September 1998; pp. 195–198. [Google Scholar]
  5. Bouyukliev, I. Classification of Griesmer Codes and Dual Transform. Discret. Math. 2009, 309, 4049–4068. [Google Scholar] [CrossRef]
  6. Bouyukliev, I.; Bouyuklieva, S. Dual transform and projective self-dual codes. Adv. Math. Commun. 2024, 18, 328–341. [Google Scholar] [CrossRef]
  7. Delsarte, P. Weights of linear codes and strongly regular normed spaces. Discret. Math. 1972, 3, 47–64. [Google Scholar] [CrossRef]
  8. Hill, R. Caps and codes. Discret. Math. 1978, 22, 111–137. [Google Scholar] [CrossRef]
  9. Carlet, C.; Danielsen, L.E.; Parker, M.G.; Solé, P. Self-dual bent functions. Int. J. Inform. Coding Theory 2010, 1, 384–399. [Google Scholar] [CrossRef]
  10. Calderbank, A.R.; Kantor, W.M. The geometry of two-weight codes. Bull. London Math. Soc. 1986, 18, 97–122. [Google Scholar] [CrossRef]
  11. Huffman, W.C.; Pless, V. Fundamentals of Error-Correcting Codes; Cambridge University Press: Cambridge, UK, 2003. [Google Scholar]
  12. Langevin, P.; Zanotti, J.P. Linear codes with balanced weight distribution. Appl. Algebra Eng. Comm. Comput. 1995, 6, 299–307. [Google Scholar] [CrossRef]
  13. Bouyukliev, I.; Fack, V.; Willems, W.; Winne, J. Projective two-weight codes with small parameters and their corresponding graphs. Des. Codes Cryptogr. 2006, 41, 59–78. [Google Scholar] [CrossRef]
  14. Bouyukliev, I.; Bouyuklieva, S.; Pashinska-Gadzheva, M. On some families of codes related to the even linear codes meeting the Grey–Rankin bound. Mathematics 2022, 10, 4588. [Google Scholar] [CrossRef]
  15. Brouwer, A.E.; Cameron, P.J.; Haemers, W.H.; Preece, D.A. Self-dual, not self-polar. Discret. Math. 2006, 306, 3051–3053. [Google Scholar] [CrossRef]
  16. Bouyukliev, I.; Bouyuklieva, S. About Code Equivalence—A Geometric Approach. In New Horizons in Differential Geometry and Its Related Fields; Adachi, T., Hashimoto, H., Eds.; World Scientific: Singapore, 2022; pp. 91–103. [Google Scholar]
  17. Godsil, C.; Royle, G. Algebraic Graph Theory; Springer: New York, NY, USA, 2001; ISBN 0-387-95241-1. [Google Scholar]
  18. Brouwer, A.E.; Van Maldeghem, H. Strongly Regular Graphs; Cambridge University Press: Cambridge, UK, 2022. [Google Scholar]
  19. Hamada, N.; Helleseth, T. A characterization of some {3v2+v3,3v1+v2;3,3}-minihypers and some [15,4,9;3]-codes with B2 = 0. J. Stat. Plann. Infer. 1996, 56, 129–146. [Google Scholar] [CrossRef]
  20. Tonchev, V.D. The uniformly packed binary [27,21,3] and [35,29,3] codes. Discrete Math. 1996, 149, 283–288. [Google Scholar] [CrossRef]
Table 1. Binary two-weight codes.
Table 1. Binary two-weight codes.
CodeNumberWeight EnumeratorsPSDSelf-PolarAdditional Information
[ 5 , 4 , 2 ] 1 1 + 10 z 2 + 5 z 4 11Ref. [13], Example 1: k 1 = 2 , t = 1
[ 6 , 4 , 2 ] 1 1 + 6 z 2 + 9 z 4 11[10]
[ 12 , 4 , 6 ] 1 1 + 12 z 6 + 3 z 8 10
[ 14 , 6 , 4 ] 1 1 + 14 z 4 + 49 z 8 11[10]
[ 18 , 6 , 8 ] 1 1 + 45 z 8 + 18 z 12 11Example 1: k 1 = 3 , t = 2
[ 21 , 6 , 8 ] 2 1 + 21 z 8 + 42 z 12 22[10]
[ 27 , 6 , 12 ] 5 1 + 36 z 12 + 27 z 16 54Refs. [10,20], Example 1: k 1 = 3 , t = 3
[ 28 , 6 , 12 ] 7 1 + 28 z 12 + 35 z 16 76Refs. [10,14,20], Example 6: k 1 = 3
[ 56 , 6 , 28 ] 1 1 + 56 z 28 + 7 z 32 1-the code may be self-polar
[ 30 , 8 , 8 ] 1 1 + 30 z 8 + 225 z 16 11[10]
[ 45 , 8 , 16 ] 2 1 + 45 z 16 + 210 z 24 22[10]
[ 51 , 8 , 24 ] 1 1 + 204 z 24 + 51 z 32 11Ref. [13], Example 1: k 1 = 4 , t = 3
[ 60 , 8 , 24 ] 12 1 + 60 z 24 + 195 z 32 1211[10]
[ 68 , 8 , 32 ] 41 1 + 187 z 32 + 68 z 40 2927Ref. [13], Example 1: k 1 = 4 , t = 4
Table 2. Ternary two-weight codes.
Table 2. Ternary two-weight codes.
CodeNumberWeight EnumeratorsPSDSelf-PolarAdditional Information
[ 10 , 4 , 6 ] 1 1 + 60 z 6 + 20 z 9 11Ref. [13], Example 3: k 1 = 2 , t = 1
[ 12 , 4 , 6 ] 2 1 + 24 z 6 + 56 z 9 22
[ 15 , 4 , 9 ] 2 1 + 50 z 9 + 30 z 12 20Refs. [13,19], Example 3: k 1 = 2 , t = 3
[ 16 , 4 , 9 ] 4 1 + 32 z 9 + 48 z 12 44
[ 20 , 4 , 12 ] 4 1 + 40 z 12 + 40 z 15 44Ref. [13], Example 3: k 1 = 2 , t = 2
[ 11 , 5 , 6 ] 1 1 + 132 z 6 + 110 z 9 00
[ 55 , 5 , 36 ] 1 1 + 220 z 36 + 22 z 45 00[8]
[ 56 , 6 , 36 ] 1 1 + 616 z 36 + 112 z 45 11Ref. [8],Example 3: k 1 = 3 , t = 2
Table 3. Quaternary two-weight codes.
Table 3. Quaternary two-weight codes.
CodeNumberWeight EnumeratorsPSDSelf-PolarAdditional Information
[ 6 , 3 , 4 ] 1 1 + 45 z 4 + 18 z 6 11Ref. [13], Example 8: k = 3 , t = 2
[ 7 , 3 , 4 ] 1 1 + 21 z 4 + 42 z 6 11Ref. [13], Example 9: k = 3 , t = 1
[ 9 , 3 , 6 ] 1 1 + 36 z 6 + 27 z 8 11Ref. [13], Example 8: k = 3 , t = 3
[ 10 , 4 , 4 ] 1 1 + 30 z 4 + 225 z 8 11
[ 15 , 4 , 8 ] 2 1 + 45 z 8 + 210 z 12 22
[ 17 , 4 , 12 ] 1 1 + 204 z 12 + 51 z 16 11Ref. [13], Example 2: k 1 = 2 , t = 1
[ 20 , 4 , 12 ] 7 1 + 60 z 12 + 195 z 16 76
[ 25 , 4 , 16 ] 19 1 + 75 z 16 + 180 z 20 1913
[ 30 , 4 , 20 ] 68 1 + 90 z 20 + 165 z 24 6634
[ 34 , 4 , 24 ] 84 1 + 153 z 24 + 102 z 28 3833Ref. [13], Example 2: k 1 = 2 , t = 2
[ 35 , 4 , 24 ] 231 1 + 105 z 24 + 150 z 28 17957
[ 40 , 4 , 28 ] 481 1 + 120 z 28 + 135 z 32 31593
Table 4. Binary three-weight codes.
Table 4. Binary three-weight codes.
CodeNumberWeight EnumeratorsPSDSelf-PolarAdditional Information
[ 15 , 4 , 6 ] 1 1 + 2 z 6 + 11 z 8 + 2 z 10 10Example 1: k 1 = 2 , t = 3
2 1 + 3 z 6 + 9 z 8 + 3 z 10 20
6 1 + 4 z 6 + 7 z 8 + 4 z 10 42
4 1 + 5 z 6 + 5 z 8 + 5 z 10 21
4 1 + 6 z 6 + 3 z 8 + 6 z 10 11
[ 20 , 4 , 8 ] 2 1 + 1 z 8 + 8 z 10 + 6 z 12 20Example 1: k 1 = 2 , t = 4
3 1 + 2 z 8 + 6 z 10 + 7 z 12 10
6 1 + 3 z 8 + 4 z 10 + 8 z 12 10
[ 18 , 6 , 8 ] 1 1 + 46 z 8 + 16 z 12 + 1 z 16 11Example 1: k 1 = 3 , t = 2
[ 27 , 6 , 12 ] 3 1 + 37 z 12 + 25 z 16 + 1 z 20 33Example 1: k 1 = 3 , t = 3
5 1 + 38 z 12 + 23 z 16 + 2 z 20 55
5 1 + 39 z 12 + 21 z 16 + 3 z 20 43
2 1 + 40 z 12 + 19 z 16 + 4 z 20 22
1 1 + 41 z 12 + 17 z 16 + 5 z 20 11
1 1 + 42 z 12 + 15 z 16 + 6 z 20 11
[ 36 , 6 , 16 ] 11 1 + 28 z 16 + 34 z 20 + 1 z 24 77Example 1: k 1 = 3 , t = 4
109 1 + 29 z 16 + 32 z 20 + 2 z 24 2726
479 1 + 30 z 16 + 30 z 20 + 3 z 24 5148
1627 1 + 31 z 16 + 28 z 20 + 4 z 24 9488
2888 1 + 32 z 16 + 26 z 20 + 5 z 24 110104
3715 1 + 33 z 16 + 24 z 20 + 6 z 24 124118
2764 1 + 34 z 16 + 22 z 20 + 7 z 24 8882
1628 1 + 35 z 16 + 20 z 20 + 8 z 24 5953
516 1 + 36 z 16 + 18 z 20 + 9 z 24 2119
216 1 + 37 z 16 + 16 z 20 + 10 z 24 2015
24 1 + 38 z 16 + 14 z 20 + 11 z 24 11
20 1 + 39 z 16 + 12 z 20 + 12 z 24 33
3 1 + 41 z 16 + 8 z 20 + 14 z 24 11
Table 5. Ternary three-weight codes.
Table 5. Ternary three-weight codes.
CodeNumberWeight EnumeratorsPSDSelf-PolarAdditional Information
[ 15 , 4 , 9 ] 1 1 + 52 z 9 + 26 z 12 + 2 z 15 10
[ 16 , 4 , 6 ] 4 1 + 2 z 6 + 28 z 9 + 50 z 12 44
5 1 + 4 z 6 + 24 z 9 + 52 z 12 55
4 1 + 6 z 6 + 20 z 9 + 54 z 12 32
3 1 + 8 z 6 + 16 z 9 + 56 z 12 22
1 1 + 10 z 6 + 12 z 9 + 58 z 12 11
1 1 + 12 z 6 + 8 z 9 + 60 z 12 00
[ 20 , 4 , 9 ] 7 1 + 2 z 9 + 36 z 12 + 42 z 15 75
23 1 + 4 z 9 + 32 z 12 + 44 z 15 1512
26 1 + 6 z 9 + 28 z 12 + 46 z 15 126
28 1 + 8 z 9 + 24 z 12 + 48 z 15 2014
12 1 + 10 z 9 + 20 z 12 + 50 z 15 52
6 1 + 12 z 9 + 16 z 12 + 52 z 15 33
2 1 + 14 z 9 + 12 z 12 + 54 z 15 00
1 1 + 16 z 9 + 8 z 12 + 56 z 15 11
[ 20 , 4 , 12 ] 5 1 + 42 z 12 + 36 z 15 + 2 z 18 54Example 2. k 1 = 2 , t = 2
10 1 + 44 z 12 + 32 z 15 + 4 z 18 85
4 1 + 46 z 12 + 28 z 15 + 6 z 18 42
5 1 + 48 z 12 + 24 z 15 + 8 z 18 31
2 1 + 50 z 12 + 20 z 15 + 10 z 18 20
1 1 + 52 z 12 + 16 z 15 + 12 z 18 11
Table 6. Two-weight codes over F 5 .
Table 6. Two-weight codes over F 5 .
CodeNumberWeight EnumeratorsPSDSelf-Polar
[ 12 , 4 , 5 ] 1 1 + 48 z 5 + 576 z 10 11
[ 18 , 4 , 10 ] 1 1 + 72 z 10 + 552 z 15 11
[ 24 , 4 , 15 ] 7 1 + 96 z 15 + 528 z 20 77
[ 26 , 4 , 20 ] 1 1 + 520 z 20 + 104 z 25 10
[ 30 , 4 , 20 ] 38 1 + 120 z 20 + 504 z 25 3833
[ 36 , 4 , 25 ] 547 1 + 144 z 25 + 480 z 30 441160
[ 39 , 4 , 30 ] 8 1 + 468 z 30 + 156 z 35 80
Table 7. Strongly regular graphs corresponding to PTW codes.
Table 7. Strongly regular graphs corresponding to PTW codes.
SRG Parameters ( v , k , λ , μ ) PTW ParametersWeight Enumerators
(25,16,9,12) [ 25 , 4 , 16 ] 4 1 + 75 z 16 + 180 z 20
(27,16,10,8) [ 27 , 6 , 12 ] 2 1 + 36 z 12 + 27 z 16
(28,12,6,4) [ 28 , 6 , 12 ] 2 1 + 28 z 12 + 35 z 16
(36,25,16,20) [ 36 , 4 , 25 ] 5 1 + 144 z 25 + 480 z 30
(45,16,8,4) [ 45 , 8 , 16 ] 2 1 + 45 z 16 + 210 z 24
(56 45 36 36) [ 56 , 6 , 36 ] 3 1 + 616 z 36 + 112 z 45
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Bouyukliev, I.; Bouyuklieva, S.; Dzhumalieva-Stoeva, M.; Bikov, D. Linear Codes and Self-Polarity. Mathematics 2024, 12, 3555. https://doi.org/10.3390/math12223555

AMA Style

Bouyukliev I, Bouyuklieva S, Dzhumalieva-Stoeva M, Bikov D. Linear Codes and Self-Polarity. Mathematics. 2024; 12(22):3555. https://doi.org/10.3390/math12223555

Chicago/Turabian Style

Bouyukliev, Iliya, Stefka Bouyuklieva, Mariya Dzhumalieva-Stoeva, and Dushan Bikov. 2024. "Linear Codes and Self-Polarity" Mathematics 12, no. 22: 3555. https://doi.org/10.3390/math12223555

APA Style

Bouyukliev, I., Bouyuklieva, S., Dzhumalieva-Stoeva, M., & Bikov, D. (2024). Linear Codes and Self-Polarity. Mathematics, 12(22), 3555. https://doi.org/10.3390/math12223555

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop