中文说明:函数 ASK_FSK_PSK(msglen) %msglen = 要传输的位数 %取 msglen = 10000 或更准确 20000 如果您有任何问题或意见请联系我 @ % %%=============================================== %NIKESH 巴贾杰 %助理教授,可爱的专业大学、 印度 %Almameter: 阿利加穆斯林大学、 印度 %+919915522564、 bajaj.nikkey@gmail.com %%=============================================== n = msglen ; b=randint(1,n) ; f1 = 1 ; f2 = 2 ; t = 0: 1 / 30: 1-1/30 ; %问 sa1=sin(2*pi*f1*t) ; E1=sum(sa1.^2) ; sa1=sa1/sqrt(E1) ;%单位能源 sa0=0*sin(2*pi*f1*t) ; FSK % sf0=sin(2*pi*f1*t) ; E=sum(sf0.^2) ; sf0=sf0/sqrt(E) ; sf1=sin(2*pi*f2*t) ; E=sum(sf1.^2) ; sf1=sf1/sqrt(E) ; PSK % sp0=-sin(2*pi*f1*t)/sqrt(E1) ; sp1=sin(2*pi*f1*t)/sqrt(E1) ; %调制 问 = [] ; psk = [] ; fsk = []; i = 1: n 如果 b (i) = = 1 问 = [询问 sa1] ; psk = [psk sp1] ; fsk = [fsk sf1] ; 其他
English Description:
function ASK_FSK_PSK(msglen) %msglen= number of bits to be transmitted %take msglen=10000, or 20000 for more accuracy %If you have any problem or feedback please contact me @ %%=============================================== % NIKESH BAJAJ % Asst. Prof., Lovely Professional University, India % Almameter: Aligarh Muslim University, India % +919915522564, bajaj.nikkey@gmail.com %%=============================================== n=msglen; b=randint(1,n); f1=1;f2=2; t=0:1/30:1-1/30; %ASK sa1=sin(2*pi*f1*t); E1=sum(sa1.^2); sa1=sa1/sqrt(E1); %unit energy sa0=0*sin(2*pi*f1*t); %FSK sf0=sin(2*pi*f1*t); E=sum(sf0.^2); sf0=sf0/sqrt(E); sf1=sin(2*pi*f2*t); E=sum(sf1.^2); sf1=sf1/sqrt(E); %PSK sp0=-sin(2*pi*f1*t)/sqrt(E1); sp1=sin(2*pi*f1*t)/sqrt(E1); %MODULATION ask=[];psk=[];fsk=[