MATLAB: How to run on iOS Matlab stand-alone application compiled under Windows

iosmcrstand-alone application

I have a set of Matlab scripts which I compile to Matlab stand-alone application (with *.exe). I use this program on several computers where Matlab MCR is installed. I need to use this application also on MAC with iOS. I know I can download a MCR for iOS, but how can I run *.exe under iOS?
Karolina

Best Answer

Mac do not run iOS . Mac run OS-X, or (more recently) MacOS . iOS runs on iPhone and iPad.
In any case, it is not possible to use MATLAB on MS Windows to create an executable that will run on OS-X or MacOS. The outputs that MATLAB Compiler produce are programs that can run on the same operating system that was used to compile with. Those programs unpack data structures and set up encryption keys and then pass control to MCR. Copying over to Mac and downloading an appropriate MCR is not sufficient, as the Mac cannot execute the Windows program that does the unpacking and setting up of encryption keys. Substituting the equivalent Mac unpacking program from a different run would not work, as that would not know the proper encryption keys.
It is possible to use MATLAB on MS Window to generate for an iPhone or iPAD target; see https://www.mathworks.com/hardware-support/ios-device-simulink.html . MATLAB Coder could be used in theory but it does not have any information about generating for iOS, so you would have to re-rewrite your code to be a Simulink model with iOS Target blocks -- essentially the same flow as generating for a system such as Raspberry Pi.
In short: copy the source over to Mac and run MATLAB Compiler there to generate a program that will run on Mac.