Home > Back-end >  Turbo under weak Rayleigh channel simulation
Turbo under weak Rayleigh channel simulation

Time:09-23

Dear bosses, ask a question here:
I made a Turbo decoding procedures, based on the Wu Yufei code to simulation in the Rayleigh channel bit error rate, using the Matlab Rayleighchan function and awgn function in 2009,
But after decoding, the error rate of 10 ^ 0, trouble you to help me see
The code is as follows:
En_output=encoderm (x, g, alpha, puncture); % Turbo decoder, did the BPSK modulation encoder output (1 - & gt; + 1, 0 - & gt; 1)
Chan=rayleighchan; % Rayleigh Channel, not considering the doppler frequency shift
R_chan=filter (chan, en_output); % Effect Channel
Yk=demultiplex (r_chan, alpha, puncture); % demultiplex the to get input for decoder 1 and 2
% the Scale of the received bits
L_c rec_s=0.5 * * yk;

% the Initialize extrinsic information
% L_e (1: L_total)=zeros (1, L_total);
L_e=zeros (1, L_total);
For iter=1: niter
% Decoder one
L_a (alpha)=L_e; % a dei info.
L_all=logmapo (rec_s (1, :), g, L_a, 1); % complete info.

L_e=L_all - 2 * rec_s (1, 1:2-2 * L_total) - L_a; % extrinsic info.

% Decoder two
L_a=L_e (alpha); % a dei info.
L_all=logmapo (rec_s (2, :), g, L_a, 2); % complete info.

L_e=L_all - 2 * rec_s (2, 1:2-2 * L_total) - L_a; % extrinsic info.

% Estimate the info. Bits
Xhat (alpha)=(sign (L_all) + 1)/2;

% Number of bit errors in the current iteration
Err (iter)=length (find (xhat (1: L_total -m) ~=x));

% Count frame errors for the current iteration
If err (iter) & gt; 0
Nferr (nEN, iter)=nferr (nEN, iter) + 1;
End
End
% iter

% of the Total number of bit errors for all iterations
Is incremented (nEN, 1: niter)=incremented (nEN, 1: niter) + err (1: niter);

If rem (nframe, 3)==0 | | nferr (nEN, niter)==ferrlim
% Bit error rate
Ber (nEN, 1: niter)=incremented (nEN, 1: niter)/nframe/(L_total - m);
% Frame error rate
Fer (nEN, 1: niter)=nferr (nEN, 1: niter)/nframe;
  • Related