Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 13 Aug 2012 14:41:59 -0500
From:      Stephen Montgomery-Smith <stephen@missouri.edu>
To:        Bruce Evans <brde@optusnet.com.au>
Cc:        freebsd-numerics@FreeBSD.org
Subject:   Re: Complex arg-trig functions
Message-ID:  <50295887.2010608@missouri.edu>
In-Reply-To: <20120814003614.H3692@besplex.bde.org>
References:  <5017111E.6060003@missouri.edu> <501C361D.4010807@missouri.edu> <20120804165555.X1231@besplex.bde.org> <501D51D7.1020101@missouri.edu> <20120805030609.R3101@besplex.bde.org> <501D9C36.2040207@missouri.edu> <20120805175106.X3574@besplex.bde.org> <501EC015.3000808@missouri.edu> <20120805191954.GA50379@troutmask.apl.washington.edu> <20120807205725.GA10572@server.rulingia.com> <20120809025220.N4114@besplex.bde.org> <5027F07E.9060409@missouri.edu> <20120814003614.H3692@besplex.bde.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 08/13/2012 11:57 AM, Bruce Evans wrote:

> I finally tested a version of this.  I only did simple comparisons (float
> vs double and double vs long double).  The results look promising after
> fixing a few bugs:

Thank you very much for doing the testing, and for fixing the bugs.

>
> % amd64 float prec, on 2**12 * 2**12 args:

> % icacosh:max_er = 0x3690000000 436.5000, avg_er = 0.317, #>=1:0.5 =
> 29104:255732

> There are negative reasons to have the float versions unless they are not
> wrappers.  The reasons to have non-wrappers are to test the algorithm and
> run faster.

That large max-err for the imaginary part of icacosh for float bothers 
me.  It means that I haven't thought it through properly.  Could you 
send me the input values that created this error(s)?

The float versions really are much harder than the double and 
long-double versions.  And it just doesn't seem worth the effort, 
because who uses them when the double versions are available?

In my case, not for speed.  Because on my machine the float versions are 
slightly slower than the double version.



Also, you made the comment that in the float version, all the 0.5 should 
become 0.5F.  Two questions:
1.  Doesn't the compiler do this conversion for me?
2.  What is wrong with using x/2 instead of 0.5*x?  You told me in a far 
earlier email to use 0.5*x.  (Similarly in one place I have a 0.25.)




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?50295887.2010608>