Wednesday, 29 May 2013

2 Bit generation and mapping with SIMULATION MODEL

In this project we developed a general procedure for each modulation. The following block diagram shows the simulation model.












Fig 2.1: Simulation model

The brief description of each simulation block is follows.

2.1 Bit Generation
The Bit Generation block main function is to generate the bit with equal probability.

2.2 Mapping
The main function mapping is to covertthe bitstream into symbols according to each modulation scheme.
For BPSK each zero is mapped to +1 and ones are mapped to -1. In QPSK, the mapper block converts each two bits block into an in phase component and a quadrature component.

Table 2.1:
For QAM we took the blocks of three bits and mapped the bits according to the given gray coding.  

2.3 Pulse Shaping Filter



The given Raised cosine filter is
It is implement as SQRC for evaluating the performance of the three modulation schemes.
2.4 Noise
The noise variance is calculated according to Eb/No and in this project we added  AWGN noise and it is calculated by multiplying the noise variance with the matrix containing the random number with zero mean and that variance is equal to one. The noise is then added to the transmitted signal to get noisy signal.
2.5 Matched Filter
Now the transmitted signal is noisy signal and it is passed through the matched filter where it samples every T Seconds (For rectangular pulse shaping the sampling time T=1, for  SQRC the sampling time T=4)
2.6 Decision
This block recovers the bits from the received samples. This block compares the received point with the thresholds to find the region in which the point lies and then decided the signal. After making the decision it then converts the received signal to the respective bits.
2.7 Comparison
The transmitted bits are compared to the received bits to find the erroneous bits and finally the bit error rate is calculated using the below formula

2.9 Encoder and Decoder

The encoder encodes the each 4-bit block into a 7-bit code word. This code word is fed into the system, at this time the output of the decision block will be the received code word rather than received bits. These code words may contain erroneous bits. The decoder will perform error check by taking 7bit blocks from the received bit stream of code words .It calculates the syndrome of each received code word. This syndrome is used to find the error pattern using syndrome LUT. Finally the corrected code word is generated and the data bits are recovered from each corrected code word.

3 Simulation Results
In this section we will discuss the simulation results of BPSK, QPSK, QAM and the obtained results are compared with theoretical values.

3.1 BPSK and QPSK with Rectangular Pulse Shaping Filter
The performance of BPSK and QPSK system in terms of BER vsEb/No is evaluated in Matlab. Both the QPSK and BPSK has same performance curves. The following figure show the BER curve for the simulated and theoretical system. It can be seen the two curves overlap each other. 
Fig3.1: Simulation results of BPSK & QPSK with Rectangular Pulse Shaping

There is no difference between the simulation and the theoretical curves of Eb/N0  vs  BER for three modulation schemes .In this context 8QAM  provides better performance than BPSK & QPSK .

3.2 8 QAM with Rectangular pulse shaping filter

The communication system with 8 QAM modulation is simulated using the same simulation model as discussed in section 2. Only the function of mapper is changed. The following figure shows the simulated and theoretical curves of 8 QAM system, 8 QAM with pulse rectangular pulse shaping filter

Fig 3.2: 8 QAM with Rectangular Pulse Shaping Filter