boostorg / math

Boost.org math module
http://boost.org/libs/math
Boost Software License 1.0
312 stars 225 forks source link

add constants #980

Closed gpeterhoff closed 9 months ago

gpeterhoff commented 1 year ago

Can you please add 2 constants to boost::math::constants: root_five = sqrt(5) psi = 1 - phi These are needed e.g. for the calculation of Fibonacci numbers.

thx Gero

mborland commented 1 year ago

The value of psi is available as reciprocal_fibonacci. I can add root_five. We also have <boost/math/special_functions/fibonacci.hpp> if that's what you need.

gpeterhoff commented 1 year ago

I meant this psi = -0.618033988749...