Force evaluation of timed always at candidate pivot points

This commit is contained in:
Gaudeval 2021-01-06 14:37:05 +00:00
parent 927d259fff
commit c53e490f80

View file

@ -135,6 +135,12 @@ def eval_mtl_g(phi, dt):
tmp = f(x) tmp = f(x)
assert b >= a assert b >= a
if b > a: if b > a:
# Force valuation at pivot points
if a < b < OO:
ts = fn.map(
lambda t: interp_all(tmp, t - b - a + dt, tmp.end),
tmp.times())
tmp = reduce(op.__or__, ts, tmp)[tmp.start:tmp.end]
return tmp.rolling(a, b).map(_min, tag=phi) return tmp.rolling(a, b).map(_min, tag=phi)
return tmp.retag({phi.arg: phi}) return tmp.retag({phi.arg: phi})