Guy on Simulink

Simulink & Model-Based Design

My top 5 new features in R2016a

Simulink R2016a has just been released and it includes a ton of new features and improvements. There is so much it is impossible to cover everything in just one blog post.

For this first blog post about R2016a, I decided to present my top five favorites.

Variant Source and Sink Blocks

For many years, it has been possible to control which blocks are active or not during a simulation by using Subsystem Variants. In R2016a, we introduced a completely new way to do it: Variant Source and Sink blocks. In this example, the grayed out blocks are inactive, controlled by a variable "a" in the base workspace.

Variant Source and Sink

Simulink Units

Units in Simulink allow you to specify the unit of measurement of signals entering and exiting subsystems, model blocks, Stateflow Charts, and MATLAB Function blocks. In the example below, subsystem A outputs meters per second, but subsystem B expects inches per second. If they were directly connected, this would generate a warning or error, recommending you insert a Unit Conversion block (as shown) to automatically take care of the conversion.

Simulink Units

Three-Way Model Merge

For those of you who are working in team on a project under source control, you will love this addition to the Simulink Report Generator: Simulink Three-Way Merge.

This feature shows you the conflicts between changes committed by another user, your changes, and the common ancestor. At the bottom, for each conflict, if the merge can be automated you can pick which one you want to end up in the target. For conflicts that cannot be automatically fixed, you can manually resolve them, mark as resolved, and then commit the target file.

Three-Way Merge

Simscape Run-Time Parameters

Simscape now supports run-time parameters. This means that you can create an executable from your model using Simulink Coder and change the values of parameters without regenerating the code.

Simscape Run-Time Parameters

Simulink Solver Profiler

This last one is very special to me. Over the past several years, I developed lots of tips and tricks to debug variable-step simulations. I have shared many of these on this blog.

For my work in MathWorks Technical Support, I need to understand why the solver takes the steps it does, so I wrote some MATLAB code to automate the gathering of the information I find useful when I analyze a model. After sharing some of these tools with my colleagues, someone suggested that my code would probably be of great help to you, our user community.

So over the past year, we worked at packaging it all in a Solver Profiler, which gathers information during a simulation and presents it in a way that will help you better understand your simulation's solver step behavior.

Solver Profiler

Now it's your turn

Go through the release notes, and leave us a comment below to tell us your favorite new feature!

|
  • print

Comments

To leave a comment, please click here to sign in to your MathWorks Account or create a new one.