Upload
others
View
4
Download
0
Embed Size (px)
Citation preview
Simulation of PN Code Sequencesfor Cellular Systems
Santit Traithavil
Department of Engineering,The Australian National University.
February 17, 2006
2
Abstract
PN sequences are an important part of Code Division Multiple Access(CDMA) based wireless cellular systems. This report investigates the gen-eration of m-sequences, Gold sequences, Gold-like sequences and Kasami se-quences, which are special families of PN sequences. The autocorrelation andcross-correlation of these sequences are compared and analysed. The PN se-quences specified in IS-95 CDMA and WCDMA standards are generated andstored for use in system level simulations.
CONTENTS 3
Contents
1 Introduction 5
2 m-Sequence 5
2.1 Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2.2 Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2.2.1 Balance Property . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.2.2 Run Length Property . . . . . . . . . . . . . . . . . . . . . . . 8
2.2.3 Autocorrelation . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.2.4 Cross-Correlation . . . . . . . . . . . . . . . . . . . . . . . . . 9
3 Gold Sequence 10
3.1 Preferred m-sequences . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.2 Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.3 Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
4 Gold-Like Sequence 12
4.1 Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
4.2 Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
5 Kasami Sequence 12
5.1 Small Set of Kasami Sequences . . . . . . . . . . . . . . . . . . . . . 13
5.1.1 Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
5.1.2 Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
5.2 Large Set of Kasami Sequences . . . . . . . . . . . . . . . . . . . . . 13
6 Implementation 14
6.1 Example 1: m-Sequence . . . . . . . . . . . . . . . . . . . . . . . . . 14
6.2 Example 2: Gold sequence . . . . . . . . . . . . . . . . . . . . . . . . 16
6.3 Example 3: Gold-like sequence and Small Set of Kasami sequence . . 18
6.4 GUI Demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
4 CONTENTS
7 Conclusions 21
A Summary of MATLAB Functions 23
B GUI Snapshot 27
5
1 Introduction
PN Sequences or Pseudo Noise Sequences are an integral part of existing mobile
cellular systems. A PN sequence consist of ones and zeros which are determined by
precise mathematical rules.
There are three well-known PN Sequence families:
1. m-Sequence.
2. Gold Sequence.
3. Kasami Sequence.
Second Generation (2G) and Third Generation (3G) phones uses Code Division
Multiple Access (CDMA) system whereby each user is assigned a unique PN Sequence
which helps to distinguish between users. The current IS-95 CDMA system uses m-
sequences while WCDMA (3G) uses Gold sequences. Kasami sequences have been
proposed for 4G systems which are expected to be deployed in 2010s.
The aim of this project is to study and generate the PN sequences used in the
cellular systems for use in system level simulations. This report details the theory
behind the generation and properties of PN sequences. The details of a graphical
user interface developed for this project to illustrate PN sequence properties is also
discussed.
This report is organised as follows. In Section 2, the generation and properties
of m-sequences are discussed. The m-sequence generator structure used in this work
is also explained. In Sections 3 and 4, the properties of Gold sequences and Gold-
like sequences are explained. Kasami sequences are discussed in Section 5. Details of
MATLAB implementation are provided in Section 6. Finally, the appendices conclude
this report.
2 m-Sequence
m-Sequence or Maximal Length Sequence is the simplest PN sequence to generate. m-
Sequences are generated by Linear Feedback Shift registers. An m stage shift register,
6 2 M -SEQUENCE
which describe by a polynomial of order m, can generated a periodic m-sequence of
period 2m−1.
2.1 Generation
PN Sequence are usually generated by Linear Feedback Shift Register (LFSR). LF-
SRs are described by primitive polynomials or generator polynomials. These poly-
nomials are conveniently and conventionally represented by a binary vector c =
[cm, cm−1, ..., c1, c0], or the octal notation of the vector. e.g. f(x) = x5 + x2 + 1
is a binary vector 100101 or octal 45. Another convention is to represent it as (5,2,0),
which is sometimes further abbreviated as (5,2).
There are two ways of implementing these polynomials:-
• Galois configuration.
• Fibonacci configuration.
For Galois feedback generators, Figure 1, the feedback adders are placed between
the stages. So, there exists small delays inherent in the feedback path. For Fibonacci
feedback generators, Figure 2, the output from last register and intermediary stages
are combine in modulo-2 adders and is fed back to the input of the first register. This
inherits a feedback loop delay which consist of the sum of all propagation delays in
the path from last stage to the first stage. Therefore, Galois feedback generators are
usually faster than Fibonacci feedback generators.
While Galois configuration are readily divisible into units consisting of a flip-flop
and a modulo-2 adder, which makes them desirable for high speed hardware imple-
mentation, Fibonacci configuration is, however, easier for software implementation
and is used throughout this work.
2.2 Properties
As mentioned earlier m-sequences are of period 2m = 1 where m is the order of
the generator polynomial. m-Sequences satisfy Balance Property and Run Length
Property, which give them an appearance of randomness.
2.2 Properties 7
c0 = 1c
1c
2c
m-1c
m= 1
1 2 m
Figure 1: m-Sequence generator structure using Galois configuration.
c0
= 1 c1
cm-1
cm = 1
1
c2
2 m-1 m
Figure 2: m-Sequence generator structure using Fibonacci configuration.
8 2 M -SEQUENCE
2.2.1 Balance Property
PN Sequences contains a balance amount of ones and zeros. If m is the number of
shift registers, L is the length of periodic sequence which is given by L = 2m − 1.
So number of ones in the sequence is 2m−1 and number of zeros in the sequence is
2m−1 − 1.
2.2.2 Run Length Property
A ‘run’ is a sequence consecutive identical symbols (1s or 0s). The length of this
sequence is the length of the run. In an m-sequence generated by a linear feedback
shift registers of length m, there are (L+1)/2 runs, where L = 2m−1. The composition
of the runs is as follows:
1. 1 run of ones of length m. 2. 1 run of zeros of length m − 1. 3. 2 runs (1 run of
ones and 1 run of zeros) of length m− 2.
4. 4 runs (2 runs of ones and 2 runs of zeros) of length m− 3.
5. 8 runs (4 runs of ones and 4 runs of zeros) of length m− 4....
m. 2m−2 runs (2m−3 runs of ones and 2m−3 runs of zeros) of length 1.
2.2.3 Autocorrelation
Autocorrelation is a measure of the similarity between a sequence and its time-shifted
sequences. It can be used to predict the start of a PN sequence by detecting the peak.
For CDMA based systems, autocorrelation is used in selecting sequences which gives
the least probability of false synchronisation.
For real valued sequence autocorrelation is defined by:
Ra[n] =∞∑
k=−∞x[k]x[n− k] (1)
For an ideal PN sequence, its autocorrelation is two-valued and is given by the
function Ra(0) = L and Ra(k) = 0 for 1 ≤ k ≤ L− 1.
Autocorrelation function of an m-sequence is periodic and two-valued. If we trans-
form the binary sequence into bipolar sequence by replacing each 0 by +1 and each 1
2.2 Properties 9
by −1, then its autocorrelation is given by:
Ra(k) =
{L, k = lL,
−1, k 6= lL.(2)
The peak value occurs every time lL where l is an integer. m-Sequences have the
best autocorrelation function of the three kinds. The maximum value of its non-peak
value (maxk[Ra(k)]k 6=lL) is smaller than sequences of other kinds.
2.2.4 Cross-Correlation
Cross-correlation describes the relationship between two sequences. The higher the
cross-correlation is, the more similar the sequences are. The cross-correlation function
of any two sequences is given by:
Rc[n] =∞∑
k=−∞x[k]y[n− k] (3)
The lower bound of the cross-correlation between any pair of binary sequences of
period L in a set of M sequences is described by Welch as [1]:
Rc(k)max ≥ L
√M − 1
ML− 1∼=√
L (4)
Usually the rejection of the signals of interfering users is measured by the ratio of
the maximum cross-correlation coefficient and the autocorrelation coefficient. Then
ratio is given by:
µ =Rc(k)max
Ra(0)(5)
A large set of m-sequences have large cross-correlation. This implies that they are
harder to be distinguish and may cause false synchonisation in CDMA based systems.
Although, it is possible to find sets of m-sequences with low cross-correlation, but
the number of sequences in the sets are too small for CDMA applications which
require much larger set of sequences. m-Sequences are useful in those applications
which require only a few sequences with excellent cross-correlation and autocorrelation
properties [2].
10 3 GOLD SEQUENCE
3 Gold Sequence
For CDMA system, each user is assigned a PN sequence to allow multiple access in a
band of frequencies. It is known that cross-correlation function between m-sequences
can have a relatively large peak, so m-sequences are not suitable in CDMA system due
to mutual interference. Although it is possible to select a small subset of m-sequences
that have smaller cross-correlation peak values, the number of sequences is usually
too small of CDMA applications. Gold sequences are preferred because the large
number of sequences they supply and the cross-correlation between the sequences are
uniformly bounded [1]. A Gold sequence can be generated by logical addition (XOR)
of two preferred m-sequences, so they have same period of 2m− 1 as for m-sequences.
3.1 Preferred m-sequences
Two m-sequences of length L with a periodic cross-correlation that takes on the
possible values {−1,−t(m), t(m)− 2} are called preferred pair m-sequences, where
t(m) =
{2(m+1)/2 + 1 , odd m
2(m+2)/2 + 1 , even m(6)
where m is the order of the sequence generator polynomial.
The preferred pair is generated by two different shift registers. The polynomials
which describe these registers are called preferred polynomial. These polynomials both
must have the same degree m.
A pair of preferred polynomial is also known as a pair of primitive polynomial.
3.2 Generation
As mentioned earlier, a Gold sequence can be generated by a logical addition of
preferred pair m-sequences. The resulting Gold sequences will have the same period
L as the two m-sequences. A set of Gold sequences can be generated by logical
addition of a preferred m-sequence and cyclically shifted versions of its pair sequence.
Thus, a pair of preferred m-sequences of period L = 2m−1, where m is the order of
3.3 Properties 11
2 3 4 51
2 3 4 51
f1(x) = x5+x2+1
f2(x) = x5+x4+x3+x2+1
Output
Sequence
Figure 3: Example of generating a set of Gold sequences
generator polynomial, can generate a total of L+2 gold sequences (including the two
generator sequences).
For example, preferred pair m-sequences generated by preferred pair polynomials
(5, 2) and (5, 4, 3, 2) of the same order n = 5 have period L = 25 − 1 = 31 generate a
set of L + 2 = 33 Gold sequences with the same period.
3.3 Properties
Although gold sequences are generated form pairs of preferred m-sequences, except
the generator sequences, gold sequences are not m-sequences. So, they do not have
the properties of m-sequences and their autocorrelation are not two valued.
Cross-correlation of gold sequences contain three possible values {−1,−t(m), t(m)−2}, where t(m) is given by Equation 6.
12 5 KASAMI SEQUENCE
4 Gold-Like Sequence
Gold-Like sequence have parameters very similar to those of Gold sequences. Number
of sequences in a gold-like sequence set is N = L + 1 = 2m where L is the length of
one sequence (number of bits).
4.1 Generation
Let u be an m-sequence of period L = 2m− 1, generated with a polynomial generator
of order m. q is an integer such that gcd(q, 2m − 1) = 3. Obtain v(k), k = 0, 1, 2, by
decimating Dku by q and repeating it 3 times, where D is a delay operator. From a
property of m-sequences, the fundamental period of v(k) will be L′ = L/3. A set of
Gold-like sequences contains the sequence u and the sequences obtained from logical
additions u with the time-shifted by 0 to L′ − 1 versions of v(k). Hence, there are
(3× L′) + 1 = L + 1 sequences in a set.
4.2 Properties
The order of generator polynomial, m, must be even and a multiple of 4 to generate
a set of Gold-like sequences. The maximum cross-correlation for Gold-like sequence
set is θmax = t(m). The cross-correlation function for a Gold-like sequence is 5 valued
and takes on value in the set {−1,−t(m), t(m) − 2,−s(m), s(m) − 2} where t(m) is
given by Equation 6 and s(m) is given by:
s(m) = 2m/2 + 1 (7)
5 Kasami Sequence
Kasami Sequence have correlation function which is closest to the Welsh’s lower bound
in Equation 4. A set of Kasami Sequences is generated in a similar way to a set of
Gold-like sequences. There are two classes of Kasami sequences: the small set and
the large set. The small set is more optimal than the large set in the sense of matching
Welch’s lower bound for correlation function. The small set is a subset of the large
set.
5.1 Small Set of Kasami Sequences 13
5.1 Small Set of Kasami Sequences
A small set of Kasami sequences is an optimal collection of binary sequences with
respect to the cross-correlation bound [3]. There are N = 2m/2 binary sequences of
period 2m − 1 within a set, where m is an even order of the polynomial generator.
5.1.1 Generation
Let u be an m-sequence of period L = 2m − 1 generated with a polynomial generator
of order m even. Find w by decimating u by q = 2m/2 + 1 and repeating it q times,
such that w is of the same length as u. From a property of PN sequence, w is of period
2m/2 − 1. A small set of Kasami sequences contains u and the sequences obtained
from logical addition of u and the shifts by 0 to 2m/2 − 2 of w. Number of sequences
in a small set is 2m/2.
5.1.2 Properties
Correlation function for a small Kasami sequences takes on values within the set
{−1,−s(m), s(m) − 2} where s(m) is given by Equation 7. Consequently, the max-
imum value for correlation functions is θmax = s(m) = 1 + 2m/2. Comparing this to
the Welch’s bound for binary sequences, θmax > −1 + 2m/2, the small set of Kasami
sequences is an optimal collection of binary sequences in term of correlation functions’
lower bound.
5.2 Large Set of Kasami Sequences
Large set of Kasami sequences contains both small set of Kasami sequences and Gold
(or Gold-like) sequences as subsets. The sequences are of period 2n−1. The number of
sequences within a set is N = 23m/2 for m = 0 mod 4, and N = 23m/2 +2n/2 for m = 2
mod 4. The autocorrelation and cross-correlation functions takes on values within
the set {−1,−s(m), s(m) − 2,−t(m), t(m) − 2}. The peak value of cross-correlation
function, |Rc|max = t(m), is larger than a small set of Kasami sequences and, in fact,
is the same as for a set of Gold sequences. However, the packing of signal space
is more efficient. CDMA based systems require large number of sequences in a set,
14 6 IMPLEMENTATION
as well as good autocorrelation and cross-correlation properties. Large set Kasami
sequences are the best in respect of the requirements, and are being considered for
future CDMA based systems.
6 Implementation
The following examples use implemented MATLAB functions to illustrate the prop-
erties of PN sequences. The key properties are summarised in Table 1 and the list
of MATLAB functions is given in Appendix A. The correctness of implemented m-
sequence, Gold sequence, Gold-like sequence and small set Kasami sequence gener-
ators were checked by comparing sequences generated by the generators with the
sequences generated by Zhao [4].
6.1 Example 1: m-Sequence
Consider a polynomial generator x3 + x2 + 1, and generate an m-sequence using
function m_seq_gen.
>> seq1=m_seq_gen([3 2])
seq1 =
1 1 1 0 0 1 0
The result sequence is seq1 = 1110010. Plot the autocorrelation of the sequence
using function Plot_Autocorr.
>> Plot_Autocorr(seq1);
From the properties of m-sequences, the peak value of autocorrelation function is
equal to L. The autocorrelation function of seq1, Figure 4, has the peak value equals
to 7.
Generate another m-sequence of generator polynomial x3 + x + 1.
>> seq2=m_seq_gen([3 1])
seq2 =
1 1 1 0 1 0 0
6.1 Example 1: m-Sequence 15
−6 −4 −2 0 2 4 6
−1
0
1
2
3
4
5
6
7
Time
Au
toco
rre
latio
n
Maximum =7
Minimum =−1
Figure 4: Autocorrelation of the sequence 1110010.
−6 −4 −2 0 2 4 6
−5
−4
−3
−2
−1
0
1
2
3
Time
Cro
ss−
co
rre
latio
n
Maximum =3Minimum =−5
Figure 5: Cross-correlation of the sequence 1110010 and the sequence 1110100.
16 6 IMPLEMENTATION
The result sequence is seq2 = 1110100. Plot the cross-correlation function of seq1
and seq2 using Plot_Cross_corr.
>> Plot_Cross_corr(seq1,seq2);
The peak value for the cross-correlation function equals to 5, Figure 5, and is
relatively large compare to the peak value for the autocorrelation function, which
equals to L = 7. This makes m-sequences easy to be interfered and not practical for
CDMA applications.
6.2 Example 2: Gold sequence
A set of Gold sequences is generated with a pair of preferred polynomial. Consider a
pair of x5 + x2 + 1 and x5 + x4 + x3 + x2 + 1. A set of gold sequence using function
gold_seq_gen.
>> gold_set=gold_seq_gen([5 2], [5 4 3 2]);
There are L + 2 = 33 sequences in the generated set. The first two sequences in
the set are m-sequences, but the others are not and they do not have the properties
for m-sequences. Plot the autocorrelation for the third sequence in the set.
>> Plot_Autocorr(gold_set(3,:));
The autocorrelation function as seen in Figure 6 is not a kind for m-sequence. It
is not two valued. However, the function’s peak value is the same as for m-sequences
which equals to L. In this case, L = 31.
Plot the cross-correlation between the 3rd sequence and the 5th sequence.
Plot_Cross_corr(gold_set(3,:),gold_set(5,:));
The cross-correlation function is 3 valued and consists of values within the set
{−1,−9, 7}. Note: t(5) = 2(5+1)/2 + 1 = 9
6.2 Example 2: Gold sequence 17
−30 −20 −10 0 10 20 30
−10
−5
0
5
10
15
20
25
30
Time
Au
toco
rre
latio
n
Maximum =31Minimum =−9
Figure 6: Autocorrelation of the third sequence in the Gold sequence set,0000000010010100100111101010110.
−30 −20 −10 0 10 20 30
−8
−6
−4
−2
0
2
4
6
Time
Cro
ss−
co
rre
latio
n
Maximum =7
Minimum =−9
Figure 7: Cross-correlation between the 3th sequence and the 5th sequence.
18 6 IMPLEMENTATION
6.3 Example 3: Gold-like sequence and Small Set of Kasamisequence
Generate a set of Gold-like sequences of generator polynomial x4+x+1 using function
gold_like_gen.
>> gold_like=gold_like_gen([4 1]);
There are L + 1 = 32 sequences in the set, and the first sequence is the only
m-sequence. Plot the autocorrelation of the 2nd sequence.
>> Plot_Autocorr(gold_like(2,:));
The autocorrelation functions, Figure 8 has the peak value equals to L = 15.
Plot the cross-correlation between 2nd sequence and 3rd sequence.
>> Plot_Cross_corr(gold_like(2,:),gold_like(3,:))
The cross-correlation function, Figure 9, consists of value within the set {−9,−5,−1, 3, 7}.Note: t(4) = 2(4+2)/2 + 1 = 9 and s(4) = 24/2 + 1 = 5.
Generate a small set of Kasami sequence with generator polynomial l x4 +x+1 using
function small_kasami_gen.
small_kasami=small_kasami_gen([4 1]);
Plot the autocorrelation of the 2nd sequence.
Plot_Autocorr(small_kasami(2,:));
Similar to Gold and Gold-like sequences, the autocorrelation function, Figure 10,
is not 2 valued as for m-sequences, but the peak value is L = 15.
Plot the cross-correlation of the 2nd and 3rd value.
Plot_Cross_corr(small_kasami(2,:),small_kasami(3,:));
The cross-correlation function of small set of Kasami sequences is optimal out
of the three kinds (m-Sequence, Gold-sequence and Kasami sequence). In this case,
the function has the peak value equals to 5, and consists of values within the set
{−5,−1, 3}. Note: s(4) = 24/2 + 1 = 5.
6.3 Example 3: Gold-like sequence and Small Set of Kasami sequence 19
−15 −10 −5 0 5 10 15
−5
0
5
10
15
Time
Au
toco
rre
latio
n
Maximum =15Minimum =−5
Figure 8: Autocorrelation of 2nd sequence, 001100111010000, in the Gold-like se-quence set.
−10 −5 0 5 10
−4
−2
0
2
4
6
Time
Cro
ss−
co
rre
latio
n
Maximum =7
Minimum =−5
Figure 9: Cross-correlation between the 2nd and 3rd sequence in the Gold-like se-quence set.
20 6 IMPLEMENTATION
−15 −10 −5 0 5 10 15
−5
0
5
10
15
Time
Au
toco
rre
latio
n
Maximum =15Minimum =−5
Figure 10: Autocorrelation of the 2nd sequence in the small set of Kasami sequences.
−10 −5 0 5 10
−5
−4
−3
−2
−1
0
1
2
3
Time
Cro
ss−
co
rre
latio
n
Maximum =3Minimum =−5
Figure 11: Cross-correlation between the 2nd and the 3rd sequence in the small setof Kasami sequences.
6.4 GUI Demo 21
6.4 GUI Demo
A MATLAB Graphical User Interface (GUI) Demo is created to demonstrate the
properties of the three different kinds of PN sequences: m-Sequence, Gold sequences
and Small Set Kasami Sequence. The graphical user interface is written in MATLAB
programming language [5]. There are options to plot analyse the run lengths, autocor-
relation and cross-correlation of the PN sequences. m-sequences used in the demo are
generated by the generator polynomial described by the octal number. Gold sequence
set is generated by the polynomial preferred pair, x5 +x2 +1 and x5 +x4 +x3 +x2 +1.
Small Kasami set is generated by the generator polynomial x4 + x + 1. Screenshots
of the graphical user interface are provided in Appendix B.
7 Conclusions
In this project, m-sequences, Gold sequences, Gold-like sequences and Kasami se-
quences were implemented. These sequences can be used in the simulation of present
and future wireless cellular systems. In addition, a MATLAB graphical user interface
demo was created to demonstrate the properties of various PN sequences.
References
[1] E. H. Dinan and B. Jabbari, “Spreading codes for direct sequence cdma and
wideband cdma cellular networks,” IEEE Communications Magazine, pp. 48–54,
Sept. 1998.
[2] D. V. Sarwate and M. B. Pursley, “Crosscorrelation properties of pseudorandom
and related sequences,” Proceedings of the IEEE, pp. 593–619, May 1980.
[3] B. J. Choi, “Spreading sequences,” May 2000, http://www-mobile.ecs.soton.ac.
uk/bjc97r/pnseq-1.1/.
[4] Q. Zhao, “Common spreading sequences used in multi-user ds-cdma systems,”
http://code.ucsd.edu/∼qizhao/seqs.html.
22 REFERENCES
[5] Matlab Help Notes, Version 7.0.1 release 14 service pack 1 ed., The MathWorks,
Sept. 2004.
23
A Summary of MATLAB Functions
Folder Function Name Description
Utility Functions Autocorrelation Find the autocorrelation of theinput sequence.
bar_pn Custom of MATLAB functionbar to plot a PN sequence.
bi2pol Transform a binary form PN se-quence into a polar form PNsequence.
Cross_correlation Find the cross-correlation of theinput sequences.
Find_RunLengths Find the run lengths of 1’s and 0’sof the input sequence.
Plot_Autocorr Plot the autocorrelation of the in-put sequence. This function usesthe function Autocorrelation.
Plot_Cross_corr Plot the cross-correlation ofthe input sequence. Thisfunction uses the functionCross_correaltion.
pol2bi Transform a polar form PN se-quence into a binary form PNsequence.
preferred_pair Check whether the two input se-quences are a preferred pair.
test_utility_func Demonstrate the usage of thefunctions in the Utility Functionsfolder.
PN Sequence Generator m_seq_gen Generate an m-sequence with in-put generator polynomial. (Ini-tial stage is all ones)
Plot_pnseq_CDMA Illustrate the usage ofPNseq_WCDMA_1, PNseq_WCDMA_2,PNseq_IS95_I, PNseq_IS95_Q
and PNseq_IS95_L.
24 A SUMMARY OF MATLAB FUNCTIONS
Folder Function Name Description
PNseq_13 Generate an m-sequence withgenerator polynomial of octal 13(x3 + x + 1).
PNseq_15 Generate an m-sequence withgenerator polynomial of octal 15(x3 + x2 + 1).
PNseq_67 Generate an m-sequence withgenerator polynomial of octal 67(x5 + x2 + 1).
PNseq_IS95_I Generate an m-sequence gI(x)used in IS-95 CDMA system.
PNseq_IS95_L Generate an m-sequence gL(x)used in IS-95 CDMA system.
PNseq_IS95_Q Generate an m-sequence gQ(x)used in IS-95 CDMA system.
PNseq_WCDMA_1 Generate an m-sequence g1(x)used in WCDMA system.
PNseq_WCDMA_2 Generate an m-sequence g2(x)used in WCDMA system.
Gold Sequence gold_seq_gen Generate a set of Gold sequencesfrom the input pair of preferredpolynomials.
test_gold_gen Demonstrate the usage of thefunction gold_seq_gen.
Gold like Sequence gold_like_gen Generate a set of Gold-likesequences from the inputpolynomial.
test_gold_like_gen Demonstrate the usage of thefunction gold_like_gen.
Kasami Sequence small_kasami_gen Generate a small set of Kasamisequence form the inputpolynomial.
25
Folder Function Name Description
test_kasami_gen Demonstrate the usage of thefunction small_kasami_gen.
Guide m_seq_pot An GUI to demonstrate someproperties of m-sequences.
PN Sequence Demo PN_Seq_Demo A GUI demo to demonstrate thedifferences in properties of m-sequences, Gold sequences andSmall Kasami Sequences. Thisfolder also contains other filesneeded for the demo.
26 A SUMMARY OF MATLAB FUNCTIONS
Seq
uen
ce/Fam
ilyN
o.of
LFSR
Decim
ationPerio
dFam
ilySize
Cross-correlation
Maxim
umm
qL
NR
cC
ross-correlation|R
max |
m-S
equen
cem
-2
m−
1-
--
Preferred
m-
2m−
1-
{−1,−
t(m),t(m
)−2}
t(m)
m-S
equen
ceG
oldSeq
uen
cem
odd
-2
m−
1L
+2
{−1,−
t(m),t(m
)−2}
t(m)
(optim
alset)
Gold
-likeSeq
uen
cem
even&
-2
m−
1L
+2
{−1,−
t(m),t(m
)−2,
t(m)
multip
leof
4−
s(m),s(m
)−2}
Kasam
iSeq
uen
cem
even2
m/2−
12
m−
12
m/2
{−1,−
s(m),s(m
)−2}
s(m)
(Sm
allSet)
Kasam
iSeq
uen
cem
even2
n/2+
1an
d2
m−
123m
/2
ifm
=0(m
od4){−
1,−t(m
),t(m)−
2,t(m
)(L
argeSet)
2(n
+2)/
2+
123m
/2+
2m
/2
ifm
=2(m
od4)−
s(m),s(m
)−2}
Note:t(m
)=
{2
(m+
1)/
2+
1,o
dd
m
2(m
+2)/
2+
1,even
m(8)
s(m)
=2
m/2+
1(9)
Tab
le1:
Key
prop
ertiesof
diff
erent
sequen
ces.
27
B GUI Snapshot
28 B GUI SNAPSHOT
Figure 12: PN Sequences Demo: m-sequence.
29
Figure 13: PN Sequences Demo: Gold sequence.
30 B GUI SNAPSHOT
Figure 14: PN Sequences Demo: Kasami sequence.