Re: My Homework: how to calculate natural log, e?
- From: "e p chandler" <epc8@xxxxxxxx>
- Date: 5 Oct 2005 10:11:52 -0700
Mr Hrundi V Bakshi wrote:
[snip]
[program listing]
> >
> > fulfils the 1ulp criterion and is implementable in hardware. Naive Taylor
> > expansion doesn't rate in either software or hardware other than a dumb
> > ox's exercise.
>
> For clf opd's types, replace as appropriate:
>
> real(8), allocatable :: Y(:,:)
>
> write(*,*) 'Naturally, exp(',x,') = ', exp(xkeep), Y(kmax,0)
>
[snip]
So why am I seeing this output?
C:\gfortran>gfortran hvb.f95
C:\gfortran>a
x?
2.3025850929940456840179914546844
Naturally, exp( 2.30258509299405 ) = 10.0000000000000
9.99999967773798
x?
This is with the latest gfortran - MinGW. An explicit FORMAT makes no
real difference. I've also varied X slightly. This does not change the
output from the algorithm posted. How much accuracy should I expect?
(Or should I read Goldberg's paper again???)
-- Elliot
.
- Follow-Ups:
- Re: My Homework: how to calculate natural log, e?
- From: Mr Hrundi V Bakshi
- Re: My Homework: how to calculate natural log, e?
- From: Rich Townsend
- Re: My Homework: how to calculate natural log, e?
- References:
- Re: My Homework: how to calculate natural log, e?
- From: Mr Hrundi V Bakshi
- Re: My Homework: how to calculate natural log, e?
- From: Steven G. Kargl
- Re: My Homework: how to calculate natural log, e?
- From: Mr Hrundi V Bakshi
- Re: My Homework: how to calculate natural log, e?
- From: Mr Hrundi V Bakshi
- Re: My Homework: how to calculate natural log, e?
- Prev by Date: Re: What am I doing wrong? Passing pointers to subroutines.
- Next by Date: Re: My Homework: how to calculate natural log, e?
- Previous by thread: Re: My Homework: how to calculate natural log, e?
- Next by thread: Re: My Homework: how to calculate natural log, e?
- Index(es):
Relevant Pages
|