* atan2 on an alpha
@ 1996-09-11 4:00 Isabeau's mom
0 siblings, 0 replies; only message in thread
From: Isabeau's mom @ 1996-09-11 4:00 UTC (permalink / raw)
hi, can anyone tell me why the following program -
#include <stdio.h>
#include <math.h>
int
main(void)
{
double ans, y = 0, x = 0;
ans = atan2(y,x);
(void)printf("atan2(%g,%g) = %g\n",y,x,ans);
return(0);
}
when built like
cc -fptm su -D_POSIX_SOURCE -lm aa.c
outputs
atan2(0,0) = 0
but when built like this
cc -fptm su -D_POSIX_SOURCE -migrate -lm aa.c
outputs
atan2(0,0) = NaNQ
i do know that x = y = 0 is listed as "invalid argument"
in the atan2 man pages.
thanks
eileen
--
It's a wonderful thing to be an afternoon
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1996-09-11 4:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-09-11 4:00 atan2 on an alpha Isabeau's mom
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox