How to measure function execution time in simulink inside a matlab function block

조회 수: 4 (최근 30일)
How to measure function execution time in simulink inside a matlab function block?
Simulink restricts using tic and toc and I need to log the execution time of the quadprog() function inside the matlab function block.
I appreciate any suggestions.

채택된 답변

ludolfusexe
ludolfusexe 2024년 12월 11일
Using
t1 = tic();
t_elapsed = toc(t1);
instead of
tic();
t_elapsed = toc();
seems to solve the problem.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Simulink에 대해 자세히 알아보기

제품


릴리스

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by