Reseña: Formal verification of programs computing the floating-point average

Se ha publicado un artículo de razonamiento formalizado en Coq sobre la aritmética titulado Formal verification of programs computing the floating-point average.

Sus autora es Silvie Boldo (del grupo Toccata (Formally Verified Programs, Certified Tools and Numerical Computations) en el LRI (Laboratoire de Recherche en Informatique) de la Universidad Paris-Sur).

Su resumen es

The most well-known feature of floating-point arithmetic is the limited precision, which creates round-off errors and inaccuracies. Another important issue is the limited range, which creates underflow and overflow, even if this topic is dismissed most of the time. This article shows a very simple example: the average of two floating-point numbers. As we want to take exceptional behaviors into account, we cannot use the naive formula (x+y)/2. Based on hints given by Sterbenz, we first write an accurate program and formally prove its properties. An interesting fact is that Sterbenz did not give this program, but only specified it. We prove this specification and include a new property: a precise certified error bound. We also present and formally prove a new algorithm that computes the correct rounding of the average of two floating-point numbers. It is more accurate than the previous one and is correct whatever the inputs.

El trabajo se presentará en el ICFEM 2015 (The 17th International Conference on Formal Engineering Methods).

El código de las correspondientes teorías en Coq se encuentra aquí.