Dear Corinna,
> ...which is what I described in the rest of my mail :)
ah, yes, sorry. I stumbled on the "0x96c75d80 which appears to be perfectly
valid for a 32 bit int", fell on my nose and looks like I forgot to walk on
then.
Best regards,
Michael
Intel Deutschland GmbH
Registered Address:
On Apr 9 14:45, Soegtrop, Michael wrote:
> Dear Corinna,
>
> > L is of type Long == int32_t, aadj is of type double. The value of
> > aadj at this time is 2529648000.0 == 0x96c75d80 which appears to be
> > perfectly valid for a 32 bit int.
>
> 2529648000 is a valid unsigned long, but not a vali
Dear Corinna,
> L is of type Long == int32_t, aadj is of type double. The value of aadj at
> this time is 2529648000.0 == 0x96c75d80 which appears to be perfectly valid
> for a 32 bit int.
2529648000 is a valid unsigned long, but not a valid signed long. The largest
32 bit long is 2^31-1 = 21
On Apr 9 08:09, Ken Brown wrote:
> On 4/9/2018 5:47 AM, Corinna Vinschen wrote:
> > On Apr 7 13:40, Ken Brown wrote:
> > > $ cat strtod_test.c
> > > #include
> > > #include
> > > #include
> > >
> > > int
> > > main ()
> > > {
> > >/* The following number comes from /usr/share/asymptote/od
On 4/9/2018 5:47 AM, Corinna Vinschen wrote:
On Apr 7 13:40, Ken Brown wrote:
$ cat strtod_test.c
#include
#include
#include
int
main ()
{
/* The following number comes from /usr/share/asymptote/ode.asy. */
const char *str = "121645100408832000.0";
char *ptr;
feenableexcept (F
On Apr 7 13:40, Ken Brown wrote:
> $ cat strtod_test.c
> #include
> #include
> #include
>
> int
> main ()
> {
> /* The following number comes from /usr/share/asymptote/ode.asy. */
> const char *str = "121645100408832000.0";
> char *ptr;
>
> feenableexcept (FE_INVALID);
> strtod (st
> Probably doesn't fit precisely into a double. Does strtold behave
> better?
actually both numbers can be represented exactly as IEEE double. In Maxima:
(%i1) factor(121645100408832000);
(%o1) 2^16*3^8*5^3*7^2*11*13*17*19
(%i2) float(log(3^8*5^3*7^2*11*13*17*19)/log(2));
(%o2) 40.755455
Am 08.04.2018 um 05:11 schrieb Duncan Roe:
I tried in 64-bit with the same result as Eliot: works fine w/out
feenableexcept, no o/p with feenableexcept.
Just in case this may have been overlooked: please note that "no output"
actually means the program crashed because of an uncaught SIGFPE, j
On Sat, Apr 07, 2018 at 04:56:13PM -0400, Eliot Moss wrote:
> On 4/7/2018 1:40 PM, Ken Brown wrote:
> > $ cat strtod_test.c
> > #include
> > #include
> > #include
> >
> > int
> > main ()
> > {
> > /* The following number comes from /usr/share/asymptote/ode.asy. */
> > const char *str = "1
On 4/7/2018 1:40 PM, Ken Brown wrote:
$ cat strtod_test.c
#include
#include
#include
int
main ()
{
/* The following number comes from /usr/share/asymptote/ode.asy. */
const char *str = "121645100408832000.0";
char *ptr;
feenableexcept (FE_INVALID);
strtod (str, &ptr);
/*
Is that 19! ? Probably doesn't fit precisely into a double. Does strtold
behave better?
Some implementations throw on unrepresentable numbers, e.g.
https://docs.oracle.com/cd/E19253-01/816-5168/6mbb3hrte/index.html
Ken Brown schrieb am Sa., 7. Apr. 2018, 10:40:
> $ cat strtod_test.c
> #includ
$ cat strtod_test.c
#include
#include
#include
int
main ()
{
/* The following number comes from /usr/share/asymptote/ode.asy. */
const char *str = "121645100408832000.0";
char *ptr;
feenableexcept (FE_INVALID);
strtod (str, &ptr);
/* If there was an exception, the following will
12 matches
Mail list logo