Is there an estimate/ratio of many lines of C code is produced by MATLAB? Is there an estimate of time too?
4 vues (au cours des 30 derniers jours)
I want to generate 10,000 lines of matlab code into c code. The matlab code contains many different signal processing techniques and functions. Is there an estimate I can use to figure out how many lines of C code will be produced and how long will it take (ignoring testing, requirements etc). We are ideally using embedded coder to generate the code, aiming at execution timing and accuracy.
Any references or documentation would be great thanks.
Darshan Ramakant Bhat le 23 Juil 2021
The number of lines of code will vary depending on on the actual MATLAB function. Innoncent looking fft() can produce 100+ lines of C code :)
Please be aware that not all MATLAB functions are supported for C/C++ code generation. You can use coder.screener() to get a compatibility report :
Also below is the list of MATLAB functions supported for codegen as of latest release :
Hope this will be helpful.