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