|
|
|
| R2012a Documentation → Simulink Verification and Validation | |
Learn more about Simulink Verification and Validation |
|
| Contents | Index |
cvdg = cvsimref(topModelName)
cvdg = cvsimref(topModelName, cvtg)
[cvdg,t,x,y] = cvsimref(topModelName, cvtg)
[cvdg,t,x,y] = cvsimref(topModelName, cvtg, timespan,
options)
[cvdg1, cvdg2, ...] = cvsimref(topModelName, cvtg1,
cvtg2, ...)
cvdg = cvsimref(topModelName) simulates the top model and all referenced models in the hierarchy, collects model coverage data, and returns the results in the cv.cvdatagroup object cvdg. You do not have to enable model coverage reporting for any of the models in a model hierarchy to use the cvsimref command.
cvdg = cvsimref(topModelName, cvtg) simulates topModelName and collects model coverage data by executing the cv.cvtestgroup object cvtg. cvtg contains cvtest specifications for the top-level model and all the referenced models in the hierarchy. cvsimref returns the model coverage results in cvdg.
[cvdg,t,x,y] = cvsimref(topModelName, cvtg) returns the time vector t, matrix of state values x, and matrix of output values y from the simulation.
[cvdg,t,x,y] = cvsimref(topModelName, cvtg, timespan, options) overrides default simulation values with the values in timespan and options.
[cvdg1, cvdg2, ...] = cvsimref(topModelName, cvtg1, cvtg2, ...) executes multiple cv.cvtestgroup objects and returns the results in a set of cv.cvdatagroup objects.
cvdg |
cv.cvdatagroup object |
t |
The simulation time vector |
x |
The simulation state matrix consisting of continuous states followed by discrete states |
y |
The simulation output matrix. Each column contains the output of a root-level Outport block, in port number order. If any Outport block has a vector input, its output has the associated number of columns. |
Open and simulate the slvnvdemo_ratelim_harness model and its two subsystems:
topModel = 'slvnvdemo_cv_mutual_exclusion'; load_system(topModel); % Make sure coverage is off for this run for the entire tree set_param(topModel,'RecordCoverage','off'); set_param(topModel,'CovModelRefEnable','Off'); simObj = sim(topModel); % Normal data allData = cvsimref(topModel); % cvsimref data
cv.cvdatagroup | cv.cvtestgroup | cvsim | cvtest

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