function cnd = condnewtonmatrix(x)
% MATLAB function computing the Euclidean condition number of the
% interpolation matrix for the Newton basis. 
% Column vector x passes the interpolation nodes.
n = length(x); M = [];
for i=1:n % i is the column index of basis function
  col = ones(n,1);
  for j=1:i-1, col = col.*(x-x(j)); end
  M = [M,col];
end
cnd = cond(M);