Beam width of linear array using MVDR beamformer

I did delay and sum beamforming technique and MVDR beamforming technique in MATLAB in time domain, but I could not make a comparison between the beam patterns as both showed same beam width. But when I did it in frequency domain, I could differentiate both the techniques as MVDR beamformer showed better resolution( low beam width) compared to delay and sum bemaformer. I used 10 array elements, with input signal sine added with noise and the steering angle is 20 degrees. Is there something wrong with my MVDR code? Please help.

    %%
clc;
clear all;
close all;

%% Time specifications:
Fs = 25e4;                   % samples per second
dt = 1/Fs;                   % seconds per sample
StopTime = 1e-3;  %0.952e-3;           % seconds
t = (0:dt:StopTime-dt)';     % seconds

%% Sine wave:
Fc = 8e3;                     % hertz
signal = sin(2*pi*Fc*t);
x=signal+randn(size(t));
%%
N = 10;
d = 0.5;
plotangl = -90:90;
tm = plotangl * pi/180;
elementPos = (0:N-1)*d;
thetasteer=20;
c=1150;
k=exp(-1j*2*pi*elementPos'*sin(thetasteer*pi/180)/c);
x1=k*x';%10x250
Sn=(x1*x1');
a=0.01.*eye(10);
Sn1=Sn+a;

%%

as=exp(-1j*2*pi*elementPos*sin(thetasteer*pi/180));%1x10
w1=(inv(Sn1)*as');
w2=(conj(as)*inv(Sn1));
w3=w2*as';
w=w1/w3;%10x1
%w=ones(10,1);%10x1
W=w*as;%10x10
%%
vv = exp (1j *2*pi*d* (0: N-1)'* (sin (tm)));%10x181
B1=W*vv;
B2=B1'*x1;
B3=abs(B2/max(B2))';%normalize
figure(2);subplot(2,1,1);polar (plotangl*pi/180, B3);title('polar plot of mvdr ');

B = 10*log10(B3);
figure(2);
subplot(2,1,2);
plot(plotangl,B);
grid on
xlabel(' Angle (degrees)');
ylabel('Normalized Beam Power[dB]');
legend('20 deg');
title('mvdr Array Pattern, 10 array elements');


Well there a few things. You didn't post your other result so no one can logically comment, comment on why one result doesn't agree with the other, without the other.

It is also usually more convenient to work in $u_x=sin(\theta)$ instead of $\theta$ because the pattern is uniform for all steer directions in $u_x$, while beamwidth is a function of $\theta$ in $\theta$ coordinates, but this is a personal preference.

I also suggest you get a copy of:

Van Trees, Harry L. Optimum array processing: Part IV of detection, estimation, and modulation theory. John Wiley & Sons, 2004.

(he lists me in the acknowledgments but I don't get a kick back ;( )

https://www.mathworks.com/matlabcentral/fileexchange/46514-optimum-array-processing--van-trees--solutions-and-figures

as an example, it includes this.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Figure 2.23
% Beam pattern for 10-element uniform array (d=lambda/2)
% scanned to 30 degrees (60 degrees from broadside)
% Xin Zhang 1/20/99
% Last updated by K. Bell 6/25/01
% Functions called: polardb
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

clear all
close all

N = 10;
n = (-(N-1)/2:(N-1)/2).';
theta = pi*(-1:0.001:1);
u = cos(theta);
d = 1/2;
vv = exp(j*2*pi*d*n*u);
theta_T = 30/180*pi;
w = 1/N*ones(N,1).*exp(j*n*pi*cos(theta_T));
B = w'*vv;
B = 10*log10(abs(B).^2);
figure
h=polardb(theta,B,-40);
hold off


While not a big deal, you actually are using MPDR (see Van Trees) not MVDR when you include the desired signal in the covariance matrix. It only matters if you don't exactly steer in that direction. To be honest, most of the literature doesn't make the distinction but the terms optimal and adaptive have been muddled for decades.

As the @Hkxs points out, you are using both time and frequency domain features to your code. MVDR is a narrowband beamformer usually taken at the same temporal DFT bin from each sensor. The temporal signal is not necessary to calculate the beam pattern and if you want to retain that feature, to steer by phase multiplication,

 signal = exp(1j*2*pi*Fc*t);


and the noise should be added at the elements.

the pattern should just be

bp=w'*vv;


For you example of a single signal steered in it's direction with $\sigma^2 \mathbf{I}$ noise, MVDR should return uniform weights.

It also helps to comment your code.

I think you're mixing time domain and frequency domain, your signal $x$ is in time and you're multiplying it by a complex exponential, generating a complex signal that is not the Fourier transform of $x$, if you want to delay $x$ in order to simulate the angle of arrival of the signal you have to do $x_{m}(n)=x(n-\tau_{m})$ (in the time domain) or $X_{m}(\omega)=e^{-j \tau_{m}}X(\omega)$ being "m" the microphone number.

Also you have to include the wave number in the steering vector $k=\dfrac{2\pi}{\lambda}$.

• I have made changes accordingly but it still gives me same beam width. – ANAGHA S GOURI Mar 8 '18 at 15:08