Given a BitSlotMap (aka BitVector) a BinaryFractalRangeSearch attempts to identify the next or previous slot (aka bit) that is set to true. This is accomplished in O(log log s) time with O(1) space.
Identify bits in the direction your searching and mask them using a binary & operation with a bit mask (i.e. all ones 1111). Compare the bits interpreted as an integer to zero, if the integer is a zero then none of the bits are set to True.
Note if there are three or fewer bits you can also search bit by bit with a simple check if the specific bit is set.
If the result of Step 1 was not a zero, segment the bits into a right and left half and repeat searching the closer side first. Repeat Step 1 for each half until the closest bit set to 1 is found.
TODO add more to this paper, i.e. examples!
Was reidentified from 1.3.6.1.4.1.33097.0.1 to 1.3.6.1.4.1.33097.0.2.2 on 2025-12-13.
https://github.com/adligo/i_collections.adligo.org/blob/main/docs/src/drafts/ZigguratIndices.pdf
https://www.youtube.com/watch?v=hmReJCupbNU&t=3719s