function y=hutes(x1,m,T,delta,k)
				#hutes(x1,m,T,delta,k) simulated annealing,
				#m uj veletlen pontbol keressuk ki az uj
				#x-et, 10 lepesenkent alfa helyett
				#(1-delta)*T-t vesszuk 
				#T a hutesi parameter (homerseklet)
n=length(x1);x=x1;fMIN=f(x);xMIN=x;
for i=1:k fx=f(x);if fMIN>fx xMIN=x;fMIN=fx;end;
        X=T*(log(rand(n,m))-log(rand(n,m)));j0=1;fmin=f(x+X(:,1));
        for j=2:m fj=f(x+X(:,j));if fj<fmin fmin=fj;j0=j;end;
        end;
        if fmin<fx x=x+X(:,j0);
        else for j=1:m p(j)=e^((fx-f(x+X(:,j)))/T);end;S=sum(p);
             p=p/(S+10^-100);t=rand;j0=1;P=p(1);
             for j=1:m-1 if t>P j0=j+1;end;P=P+p(j+1);
             end;x=x+X(:,j0);
        end;
        if i/10==floor(i/10) T=T*(1-delta);end;
        if i/100==floor(i/100) fMIN=fMIN,end;
end;y=x;if fMIN>f(x) xMIN=x;end;y=xMIN;