|
Boost : |
From: Paul A. Bristow (boost_at_[hidden])
Date: 2002-10-10 09:08:40
Thanks for this valuable info - I had not understood either the problem or the
solution!
But as the document is actually created in MS Word and it is troublesome to edit
the long source, I have simply Zipped the html file and uploaded it anew as
http://groups.yahoo.com/group/boost/files/MathConstants/Math_constants%20interva
ls.zip
I trust unzipping this is not too inconvenient.
This should now contain the updated math constants with intervals documentation
which includes intervals containing the constants which I propose to calculate
using a high precision package NTL.
For example, for pi, the EXACTLY REPRESENTABLE values for radix == 2
and significand digits = 24, 53 and 64 are:
static const float pi_f_l = 3.141592502593994140625F;
static const float pi_f_u = 3.1415927410125732421875F;
static const double pi_d_l2 =
3.141592653589793115997963468544185161590576171875;
static const double pi_d_u2 =
3.141592653589793560087173318606801331043243408203125;
static const long double pi_l_l =
3.141592653589793238295968524909085317631252110004425048828125L;
static const long double pi_l_u =
3.14159265358979323851280895940618620443274267017841339111328125L;
These float values are the same as calculated by
Sylvian Pion for the interval library using
static const float pi_f_l = 13176794.0f/(1<<22); // assuming 24 - 2 significand
bits.
but can be made to work generally.
Presentation to users will probably be via a template as proposed by Sylvian
Pion.
(However I have cooled on support of non-IEEE Floating-point and radix != 2. It
complicates the already complex code to produce these constants and I am
uncertain that they will ever be used).
Comments welcome.
Paul
Dr Paul A Bristow, hetp Chromatography
Prizet Farmhouse, Kendal, Cumbria, LA8 8AB UK
+44 1539 561830 Mobile +44 7714 33 02 04
mailto:pbristow_at_[hidden]
> -----Original Message-----
> From: boost-bounces_at_[hidden]
> [mailto:boost-bounces_at_[hidden]]On Behalf Of Herve Bronnimann
> Sent: Thursday, October 10, 2002 3:51 AM
> To: Boost mailing list
> Subject: Re: [boost] Re: math constants, including their intervals
>
>
> On Fri, Oct 04, 2002 at 10:02:29AM +0100, Ken Hagan wrote:
> > There's an error in the HTML, rather than your browser, so problems
> > ought to show up in everyone's browser. Presumably the file got garbled
> > when Paul uploaded it, or maybe when we downloaded it.
>
> FWIW, I recall having the same problem when I uploaded the docs of the
> Interval library. The problem was diagnosed as having links <A
> HREF="..."> on several lines (just like I did): when uploading the
> corresponding tag </A> would be removed, and run until the next <A> tag.
>
> The fix was simple: manually edit the HTML source to make sure this
> didn't happen. A pain, but some editors (Mozilla-based, in my case) just
> don't care to write <A HREF=".."> on a single line. The browsers don't
> have this problem. It's definitely a bug in the upload method, so files
> distributed by other means (zip, cvs, etc) don't suffer from the bug.
>
> My 2 cents,
> --
> Herve'
>
>
> _______________________________________________
> Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
>
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk