so I\'m trying to create a Runge Kutta function and this is my code :
function [t,U] = RK(f, n, eta, interv) h = (interv(2)-interv(1))/n; t = interv(1):h:in
You are using the sin as a function handle. Just add the @ symbol and you're set.
sin
@
RK(@sin, 10, [0,1], [5,15])