lmsmpdr.m

来自「array processing code for communication 」· M 代码 · 共 32 行

M
32
字号
clear all
close all
A=1/200;
N =10;
n = (-(N-1)/2:(N-1)/2)';
Vm = ones(N,1);
u=1:100;
U=-1:1/1000:1;
INR=10.^(10/10);
SNR=10.^(20/10);
ui=0.15;
us=0;
Vi = exp(j*n*pi*ui);
Vs=exp(j*n*pi*us);
X=zeros(10,1000)
W=zeros(10,100)
for i=1:1000
X(:,i)=sqrt(SNR)*exp(j*2*pi*randn)*(randn+j*randn)*Vi/sqrt(2)+exp(j*2*pi*randn)*(randn+j*randn)'*sqrt(INR)*Vs/sqrt(2)+(randn+j*randn)/sqrt(2);
end

for i=2:1000
  W(:,i)=W(:,(i-1))+A*(Vs-X(:,i)*X(:,i)'*W(:,(i-1)))
end
beam= W(:,1000)'*exp(j*n*pi*U);
beam= 20*log10(abs(beam));
plot(U,beam)
xlabel('{\itu}')
ylabel('Beam2 pattern (dB)')
title('\sigma_I^2 = 10dB, ui = 0.18')
axis([-1 1 -30 10])
line([0.15 0.15],[-30 5])
grid

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?