| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Simulink Verification and Validation |
| Contents | Index |
| Learn more about Simulink Verification and Validation |
| On this page… |
|---|
Synchronizing a Simulink Model to Create a Surrogate Module Customizing the Synchronization |
A surrogate module is a DOORS formal module that is a representation of a Simulink hierarchy. You use standard DOORS capabilities to navigate between the Simulink objects in the surrogate module and requirements in other modules.
Synchronization creates a DOORS surrogate module. The surrogate module facilitates navigation between the Simulink object and the requirements, as the following diagram illustrates.

When you synchronize a model for the first time, the DOORS software creates the surrogate module that contains a representation of the model, depending on your synchronization settings. (To customize the synchronization, seeCustomizing the Level of Detail in Synchronization.)
If you create new links or remove existing links, you can resynchronize the model. The new or updated surrogate module reflects any changes in the requirements links since the previous synchronization.
Synchronizing your Simulink model with a surrogate module offers the following advantages:
You can navigate from a requirement to a Simulink object without modifying the requirements modules.
You avoid cluttering your requirements modules with inserted navigation objects.
The DOORS database contains complete information about requirements links. You can review requirements links and verify traceability, even if the Simulink software is not running.
You can use DOORS reporting features to analyze requirements coverage.
You can separate the work of the systems engineers in charge of requirements tracking from the work of the Simulink model developers:
Systems engineers can establish requirements links to models without using the Simulink software.
Model developers can capture the requirements information and store it with the model.
You can resynchronize a model with a new surrogate module, updating any model changes, or specifying different synchronization options.
The first time that you synchronize your model with the DOORS software, the surrogate module is created in the DOORS database.
To synchronize the sf_car_doors model with the DOORS software:
Make sure that the DOORS software is running and that the Test Project is open.
In the Model Explorer, select the Synchronize Requirements
with DOORS tool
.
The DOORS settings dialog box opens.

For this exercise, accept all the default synchronization options. For more information about the options, seeCustomizing the Synchronization .
Click Synchronize to create and open a surrogate module for all DOORS requirements that have links to objects in the sf_car_doors model.

The surrogate module contains a DOORS object that is linked to the transmission subsystem; the only object in the model with a requirement. The red arrow indicates a link from the surrogate module object to the requirement.
Save the surrogate module.
| DOORS Settings Option | Description |
|---|---|
DOORS surrogate module path | Names the surrogate module using the Simulink model name. |
| Copy DOORS surrogate item links to Simulink objects | Copies all links between the surrogate module and the requirements modules into the Simulink model. |
Copy Simulink DOORS links to DOORS surrogate items | Copies all links between Simulink objects and requirements to the surrogate module. The surrogate module objects link to the same requirements as their Simulink objects. |
Additional synchronization objects | The default setting (None) specifies to synchronize only those Simulink objects that have linked requirements. For more information about the other synchronization options, seeCustomizing the Level of Detail in Synchronization. |
Save DOORS surrogate module after synchronization | Saves all changes to the surrogate module and changes the version of the surrogate module in the DOORS database. |
Save Simulink model after synchronization (recommended) | Saves all changes to the model. If you use a version control system, selecting this option changes the version of the model. |
To create a surrogate module that has more or less detail about the model hierarchy, resynchronize a model with the same or new surrogate module. In the DOORS settings dialog box, select the DOORS surrogate model module path option to name the different surrogate module in the DOORS database.
Specify a module with either a relative path (starting with ./) or a full path (starting with /). The software appends relative paths to the current DOORS project. Absolute paths must specify a project and a module name.
After you synchronize a model, the RMI automatically updates the DOORS surrogate model module path field with the actual full path and saves the unique module ID with the module.
If you select a new module path or if you have renamed the surrogate module, and you click Synchronize, the Requirements: Surrogate Module Mismatch dialog box opens.

Click Continue to create a new surrogate module with the new path or name.
You can customize the level of detail in a surrogate module so that the module reflects the full or partial Simulink model hierarchy.
In Synchronizing a Simulink Model to Create a Surrogate Module, you synchronized the model with the Additional synchronization objects option set to None. As a result, the surrogate module contains only Simulink objects that have requirement links. Additional synchronization options, described in this section, can increase the level of surrogate detail. However, increasing the level of surrogate detail can slow down synchronization.
The Additional synchronization objects option can have one of the following values. Each subsequent option adds additional Simulink objects to the surrogate module. You choose None to minimize the surrogate size or Complete to create a full representation of your model. The intermediate options provide finer level of detail. The Complete option adds all Simulink objects to the surrogate module, creating a one-to-one mapping of the Simulink model in the surrogate module.
| Drop-Down List Option | Description |
|---|---|
| None (Recommended) | Maps only Simulink objects that have requirements links and their parent objects to the surrogate module. |
| Minimal - Nonempty unmasked subsystems and Stateflow charts | Adds all nonempty Stateflow charts and unmasked Simulink subsystems to the surrogate module. |
| Moderate - Unmasked subsystems, Stateflow charts, and superstates | Adds Stateflow superstates to the surrogate module. |
| Average – Nontrivial Simulink blocks, Stateflow charts and states | Adds all Stateflow charts and states and Simulink blocks, except for trivial blocks such as ports, bus objects, and data-type converters, to the surrogate module. |
| Extensive - All unmasked blocks, subsystems, states and transitions | Adds all unmasked blocks, subsystems, states, and transitions to the surrogate module. |
| Complete - All blocks, subsystems, states and transitions | Copies all blocks, subsystems, states, and transitions to the surrogate module. |
To include all Simulink objects in the DOORS surrogate module:
Open the sf_car_doors model.
In the Model Editor, select Tools > Requirements > Synchronize with DOORS.
The DOORS settings dialog box opens.
To resynchronize with the same surrogate module, make sure that the DOORS surrogate module path option reads /Test Project/sf_car_doors, which is the surrogate module that you created in Synchronizing a Simulink Model to Create a Surrogate Module.
To update the surrogate module to include all objects in your model, from the drop-down list under Additional synchronization objects, select Complete - All blocks, subsystems, states and transitions.
You see the DOORS surrogate module for the sf_car_doors model. All Simulink objects and all Stateflow objects are now mapped in the surrogate module.

