32 #ifndef VSMC_MATH_CONSTANTS_HPP 33 #define VSMC_MATH_CONSTANTS_HPP 35 #define VSMC_DEFINE_MATH_CONSTANTS(name, val) \ 36 template <typename T> \ 37 inline constexpr T const_##name() noexcept \ 39 return static_cast<T>(val##l); \ 42 inline constexpr float const_##name<float>() noexcept \ 47 inline constexpr double const_##name<double>() noexcept \ 52 inline constexpr long double const_##name<long double>() noexcept \ 111 sqrt_pi_2, 2.506628274631000502415765284811045253007)
116 sqrt_pi_inv, 0.5641895835477562869480794515607725858441)
121 sqrt_pi_by2, 1.253314137315500251207882642405522626503)
126 sqrt_pi_by3, 1.023326707946488488479551624889264860707)
131 sqrt_pi_by4, 0.8862269254527580136490837416705725913988)
136 sqrt_pi_by6, 0.7236012545582676593630146272907957678721)
141 sqrt_pi_2by3, 1.447202509116535318726029254581591535744)
146 sqrt_pi_3by4, 1.534990061919732732719327437333897291061)
151 sqrt_pi_4by3, 2.046653415892976976959103249778529721415)
164 ln_pi_by2, 0.4515827052894548647261952298948821435718)
169 ln_pi_by3, 0.04611759718129048274818211443053300699980)
174 ln_pi_by4, -0.2415644752704904446910368915632944245037)
179 ln_pi_by6, -0.6470295833786548266690500070276435610757)
184 ln_pi_2by3, 0.7392647777412357921654142358887095750753)
189 ln_pi_3by4, 0.8570478133976192467042083453592312801438)
194 ln_pi_4by3, 1.432411958301181101582646357346886143151)
211 sqrt_e_inv, 0.6065306597126334236037995349911804534419)
232 sqrt_1by2, 0.7071067811865475244008443621048490392848)
237 sqrt_1by3, 0.5773502691896257645091487805019574556476)
242 sqrt_1by5, 0.4472135954999579392818347337462552470881)
247 sqrt_1by10, 0.3162277660168379331998893544432718533720)
272 ln_inv_3, 0.9102392266268373936142401657361070006126)
277 ln_inv_5, 0.6213349345596118107071993881805725841234)
282 ln_inv_10, 0.4342944819032518276511289189166050822944)
287 ln_ln_2, -0.3665129205816643270124391582326694694543)
291 #endif // VSMC_MATH_CONSTANTS_HPP
#define VSMC_DEFINE_MATH_CONSTANTS(name, val)