// Booster.cpp : Defines the entry point for the console application. // #include #include #include #include int main() { using namespace boost::math::detail; for (double z = -10.0; z < 10.1; z += 0.1) { double result = sinpx(z); double result2 = z * sin(z * 3.14159265); bool error = abs(result - result2) > 0.001; auto errormsg = error ? "\t*** Error" : ""; std::cout << boost::format ("%1$4.1f * sinpx (%1$4.1f * PI) is %2$11.8f\tC++ sin() is %3$11.8f%4%\n") % z % result % result2 % errormsg; } }