Long-float variant giving more precision to numerical computations.
Subject: Long-float variant giving more precision to numerical computations.
From: Douglas Crosher
Date: Fri, 15 Feb 2008 22:58:13 +1100
Raymond Toy wrote:
...
> Also, I don't think we should convert the slatec routines to use
> long-float. The constants there are only accurate to double-float
> because that's all that was used when they were generated (even if the
> original source has way more digits---an artifact of f2cl). I think the
> slatec routines should be compiled as normal double-float routines, and
> the maxima interface to them should convert to/from flonum to
> double-float as appropriate.
The slatec Fortran source comments suggests it is precise enough for
double-double float. The code can be re-translated, maintaining the
constant precision, using the following hack patch.
F2cl hack patch to target Fortran double precision to long-float or
double-double-float:
http://www.scieneer.com/files/f2cl-patch1.txt.gz
Add the following compiler-options in slatec.system and rebuild:
:double-precision-format kernel:double-double-float
:float-format kernel:double-double-float
Could be a quick path if it works out.
Regards
Douglas Crosher