Saturday, August 13, 2016

Chapter 4

CHAPTER 4

DESIGN AND IMPLEMENTATION
OF MULTILAYER QOS MODEL
FOR M-ARY SYSTEM



Introduction
Simulation Codes
Simulation Results and Analysis
Conclusion











DESIGN AND IMPLEMENTATION OF MULTILAYER
QOS MODEL FOR M-ARY SYSTEM

    1. Introduction
From results of last chapter, it observed that for spectral efficient modulation techniques such as M-PSK, BER performance degrades as value of a modulation order M (≥4) increase as shown in Fig. 4.1. This is because the distance between symbols on constellation decreases as number of symbol increases with modulation order.
C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (10).bmpFig. 4.1 BER performance of BPSK, QPSK, 8-PSK, 16-PSK



Fig. 4.2 Constellation Diagram of BPSK
C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (9).bmp
Fig. 4.3 Constellation Diagram of 4-PSK

C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (10).bmp
Fig. 4.4 Constellation Diagram of 8-PSK

C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (11).bmp
Fig. 4.5 Constellation Diagram of 32-PSK

Also from constellations diagrams of BPSK, 4-PSK, 8-PSK and 32-PSK (shown in Figures 4.2-4.5), it is observed that constellations of symbols are upward compatible i.e. constellation of symbols of BPSK can be derived from constellation of symbols of 4-PSK, 8-PSK and so on. Similarly, constellation of symbols of 4-PSK can be derived from constellation of symbols of 8-PSK, 16-PSK and so on.
the idea behind this part of thesis is that the user easily switch from one level of BER performance to another actively(on demand) without changing the actual MODEM. This is possible by using computerized encoding and decoding at transmitter and receiver respectively.    
C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (13).bmp
Fig. 4.6 Logical decision boundary of QoS level 4
C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (14).bmp
Fig. 4.7 Logical decision boundary of QoS level 3

C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (15).bmp
Fig. 4.8 Logical decision boundary of QoS level 2
Method: The comprising of encoding and decoding techniques with 32-PSK MODEM circuitry. For level-1, this technique work normally as 32-PSK transceiver. For level-2, the input bits are grouped into 3-bits symbol and a zero is added in 4th bit place. Appending a zero in end in digital signal is equivalent by multiplication by 2. The resultant signal is mapped to 32 bit PSK such as block coded modulation. It also behaves like repetitive constellation points. At receiver side, the decision boundary is extended logically such that any phase difference between 0o to 45o   is resemble symbol “0” (=000) and between 45o to 90o resemble symbol “1” (=001) and so on. similarly level 2 and 3 signals are encoded, mapped and decoded.  

    1. Simulation Codes
SamplesPerFrame = 120; maxNumErrs=100; maxNumBits=1e6; M = 32;
s = RandStream.create('mt19937ar', 'seed',529558);
prevStream = RandStream.setGlobalStream(s);
hInt2Bit1 = comm.IntegerToBit('BitsPerInteger',5,'OutputDataType','uint8');
hBit2Int1 = comm.BitToInteger('BitsPerInteger',5,'OutputDataType','uint8');
hInt2Bit3 = comm.IntegerToBit('BitsPerInteger',3,'OutputDataType','uint8');
hBit2Int3 = comm.BitToInteger('BitsPerInteger',3,'OutputDataType','uint8');
hInt2Bit4 = comm.IntegerToBit('BitsPerInteger',2,'OutputDataType','uint8');
hBit2Int4 = comm.BitToInteger('BitsPerInteger',2,'OutputDataType','uint8');
hInt2Bit5 = comm.IntegerToBit('BitsPerInteger',1,'OutputDataType','uint8');
hBit2Int5 = comm.BitToInteger('BitsPerInteger',1,'OutputDataType','uint8');
hMod = comm.PSKModulator('ModulationOrder',M,'SymbolMapping','binary', ...
       'PhaseOffset',0,'BitInput',false);
