It seems like it would be relatively easy to implement a Sage class
for real intervals that represents finite unions of open, closed, half
open, and unbounded intervals and implements union() and
intersection() methods.
I did it. I attach my piece of code. This is only python, but it is
going
I think you want the RealIntervalField. For exampe:
sage: a = RIF(0,1)
sage: b = RIF(.5,pi)
sage: a.overlaps(b)
True
see:
http://www.sagemath.org/doc/reference/sage/rings/real_mpfi.html
-M. Hampton
On Dec 9, 8:16 am, Laurent Claessens moky.m...@gmail.com wrote:
Hi
I would like to work
I was going to suggest this too, but the RIF behaves differently than
you might naively expect intervals of real number to behave. For
example, union means convex hull:
sage: a = RIF(0,1)
sage: b = RIF(2,3)
sage: a.union(b).endpoints()
(0.000, 3.00)
Also, it seems from