Mail Archives: djgpp/1998/05/11/03:46:33
Hi!
Thank you for your work!
However, I believe that the coefficients are slightly inexact.
The correct values should be:
long double C[] = { 1.L,
1/6.L,
1/120.L,
1/5040.L,
1/362880.L,
1/39916800.L,
1/6227020800.L};
if they are derived from the series for sinhx(x):
sinh(x) = 1 + x^3/3! + x^5/5! + x^7/7! + ...
Besides, this approximation (that uses 7 coefficients) is only
accurate with 64bit (double) arithmetic.
With long doubles a 8th coefficient should be added:
C[7] = 1/1307674368000.L
Jens
---
| | | Jens Bischoff | Daimler-Benz Aerospace Airbus |
| --<O>-- +-----------------+---------------------------------+
| | | Aerodynamic Data Department (EFD) |
| Dasa Airbus | Huenefeldstrasse 1-5 D-28199 Bremen (Germany) |
- Raw text -