ViolationStatistics package

Requirements.Examples.Elementary.ViolationStatistics  ยท source

Icon of ViolationStatistics

Examples of Verify.ViolationStatistics: how often, how long and how badly a requirement was violated, asserted against closed-form values

Extends Modelica.Icons.ExamplesPackage

Examples of Verify.ViolationStatistics and of the statistics option of the requirement blocks. Sine, Episodes and Gating assert every output against closed-form values; RequirementLog shows the log and the summary; the Year* models run a year with hourly output, as an annual building simulation does, and measure what the two worst-margin methods cost.

Copyright © 2026 Model Based Innovation LLC. All rights reserved.

Contents

NameKindDescription
SinemodelA sine against a limit: four episodes of 10/3 s each, the worst margin -2 between two output points
EpisodesmodelFive violations against mergeGap and minDuration, and against a property that is applicable half of the time
GatingmodelA MinDuration check: its provisional margin while Undecided does not count, the worst decided margin is 0
RequirementLogmodelVerify.Requirement with computeStatistics: the statistics are logged beside the verdict and printed in the summary
PartialYearpartial modelA year of a room temperature against a comfort band, hourly output
YearRippleNoStatisticsmodelA year with a 10-minute ripple, no statistics: the reference for the cost of the statistics
YearRippleContinuousmodelA year with a 10-minute ripple, continuous method: one event per local extremum of the margin
YearRippleRatchetmodelA year with a 10-minute ripple, ratchet method: an event only at a new low