get.m

来自「computation of conformal maps to polygon」· M 代码 · 共 31 行

M
31
字号
function varargout = get(map,varargin)
%GET    Get map parameters.
%   [VAL1,VAL2,...] = GET(F,'PROP1','PROP2',...) returns the values of the
%   map F corresponding to the requested properties. Valid properties
%   are: 
%   
%       polygon, options, prevertex, diskmap, rectpoly, raffine

% Copyright 1999 by Toby Driscoll.
% $Id: get.m 79 1999-09-30 23:04:05Z tad $

for j = 1:length(varargin)
  switch lower(varargin{j}(1:min(3,length(varargin{j}))))
   case 'pol'
    varargin{j} = map.scmap.polygon;
   case 'opt'
    varargin{j} = map.scmap.options;
   case 'dis'
    varargin{j} = map.diskmap;
   case 'rec'
    varargin{j} = map.rectpolygon;
   case 'raf'
    varargin{j} = map.rectaffine;
   case 'pre'
    varargin{j} = vertex(map.rectpolygon);
   otherwise
    warning(sprintf('Property ''%s'' not recognized.\n',varargin{j}))
    varargin{j} = [];
  end
end

⌨️ 快捷键说明

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