Skip to content

Include a central math header file for math constants #95

Description

@alexander-novo

As mentioned in #85 it's a little inconvenient to have _USE_MATH_DEFINES littered everywhere we want to use a math constant in.

My suggestion would be to have a file with constants protected with a namespace and something like constexpr real_type PI = M_PI. We can def and undef _USE_MATH_DEFINES around it. In any case, we need one place where we define $\pi$ in the entire code. I would use a separate PR for that, though.

Originally posted by @pelesh in #85 (comment)

Metadata

Metadata

Labels

developmentFeatures/Tools related to development of GridKit, rather than use as a library.

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions