Simulink use user-defined functions
3 次查看(过去 30 天)
显示 更早的评论
Hi,
is possible to call functions (user-defined functions) from Simulink blocks? For example
function y = myadd(u,v) %#codegen
y = sqrt(u+v);
end
I do not wanna rewrite functions to S-function or use some MATLAB functions. I want to take function and call them from Simulink block.
Thanks!
Vit
0 个评论
采纳的回答
Gayatri Menon
2018-6-27
Hi,
Could you check out MATLAB Function block? Please refer the below documentation for more details:
Hope this helps.
Thanks
Gayatri
0 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Simulink Functions 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!