function [ y ] = newtstep2( f , x )

F = feval(f,x);
n = length(x);
M = zeros(n);
h = 1e-5;

for i=1:n
    z=x;
    z(i)=z(i)+h;
    M(:,i) = (feval(f,z)-F)/h;
end
    
y = x - M\F;

end