Three Ways to Analyze Requirements Traceability in MATLAB
Requirements traceability analysis is the process of tracking the connections between requirements and other aspects of the development lifecycle, including design and testing. It ensures that every requirement is accounted for, has a reason to exist, has been implemented correctly, and has been verified through testing.
Learn how to analyze requirements traceability in MATLAB® using the Document View, Traceability Matrix, and Traceability Diagram from Requirements Toolbox™.
Published: 17 Jun 2024
Requirements traceability analysis is the process of tracking the connections between requirements and other aspects of the development lifecycle, including design and testing. It ensures that every requirement is accounted for, has a reason to exist, has been implemented correctly, and has been verified through testing.
Hi - I'm Pat. I'm a product manager here at MathWorks. In this video, I will show you three ways to analyze requirements traceability in MATLAB using Requirements Toolbox.
Requirements Toolbox includes features such as the Document View, Traceability Matrix, and Traceability Diagram to help you understand the relationship between artifacts, find missing links, and analyze the impact of artifact changes.
Let's start with the Document View.
The Document View in the Requirements Editor allows you to view and navigate links for a requirement all in one place in a convenient format.
Let's say you want to see how a given requirement is Implemented and Verified.
Once you open a requirements set in the Requirements Editor, click Show Requirements > Document View to change to the Document View.
Here we can see the Verify and Implement links in the Links column. We can then navigate directly to the linked artifact.
The Document View is convenient for viewing and navigation, but what if you want a comprehensive understanding of traceability between artifacts?
This is where the Traceability Matrix helps.
The Traceability Matrix is your central hub for tracking and managing links. It provides a comprehensive view of how each requirement is connected to analysis artifacts in MATLAB, design elements in Simulink, and test cases.
To use the Traceability Matrix within the Requirements Editor, select 'Traceability Matrix' from the toolstrip. Here, you can add, remove, and manage links with ease, ensuring your project's traceability is always up to date.
The Traceability Matrix is useful when looking for issues like missing or inconsistent traceability.
But the Traceability Matrix is static: how would you understand the impact of changes to a design, test, or requirement?
This is where the Traceability Diagram can help.
The Traceability Diagram allows you to visualize the connections between requirements and other Model-Based Design items, making it easier to understand the relationships and dependencies at a glance.
In the diagram, items are nodes and links are edges. The item that you generate the diagram from is the starting node.
A traceability diagram displays all items linked to the starting node, including all upstream nodes and downstream nodes.
The impact direction is determined by the link type.
To create a Traceability Diagram within the Requirements Editor app, select 'Traceability Diagram' within the toolstrip, and then choose the elements you wish to include. The diagram automatically updates, providing a dynamic view of your project's traceability.
Before you dive in to using these three features, here are a couple considerations.
First up: link types.
A link can have any number of types. Most links will have a type of Implement or Verify, but you may find reason to use other types like Relate, Derive, Refine, and Confirm.
I advise you establish a set of clear criteria for your teams to follow when using a less common link type. Otherwise, you may find inconsistencies or, even worse: excessive linking. This can lead to challenges later on when trying to decipher complex relationships between artifacts.
Next up: link granularity.
Should you link to a model, subsystem/component, or block? Believe it or not, there is no right answer to this question.
In general, you should strike a balance between consistency and understandability. The level of granularity should be consistent, meaning requirements with similar levels of detail should be linked to similarly detailed model elements. And engineers should understand why a link was made between a given requirement and a given model element.
Setting clear linking standards with examples will help your team.
In summary, the Document View, Traceability Matrix, and Traceability Diagram, when paired with robust standards for use of link types and link granularity, can help teams analyze traceability and ensure requirements are properly considered at different levels of abstraction.
To learn more, visit the Requirements Toolbox page on mathworks.com