here is the example of index used in an EFGM code
[index] = define_support(node,pt1,di);
function [index] = define_support(node,x,di)
% find nodes in neighbouring of point x
% Inputs:
% 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)]; % difference between co-ordinates of nodes and point pt in the main code
for i = 1 : numnode
r(i) = norm(dif(i,:));
end
index = find(r - di