How does simulink use data stored in matlab as an array for each time iteration?
1 次查看(过去 30 天)
显示 更早的评论
So, I have a 141x4 array in matlab which corresponds to data and time (row vector of data for each time step. my time is basically 15 sec with 0.1 step size.)
now, I want to use my row vector of data 1x4 for each time step in simulink, but I don't know how to do that. Do I need to use interpoloation? Note that my simulink time step is different than matlab: 0.001.
Thank you.
0 个评论
采纳的回答
Paul
2023-2-26
编辑:Paul
2023-2-26
Hi M.I,
141 rows does not correspond to 15 sec with 0.1 step size. Perhaps it's just 14 seconds.
Whether or not you need to use interpolation is known only by you based on the requirements of your model. A From Workspace block or 2D Lookup Table block might be suitable.
2 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Sources 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!