Yesterday, nobody contributed anything. :-(
The official answer is:
-floor(-ln(x + 1)) - 4