StatisticsLogger block
Requirements.Internal.StatisticsLogger
ยท source
Writes the violation statistics of one requirement to the log file of the inner printViolations (used by Verify.ViolationStatistics)
Extends Modelica.Blocks.Icons.Block
Writes one Statistics line per requirement to the log file of the inner
PrintViolations, at the same instant the verdicts are
written, and orders the write before the summary through the sorting port (it adds 0 to the requirement count).
The instant is terminal(), or evaluationTime when useEvaluationTime is set in
PrintViolations. The line is written by
printStatisticsToLogFile with the name of
the outer ObservationID as the checked component,
requirementName, the statistics inputs, and minDuration and mergeGap, so that a reader of
the log can recompute the statistics; worst and tWorst are logged only if hasMargin.
The block is instantiated by Verify.ViolationStatistics
when logStatistics = true (which the requirement blocks set when computeStatistics = true);
all its inputs and parameters are bound there.
Parameters
| Name | Type | Description |
|---|---|---|
requirementName parameter | String | Full path name of the requirement the statistics belong to |
hasMargin parameter | Boolean | = true, if worst and tWorst are logged |
minDuration parameter | SI.Time | The statistics' minDuration, logged with them |
mergeGap parameter | SI.Time | The statistics' mergeGap, logged with them |
Inputs
| Name | Type | Description |
|---|---|---|
nViolations input | Integer | Number of violation episodes |
totalDuration input | SI.Time | Time violated, in total |
violatedFraction input | Real | Fraction of the applicable time violated |
longestDuration input | SI.Time | Duration of the longest violation episode |
tLongestStart input | SI.Time | Start of the longest violation episode |
worst input | Real | Worst margin (logged if hasMargin) |
tWorst input | SI.Time | Instant of the worst margin (logged if hasMargin) |