Is interpolation faster in Simulink or Matlab?

2 ビュー (過去 30 日間)
Marcus Jansson
Marcus Jansson 2017 年 5 月 2 日
回答済み: Jan 2017 年 6 月 20 日
I have a Simulink program that is compiled. The Simulink program contains a Matlab function where the physics are modelled. For each timestep an interpolation will take place, a length is interpolated to an angle. I have the opportunity to choose whether to implement the interpolation in Simulink or within the Matlab function. What is the best?
I know 'interp1' is slow and that there are faster functions like 'interp1q' or 'interp1qr' in Matlab but that have greater demands for the input.
  5 件のコメント
Marcus Jansson
Marcus Jansson 2017 年 6 月 19 日
Linear. I can use interp1q, but I wonder if Simulink is even faster with its interpolation features?

サインインしてコメントする。

採用された回答

Jan
Jan 2017 年 6 月 20 日
You can use the compiled Mex version FEX: ScaleTime.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeInterpolation についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by