Tilburg center for Cognition and Communication P.O. Box 90153 Tilburg University

advertisement
Tilburg center for Cognition and Communication
P.O. Box 90153
Tilburg University
5000 LE Tilburg, The Netherlands
http://www.tilburguniversity.edu/research/institutes-and-research-groups/ticc/cc/technical-reports/
Email: ticc@uvt.nl
Copyright © A.J. van Zanten, 2013.
TiCC TR 2013-002
November, 2013
Gauss Sums, Partitions and Constant-Value
Codes
A.J. van Zanten
TiCC, Tilburg University
Tilburg, The Netherlands
and
V.V. Vavrek
Institute of Mathematics and Informatics,
Bulgarian Academy of Sciences
Tarnovo, Bulgaria
1
Abstract
We study the relationship between partitions of some integer a in GF(p) in distinct parts
of size at most ( p 1) / 2 , and binary vectors a : (a1 , a2 ,...., a( p 1)/2 ) of value defined as
( p 1)/2
ja j . In particular we investigate a group of transformations acting on the
a:
j 1
family A { A0 , A1 ,...., Ap 1} where A i stands for the set of all vectors of value i. By
exploiting properties of this relationship, we are able to determine the sign of the
p 1
n 2 in / p
quadratic Gauss sum G (2) :
. In the last section of this report we apply the
e
p
n 1
the developed theory to derive some relations for certain subsequences of the MorseThue sequence.
2
Contents
1. Introduction
p. 4
2. Gauss sums and partitions
p. 5
3. Definitions and preliminaries
p. 8
4. A group of transformations
p. 10
5. Examples for p = 7, 11, 13 and 17
p. 16
6. Constructing Ai
p. 22
1
from Ai
7. Determining the sign of the Gauss sum G(2)
p. 28
8. Ordering the vectors of GF (2)( p
p. 29
1)/2
in two different ways
9. The Morse-Thue sequence and related properties
References
p. 37
p. 50
3
1. Introduction
As is well known, the following equality holds for any integer p exceeding one
p 1
e2
in / p
0,
(1)
n 0
or, equivalently
p 1
e2
G(1) :
in / p
(2)
1
n 1
which can be considered as the sum of a finite geometric series. In this report we shall
always assume that p is an odd prime.
A less elementary problem is the summation of
p 1
G(2) :
n
n
( )e 2
1 p
p 1
in / p
( n)e 2
in / p
,
(3)
n 1
n
where ( ) is the Legendre symbol, being equal to 1 if n is a square in GF( p) and equal
p
n
to 1 if n is a nonsquare. It will be clear that ( ) can be interpreted as a character of
p
the multiplicative group of GF( p) when n runs through all nonzero elements of the field.
Since this character is of order 2, and since it was Gauss who set himself the task to
determine the sum in (3), this sum is usually called G(2) . Similarly, the sum in (1) is
called G(1) , where we may think the trivial character put in front of the e - power.
More generally, one defines a Gaussian sum
( n)e 2
G(k ) :
in / p
n
4
,
(4)
where
stands for a character of the group GF ( p ) * of order k . Here and in the next,
we adopt the convention that if no bounds are indicated, the summation variable runs
from 1 until p 1 .
Even more generally, one defines Gaussian sums with respect to a field F : GF(q) ,
q
p m as
(c) (c) ,
G( , ) :
(5)
c F \{0}
where
is a multiplicative character of F and
for
and
we can substitute
j (g
k
)
e2
ijk / q 1
an additive character. More precisely,
, k {0,1,........,q 2} ,
(6)
where g is a generator of GF (q) and
b (c )
e2
iTr (bc) / q
,
b, c
F.
(7)
One can see the Gaussian sum (5) as a relation connecting the characters of the two
abelian groups of a finite field.
From now on we only shall deal with the quadratic Gaussian sum G(2) . One can easily
derive (cf. e.g. Section 2) that
1
)p,
p
(8)
And so ∣ G (2) 2 ∣= p . Moreover, by replacing in (3) the summation variable n by
one can also show that
n
G ( 2) 2
(
± p , if p 1 mod 4 ,
G(2)
{
(9)
±i p , p
3 mod 4 .
1
) equals 1 for p 1 mod 4
p
and 1 for p 3 mod 4. In May 1801 Gauss conjectured that the true signs in (9) are the
plus signs. However, it took him another four years to prove this conjecture. On August
30, 1805, he wrote in his diary:
“At length we achieved a demonstration of the very elegant theorem mentioned before in
May, 1801, which we had sought for more than four years with all efforts.”
These relations also follow immediately from (8), since (
5
Since then, the above problem is known as “the determination of the quadratic Gauss sum”
or better “the determination of the sign of the quadratic Gauss sum”. Many different
proofs have been found, as well as connections to other mathematical problems of
various nature. For a review we refer the reader to [1]. In the remaining part of this report
we shall investigate the relationship which appears to exist between this problem and the
theory of partitions and algebraic coding theory.
2. Gauss sums and partitions
We consider again the quadratic Gauss sum G(2) in (3) which we now write as
p 1
Sp( )
n
n
( )
1 p
n
e2
,
i/ p
,
(10)
and we also introduce the product
( p 1) / 2
Pp ( )
n
(
n
),
2
.
(11)
n 1
The following lemma can easily be derived.
LEMMA 1
For any odd prime p , and for all b {1, 2, ……, p 1 } one has
(i)
Sp(
2b 2
(ii)
Pp (
b 2
1
)p;
p
1
( )p.
p
)
(
)
Proof: The proofs follow by straightforward calculations. For the sake of convenience,
we only give the proofs for b 1 .
p 1
p 1
p 1
i
j
k
( ) i ( ) j
( ) i k / i . By using l : k / i 2 , we
(i) First we write S p ( ) 2
i 1 p
j 1 p
i ,k 1 p
p 1
obtain S p ( ) 2
p 1
i
l Qi 1
li
i
li
, where Q is the set of quadratic residues in
l Qi 1
GF ( p) . Now, the additive characters of GF( p) satisfy the orthogonality relations
p 1
p 1
i
i 1
(
l i
)
1 , if l
i
p 1 , and
(
l i
)
i 1
6
p 1 , if l
p 1. Applying that ∣ Q ∣
( p 1) / 2 and distinguishing between p 1 (=
p 1
p
the result, which holds for
(ii) Since
1 mod p ) Q and p 1
p 1
p
1 and
1 , respectively.
j
is a primitive 2 p -th root of unity, we have that
( p 1) / 2
for j 1, 2,……, ( p 1) / 2 . Hence, Pp ( ) 2
{

p 1
2n
p ( p 1) / 4
1)
( 1) p
1
n 1
( x 1)( x
p j
p j
n
)}2
(
n
n
)=
n 1
p 1
(
1
( ) p , since
p
j
p 1
n
(
n 1
(1 2 ..... p 1)
Q , yields
(1
n
)
( 1) ( p
1) / 2
(1 x ...x p 1 )
x 1=
n 1
p ( p 1) / 2
p 1
)......(x
( 1)
)
p 1
xp
p
and
1 . We also used the factorization
□
1.
Next we replace the algebraic number
in the expressions (i) and (ii) of Lemma 1 and
also in (10) and (11), by a variable x , and we formulate the following property.
THEOREM 1
Let p be some odd prime. Then there is a
( p 1) / 2
( x 2n 1)
(p
px
2
{ 1 , 1} with
p
p 1
1) / 8
n
n 1
n
( ) x 2n ,
1 p
mod x p
1.
Proof . We write the equality in the Theorem as
Q( x)
mod x p
p R( x) ,
1,
where Q(x) and R(x) are considered as polynomials in ℚ[x]. From Lemma 1, it follows
that the numbers
b
e2
ib / 2 p
, b { 1, 2, ……, 2 p 1} , are all zeros of Q( x) 2
R( x) 2 .
For the p odd values of b , these numbers are also zeros of x p 1 . So, when carrying out
the division algorithm and writing
Q( x) 2 R( x) 2 q( x)( x p 1) r ( x) ,
it follows that r (x) has at least p zeros. But the degree of r (x) is at most p 1 .
Therefore r (x) is the zero polynomial. Furthermore, we have
xp
1 ( x 1)( x p
1
xp
2
....... 1) .
Since the second polynomial in the rhs is irreducible over ℚ for odd primes p , it is
contained in either Q( x) R( x) or in Q( x) R( x) or in both. It is also obvious that these
two polynomials both have 1 as a zero. So, at least one of the two contains
x p 1 x p 2 ....... 1 when factorized. Hence, at least one of the two is identical to zero.
7
Now if both were, it would follow that Q(x) and R(x) both were equal to zero mod
xp
1 which is false. We may conclude that for each odd prime p , there exists a unique
sign
p
□
as indicated in the Theorem.
As a consequence it follows when substituting
Pp ( )
for x that
).
pS p (
(12)
We also have from definition (11) and Lemma 1 (ii) that
Pp ( ) i ( p
because Im (
n
n
) > 0 and Re (
1) / 2
(13)
p,
n
n
0 for n { 1, 2, ……., ( p 1) / 2} . So,
)
p,
p
p 1 mod 8,
p,
p
p
5 mod 8,
{
Sp( )
(14)
i
p,
p
i
p
p,
p
3 mod 8,
p
7 mod 8.
The problem of the sign of the quadratic Gauss sum turns out to be equivalent to the
determination of the sign p in the polynomial equality of Theorem 1. To this end we
compare the coefficient c 2 a of x 2 a , for some integer a , in both sides of the equality. In
the rhs this coefficient is equal to
p
2 a
(
) , where
p
p
( p 2 1) / 8 .
2
GF ( p) is defined by
(15)
To determine c 2 a in the lhs, we consider the N a partitions of a into unequal parts of
size at most ( p 1) / 2 . More precisely, we study the equation
n1
n2
.......... nk
a mod p ,
(16)
k 0 , such that all ni , 1 ni ( p 1) / 2 , are different. If N ea and N oa denote the
number of the partitions with even k and odd k , respectively, then c 2 a equals
( 1) ( p
1) / 2
(Ne
N o ) . The study of such partitions will be the subject of the next section.
8
3 Definitions and preliminaries
Let p be some odd prime. We shall study the partitions of positive integers a consisting
of unequal parts the size of which is at most p 1 / 2 . It will be obvious that we can
represent such partitions by binary vectors c (c1 , c2 ,......,c( p 1) / 2 ) of length ( p 1) / 2 .
Here, ci = 1 if and only if the partition contains a part of size i . We interpret all vectors
as row vectors. The number of ones in such a vector c is called the weight of the partition
and is denoted by ∣c∣. It stands for the number of parts in the partition. Let c be some
partition. We define
( p 1) / 2
jc j mod p
a
(17)
j 1
and call a the value of c or val (c ), with a {0,1,........, p 1}. For a fixed value a ,
we collect all vectors having this value in a set Aa consisting of ∣ Aa ∣ binary vectors of
length ( p 1) / 2 . So, this set contains all “conventional” partitions of the integers
a, a p, a 2 p,........into unequal parts of size at most ( p 1) / 2 . We shall call such a set
a constant-value code modulo p or briefly a constant-value code. Corresponding to the
last lines of the previous section, we introduce integers N ea and N oa , being the number of
vectors in Aa with an even number of ones and an odd number, respectively. The
complement of a partition c is defined as the partition corresponding to the vector c c = c
+ 1 , where 1 is the all-one binary vector of length ( p 1) / 2 Since the value of 1 is
equal to
L : ( p 2 1) / 8 mod p,
(18)
all vectors of a set Aa have a complement of the same value L a . Hence, we can write
Aa c AL a , and we call Aa c the complement of Aa . We also need the “value of the
first half of 1”, defined by
K
for p
1 2 .......... [( p 1) / 4]
( p 2 ± 2 p 3) /32 mod p ,
(19)
± 1 mod 4 . Consequently we have
L 4K
(1∓ p) / 4 mod p .
9
(20)
Furthermore, from definitions (15) and (18) it follows that
2
L
( p 2 1) / 8
(21)
as equality in GF( p) .
In order to deal with the sets Aa , a {0,1,........, p 1} , we also introduce the integer
2( p
1) / 2
1
p
N ( p)
, p ± 3 mod 8 ,
{
(22)
2( p
1) / 2
1
p
, p
±1 mod 8.
4. A group of transformations
Let I {1, 2, ……….. ( p 1) / 2 } and let m be some integer with 1 m
For each such m , we introduce index sets
I1
I1m : {i : i
I , mi
I} ,
I2
p 1.
I 2m : I \ I1m ,
(23)
where the product mi is taken mod p. As is already indicated in (23), we shall omit
sometimes the parameter m, when there will not rise confusion which value m has
The sum of the integers in I 1 , respectively I 2 , will also play a role in the next. We
define
i,
Sm :
Sm ' :=
i,
(24)
i I2
i I1
both taken mod p .
m
The sets I 1 and I 2 are closely related to Gauss’ criterion for the value of ( ) ,
p
m GF( p) , being 1 if m is a square and 1 if m is not a square in GF( p) .
following lemma will illustrate this.
LEMMA 2
m
(i) ( ) ( 1) , with
p
∣ I2 ∣ ;
10
The
(ii) S
Sm' ;
m
(iii) for all non-zero m
GF( p) one has
m
Sm
m 1
and
m
Sm'
m 1
.
Proof. (i) Let I 1 {a1 , a 2 ,.......} and I 2 {b1 , b2 ,.......}. For any a i I 1 , the numerically
least residue mod p is equal to a i , whereas for any bi I 2 this value equals bi . So
equality (i) is precisely Gauss’ criterion (cf. e.g. [3, p. 519]).
(ii) This relation follows immediately from the observation that the set I 1 for m is
identical to the set I 2 for m .
(iii) It can easily be proved (cf. [ 3, p.519}) that the numbers ma1 , ma 2 ,…, mb1 , mb2 ,....
are a permutation of 1, 2, …., ( p 1) / 2 . Hence, we have mod p the equality
m( S m
Sm' )
(ma1
ma2
Furthermore, m( S m
Sm )
'
.....) (mb1
m
a
mb2
....) 1 2 ....... ( p 1) / 2
L.
mL . The two relations in the Lemma now follow
a I
□
immediately.
Next, we define for each m GF( p) * a permutation matrix Pm of size ∣I∣x∣I∣ with
elements
pi , j
1, j
mi mod p , i
I 1 , or j
{
mi mod p , i
I2 ,
(25)
pi , j
0 otherwise.
Apart from cases where we need the m -dependence of Pm explicitly, we shall omit the
index m in the next.
THEOREM 2
Let l be the order of m mod p , i.e. ord p (m) l . Then the matrix P defined by (25)
represents a permutation on I consisting of ( p 1) / l cycles of length l /2, for l even, and
of ( p 1) / 2l cycles of length l , for l odd.
Proof. Consider the mapping ℘: GF( p) GF( p) , ℘ (a) ma . This mapping, which
permutes the elements of GF( p) , can be modified into a permutation of the elements of
I in the following way. First, ℘ permutes the nonzero elements of GF( p) according to
( p 1) / l cycles of length l . Next, we change all elements a in these cycles which are
not in I into a': a p , and then we omit the minus sign of a' . If 1 is in the same
cycle as 1, which is the case if l is even, this cycle of length l is transformed into a cycle
11
of length l / 2 followed by the same cycle of length l / 2 , while all elements now are in I .
The same holds for all other cycles. If 1 and 1 are in different cycles of length l , which
is the case if l is odd, then both cycles become identical after changing the minus signs.
So, when omitting repeated cycles, we end up with a permutation of the elements of I as
described in the theorem. For the mapping ℘
matrix P represents the mapping ℘
1
1
the same holds. More precisely, the
We define the following translation vector in GF (2) ( p
t m = (t1 , t 2 , ……., t ( p
1) / 2 ) ,
□
, modified by the above procedure.
tj
1 iff j
1) / 2
for every m GF ( p)*
mi mod p , i
Another way to characterize the vector t is by saying that t j
I1 .
1 if and only if j
(26)
mI1 ,
where mI 1 stands for the set {mi : i I1} . Similarly, we can say that if the matrix element
mI 2 . Notice that the following relations hold mod p
pi , j 1 , then either j mI1 or j
I
where
I1
I2 ,
I
mI1
mI 2 ,
(27)
stands for disjunct union.
The matrices Pm and the vectors t m satisfy the following elementary properties which
will be used in the theory to be developed in the remaining part of this report.
LEMMA 3
(i) Pm n Pmn for all m GF( p) * and for all n ℤ .
(ii) When ( Pm n ) i , j
1 , then j
number of elements from
elements from mI 2 .
(iii) t m = t m +1.
m n i if the set {i, mi, m 2 i,....., m n 1i} contains an even
mI 2 , while j
m n i if this set contains an odd number of
Proof. (i) As a consequence of definition (25), we have that the i , j - elements of both
matrices are equal to 1 if and only if j ± m n i .
(ii) This statement is obvious from the definitions of the matrix Pm and the set I 2 ;
(iii) The sets I 1 and I 2 corresponding to
m are equal to the sets I 2 and I 1
□
respectively, corresponding to m .
12
Like in the case of the matrix Pm , we shall often omit the index m and just write t when
it is obvious what m -value is meant.
Next, we consider for some fixed m -value, the transformation
Tm : GF (2) ( p 1) / 2
GF (2) ( p 1) / 2 defined by
Tm ( c ) = c Pm + t m .
(28)
Since Pm is invertible, so is Tm , and hence it permutes the vectors of GF (2) ( p
THEOREM 3
Let m be a generator of GF( p) * , then for all c GF ( p )( p
(i) Tm
( p 1) / 2
( c ) c c for p 1 mod 4, and Tm
( p 1) / 2
(ii) the order of Tm as permutation of GF (2) ( p
and to ( p 1) / 2 for p 3 mod 4.
1) / 2
1) / 2
1) / 2
.
.
( c) = c for p
3 mod 4;
is equal to p 1 for p 1 mod 4,
Proof. For the sake of convenience, we adopt in this proof the notation l : p 1 , being
the order of m .
(i) For an arbitrary value of n
0 we have
Tm n ( c) = c P n + t ( P n
1
.......... P
E) .
(29)
According to Theorem 2, the permutation matrix P represents one cycle d of length l/2,
which we write as d (d1 d 2 ……. d l / 2 ) , d i I . Hence, c P l / 2 c . In order to
determine the second term in the rhs of (29) for n l / 2 , i.e. t’:=t ( P l / 2 1 ...... P E ) ,
we remark that for this n -value, the matrix between parentheses is equal to the all-one
md i 1 mod p . Let d
matrix. For each i mod l /2, we have either d i md i 1 or d i
contain r elements from I 2 , then d1 ( 1) r m l / 2 d1 ( 1) r 1 d1 , since ml 1 , and so r
must be odd (cf. Lemma 3 (ii)). If p 1 mod 4, we have that l /2 is even. It follows that
d contains an odd number of elements from I 1 . From definitions (23) and (26) it now
follows that t contains an odd number of ones. We conclude that t’ = 1, and hence Tm l / 2 (
c) = c + 1 = c c . If p 3 mod 4, then l / 2 is even, and it follows similarly that d
contains an even number of elements from I 1 and that t contains an even number of ones.
So, t’ = 0, and hence, Tm l / 2 ( c ) c + 0 = c.
13
(ii) Let p 1 mod 4. We know already that Tm p
that Tm n (c) = c for all c GF ( p) ( p
from (29) that c ( P
n
E ) = t( P
1) / 2
n 1
1
I , the identity operator. Assume
, for some n with 0
n
p 1 . It then follows
E ) for all vectors c . Multiplying next by
........ P
P E provides us with (c’ + t) ( P n E ) = 0, for all c’ , where c’ = c ( P E ) . This can
only be true if P E is the zero matrix, and so n l / 2 . But this contradicts the first
relation in (i). Hence, the order of Tm is equal to p 1 in this case.
For p 3 mod 4, the proof is completely similar.
□
THEOREM 4
Let m be some element of GF( p) * and let m
Proof. If I 1
1
be its inverse, then Tm 1 = Tm 1 .
{a, b,.......} is the index set corresponding to m , then I1 ' {ma, mb,.......}
is the index set corresponding to m 1 , as will be clear from the definition of I 1 in (23).
If P and t are the permutation matrix and translation vector w.r.t. m and if P ' and t’
stand for the same notions w.r.t. m 1 , then it will be obvious from the definitions (25)
and (26) that P' PT P 1 and t’ = t P T t P 1 . Hence, Tm 1 Tm ( c) = c PP ' + t P ' + t’ =
□
c PP 1 + t P 1 + t P 1 = c, for all c.
THEOREM 5
For each m, 1 m
p 1 , Tm induces a permutation
A1 , ………, A p 1 } such that
m ( Aa )
Ab , with b
m
m( S m
on the family of sets A { A0 ,
a) and S m
i.
i I1
Proof. Let a Aa with value a. First, we shall determine the value b of the vector b =
Tm ( a). The components ai with i
I 1 contribute
mi(1 ai ) to b, while those in I 2
i I1
yield
( p mia i ) . Hence, both contributions together and taken mod p, give b =
i I2
−
miai = mS m
mi
i I1
ma . Applying Theorem 4 now gives that there is a one-one
i I
correspondence between the vectors of Aa and those of Ab with b
Examples
m 2
I1 { 1, 2, …., [( p 1) / 4] }, I 2
t = (0, 1, 0, 1, …………),
b = 2( S 2 a ) 2( K a ) ;
14
I \ I1 ,
m( S m
a) .
□
m
( p 1) / 2
m
p 1
I 1 = {1, 3, 5, ………..}, I 2 = {2, 4, 6, ………},
t = (0, 0, 0,…,0, 1, 1, 1,….,1),
b = ( p 1) / 2 (S ( p 1) / 2 a) = ( p 1) / 2 ( L K a) ;
I 1 ∅, I 2 I ,
t = 0, P E .
b = a.
m 1
I1 I , I 2
,
t = 1, P E ,
b S1 a L a .
The permutations m , 1 m p , generate a permutation group G A on the family A of
constant-value codes. In the remaining part of this section we shall investigate this group
somewhat closer.
Let wi ,n be the value of the set m n ( Ai ), for fixed m and n 0 . According to Theorem 5,
the integers wi ,n satisfy in GF( p) the recurrence relation
wi ,n
m( S m
wi ,n 1 ) ,
wi ,0
i,
(30)
This recurrence relation is linear and can easily be solved, yielding
wi ,n
(1 ( m) n ) i( m) n =
(i
)( m) n .
(31)
Here, we also applied Lemma 2 (ii).
THEOREM 6
(i) for any m GF( p) one has
n
m
mn
for n odd and
n
m
(ii) G A has one orbit {A } of size 1, whereas all other Ai , i
size p 1 ;
(iii) the permutation
(iv) for all i
generates G A if and only if
mn
for n even;
, are in one orbit of
is a generator of GF ( p ) * ;
one has ∣ Ai ∣ = N ( p) , whereas ∣ A ∣ = N ( p) 1 for p ±1 mod 8,
and ∣ A ∣ = N ( p) 1 for p ±3 mod 8.
Proof. Part (i) follows easily by applying (31) with n 1 and replacing m by m n in the
odd case, and by m n in the even case.
Generally, the permutation m generates a subgroup of G A . From (31) we have that the
equation wi,n i is equivalent to
15
(
i )(1 ( m) n )
0.
(32)
Let l be the order of m mod p . The only i -value which satisfies eq. (32) for some
fixed n with 0 < n < l, is i
. So, A is invariant with respect to all transformations of
G A . Furthermore, it will be clear from (31), that the length of the orbit to which Ai ,
, belongs under the action of m , is equal to l . So, if we take m
, where
is a
i
generator of GF ( p)* , the orbit has length p 1 .Part (iv) follows immediately from the
fact (cf. Theorem 7) that all Ai , i
, have the same size, while│ A │=│ Ai │ 1 .
□
We remark that Theorem 6(i) with n
Theorem 4.
1 is also an immediate consequence of
5. Examples for p = 7, 11, 13 and 17
In this section we present examples for the cases p = 7, 11, 13 and 17 which represent all
possibilities mod 8.
(i) For p = 7, we have I {1, 2,3} , L 6 ,
3 and K 1 .
In this case 2 generates the group GF (7) * , whereas 2 does not.
For m
2 we obtain I 1 {2,3} , I 2 {1} and
0 1 0
0 0 1 , t = ( 1, 0, 1 ).
1 0 0
P2
3
Hence, T2 ( c) = c P 3 + t ( P 2
The constant-value codes are
A0
P
{(0,0,0)}, A1
A3
A4
Since
E ) = c + 0 = c, which illustrates Theorem 3 (ii).
{(1,0,1)} ,
{(1,0,0)} , A2
{(0,1,0)} ,
{(0,0,1), (1,1,0)} ,
A5
{(0,1,1)} ,
A6
2 is a generator of GF (7) * , the transformation
{(1,1,1)} .
2
Theorem 6, and it acts transitively on the family { Ai ∣ i
I 2 {2,3} , and so S 2 1 and S 2 ' 5 . The transformation
b 2(1 a) mod 7 gives rise to the orbits
16
generates the group G A by
} . For m 2 one has I 1 {1} ,
2 ( Aa )
Ab with
A3 ,
A3
whereas
A0
A2
Ab , with b
2 ( Aa )
A6
A4
A5 ,
A4
A1
(ii) For p 11 we have the following data: L
A6
A2
2, K
4,
*
P2
1
0
0
0
0
0
0
1
0
1
0
0
A1
3.
2 is not. For m
In this case 2 is a generator of the group GF (11) , and
I1 {1, 2} which gives rise to
0
0
0
0
A0 ,
A1
2( 5 a) mod 7, produces the orbits
A3 , A0
A3
A5
2 we obtain
0
0
1 , and t = (0, 1, 0, 1, 0).
0
1 0 0 0 0
It follows immediately that (cf. also Theorem 3(ii) and its proof)
5
T2 ( c) = c P 5 + t ( P 4
....... P
E ) = c E + t J = c + 0 = c.
The family A of constant-value codes consists of the sets:
A0
{(0,0,0,0,0), (0,1,0,1,1), (1,1,1,0,1)} ,
A2
A1
{(1,0,0,0,0), (0,0,1,1,1), (1,1,0,1,1)} ,
{(0,1,0,0,0), (1,0,1,1,1)} ,
A3
{(0,0,1,0,0), (1,1,0,0,0), (0,1,1,1,1)} ,
A4
{(0,0,0,1,0), (1,0,1,0,0), (1,1,1,1,1)} ,
A5
{(0,0,0,0,1), (1,0,0,1,0), (0,1,1,0,0)} , A6
{(1,0,0,0,1), (0,1,0,1,0), (1,1,1,0,0)} ,
A7
{(0,1,0,0,1), (0,0,1,1,0), (1,1,0,1,0)} ,
A8
{(0,0,1,0,1), (1,0,1,1,0), (1,1,0,0,1)} ,
A9
{(0,0,0,1,1), (0,1,1,1,0), (1,0,1,0,1)} ,
A10
{(1,0,0,1,1), (0,1,1,0,1), (1,1,1,1,0)} .
Since 2 is a generator of GF(11) , the transformation
2
9
is a generator of G A
according to Theorem 6, and it acts transitively on the family { Ai ∣ i
apply Theorem 5, we obtain for m 9 that I 1
17
2} . In order to
{3, 4, 5}, and hence S 9
3 4 5 1
mod 11. Indeed, the relations
transformations:
A2
A2 , A0
A9
A5
Ab and b
9 ( Aa )
A8
A3
9(1 a) , mod 11, provide us with the
A4
A6
A10
A7
A0 .
A1
Since 2 does not generate GF (11) * , we cannot apply Theorem 6 (i) for
2 . For
m
2 , we have I 1 {1,2} and S 2 3 . When applying 2 ( Aa ) Ab , b 2(3 a)
mod 11, we obtain
A2
So,
A2 , A0
2
A6
A5
A7
A0 ,
A3
A1
does not act transitively on the family { Ai ∣ i
A4
A9
A10
2} .
2
It also follows from the above sequence of transitions that the group element
orbits
A2
A2 , A0
A5
A3
A6
A7
We compare these orbits with those of
S7
7 and b
sets Ai as
A0 , A1
7.
22
A2
For m
A8
A4
has
A10
7 , we find I 1
A1
{2,5} , and so
did, thus illustrating the even case of Theorem 6 (i). The odd case is
2
{2,3} , S 8
respect to
A9
2
7(7 a) . The latter relation gives the same sequences of indices of the
2
3
demonstrated by comparing the transformations
I1
A1 .
A8
5 and b
2
and
8.
23
For m 8 we find
8(5 a) . This last equality yields the following orbits with
8:
A2 , A0
A7
A6
A3
A5
A0 ,
As one can easily verify, the transformation
3
2
A1
A10
A4
A8
A9
A1
gives rise to the same orbits.
As an illustration of Theorem 4, we take m 9 1 5 mod 11. Now, we find I 1 {1,3,5}
and S 5 9 . By applying b 5(9 a) , we derive that 5 permutes the sets of A in
reversed order as 9 did :
A0
A1
A7
A10
A6
A4
A3
A8
Similarly, we derive for m 6 2 1 mod 11, that I 1
applying b 6(6 a) the permutation
A0
A3
A7
A5
A6
A0 , A1
18
A8
A5
A9
{2,4} , S 6
A10
A9
A0
6 and next by
A4
A1
which shows that
1
2
6
(iii) For p 13 we find L
2
8,
1
.
4, K
6
*
Both 2 and 2 are generators of GF (13) .
For m 2 we have I1 {1, 2, 3} and I 2 { 4, 5, 6}, from which we infer
0 1 0 0 0 0
0 0 0 1 0 0
P2
0 0 0 0 0 1
0 0 0 0 1 0
, and t = (0, 1, 0, 1, 0, 1).
0 0 1 0 0 0
1 0 0 0 0 0
6
So, T2 ( c) = c P 6 + t ( P 5
For m
........... P
2 we have I 1
E ) = c E + t J = c + 1 = c c (cf. Theorem 3).
{4, 5, 6} and I 2
{ 1, 2, 3}, and hence
0 1 0 0 0 0
0 0 0 1 0 0
P2
0 0 0 0 0 1
0 0 0 0 1 0
, and t = (1, 0, 1, 0, 1, 0).
0 0 1 0 0 0
1 0 0 0 0 0
Again it follows that T
6
2
( c) = c + 1 = c c .
19
The constant-value codes for p 13 are:
(0, 0, 0, 0, 0, 0)
(0, 0, 1, 1, 0, 1)
(0, 1, 0, 0, 1, 1)
(1, 0, 1, 1, 1, 0)
(1, 1, 0, 1, 0, 1)
(1, 0, 0, 0, 0, 0)
(0, 0, 1, 0, 1, 1)
(1, 1, 0, 0, 1, 1)
(1, 0, 1, 1, 0, 1)
(0, 1, 1, 1, 1, 0)
(0, 1, 0, 0, 0, 0)
(0, 0, 0, 1, 1, 1)
(1, 0, 1, 0, 1, 1)
(0, 1, 1, 1, 0, 1)
(1, 1, 1, 1, 1, 0)
(0, 0, 1, 0, 0, 0)
(1, 1, 0, 0, 0, 0)
(1, 0, 0, 1, 1, 1)
(0, 1, 1, 0, 1, 1)
(1, 1, 1, 1, 0, 1)
(0, 0, 0, 1, 0, 0)
(1, 0, 1, 0, 0, 0)
(0, 1, 0, 1, 1, 1)
(1, 1, 1, 0, 1, 1)
(1, 0, 0, 0, 0, 1)
(0, 1, 0, 0, 1, 0)
(0, 0, 1, 1, 0, 0)
(1, 1, 0, 1, 0, 0)
(0, 1, 1, 1, 1, 1)
} A0
} A7
} A1
(0, 1, 0, 0, 0, 1)
(0, 0, 1, 0, 1, 0)
(1, 1, 0, 0, 1, 0)
(1, 0, 1, 1, 0, 0)
(1, 1, 1, 1, 1, 1)
} A8
} A2
(0, 0, 1, 0, 0, 1)
(1, 1, 0, 0, 0, 1)
(0, 0, 0, 1, 1, 0)
(1, 0, 1, 0, 1, 0)
(0, 1, 1, 1, 0, 0)
} A9
(0, 0, 0, 1, 0, 1)
(1, 0, 1, 0, 0, 1)
(1, 0, 0, 1, 1, 0)
(0, 1, 1, 0, 1, 0)
(1, 1, 1, 1, 0, 0)
} A10
} A3
(0, 0, 0, 0, 1, 1)
(1, 0, 0, 1, 0, 1)
(0, 1, 1, 0, 0, 1)
(0, 1, 0, 1, 1, 0)
(1, 1, 1, 0, 1, 0)
} A4
20
} A11
(1, 0, 0, 1, 0, 0)
(0, 1, 1, 0, 0, 0)
(0, 0, 0, 0, 1, 0)
(0, 0, 1, 1, 1, 1)
(1, 1, 0, 1, 1, 1)
(1, 0, 0, 0, 1, 1)
(0, 1, 0, 1, 0, 1)
(1, 1, 1, 0, 0, 1)
(0, 0, 1, 1, 1, 0)
(1, 1, 0, 1, 1, 0)
} A5
(0, 0, 0, 0, 0, 1)
(1, 0, 0, 0, 1, 0)
(0, 1, 0, 1, 0, 0)
(1, 1, 1, 0, 0, 0)
(1, 0, 1, 1, 1, 1)
} A12
} A6
2 are generators of GF (13) * , the transformations
Since both 2 and
2
4} , according to Theorem 6.
For m
2 we have I1 {4,5,6} , and so S 2 2 . Applying 2 ( Aa )
b
2(2 a) (cf. Theorem 5) yields the chain of transformations:
and
2
act
transitively on the set { Ai ∣ i
A0
A9
A1
A11
A5
A6
A8
A12
A7
whereas 2 ( A4 ) A4 , illustrating Theorem 6.
For m 2 we find I 1 {1,2,3} and S 2 6 , giving rise to
b 2(6 a) .
A4 and
Now we get the orbits A4
A0
A12
A1
A10
A5
A2
A8
A9
A10
A3
2 ( Aa )
A7
Ab , with
A2
Ab , with
A11
A3
A6
(iv) For p 17 we have L 2 ,
1 and K 10 .
In this case neither 2 nor 2 is a generator of GF (17) * .
'
For m 2 , we have I 1 {1,2,3,4} , I 2 {5,6,7,8} , and so S 2 10 , S 2 9 .
The transformation 2 ( Aa ) Ab with b 2(10 a) mod 17 produces the orbits:
A1
A1 , A0
A4
while
2 ( Aa )
A1
A12
A3
A13
Ab with b
A14
A11
A9
A2
A15
A16
A7
A5
A10
A6
A8
A4
A2
A3
A5
A9
A12
A6
A11
A4
A0 ,
2(9 a) mod 17 gives
A1 ,
A0
A16
A14
A4
A7
A13
A8
A10
A15
21
A0 ,
A0 ,
A0 .
8
8
This shows that 2
I , and hence that neither 2 nor 2 are
I and that 2
generators of G A , which is in accordance with Theorem 6 (iii).
In order to generate G A by a single permutation m we can take m
5 , since 5 appears
to be a generator of GF (17) * . Indeed 5 ( Aa ) Ab with b
5(11 a) mod 17 yields,
starting with A0 , successively Ai -sets with indices 0, 13, 10, 12, 5, 4, 16, 8, 2, 6, 9, 7, 14,
15, 3, 11, 0. This shows that the order of
5
is equal to 16, and also that
5
acts
transitively on the family of sets { Ai ∣ i 1} ( cf. Theorem 6 (ii) and (iii)).
6. Constructing Ai
1
from Ai
In this section we shall discuss a method to transform a vector a Ai into a vector b
Ai 1 . Our method is based on the following. We assume that the matrix Pm ,
m GF ( p)* , in (25) corresponds to one ( p 1) / 2 -cycle which we denote by
d : ( d1 ( 1) d 2 . . . . . d ( p
1) / 2 ) ,
di
I,
(cf. also the proof of Theorem 3). This is the case either if ord p (m)
p ( m)
(33)
p 1 or if ord
( p 1) / 2 and ( p 1) / 2 is odd, according to Theorem 2.
Corresponding to (33) we define a binary vector p of length ( p 1) / 2 , such that its i-th
component is equal to the parity of the number of d j , j i , which are in I 2 . Similarly,
we introduce a vector p’ , the i-th component of which equals the parity of the number of
d j , j i , which are in I 1 . It will be clear that the following relation holds
p’ = p + (0, 1, 0, 1,………) .
(34)
Now, let a be a binary vector of length ( p 1) / 2 representing some partition, and let
val (a) = i . From (33), from the definition of Pm in (25) and from the definition of the
components p i of p, we may conclude that
di
So, since d1
m i 1d1 ( 1) pi , 1 i ( p 1) / 2 .
(35)
1 , we can write mod p
( p 1) / 2
val (a) =
( p 1) / 2
ai i
i 1
( p 1) / 2
( 1) pi adi m i 1 .
a di d i
i 1
i 1
22
(36)
We define a translation vector s a as follows. If ad j
pj , 1
some k , 1 k
j
( p 1) / 2 , we define (s a ) d j
1, 1
j
k , and a d k
p k for
k , whereas all other
components are put equal to zero. So, the above integer k is the smallest index with
a d k p k . Formally, we can obtain s a by
s a = (1,.......,1,0,.......,0) Q ,
(37)
where the vector at the rhs contains k ones followed by ( p 1) / 2 k zeros, while the
permutation matrix Q has elements qi , j 1 if j d i and qi , j 0 otherwise.
From now on, we shall apply the vectors p and p’ only with respect to m
introduce the special vectors
a0
2 . We also
pQ, a c0 = (p + 1) Q = p c Q .
(38)
THEOREM 7
Let ord p (2) be equal to p 1 , or to ( p 1) / 2 with ( p 1) / 2 odd.
(i) if a
Ai 1 , unless a = a c0 ;
Ai , then b = a + s a
(ii) for ord p (2) = p 1 , the translation in (i) gives a one-to-one mapping Ai
Ai 1 ,
A 1 \ { a 0 };
i GF ( p) \ { 1, }, A 1 \ { a c0 } A and A
(iii) for ord p (2) ( p 1) / 2 and being odd, the translation in (i) gives a one-to-one
mapping Ai
Ai 1 , i
GF( p) \ {
1, } , A
1
A \ { a 0 } and A \ { a c0 }
A
1.
Proof. From the conditions of Theorem 7 and by applying Theorem 2, it follows that the
matrix Pm , defined in (25), represents a cyclic permutation of length ( p 1) / 2 . We only
have to take into account the change in the contribution to val (a) due to the components
a d1 ,.......,a d k . These contribute to val (a), applying (36), an amount of
k
( 1) pi a di 2 i
1
mod p , where the signs are determined by the components of p. For
i 1
1 i
k , we only have ( 1) p =
i
1 for those positions where adi
to the definition of k . But these are precisely the positions i
Hence, we find
k 1
val (b) – val (a) =
2i
1
( 1) pk (bd k
0 , for 1 i
k , due
k , where b has ones.
a d k )2 k 1 .
(39)
i 1
For a d k
pk
1 we have bd k
0 and for a d k
p k = 0, bd k
1 and so the second term
in the rhs of (39) always equals 2 k 1 . We conclude that val (b) – val (a) =
(2 k 1 1) 2 k 1 1. The only exception occurs when ad j p j for 1 j
23
( p 1) / 2 .
In that case k is not defined, and a = a c0 = p c Q . Since (a c0 ) di
can write (a c0 ) di = 1
pi , 1 i
( p 1) / 2 , we
p i , and hence by applying (36) we find
( p 1) / 2
( p 1) / 2
pi
c
0
val (a ) =
( 1) (1
pi )2
i 1
,
( 1) pi pi 2 i
val (a 0 ) =
i 1
1
.
(40)
i 1
p 1 , when we have 2( p
So, in case that ord p (2)
1)/2
1 , it follows that
( p 1) / 2
val (a 0 ) – val (a c0 ) =
2i
1
2( p
1) / 2
1 2,
(41)
i 1
On the other hand, we also have (cf. (18))
( p 1) / 2
val (a 0 ) + val (a c0 ) =
L.
i
(42)
i 1
Relations (40) and (41) together yield, using L
2 ,
val (a c0 ) =
1.
val (a 0 )
In case that ord p (2)
1,
( p 1) / 2 , when 2( p
1)/2
(43)
1, we obtain instead of (41), the equality
val (a 0 c ) – val (a 0 ) = 0,
(44)
resulting in
val (a 0 c ) = val (a 0 )
.
(45)
Statements (ii) and (iii) now follow immediately from (43) and (45). The property of the
mappings in (i) and (ii) being really one-to-one, follows from the fact that the
transformations can easily be reversed. Instead of the vector s a as defined in (37), we
then have a vector s a ’,defined by an integer k , such that k is the smallest index with
adk
□
pk .
As for the condition for ord p (2) , the following lemma may be useful.
LEMMA 4
(i) If ord p (2)
p 1 , then p
3 mod 8.
(ii) If ord p (2) ( p 1) / 2 , then p
Proof. (i) Let ord p (2)
1 mod 8.
p 1 . This implies 2( p
2
p 1
1)/2
1 . Assume p
1 mod 8, then 2
would be a square, say 2 a , and hence a
1 which contradicts a p
a GF ( p) and p 2 . So, in this case we have p
3 mod 8.
24
1
1 for
(ii) In general one has that the squares in GF ( p)* constitute a subgroup of index 2. From
the conditition in (ii) we have that <2> is a subgroup of index 2. Since any group has only
one subgroup of index 2, it follows that 2 is a square, and consequently p
1 mod 8. □
REMARK
We remark that the implications in Lemma 4 can not be reversed. For example, ord
14 and ord 31 (2) 5 . we also emphasize that ord p (2) ( p 1) / 2 does not imply
43 (2)
that ord p (2) is odd. A counterexample is p 17 with ord 17 (2) 8 .
For values of m other than 2, we were not able yet to derive results similar to those
presented in Theorem 7. Let us consider the case m = 2 , and assume that 2 generates
GF( p) * . In this case the permutation (33) is identical to the one for m 2 . Since the
2 are equal to the sets I 2 and I 1 with respect to
sets I 1 and I 2 with respect to m
m 2 , the vectors p and p’ for m
2 are equal to p’ and p for m 2 . Expression (35)
now yields
( p 1) / 2
val (a) =
'
( 1) pi ai ( 2) i 1 ,
(46)
i 1
and instead of (38) we now can write for the change in value due to the transformation
b = a + s a , the expression
val (b) – val (a) =
k
( 2) i
1
'
( 1) pk (bk
ak )( 2) k
1
=
i 1
=
( 2) k
1
3
1
( 2) k
1
=
1
(( 2) k
3
1
1) .
(47)
We see that for m = 2 the change in value is in general not the same for the various
vectors of a set Ai , but depends on k . The same is true for other m -values 2 .
Examples
For p 7 we have ord 7 (2) 3 (7 1) / 2 . Since the order of 2 is odd, we may apply
Theorem 7. For m 2 , I 1 {1} , I 2 {2,3} , d ( 1 2 3) and p = (0,0,1).
For a = (0,1,1) A5 , we find k 1 , since a d1 a1 0 p1 . Since Q I in this simple
case, it follows that s a = (1,0,0) Q
(1,0,0) . So, b = a + s a = (1,1,1), which indeed is an
element of A6 . By a similar construction we map a = (0,0,1) A3 onto b = (1,0,1) A4 .
The second vector of A3 , i.e. (1,1,0), has no image under this mapping, illustrating
Theorem 7 (ii), since (1,1,0) = a c0 = p c , and
= p is not the image of a vector in A2 .
25
3 . On the other hand, the vector (0,0,1)
For p 11 , we have ord 11 ( 2) 10 , or equivalently, 2 generates GF(11) * (cf. Section 5
(ii)). For this m -value, we have I 1 {1,2} and I 2 {3,4,5} . The 5-cycle of (33) is equal
to d ( 1 2 4 3 5), and hence p = (0,0,0,1,0) . The matrix Q has the form
1
0
Q= 0
0
0
0
1
0
0
0
0
0
0
1
0
0
0
1
0
0
For a = (1,1,1,0,1)
A0 , we find k
and a d3
p3 . It follows that s a = (1,1,1,0,0) Q = (1,1,0,1,0) . So, b = a + s a =
a4
0
3 , since a d
0
0
0 .
0
1
1
a1
1 0
p1 , a d 2
a2
1 0
p2
(0,0,1,1,1), which indeed is a vector in A1 . If we take a = (1,1,0,1,1) A1 , then k is not
defined, illustrating Theorem 7 (ii), since a c0 = p c Q = (1,1,1,0,1) Q = (1,1,0,1,1) A1 and
2 . Taking for a the vectors (0,1,0,0,0) and (1,0,1,1,1) , both from A2 , yields vectors b
equal to (1,1,0,0,0) and (0,1,1,1,1) , respectively, which are in A3 . The third vector
(0,0,1,0,0) of A3 is the complement of a c0 , so equals thus confirming again Theorem 7 (ii).
For p 13 , we have that both 2 and 2 are generators of GF(13) (cf. Section 5 (iii)).
First we take m 2 , for which we have I 1 {1,2,3} and I 2 {4,5,6} . The 6-cycle of (33)
is equal to d = (1 2 4 5 3 6), and hence p = (0,0,0,1,0,0).
The matrix Q corresponding to d has the form
1 0 0 0 0 0
Q
0 1 0 0 0 0
0 0 0 1 0 0
0 0 0 0 1 0
.
0 0 1 0 0 0
0 0 0 0 0 1
We derive a c0 = p c Q = (1,1,1,1,0,1). Now, val( a c0 ) = 16 = 3 mod 13, and so a
c
0
. According to Theorem 7 (ii), this vector has no image in A4 = A .
Furthermore, val( a 0 ) = 5 mod 13. So, a 0 is in A5 . Again according to Theorem 7 (ii),
A4 are mapped
this vector is not the image of a vector in A4 . The four vectors in A
onto the four other vectors of A5 in the following way:
A3
A
1
(0,0,0,1,0,0)
(1,0,1,0,0,0)
(1,0,0,1,0,0),
(0,1,1,0,0,0),
26
(0,1,0,1,1,1)
(1,1,1,0,1,1)
(1,1,0,1,1,1),
(0,0,1,1,1,1).
In order to illustrate the remark right after Theorem 7, we take m
2 . Of course, we
have the same 6-cycle (1 2 4 5 3 6), from which we infer that I 1 {4,5,6} , I 2 {1,2,3} ,
and hence p’ = (0,1,0,0,0,1), which can also be derived from p by applying (34), and
consequently a 0 ’ = p’ Q = (0,1,0,0,0,1).
The vectors of A3 are mapped in the following way.
a = (0,0,1,0,0,0) with k
1 is mapped onto b = (1,0,1,0,0,0) A4 ,
a = (1,1,0,0,0,0) with k
2 is mapped onto b = (0,0,0,0,0,0) A0 ,
a = (1,0,0,1,1,1) with k
5 is mapped onto b = (0,1,1,0,0,1) A11 ,
a = (0,1,1,0,1,1) with k
1 is mapped onto b = (1,1,1,0,1,1) A4 ,
a = (1,1,1,1,0,1) with k
2 is mapped onto b = (0,0,1,1,0,1) A0 .
These results comply with (47), since the value of (( 2) k
for k 1 , 2 and 5, respectively.
1
1) / 3 is equal to 1,
3 , and 8
□
The permutation d of the integers of the set I {1,2,......,( p 1) / 2} in (33) is written in
such a way that d1 1 . If we choose for a different integer at the first position, say d1 t ,
one can easily verify by adjusting the proof of Theorem 7, that one obtains a one-to-one
mapping from Ai to Ai t with similar properties.
Example
Take p 13 and d (2 4 5 3 6 1). The corresponding parity vector equals p =
(0,0,1,0,0,1) , and the corresponding matrix Q is
0 1 0 0 0 0
Q=
0 0 0 1 0 0
0 0 0 0 1 0
0 0 1 0 0 0
.
0 0 0 0 0 1
1 0 0 0 0 0
This yields the following transformations for the vectors of A3 :
27
a = (0,0,1,0,0,0), a d1
b = (0,1,1,0,0,0);
a2
0
p1 , k
a = (1,1,0,0,0,0), a d1
b = (1,0,0,1,0,0);
a2
1
p1 , a d 2
a = (1,0,0,1,1,1), a d1
b = (1,1,0,1,1,1);
a2
0
p1 , k
a = (0,1,1,0,1,1), a d1
b = (0,0,1,1,1,1);
a2
1
p1 , a d 2
a4
0
p2 , k
a = (1,1,1,1,0,1), a d1
a2
1
p1 , a d 2
a4
1
p 2 , a d3
ad4
k
a3
1
1 , s a (0,1,0,0,0,0) ,
a4
p2 , k
0
2 , s a (0,1,0,1,0,0) ,
1 , s a (0,1,0,0,0,0) ,
p 4 , a d5
a6
1
2 , s a = (0,1,0,1,0,0),
a5
p5 , a d 6
a1
0
p3 ,
1
p6 ,
6 , s a (1,1,1,1,1,1) ,
b = (0,0,0,0,1,0).
As one can see, all b-vectors are in A5 , which confirms the remark on the previous page
with t 2 .
□
7. Determining the sign of the Gauss sum G(2)
In this section we shall derive the correct sign(s) for the Gauss sum G(2) (cf. (9)). Firstly,
we present and prove a theorem concerning the integers N ea and N oa , a {0,1,...., p 1}
which were introduced in Section 2.
THEOREM 8
(i) N e No | A |/2 for any odd prime p;
(ii) if p 1 mod 8, then N o
(iii) if p
(iv) if p
(v) if p
1
3 mod 8, then N o
1 mod 8, then N o
3 mod 8, then N o
1
∣ A ∣/2 1 and N e
1
∣ A ∣/2 and N e
1
1
1
∣ A ∣/2+1;
∣ A ∣/2-1 and N e
∣ A ∣/2 and N e
1
∣ A ∣/2;
1
∣ A ∣/2;
∣ A ∣/2+1.
Proof. (i) These equalities are an immediate consequence of the equalities (cf. Section 2)
2 a
and c2 a ( 1)( p 1)/2 ( N ea N oa ) for a
.
c2 a
p
p
p
(ii) and (iii) Assume p 1 mod 4. Then ∣ A ∣/2 is even as follows from (22) and
Theorem 6 (iv). Let the words (vectors) in Ai , 0 i p 1 , be ordered in some way. So,
28
we have ordered blocks with ( p 1) / 2 columns and N ( p) rows for i
, and N ( p) 1
rows for i
. Changing in column j zeros into ones, and vice versa, yields a one-toone correspondence between the words in Ai with a zero on position j and the words in
Ai
j
with a one on that position for all i GF ( p) and 1
j
( p 1) / 2 . Since ∣ A ∣/2 is
even, the j th column of A has an even number of zeros. It follows that the j th column
of A kj with k 0 has even parity if and only if k is odd.. We conclude that A 1
contains an odd number of columns with odd parity, and hence also an odd number of
rows with odd parity, if and only if the equation kj 1 , k even, j {1, 2,....,( p 1) / 2} ,
has an odd number of solutions or, equivalently, if and only if the equation 2lj 1 ,
l , j {1, 2,....,( p 1) / 2} has an odd number of solutions in GF ( p) . Because of the
symmetry between l and j , this last condition is satisfied if and only if 2 is a square in
GF ( p) . Since this is true if and only if p
1 mod 8, we have in this case that A 1
contains an odd number of rows with odd parity for p 1 mod 8 and an even number of
such rows for p
3 mod 8. From Theorem 6 it follows that for p 1 mod 8 ∣ A 1 ∣=∣
A ∣/2+(∣ A ∣/2 1 ), and for p
3 ∣ A 1 ∣=(∣ A ∣/2+1)+∣ A ∣/2. Since in both
cases ∣ A ∣/2 is even, the relations in (ii) and (iii) now follow.
(iv) and (v) Assume that p
1 mod 4, and so ∣ A ∣/2 is odd. In a similar way as in the
previous case we derive that A 1 contains an odd number of rows with odd parity if and
only if the equation kj 1 , k odd, j {1, 2,....,( p 1) / 2} , has an odd number of
solutions in GF ( p) . Equivalent to this condition is that the equation 2lj
1,
l , j {1, 2,....,( p 1) / 2} has an odd number of solutions. Since p
1 mod 4, this is true
if and only if p 3 mod 8. Hence, we have in this case that A 1 has an odd number of
rows with odd parity if p 3 mod 8 and an even number of such rows if p
1 mod 8.
The relations in (iv) and (v) now follow as in the previous case.
□
As a kind of corollary we now can state the complete expressions for the Gauss sum
G(2) .
THEOREM 9 (Gauss 1805)
For any odd prime p one has G (2)
mod 4
p if p 1 mod 4 , and G (2)
Proof. From Theorem 8 it follows that N e
this result in the relation
p
2
( 1)( p
p
1
1)/2
1
No
( Ne
1
i p if p
1
1 for any odd prime p . Substituting
No 1 ) (cf. the end of Section 2),
□
gives the above result.
29
8. Ordering the vectors of GF (2)( p
1)/2
in two different ways
In order to deal with cases where Theorem 7 cannot be applied, i.e. when ord p (2) is less
than ( p 1) / 2 , or when ord p (2) = ( p 1) / 2 and even, we will use the following lemma.
This lemma will help us to consider the transformation of Theorem 7 in a slightly
different context and to generalize that transformation. In the lemma and in the remaining
part of this report we shall write binary numbers in reversed order, i.e. from right to left.
Accordingly, binary addition, i.e. with carry and denoted by , will be carried out from
left to right. The reason to handle the binary representation of numbers in this way, is to
adjust to the cycle notation of permutations where the permuted objects are ordered from
left to right.
LEMMA 5
(i) Let u be some fixed binary vector of length n . For any v GF (2) n we define a
transformation v w = v + s, where s is defined such that s i 1 for 1 i k , where k
is the first index value with vk uk , while si 0 for i k . When repeatedly applying
this transformation, starting with the vector v 0 := u, one obtains a list v 0 , v 1 = v 0 + s 0 ,
v 2 = v 1 + s 1 , ………… of all 2 n vectors of GF (2) n , ending with the vector v 2 n 1 = u c ;
(ii) If one labels the vectors in this list from 0 until 2 n 1 , the e-th vector v e can be
obtained directly from v 0 u by v e = u e, where e stands for the binary representation
of length n of the integer e (in reversed order);
(iii) If v l is the l-th vector in the list, then v l e +u =(v l u) e for 0 l e n .
Proof. The statement in the Lemma is trivial for u = 0. In that case the order of the
vectors in the list is precisely the natural order of the integers 0, 1, …., 2 n 1 , when the
vectors are interpreted as the binary representations of these integers written from right to
left. Furthermore, it can easily be seen that a list starting with an arbitrary u can be
obtained by adding (in GF (2) n ) the vector u to all vectors of the list corresponding to u
= 0. The list is not cyclic and actually ends with u c , since for that vector the
transformation is not defined . The remaining part of the Lemma follows easily.
Example
For n 3 and u = 101, we obtain the following list by repeatedly applying w = v + s:
v
s
101
100
001
110
111
100
011
111
100
100
30
□
000
110
010
110
100
The word v 6 can be obtained from v 0 (=u) = 101 by v 0
011 =110.
Notice, that when applying Lemma 5 under the conditions of Theorem 7, with
n ( p 1) / 2 , v = a Q 1 , a Ai and u : = p the parity vector corresponding to
permutation d, the result is w = b Q 1 , b Ai
aQ
1
1
(cf. also (37) and (38)). One could say that
is the vector a in d-representation, and therefore we write a d := a Q 1 , and
similarly b d : b Q 1 . Similarly, the vector s a Q 1 in (37) is also in d-representation. Using
this notation and combining Theorem 7 and Lemma 4 with u = p , provides us with the
following theorem. In this theorem d stands for the permutation (33), while
denotes
the addition of two binary numbers of length ( p 1) / 2
THEOREM 10
Let ord p (2) be equal to p 1 , or to ( p 1) / 2 with ( p 1) / 2 odd, and let a
Ai be
represented by a d in d-representation. Let furthermore e be the binary representation of
length ( p 1) / 2 of some positive integer e and written in reversed order. Then the vector
b d , defined by b d + p = (a d + p)
e is the d-representative of a vector b Ai e .
Example
Let p 13 . Then 2 is a generator of GF(13) * . So, the matrix P2 represents the
permutation d (1 2 4 5 3 6) which defines the parity vector p = (0, 0, 0, 1, 0, 0). We
start with the vector a = (1, 1, 0, 1, 0, 1) A0 or with a d = a Q 1 = (1, 1, 1, 0, 0, 1) with
Q as defined inSection 6. First we apply Theorem 10 with e 1 represented by the
binary vector e = (1, 0, 0, 0, 0, 0). Successively, we find a d p = (1, 1, 1, 1, 0, 1), (a d + p)
e = (0, 0, 0, 0, 1, 1), b d = (0, 0, 0, 1, 1, 1) and finally b = b d Q = (0, 0, 1, 0, 1, 1) A1 .
Actually, this construction is nothing else as the construction of Theorem 7, formulated in
a slightly different context.
Next, we take e 7 , represented by e = (1, 1, 1, 0, 0, 0). Starting with the vector a = (0, 1,
1, 1, 1, 0) A1 , we construct successively a d = (0, 1, 1, 1, 1, 0), a d + p = (0, 1, 1, 0, 1, 0),
(a d + p)
e = (1, 0, 1, 1, 1, 0), b d = (1, 0, 1, 0, 1, 0) and b = b d Q = (1,0, 1, 1, 0, 0),
which indeed is a vector in A8 .
In case that we write the permutation d in a different way, the permutation matrix Q and
the parity vector p also change. Say, we write d = (5 3 6 1 2 4) with corresponding parity
vector p = (0, 1, 1, 0, 0, 0). Now, if we start with a = (0, 1, 1, 0, 1, 1) A3 and with e = 1,
31
we find successively a d = aQ 1 = (1, 1, 1, 0, 1, 0), a d p = (1, 0, 0, 0, 1, 0), b d = (a d + p)
e = (0, 1, 0, 0, 1, 0), b = b d Q = (0, 1, 0, 0, 0, 1) A8 .
□
Example
As another example we take the case p 11 and e = (1, 0, 0, 0, 0). We know already that
2 , d = (1 2 4 3 5), p = (0, 0, 0, 1, 0), while Q has the form
Q
1
0
0
0
0
1
0
0
0
0
0
1
0
0
1
0
0
0
0 .
0
0 0 0 0 1
We start with the vector a 0 = p Q = 00100, which is in A3
A . Subsequently, we find,
leaving out brackets and comma’s, a 0d = p = 00010, a 0d + p = 00000, b d + p = (a 0d +p)
e = 10000, b d = 10010, and finally b = b d Q = 10100
A4 .
In a similar way we compute a list containing all 32 vectors of GF ( 2)5 . Below we
present the complete list.
ad + p
bd
A3
00000
10010
A4
A5
A6
A7
A8
A9
A10
A0
A1
A2
A3
10000
01000
11000
00100
10100
01100
11100
00010
01010
11010
00110
10110
01110
11110
00000
10000
10010
01010
11010
01000
11000
00100
00010 A4
10010 A5
01010 A6
11010 A7
00110
10110
01110
11110
10100
01100
11100
00011
a
a 0 = 00100
10100
01100
11100
00110
10110
01110
11110
00000
10000
01000
11000
32
00101
A8
00001
10011
10101
A9
01101
A10
11101
A0
10001
01001
11001
01011
11011
00111
00111
10111
01111
11111
00001
10001
01001
11001
00011
10011
01011
A1
A2
A3
A4
A5
A6
A7
A8
A9
A10
A0
00101
10101
01101
10111
01111
11111
11101
00011
10011
00001
10001
01001
01011
11011
11001
00101
00111
10111
01111
10101
01101
11101
A1
11111
a c0 = 11011
As one can see, the left list starts with the vector a 0 = (0, 0, 1, 0, 0)
c
0
A3 = A
1
and ends
A1 = A 1 , and contains all 32 binary vectors a of length 5. The
with a = (1, 1, 0, 1, 1)
list in the middle contains the corresponding vectors a d + p. One can verify that this list
consists again of all binary vectors of length 5, such that the reversed vectors are in
natural order, starting with (0, 0, 0, 0, 0) and ending with (1, 1, 1, 1, 1), thus
corroborating Lemma 5 and Theorems 7(iii) and 8.
□
Example
For p 7 we have ord p (2) = ( p 1) / 2 = 3 which is odd. The permutation matrix P2
represents the permutation d = (1 2 3). So, Q I . Furthermore, I 1 {1}, I 2 {2, 3},
p =(0, 0, 1),
3 , ∣ Ai ∣ = 1 for i 3 , and ∣ A3 ∣ = 2. It follows that a 0 pQ = (0, 0, 1).
In this case we have the following lists:
a0
a
ad + p
bd
001 A3
101 A4
011 A5
000
101
100
010
011
111
33
111 A6
000 A0
110
000
001
100
100 A1
010 A2
c
a 0 = 110 A3
101
011
111
010
110
□
Now, the left list starts with a 0 A and ends with a c0 A .
From the above examples it will be clear that the easiest way to obtain a list of all vectors
of GF ( 2) ( p 1) / 2 , ordered according to increasing value (17), is as follows. We shall call
that list L p and denote its vectors (words) by a 0 , a 1 , …., a 2( p 1)/2 1 in the next theorem.
THEOREM 11
Let L be the list of the binary vectors of GF (2) p 1/2 in natural order and written from
right to left. Transforming each v of this list into ( v + p )Q yields a list L p which is
ordered such that the value of the corresponding partitions increases by 1 mod p when
going to the next word. The list ℒ p starts with a 0 pQ and ends with a ( p 1)/2 1 = a c0 . For
ord p (2)
p 1 one has a 0 A
1
and a c0 A
1
, whereas for ord 2 ( p) ( p 1) / 2 and odd,
c
0
both a 0 and a are in A .
THEOREM 12
Let C i : { a i jp : j {0,1, 2,....}}, be the set of vectors with indices i, i
of length ( p 1) / 2 in the list ℒ p , for any i with 0 i
(i) If ord p (2)
p 1 , then Ci = A
i 1
for 0 i
p 1.
p 1 , while C p 1 = A .
(ii) If ord p (2) ( p 1) / 2 with ( p 1) / 2 odd, then Ci = A
Example
Take p 13 . Then p = 000100,
i
for 0 i
4 , and the matrix Q has the form
1 0 0 0 0 0
0 1 0 0 0 0
Q
0 0 0 1 0 0
0 0 0 0 1 0
0 0 1 0 0 0
0 0 0 0 0 1
Applying Theorem 11 with i 0 , yields respectively
34
p , i 2 p , ….and
.
p 1.
a0
a 13
a 26
a 39
a 52
000100Q = 000010,
101000 Q = 100100,
= 010010Q = 011000,
= 111101Q = 110111,
= 001111Q = 001111.
These are precisely the vectors of the constant-value code A5 . Observe that the procedure
of constructing vectors in L p from those in L automatically halts when we try to
construct a 65 , since 65 is an integer which has no binary representation of length 6.
By applying Theorem 11 with p 1 12 , we obtain
a 12
a 25
a 38
a 51
= 001000Q = 000100,
= 100010Q = 101000,
= 011101Q = 010111,
= 110111Q = 111011.
These four vectors are the vectors of the family A A4 . Here also, the procedure stops
automatically, since 64 cannot be represented as a binary vector of length 6.
Finally, we give the complete lists L and L p for our running example of p 13 .
L
Lp
0
1
2
3
4
5
6
000000
100000
010000
110000
001000
101000
011000
000100
100100
110100
110100
001100
101100
011100
7
8
9
10
11
12
111000
000100
100100
010100
110100
001100
111100
000000
100000
010000
110000
001000
35
000010 A5
100001 A6
010010 A7
110010 A8
000110 A9
100110 A10
010110 A11
110110 A12
000000 A0
100000 A1
010000 A2
110000 A3
000100 A4
13
101100
101000
100100
A5
14
15
16
17
18
19
20
21
22
011100
111100
000010
100010
010010
110010
001010
101010
011010
011000
111000
000110
100110
010110
110110
001110
101110
011110
010100
110100
001010
101010
011010
111010
001110
101110
011110
A6
23
24
25
26
27
28
29
30
31
32
111010
000110
100110
010110
110110
001110
101110
011110
111110
000001
111110
000010
100010
010010
110010
001010
101010
011010
111010
000101
111110
001000
101000
011000
111000
001100
101100
011100
111100
000011
A2
33
34
35
36
37
38
39
40
41
100001
010001
110001
001001
101001
011001
111001
000101
100101
100101
010101
110101
001101
101101
011101
111101
000001
100001
100011
010011
110011
000111
100111
010111
110111
000001
100001
A12
42
43
44
45
46
47
48
010101
110101
001101
101101
011101
111101
000011
010001
110001
001001
101001
011001
111001
000111
010001
110001
000101
100101
010101
110101
001011
36
A7
A8
A9
A10
A11
A12
A0
A1
A3
A4
A5
A6
A7
A8
A9
A10
A11
A0
A1
A2
A3
A4
A5
A6
A7
A8
A9
A10
A11
A12
A0
A1
49
100011
100111
101011
A2
50
51
52
53
54
55
56
57
58
010011
110011
001011
101011
011011
111011
000111
100111
010111
010111
110111
001111
101111
011111
111111
000011
100011
010011
011011
111011
001111
101111
011111
111111
001001
101001
011001
A3
59
60
61
62
63
110111
001111
101111
011111
111111
110011
001011
101011
011011
111011
111001
001101
101101
011101
111101
A4
A5
A6
A7
A8
A9
A10
A11
A12
A0
A1
A2
A3
9. The Morse-Thue sequence and related properties
In order to deal with the parity of the weight of binary numbers, we introduce the wellknown Morse-Thue sequence
M
m0 , m1 ,...., mi ,..... ,
(48)
where mi stands for the parity of the number of ones in the binary representation of i, i.e.
mi : 0 if the weight│i│ is even and mi : 1 if this weight is odd. One can easily derive
the following recursive rule, which can serve as definition of M
M (2k 1 )
M (2k ) M (2k ) c , M (1) 0 ,
(49)
where M ( j ) denotes the subsequence of the first j elements of M. In the next, a
subsequence of M shall always mean a subsequence of consecutive elements of M, unless
stated otherwise. The following simple properties, collected in a lemma, can easily be
proven by applying (49).
LEMMA 6
(i) M does not contain subsequences consisting of three consecutive identical elements.
m2k i for all i 0 , transforms M into itself for all k 0 .
(ii) The substitution mi
37
(iii) The substitution rules 0 01 , 1 10 , together with the initiator M (1) 0 ,
generate the sequence M.
(iv) For all i 0 one has m2i mi , m2i 1 mi 1 .
(v) For all even i 0 one has mi 1 mi 1 , and for all odd i 0 , mi 1 mi 1 .
Now, let M ' mi , mi 1 ,...., mi 2 k and M '' mi , mi 1 ,...., mi 2 k 1 be subsequences of M of
length 2k 1 and of length 2k , respectively, consisting of consecutive elements, and let
furthermore n1 be the number of ones and n0 be the number of zeros in either of these
sequences. Then we can derive the following lemma.
LEMMA 7
(i) In M’ one has for even i and any k
mi 2 k 0 .
0 , n1 n0 1 if mi
2k
1 , and n1 n0
1 if
1 if mi 0 .
(ii) In M’ one has for odd i and any k 0 , n1 n0 1 if mi 1 , and n1 n0
(iii) In M’’ one has for any k 1 , n1 n0 0 , except if i is odd and mi mi 2 k 1 0 or
mi mi 2 k 1 1 , when n1 n0
2 and n1 n0 2 , respectively.
Proof. We shall prove the Lemma by induction on k. Both statements are trivially true
for k 0 . Assume the statements are true for some k 0 . Let M '' M ', mi 2 k 1 , mi 2 k 2
be a subsequence of length 2k 3 .
(i) If i is even, then i 2k is even. In case that mi 2 k 2 1 , we have M '' M ',0,1 or
M '' M ',1,1 . In the first case, M ' ends at 1 and in the second case at 0, because of
Lemma 5 (v). From the induction assumption it now follows that for M '' the difference
n1 n0 is equal to 1 0 1 in the first case, and to 1 2 1 in the second case. If
mi 2 k 2 0 , we have M '' M ',0,0 or M '' M ',1,0 with M ' ending at 1 and 0
respectively. Hence, again applying the assumption condition, the difference n1 n0 for
1 in the second. So, statement
M '' is equal to 1 2
1 in the first case, and to 1 0
(i) holds for k 1 .
(ii) If i is odd, then i 2k 2 is odd. Again by Lemma (v), we may conclude that
M '' M ',0,1 or M '' M ',1,0 . From the induction assumption it follows that in case that
if mi 1 , the difference n1 n0 equals 1 0 1 . If mi 0 , this difference equals
1 0 1. So, statement (ii) also holds for k 1 .
By the principle of mathematical induction both statements hold for all k 0 .
Part (iii) is a consequence of (i) and (ii).
□
In the next we consider the integers in the set {0,1,...., n 1} with n 2( p 1)/2 and written
in binary, which provides us with all binary numbers of length ( p 1) / 2 . As for our
notation, when writing a mod n we mean the integer in {0,1,...., n 1} which is equal to
38
a modulo n . Each of these integers can be written as i jp with 0 i p 1 and
0 j N ( p) 1 , except for n 1 N ( p) p in the case p
1 mod 8 (cf. (22)). For a
given integer a, one obtains i and j by dividing a by p. The quotient is equal to j and
the remainder to i . Next we order all integers of the set {0,1,...., n 1} lexicographically
with respect to i and j , and we call the resulting list L’. It is obvious that L’’ can be
written as a concatenation of p sublists
L’ = B0 , B1 ,...., B p 1 .
(50)
It will also be clear that the set Ci (cf. Theorem 12) consists of the binary representations
(written from left to right) of the integers in Bi , 0 i p 1 .
For p
3 mod 8 the sublists themselves are of the form
Bi
i, i 1 p,...., i ( N ( p) 1) p , 0 i
Bp
For p
1
p 1,
(51)
p 1, 2 p 1,...., ( N ( p) 1) p 1 .
(52)
1 mod 8 we have
Bi
i, i 1 p, i 2 p,...., i ( N ( p) 1) p , 0 i
B0
p 1,
(53)
0,1 p, 2 p,...., ( N ( p) 1) p, N ( p) p .
THEOREM 13
Let p be an odd prime such that ord p (2)
(54)
p 1 . Let F be a mapping defined by
F (b) 2b 1 mod N ( p) p , for all b {0,1,..., n 1} .
(i) F is a one-to-one mapping on {0,1,...., n 1} .
(ii) F generates orbits of length k, with k : ord p (2) p 1 , on the set of elements not in
Bp
1
and each orbit contains precisely one element of Bi , for any i
p 1.
(iii) On the family of sets {Bi ∣ i p 1} F generates one orbit of length p 1 .
(iv) F induces a permutation of the elements of B p 1 , and the number jp 1 Bp 1 lies in
an orbit of length k j , which is equal to the order of 2 mod N ( p) / ( j, N ( p)) , for
1 j N ( p) 1 ..
(v) If bl 1bl 2 ....b0 , with l : ( p 1) / 2 , is the binary representation of b in GF (2)( p
1)/2
,
c
then bl 2 ....b0bl is the binary representation of F (b) .
(vi) If nei denotes the number of binary words in Bi with an even number of ones and noi
the number with an odd number of ones, then nep
39
1
nop 1 .
(vii) If Fkp i is the mapping defined on {0,1,...., n 1} by Fkp i (b)
N ( p) p , for any fixed k and 0 i
elements of Bi if i
i
jp
Bi , 0
p 1 , then Fkp
i
p 1, and of the elements of B p
2b kp i mod
induces a permutation of the
1
if i
p 1 . The integer
N ( p) 1 , lies in an orbit of length k j which is equal to the order of
j
2 mod N ( p) / ( j k , N ( p)) , if j
of Fkp i .
k mod N ( p) . The integer i kp
Proof. We remark that because of the assumption ord p (2)
Bi is a fixed point
p 1 , we have from Lemma
4(i) that p
3 mod 8. Therefore, we have to take (51) and (52) as definition of the sets
Bi .
(i) From F (b) F (c) it follows that b c 0 mod N ( p) p , and so b c , since both are
less than N ( p) p . This implies the statement.
(ii) Take b Bi , i p 1. Then F a (b) 2a b 2a 1 mod N ( p) p . Putting F a (b) b
yields the equation (2a 1)(b 1) 0 mod N ( p) p . Since b B p 1 , we have b 1 0
mod p . Hence, 2a 1 0 mod p , and so a ord p (2) .
(iii) This is a consequence of (ii).
(iv) Consider b : jp 1 B p 1 , 1 j N ( p) 1 , Then F (b) 2 jp 1 mod N ( p) p . If
N ( p) , we have by definition that 2 jp 1 B p 1 . If 2 j
2j
N ( p) , we subtract N ( p) p
and obtain (2 j N ( p)) p 1 which is clearly also in B p 1 . Applying F a , a
jp 1 Bp 1 , 1
j
0 , on
N ( p) 1 , and putting the result equal to jp 1 itself, yields the
a
equation (2 1) jp 0 mod N ( p) p , or equivalently (2a 1) j 0 mod N ( p) . The
result follows immediately.
(v) If bl 1 0 , the value of bl 2 ....b01 is 2b 1 which is equal to F (b) , since
b (n 1) / 2 , and hence 2b 1 n N ( p) p 1 . If bl 1 1 , the value of bl 2 ....b0 0 is
equal to 2b n 2b pN ( p) 1 . Now, b n / 2 and so 2b 1 n N ( p) p . According
to the definition of F , we again can identify this result with F (b) .
(vi) This follows immediately from (iv) and (v), since any time F is applied on an
element of B p 1 , the parity of its binary representation changes.
(vii) Consider b : i
jp
Bi , 0
j
N ( p) 1 . Then Fkp i (b) i (2 j k ) p mod
N ( p) p . Similary as in the proof of (iv), it follows that this integer is always in Bi . The
value of the orbit length k j is derived in a similar way as in the proof of (iv). Applying
Fkp
a
i
, a
0 , on i
jp
Bi , and putting the result equal to i
jp , yields the equation
(2a 1)( j k ) 0 mod N ( p) . For j
k mod N ( p) , the result now follows
immediately. For j
k we obtain that Fkp i (i kp) 2(i kp) kp i i kp .
THEOREM 14
40
□
Let p be an odd prime such that ord p (2) is equal to ( p 1) / 2 and odd. Let furthermore
G be the transformation defined by G(b) 2b mod N ( p) p , for all b {0,1,..., n 1} .
(i) G is a one-to-one mapping on {0,1,...., n 2} .
(ii) G generates orbits of length k : ord p (2) ( p 1) / 2 on the set of elements not in B0
and each orbit contains at most one element of Bi , i
0.
(iii) On the family of sets {Bi ∣ i 0} G generates two orbits of length ( p 1) / 2 .
(iv) G induces a permutation of the elements of B0 \{n 1} , and the number jp B0 lies
in an orbit of length k j which is equal to the order of 2 mod N ( p) / ( j, N ( p)) , for
0 j N ( p) , while 0 is a fixed point.
(v) If bl 1bl 2 ....b0 , with l : ( p 1) / 2 , is the binary representation of b in GF (2)( p
then bl 2 ....b0bl 1 is the binary representation of G(b).
1)/2
,
(vi) If nei and noi denote the number of binary words in Bi of even parity and of odd
parity respectively, then ne0 no0 .
(vii) If Gkp i is the mapping defined on {0,1,...., n 1} by Gkp i (b)
N ( p) p , for any fixed k and i, 0 i
2b kp i mod
p 1 , then Gkp i induces a permutation of the
elements of Bi if i 0 , and of the elements of B0 \{n 1} if i 0 . The integer i jp
0 j N ( p) 1 , lies in an orbit of length k j which is equal to the order of 2 mod
N ( p) / ( j k , N ( p)) , if j
Gkp i .
k mod N ( p) . The integer i kp
Bi ,
Bi is a fixed point of
Proof. Because of the assumption ord p (2) ( p 1) / 2 , we have from Lemma 4 (ii) that
p
1 mod 8, and hence we have to take (53) and (54) as definition for the sets Bi . Parts
(i) – (v) are proved in a similar way as the corresponding parts of Theorem 11. As for (vi),
we remark that for 0 j N ( p) , jp and ( N ( p) j ) p are both in B0 , and that the sum
of these two integers is equal to N ( p) p n 1. Since the binary representation of n 1 is
equal to the all-one word 11....1 of length ( p 1) / 2 and since this number is assumed to
be odd, the set B0 contains as many words of even parity as of odd parity. In order to
prove (vii), we first remark that Gkp i (i jp) i (2 j k ) p Bi for all i . Applying
Gkp
a
i
, a
0 , on the integer i
jp
Bi and putting the result equal to this integer, yields
the equation (2a 1)( j k ) 0 mod N ( p) , like in the proof of Theorem 13 (vii), and the
result follows similarly.
□
Example
First we take p 13. So, N (13) 5 , n 26 N (13).13 1 and ord 13 (2) 12 .
Starting with b 0 and applying F repeatedly provides us with the following orbit of
length 12:
41
F 0 (b)
0 0 0 p , F 1 (b) 1 1 0 p , F 2 (b) 3 3 0 p , F 3 (b)
4
5
8
9
6
F (b) 15 2 1 p , F (b) 31 5 2 p , F (b)
F (b)
60 8 4 p , F (b) 56
10
4 4 p , F (b)
7
7
63 11 4 p , F (b)
7 0p ,
62 10 4 p .
11
48 9 3 p , F (b) 32 6 2 p ,
12
F (b) 0 b .
In a similar way we obtain the other four orbits of elements not in B12 . Below we present
all five orbits in binary representation:
0 000000
8 001000
10 001010
2 000010
34 100010
1 000001
17
010001
21 010101
5 000101
4 000100
3 000011
35 100011
43 101011
11 001011
9 001001
7 000111
15 001111
6 000110
13 001101
22 010110
45 101101
23 010111
47 101111
19 010011
39 100111
31 011111
27
011011
26 011010
30 011110
14 001110
63 111111
55 110111
53 110101
61 111101
29 011101
62 111110
60 111100
46 101110
28 011100
42 101010
20 010100
58 111010
52 110100
59 111011
54 110110
56 111000
57 111001
41 101001
40 101000
44 101100
48 110000
32 100000
50 110010
36 100100
18 010010
37 100101
16 010000
33 100001
24 011000
49 110001
The first element in the various columns is chosen such that each binary integer differs in
precisely one bit from the integer left from it in the same row. By Theorem 13 (v), the
same holds in all rows. One could say that neighbouring columns are “parallel” at
distance 1.
The transformation F generates the following orbit on the family {Bi ∣ i 12} :
B0
B1
B3
B7
B2
B5
B11
B10
B8
B4
B9
B6
The words in B12 are
p 1 12
2 p 1 25
3 p 1 38
4 p 1 51
001100
011001
100110
110011
As one can verify, the transformation F permutes these words according to
001100
011001
110011
100110
42
001100
B0
Remark that the numerical values of b and F (b) , which lie in the set {0,1,....,63} , are
such that F (b) 2b 1 mod 65 (65 = pN ( p) , (cf. the proof of Theorem 13).
Equivalently, the above series of transformations can also be indicated by
1p 1
2p 1
3p 1,
4p 1
where the coefficient 3 is obtained by 2.4 = 3 mod 5 ( =N(13)). The size 4 of the only
orbit in B12 is in agreement with Theorem 13 (iv), since N (13) 5 and ( j,5) 1 ,
1 j 4.
In order to illustrate Theorem 13 (vii), we consider the action of the operators Fkp
k {0,1, 2,3, 4} , on the set B0
0
Fkp ,
{0,13, 26,39,52} .
F0 generates the orbit 13 26 52 39 13 and has fixed point 0;
Fp generates the orbit 0 13 39 26 0 and has fixed point 52;
F2 p generates the or bit 0
26
13
52
0 and has fixed point 39;
F3 p generates the orbit 0
39
52
13
0 and has fixed point 26;
F4 p generates the orbit 0
52
26
39
0 and has fixed point 13.
From the binary representations 0 000000 , 13 001101 , 26 011010 , 39 100111
and 52 110100 , it follows that the orbit of Fp has the property that each element has an
immediate successor with opposite parity. The other four orbits of length 4 do not share
that property. Similarly, there exists a unique operator Fkp i for the set Bi with the same
property, e.g.:
F1
2p
generates the orbit 1
F2
0p
generates the orbit 15
F3
4p
generates the orbit 3
55
29
42
3 and has fixed point 16;
generates the orbit 4
43
56
17
4 and has fixed point 30.
F4
3p
27
14
28
54
53
41
1 and has fixed point 40;
15 and has fixed point 2;
□
In the first part of the above example we observed that the five orbits of the operator F
acting on the elements not in B12 can be ordered such that any word in one orbit is at
distance 1 from the corresponding word in an other orbit. It turns out that this
phenomenon is part of a more general property of the operator F , which we shall prove
below.
THEOREM 15
Let p be a prime such that p
3 mod 8. Let Oi and O j be two orbits of the operator F
acting on the elements not in B p 1 . If the initial words in these orbits are chosen such
43
that their Hamming distance is equal to d, 1 d ( p 1) / 2 , then any two corresponding
words in Oi and O j are at Hamming distance d.
Proof If the left most bits of the two words at Hamming distance d are both equal to 0
or both equal to 1, the right most bits are both put equal to 1 or both to 0, respectively,
under the action of F , and so the distance does not change. If the left most bits are 0 and
1, the right most bits are put equal to 0 and 1 by F , and hence the Hamming distance is
again d after the action of F .
□
Example
Next we take p 19 , with N (19) 27 , n 29
N (19).19 1 and ord 19 (2) 18 .
F (= F1 , cf. Theorem 13) generates the following orbit on the family of sets {Bi ∣ i 18} :
B0
B1
B17
B16
B3
There are three orbits in B p
respectively:
B14
1
B7
B10
B15
B12
B2
B6
B5
B11
B13
B8
B4
B9
B0
B18 = {18, 37, …., 493} of length 6, 2 and 18,
3 p 1 56 000111000
6 p 1 113 001110001
12 p 1 237 011100011
{
24 p 1 455 111000111
21 p 1 398 110001110
15 p 1 284 100011100
{
p 1 18 000010010
2 p 1 37 000100101
4 p 1 75 001001011
8 p 1 151 010010111
{ 16 p 1 303 100101111
5 p 1 94 001011110
10 p 1 189 010111101
20 p 1 379 101111011
13 p 1 246 011110110
9 p 1 170 010101010
18 p 1 341 101010101
26 p 1
25 p 1
23 p 1
19 p 1
11 p 1
22 p 1
17 p 1
7p 1
14 p 1
493
474
436
360
208
417
322
132
265
111101101
111011010
110110100
101101000
011010000
110100001
101000010
010000100
100001001
Here again, we can see that the transformation F is also established by
44
j ' p 1 , with j ' 2 j mod N (19) (= 27).
jp 1
For j 1 we find an orbit of size k1 = 18 which is equal to the order of 2 with respect to
27/(27,1) = 27. We find k1 18 . Similarly, we find for j 3 an orbit of length 6 and for
j 9 an orbit of length 2.
Similarly, we investigate the orbits of the operator Fp which leaves the set B0 = {0, 19,
38,…., 494} invariant under its action Fp (b) 2b p mod N ( p) p . Again we find orbits
of length 18, 6 and 2, together with an orbit of length 1 (cf. Theorem 13 (vi)). The
respective orbits are:
0
19
57
133
285
190
38
76 171 361
228 475
399 304 114 247 0 ,
95
209
437
380
152
323
152 ,
456
418
342
38 ,
266
and the fixed point 494 = 26.19.
Finally, we shall illustrate Theorem 13 (vi), by considering the action of F1.19
1
F18 on
the set B1 {1, 20,58,...., 495} . According to that Theorem B1 is invariant under this
action. We find the following orbits:
1
20
58
134
286
191
39
96
77 172 362 229
476
400 305 115 248 1 ,
210
438
381
153
324
153 ,
267
457
419
343
39 ,
while 495 = 26.19 + 18 the (only) fixed point is in B1 .
Next we take an example such that ord p (2) ( p 1) / 2 and even.
Example
Let p 17 . We have N (17) 15 , n 28 N (17).17 1 and ord 17 (2) 8 . We shall
show that the operator F , which in this case ( p
1 mod8) is also defined by
F (b) 2b 1 mod N ( p) p , has similar properties as the operator in Theorem 13 where
we dealt with the case p
3 mod 8.
Starting with b 0 and applying F repeatedly, yields the orbit
0 1 3 7 15 31 63 127 0 .
45
□
Similarly, we get an orbit
8 17 35 71 143 32 65 131 8 .
Altogether we obtain 30 orbits of length 8 containing all elements which are not in
B16 255( 1), 16, 33, 50, 67, 84, 101, 118, 135, 152, 169, 186, 203, 220, 237, 254,
which is similar to Theorem 11 (ii).
The transformation F (b) 2b 1 mod 255 generates the following orbits on the family
{Bi ∣ i 16 }:
B0
B1
B3
B7
B15
B14
B12
B8
B0
B2
B5
B11
B6
B13
B10
B4
B9
B2
Since ord 17 (2) 8 , this result is similar to Theorem 13 (iii).
The transformation F generates five orbits in B16 :
16
33
67
50
101
203
84
118
169
237
220
254
254
135
152
16
50
84
186
118
Observe that always F (b) F ( jp 1) j ' p 1 , with j ' 2 j mod 15. As special cases
we draw the reader’s attention to F (15 p 1) 2.15 p 1 15 p 1 mod 15 , which gives
the size of 1 for the last orbit. The length 4 of the orbits corresponding to 16, 50 and 118
are determined by k1 k3 k5 = 4, being the order of 2 with respect to 15=
N (17) / ( j, N (17)) for j 1 , 3 and 5. Furthermore, k5
respect to N (17) / (5, N (17)) 15 / 5 3 .
Example
Now we take p
2 which is the order of 2 with
□
23 . Since ord 23 (2) 11 which is odd, the conditions of Theorem 14
are satisfied. Furthermore, we have pN ( p) 211 1 23.89 , and so N (23) 89 .
It appears that, apart from the fixed points 0 and 211 1 , the operator G generates 8
orbits of length 11 on B0 i.e. the orbits containing respectively
46
1.23 = 00000010111, 9.23 = 0001101111, 19.23 = 00110110101, 33.23 = 01011110111,
3.23 = 00000100101, 5.23 = 00001110011, 11.23 = 00011111101, 13.23 = 00100101011.
As one can verify, the words in the first four orbits all have even parity and the words in
the second four orbits all have odd parity. The eight non-trivial orbits all have the same
length in this case, because N (23) 89 is a prime and so ( j,89) 1 for all relevant j
(cf. Theorem 14).
Similarly, let G operate on elements which are not in B0 . If we take the integer 1 B1 ,
we obtain successively elements lying in the sets B1 , B2 , B4 , B8 .B16 , B9 , B18 , B13 , B3 , B6 , B12
and back to B1 . Starting with 5 B5 yields successively the sets
B5 , B10 , B20 , B17 , B11 , B22 , B21 , B19 , B15 , B7 , B14 and back to B5 . Continuing in this way, we
get 22 orbits of length 11 containing all elements not in B0 .
Next, we consider the operator G p 1 which is defined by the mapping
G p 1 (b)
2b
p 1 . Theorem 14 (vii) states that the set B1 is invariant under its action.
We find for the orbits in B1 , apart from the fixed point 1 88.23 , 8 orbits of length 11
(observe that ord N ( p ) (2) = ord p (2) in this case, since ( N ( p), p) (89, 23) 1 ). The
orbits are:
1, 1 + 1.23, 1 + 3.23, 1 + 7.23, 1 + 15.23, 1 + 31.23, 1 + 63.23, 1 + 38.23, 1 + 77.23,
1 + 66.23, 1 + 44.23,
with parities 1, 0, 1, 1, 0, 1, 0, 1, 1, 0 and 0, respectively. Similar orbits exist containing
1 + 9.23, 1 + 19.23, 1 + 33.23, 1+ 3.23, 1 + 5.23, 1 + 11.23 and 1 + 13.23.
□
REMARK
In the above example we have the peculiarity that both the non-trivial orbits in B0 as well
as the orbits of elements not in B0 , both have the same length 11. This can also occur in
other cases, i.e. if ord p (2) ( p 1) / 2 and odd (the conditions of Theorem 14), N ( p) is
a prime and p is not a Mersenne prime. We can see this in the following way. From the
conditions for ord p (2) , we know that p
(p
1 mod 8 and that 2
1)/2
1 N ( p) p . Let l
be the order of 2 with respect to N ( p) , then 2l 1 kN ( p) for some positive integer k .
It follows that l ∣ ( p 1) / 2 , and hence 2l 1 ∣ 2( p 1)/2 1 and k ∣ p . So, either k 1 or
k p . But k 1 implies that N ( p) is a Mersenne prime, which is forbidden. We
conclude that k p and l ( p 1) / 2 .
The next theorem partly generalizes Theorem 13 (i), (iv) and Theorem 14 (i), (iv), and
puts some of the results of those theorems in a slightly different notation.
47
It is obvious that the mappings Fkp
i
and Gkp i are actually the same function written in
different notation. More precisely, defining the function H i ,k :{0,1,...., n 1}
{0,1,...., n 1} , H i ,k (b)
G
2b i kp mod N ( p) p yields as special cases F
H1,0 and
H 0,0 .
Another special case is the mapping H 2e ,0 .
THEOREM 16
Let p be an odd prime. Let H 2e ,0 be the mapping defined by H 2e ,0 (b)
2b 2e mod
N ( p) p , for all b {0,1,...., n 1} .
e
(i) H 0,0 and F 2 , e 0 , is a one-to-one mapping on {0,1,...., n 1} .
e
(ii) H 0,0 and F 2 , e 0 , induces a permutation of the elements of B0 and B p
2e
,
respectively.
Proof. (i) This is shown in the same way as Theorem 13 (i).
(ii) Consider the action of H 2e ,0 , and take b : jp 2e Bp 2e . Then
H 2e ,0 (b) 2 jp 2e
1
2e
2 jp 2e mod N ( p) p . If 2 j
that the result is again in B p
2e
. If 2 j
N ( p) , we have by definition
N ( p) , we subtract N ( p) p and obtain
(2 j N ( p)) 2e which clearly is also in B p
2e
. For H 0,0 the proof is similar.
□
We remark that under the conditions of Theorems 13 and 14, we derived the equality
nie nio for i p 1 and i 0 , respectively, but that none of the Theorems 11-14 gives
an answer to the question of the relative sizes of nie and nio for other values of i , and
neither for cases when the conditions in Theorems 13 and 14 are not satisfied. By
applying the result of Gauss (Theorem 9), we can get a partial answer to that question as
the next theorem will show. We intoduce the symbol p , defined as p 0 if ∣p∣ is even,
and p 1 if p is odd.
THEOREM 17
Let p be an odd prime with ord p (2)
p 1 or with ord p (2)
furthermore M ' be the subsequence mi , mi p ,...., mi
i
e
i
o
( N ( p ) 1) p
( p 1) / 2 and odd. Let
of the Morse-Thue sequence
M, where 0 i p 1 . If n and n denote the number of elements in M ' of
respectively even and odd weight, then the following relations hold:
(i) | nei noi | = 1 for all i satisfying 0 i p 1 , i
;
48
( 1) p , with i 0 , if p
(ii) nei noi
3 mod 8, and i 1 , if p
1 mod 8.
Proof. It will be obvious that the elements in M ' are identical to the elements of the
block Bi . Therefore, we were entitled to use the same notation for the numbers of words
of a certain parity in M ' as well as for the words of Bi . Furthermore, we know that
p
3 mod 8 in the first case, whereas p
1 mod 8 in the second case.
(i) From Theorems 8 and 9 we know that the equality ∣ N ei N oi ∣ = 1 is true for blocks
A i 1 , 0 i p 1 , in the first case, and for blocks A i , 0 i p 1 in the second (cf.
also Theorem 12). When transforming the vectors of Ai into vectors of Bi by applying
Theorem 11, the parities of the binary words do not change, unless the weight of the
vector p is odd (rember that the matrix Q is a permutation matrix which permutes the
ones in a binary word).
(ii) We also know, from the proof of Theorem 8, that N e 1 N o 1 1 for any odd prime
□
p . The equality in (ii) now follows immediately.
Example
For p 7 and i 1 we have for the trivial subsequence (1 =) 001 that ne1
1
e
hence n
1.
p
1
o
n
1 . Since d
(1 2 3), I1 {1} , I 2
{2,3} , we have p
0
o
1 . Since d (1 2 4 3 5), I1 {1, 2} , I 2
hence n n
p (0,0,0,1,0) and so p 1 .
1 and
(0, 0,1) and so
For p 11 and i 0 we have for the subsequence 0, 11, 22 that ne0 1 , no0
0
e
0 , no1
2 and
{3, 4,5} , we have
For p 13 and i 0 we have the subsequence 0, 13, 26, 39, 52 in binary written as
1.
000000, 101100, 010110, 100111, 110100. So, ne0 2 , no0 3 and ne0 no0
Similarly as in the previous examples we find p (0,0,0,1,0,0) and so p 1 .
For p 23 we find d (1 2 4 8 7 9 5 10 3 6 11) , p (0,0,0,0,1,0,1,1,0,0,1) and so
0 . One can verify that in this case ne1 no1 1 .
p
REMARK
In cases that the condition for ord p (2) in Theorem 17 is not satisfied, the theorem is not
necessarily true. As a counterexample we present the case p 17 . For i 1 we have the
subsequence 1, 18, 35, 52, 69, 86, 103, 120, 137, 154, 171, 188, 205, 222, 239.
Written in binary this yields the Morse-Thue subsequence
00000001, 00010010, 00100011, 00110100, 01000101, 01010110, 01100111, 01111000,
10001001, 10011010, 10101011, 10111100, 11001101, 11011110, 11101111.
49
Hence, ne1
5 , no1
10 and so ne1 no1
5.
We conclude this section by formulating the following problems:
(i) Is there a simple criterion for p to decide whether p is equal to 1 or to 0?
(ii) Can Theorem 17 be generalized for other values of the prime p?
(iii) Is it possible to reverse the arguments and determine the Gauss sign by starting from
properties of the Morse-Thue sequence?
References
[1] E.R. Berlekamp, Algebraic Coding Theory, McGraw-Hill Book Company, New York,
1968.
[2] B. Bruce, C. Berndt and R.J. Evans, The Determination of Gauss Sums, Bull. Am.
Math. Soc. 5 (1981), 107-129.
[3] F.J. Mac Williams and N.J.A. Sloane, The Theory of Error Correcting Codes, NorthHolland Publishing Company, Amsterdam, 1977.
[4] V.V. Vavrek, Linear Codes and Conference Matrices (diss.), Delft University Press,
Delft, 2005.
[5] A.J. van Zanten and V.V. Vavrek, Partitions and Constant-value Codes , Proceedings
of the Eleventh International Workshop ACCT, pp. 312 – 317, Pamporovo, Russia, June
16 – 22, 2008.
50
Download