Laguerre cosine approximation<*** End of File ***>
Math history fun fact
I came across this some 50 years ago,
before calculators had trig keys.It's good to about 4 significant digits for first quadrant,
and exact at 0, 45, 60, 90 degrees.m = angle/90 for degrees or angle/pi/2 for radians
-m^2
( --------------------------------- - 1)
sqrt((-m^3 + 4m^2 -5m + 2)/3) + mThis can be expressed in linear form as:
-(((((((4-m)m-5)m+2)/3)^(1/2)+m)^(-1)mm)-1)
which can be keyed in directly on a simple chain-logic memory
calculator with a square root key and the ability to find the
reciprocal using some combination of / and = keys. Handle the
leading minus at the end, just mentally if necessary.To test it, on a 12C, for angles in degrees:
90 / ENTER ENTER ENTER
4 x<>y - X 5 - X 2 + 3 / g-sqrt + 1/x X X 1 - CHS
OT: Cosine curio
|
12-11-2011, 05:17 PM
12-11-2011, 09:23 PM
It seems like the final 1 should be positive, not negative.
12-12-2011, 06:49 PM
Interesting approximation! Can we enhance it now that we have tools like Matlab and Excel? Crawl it right in pointing out that the trailing -1 in the first two equations should be +1. Namir
12-13-2011, 05:45 AM
Really interesting approximation. As Namir and Crawl have already point out, there is a typo in the developed formulae only.
The linear formulea and the RPN instructions are all correct. Using my HP-41C, I just test a few points to observe error between cosine and the Laguerre approximation (express in the following table as ppm
Angle(°) m=a/90° Laguerre(m) Cos(a) Error(ppm) As explain, in first quadrant, few error and exact value for same remarkable values are obtained. No more approximation can be obtained after 180° due to the sign of the polynôme under the square root. The following figure better illustrate accuracy and region of interest for this cosine approximation: Note that in this graph, Lag(a) is the real part of the laguerre approximation. That’s why plot continue after the 180° limit. As Namir point it out, we can enhance this approximation, but not only in accuracy, other way may be to make it usable on a larger domain.
Edited: 13 Dec 2011, 5:58 a.m. |
« Next Oldest | Next Newest »
|
Possibly Related Threads… | |||||
Thread | Author | Replies | Views | Last Post | |
Cosine for fun | Chuck | 6 | 1,859 |
12-04-2009, 07:39 PM Last Post: Chuck |
|
HP 35s and Cosine of large numbers | Chuck | 6 | 1,802 |
01-15-2009, 01:52 AM Last Post: Hal Bitton in Boise |
|
The HP 20b RPN Arcus Cosine Bug | Marcus von Cube, Germany | 1 | 747 |
09-17-2008, 09:21 AM Last Post: cyrille de Brebisson |