Solving a non-standard ODE
显示 更早的评论
I'm trying to solve an ODE like this: xdot = r(t)-x, where r(t) is a pre-calculated signal array of size 100. Let x(0) = 0. How do I set up the ODE? Thanks a lot.
回答(1 个)
Nicolas Schmit
2017-12-4
0 个投票
Create a interpolation of r(t), for example using interp1(), then use the interpolation routine in an ODE solver.
类别
在 帮助中心 和 File Exchange 中查找有关 Ordinary Differential Equations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!