无线通信中的IQ调制,BPSK调制,QPSK调制,16QAM调制的理解 下载本文

内容发布更新时间 : 2024/5/26 19:21:27星期一 下面是文章的全部内容请认真阅读。

Linux下使用GNU Octave运行下面的代码:

MATLAB 1 %输入信号 2 3 >> subplot(4,1,1); 4 >> t=0:0.001:8; 5 >> d=[0 0 ;0.5 1;1 1;1.5 0;2 1 ;2.5 1;3 0;3.5 0;4 0;4.5 1 ;5 1 ;5.5 0 ;6 1 ;6.5

6 1 ;7 0 ;7.5 0];

7 >> s=pulstran(t-0.25,d,'rectpuls',0.5);plot(t,s) ; 8 >> axis([0 8 -0.5 1.5]);

9 >> text(0.25,1.2,'0') ; text(0.75,1.2,'1') ; text(1.25,1.2,'1') ; 10 text(1.75,1.2,'0') ;

11 >> text(2.25,1.2,'1') ; text(2.75,1.2,'1') ; text(3.25,1.2,'0') ; text(3.75,1.2,'0') ;

>> text(4.25,1.2,'0') ; text(4.75,1.2,'1') ; text(5.25,1.2,'1') ; text(5.75,1.2,'0') ;

>> text(6.25,1.2,'1') ; text(6.75,1.2,'1') ; text(7.25,1.2,'0') ; text(7.75,1.2,'0') ;

MATLAB

1 % I路信号 2

3 >> subplot(4,1,2); 4 >> t=0:0.001:8; 5 >> a=1/sqrt(2);

6 >> d=[0 -a ;1 +a;2 -a;3 +a; 4 -a ;5 +a;6 -a;7 +a]; 7 >> s=pulstran(t-0.5,d,'rectpuls');plot(t,s) ; 8 >> axis([0 8 -2 2]); 9 >> text(0.5,1.5,'-0.7') ;

10 text(1.5,1.5,'+0.7') ;text(2.5,1.5,'-0.7') ;text(3.5,1.5,'+0.7'); >> text(4.5,1.5,'-0.7') ;

text(5.5,1.5,'+0.7') ;text(6.5,1.5,'-0.7') ;text(7.5,1.5,'+0.7');

MATLAB

1 % Q路信号 2

3 >> subplot(4,1,3); 4 >> t=0:0.001:8;

5 >> d=[0 +a;1 -a;2 -a;3 +a; 4 +a;5 -a;6 -a;7 +a]; 6 >> s=pulstran(t-0.5,d,'rectpuls');plot(t,s) ; 7 >> axis([0 8 -2 2]);

8 >> text(0.5,1.5,'+0.7') ; text(1.5,1.5,'-0.7') ; text(2.5,1.5,'-0.7') ; 9 text(3.5,1.5,'+0.7')

>> text(4.5,1.5,'+0.7') ; text(5.5,1.5,'-0.7') ; text(6.5,1.5,'-0.7') ; text(7.5,1.5,'+0.7')

MATLAB

1 %QPSK调制信号 2

3 >> subplot(4,1,4); 4 >> t=0:0.001:8;

5 >> d1=[0 -a ;1 +a;2 -a;3 +a; 4 -a ;5 +a;6 -a;7 +a]; 6 >> s1=pulstran(t-0.5,d1,'rectpuls').*cos(2*pi*5*t) ; 7 >> d2=[0 +a;1 -a;2 -a;3 +a; 4 +a;5 -a;6 -a;7 +a]; 8 >> s2=pulstran(t-0.5,d2,'rectpuls').*sin(2*pi*5*t); 9 >> plot(t,s1-s2) ; 10 >> axis([0 8 -2 2]);

11 >> text(0.3,1.5,'3\\pi/4') ; text(1.3,1.5, '7\\pi/4') ; text(2.3,1.5,'5\\pi/4') ; 12 text(3.3,1.5,'\\pi/4') ;

>> text(4.3,1.5, '3\\pi/4') ; text(5.3,1.5, '7\\pi/4') ; text(6.3,1.5,'5\\pi/4') ; text(7.3,1.5,'\\pi/4') ;