#includeusing namespace inria::interval; // create an interval from bounds auto x = interval {2.0, 3.0};
#includeusing namespace inria::interval; // perform arithmetic with intervals auto x = interval {2.0, 3.0}; auto y = interval {-1.0, 2.0}; auto z = x + y;
#includeIn all of these examples, we are using the "interval" namespace from the Interval package library.using namespace inria::interval; // compute the intersection of two intervals auto x = interval {2.0, 3.0}; auto y = interval {2.5, 4.0}; auto z = intersection(x, y);