⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 beamform.m

📁 现代信号谱估计算法的matlab代码 调用函数代码
💻 M
字号:
function phi=beamform(Y,L,d)
%
% The Beamforming method for direction of arrival estimation
%
% phi=beamform(Y,L,d);
%
%    Y   <- the ULA data
%    L   <- the number of samples on [-pi/2,pi/2] to search for the sources
%    d   <- sensor spacing in wavelengths
%    phi -> the spatial spectral estimate at L equally spaced angles
%           in [-90,90] degrees
%

% Copyright 1996 by R. Moses

[m,N]=size(Y);

% compute the sample covariance matrix
R=Y*Y'/N;

phi=zeros(L,1);

for i = 1 : L,
   a=exp(-2*pi*j*d*sin(-pi/2 + pi*(i-1)/L)*[0:m-1].');
   phi(i)=real(a'*R*a);
end

⌨️ 快捷键说明

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