odefun=@(t,y)[-2*y];
tspan=[0,10];
y0=1;
color=['ro';'b+';'g.';'ks'];
H=[0.01, 0.1, 1, 2];
k=1;
for h=H
Nh=round((tspan(2)-tspan(1))/h);
[tn,un]=cranknic(odefun,tspan,y0,Nh);
figure(k)
xlabel('t')
ylabel('u_n')
plot(tn,un,color(k,:))
title(['h=',num2str(h)])
k=k+1;
end















