This is the mail archive of the
newlib@sources.redhat.com
mailing list for the newlib project.
Re: Error of tan/tanf in libm.
- To: Tim Prince <tprince at computer dot org>
- Subject: Re: Error of tan/tanf in libm.
- From: Stephen L Moshier <moshier at mediaone dot net>
- Date: Sat, 14 Apr 2001 22:37:56 -0400 (EDT)
- cc: newlib at sources dot redhat dot com
- Reply-To: moshier at moshier dot ne dot mediaone dot net
> The only libm functions in newlib which I've found to be substandard
> are acosf() / asinf().
newlib-1.9 has at least two versions: newlib/libm/math/ef_asin.c,
newlib/libm/mathfp/sf_asine.c. Are you referring to one of these?
sf_asine.c seems to have about 2 ulps relative error, ef_asin.c
has 3 ulps.
The main problem with ef_asin.c is that the values
of pio2_hi, pio2_lo, pio4_hi are chosen incorrectly for IEEE
(strictly rounded) arithmetic. If someone would like a patch
to fix ef_asin.c, I can give you one written for the file e_asinf.c in
glibc which I think is the same code. The fix yields less than 1 ulp
relative error.