What Is Dependency Analysis?
Every design, whether it is a Simulink®model or a project, requires a set of files and products to run successfully. Dependencies include data files, model references, linked libraries, MATLAB®andC/C++
code, Stateflow®charts, and requirements documents.
Dependency Analysis for Projects
You perform a dependency analysis to analyze project structure and discover required files and products. You can use the dependency graph to identify all required files and products, and perform an impact analysis.
On theProjecttab, click the down arrow to expand theToolsgallery. UnderApps, clickDependency Analyzer. For more details, seeRun a Dependency Analysis.
With the Dependency Analyzer, you can:
Find required products and add-ons. SeeFind Required Products and Add-Ons.
Check project dependencies and problems before sharing, packaging, or submitting your project to source control. See检查依赖项成果lts and Resolve Problems.
Perform an impact analysis to find the impact of changing particular files. SeePerform an Impact Analysis.
Export the dependency analysis results as workspace variables, or
.graphml
files, or send the files for custom task processing. Exporting the results enables further processing or archiving. SeeExport Dependency Analysis Results.
Tip
For an example showing how to perform file-level impact analysis to find and run the tests affected by modified files, seePerform Impact Analysis with a Project.
Dependency Analysis for Models
You perform a dependency analysis to examine models, subsystems, and libraries referenced directly or indirectly by the model. You can use the dependency graph to identify all required files and products.
On theModeling选项卡,最右边的Designsection, click the arrow. UnderDependencies, clickDependency Analyzer.
You can explore model dependencies using the model hierarchy or the model instances views. For more details, seeAnalyze Model Dependencies.
To package, share, or put your design under source control, create a project from your model. For more details, seeCreate a Project from a Model. Perform a project dependency analysis to explore the dependency graph using source control and project-specific views.