ABSTRACT
Algorithms in Computational Geometry and Computer Aided Design are often developed for the Real RAM model of computation, which assumes exactness of all the input arguments and operations. In practice, however, the exactness imposes tremendous limitations on the algorithms --- even the basic operations become uncomputable, or prohibitively slow. When the computations of interest are limited to determining the sign of polynomial expressions over floating point numbers, faster approaches are available. One can evaluate the polynomial in floating-point first, together with some estimate of the rounding error, and fall back to exact arithmetic only if this error is too big to determine the sign reliably. A particularly efficient variation on this approach has been used by Shewchuk in his robust implementations of Orient and InSphere geometric predicates. We extend Shewchuk's method to arbitrary polynomial expressions. The expressions are given as programs in a suitable source language featuring basic arithmetic operations of addition, subtraction, multiplication and squaring, which are to be perceived by the programmer as exact. The source language also allows for anonymous functions, and thus enables the common functional programming technique of staging. The method is presented formally through several judgments that govern the compilation of the source expression into target code, which is then easily transformed into SML or, in case of single-stage expressions, into C.
- M. 0. Benouamer, P. Jailon, D. Michelucci, and J. M. Moreau. A lazy exact arithmetic. In E. E. Swartzlander, NI. J. Irwin, and J. Jullien, editors, Proceedings of the 11th IEEE Symposium on Computer Arithmetic, pages 242-249, Windsor, Canada, June 1993. IEEE Computer Society Press, Los Alamitos, CA.Google ScholarCross Ref
- S. Fortune and C. J. V. Wyk. Efficient exact arithmetic for computational geometry. In Ninth Annual Symposium on Computational Geometry, pages 163-172. Association for Computing Machinery, May 1993. Google ScholarDigital Library
- S. Funke and K. Mehlhorn. LOOK - a lazy object-oriented kernel for geometric computation. In Proceedings of the 16th Symposium on Computational Geometry, pages 156-165. ACM. June 2000. Google ScholarDigital Library
- IEEE. IEEE standard for binary floating-point arithmetic. ACM SIGPLAN Notices, 22(2):925, Feb. 1985.Google Scholar
- K. Mehlhorn and S. Nher. LEDA: A Platform for Combznatonal and Geometric Computing. Cambridge University Press, 1999. Google ScholarDigital Library
- D. Michelucci and J. M. Moreau, Lazy arithmetic. IEEE Transactions on Computers, 46(9), September 1997. Google ScholarDigital Library
- A. Nanevski, G. Blelloch, and R. Harper. Automatic generation of staged geometric predicates. Technical Report CMU-CS-01-141, School of Computer Science, Carnegie Mellon University, June 2001.Google ScholarDigital Library
- D. M. Priest, On Properties of Floating Point Arithmetics: Numerical Stability and the Cost of Accurate Computations. PhD thesis, University of California at Berkeley, Berkeley, California, November 1992. Google ScholarDigital Library
- S. A. Seshia, C. E. Blelloch, and R. W. Harper. A performance comparison of interval arithmetic and error analysis in geometric predicates. Technical Report CMU-CS-00-172, School of Computer Science, Carnegie Mellon University, December 2000.Google Scholar
- J. R. Shewchuk. http://www. cs.cmu.edu/quake/triangle.btml.Google Scholar
- J. R. Shewchuk. Delaunay Refinement Mesh Generation. PhD thesis, Carnegie Mellon University, 1997. Google ScholarDigital Library
Index Terms
- Automatic generation of staged geometric predicates
Recommendations
Automatic generation of staged geometric predicates
Algorithms in Computational Geometry and Computer Aided Design are often developed for the Real RAM model of computation, which assumes exactness of all the input arguments and operations. In practice, however, the exactness imposes tremendous ...
Automatic Generation of Staged Geometric Predicates
Algorithms in Computational Geometry and Computer Aided Design are often developed for the Real RAM model of computation, which assumes exactness of all the input arguments and operations. In practice, however, the exactness imposes tremendous ...
Staged compilation
Traditional compilers compile and optimize files separately, making worst-case assumptions about the program context in which a file is to be linked. More aggressive compilation architectures perform cross-file interprocedural or whole-program analyses, ...
Comments