function [t,w]=euler(y0,a,b,h)
% Function call = [a,b]=euler(1,0,1,0.1);

N=(b-a)/h;
t=linspace(a,b,N+1);
w(1)=y0;
for i=1:N
    w(i+1)=w(i)+h*defunc(t(i),w(i));
end
[T,Y] = ODE45('defunc',t,y0);
plot(T,Y)
hold on
plot(t,w,'o')
hold off
error=max(abs(w-Y'))