کد مقاله کد نشریه سال انتشار مقاله انگلیسی نسخه تمام متن
421515 684871 2015 6 صفحه PDF دانلود رایگان
عنوان انگلیسی مقاله ISI
Stupid is as Stupid Does: Taking the Square Root of the Square of a Floating-Point Number
ترجمه فارسی عنوان
احمقانه است که آیا احمقانه است: با توجه به میدان ریشه میدان یک نقطه شناور نقطه
موضوعات مرتبط
مهندسی و علوم پایه مهندسی کامپیوتر نظریه محاسباتی و ریاضیات
چکیده انگلیسی

Floating-point experts know that mathematical formulas may fail or give imprecise results when implemented in floating-point arithmetic. This article describes an example where, surprisingly, it is absolutely not the case. Indeed, using radix 2 and an unbounded exponent range, the computation of the square root of the square of a floating-point number a is exactly |a|. A consequence is the fact that the floating-point computation of is always in the interval [−1,1]. This removes the need for a test when calling an arccos or an arcsin on this value. For more guarantees, this property was formally checked using the Coq proof assistant and the Flocq library. The conclusion will give hints on what happens without assumptions and in other radices, where the behavior is very different.

ناشر
Database: Elsevier - ScienceDirect (ساینس دایرکت)
Journal: Electronic Notes in Theoretical Computer Science - Volume 317, 18 November 2015, Pages 27-32