Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Embedded MATLAB functions in SIMULINK

Status
Not open for further replies.

epajuelo

Mechanical
Jul 27, 2010
3
0
0
ES
Hi everyone!!

I want to execute the following .m file from SIMULINK to create a block able to do a triple interpolation:
**************
function D=interpolateD(A,B,C)
%
%
load '-MAT' Avector % Loads Avector from a .MAT file
load '-MAT' Bvector
load '-MAT' Cvector
load '-MAT' Dvector
%
D=interp3(Avector,Bvector,Cvector,Dvector,A,B,C);
***************
I tred to used a embedded MATLAB function coverting "load" and "interp3" into extrinsic functions but it does not work. I think that the problem is that I need to load Avector,...,Dvector in the Worspace, but I can not. Can anyone help me??

I attached the MATLAB functions in case anyone could help me.

Thanks in advance!!!!
 
Status
Not open for further replies.
Back
Top