26 lines
441 B
Matlab
26 lines
441 B
Matlab
|
|
T=10e-3; %信号时宽
|
|
B=3e6; %信号带宽
|
|
fs=4*B; %采样频率
|
|
N=fix(T*fs); %采样点数
|
|
|
|
x = 0:T/N:T;
|
|
|
|
f=sin(2*pi*300*x) + sin(2*pi*200*x);
|
|
|
|
|
|
y= x(1:2:N); %采样x的奇数点
|
|
z=x(2:2:N);%采样x的偶数点
|
|
|
|
|
|
fi=sin(2*pi*300*y) + sin(2*pi*200*y);
|
|
fq=sin(2*pi*300*z) + sin(2*pi*200*z);
|
|
subplot(2,2,1)
|
|
|
|
plot(fi)
|
|
subplot(2,2,2)
|
|
|
|
plot(fq)
|
|
|
|
complexArray = fi + fq*1i;
|
|
complexArray = complexArray'; |