You are on page 1of 37

a

r
X
i
v
:
1
3
0
6
.
0
9
5
7
v
1


[
c
s
.
I
T
]


5

J
u
n

2
0
1
3
DUAL CODES OF PRODUCT SEMI-LINEAR CODES
LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Abstract. Let Fq be a nite eld with q elements and denote by an auto-
morphism of Fq. In this paper we revisit some main properties of module skew
codes in the non-commutative ring Fq[X, ], and then we apply the theory to
the case of some linear codes invariant by a semi-linear map of F
n
q
for n 2.
Introduction
Recently there has been a lot of interest on algebraic codes in the setting of skew
polynomial rings which form an important family of non-commutative rings. Skew
polynomials rings have found applications in the construction of algebraic codes,
where codes are dened as ideals (submodules) in the quotient rings (modules) of
skew polynomials rings. The main motivation for considering these codes is that
polynomials in skew polynomial rings exhibit many factorizations and hence there
are many more ideals in a skew polynomial ring than in the commutative case.
Furthermore, the research on codes in this setting has resulted in the discovery of
many new codes with better Hamming distance than any previously known linear
code with same parameters.
Inspired by the recent works [2], [3] and [4], we revisit in this paper from a theo-
retical point of view some main properties of the module skew codes and we adapt
this theory to the case of some linear codes invariant by a semi-linear transforma-
tion.
1. Notation and background material
Let F
q
be a nite eld with q elements and denote by an automorphism of F
q
.
Consider the ring structure dened on the following set:
R := F
q
[X; ] = {a
n
X
n
+... +a
1
X +a
0
| a
i
F
q
and n N} .
The addition in R is dened to be the usual addition of polynomials and the multi-
plication is dened by the basic rule X a = (a)X for any a F
q
and extended to
all elements of R by associativity and distributivity. The ring R is known as skew
polynomial ring and its elements are skew polynomials. Moreover, it is a left and
right Euclidean ring whose left and right ideals are principals.
Let f = X
n

n1
i=0
f
i
X
i
R be a polynomial of degree n and denote by
: F
n
q
R/Rf the linear transformation which sends a vector (c
0
, ..., c
n1
) F
n
q
to a polynomial c =

n1
i=0
c
i
X
i
of R. We will always assume that the constant
term f
0
of f is nonzero.
2010 Mathematics Subject Classication. Primary: 12Y05, 16Z05; Secondary: 94B05, 94B35.
Key words and phrases: nite elds, dual codes, skew polynomial rings, semi-linear maps.
1
2 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Following [2], we dene via the map some linear codes C F
n
q
using skew
polynomial rings R.
Denition 1. An f-module -code (or simply a module -code) C is a linear code
in F
n
q
which corresponds via to a left R-submodule Rg/Rf R/Rf in the basis
1, X, ..., X
n1
, where g is a right divisor of f in R. The length of the code C is
n = deg(f) and its dimension is k = deg(f) deg(g). In this case we say that
the code C is of type [n, k]
q
. For simplicity, we will denote this code C = (g)
k
n,
.
Moreover, if the minimum distance of the code is d, then we say that the code C is
of type [n, k, d]
q
. When there will not be any confusions, we will call an f-module
-code simply a module -code.
The following proposition characterizes a module -code in terms of a group of
semi-linear automorphisms.
Proposition 2. A linear code C in F
n
q
is an f-module -code if and only if C
is invariant under the semi-linear map A
c
, where : F
n
q
F
n
q
is dened by
((c
0
, ..., c
n1
)) := ((c
0
), ..., (c
n1
)), and A
c
is the matrix
_
_
_
_
_
0 1
.
.
.
.
.
.
0 1
f
0
f
1
. . . f
n1
_
_
_
_
_
Proof. If the linear code C is an f-module -code (g)
k
n,
, then

n1
i=0
c
i
X
i
Rg/Rf
implies X

n1
i=0
c
i
X
i
Rg/Rf, where
X
n1

i=0
c
i
X
i
= [(c
n2
) +(c
n1
)f
n1
]X
n1
+...+
(1) + [(c
0
) +(c
n1
)f
1
]X + [(c
n1
)f
0
].
This shows that the code is invariant under A
c
.
Conversely, assume that C is a linear code invariant by A
c
. Note that (C)
is an abelian group with respect to the sum in R/Rf. Now, take an element
c = (c
0
, ..., c
n1
) =
n1

i=0
c
i
X
i
(C).
Then by (1) we get
X c = ((c
0
, ..., c
n1
) A
c
) (C).
By induction, we deduce that X
h
c (C) for all h 0. Therefore, (C) is a left
ideal of R/Rf, that is, there exists a polynomial g such that (C) = Rg/Rf is a
left R-submodule Rg/Rf R/Rf in the basis 1, X, ..., X
n1
.
Remark 3. From the proof of the above result, we can easily deduce that X
k

(v) = ((v)( A
c
)
k
) for all v F
n
q
and k N.
Let us recall here that if F
q
is a nite eld with q = p
s
elements, then the
map

: F
q
F
q
dened by

(a) = a
p
is an automorphism on the eld F
q
which
xes the subeld with p elements. This automorphism

is called the Frobenius
automorphism and it has order s. Moreover, it is also known that the cyclic group it
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 3
generates is the full group of automorphisms of F
q
, i.e. Aut(F
q
) =<

>. Therefore,
any Aut(F
q
) is dened as
(a) :=

t
(a) = a
p
t
,
where a F
q
and t is an integer such that 0 t s.
1.1. An immersion map for an f-module -code. In this section we will give
an algorithm to show that there exists always a suitable integer m n such that
X
m
1 is a left multiple of f R. This will allow us to construct an immersion
map of the code space F
n
q
into an F
m
q
which will be useful for nding duals codes
of module -codes.
Let f = X
n

n1
i=0
f
i
X
i
R and consider the right division
X
n
1 = f q
n
+r
n
,
where q
n
, r
n
R and 0 deg r
n
< deg f. Assume that r
n
is not equal to zero,
otherwise we are done.
Let k be an integer such that k > n and consider again the right divisions
X
k
1 = f q
k
+r
k
,
where q
k
, r
k
R and 0 deg r
k
< deg f. Since there are at most q
deg r
k
+1
distinct
polynomials r
k
, we see that for some k
2
> k
1
n we get r
k1
= r
k2
. Thus we obtain
that
X
k1
(X
k2k1
1) = (X
k2k1
1) X
k1
= f (q
k2
q
k1
).
Put q

:= q
k2
q
k1
and note that q

= 0 R. This shows that X = 0 is a root of


f q

. Since f(0) = 0, we deduce that q

(0) = 0. Hence q

= q
1
X for some q
1
R.
Thus we have
(X
k2k1
1) X
k1
= f q
1
X
and since R has not nonzero zero divisors, we can deduce that
(X
k2k1
1) X
k11
= f q
1
where q
1
R. By an inductive argument, we can conclude that
X
k2k1
1 = f q

for some q

R. This shows that there exists always an integer t n such that


X
t
1 = f q
f
for some nonzero q
f
=

mn
i=0
q
i
X
i
R.
From now on, we denote by m the minimum integer such that m n and X
m
1
is a right multiple of f, i.e.
(*) m := min
_
i N | X
i
1 = f p for some p R
_
.
In this case, we write
(**) X
m
1 = f q
f
.
Moreover, by the above construction we have
n m q
n
+n 2.
Lemma 4. Dene
m

:= min
_
j N | X
j
1 = p f

for some p R
_
,
where f

:= 1

n
i=1

i
(f
ni
)X
i
R. Then m

= m.
4 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Proof. In order to prove the statement, we need the following isomorphism of rings
: R R
dened as (

t
i=0
a
i
X
i
) :=

t
i=0
(a
i
)X
i
. Let X
m
1 = f q
f
. By [2, Lemma
1(1)] we know that
X
m
1 = (1 X
m
)

= (f (q
f
))

= q

for some q

R. This implies that m m

.
On the other hand, let X
m

1 = q
f
f

. By [2, Lemma 1] we see that


X
m

