adapt dispatch refactoring for boost_math namespace