himl_0001: Usage of standardized MATLAB function headers
R2026bUse a standardized header to document the purpose and use of MATLAB functions
Usage: High-Integrity System Modeling
Guideline ID: himl_0001
Rules
| himl_0001: Usage of standardized MATLAB® function headers |
|---|
When using MATLAB functions, use a standardized header to provide information about the purpose and use of the function. Rationale A standardized header improves the readability and documentation of MATLAB functions. The header should provide a function description and usage information. Verification Check usage of standardized MATLAB function headers (Simulink Check) Example A typical standardized function header includes:
% FUNCTION NAME: % avg % % DESCRIPTION: % Compute the average of three inputs % % INPUT: % in1 - (double) Input one % in2 - (double) Input two % in3 - (double) Input three % % OUTPUT: % out - (double) Calculated average of the three inputs % % ASSUMPTIONS AND LIMITATIONS: % None % % REVISION HISTORY: % 05/02/2018 - mmyers % * Initial implementation % |
Industry Standards
DO-331, Section MB.6.3.4.e – Source code is traceable to low-level requirements
ISO 26262-6, Table 1 (1g) – Use of style guides