Repository navigation
Validation as OpenModelica's library testing: omc's tube comparison in Julia - #14
Merged
Merged
Conversation
…n Julia compare_signal compared at 101 evenly spaced samples: a switch up to a sample interval late passed and a deviation between samples was not seen. It now compares OM.jl's values at every reference time against the band omc's diffSimulationResults builds (SimulationResultsCmpTubes.c, ported as tube_compare in src/tubes.jl, fused multiply-adds where clang contracts) with OpenModelica's library testing settings (relTol 3e-3, relTolDiffMinMax 3e-3, rangeDelta 1e-3): a model's signals in order sharing the reference's times as omc's one call does, over [StartTime, stopTime], a reference event not compared, a non-finite value failing. The experiment lists record StartTime, simulated from there (MSL ForceStrokeBehaviour: -4). SignalComparison and signals.json carry the band at the plotted samples and the compared/event/outside counts; the viewer draws the band and where OM.jl is furthest outside it. Tests check the port against omc's verdicts and band. Assisted-by: Claude Opus 5.5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Signals were compared at 101 evenly spaced samples with atol 0.01 + reltol 3e-3: a switch up to a sample interval late passed, a deviation between samples was not seen, and small-range signals were hardly checked.
compare_signalnow compares as OpenModelica's library testing does: omc'sdiffSimulationResultsband (SimulationResultsCmpTubes.c, v1.27.1) ported to Julia astube_compare(src/tubes.jl), with relTol 3e-3, relTolDiffMinMax 3e-3, rangeDelta 1e-3, at every reference time over [StartTime, stopTime]; a model's signals in order on shared reference times as omc's one call; reference events not compared; a non-finite value fails. Fused multiply-adds where clang contracts (TUBE_FUSED;fused = falsefor an unfused build).SignalComparison/ signals.json carry the band at the plotted samples and compared/events/outside counts; the viewer draws the band.🤖 Generated with Claude Code