Save the surrogate module.
Notice the following about the surrogate module in the preceding graphic:
The name of the surrogate module is sf_car_doors, as you specified in the Requirements settings dialog box.
The left pane displays a node for each synchronized object in your model.
The right pane displays a DOORS object for each Simulink object.
Each Simulink object has a unique ID in the surrogate module. For example, the ID for the surrogate module object associated with the Mux block in the preceding figure is 11.
The Block Type column identifies each object as a particular block or a subsystem.
If you delete a previously synchronized object from your model and then resynchronize, the Block Deleted column reads true. Otherwise, it reads false.
If you delete any DOORS object, explicitly purge it to remove the object from the module. For information on how to purge an object, see the DOORS documentation.
In the previous exercises, before synchronization, you added the link from the transmission object in sf_car_doors to the Transmission Requirements requirement. In the surrogate module, the transmission object retains its ID (2), but the transmission object appears farther down in the module, in hierarchical order. The transmission object in the surrogate module has a red arrow indicating that it links to a Simulink object.
The RMI does not display a warning message if you change your model after synchronization. If you want the surrogate module to reflect changes to the Simulink model, resynchronize your model.
In the next example, you add a new block to the sf_car_doors model, and later delete it, resynchronizing after both steps:
In the sf_car_doors model, make a copy of the vehicle mph (yellow) & throttle % Scope block.

In the DOORS settings dialog box, leave the Additional synchronization objects option set to Complete - All blocks, subsystems, states, and transitions, and click Synchronize.
The software updates the surrogate module with the new block.

In the sf_car_doors model, delete the newly added Scope block and resynchronize.
The block that you delete appears at the bottom of the list of objects in the surrogate module, and its entry in the Block Deleted column reads True.

Right-click the object and select Delete to delete this entry from the surrogate module.
Save the sf_car_doors model.
The requirements in the formal module and the surrogate module are both in the DOORS database. You can review the requirements and the Simulink objects in the surrogate module without starting the Simulink software. When you synchronize your model, the DOORS software creates links between the surrogate module objects and the requirements in the DOORS database.
To navigate from the surrogate module transmission object to the requirement in the formal module:
In the surrogate module object for the transmission subsystem, right-click the right-facing red arrow.

Select the requirement name.
The My Requirements module opens, scrolled to the Transmission Requirements object.
To navigate from the requirement in the My Requirements module to the surrogate module:
In the Transmission Requirements object in the My Requirements module, right-click the left-facing orange arrow.

Select the object name.
The surrogate module for sf_car_doors opens, scrolled to the object associated with the transmission subsystem.
If you synchronize your model, you can navigate between Simulink objects and DOORS requirements using the surrogate module as an intermediary.
Navigating from a Simulink Object to a Requirement. To navigate from the transmission subsystem in the sf_car_doors model to the linked requirement in the My Requirements formal module:
In the sf_car_doors model, right-click the transmission subsystem and select Requirements > 1. "DOORS Surrogate Item".
The surrogate module opens, scrolled to the object associated with the transmission subsystem.
To display the individual requirement, in the surrogate module, right-click the right-facing red arrow and select the requirement.
The My Requirements module opens, scrolled to the Transmission Requirements requirement.
Navigating from a Requirement to the Model. To navigate from the Transmission Requirements object module to the transmission subsystem in the sf_car_doors model:
In the My Requirements module, in the Transmission Requirements object, right-click the left-facing orange arrow.
In the surrogate module, select the path to the linked object: /Test Project/sf_car_doors > 2. transmission.
The surrogate module opens, scrolled to the Transmission Requirements.
In the surrogate module, select the transmission object.
Select MATLAB > Select item.
The sf_car_doors model opens as follows:
For a Simulink object, the Model Editor opens with that block or subsystem, and all its parent blocks, highlighted.
For a Stateflow object, the diagram containing the selected object opens with the object highlighted.
![]() | Linking Simulink Objects to DOORS Requirements | Viewing Simulink Objects with Requirements | ![]() |

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |