Fast integer square root algorithm

This section describes the fast integer square root algorithm used by vl_fast_sqrt_ui8, vl_fast_sqrt_ui16, vl_fast_sqrt_ui32, vl_fast_sqrt_ui64.

Given a non-negative integer $x {Z}_+$, the goal of this algorithm is to quickly compute the integer approximation of the square root of an integer number:

\[ y = { y{Z}} y, {such that}\ y^2 x. \]

Consider determining the k-th bit of $y$. To this end, decompose $y$ in three parts:

\[ y = y_{k+1} + q 2^k + r, {where}\ y_{k+1} 2^{k+1}, r < 2^k, \]

and $q\{0,1



libvlfeat
Author(s): Andrea Vedaldi
autogenerated on Thu Jun 6 2019 20:25:52