define_support.asv

来自「efg code with matlab」· ASV 代码 · 共 19 行

ASV
19
字号
% *************************************************************************
%                 TWO DIMENSIONAL ELEMENT FREE GALERKIN CODE
%                            Nguyen Vinh Phu
%                        LTDS, ENISE, Juillet 2006
% *************************************************************************
function [index] = define_support(node,x,di)
% find nodes in neighbouring of point x
% Inpputs:
%  node : numnode x 2, nodal coordinates
%  x    : 1 x 2, coordinate of point 
%  di   : 1 x numnode, size of support of nodes

numnode = size(node,1) ;
dif = node - [ones(numnode,1)*x(1,1) ones(numnode,1)*x(1,2)];
for i = 1 : numnode
    r(i) = norm(dif(i,:));
end

index = find(r<=di);

⌨️ 快捷键说明

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