Converting Matlab Code to C/C++
You have to use Matlab Toolkit Coder.
Here is a Demo of MATLAB Coder, which converting Hello World .m script to C++ file.
This is a simple demo for the conversion of Matlab’s .m script file to a C++ file for your trading or target platform.
Please see the attached video and zip folder for further details.