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

📄 dispuserleft.m

📁 It s a simulation for WCDMA Radio Networks.
💻 M
字号:
%DISPUSERLEFT   DISPUSERLEFT displays all users after both UL and DL iterations
%               indicating the different bit rates by different colors and markers.
%
%Inputs:  (global) mobilestation, basestation, numBSs, umMSs, xPos, yPos,
%         xmin, xmax, ymin, ymax, resolution
%Outputs:
%
%Authors: Achim Wacker (AWa), Jaana Laiho-Steffens (jls), Kai Heikkinen (KHeik)
%
%Revision: 5.0.0cd   Date: 17-Jul-2001
%
%needed m-files: BSplot.m

tmpLayer = [];
if numBStype1
   tmpLayer = [tmpLayer 1];
end
if numBStype2
   tmpLayer = [tmpLayer 2];
end

for layer = tmpLayer
   eval(['tmpInd = numBStype' num2str(layer) ';']);
   eval(['tmpMSs = [mobilestation(indMStype' num2str(layer) ')];']);
   
   colors = 'gbrgbrgbr';
   marker = '...***ooo';
   ii = 1;
   figure;
   set(gcf, 'Tag', 'tagUserFig');
   hold on
   bitRates = unique([[mobilestation.RUL] [mobilestation.RDL]]);
   if length(bitRates) > 9
      bitRates = bitRates(1:9);
   end
   numOut = [];
   userDelta = 0;
   lBitRates = [];
   for tmpRate = bitRates
      ind1 = find([tmpMSs.RUL] == tmpRate & [tmpMSs.usedCarr] == layer);
      plot([tmpMSs(ind1).x], [tmpMSs(ind1).y], [marker(ii) colors(ii)]);
      ii = ii+1;
      if ~isempty(ind1)
         lBitRates = [lBitRates; tmpRate];
         numOut = [numOut; length(ind1)];
         userDelta = userDelta+length(ind1);
      end
   end
   
   servedUsers = sum([tmpMSs.usedCarr] == layer);
   if numBStype1 == 0 | numBStype2 == 0
      layerString = [];
   else
      if mode == 1
         layerString = [' for carrier ' num2str(layer)];
      elseif mode == 2
         layerString = [' for operator ' num2str(layer)];
      end
   end
   titleText = ['USER DISTRIBUTION' layerString ' (total = ' num2str(servedUsers), ' users)'];
   title(['\it{', titleText, '}']);
   axis('equal');
   BSplot(basestation, gcf, vectMap, lossData);
   hLegend = legend(strcat(num2str(lBitRates(:)/1000), ' kBit/s (', num2str(numOut(:)), ')'));
   set(hLegend, 'color', [1 1 1]);
end

%clean up
clear tmpMSs ind1 ii totalUsers colors marker tmpRate layerString servedUsers layer numOut userDelta lBitRates bitRates
clear userDelta outageReason outageText titleText hLegend

⌨️ 快捷键说明

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