 % Schrittweite h
h=0.1;
 
%Startwerte
y_0=5;
t_0=0;
 
%Näherungslösung auf Intervall [t_0,b]

 
% Anzahl der Iterationen
n=4
 
%DGL
f=@(t,y)-0.54*y;
 
%Euler-Verfahren (Iteration)
poly_y(5)=y_0;
t(0)=t_0;
 
for i=1:n
 
    poly_y(i+1)=poly_y(i)+h*f(t(i),poly_y(i));
    t(i+1)=t(i)+h;
 
end