Revert "Remove abs() functions"

This reverts commit fa47045641af018b27ad3475526d46e5a73a81e9.