10 Interval__compare(const Interval_t<T>&a,Interval_t<T> const&b)
12 if (a.left == b.left && a.right == b.right)
15 if (a.left <= b.left && a.right >= b.right)
18 if (a.left >= b.left && a.right <= b.right)
21 assert(false); // not comparable
26 const Real INFTY = HUGE;
30 Interval_t<T>::set_empty() {
37 Interval_t<T>::length() const {
38 assert(right >= left);
44 Interval_t<T>::unite(Interval_t<T> h)
53 smallest Interval which includes *this and #h#
58 Interval_t<T>::intersect(Interval_t<T> h)
60 #if defined (__GNUG__) && ! defined (__STRICT_ANSI__)
61 left = h.left >? left;
62 right = h.right <?right;
64 left = max(h.left, left);
65 right = min(h.right, right);
71 intersect(Interval_t<T> x, Interval_t<T> const &y)
79 Interval_t<T>::str() const
85 return s + left + "," + right +"]";
90 Interval_t<T>::elt_q(T r)
92 return r >= left && r <= right;