www.gusucode.com > phased 案例源码 matlab代码程序 > phased/ConversionofRadiationPatternUsingSpecificUVValuesExample.m
%% Convert Radiation Pattern For Specific U/V Values % Convert a radiation pattern to $u/v$ form, with the $u$ and $v$ coordinates % spaced by 0.05. % Copyright 2015 The MathWorks, Inc. %% % The radiation pattern is cosine of the elevation angle. az = -90:90; el = -90:90; pat_azel = repmat(cosd(el)',1,numel(az)); %% % Define the set of $u$ and $v$ coordinates at which to sample the pattern. % Then, convert the pattern. u = -1:0.05:1; v = -1:0.05:1; pat_uv = azel2uvpat(pat_azel,az,el,u,v); %% % Plot the result. H = surf(u,v,mag2db(pat_uv)); H.LineStyle = 'none'; xlabel('u'); ylabel('v'); zlabel('Pattern');