Update math_functions.hpp