How do I pass ode45 an odefun that takes two arguments?

后端 未结 2 1443

I have a use case as follows:

Inside F.m I have a function F that takes as its argument a 2 x 1 matrix x. F

2条回答
  •  伪装坚强ぢ
    2021-01-28 21:05

    I believe F in ode45(F,...) should be a function handle, i.e. @F. Also, you can have a look at this page of the MATLAB documentation for different methods to pass extra parameters to functions.

提交回复
热议问题