Help with creating a function file

4 views (last 30 days)
Jyan
Jyan on 14 Dec 2014
How do you write a function with the name ”min_ode” and call it by ”[t,U]=min ode(f,I,ua,h)”. This should solve initial value problems. f is the function, I is the interval [a b], ua is a given number such as u(a)=ua and h is the length of steps.It should return t and U that is two vectors. Ex:
[t,U]=min ode(@fun,[1 4],2,1e-3)

Answers (0)

Categories

Find more on Physics in Help Center and File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!