필터 지우기
필터 지우기

Matlab function using fzero on function with griddedinterpolant

조회 수: 3 (최근 30일)
Louis
Louis 2014년 2월 18일
답변: Euan Russano 2016년 5월 23일
Hello, i work on simulink and i need to make null a function for each iteration. For this, i use a "matlab function" which uses the fzero function. Then i defined a matlab function de solve interpolate a 2D grid. I used interp2 and passed grid variable via simulink.signal. I need also to generate C code to execute it in real time. That works but as grid variable is huge, it is too slow.
I then saw griddedinterpolant which optimize memory and is cpu efficient. That is right when i test it via command line. But i cannot insert this function in a Matlab function ("only supported within the Matlab environment") in simulink and C coder generation seems not to exist.
How can i proceed ?

답변 (1개)

Euan Russano
Euan Russano 2016년 5월 23일
Use the 2-D Lookup Table in place of the griddedInterpolant object in simulink.

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by