You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
engine: a conveyor leak fraction given as a graphical function is ignored #865
A conveyor leak flow whose fraction is a graphical function (the flow has a <gf> and its <eqn> is the lookup input) simulates with the wrong fraction and no warning.
Conveyor expansion copies the flow's equation into a hidden fraction variable but not its graphical function, so the leak fraction becomes the raw lookup input instead of the table's output.
A per-element <gf> on an arrayed leak flow is carried over; only a whole-variable <gf> is lost.
Example
A leak flow with <leak/>, <eqn>TIME</eqn>, and a <gf> mapping 0..10 to 0..0.1: at TIME = 5 the leak fraction used is 5 (clamped to 1 on a linear-leak conveyor, so the whole zone drains), not the table's 0.05.
Why it matters
Silent wrong numbers.
Stella lets any flow be a graphical function, so this is a plausible way to write a time- or state-dependent leak fraction, but we have not seen it in a real model.
Fix
In leak_fraction_equation's flow-equation case, copy the flow's gf onto the synthesized fraction aux; this is a few lines plus a test.
When an explicit <leak>expr</leak> fraction is present the flow's <gf> does not apply to it; reject that combination rather than guess.
Cross-reference: #944 tracks the case item 2 above explicitly carves out -- a same-step direct read of a conveyor-driven leak flow. That rule (not just the PREVIOUS() variant) blocks the checked-in Stella fixture test/conveyors/covid19_severity.stmx, whose death rate aux sums four conveyor leak flows. A design that permits the direct read subsumes item 2, so the two are best resolved together.
changed the title [-]Conveyor engine: deferred edge-case limitations (GF leak fraction, PREVIOUS(driven_flow), JSON serialization)[/-][+]engine: a conveyor leak fraction given as a graphical function is ignored[/+]on Oct 12, 2026
Activity
bpowers commentedon Jul 11, 2026
Cross-reference: #944 tracks the case item 2 above explicitly carves out -- a same-step direct read of a conveyor-driven leak flow. That rule (not just the
PREVIOUS()variant) blocks the checked-in Stella fixturetest/conveyors/covid19_severity.stmx, whosedeath rateaux sums four conveyor leak flows. A design that permits the direct read subsumes item 2, so the two are best resolved together.[-]Conveyor engine: deferred edge-case limitations (GF leak fraction, PREVIOUS(driven_flow), JSON serialization)[/-][+]engine: a conveyor leak fraction given as a graphical function is ignored[/+]