Replaced old std::fabs by more generic std::abs.