Is interpolation faster in Simulink or Matlab?

조회 수: 6 (최근 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 CenterFile Exchange에서 Interpolation에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by