Re: Best processors for trig?
- From: Paul Keinanen <keinanen@xxxxxx>
- Date: Sat, 31 Mar 2007 20:25:06 +0300
On Sat, 31 Mar 2007 16:05:28 GMT, Tauno Voipio
<tauno.voipio@xxxxxxxxxxxxx> wrote:
Paul Keinanen wrote:
The most difficult of the elementary functions
is the logarithm, its Taylor series uses half of an
infinity to converge.
After all, the only real problem with logs is that you must be able to
calculate it in the 1.0 .. 2.0 range, the rest is trivial.
Do you really need anything more than a 6th degree polynomial ?
Yes - I do.
The MacLaurin series for a log (calculated for log(1 + x))
needs 5000 terms for 4 digits. Pick your favourite formula
collection and have a look.
In the 1970's I disassembled the PDP-11 FORTRAN run time library to
check out how it was implemented. I did not find any functions that
would have required more than the 4th degree for single precission and
8th degree for double precission.
Later analysis of VAX-11 FORTRAN revelee that even 3rd (6th degree for
double) was used.
I had to split the range to (1 .. sqrt(2)) and (sqrt(2) .. 2),
and calculate 5th degree Chebysev series approximations to
get enough precision for single-precision float.
That range is far too wide. I would split the 1.0 to 2.0 range to 4-16
segments with appropriate coefficients.
Paul
.
- References:
- Best processors for trig?
- From: Mike Noone
- Re: Best processors for trig?
- From: Tim Wescott
- Re: Best processors for trig?
- From: larwe
- Re: Best processors for trig?
- From: Tauno Voipio
- Re: Best processors for trig?
- From: Paul Keinanen
- Re: Best processors for trig?
- From: Tauno Voipio
- Best processors for trig?
- Prev by Date: Re: shame on MISRA
- Next by Date: Re: shame on MISRA
- Previous by thread: Re: Best processors for trig?
- Next by thread: Re: Best processors for trig?
- Index(es):