Problem with "Rayleighchan" in MATLAB! Somebody he

Status
Not open for further replies.

hoangtuna

Newbie level 3
Joined
Dec 11, 2009
Messages
4
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
Vietnam
Activity points
1,310
Hello everybody !
I want to simmulate a Rayleigh channel with BPSK signal with following code
===============================
chan=rayleighchan(1/10000,100);
M=2;
tx=randint(nbit,1,M);
dpsksig=pskmod(tx,M);
fadedsig=filter(chan,dpsksig);
snr=0:1:20;
for n=1:length(snr)
rxsig=awgn(fadedsig,snr);
rx=pskdemod(rxsig,M);
[nerrors,ber]=biterr(tx(2:end),rx(2:end));
end
================================
But BER [1*21] I get is terrible
[0.472647264726473 0.477147714771477 0.465246524652465 0.465346534653465 0.470547054705471 0.463746374637464 0.462746274627463 0.458845884588459 0.461246124612461 0.461546154615462 0.460046004600460 0.457145714571457 0.454145414541454 0.453945394539454 0.453345334533453 0.456245624562456 0.452745274527453 0.452245224522452 0.454945494549455 0.454645464546455 0.454845484548455]
It is different with theorical BER.
Why there is that difference? Someone can help me?
 

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…