Products & Services Solutions Academia Support User Community Company

Learn more about Simulink Design Verifier   

sldvrun - Analyze model

Syntax

status = sldvrun
status = sldvrun(model)
status = sldvrun(block)
status = sldvrun(model, options)
[status, filenames] = sldvrun(model, options)
[status, filenames] = sldvrun(model, options, showUI, startCov)

Description

status = sldvrun analyzes the current model to generate test cases that provide model coverage or prove the model properties.

status = sldvrun(model) analyzes model to generate test cases that provide model coverage or prove the model properties

status = sldvrun(block) converts block into a new model and runs a design verification analysis on the new model.

status = sldvrun(model, options) analyzes model using the sldvoptions object options.

[status, filenames] = sldvrun(model, options) analyzes model and returns the file names the software created during the analysis.

[status, filenames] = sldvrun(model, options, showUI, startCov) opens the log window during the analysis if you set showUI to true. If you set showUI to false (the default), it directs output to the MATLAB command line.

Inputs

model

Handle to a Simulink model

Default: []

block

Handle to a block in a Simulink model

Default: []

options

sldvoptions object specifying the analysis options

Default: []

showUI

Logical value indicating where to display messages during the analysis

true to display messages in the log window
false (default) to display messages in the MATLAB command window

startCov

cvdata object specifying model coverage objects for the software to ignore

Default: []

Outputs

filenames

A structure whose fields list the file names that the Simulink Design Verifier software generates:

DataFile

MAT-file with raw input data

HarnessModel

Simulink harness model

SystemTestFile

SystemTest TEST-file

Report

HTML report with the results

ExtractedModel

Simulink model extracted from subsystem

BlockReplacementModel

Simulink model obtained after block replacements

status

-1

Analysis exceeded the maximum processing time

 0

Error

 1

Preprocessing completed normally

Examples

Set sldvoptions parameters, open the Cruise Control model, and analyze the model using the specified options:

opts = sldvoptions;
opts.Mode = 'TestGeneration';                  % Perform test-generation analysis
opts.ModelCoverageObjectives = 'MCDC';         % MCDC coverage
opts.SaveHarnessModel = 'off';                 % Don't save the harness as model file
opts.SaveReport = 'on';                        % Save the HTML report
open_system 'sldvdemo_cruise_control';
[ status, files ] = sldvrun('sldvdemo_cruise_control', opts);

Alternatives

In the Model Editor window, select either Tools > Design Verifier > Generate Tests or Tools > Design Verifier > Prove Properties to run a Simulink Design Verifier analysis option.

See Also

sldvcompat | sldvgencov | sldvoptions

Tutorials

  


Related Products & Applications

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