I have a question related to the Euler Method implementation. I have the following function:
I have written its main function code as:
function y = eulerfunction(func, t, y0)
y(:,k+1) = y(:,k) + h*func(t(k), y(:,k));
Now I am writing the remaining script.
y = eulerfunction(f, t, y0)
Can you please help me to convert that f(t,y) in MATLAB Format? Like what to write in these brackets '[ ]' according to the f (t,y) in above equation (1):
f = @(t, y) [ ];
Any help will be really appreciated! Thanks alot in advance.