fvar.m

来自「电力系统的psat」· M 代码 · 共 57 行

M
57
字号
function  name = fvar(argom,spaces)% FVAR creates fixed space data strings%% NAME = FVAR(ARGOM,SPACES)%     ARGOM values (string or number)%     SPACES fixed character number%     NAME output (string)%%Author:    Federico Milano%Date:      11-Nov-2002%Update:    08-Mar-2004%Version:   1.1.0%%E-mail:    fmilano@thunderbox.uwaterloo.ca%Web-site:  http://thunderbox.uwaterloo.ca/~fmilano%% Copyright (C) 2002-2005 Federico Milano%% This toolbox is free software; you can redistribute it and/or modify% it under the terms of the GNU General Public License as published by% the Free Software Foundation; either version 2.0 of the License, or% (at your option) any later version.%% This toolbox is distributed in the hope that it will be useful, but% WITHOUT ANY WARRANTY; without even the implied warranty of% MERCHANDABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU% General Public License for more details.%% You should have received a copy of the GNU General Public License% along with this toolbox; if not, write to the Free Software% Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307,% USA.global Settingsif isnumeric(argom)  argom = round(argom/Settings.lftol)*Settings.lftol;  if argom >= 0    segno = ' ';  else    segno = '-';  end  argom = abs(argom);  name = num2str(argom);else  if double(argom(1)) <= 57 & double(argom(1)) >= 48    segno = ' ';  else    segno = '';  end  name = argom;endname = [segno, name, blanks(spaces)];name = name(1:spaces);

⌨️ 快捷键说明

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