LEMA: towards a language for reliable arithmetic

  • Authors:
  • Vincent Lefèvre;Philippe Théveny;Florent de Dinechin;Claude-Pierre Jeannerod;Christophe Mouilleron;David Pfannholzer;Nathalie Revol

  • Affiliations:
  • UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon;UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon;UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon;UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon;UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon;UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon;UMR 5668 CNRS - ENS de Lyon - INRIA - UCBL, Université de Lyon

  • Venue:
  • ACM Communications in Computer Algebra
  • Year:
  • 2010

Quantified Score

Hi-index 0.00

Visualization

Abstract

Generating certified and efficient numerical codes requires information ranging from the mathematical level to the representation of numbers. Even though the mathematical semantics can be expressed using the content part of MathML, this language does not encompass the implementation on computers. Indeed various arithmetics may be involved, like floating-point or fixed-point, in fixed precision or arbitrary precision, and current tools do not handle all of these. Therefore we propose in this paper LEMA (Langage pour les Expressions Math'ematiques Annot'ees), a descriptive language based on MathML with additional expressiveness. LEMA will be used during the automatic generation of certified numerical codes. Such a generation process typically involves several steps, and LEMA would thus act as a glue to represent and store the information at every stage. First, we specify in the language the characteristics of the arithmetic as described in the IEEE 754 floatingpoint standard: formats, exceptions, rounding modes. This can be generalized to other arithmetics. Then, we use annotations to attach a specific arithmetic context to an expression tree. Finally, considering the evaluation of the expression in this context allows us to deduce several properties on the result, like being exact or being an exception. Other useful properties include numerical ranges and error bounds.