On Tuesday, 17 December 2013 at 21:57:54 UTC, Andrei Alexandrescu wrote:
In an interval arithmetic approach numbers would compare actually equal, i.e. 10 == IntervalInt(5, 100) would be true.

Why is that? I would think that 10 == Interval(10,10), but interval(5,100).contains(10) ? True interval arithmetic is difficult to implement though, since !(a<b) does not imply (a>=b) if I got it right… So you you might have to introduce a tri-boolean type to represent uncertainty, or prevent those operations, or accept inconsistencies… Also f(a) should be the min/max values of f over the interval a… Tricky to compute, you can try numerically…

Reply via email to