Retrieve lookup table coverage information from cvdata
object
coverage = tableinfo(cvdo, object)
coverage = tableinfo(cvdo, object, ignore_descendants)
[coverage, exeCounts]
= tableinfo(cvdo, object)
[coverage, exeCounts, brkEquality]
= tableinfo(cvdo, object)
returns
lookup table coverage results from the coverage
= tableinfo(cvdo
, object
)cvdata
object cvdo
for
the model component object
.
returns
lookup table coverage results for coverage
= tableinfo(cvdo
, object
, ignore_descendants
)object
, depending
on the value of ignore_descendants
.
[
returns
lookup table coverage results and the execution count for each interpolation/extrapolation
interval in the lookup table block coverage
, exeCounts
]
= tableinfo(cvdo
, object
)object
.
[
returns
lookup table coverage results, the execution count for each interpolation/extrapolation
interval, and the execution counts for breakpoint equality.coverage
, exeCounts
, brkEquality
]
= tableinfo(cvdo
, object
)
|
| ||
|
Logical value specifying whether to ignore the coverage of descendant objects
| ||
|
Full path or handle to a lookup table block or a model containing a lookup table block. |
|
A cell array containing vectors that identify the number of times during simulation that the lookup table block input was equivalent to a breakpoint value. Each vector represents the breakpoints along a different lookup table dimension. | ||||
|
The value of
| ||||
|
An array having the same dimensionality as the lookup table block; its size has been extended to allow for the lookup table extrapolation intervals. |
Collect lookup table coverage for the slvnvdemo_cv_small_controller
model
and determine the percentage of interpolation/extrapolation intervals
coverage collected for the Gain Table block in the Gain subsystem:
mdl = 'slvnvdemo_cv_small_controller'; open_system(mdl) %Create test spec object testObj = cvtest(mdl) %Enable lookup table coverage testObj.settings.tableExec = 1; %Simulate the model data = cvsim(testObj) blk_handle = get_param([mdl, '/Gain/Gain Table'], 'Handle'); %Retrieve l/u table coverage cov = tableinfo(data, blk_handle) %Percent MCDC outcomes covered percent_cov = 100 * cov(1) / cov(2)
Use the coverage settings to collect lookup table coverage for a model:
Open the model.
In the Model Editor, select Model Settings on the Modeling tab.
On the Coverage pane of the Configuration Parameters dialog box, select Enable coverage analysis.
Under Coverage metrics, select Lookup Table.
Click OK to close the Configuration Parameters dialog box and save your changes.
Simulate the model by clicking the Run button and review the results.
complexityinfo
| conditioninfo
| cvsim
| decisioninfo
| getCoverageInfo
| mcdcinfo
| overflowsaturationinfo
| sigrangeinfo
| sigsizeinfo