function Nodes = addnodes(Nodes,inode,ixnode,iynode,iznode)
%
%  Name: addnodes
% 
%  Usage:  Nodes = addnodes(Nodes,inode,ixnode,iynode,iznode)
% 
%   Description:
%     Updates Nodes list -- called
%     from GUI geometry definition function 
%     'generategeom'

%  Version SWD960321
%
%  Copyright (c) 1996 by Scott W. Doebling
%	Los Alamos National Laboratory
%	ESA-EA, doebling@lanl.gov
%

if ~isempty(Nodes),

  rinode = find(Nodes(:,1) == inode);

else

  rinode = [];

end

if isempty(rinode),

%   This is a new node

   Nodes = [Nodes; inode, ixnode, iynode, iznode];

else

%   Replace an existing node

   Nodes(rinode,:) = [inode, ixnode, iynode, iznode];

end

return