hDemod = comm.PSKDemodulator('ModulationOrder',M,'SymbolMapping',...
       'binary','PhaseOffset',0,'BitOutput',false,...
       'OutputDataType','uint8','DecisionMethod','Hard decision');
hChan = comm.AWGNChannel('NoiseMethod','Signal to noise ratio (Eb/No)', ...
                   'BitsPerSymbol',log2(M),'SignalPower',1);
hSymError = comm.ErrorRate; hBitError = comm.ErrorRate;
EbNoVec = 0:0.5:25;                             
SERVec32 = zeros(size(EbNoVec)); BERVec32 = zeros(size(EbNoVec));
SERVec8 = zeros(size(EbNoVec));   BERVec8 = zeros(size(EbNoVec));
SERVec4 = zeros(size(EbNoVec));   BERVec4 = zeros(size(EbNoVec));
SERVec2 = zeros(size(EbNoVec));   BERVec2 = zeros(size(EbNoVec));
txBits = randi([0 1], SamplesPerFrame, 1, 'uint8');
for p = 1:length(EbNoVec);
 reset(hSymError);  reset(hBitError);
 hChan.EbNo = EbNoVec(p);
 SER = zeros(3,1); BER = zeros(3,1);                          
 while (BER(2)<maxNumErrs) && (BER(3)<maxNumBits)
   txSym = step(hBit2Int1, txBits);   tx = step(hMod, txSym);   rx = step(hChan, tx);                     
   rxSym = step(hDemod, rx);    rxBits = step(hInt2Bit1, rxSym);           
   SER = step(hSymError, txSym, rxSym); BER = step(hBitError, txBits, rxBits);   
 end
 SERVec32(p) = SER(1);     BERVec32(p) = BER(1);
 if (BER(1) <= 1e-4)||(SER(1) <= 1e-4) , break , end
end
release(hChan); release(hMod); release(hDemod);
for q = 1:length(EbNoVec);
 reset(hSymError); reset(hBitError);
 hChan.EbNo = EbNoVec(q) + 10*log10(8/32);
 SER = zeros(3,1);  BER = zeros(3,1);                          
 while (BER(2)<maxNumErrs) && (BER(3)<maxNumBits)
   txSym3 = step(hBit2Int3, txBits); txSym13 = txSym3*4;tx3 = step(hMod, txSym13);                  
   rx3 = step(hChan, tx3);  rxSym = step(hDemod, rx3);                
   for p = 1:length(rxSym)
       if (rxSym(p)>2)&&(rxSym(p)<6) rxSym(p)=1;
       elseif (rxSym(p)>6)&&(rxSym(p)<10) rxSym(p)=2;
       elseif (rxSym(p)>10)&&(rxSym(p)<14)  rxSym(p)=3;
       elseif (rxSym(p)>14)&&(rxSym(p)<18) rxSym(p)=4;
       elseif (rxSym(p)>18)&&(rxSym(p)<22)  rxSym(p)=5;
       elseif (rxSym(p)>22)&&(rxSym(p)<26)  rxSym(p)=6;
       elseif (rxSym(p)>26)&&(rxSym(p)<30)  rxSym(p)=7;
       else
           rxSym(p)=0;
       end
   end
   rxBits3 = step(hInt2Bit3, rxSym);           
   SER = step(hSymError, txSym3, rxSym);   BER = step(hBitError, txBits, rxBits3);   
 end
 SERVec8(q) = SER(1); BERVec8(q) = BER(1);
 if (BER(1) <= 1e-4)||(SER(1) <= 1e-4) , break , end
