From: Thorsten Ohl <ohl@hep.tu-darmstadt.de>
To: caml-list@inria.fr
Subject: [Caml-list] YAFPFR: Yet another floating point feature request
Date: Mon, 8 Oct 2001 18:21:55 +0200 [thread overview]
Message-ID: <200110081621.f98GLt931245@heplix4.ikp.physik.tu-darmstadt.de> (raw)
The C library header file <float.h> contains (among others) the
following useful macros:
/* Number of decimal digits of precision in a double */
#define DBL_DIG 15
/* Difference between 1.0 and the minimum double greater than 1.0 */
#define DBL_EPSILON 2.2204460492503131e-16
/* Minimum normalised double */
#define DBL_MIN 2.2250738585072014e-308
/* Minimum int x such that 10**x is a normalised double */
#define DBL_MIN_10_EXP (-307)
/* Maximum double */
#define DBL_MAX 1.7976931348623157e+308
/* Maximum int x such that 10**x is a representable double */
#define DBL_MAX_10_EXP 308
It would be great if these values were accessible from O'Caml in a
future version so that numerical code could be made to work on
different machines.
Merci,
-Thorsten
--
Thorsten Ohl, Physics Department, TU Darmstadt -- ohl@hep.tu-darmstadt.de
http://heplix.ikp.physik.tu-darmstadt.de/~ohl/ [<=== PGP public key here]
-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
next reply other threads:[~2001-10-08 16:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-10-08 16:21 Thorsten Ohl [this message]
[not found] <200110081621.f98GLt931245@heplix4.ikp.physik.tu-darmstadt. de>
2001-10-09 21:11 ` Chris Hecker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200110081621.f98GLt931245@heplix4.ikp.physik.tu-darmstadt.de \
--to=ohl@hep.tu-darmstadt.de \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox