Improper tan and atan on Solaris

From: Andreas Hoeschler (ahoesch@smartsoft.de)
Date: Wed Jun 02 2004 - 10:06:35 EDT


Hi,

>> on Solaris the tan() and atan() functions do not seem to work
>> properly.
>> The same code built on MacOSX produces proper results. On Solaris
>> these
>> functions return wrong values. Anybody seen this and knows hot to fix
>> that? I am using the gcc 3.x from sunfreeware.com.
>
> What does "improper" mean in this context?
>
> (Inputs, outputs?)

Oh sorry. Here is what I get:

> 2004-06-02 15:58:29.294 RasterServiceFillMerc[24022] aa 1.252687
> 2004-06-02 15:58:29.306 RasterServiceFillMerc[24022] tan (aa)
> 1072958209.000000

> 2004-06-02 15:58:29.318 RasterServiceFillMerc[24022] aa
> 1072957976.967294
> 2004-06-02 15:58:29.318 RasterServiceFillMerc[24022] atan (aa) =
> 1104148997.000000

MacOSx and my pocket calculator come to identical values, Solaris has a
different understanding of these functions. Any ideas?

I could work around the tan() problem by using sin(aa) / cos(aa)
instead instead of tan(aa). However, I don't know of a replacement for
atan() and I don't have my Bronstein handy right now. Any ideas?

Thanks!

Regards,

   Andreas
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 23:28:46 EDT