Add missing #include <cmath>.