220 31536 <6bccd7e5-82ad-4c59-9f72-f7fb6639c0ca@isocpp.org> article
Path: news.gmane.org!.POSTED!not-for-mail
From: 3dw4rd@verizon.net
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Math constants
Date: Thu, 9 Mar 2017 14:44:32 -0800 (PST)
Lines: 1184
Approved: news@gmane.org
Message-ID: <6bccd7e5-82ad-4c59-9f72-f7fb6639c0ca@isocpp.org>
References: <ad05f2f2-609d-4fd3-90f7-d66c74e168b7@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: blaine.gmane.org
Mime-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_951_1972070828.1489099472968"
X-Trace: blaine.gmane.org 1489099477 11565 195.159.176.226 (9 Mar 2017 22:44:37 GMT)
X-Complaints-To: usenet@blaine.gmane.org
NNTP-Posting-Date: Thu, 9 Mar 2017 22:44:37 +0000 (UTC)
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBCS2FYFYXYEBBUNVQ7DAKGQEF2ATQTY@isocpp.org Thu Mar 09 23:44:30 2017
Return-path: <std-proposals+bncBCS2FYFYXYEBBUNVQ7DAKGQEF2ATQTY@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-io0-f198.google.com ([209.85.223.198])
	by blaine.gmane.org with esmtp (Exim 4.84_2)
	(envelope-from <std-proposals+bncBCS2FYFYXYEBBUNVQ7DAKGQEF2ATQTY@isocpp.org>)
	id 1cm6nM-0002AO-VP
	for gclcip-std-proposals@m.gmane.org; Thu, 09 Mar 2017 23:44:29 +0100
Original-Received: by mail-io0-f198.google.com with SMTP id 68sf49467294ioh.4
        for <gclcip-std-proposals@m.gmane.org>; Thu, 09 Mar 2017 14:44:35 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=isocpp-org.20150623.gappssmtp.com; s=20150623;
        h=date:from:to:message-id:in-reply-to:references:subject:mime-version
         :x-original-sender:reply-to:precedence:mailing-list:list-id
         :x-spam-checked-in-group:list-post:list-help:list-archive
         :list-subscribe:list-unsubscribe;
        bh=s2exN+3OXxpyKywZmRxQyurTiQWEe0fuoRO+qhJMbX0=;
        b=XdBTA8q1KqTn+wWqZvXjBzFEuYSHA7erRvYuFAb6g5IEHhNxLHMBs3JcJhKS6s2h8Z
         AvrbaIxSNmnYmxIcLqC/XnaGLBcVNdhjeXqbMbKfVbxoqsr8F08fINnGPmLqBz+J2Z5i
         LSvszxjYcW+qka+XWCctvt8hqogeEYpMv2oCX/A+ZC41/T8eb8fmTXjCQJUBEvKhuw88
         6wEtndOtPUj3Gq/vM52aehFakEtdlhfBjvkPdWautD0tAs/RgWPUhWm9XYxhn2kVsmzt
         ACerTqTOo4DEjgshDxzux5T34kITKzYMM8IdnO0St9LKVkBHukYlo+lW3YCHGPDkV49c
         5V5g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:date:from:to:message-id:in-reply-to:references
         :subject:mime-version:x-original-sender:reply-to:precedence
         :mailing-list:list-id:x-spam-checked-in-group:list-post:list-help
         :list-archive:list-subscribe:list-unsubscribe;
        bh=s2exN+3OXxpyKywZmRxQyurTiQWEe0fuoRO+qhJMbX0=;
        b=pODKNV2HJIygFQoVD8ytgd7d96kw1AeE9IFr6z7xlCtOfM1bvMW7A/1569OzoyZcRK
         cFhjkINX1gSPtuzinmZ3BivYmPVSbu51CCUYx4mIJlhKt3FGbjaYPxWsbbS0LurD/b2v
         2zXMcWExSpjnBd0pNiUHWSC5Fc1QSjwLxs0wgr/3terERXD39gxGtHRIq7qIbogURgEE
         l4S/0FghLOrFrMa2b3J/f0Fn3xCzCXFV2cThPN4c7kHIGRxjpU6NCgPyBYK9Jy4N+HTX
         rmuhplJXYBu6Xs/AnEmWTHL2UlaUDcCQFFdUqVYAmAfyyEtnF5aJvuXdx5u0R0zwDE6+
         HxiQ==
X-Gm-Message-State: AMke39k68xRY22nKEyz6DueaPZ4qpgDZRiT3mlRS/yzdHOC/+f3EneND2HsqQ1vlBdulRA==
X-Received: by 10.107.175.217 with SMTP id p86mr5063440ioo.101.1489099474629;
        Thu, 09 Mar 2017 14:44:34 -0800 (PST)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.157.54.152 with SMTP id h24ls7519407otc.30.gmail; Thu, 09 Mar
 2017 14:44:33 -0800 (PST)
X-Received: by 10.157.13.82 with SMTP id 76mr1914288oti.6.1489099473672;
        Thu, 09 Mar 2017 14:44:33 -0800 (PST)
In-Reply-To: <ad05f2f2-609d-4fd3-90f7-d66c74e168b7@isocpp.org>
X-Original-Sender: 3dw4rd@verizon.net
Precedence: list
Mailing-list: list std-proposals@isocpp.org; contact std-proposals+owners@isocpp.org
List-ID: <std-proposals.isocpp.org>
X-Google-Group-Id: 399137483710
List-Post: <https://groups.google.com/a/isocpp.org/group/std-proposals/post>, <mailto:std-proposals@isocpp.org>
List-Help: <https://support.google.com/a/isocpp.org/bin/topic.py?topic=25838>, <mailto:std-proposals+help@isocpp.org>
List-Archive: <https://groups.google.com/a/isocpp.org/group/std-proposals/>
List-Subscribe: <https://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>,
 <mailto:std-proposals+subscribe@isocpp.org>
List-Unsubscribe: <mailto:googlegroups-manage+399137483710+unsubscribe@googlegroups.com>,
 <https://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:31536
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/31536>

------=_Part_951_1972070828.1489099472968
Content-Type: multipart/alternative; 
	boundary="----=_Part_952_1398975516.1489099472971"

------=_Part_952_1398975516.1489099472971
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable



