Technical data
2
Working with the Target Language
2-36
When calling MATLAB, these conversions are made:
When values are returned from MATLAB, they are converted as follows:
Other value types are not currently supported.
As an example, this statement uses the
FEVAL built-in function to call MATLAB
to take the sine of the input argument.
%assign result = FEVAL( "sin", 3.14159 )
Note: The FEVAL function is only available from the MATLAB command line
version of the Target Language Compiler. It is not available from the shell
version. Use the
STAND_ALONE predefined value to determine if FEVAL is
available to you.
TLC Type MATLAB Type
"Boolean"
or
"Number" or “Real”
Double Scalar
"String" Char Vector
"Vector"
If the vector is entirely strings, then Char Matrix. If
it is entirely numeric, then
Double Vector.
Otherwise, it is an error.
MATLAB Type TLC Type
Double Scalar "Number"
or "Real" depending on the value
Char Row Vector "String"
Char Matrix
or
Char Col Vector
"Vector" of "Strings"
Double Vector "Vector"
whose elements are "Number" or "Real"
depending on their values