You are on page 1of 7

Matlab Simulink

The OFDM system will be applied according to the LTE parameters of the 5 MHz
bandwidth that have been studied on Matlab Simulink, generate random bits will be
generated first so a RANDOM INTEGER GENERATOR block is to be used, the M-
ary number will be according to the desired Modulation technique, in this example is 16
QAM, the sample time will be 1 divided by the number of data subcarriers in this case it
will be 1/301 and the number of samples per frame is the number of data subcarriers

After generating random bits now these signals will be modulated with 16 QAM
Modulation techniques so a RECTANGULAR 16 QAM MODULATOR block is to be
called from the library, the M-ary number is 16 and the constellation ordering is Gray.

Page 13 of 33
The next step is to take these values to the IFFT step but the number of samples is 301
and the IFFT only accepts radix 2 numbers ( 2 ^N numbers ) so zero padding (add zeros
the stream you have ) will take place to the 301 to make it reach the nearest radix 2
number which is 512 , the zeros added will be in between the 301 data subcarriers so the
data will be divided into 2 parts and fill the zeros in between so that will be done with a
SELECT ROWS block and the indices to output will be {1:150,151:301} , now 211
zeros will be added between 150 and 151 so the total will be 512, this process needs a
CONSTANT block and the constant value will be equal to
complex(0,0)*zeros(211,1) , these 2 outputs of the SELECT ROWS and the
CONSTANT block all 3 need to be connected so a MATRIX CONCATENATE block
is to be used in this case, the number of inputs in this block will be 3 inputs 1 input
represents the data from 1 to 150 and the second input is the zero padding ( 211 zeros )
and the third input is the data from 151 to 301 , so the data now became radix 2
(512) and an IFFT block to used in the next step.

Page 14 of 33
Now that o/p will be taken connected to a IFFT (frequency to time domain) block and it
must be taken in consideration that the boxes of the ‘Divide output by FFT length’ and
‘inherit FFT length from input dimensions’ are both marked .

The next block used is the SELECTOR block which will act like a cyclic prefix,
according to the LTE parameters the number of samples of the cyclic prefix in the short 5
MHz is 36 samples, this means that the last 36 samples will be taken from the 512 data
samples and then put it in the beginning of the data samples so that the total number of
the data samples becomes 512 + 36, so in the SELECTOR block the index vector will be
[477:512 1:512].

Now that successfully generating the OFDM signal, the signal will pass through a noisy
channel, in this example an Additive white Gaussian noise channel will be used, so an
AWGN CHANNEL block is to be added to the design and the adjustments of the block
is : the mode on the signal to noise ratio (SNR) and the SNR (dB) is 20 and the input
signal power is 0.01 watts

To see the output after the noisy channel the output will be taken to a |FFT| block so that
the signal is completely in the positive part and then into VECTORSCOPE block to see
the output

Page 15 of 33
.

Now after the signal has been transmitted, the next step is to receive the signal so the
cyclic prefix should be removed from the signal, a SELECTOR block to be used again
and this time the main 512 points will be selected before adding the cyclic prefix, the first
36 points are the ones which has been added so in the SELECTOR block the index
vector will be [37:548].

Page 16 of 33
The next step is to pass on a FFT block

After passing on a FFT block, a FRAME STATUS CONVERSION block is to be used


to convert the data into frames.

Retrieval of the 301 data symbols that we have transmitted is the main step in the
receiver, so the 211 zeros that have been added in the zero padding step is to be
completely removed, so a SELECTOR block to be used to remove these zeros and the
index vector for this block will be from [1:150 362:512], the first 150 data symbols to be
selected and then skip the 211 zeros that has been added and then the last 151 data
symbols which are from 362 to 512 is to be taken also.

The output after the removal of the zero padding on the scope will be

Page 17 of 33
Now demodulating the signal with a RECTANGULAR 16 QAM DEMODULATOR
will take place and hence the OFDM system design is finished.

Calculating the bit error rate is the next step, it will be calculated between the transmitted
bits and relatively with the received bits so a DATA_TX block is to be placed after the
random integer generator and a DATA_RX block is to be placed after the Demodulator
and both of them will be inputs to an ERROR RATE CALCULATION block and the
output will be on a DISPLAY block which will show the packet loss, bit loss and the
total bits.

Page 18 of 33
Page 19 of 33

You might also like