www.gusucode.com > phased 案例源码 matlab代码程序 > phased/MVDRBeamformerExample.m
%% MVDR Beamformer with Arrival Directions of 30 and 45 Degrees % Construct a 10-element, half-wavelength-spaced line array. Choose two % arrival directions of interest - one at 30° azimuth and the other at 45° azimuth. % Assume both directions are at 0° elevation. Compute the MVDR beamformer weights for % each direction. Specify a sensor spatial covariance matrix % that contains signals arriving from -60° and 60° and noise at -10 dB. %% % Set up the array and sensor spatial covariance matrix. N = 10; d = 0.5; elementPos = (0:N-1)*d; Sn = sensorcov(elementPos,[-60 60],db2pow(-10)); %% % Solve for the MVDR beamformer weights. w = mvdrweights(elementPos,[30 45],Sn); %% % Plot the two MVDR array patterns. plotangl = -90:90; vv = steervec(elementPos,plotangl); plot(plotangl,mag2db(abs(w'*vv))) grid on xlabel('Azimuth Angle (degrees)'); ylabel('Normalized Power (dB)'); legend('30 deg','45 deg'); title('MVDR Array Pattern') %% % The figure shows plots for each beamformer direction. One plot has the % expected maximum gain at 30 degrees and the other at 45 degrees. The nulls at -60 and % 60 degrees arise from the fundamental property of the MVDR beamformer of suppressing % power in all directions except for the arrival direction.