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