Main Content

db_0110: Block parameters

Sub ID Recommendations

  • NA-MAAB — a

  • JMAAB — a

MATLAB Versions

All

Rule

Sub ID a

Block parameters shall not be used to describe:

  • Operation expressions

  • Data type conversion

  • Selection of rows or columns

  • MATLAB® commands

Custom Parameter

Not Applicable

Rationale

Sub ID a:

  • Operation expressions, data type conversion, or row or column selection become a magic number in generated code, which makes consistency between the model and code difficult to maintain. Adjusting parameters also becomes difficult.

  • Describing the calculation formula within the block decreases readability.

  • The result of executing a MATLAB command is reflected in the code, which makes consistency between the model and code difficult to maintain.

Verification

Model Advisor check: Check usage of tunable parameters in blocks (Simulink Check)

Last Changed

R2020a

See Also

Introduced in R2020a