Issue in de-punctured Convolutional Code

Status
Not open for further replies.

Ram_sek

Newbie level 3
Joined
Feb 22, 2014
Messages
4
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
22
Hi

I tried a simple OFDM program with punctured convolutional codes. But there is an issue in de-puncturing so my graph for SNR vs BER is a flat response.

My code is as below. Please help me out why im getting bad graph like this..
Code:
N = 10^3;               
SNR_dB = [0:24];     
M=4;

for ii = 1:1:length(SNR_dB)
% input
x = randint(1,N);   
% puncturing- channel encoding
t = poly2trellis(7,[171 133]);                  
punctcode = convenc(x, t);

inter1=randintrlv(punctcode,2); 
q1=qammod(inter1,M);
f1=ifft(q1);
x1=awgn(f1,SNR_dB(ii),'measured');

ww=fft(x1);                        
dmod = qamdemod(ww,M);
y= randdeintrlv(dmod,2);
% de-puncturing
d_punctcode = vitdec(y,t,35, 'trunc', 'unquant');
[num2,ber(ii)]= biterr(x,d_punctcode);
end

figure();
semilogy(SNR_dB,ber,'LineWidth',2)
grid on
axis([0 15 10^-4 1])
xlabel('SNR')
ylabel('BER')




 
Last edited by a moderator:

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…