Efficiency about Embedded Funtion in Simulink
이전 댓글 표시
I have tried to write some Matlab Code in Simulink using "Embedded Function" Block. However I found that the efficiency is quite low, comparing to the Embedded function having same code in Demos which represented in Low fps in display.
I replaced the Embedded function in Demo with mine, same source code, and this problem appears more obvious. So could someone explain this to me? What can I do to improve this other than using S-Function which makes source code unreadable. Thanks~
댓글 수: 4
Arnaud Miege
2011년 5월 19일
Can you post your code and if possible upload your model to a filesharing site?
Lofi
2011년 5월 24일
Arnaud Miege
2011년 5월 24일
I have tried replacing the block with an Embedded MATLAB Function and copying the code across. I can't see any difference in performance. It works well in both cases.
Lofi
2011년 5월 29일
답변 (1개)
Mark
2011년 5월 23일
0 개 추천
The best way to do this is probably to use Accelerator Mode, or Rapid Accelerator mode. There is some overhead that occurs during model update for these modes, but if the simulation is going to be repeated often enough, it can be worth it.
카테고리
도움말 센터 및 File Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!