end
release(hChan); release(hMod); release(hDemod);
for q = 1:length(EbNoVec);
 reset(hSymError); reset(hBitError); hChan.EbNo = EbNoVec(q) + 10*log10(4/32);
 SER = zeros(3,1);  BER = zeros(3,1);                          
 while (BER(2)<maxNumErrs) && (BER(3)<maxNumBits)
   txSym4 = step(hBit2Int4, txBits); txSym14 = txSym4*8;
   tx4 = step(hMod, txSym14); rx4 = step(hChan, tx4); rxSym = step(hDemod, rx4);                
   for p = 1:length(rxSym)
       if (rxSym(p)>4)&&(rxSym(p)<12) rxSym(p)=1;
       elseif (rxSym(p)>12)&&(rxSym(p)<20) rxSym(p)=2;
       elseif (rxSym(p)>20)&&(rxSym(p)<28) rxSym(p)=3;
       else
           rxSym(p)=0;
       end
   end
   rxBits4 = step(hInt2Bit4, rxSym);           
   SER = step(hSymError, txSym4, rxSym);    BER = step(hBitError, txBits, rxBits4);   
 end
 SERVec4(q) = SER(1); BERVec4(q) = BER(1);
 if (BER(1) <= 1e-4)||(SER(1) <= 1e-4) , break , end
end
release(hChan); release(hMod); release(hDemod);
for q = 1:length(EbNoVec);
 reset(hSymError); reset(hBitError);
 hChan.EbNo = EbNoVec(q) + 10*log10(2/32);
 SER = zeros(3,1); BER = zeros(3,1);                          
 while (BER(2)<maxNumErrs) && (BER(3)<maxNumBits)
   txSym5 = step(hBit2Int5, txBits); txSym15 = txSym5*16;
   tx5 = step(hMod, txSym15); rx5 = step(hChan, tx5); rxSym = step(hDemod, rx5);                
   for p = 1:length(rxSym)
       if (rxSym(p)>8)&&(rxSym(p)<24 rxSym(p)=1;
       else
           rxSym(p)=0;
       end
   end
   rxBits5 = step(hInt2Bit5, rxSym);           
   SER = step(hSymError, txSym5, rxSym);  BER = step(hBitError, txBits, rxBits5);   
 end
 SERVec2(q) = SER(1);  BERVec2(q) = BER(1);
 if (BER(1) <= 1e-4)||(SER(1) <= 1e-4) , break , end
end
RandStream.setGlobalStream(prevStream);
semilogy(EbNoVec,SERVec32,EbNoVec,SERVec8,EbNoVec,SERVec4,EbNoVec,… SERVec2);
axis([0 25 1e-4 1]); legend  ( 'QOS Pt.1', 'QOS Pt.2', 'QOS Pt.3', 'QOS Pt.4');
xlabel  ( 'Eb/No' ); ylabel( 'Error Probability' ); title('Symbol Error Probability');  grid on;  
Fig.;
semilogy(EbNoVec,BERVec32,EbNoVec,BERVec8,EbNoVec,BERVec4,EbNoVec,…BERVec2);
axis([0 25 1e-4 1]); legend  ('QOS Pt.1', 'QOS Pt.2', 'QOS Pt.3', 'QOS Pt.4');
xlabel  ( 'Eb/No' ); ylabel( 'Error Probability' ); title( 'Bit Error Probability' );grid on;  
    1. Simulation Results and Analysis
C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (25).bmp
Fig. 4.9 Simulated SER performance of 4-Level QOS system.

C:\Users\Simer\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Word\New Picture (27).bmp
Fig. 4.10 Simulated BER performance of 4-Level QOS system.

    1. Conclusion
In this chapter, it is concluded that constellation signals of lower modulation order can be encoded to constellation signal of higher modulation order and can be demodulated by same higher order demodulator. Fig. 4.10 shows the comparison of BER performance of different levels of QoS system. Different level of QoS is assigned to these BER performances such as QoS level 1 is assigned to 32-PSK constellation signal, QoS level 2 is assigned to 8-PSK constellation signal, QoS level 3 is assigned to 4-PSK constellation signal and QoS level 4 is assigned to BPSK constellation signal and BER performance is getting better as lower constellation signal is mapped to higher constellation signal. Same conclusion is derived from Fig. 4.9 on the basis of SER







No comments:

Post a Comment