n_locate.m

来自「it is a source code for geodesy」· M 代码 · 共 22 行

M
22
字号
function iloc = n_locate(i_max,node)
%N_LOCATE Finds the index of node within an i_max by 1 vector of nodes

%Kai Borre 07-31-97
%Copyright (c) by Kai Borre
%$Revision: 1.0 $  $Date: 1997/09/26 $

global nodes

for i = 1:i_max
   if (nodes(i) == 0)
      iloc = i;
      nodes(i) = node;
      break;
   end;
   if (nodes(i) == node)
      iloc = i;
      break;
   end;
end;
%%%%%%%%%%%% end n_locate.m  %%%%%%%%%%%%%%%%%%%%%

⌨️ 快捷键说明

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