I want to use some functions defined by MPT3 (a toolbox designed for multi-parametric optimization and model predictive control) in my "Matlab function" block in Simulink. But this error occurs after I execute the Simulink:

The thing that I do not understand is, first, it recognized the "polytope" function inside the Matlab function script in the Simulink block shown below,

Second, if I run it in my main Matlab prompt, it will work.

As a result, I am confused as to why it is not working once these lines are in the Matlab function block in Simulink, thank you.