DOI: 10.17587/prin.14.531-549
Calculating Correctly Rounded Exponential Function in Double-Precision Using Extended Double-Precision Arithmetic
A. N. Godunov, PhD, Head of Department, nkag@niisi.ras.ru, Federal State Institution Scientific Research Institute for System Analysis of the Russian Academy of Sciences (SRISA), Moscow, 117218, Russian Federation
Corresponding author: Aleksandr N. Godunov, PhD, Head of Department, Federal State Institution "Scientific Research Institute for System Analysis of the Russian Academy of Sciences" (SRISA), Moscow, 117218, Russian Federation, E-mail: nkag@niisi.ras.ru
Received on July 07, 2023
Accepted on August 28, 2023
The article presents an effective algorithm for calculating the correctly rounded exponent for any of the rounding modes specified by the IEEE 754 standard. The argument and the function value are double-precision numbers, but the algorithm itself uses extended double-precision arithmetic for calculations. At the argument reduction stage, we approximate the argument with numbers whose exponent value has a short mantissa, which makes calculations faster. The article gives a formal description of the algorithm and a proof of its correctness. The function has the shortest maximum execution time among the considered functions calculating correctly rounded exponent. The execution time slightly depends on the value of the argument, which may be important for critical applications.
Keywords: algorithm, exponent, correct rounding, double-precision
pp. 531–549
For citation:
Godunov A. N. Calculating Correctly Rounded Exponential Function in Double-Precision Using Extended Double-Precision Arithmetic, Programmnaya Ingeneria, 2023, vol. 14, no. 11, pp. 531—549. DOI: 10.17587/prin.14.531-549.
References:
- IEEE Std. 754-2008 — IEEE Standard for Floating-Point Arithmetic, IEEE Std., 2018.
- Godunov A. N. Algorithm for Calculating Correctly Rounded Exponential Function in Double Precision Using Double-Extended Arithmetic, Programming and Computer Software, 2022, vol. 48, no. 6, pp. 369—375. DOI: 10.1134/S0361768822060032.
- Godunov A. Algorithms for Calculating Correctly Rounded Exponential Function in Double-Precision Arithmetic, IEEE Transactions on Computers, 2020, vol. 69, no. 9, pp. 1388—1400. DOI: 10.1109/TC.2020.2972901.
- Muller J.-M. Elementary Functions: Algorithms and Implementation. Birkhauser, 2005, 286 p.
- Lefevre V., Muller J.-M. Worst cases for correct rounding of the elementary functions in double precision, Proceedings of the 15th IEEE Symposium on Computer Arithmetic, June 2001, pp. 111—118.
- de Dinechin F., Defour D., Lauter C. Fast correct rounding of elementary functions in double precision using double-extended arithmetic, INRIA, Research Report, RR-5137, 2004, available at: http://inria.hal.science/inria-00071446/document (date of access 03.07.2023).
- Lefevre V. Hardest-to-Round Cases — Part 2, Journees TaMaDi, Lyon, Oct. 2013, available at: http://www.vinc17.org/re-search/slides/tamadi2013-10.pdf (date of access 03.07.2023).
- Daramy-Loirat C., Defour D., de Dinechin F., Gallet M., Gast N., Lauter C. Q., Muller J.-M. CR-LIBM, a library of correctly rounded elementary functions in double-precision, LIP, Research Report, 2006, available at: https://hal-ens-lyon.archives-ouvertes.fr/ensl-01529804 (date of access 03.07.2023).
- Chevillard S., Jolde§ M., Lauter C. Sollya: An Environment for the Development of Numerical Codes, Mathematical Software — ICMS 2010, Heidelberg, Germany, Springer, September 2010, pp. 28—31.
- Lauter C. A correctly rounded implementation of the exponential function on the Intel Itanium architecture. INRIA, Research Report, RR-5024, 2003, available at: https://hal.inria.fr/ inria-00071560/documnt (date of access 03.07.2023).
- Gelfond A. O. Transcendental and Algebraic Numbers, Dover, NewYork, 1960, 208 p.
- Shilov G. E. Elementary Real and Complex Analysis, Dover Pubns, NewYork, 1996, 516 p.