|
I am trying to create an exe from a matlab function which doubles the
number you give it.
matlab function: test.m
function [output] = test (number)
%return double the input number
output = 2*number;
disp(output);
run matlab compiler at command line with:
mcc -mv test.m
with the resulting exe: test.exe
However when I run it at DOS prompt:
test 1
I am returned a value of 98. I thought that maybe this was some octal
description of the output, but 98 oct is not 2 decimal.
Some other results it returned:
C:\Documents and Settings\alex\Desktop\lighttrans\Frank Work
\test_dll_2>test 2
100
C:\Documents and Settings\alex\Desktop\lighttrans\Frank Work
\test_dll_2>test 4
104
C:\Documents and Settings\alex\Desktop\lighttrans\Frank Work
\test_dll_2>test 5
106
C:\Documents and Settings\alex\Desktop\lighttrans\Frank Work
\test_dll_2>test 10
98 96
Do you have any ideas what might have happened?
Also note that the exe worked properly as %errorlevel% was 0 after
running
Thanks
ALex
|