mirror of
https://github.com/boostorg/math.git
synced 2026-01-19 04:22:09 +00:00
Correct use of M_PI - it's a Unix-ism.
This commit is contained in:
@@ -20,7 +20,7 @@ int main()
|
||||
|
||||
// The Archimedean spiral is given by r = a*theta. We have set a = 1.
|
||||
std::vector<std::array<double, 2>> spiral_points(500);
|
||||
double theta_max = M_PI;
|
||||
double theta_max = boost::math::constants::pi<double>();
|
||||
for (size_t i = 0; i < spiral_points.size(); ++i)
|
||||
{
|
||||
double theta = ((double) i/ (double) spiral_points.size())*theta_max;
|
||||
|
||||
Reference in New Issue
Block a user