dist [MTL Home] Programmers Guide
  Contents | Index |  Search 


Category:intervals,math Component type:function
Prototype
template <class Tnum>
Tnum dist(const Tnum& r, const interval<Tnum>& x) ;
Description
Returns the difference between a number and the closest bound of an interval x. Distance is calculated using rounding to the nearest (the default FPU setting).
Definition
interval.cct
Preconditions
Complexity
Example
In intersection.h:

Notes
See also

[MTL Home] Copyright © 1998,1999 University of Notre Dame. All Rights Reserved.