Newsletters

  • Contact sales

Tips and Tricks - Checking Your Model with Simulink Model Advisor

By Dan Lluch, MathWorks

  • Have you configured the best set of optimization options for your Simulink model?
  • Can you find all instances of unconnected blocks in your models?
  • How do you promote best practices, such as specifying the root level input port information?
  • How do you check that the model is ready for production code generation?

The Simulink Model Advisor enables you to check models for conditions and configuration settings to produce efficient models and generated code. You can run the Model Advisor at any time in the development cycle.

Checking with the Model Advisor lets you avoid problems that arise from incomplete models or poor modeling style and reminds you of the recommended settings. You can customize the checks using Simulink Verification and Validation 1.1.1. For instance, you can check that:

  • All subsystem blocks have a blue background color
  • All Sum blocks are square
  • All library-linked blocks come from your company’s custom libraries

Real-Time Workshop provides several Model Advisor example models. To view them, type modeladvisor(‘rtwdemo_advisor1’) at the MATLAB command line.

nn06_tips_fig1_w.gif

Click on image to see enlarged view.

You can use an M-based API to customize the full contents of the Model Advisor. To see a customization example, type slvnvdemo_mdladv at the MATLAB command prompt.

Using M scripting language and the Simulink API together with the expert advice of the Model Advisor, you can let your imagination and requirements guide you to more accurate, efficient simulations and well-constructed code. Please share your custom model checks with other MATLAB users worldwide by uploading them to MATLAB Central File Exchange.


Published 2006

Receive the latest MATLAB and Simulink technical articles.

Related Resources

Latest Blogs