Yesterday, nobody contributed anything.  :-(
The official answer is: log2(-(2 * x + floor(-(2 * x))))