added algorithm/math.h header reference (needed for compile under emscripten)