Added C++ mmath functions.