Shwan
Newbie level 6
maximum ratio combiner
Hi,
Could you please help me how to use the Maximum Ratio combination in Multipath Rayleigh fading channel, using Matlab comands, and have a look for the program bellow you will see the error that I have, and could you tell me the problem, and how to solve it.
clear all
whos
SNR=0:2:20; %Range of noise in dB.
M=2; % DBPSK
n=50000;
c=rayleighchan(1/10000,100,[0 2e-5],[0 -9]); %Rayleigh Channel that uses
% data rate 10000 bit/second,
x=randint(n,1,M); % Randomly generate data bits
xmod=dpskmod(x,M); %Modulate the input signal
yfaded=filter(c,xmod); %Effect of the channel
for i=1:length(SNR)
y=awgn(yfaded,SNR(i));
z=dpskdemod(y,M);
rs=sum(z.*conj,1);
[num,ber(i)]=biterr(x,rs);
end
semilogy(SNR,ber);
grid;
xlabel('SNR(dB)')
ylabel('BER')
title('BER for DBPSK over Multipath Fading(Rayleigh Channel)')
Cheers
Shwan
Hi,
Could you please help me how to use the Maximum Ratio combination in Multipath Rayleigh fading channel, using Matlab comands, and have a look for the program bellow you will see the error that I have, and could you tell me the problem, and how to solve it.
clear all
whos
SNR=0:2:20; %Range of noise in dB.
M=2; % DBPSK
n=50000;
c=rayleighchan(1/10000,100,[0 2e-5],[0 -9]); %Rayleigh Channel that uses
% data rate 10000 bit/second,
x=randint(n,1,M); % Randomly generate data bits
xmod=dpskmod(x,M); %Modulate the input signal
yfaded=filter(c,xmod); %Effect of the channel
for i=1:length(SNR)
y=awgn(yfaded,SNR(i));
z=dpskdemod(y,M);
rs=sum(z.*conj,1);
[num,ber(i)]=biterr(x,rs);
end
semilogy(SNR,ber);
grid;
xlabel('SNR(dB)')
ylabel('BER')
title('BER for DBPSK over Multipath Fading(Rayleigh Channel)')
Cheers
Shwan