How to make coder use #define macro for constant values
显示 更早的评论
I have a list of physical constants which are defined as constant properties in a classdef. For instance:
classdef uniConst
properties (Constant)
gravity=9.81;
pressure=1021;
end
end
When I use coder on a matlab script, coder inserts all of these constants as hard-coded values (such as 9.81 instead of gravity). Is there anyway to make coder use #define statements for such constant values so that the resultant code can be more human-readable?
回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Quantization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!