On Saturday, March 4, 2017 at 1:32:34 PM UTC-5, l...@compuserve.com wrote:
>
>
>
>
>
>
>
> *Hello everyone,        Many areas of software development where C++ is=
=20
> actively used involve mathematical calculations. The language inherited a=
=20
> sizable math function library from C, and now has its own numerics librar=
y=20
> that grows with every release. There is however a small but annoying=20
> omission: C++ standard headers do not include definitions of mathematical=
=20
> constants. To this math major it appears to be a very strange gap: wherev=
er=20
> common mathematical functions are used, the constants such as  =CF=80 or =
e=20
> appear quite frequently. Yes, it is not terribly difficult to define a=20
> constant, but from the C++ user's perspective this is as if they were=20
> served a dish at a restaurant but asked to bring their own salt.        =
=20
> True, many math.h headers include M_PI and other constant definitions. I=
=20
> see a few problems with this. First,the predecessor defines are notorious=
ly=20
> unsafe, and the C++ community has been trying to move away from them sinc=
e=20
> its very first days. Second, relying on them is not helpful for code's=20
> portability, and sometimes requires an additional macro definition such=
=20
> us _USE_MATH_DEFINES. Third, these definition are available only by the=
=20
> grace of the specific vendor implementation. For example, the code=20
> fragment#include <cstdlib>#define _USE_MATH_DEFINES#include <cmath>const=
=20
> double PI =3D M_PI;compiles in Microsoft Visual C++ 2015 but errors out i=
n=20
> Visual C++ 2017 RC because the M_PI is no longer available. I think a=20
> solution would be very uncontroversial and easy to implement.The header=
=20
> <cmath> should include as part of the std namespace the definitions of=20
> common math constants specified at long double precision. For example,=20
> depending on the length of long double, that portion of the header may lo=
ok=20
> as follows:namespace std { const long double PI =3D 3.1415926535897932384=
6;=20
> // pi const long double E =3D 2.71828182845904523536; // e const long dou=
ble=20
> LOG2E =3D 1.44269504088896340736; // log2(e) const long double LOG10E =3D=
=20
> 0.434294481903251827651; // log10(e) const long double LN2 =3D=20
> 0.693147180559945309417; // ln(2) const long double LN10 =3D=20
> 2.30258509299404568402; // ln(10) const long double SQRT2 =3D=20
> 1.41421356237309504880; // sqrt(2)}*
>


I had dabbled with this after variable templates were added.  I took that=
=20
route.
I think that this could devolve into endless bikeshed discussions and what=
=20
constants to include.=20

Design decisions:
1. variable templates.
2. In analogy with ud literals sub-directories place constants in constants=
=20
sub-directories.
3. I prefixed the math constants with m_ but c_ for constant may be better.

--------------------------------------------------------------------------
/*
  Variable template math constants for the standard library.
  Edward M. Smith-Rowland <esmith-rowland at alionscience dot com>
  2014-03-12

  We have variable templates in C++14.  In fact pi was offered as a use=20
case for that feature.
  We can do math constants right.  The constants in math.h are double=20
precision
  and promote computations unless you cast or erode long double precision.
  These M_* constants are actually POSIX compatibility - std C++ does not=
=20
mandate them.
  GCC has extension for long double versions suffixed by 'l'
  (but apparently no float versions with 'f' suffix).
  In any case these macros don't help with generic code.
  There are several bespoke versions of generic template math constants=20
around libstdc++
  using all the pre-variable-template techniques and with all the=20
annoyances outlined
  by the variable template proposal.

  'Grammar' + Bikeshedding
  I find 'm_' gives me flexibility in the 'grammar'.  We could do just=20
'_'.  Or 'c_'.
  Dividing numbers: 1_2 is 1/2, pi_2 is pi/2. Alt. _div_ seems wordy.
  Multiples of pi: Npi (2pi, 4pi).   For some reason nobody cares about=20
multiples of e
  but 2e that would be my proposal for 2*e<> if someone were to want.
  Function args preceded by '_' (unlike math.h!) make things easier to=20
read.  Alt. revert that to math.h.
  Lower case because these are not macros and because that's how we roll in=
=20
the std library.

  What to put in?
  Help people with intensive calculations.
  Division and sqrt are are more expensive than multiplication and integral=
=20
powers.
  Logs can take a while too.
  On the other hand, logs and square roots of integers appear in series=20
expansions of various
  functions.  Rather than having just a few, perhaps a substantial table=20
would be in order.

  This is a superset of math.h, <ext/cmath> from libstdc++ (with different=
=20
grammar).

  Prevent collision with an extra constants namespace after std.
  Add namespace versioning.
  Should I insert an experimental namespace between std and constants?

  Should we default to double?  Doing so might play nice with auto.

  Although it spoils the genericity of the template variable constants
  we could offer typedefs to the different precisions.  I'll hold off for=
=20
now.

  I made the constants and math_constants name spaces inline for the same=
=20
reason
  library literal operator namespaces are inline: using std to get the math=
=20
functions
  should give you access to the constants as well.

  This would go in some <cmath> or another.
 */

// Toy implementation:

#if __cplusplus <=3D 201103L
# include <bits/c++14_warning.h>
#else

namespace std
{
namespace experimental
{
inline namespace maths_v1
{
inline namespace constants
{
inline namespace math_constants
{
  /// Constant: @f$ \pi @f$ (see POSIX @c M_PI).
  template<typename _RealType>
    constexpr _RealType
    m_pi            =3D 3.1415'92653'58979'32384'62643'38327'95028'84195e+0=
L;

  /// Constant: @f$ \pi / 2 @f$ (see POSIX @c M_PI_2).
  template<typename _RealType>
    constexpr _RealType
    m_pi_2          =3D 1.5707'96326'79489'66192'31321'69163'97514'42098e+0=
L;

  /// Constant: @f$ \pi / 3 @f$.
  template<typename _RealType>
    constexpr _RealType
    m_pi_3          =3D 1.0471'97551'19659'77461'54214'46109'31676'28063e+0=
L;

  /// Constant: @f$ \pi / 4 @f$ (see POSIX @c M_PI_4).
  template<typename _RealType>
    constexpr _RealType
    m_pi_4          =3D 7.8539'81633'97448'30961'56608'45819'87572'10488e-1=
L;

  /// Constant: @f$ 4 \pi / 3 @f$.
  template<typename _RealType>
    constexpr _RealType
    m_4pi_3         =3D 4.1887'90204'78639'09846'16857'84437'26705'12253e+0=
L;

  /// Constant: @f$ 2 \pi @f$.
  template<typename _RealType>
    constexpr _RealType
    m_2pi           =3D 6.2831'85307'17958'64769'25286'76655'90057'68391e+0=
L;

  /// Constant: @f$ 4 \pi @f$.
  template<typename _RealType>
    constexpr _RealType
    m_4pi           =3D 1.2566'37061'43591'72953'85057'35331'18011'53678e+1=
L;

  /// Constant: degrees per radian @f$ 180 / \pi @f$.
  template<typename _RealType>
    constexpr _RealType
    m_deg_rad       =3D 5.7295'77951'30823'20876'79815'48141'05170'33237e+1=
L;

  /// Constant: radians per degree @f$ \pi / 180 @f$.
  template<typename _RealType>
    constexpr _RealType
    m_rad_deg       =3D 1.7453'29251'99432'95769'23690'76848'86127'13443e-2=
L;

  /// Constant: @f$ \sqrt{\pi / 2} @f$.
  template<typename _RealType>
    constexpr _RealType
    m_sqrt_pi_2     =3D 1.2533'14137'31550'02512'07882'64240'55226'26505e+0=
L;

  /// Constant: @f$ 1 / \pi @f$ (see POSIX @c M_1_PI).
  template<typename _RealType>
    constexpr _RealType
    m_1_pi          =3D 3.1830'98861'83790'67153'77675'26745'02872'40691e-1=
L;

  /// Constant: @f$ 2 / \pi @f$ (see POSIX @c M_2_PI).
  template<typename _RealType>
    constexpr _RealType
    m_2_pi          =3D 6.3661'97723'67581'34307'55350'53490'05744'81383e-1=
L;

  /// Constant: @f$ 1 / \sqrt{\pi} @f$.
  template<typename _RealType>
    constexpr _RealType
    m_1_sqrt_pi     =3D 5.6418'95835'47756'28694'80794'51560'77258'58438e-1=
L;

  /// Constant: @f$ \sqrt{\pi} @f$.
  template<typename _RealType>
    constexpr _RealType
    m_sqrt_pi       =3D 1.7724'53850'90551'60272'98167'48334'11451'82797e+0=
L;

  /// Constant: @f$ 2 / \sqrt{\pi} @f$ (see POSIX @c M_2_SQRTPI).
  template<typename _RealType>
    constexpr _RealType
    m_2_sqrt_pi     =3D 1.1283'79167'09551'25738'96158'90312'15451'71688e+0=
L;

  /// Constant: Euler's number @f$ e @f$ (see POSIX @c M_E).
  template<typename _RealType>
    constexpr _RealType
    m_e             =3D 2.7182'81828'45904'52353'60287'47135'26624'97759e+0=
L;

  /// Constant: @f$ 1 / e @f$.
  template<typename _RealType>
    constexpr _RealType
    m_1_e           =3D 3.6787'94411'71442'32159'55237'70161'46086'74462e-1=
L;

  /// Constant: @f$ \log_2(e) @f$ (see POSIX @c M_LOG2E).
  template<typename _RealType>
    constexpr _RealType
    m_log2_e        =3D 1.4426'95040'88896'34073'59924'68100'18921'37427e+0=
L;

  /// Constant: @f$ \log_2(10) @f$.
  template<typename _RealType>
    constexpr _RealType
    m_log2_10       =3D 3.3219'28094'88736'23478'70319'42948'93901'75867e+0=
L;

  /// Constant: @f$ \log_10(2) @f$.
  template<typename _RealType>
    constexpr _RealType
    m_log10_2       =3D 3.0102'99956'63981'19521'37388'94724'49302'67680e-1=
L;

  /// Constant: @f$ \log_10(e) @f$ (see POSIX @c M_LOG10E).
  template<typename _RealType>
    constexpr _RealType
    m_log10_e       =3D 4.3429'44819'03251'82765'11289'18916'60508'22940e-1=
L;

  /// Constant: @f$ \log_10(pi) @f$.
  template<typename _RealType>
    constexpr _RealType
    m_log10_pi      =3D 4.9714'98726'94133'85435'12682'88290'89887'36507e-1=
L;

  /// Constant: @f$ \ln(2) @f$ (see POSIX @c M_LN2).
  template<typename _RealType>
    constexpr _RealType
    m_ln_2          =3D 6.9314'71805'59945'30941'72321'21458'17656'80748e-1=
L;

  /// Constant: @f$ \ln(3) @f$.
  template<typename _RealType>
    constexpr _RealType
    m_ln_3          =3D 1.0986'12288'66810'96913'95245'23692'25257'04648e+0=
L;

  /// Constant: @f$ \ln(10)@f$ (see POSIX @c M_LN10).
  template<typename _RealType>
    constexpr _RealType
    m_ln_10         =3D 2.3025'85092'99404'56840'17991'45468'43642'07602e+0=
L;

  /// Constant: Euler-Mascheroni @f$ \gamma_E @f$.
  template<typename _RealType>
    constexpr _RealType
    m_gamma_e       =3D 5.7721'56649'01532'86060'65120'90082'40243'10432e-1=
L;

  /// Constant: Golden Ratio @f$ \phi =3D (1 + \sqrt{5})/2 @f$.
  template<typename _RealType>
    constexpr _RealType
    m_phi           =3D 1.6180'33988'74989'48482'04586'83436'56381'17720e+0=
L;

  /// Constant: @f$ \sqrt{2}@f$ (see POSIX @c M_SQRT2).
  template<typename _RealType>
    constexpr _RealType
    m_sqrt_2        =3D 1.4142'13562'37309'50488'01688'72420'96980'78569e+0=
L;

  /// Constant: @f$ \sqrt{3} @f$.
  template<typename _RealType>
    constexpr _RealType
    m_sqrt_3        =3D 1.7320'50807'56887'72935'27446'34150'58723'66945e+0=
L;

  /// Constant: @f$ \sqrt{5} @f$.
  template<typename _RealType>
    constexpr _RealType
    m_sqrt_5        =3D 2.2360'67977'49978'96964'09173'66873'12762'35440e+0=
L;

  /// Constant: @f$ \sqrt{7} @f$.
  template<typename _RealType>
    constexpr _RealType
    m_sqrt_7        =3D 2.6457'51311'06459'05905'01615'75363'92604'25706e+0=
L;

  /// Constant: @f$ 1 / \sqrt{2}@f$ (see POSIX @c M_SQRT1_2).
  template<typename _RealType>
    constexpr _RealType
    m_1_sqrt_2      =3D 7.0710'67811'86547'52440'08443'62104'84903'92845e-1=
L;

  /// Constant: Catalan's @f$ G =3D 1 - 1/9 + 1/25 - 1/49 + 1/81 - ... @f$.
  template<typename _RealType>
    constexpr _RealType
    m_catalan       =3D 9.1596'55941'77219'01505'46035'14932'38411'07741e-1=
L;

  /// Constant: @f$ \pi^2/6 @f$.
  template<typename _RealType>
    constexpr _RealType
    m_pi2_6         =3D 1.6449'34066'84822'64364'72415'16664'60251'89218e+0=
L;

} // inline namespace math_constants
} // inline namespace constants
} // inline namespace maths_v1
} // namespace experimental
} // namespace std

#endif // C++14



--------------------------------------------------------------------------

--=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp=
..org/d/msgid/std-proposals/6bccd7e5-82ad-4c59-9f72-f7fb6639c0ca%40isocpp.or=
g.

------=_Part_952_1398975516.1489099472971
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br><br>On Saturday, March 4, 2017 at 1:32:34 PM UTC-5, l.=
...@compuserve.com wrote:<blockquote class=3D"gmail_quote" style=3D"margin: =
0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><div d=
ir=3D"ltr"><div><b><div>Hello everyone,</div><div><br></div><div>=C2=A0 =C2=
=A0 =C2=A0 =C2=A0 Many areas of software development where C++ is actively =
used involve mathematical calculations. The language inherited a sizable ma=
th function library from C, and now has its own numerics library that grows=
 with every release. There is however a small but annoying omission: C++ st=
andard headers do not include definitions of mathematical constants. To thi=
s math major it appears to be a very strange gap: wherever common mathemati=
cal functions are used, the constants such as =C2=A0=CF=80 or e appear quit=
e frequently. Yes, it is not terribly difficult to define a constant, but f=
rom the C++ user&#39;s perspective this is as if they were served a dish at=
 a restaurant but asked to bring their own salt.=C2=A0</div><div><br></div>=
<div>=C2=A0 =C2=A0 =C2=A0 =C2=A0 True, many math.h headers include M_PI and=
 other constant definitions. I see a few problems with this. First,</div><d=
iv>the predecessor defines are notoriously unsafe, and the C++ community ha=
s been trying to move away from them since its very first days. Second, rel=
ying on them is not helpful for code&#39;s portability, and sometimes requi=
res an additional macro definition such us=C2=A0</div><div>_USE_MATH_DEFINE=
S. Third, these definition are available only by the grace of the specific =
vendor implementation. For example, the code fragment</div><div><br></div><=
div>#include &lt;cstdlib&gt;</div><div>#define _USE_MATH_DEFINES</div><div>=
#include &lt;cmath&gt;</div><div>const double PI =3D M_PI;</div><div><br></=
div><div>compiles in Microsoft Visual C++ 2015 but errors out in Visual C++=
 2017 RC because the M_PI is no longer available.</div><div><br></div><div>=
<span style=3D"white-space:pre">	</span>I think a solution would be very un=
controversial and easy to implement.The header &lt;cmath&gt; should include=
 as part of the std namespace the definitions of common math constants spec=
ified at long double precision. For example, depending on the length of lon=
g double, that portion of the header may look as follows:</div><div><br></d=
iv><div><div>namespace std {</div><div><span style=3D"white-space:pre">	</s=
pan>const long double PI =3D 3.14159265358979323846;<span style=3D"white-sp=
ace:pre">		</span>// pi</div><div><span style=3D"white-space:pre">	</span>c=
onst long double E =3D 2.71828182845904523536;<span style=3D"white-space:pr=
e">		</span>// e</div><div><span style=3D"white-space:pre">	</span>const lo=
ng double LOG2E =3D 1.44269504088896340736;<span style=3D"white-space:pre">=
	</span>// log2(e)</div><div><span style=3D"white-space:pre">	</span>const =
long double LOG10E =3D 0.434294481903251827651; // log10(e)</div><div><span=
 style=3D"white-space:pre">	</span>const long double LN2 =3D 0.693147180559=
945309417;<span style=3D"white-space:pre">	</span>// ln(2)</div><div><span =
style=3D"white-space:pre">	</span>const long double LN10 =3D 2.302585092994=
04568402;<span style=3D"white-space:pre">	</span>// ln(10)</div><div><span =
style=3D"white-space:pre">	</span>const long double SQRT2 =3D 1.41421356237=
309504880;<span style=3D"white-space:pre">	</span>// sqrt(2)</div><div>}</d=
iv></div></b></div></div></blockquote><div><br><br>I had dabbled with this =
after variable templates were added.=C2=A0 I took that route.<br>I think th=
at this could devolve into endless bikeshed discussions and what constants =
to include. <br><br>Design decisions:<br>1. variable templates.<br>2. In an=
alogy with ud literals sub-directories place constants in constants sub-dir=
ectories.<br>3. I prefixed the math constants with m_ but c_ for constant m=
ay be better.<br><br>------------------------------------------------------=
--------------------<br>/*<br>=C2=A0 Variable template math constants for t=
he standard library.<br>=C2=A0 Edward M. Smith-Rowland &lt;esmith-rowland a=
t alionscience dot com&gt;<br>=C2=A0 2014-03-12<br><br>=C2=A0 We have varia=
ble templates in C++14.=C2=A0 In fact pi was offered as a use case for that=
 feature.<br>=C2=A0 We can do math constants right.=C2=A0 The constants in =
math.h are double precision<br>=C2=A0 and promote computations unless you c=
ast or erode long double precision.<br>=C2=A0 These M_* constants are actua=
lly POSIX compatibility - std C++ does not mandate them.<br>=C2=A0 GCC has =
extension for long double versions suffixed by &#39;l&#39;<br>=C2=A0 (but a=
pparently no float versions with &#39;f&#39; suffix).<br>=C2=A0 In any case=
 these macros don&#39;t help with generic code.<br>=C2=A0 There are several=
 bespoke versions of generic template math constants around libstdc++<br>=
=C2=A0 using all the pre-variable-template techniques and with all the anno=
yances outlined<br>=C2=A0 by the variable template proposal.<br><br>=C2=A0 =
&#39;Grammar&#39; + Bikeshedding<br>=C2=A0 I find &#39;m_&#39; gives me fle=
xibility in the &#39;grammar&#39;.=C2=A0 We could do just &#39;_&#39;.=C2=
=A0 Or &#39;c_&#39;.<br>=C2=A0 Dividing numbers: 1_2 is 1/2, pi_2 is pi/2. =
Alt. _div_ seems wordy.<br>=C2=A0 Multiples of pi: Npi (2pi, 4pi).=C2=A0=C2=
=A0 For some reason nobody cares about multiples of e<br>=C2=A0 but 2e that=
 would be my proposal for 2*e&lt;&gt; if someone were to want.<br>=C2=A0 Fu=
nction args preceded by &#39;_&#39; (unlike math.h!) make things easier to =
read.=C2=A0 Alt. revert that to math.h.<br>=C2=A0 Lower case because these =
are not macros and because that&#39;s how we roll in the std library.<br><b=
r>=C2=A0 What to put in?<br>=C2=A0 Help people with intensive calculations.=
<br>=C2=A0 Division and sqrt are are more expensive than multiplication and=
 integral powers.<br>=C2=A0 Logs can take a while too.<br>=C2=A0 On the oth=
er hand, logs and square roots of integers appear in series expansions of v=
arious<br>=C2=A0 functions.=C2=A0 Rather than having just a few, perhaps a =
substantial table would be in order.<br><br>=C2=A0 This is a superset of ma=
th.h, &lt;ext/cmath&gt; from libstdc++ (with different grammar).<br><br>=C2=
=A0 Prevent collision with an extra constants namespace after std.<br>=C2=
=A0 Add namespace versioning.<br>=C2=A0 Should I insert an experimental nam=
espace between std and constants?<br><br>=C2=A0 Should we default to double=
?=C2=A0 Doing so might play nice with auto.<br><br>=C2=A0 Although it spoil=
s the genericity of the template variable constants<br>=C2=A0 we could offe=
r typedefs to the different precisions.=C2=A0 I&#39;ll hold off for now.<br=
><br>=C2=A0 I made the constants and math_constants name spaces inline for =
the same reason<br>=C2=A0 library literal operator namespaces are inline: u=
sing std to get the math functions<br>=C2=A0 should give you access to the =
constants as well.<br><br>=C2=A0 This would go in some &lt;cmath&gt; or ano=
ther.<br>=C2=A0*/<br><br><div style=3D"background-color: rgb(250, 250, 250)=
; border-color: rgb(187, 187, 187); border-style: solid; border-width: 1px;=
 overflow-wrap: break-word;" class=3D"prettyprint"><code class=3D"prettypri=
nt"><div class=3D"subprettyprint"><span style=3D"color: #800;" class=3D"sty=
led-by-prettify">// Toy implementation:</span><span style=3D"color: #000;" =
class=3D"styled-by-prettify"><br><br></span><span style=3D"color: #800;" cl=
ass=3D"styled-by-prettify">#if __cplusplus &lt;=3D 201103L</span><span styl=
e=3D"color: #000;" class=3D"styled-by-prettify"><br></span><span style=3D"c=
olor: #800;" class=3D"styled-by-prettify"># include &lt;bits/c++14_warning.=
h&gt;</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br><=
/span><span style=3D"color: #800;" class=3D"styled-by-prettify">#else</span=
><span style=3D"color: #000;" class=3D"styled-by-prettify"><br><br></span><=
span style=3D"color: #008;" class=3D"styled-by-prettify">namespace</span><s=
pan style=3D"color: #000;" class=3D"styled-by-prettify"> std<br></span><spa=
n style=3D"color: #660;" class=3D"styled-by-prettify">{</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"><br></span><span style=3D"co=
lor: #008;" class=3D"styled-by-prettify">namespace</span><span style=3D"col=
or: #000;" class=3D"styled-by-prettify"> experimental<br></span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">{</span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"><br></span><span style=3D"color: #008=
;" class=3D"styled-by-prettify">inline</span><span style=3D"color: #000;" c=
lass=3D"styled-by-prettify"> </span><span style=3D"color: #008;" class=3D"s=
tyled-by-prettify">namespace</span><span style=3D"color: #000;" class=3D"st=
yled-by-prettify"> maths_v1<br></span><span style=3D"color: #660;" class=3D=
"styled-by-prettify">{</span><span style=3D"color: #000;" class=3D"styled-b=
y-prettify"><br></span><span style=3D"color: #008;" class=3D"styled-by-pret=
tify">inline</span><span style=3D"color: #000;" class=3D"styled-by-prettify=
"> </span><span style=3D"color: #008;" class=3D"styled-by-prettify">namespa=
ce</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> constan=
ts<br></span><span style=3D"color: #660;" class=3D"styled-by-prettify">{</s=
pan><span style=3D"color: #000;" class=3D"styled-by-prettify"><br></span><s=
pan style=3D"color: #008;" class=3D"styled-by-prettify">inline</span><span =
style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"=
color: #008;" class=3D"styled-by-prettify">namespace</span><span style=3D"c=
olor: #000;" class=3D"styled-by-prettify"> math_constants<br></span><span s=
tyle=3D"color: #660;" class=3D"styled-by-prettify">{</span><span style=3D"c=
olor: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"=
color: #800;" class=3D"styled-by-prettify">/// Constant: @f$ \pi @f$ (see P=
OSIX @c M_PI).</span><span style=3D"color: #000;" class=3D"styled-by-pretti=
fy"><br>=C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by-prett=
ify">template</span><span style=3D"color: #660;" class=3D"styled-by-prettif=
y">&lt;</span><span style=3D"color: #008;" class=3D"styled-by-prettify">typ=
ename</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> _Rea=
lType</span><span style=3D"color: #660;" class=3D"styled-by-prettify">&gt;<=
/span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 =
=C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by-prettify">con=
stexpr</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> _Re=
alType<br>=C2=A0 =C2=A0 m_pi =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0</spa=
n><span style=3D"color: #660;" class=3D"styled-by-prettify">=3D</span><span=
 style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D=
"color: #066;" class=3D"styled-by-prettify">3.1415</span><span style=3D"col=
or: #080;" class=3D"styled-by-prettify">&#39;92653&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">58979</span><span style=3D"c=
olor: #080;" class=3D"styled-by-prettify">&#39;32384&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">62643</span><span style=3D"c=
olor: #080;" class=3D"styled-by-prettify">&#39;38327&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">95028</span><span style=3D"c=
olor: #080;" class=3D"styled-by-prettify">&#39;84195e+0L;<br><br>=C2=A0 ///=
 Constant: @f$ \pi / 2 @f$ (see POSIX @c M_PI_2).<br>=C2=A0 template&lt;typ=
ename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0 m=
_pi_2 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0=3D 1.5707&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">96326</span><span style=3D"c=
olor: #080;" class=3D"styled-by-prettify">&#39;79489&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">66192</span><span style=3D"c=
olor: #080;" class=3D"styled-by-prettify">&#39;31321&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">69163</span><span style=3D"c=
olor: #080;" class=3D"styled-by-prettify">&#39;97514&#39;</span><span style=
=3D"color: #066;" class=3D"styled-by-prettify">42098e+0L</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">;</span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span><span style=3D"=
color: #800;" class=3D"styled-by-prettify">/// Constant: @f$ \pi / 3 @f$.</=
span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 <=
/span><span style=3D"color: #008;" class=3D"styled-by-prettify">template</s=
pan><span style=3D"color: #660;" class=3D"styled-by-prettify">&lt;</span><s=
pan style=3D"color: #008;" class=3D"styled-by-prettify">typename</span><spa=
n style=3D"color: #000;" class=3D"styled-by-prettify"> _RealType</span><spa=
n style=3D"color: #660;" class=3D"styled-by-prettify">&gt;</span><span styl=
e=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><s=
pan style=3D"color: #008;" class=3D"styled-by-prettify">constexpr</span><sp=
an style=3D"color: #000;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0=
 =C2=A0 m_pi_3 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0</span><span style=3D"colo=
r: #660;" class=3D"styled-by-prettify">=3D</span><span style=3D"color: #000=
;" class=3D"styled-by-prettify"> </span><span style=3D"color: #066;" class=
=3D"styled-by-prettify">1.0471</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;97551&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">19659</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;77461&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">54214</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;46109&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">31676</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;28063e+0L;<br><br>=C2=A0 /// Constant: @f$ \pi / 4=
 @f$ (see POSIX @c M_PI_4).<br>=C2=A0 template&lt;typename _RealType&gt;<br=
>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0 m_pi_4 =C2=A0 =C2=A0 =
=C2=A0 =C2=A0 =C2=A0=3D 7.8539&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">81633</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;97448&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">30961</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;56608&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">45819</span><span style=3D"color: #080;" class=3D"=
styled-by-prettify">&#39;87572&#39;</span><span style=3D"color: #066;" clas=
s=3D"styled-by-prettify">10488e-1L</span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">;</span><span style=3D"color: #000;" class=3D"style=
d-by-prettify"><br><br>=C2=A0 </span><span style=3D"color: #800;" class=3D"=
styled-by-prettify">/// Constant: @f$ 4 \pi / 3 @f$.</span><span style=3D"c=
olor: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"=
color: #008;" class=3D"styled-by-prettify">template</span><span style=3D"co=
lor: #660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"color: #=
008;" class=3D"styled-by-prettify">typename</span><span style=3D"color: #00=
0;" class=3D"styled-by-prettify"> _RealType</span><span style=3D"color: #66=
0;" class=3D"styled-by-prettify">&gt;</span><span style=3D"color: #000;" cl=
ass=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #=
008;" class=3D"styled-by-prettify">constexpr</span><span style=3D"color: #0=
00;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_4pi_3 =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 </span><span style=3D"color: #660;" class=3D"style=
d-by-prettify">=3D</span><span style=3D"color: #000;" class=3D"styled-by-pr=
ettify"> </span><span style=3D"color: #066;" class=3D"styled-by-prettify">4=
..1887</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;=
90204&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">=
78639</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;=
09846&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">=
16857</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;=
84437&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">=
26705</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;=
12253e+0L;<br><br>=C2=A0 /// Constant: @f$ 2 \pi @f$.<br>=C2=A0 template&lt=
;typename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=
=A0 m_2pi =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =3D 6.2831&#39;</span><span st=
yle=3D"color: #066;" class=3D"styled-by-prettify">85307</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;17958&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">64769</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;25286&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">76655</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;90057&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">68391e+0L</span><span s=
tyle=3D"color: #660;" class=3D"styled-by-prettify">;</span><span style=3D"c=
olor: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span><span style=
=3D"color: #800;" class=3D"styled-by-prettify">/// Constant: @f$ 4 \pi @f$.=
</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0=
 </span><span style=3D"color: #008;" class=3D"styled-by-prettify">template<=
/span><span style=3D"color: #660;" class=3D"styled-by-prettify">&lt;</span>=
<span style=3D"color: #008;" class=3D"styled-by-prettify">typename</span><s=
pan style=3D"color: #000;" class=3D"styled-by-prettify"> _RealType</span><s=
pan style=3D"color: #660;" class=3D"styled-by-prettify">&gt;</span><span st=
yle=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span>=
<span style=3D"color: #008;" class=3D"styled-by-prettify">constexpr</span><=
span style=3D"color: #000;" class=3D"styled-by-prettify"> _RealType<br>=C2=
=A0 =C2=A0 m_4pi =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 </span><span style=3D"c=
olor: #660;" class=3D"styled-by-prettify">=3D</span><span style=3D"color: #=
000;" class=3D"styled-by-prettify"> </span><span style=3D"color: #066;" cla=
ss=3D"styled-by-prettify">1.2566</span><span style=3D"color: #080;" class=
=3D"styled-by-prettify">&#39;37061&#39;</span><span style=3D"color: #066;" =
class=3D"styled-by-prettify">43591</span><span style=3D"color: #080;" class=
=3D"styled-by-prettify">&#39;72953&#39;</span><span style=3D"color: #066;" =
class=3D"styled-by-prettify">85057</span><span style=3D"color: #080;" class=
=3D"styled-by-prettify">&#39;35331&#39;</span><span style=3D"color: #066;" =
class=3D"styled-by-prettify">18011</span><span style=3D"color: #080;" class=
=3D"styled-by-prettify">&#39;53678e+1L;<br><br>=C2=A0 /// Constant: degrees=
 per radian @f$ 180 / \pi @f$.<br>=C2=A0 template&lt;typename _RealType&gt;=
<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0 m_deg_rad =C2=A0 =C2=
=A0 =C2=A0 =3D 5.7295&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">77951</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;30823&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">20876</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;79815&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">48141</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;05170&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">33237e+1L</span><span style=3D"color: #660;" class=3D"style=
d-by-prettify">;</span><span style=3D"color: #000;" class=3D"styled-by-pret=
tify"><br><br>=C2=A0 </span><span style=3D"color: #800;" class=3D"styled-by=
-prettify">/// Constant: radians per degree @f$ \pi / 180 @f$.</span><span =
style=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span=
 style=3D"color: #008;" class=3D"styled-by-prettify">template</span><span s=
tyle=3D"color: #660;" class=3D"styled-by-prettify">&lt;</span><span style=
=3D"color: #008;" class=3D"styled-by-prettify">typename</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> _RealType</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">&gt;</span><span style=3D"co=
lor: #000;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span sty=
le=3D"color: #008;" class=3D"styled-by-prettify">constexpr</span><span styl=
e=3D"color: #000;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0=
 m_rad_deg =C2=A0 =C2=A0 =C2=A0 </span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">=3D</span><span style=3D"color: #000;" class=3D"sty=
led-by-prettify"> </span><span style=3D"color: #066;" class=3D"styled-by-pr=
ettify">1.7453</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;29251&#39;</span><span style=3D"color: #066;" class=3D"styled-by-p=
rettify">99432</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;95769&#39;</span><span style=3D"color: #066;" class=3D"styled-by-p=
rettify">23690</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;76848&#39;</span><span style=3D"color: #066;" class=3D"styled-by-p=
rettify">86127</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;13443e-2L;<br><br>=C2=A0 /// Constant: @f$ \sqrt{\pi / 2} @f$.<br>=
=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _RealT=
ype<br>=C2=A0 =C2=A0 m_sqrt_pi_2 =C2=A0 =C2=A0 =3D 1.2533&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">14137</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;31550&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">02512</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;07882&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">64240</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;55226&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">26505e+0L</span><span s=
tyle=3D"color: #660;" class=3D"styled-by-prettify">;</span><span style=3D"c=
olor: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span><span style=
=3D"color: #800;" class=3D"styled-by-prettify">/// Constant: @f$ 1 / \pi @f=
$ (see POSIX @c M_1_PI).</span><span style=3D"color: #000;" class=3D"styled=
-by-prettify"><br>=C2=A0 </span><span style=3D"color: #008;" class=3D"style=
d-by-prettify">template</span><span style=3D"color: #660;" class=3D"styled-=
by-prettify">&lt;</span><span style=3D"color: #008;" class=3D"styled-by-pre=
ttify">typename</span><span style=3D"color: #000;" class=3D"styled-by-prett=
ify"> _RealType</span><span style=3D"color: #660;" class=3D"styled-by-prett=
ify">&gt;</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><=
br>=C2=A0 =C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by-pre=
ttify">constexpr</span><span style=3D"color: #000;" class=3D"styled-by-pret=
tify"> _RealType<br>=C2=A0 =C2=A0 m_1_pi =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0=
</span><span style=3D"color: #660;" class=3D"styled-by-prettify">=3D</span>=
<span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span sty=
le=3D"color: #066;" class=3D"styled-by-prettify">3.1830</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;98861&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">83790</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;67153&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">77675</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;26745&#39;</span><span =
style=3D"color: #066;" class=3D"styled-by-prettify">02872</span><span style=
=3D"color: #080;" class=3D"styled-by-prettify">&#39;40691e-1L;<br><br>=C2=
=A0 /// Constant: @f$ 2 / \pi @f$ (see POSIX @c M_2_PI).<br>=C2=A0 template=
&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =
=C2=A0 m_2_pi =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0=3D 6.3661&#39;</span><span=
 style=3D"color: #066;" class=3D"styled-by-prettify">97723</span><span styl=
e=3D"color: #080;" class=3D"styled-by-prettify">&#39;67581&#39;</span><span=
 style=3D"color: #066;" class=3D"styled-by-prettify">34307</span><span styl=
e=3D"color: #080;" class=3D"styled-by-prettify">&#39;55350&#39;</span><span=
 style=3D"color: #066;" class=3D"styled-by-prettify">53490</span><span styl=
e=3D"color: #080;" class=3D"styled-by-prettify">&#39;05744&#39;</span><span=
 style=3D"color: #066;" class=3D"styled-by-prettify">81383e-1L</span><span =
style=3D"color: #660;" class=3D"styled-by-prettify">;</span><span style=3D"=
color: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span><span styl=
e=3D"color: #800;" class=3D"styled-by-prettify">/// Constant: @f$ 1 / \sqrt=
{\pi} @f$.</span><span style=3D"color: #000;" class=3D"styled-by-prettify">=
<br>=C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by-prettify"=
>template</span><span style=3D"color: #660;" class=3D"styled-by-prettify">&=
lt;</span><span style=3D"color: #008;" class=3D"styled-by-prettify">typenam=
e</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> _RealTyp=
e</span><span style=3D"color: #660;" class=3D"styled-by-prettify">&gt;</spa=
n><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=
=A0 </span><span style=3D"color: #008;" class=3D"styled-by-prettify">conste=
xpr</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> _RealT=
ype<br>=C2=A0 =C2=A0 m_1_sqrt_pi =C2=A0 =C2=A0 </span><span style=3D"color:=
 #660;" class=3D"styled-by-prettify">=3D</span><span style=3D"color: #000;"=
 class=3D"styled-by-prettify"> </span><span style=3D"color: #066;" class=3D=
"styled-by-prettify">5.6418</span><span style=3D"color: #080;" class=3D"sty=
led-by-prettify">&#39;95835&#39;</span><span style=3D"color: #066;" class=
=3D"styled-by-prettify">47756</span><span style=3D"color: #080;" class=3D"s=
tyled-by-prettify">&#39;28694&#39;</span><span style=3D"color: #066;" class=
=3D"styled-by-prettify">80794</span><span style=3D"color: #080;" class=3D"s=
tyled-by-prettify">&#39;51560&#39;</span><span style=3D"color: #066;" class=
=3D"styled-by-prettify">77258</span><span style=3D"color: #080;" class=3D"s=
tyled-by-prettify">&#39;58438e-1L;<br><br>=C2=A0 /// Constant: @f$ \sqrt{\p=
i} @f$.<br>=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 const=
expr _RealType<br>=C2=A0 =C2=A0 m_sqrt_pi =C2=A0 =C2=A0 =C2=A0 =3D 1.7724&#=
39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">53850</=
span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;90551&#=
39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">60272</=
span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;98167&#=
39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">48334</=
span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;11451&#=
39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">82797e+=
0L</span><span style=3D"color: #660;" class=3D"styled-by-prettify">;</span>=
<span style=3D"color: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </=
span><span style=3D"color: #800;" class=3D"styled-by-prettify">/// Constant=
: @f$ 2 / \sqrt{\pi} @f$ (see POSIX @c M_2_SQRTPI).</span><span style=3D"co=
lor: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"c=
olor: #008;" class=3D"styled-by-prettify">template</span><span style=3D"col=
or: #660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"color: #0=
08;" class=3D"styled-by-prettify">typename</span><span style=3D"color: #000=
;" class=3D"styled-by-prettify"> _RealType</span><span style=3D"color: #660=
;" class=3D"styled-by-prettify">&gt;</span><span style=3D"color: #000;" cla=
ss=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #0=
08;" class=3D"styled-by-prettify">constexpr</span><span style=3D"color: #00=
0;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_2_sqrt_pi =
=C2=A0 =C2=A0 </span><span style=3D"color: #660;" class=3D"styled-by-pretti=
fy">=3D</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">1.1283</span=
><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;79167&#39;<=
/span><span style=3D"color: #066;" class=3D"styled-by-prettify">09551</span=
><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;25738&#39;<=
/span><span style=3D"color: #066;" class=3D"styled-by-prettify">96158</span=
><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;90312&#39;<=
/span><span style=3D"color: #066;" class=3D"styled-by-prettify">15451</span=
><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;71688e+0L;<=
br><br>=C2=A0 /// Constant: Euler&#39;</span><span style=3D"color: #000;" c=
lass=3D"styled-by-prettify">s number </span><span style=3D"color: #066;" cl=
ass=3D"styled-by-prettify">@f$</span><span style=3D"color: #000;" class=3D"=
styled-by-prettify"> e </span><span style=3D"color: #066;" class=3D"styled-=
by-prettify">@f$</span><span style=3D"color: #000;" class=3D"styled-by-pret=
tify"> </span><span style=3D"color: #660;" class=3D"styled-by-prettify">(</=
span><span style=3D"color: #000;" class=3D"styled-by-prettify">see POSIX </=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">@c</span><sp=
an style=3D"color: #000;" class=3D"styled-by-prettify"> M_E</span><span sty=
le=3D"color: #660;" class=3D"styled-by-prettify">).</span><span style=3D"co=
lor: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"c=
olor: #008;" class=3D"styled-by-prettify">template</span><span style=3D"col=
or: #660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"color: #0=
08;" class=3D"styled-by-prettify">typename</span><span style=3D"color: #000=
;" class=3D"styled-by-prettify"> _RealType</span><span style=3D"color: #660=
;" class=3D"styled-by-prettify">&gt;</span><span style=3D"color: #000;" cla=
ss=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #0=
08;" class=3D"styled-by-prettify">constexpr</span><span style=3D"color: #00=
0;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_e =C2=A0 =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 </span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">=3D</span><span style=3D"color: #000;" class=3D"sty=
led-by-prettify"> </span><span style=3D"color: #066;" class=3D"styled-by-pr=
ettify">2.7182</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;81828&#39;</span><span style=3D"color: #066;" class=3D"styled-by-p=
rettify">45904</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;52353&#39;</span><span style=3D"color: #066;" class=3D"styled-by-p=
rettify">60287</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;47135&#39;</span><span style=3D"color: #066;" class=3D"styled-by-p=
rettify">26624</span><span style=3D"color: #080;" class=3D"styled-by-pretti=
fy">&#39;97759e+0L;<br><br>=C2=A0 /// Constant: @f$ 1 / e @f$.<br>=C2=A0 te=
mplate&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=
=C2=A0 =C2=A0 m_1_e =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =3D 3.6787&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">94411</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;71442&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">32159</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;55237&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">70161</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;46086&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">74462e-1L</span=
><span style=3D"color: #660;" class=3D"styled-by-prettify">;</span><span st=
yle=3D"color: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span><sp=
an style=3D"color: #800;" class=3D"styled-by-prettify">/// Constant: @f$ \l=
og_2(e) @f$ (see POSIX @c M_LOG2E).</span><span style=3D"color: #000;" clas=
s=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"color: #008;" cla=
ss=3D"styled-by-prettify">template</span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">&lt;</span><span style=3D"color: #008;" class=3D"st=
yled-by-prettify">typename</span><span style=3D"color: #000;" class=3D"styl=
ed-by-prettify"> _RealType</span><span style=3D"color: #660;" class=3D"styl=
ed-by-prettify">&gt;</span><span style=3D"color: #000;" class=3D"styled-by-=
prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #008;" class=3D"st=
yled-by-prettify">constexpr</span><span style=3D"color: #000;" class=3D"sty=
led-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_log2_e =C2=A0 =C2=A0 =C2=A0 =
=C2=A0</span><span style=3D"color: #660;" class=3D"styled-by-prettify">=3D<=
/span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><sp=
an style=3D"color: #066;" class=3D"styled-by-prettify">1.4426</span><span s=
tyle=3D"color: #080;" class=3D"styled-by-prettify">&#39;95040&#39;</span><s=
pan style=3D"color: #066;" class=3D"styled-by-prettify">88896</span><span s=
tyle=3D"color: #080;" class=3D"styled-by-prettify">&#39;34073&#39;</span><s=
pan style=3D"color: #066;" class=3D"styled-by-prettify">59924</span><span s=
tyle=3D"color: #080;" class=3D"styled-by-prettify">&#39;68100&#39;</span><s=
pan style=3D"color: #066;" class=3D"styled-by-prettify">18921</span><span s=
tyle=3D"color: #080;" class=3D"styled-by-prettify">&#39;37427e+0L;<br><br>=
=C2=A0 /// Constant: @f$ \log_2(10) @f$.<br>=C2=A0 template&lt;typename _Re=
alType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0 m_log2_10 =
=C2=A0 =C2=A0 =C2=A0 =3D 3.3219&#39;</span><span style=3D"color: #066;" cla=
ss=3D"styled-by-prettify">28094</span><span style=3D"color: #080;" class=3D=
"styled-by-prettify">&#39;88736&#39;</span><span style=3D"color: #066;" cla=
ss=3D"styled-by-prettify">23478</span><span style=3D"color: #080;" class=3D=
"styled-by-prettify">&#39;70319&#39;</span><span style=3D"color: #066;" cla=
ss=3D"styled-by-prettify">42948</span><span style=3D"color: #080;" class=3D=
"styled-by-prettify">&#39;93901&#39;</span><span style=3D"color: #066;" cla=
ss=3D"styled-by-prettify">75867e+0L</span><span style=3D"color: #660;" clas=
s=3D"styled-by-prettify">;</span><span style=3D"color: #000;" class=3D"styl=
ed-by-prettify"><br><br>=C2=A0 </span><span style=3D"color: #800;" class=3D=
"styled-by-prettify">/// Constant: @f$ \log_10(2) @f$.</span><span style=3D=
"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=
=3D"color: #008;" class=3D"styled-by-prettify">template</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"co=
lor: #008;" class=3D"styled-by-prettify">typename</span><span style=3D"colo=
r: #000;" class=3D"styled-by-prettify"> _RealType</span><span style=3D"colo=
r: #660;" class=3D"styled-by-prettify">&gt;</span><span style=3D"color: #00=
0;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"co=
lor: #008;" class=3D"styled-by-prettify">constexpr</span><span style=3D"col=
or: #000;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_log10=
_2 =C2=A0 =C2=A0 =C2=A0 </span><span style=3D"color: #660;" class=3D"styled=
-by-prettify">=3D</span><span style=3D"color: #000;" class=3D"styled-by-pre=
ttify"> </span><span style=3D"color: #066;" class=3D"styled-by-prettify">3.=
0102</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;9=
9956&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">6=
3981</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;1=
9521&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">3=
7388</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;9=
4724&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">4=
9302</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;6=
7680e-1L;<br><br>=C2=A0 /// Constant: @f$ \log_10(e) @f$ (see POSIX @c M_LO=
G10E).<br>=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 conste=
xpr _RealType<br>=C2=A0 =C2=A0 m_log10_e =C2=A0 =C2=A0 =C2=A0 =3D 4.3429&#3=
9;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">44819</s=
pan><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;03251&#3=
9;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">82765</s=
pan><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;11289&#3=
9;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">18916</s=
pan><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;60508&#3=
9;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">22940e-1=
L</span><span style=3D"color: #660;" class=3D"styled-by-prettify">;</span><=
span style=3D"color: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </s=
pan><span style=3D"color: #800;" class=3D"styled-by-prettify">/// Constant:=
 @f$ \log_10(pi) @f$.</span><span style=3D"color: #000;" class=3D"styled-by=
-prettify"><br>=C2=A0 </span><span style=3D"color: #008;" class=3D"styled-b=
y-prettify">template</span><span style=3D"color: #660;" class=3D"styled-by-=
prettify">&lt;</span><span style=3D"color: #008;" class=3D"styled-by-pretti=
fy">typename</span><span style=3D"color: #000;" class=3D"styled-by-prettify=
"> _RealType</span><span style=3D"color: #660;" class=3D"styled-by-prettify=
">&gt;</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=
=C2=A0 =C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by-pretti=
fy">constexpr</span><span style=3D"color: #000;" class=3D"styled-by-prettif=
y"> _RealType<br>=C2=A0 =C2=A0 m_log10_pi =C2=A0 =C2=A0 =C2=A0</span><span =
style=3D"color: #660;" class=3D"styled-by-prettify">=3D</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color=
: #066;" class=3D"styled-by-prettify">4.9714</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;98726&#39;</span><span style=3D"colo=
r: #066;" class=3D"styled-by-prettify">94133</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;85435&#39;</span><span style=3D"colo=
r: #066;" class=3D"styled-by-prettify">12682</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;88290&#39;</span><span style=3D"colo=
r: #066;" class=3D"styled-by-prettify">89887</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;36507e-1L;<br><br>=C2=A0 /// Constan=
t: @f$ \ln(2) @f$ (see POSIX @c M_LN2).<br>=C2=A0 template&lt;typename _Rea=
lType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0 m_ln_2 =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0=3D 6.9314&#39;</span><span style=3D"color: =
#066;" class=3D"styled-by-prettify">71805</span><span style=3D"color: #080;=
" class=3D"styled-by-prettify">&#39;59945&#39;</span><span style=3D"color: =
#066;" class=3D"styled-by-prettify">30941</span><span style=3D"color: #080;=
" class=3D"styled-by-prettify">&#39;72321&#39;</span><span style=3D"color: =
#066;" class=3D"styled-by-prettify">21458</span><span style=3D"color: #080;=
" class=3D"styled-by-prettify">&#39;17656&#39;</span><span style=3D"color: =
#066;" class=3D"styled-by-prettify">80748e-1L</span><span style=3D"color: #=
660;" class=3D"styled-by-prettify">;</span><span style=3D"color: #000;" cla=
ss=3D"styled-by-prettify"><br><br>=C2=A0 </span><span style=3D"color: #800;=
" class=3D"styled-by-prettify">/// Constant: @f$ \ln(3) @f$.</span><span st=
yle=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span s=
tyle=3D"color: #008;" class=3D"styled-by-prettify">template</span><span sty=
le=3D"color: #660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"=
color: #008;" class=3D"styled-by-prettify">typename</span><span style=3D"co=
lor: #000;" class=3D"styled-by-prettify"> _RealType</span><span style=3D"co=
lor: #660;" class=3D"styled-by-prettify">&gt;</span><span style=3D"color: #=
000;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"=
color: #008;" class=3D"styled-by-prettify">constexpr</span><span style=3D"c=
olor: #000;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_ln_=
3 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0</span><span style=3D"color: #660;" cla=
ss=3D"styled-by-prettify">=3D</span><span style=3D"color: #000;" class=3D"s=
tyled-by-prettify"> </span><span style=3D"color: #066;" class=3D"styled-by-=
prettify">1.0986</span><span style=3D"color: #080;" class=3D"styled-by-pret=
tify">&#39;12288&#39;</span><span style=3D"color: #066;" class=3D"styled-by=
-prettify">66810</span><span style=3D"color: #080;" class=3D"styled-by-pret=
tify">&#39;96913&#39;</span><span style=3D"color: #066;" class=3D"styled-by=
-prettify">95245</span><span style=3D"color: #080;" class=3D"styled-by-pret=
tify">&#39;23692&#39;</span><span style=3D"color: #066;" class=3D"styled-by=
-prettify">25257</span><span style=3D"color: #080;" class=3D"styled-by-pret=
tify">&#39;04648e+0L;<br><br>=C2=A0 /// Constant: @f$ \ln(10)@f$ (see POSIX=
 @c M_LN10).<br>=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 =
constexpr _RealType<br>=C2=A0 =C2=A0 m_ln_10 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =
=3D 2.3025&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prett=
ify">85092</span><span style=3D"color: #080;" class=3D"styled-by-prettify">=
&#39;99404&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prett=
ify">56840</span><span style=3D"color: #080;" class=3D"styled-by-prettify">=
&#39;17991&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prett=
ify">45468</span><span style=3D"color: #080;" class=3D"styled-by-prettify">=
&#39;43642&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prett=
ify">07602e+0L</span><span style=3D"color: #660;" class=3D"styled-by-pretti=
fy">;</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br><=
br>=C2=A0 </span><span style=3D"color: #800;" class=3D"styled-by-prettify">=
/// Constant: Euler-Mascheroni @f$ \gamma_E @f$.</span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"colo=
r: #008;" class=3D"styled-by-prettify">template</span><span style=3D"color:=
 #660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"color: #008;=
" class=3D"styled-by-prettify">typename</span><span style=3D"color: #000;" =
class=3D"styled-by-prettify"> _RealType</span><span style=3D"color: #660;" =
class=3D"styled-by-prettify">&gt;</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #008=
;" class=3D"styled-by-prettify">constexpr</span><span style=3D"color: #000;=
" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_gamma_e =C2=A0=
 =C2=A0 =C2=A0 </span><span style=3D"color: #660;" class=3D"styled-by-prett=
ify">=3D</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> <=
/span><span style=3D"color: #066;" class=3D"styled-by-prettify">5.7721</spa=
n><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;56649&#39;=
</span><span style=3D"color: #066;" class=3D"styled-by-prettify">01532</spa=
n><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;86060&#39;=
</span><span style=3D"color: #066;" class=3D"styled-by-prettify">65120</spa=
n><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;90082&#39;=
</span><span style=3D"color: #066;" class=3D"styled-by-prettify">40243</spa=
n><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;10432e-1L;=
<br><br>=C2=A0 /// Constant: Golden Ratio @f$ \phi =3D (1 + \sqrt{5})/2 @f$=
..<br>=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _=
RealType<br>=C2=A0 =C2=A0 m_phi =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =3D 1.61=
80&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">339=
88</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;749=
89&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">484=
82</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;045=
86&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">834=
36</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;563=
81&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">177=
20e+0L</span><span style=3D"color: #660;" class=3D"styled-by-prettify">;</s=
pan><span style=3D"color: #000;" class=3D"styled-by-prettify"><br><br>=C2=
=A0 </span><span style=3D"color: #800;" class=3D"styled-by-prettify">/// Co=
nstant: @f$ \sqrt{2}@f$ (see POSIX @c M_SQRT2).</span><span style=3D"color:=
 #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"color=
: #008;" class=3D"styled-by-prettify">template</span><span style=3D"color: =
#660;" class=3D"styled-by-prettify">&lt;</span><span style=3D"color: #008;"=
 class=3D"styled-by-prettify">typename</span><span style=3D"color: #000;" c=
lass=3D"styled-by-prettify"> _RealType</span><span style=3D"color: #660;" c=
lass=3D"styled-by-prettify">&gt;</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #008=
;" class=3D"styled-by-prettify">constexpr</span><span style=3D"color: #000;=
" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_sqrt_2 =C2=A0 =
=C2=A0 =C2=A0 =C2=A0</span><span style=3D"color: #660;" class=3D"styled-by-=
prettify">=3D</span><span style=3D"color: #000;" class=3D"styled-by-prettif=
y"> </span><span style=3D"color: #066;" class=3D"styled-by-prettify">1.4142=
</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;13562=
&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">37309=
</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;50488=
&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">01688=
</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;72420=
&#39;</span><span style=3D"color: #066;" class=3D"styled-by-prettify">96980=
</span><span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;78569=
e+0L;<br><br>=C2=A0 /// Constant: @f$ \sqrt{3} @f$.<br>=C2=A0 template&lt;t=
ypename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0=
 m_sqrt_3 =C2=A0 =C2=A0 =C2=A0 =C2=A0=3D 1.7320&#39;</span><span style=3D"c=
olor: #066;" class=3D"styled-by-prettify">50807</span><span style=3D"color:=
 #080;" class=3D"styled-by-prettify">&#39;56887&#39;</span><span style=3D"c=
olor: #066;" class=3D"styled-by-prettify">72935</span><span style=3D"color:=
 #080;" class=3D"styled-by-prettify">&#39;27446&#39;</span><span style=3D"c=
olor: #066;" class=3D"styled-by-prettify">34150</span><span style=3D"color:=
 #080;" class=3D"styled-by-prettify">&#39;58723&#39;</span><span style=3D"c=
olor: #066;" class=3D"styled-by-prettify">66945e+0L</span><span style=3D"co=
lor: #660;" class=3D"styled-by-prettify">;</span><span style=3D"color: #000=
;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span><span style=3D"color:=
 #800;" class=3D"styled-by-prettify">/// Constant: @f$ \sqrt{5} @f$.</span>=
<span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 </span=
><span style=3D"color: #008;" class=3D"styled-by-prettify">template</span><=
span style=3D"color: #660;" class=3D"styled-by-prettify">&lt;</span><span s=
tyle=3D"color: #008;" class=3D"styled-by-prettify">typename</span><span sty=
le=3D"color: #000;" class=3D"styled-by-prettify"> _RealType</span><span sty=
le=3D"color: #660;" class=3D"styled-by-prettify">&gt;</span><span style=3D"=
color: #000;" class=3D"styled-by-prettify"><br>=C2=A0 =C2=A0 </span><span s=
tyle=3D"color: #008;" class=3D"styled-by-prettify">constexpr</span><span st=
yle=3D"color: #000;" class=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=
=A0 m_sqrt_5 =C2=A0 =C2=A0 =C2=A0 =C2=A0</span><span style=3D"color: #660;"=
 class=3D"styled-by-prettify">=3D</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"> </span><span style=3D"color: #066;" class=3D"style=
d-by-prettify">2.2360</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;67977&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">49978</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;96964&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">09173</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;66873&#39;</span><span style=3D"color: #066;" class=3D"styl=
ed-by-prettify">12762</span><span style=3D"color: #080;" class=3D"styled-by=
-prettify">&#39;35440e+0L;<br><br>=C2=A0 /// Constant: @f$ \sqrt{7} @f$.<br=
>=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =C2=A0 constexpr _Real=
Type<br>=C2=A0 =C2=A0 m_sqrt_7 =C2=A0 =C2=A0 =C2=A0 =C2=A0=3D 2.6457&#39;</=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">51311</span>=
<span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;06459&#39;</=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">05905</span>=
<span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;01615&#39;</=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">75363</span>=
<span style=3D"color: #080;" class=3D"styled-by-prettify">&#39;92604&#39;</=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">25706e+0L</s=
pan><span style=3D"color: #660;" class=3D"styled-by-prettify">;</span><span=
 style=3D"color: #000;" class=3D"styled-by-prettify"><br><br>=C2=A0 </span>=
<span style=3D"color: #800;" class=3D"styled-by-prettify">/// Constant: @f$=
 1 / \sqrt{2}@f$ (see POSIX @c M_SQRT1_2).</span><span style=3D"color: #000=
;" class=3D"styled-by-prettify"><br>=C2=A0 </span><span style=3D"color: #00=
8;" class=3D"styled-by-prettify">template</span><span style=3D"color: #660;=
" class=3D"styled-by-prettify">&lt;</span><span style=3D"color: #008;" clas=
s=3D"styled-by-prettify">typename</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"> _RealType</span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">&gt;</span><span style=3D"color: #000;" class=3D"st=
yled-by-prettify"><br>=C2=A0 =C2=A0 </span><span style=3D"color: #008;" cla=
ss=3D"styled-by-prettify">constexpr</span><span style=3D"color: #000;" clas=
s=3D"styled-by-prettify"> _RealType<br>=C2=A0 =C2=A0 m_1_sqrt_2 =C2=A0 =C2=
=A0 =C2=A0</span><span style=3D"color: #660;" class=3D"styled-by-prettify">=
=3D</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </span=
><span style=3D"color: #066;" class=3D"styled-by-prettify">7.0710</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;67811&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">86547</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;52440&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">08443</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;62104&#39;</spa=
n><span style=3D"color: #066;" class=3D"styled-by-prettify">84903</span><sp=
an style=3D"color: #080;" class=3D"styled-by-prettify">&#39;92845e-1L;<br><=
br>=C2=A0 /// Constant: Catalan&#39;</span><span style=3D"color: #000;" cla=
ss=3D"styled-by-prettify">s </span><span style=3D"color: #066;" class=3D"st=
yled-by-prettify">@f$</span><span style=3D"color: #000;" class=3D"styled-by=
-prettify"> G </span><span style=3D"color: #660;" class=3D"styled-by-pretti=
fy">=3D</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </=
span><span style=3D"color: #066;" class=3D"styled-by-prettify">1</span><spa=
n style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">-</span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color: #066;" =
class=3D"styled-by-prettify">1</span><span style=3D"color: #660;" class=3D"=
styled-by-prettify">/</span><span style=3D"color: #066;" class=3D"styled-by=
-prettify">9</span><span style=3D"color: #000;" class=3D"styled-by-prettify=
"> </span><span style=3D"color: #660;" class=3D"styled-by-prettify">+</span=
><span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span st=
yle=3D"color: #066;" class=3D"styled-by-prettify">1</span><span style=3D"co=
lor: #660;" class=3D"styled-by-prettify">/</span><span style=3D"color: #066=
;" class=3D"styled-by-prettify">25</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"> </span><span style=3D"color: #660;" class=3D"style=
d-by-prettify">-</span><span style=3D"color: #000;" class=3D"styled-by-pret=
tify"> </span><span style=3D"color: #066;" class=3D"styled-by-prettify">1</=
span><span style=3D"color: #660;" class=3D"styled-by-prettify">/</span><spa=
n style=3D"color: #066;" class=3D"styled-by-prettify">49</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color=
: #660;" class=3D"styled-by-prettify">+</span><span style=3D"color: #000;" =
class=3D"styled-by-prettify"> </span><span style=3D"color: #066;" class=3D"=
styled-by-prettify">1</span><span style=3D"color: #660;" class=3D"styled-by=
-prettify">/</span><span style=3D"color: #066;" class=3D"styled-by-prettify=
">81</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </spa=
n><span style=3D"color: #660;" class=3D"styled-by-prettify">-</span><span s=
tyle=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"c=
olor: #660;" class=3D"styled-by-prettify">...</span><span style=3D"color: #=
000;" class=3D"styled-by-prettify"> </span><span style=3D"color: #066;" cla=
ss=3D"styled-by-prettify">@f$</span><span style=3D"color: #660;" class=3D"s=
tyled-by-prettify">.</span><span style=3D"color: #000;" class=3D"styled-by-=
prettify"><br>=C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by=
-prettify">template</span><span style=3D"color: #660;" class=3D"styled-by-p=
rettify">&lt;</span><span style=3D"color: #008;" class=3D"styled-by-prettif=
y">typename</span><span style=3D"color: #000;" class=3D"styled-by-prettify"=
> _RealType</span><span style=3D"color: #660;" class=3D"styled-by-prettify"=
>&gt;</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>=
=C2=A0 =C2=A0 </span><span style=3D"color: #008;" class=3D"styled-by-pretti=
fy">constexpr</span><span style=3D"color: #000;" class=3D"styled-by-prettif=
y"> _RealType<br>=C2=A0 =C2=A0 m_catalan =C2=A0 =C2=A0 =C2=A0 </span><span =
style=3D"color: #660;" class=3D"styled-by-prettify">=3D</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color=
: #066;" class=3D"styled-by-prettify">9.1596</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;55941&#39;</span><span style=3D"colo=
r: #066;" class=3D"styled-by-prettify">77219</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;01505&#39;</span><span style=3D"colo=
r: #066;" class=3D"styled-by-prettify">46035</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;14932&#39;</span><span style=3D"colo=
r: #066;" class=3D"styled-by-prettify">38411</span><span style=3D"color: #0=
80;" class=3D"styled-by-prettify">&#39;07741e-1L;<br><br>=C2=A0 /// Constan=
t: @f$ \pi^2/6 @f$.<br>=C2=A0 template&lt;typename _RealType&gt;<br>=C2=A0 =
=C2=A0 constexpr _RealType<br>=C2=A0 =C2=A0 m_pi2_6 =C2=A0 =C2=A0 =C2=A0 =
=C2=A0 =3D 1.6449&#39;</span><span style=3D"color: #066;" class=3D"styled-b=
y-prettify">34066</span><span style=3D"color: #080;" class=3D"styled-by-pre=
ttify">&#39;84822&#39;</span><span style=3D"color: #066;" class=3D"styled-b=
y-prettify">64364</span><span style=3D"color: #080;" class=3D"styled-by-pre=
ttify">&#39;72415&#39;</span><span style=3D"color: #066;" class=3D"styled-b=
y-prettify">16664</span><span style=3D"color: #080;" class=3D"styled-by-pre=
ttify">&#39;60251&#39;</span><span style=3D"color: #066;" class=3D"styled-b=
y-prettify">89218e+0L</span><span style=3D"color: #660;" class=3D"styled-by=
-prettify">;</span><span style=3D"color: #000;" class=3D"styled-by-prettify=
"><br><br></span><span style=3D"color: #660;" class=3D"styled-by-prettify">=
}</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><=
span style=3D"color: #800;" class=3D"styled-by-prettify">// inline namespac=
e math_constants</span><span style=3D"color: #000;" class=3D"styled-by-pret=
tify"><br></span><span style=3D"color: #660;" class=3D"styled-by-prettify">=
}</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><=
span style=3D"color: #800;" class=3D"styled-by-prettify">// inline namespac=
e constants</span><span style=3D"color: #000;" class=3D"styled-by-prettify"=
><br></span><span style=3D"color: #660;" class=3D"styled-by-prettify">}</sp=
an><span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span =
style=3D"color: #800;" class=3D"styled-by-prettify">// inline namespace mat=
hs_v1</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br><=
/span><span style=3D"color: #660;" class=3D"styled-by-prettify">}</span><sp=
an style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=
=3D"color: #800;" class=3D"styled-by-prettify">// namespace experimental</s=
pan><span style=3D"color: #000;" class=3D"styled-by-prettify"><br></span><s=
pan style=3D"color: #660;" class=3D"styled-by-prettify">}</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color=
: #800;" class=3D"styled-by-prettify">// namespace std</span><span style=3D=
"color: #000;" class=3D"styled-by-prettify"><br><br></span><span style=3D"c=
olor: #800;" class=3D"styled-by-prettify">#endif</span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color: #800;" =
class=3D"styled-by-prettify">// C+</span><span style=3D"color: #800;" class=
=3D"styled-by-prettify">+14</span><span style=3D"color: #000;" class=3D"sty=
led-by-prettify"><br><br></span></div></code></div><br><br>----------------=
----------------------------------------------------------<br><br></div></d=
iv>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/6bccd7e5-82ad-4c59-9f72-f7fb6639c0ca%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/6bccd7e5-82ad-4c59-9f72-f7fb6639c0ca=
%40isocpp.org</a>.<br />

------=_Part_952_1398975516.1489099472971--

------=_Part_951_1972070828.1489099472968--

.
