Dear Mathuranathan, can you please help me with updating of the code to reflect DBPSK instead of BPSK?

clear all;

clc;

M=2;

K=5;

DIVORDER=1;

EbNo=0:1:35;

BER_Ray=berfading(EbNo,’psk’,M,DIVORDER);

BER_Rician=berfading(EbNo,’psk’,2,1,K);

BER=berawgn(EbNo,’psk’,M,’nondiff’);

semilogy(EbNo,BER,’o-‘);

hold on

semilogy(EbNo,BER_Ray,’*-‘);

semilogy(EbNo,BER_Rician,’+-‘);

grid on

legend(‘AWGN’,’Rayleigh’,’Rice’);%,’Rayleigho simulace’);

xlabel(‘Eb/No [dB]’);

ylabel(‘BER’);

axis([0 35 1e-5 1])

All you have to do is use the following statements

ber_fading = berfading(EbNo,’dpsk’,M,divorder) %returns the BER for DPSK over an uncoded Rayleigh fading channel

ber_awgn = berawgn(EbNo,’dpsk’,M) %for DPSK over awgn

For other modulations refer the communication toolbox help

https://www.mathworks.com/help/comm/ref/berawgn.html

https://www.mathworks.com/help/comm/ref/berfading.html

*×*