Improving the Accuracy of the Fast Inverse Square Root by Modifying Newton–Raphson Corrections

Direct computation of functions using low-complexity algorithms can be applied both for hardware constraints and in systems where storage capacity is a challenge for processing a large volume of data. We present improved algorithms for fast calculation of the inverse square root function for single-...

Full description

Bibliographic Details
Main Authors: Cezary J. Walczyk, Leonid V. Moroz, Jan L. Cieśliński
Format: Article
Language:English
Published: MDPI AG 2021-01-01
Series:Entropy
Subjects:
Online Access:https://www.mdpi.com/1099-4300/23/1/86
Description
Summary:Direct computation of functions using low-complexity algorithms can be applied both for hardware constraints and in systems where storage capacity is a challenge for processing a large volume of data. We present improved algorithms for fast calculation of the inverse square root function for single-precision and double-precision floating-point numbers. Higher precision is also discussed. Our approach consists in minimizing maximal errors by finding optimal magic constants and modifying the Newton–Raphson coefficients. The obtained algorithms are much more accurate than the original fast inverse square root algorithm and have similar very low computational costs.
ISSN:1099-4300