1 = (1 X
m

= ((q
f
) f

=
=
m

n
((f

) q

=
m

n
(
n
(f)) q

=
m

(f) q

for some q

R. Hence we get
X
m

1 =
m

(X
m

1) =
m

(
m

(f) q

) = f
m

(q

),
i.e. m

m. This gives m

= m.
By using the computer algebra system Magma [1], in line with Lemma 4 the
following MAGMA program allows us to nd the integer m as in () for any poly-
nomial f R.
Program 1:
// Define the finite field with "a" elements
a:= ... ;
F<w>:=GF(a);
// Define the skew polynomial ring and
//the automorphism: a=p^t, q=1,...,t
R<X>:=TwistedPolynomials(F:q:= ... );
// The polynomial "1+w*X+w^2*X^2"
// is written as R![1,w,w^2] and f1
// must be f^{*} as defined in Lemma 4
f1:=R![ ... , ... , ... ];
n:=Degree(f1);
// Calculate m
for i in [n.. a^n+n-2] do
if GCD(X^i-1,f1) eq f1 then
printf "m=";
i;
break;
end if;
end for;
Remark 5. If is the identity automorphism of F
q
, then the minimal polynomial of
A
c
is equal to f R. Let m

:= min
_
i N | A
i
c
= I
_
and note that the polynomial
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 5
X
m

1 is satised by A
c
. Therefore, it follows that there exists a polynomial
q
f
=

mn
i=0
q
i
X
i
R such that X
m

1 = f q
f
. This gives m = m

, that is,
m = min
_
i N | A
i
c
= I
_
.
The following example shows that Remark 5 does not hold in general when is
not equal to the identity of F
q
.
Example 6. In F
3
4
, where F
4
= F
2
[] with
2
++1 = 0, consider the polynomial
f = X
3
+X + 1 associated to the matrix
A
c
:=
_
_
0 1 0
0 0 1
1 0
_
_
and dene (x) = x
2
for any x F
4
. By the following
Program 2:
F:=GF(4);
A := Matrix(F, 3, 3, [0,0,1,1,0,F.1,0,1,0]);
for i in [1..21] do i, A^i;
end for;
we see that min
_
i N | A
i
c
= I
_
= 21. Moreover, we obtain that
X
21
1 = f q +r,
where
q = X
18
+
2
X
16
+X
15
+X
14
+X
13
+X
10
+
2
X
8
+X
7
+X
6
+X
5
+X
2
+
2
and
r = X
2
+
2
X + = 0.
This gives m = min
_
i N | A
i
c
= I
_
. By applying in this case Program 1, we have
Program 3:
a:= 4;
F<w>:=GF(a);
R<X>:=TwistedPolynomials(F:q:=2);
f1:=R![1,0,w^2,1];
n:=Degree(f1);
for i in [n.. a^n+n-2] do
if GCD(X^i-1,f1) eq f1 then
printf "m=";
i;
break;
end if;
end for;
which gives m = 8(< 21). Hence
X
8
1 = (X
3
+X + 1) q
f
with q
f
= X
5
+
2
X
3
+X
2
+X + 1.
Then we have the following results.
6 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Lemma 7. Let m as in () and let P be the mm matrix
_
_
_
_
_
0 1
.
.
.
.
.
.
0 1
1 0 . . . 0
_
_
_
_
_
.
Denote by q
f
:= (q
0
, ..., q
mn
, 0, ..., 0) F
m
q
, where the q
i
s are the coecients of
q
f
R as in (). Then there exists a commutative diagram
F
n
q
i
//

F
m
q

R
n
j
//
R
m
such that

i = j , where R
n
:= R/Rf, R
m
:= R/R(X
m
1), i(v) := vQ with
Q the matrix
_
_
_
_
_
_
q
f
( q
f
)( P)
( q
f
)( P)
2
...
( q
f
)( P)
n1
_
_
_
_
_
_
and j(a +Rf) := (a q
f
) +R(X
m
1) for any a R.
Proof. This follows from the linearity of the maps i, j, and

by considering the
canonical basis of F
n
q
.
Proposition 8. With the same notation as in Lemma 7, we have
i((c)( A
c
)
k
) = (i(c))( P)
k
for any c F
n
q
and k N.
Proof. Let c F
n
q
. By Lemma 7 and Remark 3, we have the two following commu-
tative diagram:
c
i
//

i(c)

(c)
j
//
j((c))
where j((c)) =

(i(c)), and
(c)( A
c
)
k
i
//

i((c)( A
c
)
k
)

X
k
(c)
j
//
j(X
k
(c))
where j(X
k
(c)) =

(i((c)( A
c
)
k
)). Since

is an isomorphism, by the
commutative diagram of Lemma 7, we obtain
i((c)( A
c
)
k
) = (

)
1
(j(X
k
(c))) =
= (

)
1
(X
k
(c) q
f
) = (

)
1
(X
k
j((c))) =
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 7
= (

)
1
(X
k

(i(c))) = (

)
1

((i(c))( P)
k
),
that is, i((c)( A
c
)
k
) = (i(c))( P)
k
for any k N.
Remark 9. The maps i and j in Lemma 7 are injective. Moreover, Proposition 8
shows that the image via i of an f-module -code in F
n
q
is a module -cyclic code
in F
m
q
, where m is dened as in () (or as in Remark 5).
Let s be the order of . From the above results, we can deduce the following two
corollaries.
Corollary 10. With the same notation as above, let m = as +r, with 0 r < s.
Then ( q
f
)
r
= q
f
.
Proof. Since X
m
1 = f q
f
and f, q
f
are monic polynomials, by [2, Lemma 2(2)]
we see that X
m
= 1 +(q
f
)
m
f. Since ( P)
m
=
m
P
m
=
m
and
s
is the
identity, from the following commutative diagram
e
1
( A
c
)
m
i
//

i(e
1
)( P)
m

X
m
= 1
j
//
j(1) = q
f
we conclude that
q
f
= (

)
1
(q
f
) = i(e
1
)( P)
m
= ( q
f
)
m
= ( q
f
)
r
.

Corollary 11. With the same notation as above, if


(f
0
, f
1
, ..., f
n1
)
t
= (f
0
, f
1
, ..., f
n1
)
for every integer t such that 0 < t < s, then s divides m.
Proof. Since X
m
1 = f q
f
, from Corollary 10 it follows that
f q
f
= X
m
1 = (X
m
1)
m
= (f)
m
(q
f
)
m
= (f)
m
q
f
,
i.e. f = (f)
m
. Let m = as +r with 0 r < s.
Assume now that r = 0. Then we get f = (f)
m
= (f)
r
, that is,
(f
0
, f
1
, ..., f
n1
)
r
= (f
0
, f
1
, ..., f
n1
)
for some 0 < r < s, but this is a contradiction. Thus r = 0 and s divides m.
Example 12. In F
5
4
, where F
4
= F
2
[] with
2
+ +1 = 0 and is the Frobenius
map, consider the following two polynomials:
(1) f = X
5
+X
3
+X
2
+ 1;
(2) g = X
5
+X
2
+ 1.
Note that in both cases the hypothesis of Corollary 11 is not satised. By applying
Program 1 with f1 := R![1, 0, 1, 1, 0, 1] and g1 := R![1, 0, 0, 1, 0, 1], we obtain m =
12, 31, respectively.
8 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Finally, let us give also some upper bounds and estimations about the integer m
in () when is the identity of F
q
.
Let GL
n
be the linear group of matrices n n with coecients in F
q
. From [11, p.
3] we know that
|Stab
GLn
(U)| =
|GL
n
|
|G
q
(k, n)|
,
where G
q
(k, n) is the grassmannian variety over F
q
and Stab
GLn
(U) is the stabilizer
of any U G
q
(k, n). Since
|GL
n
| =
n1

i=0
(q
n
q
i
)
and
|G
q
(k, n)| =
(q
n
1)(q
n
q)...(q
n
q
k1
)
(q
k
1)(q
k
q)...(q
k
q
k1
)
,
we obtain that
|Stab
GLn
(U)| =
(q
k
1)(q
k
q)...(q
k
q
k1
)

n1
i=0
(q
n
q
i
)
(q
n
1)(q
n
q)...(q
n
q
k1
)
=
(*) =
n1

i=k
(q
n
q
i
)
k1

j=0
(q
k
q
j
).
This allows us to prove the following upper bound for m.
Lemma 13. Suppose that = id, where id is the identity automorphism of F
q
.
Then
m min
g|f
_
_
_
n1

i=k
(q
n
q
i
)
k1

j=0
(q
k
q
j
) | k = dim(g)
n,id
_
_
_
.
Proof. Let g be any right divisor of f in R. By Proposition 2 we deduce that the f-
module code (g)
n,id
is invariant with respect to A
c
. Thus < A
c
> Stab
GLn
((g)
n,id
)
and since m := | < A
c
> |, the statement follows easily from (*).
Remark 14. Let F
q
K be an extension of F
q
such that f =

n
i=1
(X a
i
) with
a
i
K. If m
i
:= min
_
h
i
| a
hi
i
= 1
_
, then m = lcm(m
1
, ..., m
n
).
Remark 15. Let p := Char(F
q
). If the polynomial f has a root of multiplicity
2, then X
m
1 has a root of multiplicity 2. This shows that gcd(m, p) = 1
and since p is a prime number, we get m 0 mod p.
The next result gives a more simple computation of m.
Proposition 16. Denote by

f :=
1
(X
n
f) and let
k := min
_
h N {0} |

fA
h
c
= e
1
_
.
Then m = n +k. In particular, we have deg q
f
= k.
Proof. For any h = 1, ..., n, we have
e
h
A
n+k
c
= (((e
h
)A
nh+1
c
)A
k
c
)A
h1
c
= (((e
n
)A
c
)A
k
c
)A
h1
c
=
= ((

f)A
k
c
)A
h1
c
= (e
1
)A
h1
c
= e
h
.
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 9
Hence A
n+k
c
= I and for the minimality of m we deduce that m n +k. Further-
more, since A
m
c
= I we get
e
1
= (((e
1
)A
n1
c
)A
c
)A
mn
c
= ((e
n
)A
c
)A
mn
c
=

fA
mn
c
,
that is,

fA
mn
c
= e
1
. So, by denition of k we can conclude that k m n, i.e.
m n +k.
Let p
0
be the period of det A
c
. Since A
m
c
= I, it follows that (det A
c
)
m
= 1,
i.e. m 0 mod p
0
with p
0
the period of det A
c
. This gives immediately also the
following
Proposition 17. Denote by B := A
p0
c
. Let m

be the minimum integer such that

fB
m

=

f, where

f :=
1
(X
n
f). Then m = p
0
m

. In particular, we have
deg q
f
= p
0
m

n.
When = id, all the above results produce the following
Algorithm 1:
Input: f
Dene a
0
:= det A
c
;
Compute the period p
0
of a
0
;
Dene B := A
p0
c
;
Find the rational canonical form B

of B;
For any diagonal block B
i
, i = 1, ..., s, of B

compute m

i
= min
_
h | B
h
i
= I
_
.
Output: m = lcm(m

1
, ..., m

s
) p
0
.
a:= ... ;
F<w>:=GF(a);
P<x>:=PolynomialRing(F);
// Define the polynomial f
f:= ... ;
d:=Degree(f);
A:=CompanionMatrix(f);
e:=Determinant(A);
// Calculate the period of a_0
for i in [1.. a] do
b:=e^i;
if b is eq 1 then
printf "period = ";
i;
p:=i;
break;
end if;
end for;
// Define the matrix B
B:=A^p;
10 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


// Find the rational canonical form B
C,D,E:=PrimaryRationalForm(B);
// Calculate the m_is
n:=#E;
for j in [1.. n] do
g:=E[j][1];
H:=CompanionMatrix(g);
h:=Degree(g);
I:=IdentityMatrix(F,h);
for i in [1.. a^(h^2)] do
K:=H^i;
r:=Rank(K-I);
if r eq 0 then
printf "period of polynomial ";
j;
printf " = ";
i;
break;
end if;
end for;
end for;
2. Generalities on module -codes
In this section we revisit some main properties of f-module -codes, as duals codes,
construction methods, coding and decoding.
2.1. Duals of an f-module -code. In [2] the authors prove that the Euclidean
dual of a module -code is a module -code if and only if it is a -constacyclic
code. Moreover, they establish that a module -code which is not -constacyclic
code is a shortened -constacyclic code and that its Euclidean dual is a punctured
-constacyclic code. This enables them to give a form of the parity-check matrix
for module -codes.
Let us only observe here that there exists an alternative method to nd a parity-
check matrix for any module -code. The following result allows us to obtain
directly a form of the parity-check matrix for any module -code C which is useful
to deduce also the generator matrix of C.
Proposition 18. Let C = (g)
k
n,
be a module -code. For any integer i such that
0 i k 1, write in R
X
nk+i
= q
i
g +r
i
, with 0 deg r
i
< n k.
Denote by T the following matrix
T :=
_
_
_
_
_

nk
(
1
(r
0
))

nk
(
1
(r
1
))
.
.
.

nk
(
1
(r
k1
))
_
_
_
_
_
,
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 11
where
nk
is the projection map onto the rst n k coordinates, i.e.

nk
(v
1
, ..., v
nk
, v
nk+1
, ..., v
n
) := (v
1
, ..., v
nk
).
Then a parity check matrix H of C is given by
H :=
_
I
nk
T
t
_
,
where I
nk
is the (n k) (n k) identity matrix and T
t
is the transpose matrix
of T.
Proof. Since deg r
i
< n k, note that

1
(X
nk+i
r
i
) C
are linearly independent for 0 i k 1. Thus
_
T I
k
_
is a generator matrix for C. Since (C

= C, this implies that the matrix H as


in the statement is a parity check matrix for the code C.
Remark 19. The above result holds also for any module (, )-code (see [3]), where
is a derivation of F
n
q
.
The following MAGMA program gives the list of all the reminders r
i
of Propo-
sition 18 which we need to construct the parity check matrix H as in the above
result.
Program 4:
a:= ... ;
F<w>:=GF(a);
R<X>:=TwistedPolynomials(F:q:=...);
g:=R![...,...,...];
n:= ...
d:=Degree(g);
for i in [0.. n-d-1] do
e:=R![1];
for j in [1.. d+i] do
e:=e*R![0,1];
end for;
a,b:=Quotrem(e,g);
b;
end for;
In what follows we study two other kind of dual codes, the Quasi-Euclidean
and the Hermitian dual codes, and we investigate some of their properties and
connections between them and the Euclidean dual codes.
12 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


2.1.1. Quasi-Euclidean dual codes. Let
f = X
n

n1

i=0
f
i
X
i
R
be a monic polynomial of degree n. By Lemma 7, we know that there exists an
injective map i : F
n
q
F
m
q
with m n. Denote by I the image of i and by
the semi-linear map P, where P is the m m permutation matrix of Lemma
7. Dene B := QQ
t
, where M
t
is the transpose of a matrix M, and note that B is
a symmetric matrix.
Let r be the rank of the matrix B and observe that
rkB := r = n dim(Ker Q
t
I)
with 0 r n.
Remark 20. When r = 0, we see that B is the null matrix and in this case Q
represents the generator matrix of a self-orthogonal -cyclic code of dimension n in
F
m
q
.
Denition 21. Let C be a linear code in F
n
q
. We denote by

the quasi-euclidean
scalar product on F
n
q
dened by a

b := aBb
t
for any a, b F
n
q
and by C

the
linear quasi-euclidean dual code of C with respect to

, i.e.
C

:=
_
x F
n
q
| x

c = 0 for every c C
_
.
Proposition 22. Let C be a linear code in F
n
q
. Then we have
(i) C

= (C B)

.
(ii) dimC

= dimC

+ dim(C Ker B) dimC

;
(iii) C

B = C

(Im B);
(iv) C (C

.
Proof. (i) To prove C

= (C B)

, we observe that
w (C B)

w (cB) = 0, c C
wB
t
c
t
= 0, c C
wBc
t
= 0, c C
w

c = 0, c C
w C

.
(ii) This follows easily from
dim(C B) = dimC dim(C Ker B)
and dimC

= n dim(C B).
(iii) If x C

B, then x Im B and x =

c

B with

c

. Hence for every


c C we get
x c =

c

B c =

c

c = 0,
i.e. C

B C

(Im B).
On the other hand, let y C

(Im B). Then y = vB C

for some v F
n
q
.
Thus for any c C we have
v

c = vBc
t
= y c = 0,
that is, C

(Im B) C

B.
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 13
(iv) Let x C. Then for every

c

by (i) we have
x

= xB

t
= (xB)

c

= 0,
i.e. C (C

.
Corollary 23. Let C be a linear code in F
n
q
. If r = n, then we have
(j) C

= C

B
1
;
(jj) dimC

= dimC

;
(jjj) (C

= C.
Proof. Parts (j) and (jj) follow from Proposition 22(ii) and (iii). As to (jjj), it is
sucient to note that (C

= (C

B
1
and then
dim(C

= dim(C

= dim((CB)

= dim(CB) = dimC.

Remark 24. When r = n, from Corollary 23 we know that C

= C

B
1
. Thus
Proposition 18 allows us to nd easily a generator matrix of C

by multiplying on
the right the parity check matrix of C by B
1
.
Proposition 25. Let C be a linear code in F
n
q
. Then we get
i(C

) = i(C + Ker B)

I.
Proof. If x i(C

), then x = i(v) = vQ I for some v C

.
Hence for every c C and

b Ker B, we have
x i(c +

b) = x i(c) +x i(

b) = v

c +v (

bB) = 0,
that is, i(C

) i(C + Ker B)

I.
Now, let x i(C + Ker B)

I, i.e. x = i(v) = vQ i(C + Ker B)

i(C)

for some v F
n
q
. Thus for every y C we have
v

y = vBy
t
= (vQ)(yQ)
t
= x i(y) = 0,
i.e. v C

. Hence we get x = i(v) i(C

), that is, i(C + Ker B)

I i(C

).

Corollary 26. Let C be a linear code. Then


C C

i(C) i(C + Ker B)

.
In particular, if C is self-ortogonal with respect to

then i(C) is self-ortogonal


with respect to .
Proof. Since i is injective, the statement can be obtained by Proposition 25 and
the following equivalence
i(C) i(C + Ker B)

I i(C) i(C + Ker B)

.
Finally, the last statement follows from the fact that
i(C + Ker B)

i(C)

14 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Theorem 27. Let C be an f-module -code. Assume that m is a multiple of s. If
C + Ker B is an f-module -code (g), then C

is an f-module -code (g

) with
g

q
f
= l.l.c.m. < h

, q
f
> mod (X
m
1),
where h

k
i=1

i
(h
ki
)X
i
and
X
m
1 = g q
f
(
k

i=1
h
i
X
i
).
In particular, a generator matrix of C

is given by the following matrix:


_
_
_
_
_
_

1
(g

)
(
1
(g

))( A
c
)
((
1
(g

))( A
c
)
2
...
(
1
(g

))( A
c
)
nk1
_
_
_
_
_
_
.
Proof. By hypothesis, Proposition 25 and [2, Theorem 1], we deduce that i(C +
Ker B)

and I are both -cyclic codes. Therefore it follows that i(C

) is also a
-cyclic code. By Propositions 8 and 2 we conclude that C

is an f-module -code.
Finally, from Lemma 7 it follows that there exists a commutative diagram
C + Ker B
i
//

i(C + Ker B)

(g)
j
//
(gq
f
)
such that

(i(C + Ker B)) = (gq


f
) := R(gq
f
)/R(X
m
1). Since i(C + Ker B) is
a -cyclic code, by [4, Theorem 8] we known that i(C +Ker B)

is again a -cyclic
code generated by the skew polynomial h

:= h

R such that
X
m
1 = g q
f
h,
where h

is as in [2, Denition 3]. Since I is generated by q


f
R, from Proposition
25 it follows that

(i(C

)) = (h

) (q
f
), i.e. i(C

) is generated by G := l.l.c.m. <


h

, q
f
>. From Lemma 7 we deduce that C

is generated by a polynomial g

R
such that G = g

q
f
.
Remark 28. The code C +Ker B is an f-module -code if for instance Ker B C.
In particular, when r = n, it follows that
C = C

C B
1
is the dual code C

of C.
Example 29. In F
3
4
, where F
4
= F
2
[] with
2
++1 = 0, consider the following
four polynomials:
(1) f
0
= X
3
+X
2
+ 1;
(2) f
1
= X
3
+
2
X
2
+
2
X +;
(3) f
2
= X
3
+X
2
+X +
2
;
(4) f
3
= X
3
+
2
.
By applying Program 1, we obtain m = 6 for the rst three cases, while m = 7 for
the fourth case. Then
X
6
1 = f
1
q
f1
= f
2
q
f2
= f
3
q
f3
, X
7
1 = f
0
q
f0
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 15
where
q
f0
= X
4
+X
3
+X
2
+ 1, q
f1
= X
3
+X
2
+
2
X +
2
,
q
f2
= X
3
+X
2
+X +, q
f3
= X
3
+.
Therefore this gives
Q
0
=
_
_
1 0 1 1 1 0 0
0 1 0 1 1 1 0
0 0 1 0 1 1 1
_
_
, Q
1
=
_
_

2
1 0 0
0
2
1 0
0 0
2

2
1
_
_
,
Q
2
=
_
_
1 1 0 0
0
2

2
1 1 0
0 0 1 1
_
_
, Q
3
=
_
_
0 0 1 0 0
0
2
0 0 1 0
0 0 0 0 1
_
_
,
and
B
0
=
_
_
0 0 0
0 0 0
0 0 0
_
_
, B
1
=
_
_
1
1
2
1
1
_
_
,
B
2
=
_
_
0
2
0

2
0
0 0
_
_
, B
3
=
_
_
0 0
0
2
0
0 0
_
_
,
with rk B
i
= i for i = 0, ..., 3. Note that from Remark 20 it follows that Q
0
is the
generator matrix of a self-orthogonal -cyclic code (in fact, a self-orthogonal cyclic
code) of type [7, 3, 3]
4
. With the following Magma program
Program 5:
a:= 4;
F<w>:=GF(a);
R<X>:=TwistedPolynomials(F:q:=2);
// Define the polynomial fj
fj:=R![ ... , ... , ... ];
n:=Degree(fj);
// Sets of possible coefficients
A:=[1,w,w^2];
B:=[0,1,w,w^2];
// n iterations, with n = deg fj
for a1 in A do
for a2 in B do
...
for an in B do
q,r:=Quotrem(fj,R![a1, ... ,an]);
if r eq R![0] then
printf "Right Factor = ";
R![a1, ... ,an];
printf "Quotient = ";
q;
end if;
16 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


end for;
end for;
...
end for;
we can factorize the polynomials f
j
s:
f
0
= (X
3
+
2
X
2
+
2
) = (
2
X
3
+X
2
+)
2
,
f
1
= (X +) (X
2
+X + 1) = (
2
X
2
+) (X + 1) =
= (X + 1) (X
2
+X +) = (X
2
+ 1) (
2
X +) =
= (X
2
+
2
) (X +
2
) = (
2
X +
2
) (
2
X
2
+
2
X +
2
),
f
2
= (X +
2
) (X
2
+ 1) = (
2
X
2
+
2
X +
2
) (X + 1) =
= (
2
X +) (
2
X
2
+) = (X
2
+X +) (
2
X +) =
= (X + 1) (X
2
+
2
) = (X
2
+X + 1) (X +
2
),
f
3
= (
2
X
2
+ X +
2
) (X + 1) = (X +
2
) (X
2
+X + 1) =
= (X
2
+X +) (
2
X +) = (X +) (X
2
+
2
X +) =
= (X
2
+
2
X + 1) (X +
2
) = (
2
X + 1) (
2
X
2
+X +
2
).
Therefore, let
C
0
= (X
3
+X
2
+ 1)
0
3,
; C
1
= (X +
2
)
2
3,
, (X
2
+X + 1)
1
3,
;
C
2
= (X +
2
)
2
3,
, (X
2
+
2
)
1
3,
; C
3
= (X +
2
)
2
3,
, (X
2
+X + 1)
1
3,
,
with generator matrices respectively
G
1
=
_

2
1 0
0 1
_
,
_
1 1 1
_
;
G
2
=
_

2
1 0
0 1
_
,
_

2
0 1
_
;
G
3
=
_

2
1 0
0 1
_
,
_
1 1
_
.
Thus C

0
= C

0
= F
3
4
and from Proposition 18 we deduce that the parity check
matrices of the C
i
s for i = 1, 2, 3 are:
H
1
=
_
1
2
1
_
,
_
1 0 1
0 1 1
_
;
H
2
=
_
1
2
1
_
,
_
1 0
2
0 1 0
_
;
H
3
=
_
1
2
1
_
,
_
1 0 1
0 1
_
.
Therefore we have
C

1
= F
3
4
, (X +
2
)
2
3,
; C

2
=< (1, 0, ), (0, 1,
2
) >, F
3
4
;
C

3
=< (
2
, 1,
2
) >, < (1, 0, 1), (0, , 1) > .
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 17
Remark 30. The Program 5, with slight modications, can be used repeatedly to
nd all the decompositions of a polynomial in the skew polynomial ring R.
2.1.2. Hermitian dual codes. Let f R be as in subsection 1) and assume that the
order s of Aut(F
q
) divides m, where m is as in (), i.e.
( ) m = m

s , m

N
Under condition (), we can introduce also the notion of dual Hermitian codes
and give some of their properties.
We dene a conjugation map on R/RF for some F R such that
(aX
i
) :=
i
(a)X
deg Fi
,
where 0 i deg F 1, which is extended to all elements of R/RF by linearity of
addition. We then dene a Hermitian product of two elements p(X) = p
0
+p
1
X +
... +p
m1
X
m1
and t(X) = t
0
+t
1
X +... +t
m1
X
m1
of R/R(X
m
1) by
p(X)
P
t(X) := p(X)(t(X)).
By Lemma 7 we can also dene the Hermitian product of two elements a(X) =
a
0
+a
1
X +... +a
n1
X
n1
and b(X) = b
0
+b
1
X +... +b
n1
X
n1
of R/Rf by
< a(X), b(X) >:= j(a(X))
P
j(b(X)).
The following two results are now an immediate generalization of [9, Proposition
3.2 and Corollary 3.3].
Theorem 31. Let a,

b F
n
q
and let a(X) and b(X) be their polynomial represen-
tation in R/Rf via , respectively. If () holds, then
a

b( A
c
)
h
= 0 for all 0 h m1 < a(X), b(X) >= 0.
Proof. Since
m
= id, the condition < a(X), b(X) >= 0 is equivalent to
j(a(X))
P
j(b(X)) = 0 a(X)q
f
(b(X)q
f
) = 0

_
m1

i=0
a

i
X
i
_

_
m1

k=0
b

k
X
k
_
= 0

_
m1

i=0
a

i
X
i
_

_
m1

k=0

k
(b

k
)X
mk
_
= 0

m1

h=0
_
m1

i=0
a

i+h

h
(b

i
)
_
X
h
= 0,
where the subscript i +h is taken modulo m. Comparing the coecients of X
h
on
both sides of the last equation, we get
m1

i=0
a

i+h

h
(b

i
) = 0, for all 0 h m1.
18 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


By Proposition 8 the above equation is equivalent for all 0 h m1 to

(
h
P
h
) = 0

a

( P)
h
= 0
i(a) i(

b)( P)
h
= 0
i(a) i(

b( A
c
)
h
) = 0
aQ (

b( A
c
)
h
)Q = 0
i.e. a

b( A
c
)
h
= 0 for all 0 h m1.
Let I be a left ideal of R/Rf.
We dene I

the dual of I in R/Rf taken with respect to the Hermitian scalar


product <, >, that is,
I

:= {a(X) R/Rf | < a(X), t(X) >= 0 , t(X) I }.


Note that in general I

is not a left ideal of R/Rf. From Theorem 31, we deduce


the following
Corollary 32. Let C be an f-module -code. If () holds, then
(C

) = (C)

.
Proof. Let (

b) (C

) for some

b C

. Then we have for any a C and h Z


0

a( A
c
)
h
= 0.
Thus by Theorem 31 we get
< (

b), (a) >= 0 for all a C,


i.e. (

b) (C)

. Hence (C

) (C)

. Finally, let b(X) (C)

. Then we see
that
< b(X), (a) >= 0, a C.
By Theorem 31 with h = 0, this implies that

1
(b(X))

a = 0, a C,
i.e.
1
(b(X)) C

. This shows that


b(X) = (
1
(b(X)) (C

),
i.e. (C)

(C

).
Remark 33. If () holds, C and C +Ker B are f-module -codes, then Theorem
27 and Corollary 32 say that (C)

is a left ideal of R/Rf.


Corollary 34. Let C be an f-module -code. If () holds, then
C = C

(C) = (C)

,
i.e. C is self-dual with respect to

if and only if (C) is self-dual with respect to


<, >.
Proof. Since is an isomorphism, this follows immediately from Corollary 32.
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 19
Example 35. In F
3
4
, where F
4
= F
2
[] with
2
++1 = 0, consider the polynomial
f = X
3
+X + 1 associated to the matrix
A
c
:=
_
_
0 1 0
0 0 1
1 0
_
_
and dene (x) = x
2
for any x F
4
. From Example 6, we know that m = 8 and
X
8
1 = (X
3
+X + 1) q
f
with q
f
= X
5
+
2
X
3
+ X
2
+ X + 1. By Lemma 7 there exists a commutative
diagram
F
3
4
i
//

F
8
4

R
3
j
//
R
8
such that

i = j , where R
3
:= R/Rf, R
8
:= R/R(X
8
1) with R = F
4
[X, ],
i(v) := vQ with
Q =
_
_
1 1
2
0 1 0 0
0 1
2
1 0 1 0
0 0 1 1
2
0 1
_
_
and j(a + Rf) := (a q
f
) + R(X
8
1) for any a R. Note that the order of
divides m. By Program 5, we see that
f = (
2
X + 1)(
2
X
2
+X + 1) = (X
2
+X + 1)(
2
X + 1) =
= (X
2
+X +
2
)(X +) = (X +
2
)(X
2
+X +) =
= (
2
X
2
+
2
X +)(X +
2
) = (X +)(X
2
+
2
X +
2
).
Therefore we have the following two non-trivial -codes:
C
1
= (X
2
+X +)
1
3,
, C
2
= (X +)
2
3,
.
Note that
(C
1
) =
_
0, X
2
+X +, X
2
+
2
X +
2
,
2
X
2
+X + 1
_
and
(C
2
) = (C
1
) {X
2
+
2
X, X
2
+X,
2
X
2
+X, X +, X
2
+,

2
X
2
+
2
X+, X+
2
, X
2
+X+
2
,
2
X
2
+
2
,
2
X+1, X
2
+1, X
2
+X+1}.
Hence (C
2
)

(C
1
)

. Let p := X
2
+X + (C
1
). Since
q
f
(p q
f
) = q
f
(X
7
+X
6
+X
5
+X
4
+X
3
+X
2
+X +),
q
f
(p q
f
) = q
f
(
2
X
7
+
2
X
6
+
2
X
5
+
2
X
4
+
2
X
3
+
2
X
2
+
2
X +
2
)
and
q
f
(
2
p q
f
) = q
f
(X
7
+X
6
+X
5
+X
4
+X
3
+X
2
+X + 1)
are all equal to 0 mod (X
8
1), we deduce that (C
1
)

= R
3
, i.e. C

1
= F
3
4
.
By making similar accounts for the case C
2
= (X+)
2
3,
, we get (C
2
)

= (C
2
)
and from Corollary 34 it follows that C

2
= C
2
.
20 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


2.2. Remarks on the construction of an f-module -code. In R there are
exactly q
r1
(q1) dierent polynomials of the form g = g
0
+g
1
X+...+g
r1
X
r1
+
X
r
with g
0
= 0. Thus if h is another monic polynomial of degree r, then it follows
that (g) = (h) whenever g = h. Furthermore, for any given monic polynomial
g R of degree r n as above there always exists a polynomial f R of degree n
as in 1 such that g is a (right) divisor of f. This shows that there exist q
r1
(q 1)
module -codes with parameters of [n, n r]
q
.
Inspired by [8], let us give here the following
Denition 36.
D

q
(n, k) := max {d | a module code of type [n, k, d]
q
}
Similarly to [8, Proposition 3.1], we obtain the following
Proposition 37.
D

q
(n, k) D

q
(n + 1, k + 1).
Proof. Let g = g
0
+g
1
X+... +g
nk
X
nk
be the generator polynomial of a module
-code C
n+1,k+1
with parameters [n + 1, k + 1, D

q
(n + 1, k + 1)]. Observe that g
0
and g
nk
are distinct to zero and that the generator matrix G
n+1,k+1
of C
n+1,k+1
has the form
_
_
_
_
_
g
0
g
1
... g
nk
0 ... 0
0
.
.
. G
n,k
0
_
_
_
_
_
,
where G
n,k
is the following matrix
_
_
_
_
_
(g
0
) ... (g
nk
) 0 ... 0
0
2
(g
0
) ...
2
(g
nk
) ... 0
.
.
.
.
.
.
.
.
.
.
.
.
0 ... 0
k
(g
0
) ...
k
(g
nk
)
_
_
_
_
_
.
Note that the minimum (Hamming) distance decided by G
n,k
is at least D

q
(n +
1, k + 1). Dene G := (g
0
) + (g
1
)X... + (g
nk
)X
nk
. Then G is the generator
polynomial of a module -code C
n,k
of type [n, k, d]
q
with d D

q
(n + 1, k + 1).
Hence we get D

q
(n, k) d D

q
(n + 1, k + 1).
Remark 38. If C is a module -code of type [n, k, ]
q
with distance 1, then
we have D

q
(n, k) . Therefore by Proposition 37 we see that for any integer
such that 0 < k there exists at least a module -code C

of type [n, k, d]
q
with d 1. Thus the above result can be useful to ensure the existence and
the construction of module -codes of type [n, k, d]
q
with distance d grater or equal
to some xed value and small values for n and k.
Denote by F

q
F
q
the eld xed under . In what follows we try to construct
vectors v F
n
q
such that 1 dim[v] k for some integer k < n, where [v] F
n
q
is
the vector subspace generated by
_
v, (v)( A
c
), (v)( A
c
)
2
, ...
_
.
Put A := A
c
. Note that
(v)( A

) = (v)(A )
for any v (F
q
)
n
, where A

:= [(a
ij
)] if A = [a
ij
]. This gives the following
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 21
Lemma 39. With the same notation as above, for any integer k 1 we have
( A)
k
=
k
A
k
,
where A
k
:= A

k1 ... A

2 A

A for k 2 and A
1
:= A.
For any integer h such that 1 h n 1, consider the equation:
(#) (v)( A)
h
x
h
+... + (v)( A)
1
x
1
+ (v)x
0
=

0.
If there exists a non-trivial vector v and a nonzero x
h
F
q
which satises the
above equation (#), we can deduce that (v)( A)
h
can be written as a linear
combination of vectors in
_
v, (v)( A), ..., (v)( A)
h1
_
, i.e. 1 dim[v] h.
In order to simplify equation (#), we will consider only vectors v (F

q
)
n
. In
this case, by Lemma 39 (#) becomes
(#

) v (A
h
x
h
+... +A
1
x
1
+Ix
0
) =

0,
where v (F

q
)
n
. Thus the existence of a non trivial vectors v (F

q
)
n
which satisfy
equation (#

) is ensured by the existence of non trivial solutions x


h
, ..., x
1
, x
0
of
the equation
(#

) det(A
h
x
h
+... +A
1
x
1
+Ix
0
) = 0.
So we have reduced the problem of nding a vector v =

0 in (F

q
)
n
which is a
solution of (#) to the problem of nding non trivial solutions x
h
, ..., x
1
, x
0
in F
q
of
(#

). Dene
F
h
(x
0
, x
1
, ..., x
h
) := det(A
h
x
h
+... +A
1
x
1
+Ix
0
).
We have the following
Lemma 40. The polynomial F
h
(x
0
, x
1
, ..., x
h
) is an homogeneous polynomial of
degree n in the variables x
0
, x
1
, ..., x
h
.
Proof. For any F
q
, we get
F
h
(x
0
, x
1
, ..., x
h
) = det(A
h
(x
h
) +... +A
1
(x
1
) +I(x
0
))
= det(I (A
h
x
h
+... +A
1
x
1
+Ix
0
))
= det(I) det(A
h
x
h
+... +A
1
x
1
+Ix
0
)
=
n
F
h
(x
0
, x
1
, ..., x
h
),
and this gives the statement.
From Lemma 40 it follows that the zero locus Z(F
h
(x
0
, x
1
, ..., x
h
)) of F
h
(x
0
, x
1
, ..., x
h
)
on the projective space P
h
(F
q
) is well dened. Put
Z
h,n
:= Z(F
h
(x
0
, x
1
, ..., x
h
)) P
h
(F
q
).
Then Z
h,n
is a hypersurface of P
h
(F
q
), i.e. dimZ
h
= h 1, of degree n h +
1. Moreover, all the points of Z
h,n
represent no trivial solutions of (#

). This
gives a relation between the construction of a module -code C = [v], with v
(F

q
)
n
, of dimension less or equal to h with the existence of (rational) points on the
hypersurface Z
h,n
of P
h
(F
q
).
Remark 41. When is the identity of F
n
q
, e.g. if q is a prime number, we know
from [5] that the number N
q
of F
q
-points of the hypersurface Z
h,n
is bounded for
the following inequalities: (i) N
q
(n 1)q + 1 if h = 2, except for a curve Z
2,4
over F
4
; (ii) N
q
(n 1)q
h1
+nq
h2
+
q
h2
1
q1
if h 3.
22 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


2.3. A coding and decoding method. In this subsection, we extend to the
non-commutative case some results which appear in [6].
Let C = (g)
k
n,
be an f-module -code. Write g = g
nk
X
nk
+ ... + g
1
X + g
0
.
We know that g divides f, i.e. there exists a unique polynomial q of degree k such
that f = q g, and that a generator matrix G for C is given by
G :=
_
_
_
_
_
_
g
(g)( A
c
)
(g)( A
c
)
2
...
(g)( A
c
)
k1
_
_
_
_
_
_
,
where g :=
1
(g) = (g
0
, g
1
, ..., g
nk
, 0, ..., 0).
An easy codication is clearly to multiply the original message m by X
nk
, where
m = m
0
+m
1
X+... +m
k1
X
k1
. The result is m

= X
nk
m =
nk
(m
0
)X
nk
+

nk
(m
1
)X
nk+1
+ ... +
nk
(m
k1
)X
n1
. By dividing m

for g, we obtain that


m

= q

g +r, where either r = 0 or deg r < nk. Since q

g C and deg r < nk,


we deduce that all the information about the original message m is contained in
the last powers X
nk
, ..., X
n1
of m

r C. More precisely, for decoding the


received message it will be sucient to apply
n+k
to
1
(m

r) and the original


message will be given by the last k coordinates of the vector (
1
(m

r))
n+k
.
2.3.1. A Meggitt type decoding. Denote by R
g
(v) the rest of the division of v R by
g and dene the syndrome S(v) of v as S(v) := R
g
(X
nk
v), where deg g = nk.
Lemma 42. Under the same hypothesis as above, we have
S(v) = 0 R if and only if v (C).
Proof. Let v R such that S(v) = 0 R. Then R
g
(X
nk
v) = 0 and so we can
deduce that X
nk
v (C), i.e. X
nk
v = h g for some h R.
Put t := f
1
0
X
n1
... f
1
0
f
1
and note that t X = 1 in R. Hence
t
nk
h g = t
nk
(X
nk
v) = (t
nk
(X
nk
)) v = v,
that is, v (C). On the other hand, if v (C), then v = q g for some q R.
Thus by denition we can conclude that S(v) = 0 R.
Let m F
k
q
be the original message and code m as
m

:= m G C,
where G is the above generator matrix of C = (g)
k
n,
. Note that
( m

) = ( m G) = ( m) g (g) R.
We now give here an analogous of the Meggitt algorithm (see [6, 4.6]) for an
f-module -codes. For any c R, denote by wt(c) the weight of
1
c F
n
q
. Let
us recall that in this situation the main hypothesis is that the error e dened by
e := m

+C
has weight
d1
2
, where d is the distance of C and m

is the received message.


Moreover, by Lemma 42 we have
S(( m

)) = S((e))
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 23
and recall that
(f
1
0
X
n1
... f
1
0
f
1
) X = 1 R/Rf.
Algorithm 2 (A -Meggitt type algorithm):
Input: m

Step 1: Compute all the syndromes S(e

), where e

n1
i=0
e

i
X
i
is such
that wt(e

)
d1
2
and e

n1
= 0;
Step 2: Compute S(( m

)) and dene s := S(( m

));
Step 3: If s = 0 R then write e =

0;
Step 4: If s is equal to some of the syndromes S(e

) of Step 1, then write


e =
1
(e

);
Step 5: If s is not in the list of Step 1, then
m

= m

+
1
(e)
for some error e R such that wt(e)
d1
2
and e =

h
j=0
e
j
X
j
with
e
h
= 0 and h < n 1. Since is an automorphism of F
q
, there exists an
integer k := n h 1 such that
e

:= X
k
e
is an error as in Step 1, that is, e

n1
i=0
e

i
X
i
with wt(e

)
d1
2
and
e

n1
= 0. Thus by Lemma 42 the syndrome S(X
k
( m

)) is equal to S(e

)
with e

as in Step 1 and we write


e =
1
((f
1
0
X
n1
... f
1
0
f
1
)
k
e

);
Output: m

= m

e.
3. Product semi-linear codes
The above sections allows us to extend the previous codes to the case of codes
invariant by a semi-linear transformation T : F
q
F
q
, which we call here semi-
linear codes, or T-codes for simplicity. It is known that a semi-linear map T is the
composition of an automorphism of F
q
with an F
q
-linear transformation M, i.e.
(v)T := (v) M, where (v
1
, ..., v
n
) := ((v
1
), ..., (v
n
)). In this case we will call
T a -semi-linear map, or a -semi-linear transformation. For any v F
n
q
and any
-semi-linear map T of F
n
q
, let [v] denote the T-cyclic subspace of F
n
q
spanned by
_
v, (v)T, (v)T
2
, ...
_
.
3.1. Background material. The main result of [7] allows us to decompose the
vector space F
n
q
into a direct sum of very special vector subspaces and to nd a
normal canonical form for any -semi-linear transformation.
Denition 43. Let A and B be two matrices. We say that A is -similar to B, and
we write A

B, if there exists an invertible matrix C such that A = (C

)
1
BC,
where C

is the matrix obtained by applying the automorphism to each entry of


C. Moreover, we say that two -semi-linear maps T = M and T

= M

of
F
n
q
are -similar if M

and in this case we simply write T

.
By choosing the basis of F
n
q
to be the union of appropriate bases
_
u
i
, T(u
i
), T
2
(u
i
), ..., T
dim[ ui]1
(u
i
)
_
24 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


of T-cyclic subspaces [u
i
], i = 1, ..., r, it follows immediately the existence of a
normal canonical form for any -semi-linear map T.
Theorem 44 ([7], Theorem 5). Let be an automorphism of F
n
q
and T a -semi-
linear transformation on F
n
q
. Then
F
n
q
= [u
1
] ... [u
r
],
for T-cyclic subspaces [u
i
] satisfying dim[u
1
] dim[u
2
] ... dim[u
r
]. Moreover,
if T = M then
T

diag(M
1
, ..., M
r
),
where M

diag(M
1
, ..., M
r
) and each M
i
is a n
i
n
i
matrix of the following form
_
_
_
_
_
0 1
.
.
.
.
.
.
0 1
a
i,0
a
i,1
. . . a
i,ni1
_
_
_
_
_
with n
i
1 and such that

r
i=1
n
i
= n.
For the convenience of the reader, let us recall here the construction of the vectors
u
i
, i = 1, ..., r, which appear in the above result (see [7, 6]). Let {e
1
, ..., e
n
} be a
basis for F
n
q
and suppose that the -semi-linear map T sends e
k
into
e
k
T = e
1

1k
+... +e
n

nk
,
for k = 1, ..., n, or using the usual rule of matrix multiplication
(e
1
T, ..., e
n
T) = (e
1
, ..., e
n
)T ,
where T = [
ij
].
Let F
n
q
[t] be the extension of F
n
q
obtained by allowing the coecients to range in
F
q
[t, ], i.e. F
n
q
[t] is the totally of forms x(t) :=

n
i=1
e
i

i
(t), where
i
(t) F
q
[t, ].
Note that this denition is independent of the choice of basis of F
n
q
and that F
n
q
[t]
is an abelian group under addition. The correspondence x(t) x(t)a(t) with
a(t) F
q
[t, ] is an automorphism of this group. Thus F
n
q
[t] may be looked upon as
an abelian group (F
n
q
[t], F
q
[t, ]) with operators F
q
[t, ]. With x(t) :=

n
i=1
e
i

i
(t)
we associate the vector x :=

n
i=1
e
i

i
(T) and with the automorphism x(t)
x(t)a(t) we associate the automorphism x xa(T). These correspondences dene
a surjective operator homomorphism of (F
n
q
[t], F
q
[t, ]) onto (F
n
q
, F
q
[T, ]). Dene
f
1
(t), ..., f
n
(t) by
(f
1
(t), ..., f
n
(t)) = (e
1
, ..., e
n
)(T tI),
where T = [
ij
] and I denotes the unit matrix. From [7, Lemma 4] we know that
{f
1
(t), ..., f
n
(t)} is a basis for Ker , the kernel of . We may replace the bases
{e
1
, ..., e
n
} and {f
1
(t), ..., f
n
(t)} of F
n
q
[t] and Ker respectively by
(

1
(t), ...,

e

n
(t)) = (e
1
, ..., e
n
)U(t)
1
and
(f

1
(t), ..., f

n
(t)) = (f
1
(t), ..., f
n
(t))V (t),
where U(t) and V (t) are invertible matrices in the ring of matrices of n rows and
columns with coordinates in F
q
[t, ]. Then we have
(f

1
(t), ..., f

n
(t)) = (

1
(t), ...,

e

n
(t))U(t)(T tI)V (t),
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 25
and in view of [7, 5] we may choose U(t) and V (t) so that V (t)(T tI)U(t) has
the form
_
_
_
_
_
_
_
_
_
_
1
.
.
.
1

1
(t)
.
.
.

r
(t)
_
_
_
_
_
_
_
_
_
_
where the invariant factors
i
(t) are bounded with bounds

i
(t) =
i
(t)h
i
(t) di-
viding
i
(t) if i < r and i < j (e.g., see the Appendix 4).
Dene

e

i
:= (

i
(t)) for i = 1, ..., r. Since

e

j
(t) Ker for j = 1, ..., n r,
we have

e

1
=

0, ...,

e

nr
=

0. Thus denote by
u
i
:=

e

nr+i
= (

nr+i
(t)),
for i = 1, ..., r. From [7, p. 496] it follows that if

i
(t) = t
mi
a
i,mi1
t
mi1
... a
i,2
t
2
a
i,1
t a
i,0
,
then
(u
1
, u
1
T, ..., u
1
T
m11
, ..., ..., u
r
, u
r
T, ..., u
r
T
mr1
)
is a basis for F
n
q
.
This gives a construction method to nd the vectors u
i
of Theorem 44.
Remark 45. By Theorem 44, we know that any -semi-linear transformation T =
M is -similar to diag(M
1
, ..., M
r
), i.e. there exists an invertible matrix
C :=
_
_
_
_
_
_
_
_
_
_
_
_
_
_
_
_
_
u
1
(u
1
)T
.
.
.
(u
1
)T
n11
.
.
.
u
r
(u
r
)T
.
.
.
(u
r
)T
nr1
_
_
_
_
_
_
_
_
_
_
_
_
_
_
_
_
_
such that
T = M = C
1
( diag(M
1
, ..., M
r
))C,
where n
i
:= dim[u
i
] for i = 1, ..., r. Therefore we can reduce the study of any
semi-linear code C
T
which is invariant by T to the study of the semi-linear code
C
c
:= C
T
C
1
invariant by the corresponding -semi-linear transformation
diag(M
1
, ..., M
r
) = diag( M
1
, ..., M
r
),
where each M
i
is the -semi-linear transformation on F
ni
q
such that F
n
q
=
F
n1
q
... F
nr
q
with

r
i=1
n
i
= n.
26 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Remark 46. Let T = M be a -semi-linear transformation. If M is an n n
matrix with coordinates in F

q
, then M admits a rational normal form, i.e. there
exists an invertible matrix C with coordinates in F

q
such that M = C
1
DC, where
D = diag(M
1
, ..., M
k
) and each M
i
is a n
i
n
i
matrix as in Theorem 44. Thus we
have
CTC
1
= C( M)C
1
= CMC
1
= D
and in this case it is easy to nd the matrix C which allows us to transform a T-code
into a cartesian product of module -codes and vice versa. A typical example of
this situation are the skew quasi-cyclic codes, where the matrix M is a permutation
matrix P such that P = P

= P

1 .
Let T = M be a -semi-linear transformation which is -similar to
diag(M
1
, ..., M
r
) by the matrix C as in Remark 45. Write F
n
q
= F
n1
q
... F
nr
q
with

r
i=1
n
i
= n and dene the following linear transformation:
: F
n1
q
... F
nr
q
R
n
:= R/Rf
1
... R/Rf
r
,
where = (
1
, ...,
r
) and for each j = 1, ..., r the linear transformation
j
: F
nj
q

R/Rf
j
is dened as in Section 1. We can now generalize Proposition 2 as follows.
Proposition 47. With the same notation as above, let C F
n
q
be a linear code.
Then
C is a T-code C = C
c
C with C
c
a linear code such that (C
c
) is a left
R-submodule of R
n
.
Proof. By Remark 45 we know that any T-code can be written as C
c
C, where C
c
is
a linear code invariant by the matrix D := diag( M
1
, ..., M
r
) and vice versa.
So it is sucient to show that a linear code C
c
is invariant by D if and only if (C
c
)
is a left R-submodule of R
n
.
Let C
c
be a linear code invariant by D. Note that (C
c
) is an abelian group
with respect to the sum. Moreover, we obtain that
X (c) = (cD) (C
c
)
for any c C
c
. This implies that (C
c
) is an R-submodule of R
r
. On the other
hand, let (C
c
) be an R-submodule of R
r
. Then for every c
1
((C
c
)) we have
cD =
1
(X (c))
1
((C
c
)) = C
c
,
since X (c) (C
c
).
Example 48. In F
6
4
, where F
4
= F
2
[] with
2
+ + 1 = 0, consider the matrix
D =
_
_
_
_
_
_
_
_
0 1 0 0 0 0
0 0 1 0 0 0
1 0 0 0 0 0
0 0 0 0 1 0
0 0 0 0 0 1
0 0 0 1 0 0
_
_
_
_
_
_
_
_
and the semi-linear transformation D. The code C =< (1, 1, 1, 1, 1, 1) > is
invariant by D, C

=< (1, 1, 1, 0, 0, 0) >=< (1, 1, 1) > < (0, 0, 0) >, but
C = C
1
C
2
for any -code C
i
F
3
4
invariant by
_
_
0 1 0
0 0 1
1 0 0
_
_
for i = 1, 2.
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 27
Remark 49. In the commutative case, that is = id, the Chinese remainder
theorem says that if (f
1
), ..., (f
k
) are ideals of R which are pairwise coprime, i.e.
(f
i
)+(f
j
) = R for all i = j, then I := (f
1
)...(f
k
) = (f
1
)...(f
k
) and the quotient
ring R/I is isomorphic to the product ring R/(f
1
)...R/(f
k
) via the isomorphism
f : R/I R/(f
1
) ... R/(f
k
) such that f(a +I) := (a + (f
1
), ..., a + (f
k
)).
In the non-commutative case, i.e. = id, there exists an analogous of the above
result. In this situation, if (f
1
), ..., (f
k
) are pairwise coprime two-sided ideals of R,
then
R/((f
1
) ... (f
k
))

= R/(f
1
) ... R/(f
k
)
as R-modules and (f
1
) ... (f
k
) can be replaced by a sum over all orderings of
(f
1
), ..., (f
k
) of their product (or just a sum over enough orderings, using inductively
that J K = JK + KJ for coprimes ideals J, K). In this case, we have a method
to nd all the R-submodules of R/(f
1
) ... R/(f
k
) via R/((f
1
) ... (f
k
)).
Remark 50. From [10] we known that every reduced polynomial has a represen-
tation as the product of prime factors. Two dierent decompositions of the same
polynomial have the same number of prime factors and the factors are similar in
pairs. One decomposition can be obtained from the other through interchanges of
factors. Therefore, up to renaming, we can obtain a standard decomposition of
F
n
q
= F
N1
q
... F
Ns
q
and an isomorphism
: F
N1
q
... F
Ns
q
R/RF
1
... R/RF
s
,
where = (
1
, ...,
s
) with
j
: F
Nj
q
R/RF
j
the usual isomorphism and the
F
j
s are irreducible polynomials of degree N
j
1 for j = 1, ..., s. Moreover, every
R-submodule (C
c
) of R/RF
1
... R/RF
s
is isomorphic to a trivial product
I
1
... I
s
, where I
j
is either R/RF
j
or {0} for any j = 1, ..., s.
From Remark 50, it follows naturally the following
Denition 51. Let C
T
F
n
q
be a semi-linear code invariant by a -semi-linear
map T. We say that C
T
is a product semi-linear code, or a product T-code, if
C
T
= (C
1
... C
r
)C, where T = C
1
( diag(M
1
, ..., M
r
))C for an invertible
matrix C, the M
j
s are given as in Theorem 44, the C
j
s are f
j
-module -codes with
respect to M
j
, f
j
= X
nj

nj1
k=0
f
j,k
X
k
for every j = 1, ..., r and n =

r
j=1
n
j
.
Remark 52. Any semi-linear code invariant by a -semi-linear transformation is
isomorphic to a product semi-linear code.
From Denition 51 it follows that a generator matrix of a product semi-linear
code C
T
= (C
1
... C
r
)C is given by
_
_
_
_
_
_
G
1
G
2
.
.
.
G
r
_
_
_
_
_
_
C
28 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


where k
i
:= dimC
i
,

r
i=1
k
i
= dimC
T
and each block
G
i
:=
_
_
_
_
_
g
i
(g
i
)( M
i
)
.
.
.
(g
i
)( M
i
)
ki1
_
_
_
_
_
is the k
i
n
i
generator matrix of C
i
= (g
i
)
ki
ni,
, where g
i
=
1
i
(g
i
) and
i
: F
ni
q

R/Rf
i
for i = 1, ..., r.
The following result gives us an existence condition of semi-linear code C
T
F
n
q
with dimC
T
:= k.
Theorem 53. Let T = M be a -semi-linear transformation over F
n
q
. With
the same notation as in Remark 50, let F
n
q
= F
N1
q
... F
Ns
q
be the standard
decomposition of F
n
q
and let be the isomorphism
: F
N1
q
... F
Ns
q
R/RF
1
... R/RF
s
,
where = (
1
, ...,
s
) with
j
: F
Nj
q
R/RF
j
the usual isomorphism, the F
j
s are
irreducible polynomials of degree N
j
1 for j = 1, ..., s. Then
a T-code of type [n, k] k =

t
i=1
deg F
ji
, where 1 t s and the j
i
s
are distinct sub-indeces of {1, ..., s}.
Proof. Observe that the set of T-codes C
T
is in one-to-one correspondence with the
set of linear codes C
D
invariant by the semi-linear transformation D := diag(
M
1
, ..., M
r
) for any diagonalization of the matrix M. Therefore it is sucient to
prove the statement with the standard decomposition of F
n
q
as in Remark 50. So,
let C
T
F
n
q
be a T-code of type [n, k]. Then C
T
C
1
is a linear code C
D
invariant
by the semi-linear transformation D := diag( M
1
, ..., M
r
). With the same
notation as in the statement, (C
D
) is an R-submodule of R/RF
1
... R/RF
s
.
Since the F
i
s are irreducible polynomials and every R-submodule of R/RF
1
...
R/RF
s
is isomorphic to I
1
... I
s
with I
j
= {0} or R/RF
j
for j = 1, ..., s, we
conclude that
k := dimC
T
= dimC
D
=
s

i=1
t
i
,
where t
i
is either 0 or equal to deg F
i
. On the other hand, without loss of generality,
assume up to renaming that k =

t
i=1
deg F
i
with 1 t s. Then the product
code F
deg F1
q
... F
deg Fs
q
{0} ... {0} is a T-code of type [n, k].
Finally, as a byproduct of the above arguments and sections, we obtain the
following results for product T-codes.
3.2. Euclidean dual product T-codes.
Proposition 54. Let C
T
F
n
q
be a product semi-linear code invariant by a -semi-
linear transformation T. If
C
T
= (C
1
... C
r
)C,
then we have
C
T

= (C

1
... C

r
)C
1
t
,
where C
t
is the transpose matrix of C and C

i
is the Euclidean dual code of C
i
for
every i = 1, ..., r.
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 29
Proof. Put
E = (C

1
... C

r
)C
1
t
and note that
dimE = dim(C

1
... C

r
) =
r

i=1
dimC

i
=
r

i=1
(m
i
dimC
i
) =
=
r

i=1
m
i

r

i=1
dim(C
i
) = n dimC
T
= dimC
T

.
Let v E. Since E = (C

1
... C

r
)C
1
t
, we deduce that v = wC
1
t
for some
vector w = ( c
1

, ..., c
r

) (C

1
... C

r
). Thus for every c = ( c
1
, ..., c
r
)C C
T
,
we see that
v c = wC
1
t
c
t
= ( c
1

, ..., c
r

)C
1
t
(( c
1
, ..., c
r
)C)
t
=
= ( c
1

, ..., c
r

)( c
1
, ..., c
r
)
t
= c
1

c
1
+... + c
r

c
r
= 0,
i.e. E C
T

. Since dimE = C
T

, we conclude E = C
T

.
Theorem 54 allows us to nd easily a parity check matrix of a product semi-linear
code C
T
F
n
q
.
Corollary 55. Let C
T
F
n
q
be a product T-code invariant by a -semi-linear
transformation T. If C
T
= (C
1
... C
r
)C then the parity check matrix of C
T
is
_
_
_
_
_
_
H
1
H
2
.
.
.
H
r
_
_
_
_
_
_
C
1
t
where C
t
is the transpose matrix of C, h
i
:= dimC

i
,

r
i=1
h
i
= dimC

T
and each
block H
i
is the h
i
n
i
parity check matrix of C
i
for i = 1, ..., r.
Remark 56. Corollary 55 and Proposition 18 are useful to calculate the minimum
Hamming distance of any product semi-linear code. Furthermore, section III B
gives also a method to construct all the product T-codes.
3.3. Quasi-Euclidean dual product T-codes. From Lemma 7, we know that
there exists a commutative diagram for any k = 1, ..., r:
F
n
k
q
i
k
//

F
m
k
q

R/Rf
k
j
k
//
R/R(X
m
k
1)
30 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


Let us consider now also the following commutative diagram:
F
n
q
i
((

:=C
1

F
n1
q
... F
nr
q
i
//

F
m1
q
... F
mr
q

R
n
j
//
R
m
where n =

r
i=1
n
i
, m =

r
i=1
m
i
, f
i
= X
ni

ni1
j=0
f
i,j
X
j
R,
R
n
:= R/Rf
1
... R/Rf
r
,
R
m
:= R/R(X
m1
1) ... R/R(X
mr
1),
i(v) := vQ with
Q :=
_
_
_
_
_
_
Q
1
Q
2
.
.
.
Q
r
_
_
_
_
_
_
and all the Q
i
s are matrices n
i
m
i
as in Lemma 7, = (
1
, ...,
r
) with
i
:
F
ni
q
R/Rf
i
,

= (

1
, ...,

r
) with

i
: F
mi
q
R/R(X
mi
1) and
j(p
1
, ..., p
r
) := (p
1
q
f1
, ..., p
r
q
fr
)
with all the q
fi
s polynomials in R as in Lemma 7.
Denote by I the image of i and dene
B := C
1
Q Q
t
(C
1
)
t
,
where M
t
is the transpose of a matrix M. Note that B is a symmetric matrix.
Let r be the rank of the matrix B and observe that
r := rkB = rk(Q Q
t
) = n dim(Ker Q
t
I)
with 0 r n.
Denition 57. Let C be a linear code in F
n
q
. We denote by

the quasi-euclidean
scalar product on F
n
q
dened by a

b := aB

b
t
for any a,

b F
n
q
and by C

the
linear quasi-euclidean dual code of C with respect to

, i.e.
C

:=
_
x F
n
q
| x

c = 0 for every c C
_
.
Corollary 58. Let C be a linear code in F
n
q
. Then we have
(i) C

= (C B)

.
(ii) dimC

= dimC

+ dim(C Ker B) dimC

;
(iii) C

B = C

(Im B);
(iv) C (C

;
(v) i(C

) = i(C + Ker B)

I.
Furthermore, if r = n, then we have
(j) C

= C

B
1
;
(jj) dimC

= dimC

;
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 31
(jjj) (C

= C.
Proof. The proofs are similar to those in Propositions 22, 25 and Corollary 23.
Corollary 59. Let C be a linear code. Then
C C

i(C) i(C + Ker B)

.
In particular, if C is self-ortogonal with respect to

then i(C) is self-ortogonal


with respect to .
Proof. Since i is injective, the rst part of the statement can be obtained by
Corollary 58(v) and the following equivalence
i(C) i(C + Ker B)

I i(C) i(C + Ker B)

.
Finally, the last part of the statement follows from the fact that
i(C + Ker B)

i(C)

Lemma 60. With the same notation as above, we have


i(c T
k
) = i(c)( P)
k
for any c F
n
q
and k N, where
P :=
_
_
_
_
_
_
P
1
P
2
.
.
.
P
r
_
_
_
_
_
_
and the P
i
s are the m
i
m
i
permutation matrices as in Lemma 7 for i = 1, ..., r.
Proof. It is sucient to prove the statement for k = 1. Thus, for every c F
n
q
, let
v = (v
1
, ..., v
r
) F
n1
q
... F
nr
q
be the vector such that c = vC. By denition and
Proposition 8 we have
i(c T) = i(c TC
1
) = i(c C
1
( D)CC
1
) = i((v)( D)) =
= i((v
1
M
1
, ..., v
r
M
r
)) = ((v
1
)( M
1
)Q
1
, ..., (v
r
)( M
r
)Q
r
) =
= (i
1
(v
1
M
1
), ..., i
r
(v
r
M
r
)) = (i
1
(v
1
)( P
1
), ..., i
r
(v
r
)( P
r
)) =
= (i
1
(v
1
), ..., i
r
(v
r
))( P) = (v
1
Q
1
, ..., v
r
Q
r
)( P) =
= (v
1
, ..., v
r
)Q( P) = (v)Q( P) = i(v)( P),
that is, i(c T) = i(v)( P) = i(c)( P).
Corollary 61. Let C = (C
1
... C
r
)C be a linear code in F
n
q
. Then
(j) C

= (C

1
... C

r
)C;
(jj) C is a product T-code i(C) is a linear code invariant by P.
Proof. (j) By Corollary 58(i) we have
C

= (CB)

= ((C
1
... C
r
)CB)

= ((C
1
... C
r
)Q Q
t
C
1
t
)

=
= ((C
1
Q
1
(Q
1
)
t
... C
r
Q
r
(Q
r
)
t
)C
1
t
)

=
= ((C
1
B
1
)

... (C
r
B
r
)

)C = (C

1
... C

r
)C.
(jj) From Lemma 60 it follows that
32 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


C is a product T-code (C) is a linear code invariant by D
i((C)) is a linear code invariant by P i(C) is a linear code invariant by
P.
Corollary 62. With the same notation as above, let C
T
be a T-code. Assume that
the order s of divides all the m
i
s. If C
T
+Ker B = (C
1
... C
r
)C is a product
T-code, then
C

T
= (C

1
... C

r
)C
is a T-code, where C

i
= (C
i
B
i
)

with B
i
:= Q
i
(Q
i
)
t
for i = 1, ..., r. Furthermore,
a generator matrix of C

T
is given by the following matrix:
G

:=
_
_
_
_
_
_
G

1
G

2
.
.
.
G

r
_
_
_
_
_
_
C,
where G

i
is the generator matrix of C

i
for every i = 1, ..., r.
In particular, if C
i
+ Ker B
i
is an f
i
-module -code for every i = 1, ..., r, then
C

T
is a product T-code and all the G

i
s of G

are given by Theorem 27.


Proof. Note that by Lemma 60 the image I of i is invariant by P and since
i(C
T
+ Ker B)

= i(C
1
... C
r
)

=
= (i
1
(C
1
) ... i
r
(C
r
))

= (i
1
(C
1
)

... i
r
(C
r
)

),
observe that i(C
T
+Ker B)

is also invariant by P. Thus i(C


T
+Ker B)

I
is invariant by P and from Corollary 58(v) and Lemma 60 we can conclude that
C

T
is invariant by T, i.e. C

T
is a T-code. Moreover, by Corollaries 58(i) and 61(j)
we obtain that
C

T
= (C
T
B)

= ((C
T
+ Ker B)B)

= (C
T
+ Ker B)

= (C

1
... C

r
)C.
Finally, the last part of the statement follows directly from Theorem 27.
3.4. Hermitian dual product T-codes. Assume that the order s of Aut(F
q
)
divides m
i
for all i = 1, ..., r, i.e.
( ) m
i
= m

i
s , m

i
N
Dene a conjugation map on R
m
:= R/R(X
m1
1) ... R/R(X
mr
1)
such that
((a
i1
X
i1
, ..., a
ir
X
ir
)) := (
1
(a
i1
X
i1
), ...,
r
(a
ir
X
ir
)),
where

k
(a
i
k
X
i
k
) :=
i
k
(a
i
k
)X
m
k
i
k
R/R(X
m
k
1)
for k = 1, ..., r, which is extended to all elements of R
m
by linearity of addition.
We then dene a product of two elements p(X) = (p
1
(X), ..., p
r
(X)) R
m
and

t(X) = (t
1
(X), ..., t
r
(X)) R
m
by
p(X)
P

t(X) := (p
1
(X)
1
(t
1
(X)), ..., p
r
(X)
r
(t
r
(X))).
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 33
By the above commutative diagram, we can also dene a Hermitian product of
two elements a(X) := (a
1
(X), ..., a
r
(X)) and

b(X) := (b
1
(X), ..., b
r
(X)) of R
n
:=
R/Rf
1
... R/Rf
r
by
<a(X),

b(X) >:= j(a(X))


P
j(

b(X)).
The following result is now an immediate consequence of Theorem 31.
Corollary 63. With the same notation as above, let a = ( a
1
, ..., a
r
),

b = (

b
1
, ...,

b
r
)
F
n1
q
... F
nr
q
and denote by
a(X) := (
1
( a
1
), ...,
r
( a
r
)) := (a
1
(X), ..., a
r
(X))
and

b(X) := (
1
(

b
1
), ...,
r
(

b
r
)) := (b
1
(X), ..., b
r
(X))
their polynomial representation in R/Rf
1
... R/Rf
r
via = (
1
, ...,
r
) respec-
tively. If () holds, then
a
i

b
i
(M
i
)
hi
= 0, for all 0 h
i
m
i
1, i = 1, ..., r <a(X),

b(X) >=

0.
Proof. The statement follows easily by applying Theorem 31 to each component of
<a(X),

b(X) > R
m
.
Let I be a left R-submodule of R
n
.
We dene I

the dual of I in R
n
taken with respect to the Hermitian product
<, >, that is,
I

:= {a(X) R
n
| <a(X),

t(X) >=

0 ,

t(X) I }.
Note that in general I

is not a left R-submodule of R


n
. From Corollary 63, we
deduce the following
Corollary 64. Let C
T
= (C
1
... C
r
)C be a product T-code. Dene the isomor-
phism = . If () holds, then
(C

T
) = (C
T
)

.
Proof. Since C
T
= (C
1
... C
r
)C, from Corollary 61(j) we deduce that C

T
=
(C

1
... C

r
)C. Thus it is sucient to prove that
(C

1
... C

r
) = (C
1
... C
r
)

.
The proof of the above equality is similar to that of Corollary 32 by using Corollary
63 instead of Theorem 31.
Remark 65. If () holds, C
T
= (C
1
... C
r
)C is a product T-code and each
C
i
+Ker B
i
is an f
i
-module -code for i = 1, ..., r, then Corollaries 62 and Corollary
64 say that
(C
T
)

=
1
(C

1
) ...
r
(C

r
) = (g

1
) ... (g

r
),
where
i
(C

i
) = (g

i
) R/Rf
i
for every i = 1, ..., r. In particular, in this case
(C
T
)

is a left R-submodule of R
n
.
Corollary 66. Let C
T
= (C
1
... C
r
)C be a product T-code. If () holds, then
C
T
= C

T
(C
T
) = (C
T
)

,
i.e., C
T
is self-dual with respect to

(C
T
) is self-dual with respect to <, >.
Proof. Since is an isomorphism, this follows immediately from Corollary 64.
34 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


3.5. A coding and decoding method for product T-codes. Finally, given a
-semi-linear transformation T = M and a product T-code C
T
F
n
q
, an easy
codication of a message m F
k
q
is given by mG
T
C
1
, where G
T
is a generator
matrix of C
T
and C is the invertible matrix such that CMC
1
= diag(M
1
, ..., M
r
)
with M
i
a matrix as in Theorem 44. Note that mG
T
C
T
and then
m

:= mG
T
C
1
C
T
C
1
= C
1
... C
r
for some f
i
-module -codes C
i
= (g
i
), where the g
i
s are right divisors of the f
i
s
respectively (see Remark 45).
Let d
min
:= min
i=1,...,r
{d(C
i
)}, where d(C
i
) := d
i
is the minimum Hamming
distance of the code C
i
for i = 1, ..., r, and assume that the error e dened by
e = m

+ (C
1
... C
r
)
has weight
dmin1
2
, where m

is the received message.


Let
j
: F
nj
q
R/Rf
j
for j = 1, ..., r and for any vector v = (v
1
, ..., v
r
) F
n
q
=
F
n1
q
... F
nr
q
dene
(v) := (
1
(v
1
), ...,
r
(v
r
))
and the syndrome of (v) as
S((v)) := (R
g1
(
1
(v
1
)), ..., R
gr
(
r
(v
r
))),
where R
gi
(
i
(v
i
)) is the rest of the division of
i
(v
i
) by g
i
for every i = 1, ..., r. Sim-
ilarly to Lemma 42, observe that S(( m

)) = (0, ..., 0). Hence S((e)) = S(( m

)).
Denote by t
i
the polynomials in R such that t
i
X = 1 R/Rf
i
for every i = 1, ..., r.
Algorithm 3 (A T-Meggitt type algorithm):
Input: m

= ( m

1
, ..., m

r
)
Step 1: Compute all the syndromes
S((

)) = S((
1
(

1
), ...,
r
(

r
)),
where
i
(

i
) =

ni1
j=0
e

j,i
X
j
is such that wt(

i
) = wt(
i
(

i
))
di1
2
with d
i
the minimum Hamming distance of C
i
and e

i,ni1
= 0;
Step 2: Compute S(( m

)) and dene s := S(( m

));
Step 3: If s =

0 R/Rf
1
... R/Rf
r
then write e =

0;
Step 4: If s is equal to some of the syndromes S((

)) of Step 1, then
write e =

e

;
Step 5: If s is not in the list of Step 1, then
m

= m

+

e

for some error



e

= (

1
, ...,

e

r
) F
n1
q
...F
nr
q
such that wt(

)
dmin1
2
and (

) = (

h1
j=0
e

j,1
X
j
, ...,

hr
j=0
e

j,r
X
j
) with e

hi,i
= 0, h
i
n
i
1 and
h
k
< n
k
1 for some k = 1, ..., r. Since is an automorphism of F
q
, there
exists an integer
k
:= n
k
h
k
1 such that
e
k
:= X

_
_
h
k

j=0
e

j,k
X
j
_
_
,
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 35
i.e.
k
(

E
k
) := e
k
=

n
k
1
j=0
e
j,k
X
j
is such that wt(

E
k
)
d
k
1
2
and
e
n
k
1,k
= 0. Thus the syndrome
S((
1
(

1
), ..., e
k
, ...,
r
(

r
))
is as in Step 1, where
i
(

i
) =

ni1
j=0
e

j,i
X
j
is such that wt(
i
(

i
))
di1
2
and e

i,ni1
= 0 for i = k. Then write
e = (

1
, ...,
1
k
(t

k
k
e
k
), ...,

r
);
Output: m

= m

e.
4. Appendix: A normal form of a polynomial matrix
Recall that R := F
q
[X, ]. First of all, let us show as follows: if A =
_
a
11
a
12
a
21
a
22
_
is a 2 2 matrix with coordinates in R, then there exist elementary matrices E, F
such that EAF has the normal form
EAF =
_

1
0
0
2
_
.
Up to exchange rows and columns by left and right multiplication of A with the
matrix
_
0 1
1 0
_
, we can assume that a
11
= 0 and a
11
= p a
21
+r, where p, r R
and deg(r) < deg(a
21
). Then
_
1 0
1 p
_

_
a
11
a
12
a
21
a
22
_
=
_
a
11
a
12
r a
12
p a
22
_
.
Since deg(r) < deg(a
11
), we obtain that a
11
= p

r + r

, where p

, r

F
q
[X, ] and
deg(r

) < deg(r). Then


_
1 0
1 p

_
a
11
a
12
r a
12
pa
22
_
=
_
a
11
a
12
a
11
p

r a
12
p

(a
12
p

a
22
)
_
=
=
_
a
11
a
12
r

a
12
p

(a
12
p

a
22
)
_
.
Thus with an inductive argument, by a nite numbers of steps we can obtain the
following matrix
_
a
11
a
12
0 a

22
_
.
The goal now is to obtain zero instead of a
12
by a similar process. Write a
11
=
a
12
s +t, where s, t F
q
[X, ] with deg(t) < deg(a
12
). Then
_
a
11
a
12
0 a

22
_

_
1 1
0 s
_
=
_
a
11
a
11
a
12
s
0 a

22
s
_
=
_
a
11
t
0 a

22
s
_
.
By applying again right division between a
11
and t, we nally obtain a matrix
_

1
0
0
2
_
.
This process can be realized by the fact that when we apply the algorithm of the
left (right) division, the degrees of the remainders decrease. This gives easily the
matrices E and F.
36 LUIS FELIPE TAPIA CUITI

NO AND ANDREA LUIGI TIRONI


The above result can be generalized to the case of n n matrices with n 3.
For instance, when n = 3, if the matrix A has the form
A =
_
_
a
11
a
12
a
13
a
21
a
22
a
23
a
31
a
32
a
33
_
_
,
up to exchange rows and columns by permutation matrices, we can suppose again
that a
11
= 0. By multiplying the matrix A on the right and on the left with
matrices as
_
_
1 1 0
0 q
1
0
0 0 1
_
_
,
_
_
1 0 1
0 1 0
0 0 q
2
_
_
and
_
_
1 0 0
1 q
3
0
0 0 1
_
_
,
_
_
1 0 0
0 1 0
1 0 q
4
_
_
for some q
i
F
q
respectively, we lead to the following matrix
A

=
_
_
a
11
0 0
0 a

22
a

23
0 a

32
a

33
_
_
.
By a similar argument as above, we can reduce A

to the following matrix


_
_
a
11
0 0
0
2
0
0 0
3
_
_
by multiplying A

on the left and on the right with matrices of type


_
_
1 0 0
0 1 0
0 1 a
_
_
,
_
_
1 0 0
0 1 1
0 0 b
_
_
for some a, b F
q
, respectively.
Conclusion
In the rst part of this paper, we study the main properties of module -codes
in the non-commutative ring F
q
[X, ], where : F
q
F
q
is an automorphism of
the nite eld F
q
with q elements, with particular emphasis to Euclidean, Quasi-
Euclidean and Hermitian dual codes. The main ingredient here is the construction
of an injective map which transforms a module -code into a skew cyclic code for
taking advantages of the nice properties of these latter well-known codes. Further-
more, we show some connections between these three kinds of dual codes, we give a
program for obtaining factorizations of a polynomial in a skew polynomial ring and
a technique to construct a -code. Finally, we generalize to this new context some
known results about codication and decodication. In the last part of this work,
we apply the previous theory to the more general case of some codes invariant by
semi-linear transformations of F
n
q
for n 2 and we hope that all the above results
will be a future topic of interest also for further studies of skew quasi-cyclic codes.
DUAL CODES OF PRODUCT SEMI-LINEAR CODES 37
References
[1] W. Bosma, J. Cannon and C. Playoust, The Magma algebra system. I. The user language, J.
Symbolic Comput. 24 (1997), no. 3-4, 235265.
[2] D. Boucher and F. Ulmer, A note on the dual codes of module skew codes, Cryptography and
coding, Lecture Notes in Comput. Sci. 7089, Springer, Heidelberg, 2011, 230243.
[3] D. Boucher and F. Ulmer, Linear codes using skew polynomials with automorphisms and
derivations, Des. Codes Cryptogr. 2013, DOI 10.1007/s10623-012-9704-4.
[4] D. Boucher and F. Ulmer, Codes as modules over skew polynomial rings, Cryptography and
coding, Lecture Notes in Comput. Sci. 5921, Springer, Berlin, 2009, 3855.
[5] M. Homma and S.J. Kim, An elementary bound for the number of points of a hypersurface
over a nite eld, Finite Fields Appl. 20 (2013), 7683.
[6] W.Cary Human and V. Pless, Fundamentals of error-correcting codes, Cambridge University
Press, Cambridge, 2003.
[7] N. Jacobson, Pseudo-linear transformations, Ann. of Math. (2) 38 (1937), no. 2, 484507.
[8] Zhuo-Jun Liu and Dong-Dai Lin, A class of generalized cyclic codes, Acta Math. Appl. Sinica
(English Ser.) 16 (2000), no. 1, 5358.
[9] S. Ling and P. Sole, On the algebraic structure of quasi-cyclic codes. I. Finite elds, IEEE
Trans. Inform. Theory 47 (2001), no. 7, 27512760.
[10] O. Ore, Theory of non-commutative polynomials, Ann. of Math. (2) 34 (1933), no. 3, 480508.
[11] J. Rosenthal and Anna-Lena Trautmann, A complete characterization of irreducible cyclic
orbit codes and their Pl ucker embedding, Des. Codes Cryptogr. 66 (2013), no. 1-3, 275289.
Departamento de Matem atica, Universidad de Concepci on, Casilla 160-C, Concepci on,
Chile
E-mail address: ltapiac@udec.cl, atironi@udec.cl

You might also like