How to solve this odearguments error when trying to use 'ODE45' command?
2 ビュー (過去 30 日間)
古いコメントを表示
I got an error:
Error in ode45 (line 115)
odearguments(FcnHandlesUsed, solver_name, ode, tspan, y0, options, varargin);
Error in solution (line 9)
[t,x] = ode45('func',[0 5],[0 0]);
My code is:
0 件のコメント
回答 (1 件)
Cris LaPierre
2021 年 3 月 21 日
Your syntax is wrong. You are passing in a character array to ode45, not a function.
Use @func instead of 'func'.
参考
カテゴリ
Help Center および File Exchange で Ordinary Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!