(12C) Bhaskara's Sine and Cosine Approximations
|
02-26-2022, 06:22 PM
(This post was last modified: 02-28-2022 06:29 AM by Thomas Klemm.)
Post: #1
|
|||
|
|||
(12C) Bhaskara's Sine and Cosine Approximations
Bhaskara's Sine and Cosine Approximations
References
Formulas \(\sin(x) \approx \frac{16(\pi - x)x}{5 \pi^2 - 4(\pi - x)x}\) \(\cos(x) \approx \frac{\pi^2 - 4x^2}{\pi^2 + x^2}\) We can use the substitution \(\pi \to 180^{\circ}\) and get instead for \(x\) in degrees: \(\sin(x) \approx \frac{4(30 - \frac{x}{6})\frac{x}{6}}{1125 - (30 - \frac{x}{6})\frac{x}{6}}\) \(\cos(x) \approx \frac{9 - 4[\frac{x}{60}]^2}{9 + [\frac{x}{60}]^2}\) Python Programs Code: def sin(x): Code: def cos(x): Program There's a jump table at the beginning, so you can use the following: GTO 01 for \(\sin(x)\) GTO 02 for \(\cos(x)\) Code: 01- 43 33 19 g GTO 19 Examples Sine What is \(\sin(36^{\circ})\)? GTO 01 36 R/S 0.587 Cosine What is \(\cos(36^{\circ})\)? GTO 02 36 R/S 0.808 Accuracy For special values (e.g. 30, 60, 90, …) the approximation is exact. But in general it's only correct to about 3 places. In the last column is the correct value. Sine 0: 0.000 0.000 10: 0.175 0.174 20: 0.343 0.342 30: 0.500 0.500 40: 0.642 0.643 50: 0.765 0.766 60: 0.865 0.866 70: 0.939 0.940 80: 0.985 0.985 90: 1.000 1.000 100: 0.985 0.985 110: 0.939 0.940 120: 0.865 0.866 130: 0.765 0.766 140: 0.642 0.643 150: 0.500 0.500 160: 0.343 0.342 170: 0.175 0.174 180: 0.000 0.000 Cosine -90: 0.000 0.000 -80: 0.175 0.174 -70: 0.343 0.342 -60: 0.500 0.500 -50: 0.642 0.643 -40: 0.765 0.766 -30: 0.865 0.866 -20: 0.939 0.940 -10: 0.985 0.985 0: 1.000 1.000 10: 0.985 0.985 20: 0.939 0.940 30: 0.865 0.866 40: 0.765 0.766 50: 0.642 0.643 60: 0.500 0.500 70: 0.343 0.342 80: 0.175 0.174 90: 0.000 0.000 |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
(12C) Bhaskara's Sine and Cosine Approximations - Thomas Klemm - 02-26-2022 06:22 PM
RE: (12C) Bhaskara's Sine and Cosine Approximations - Thomas Klemm - 07-29-2022, 12:13 PM
RE: (12C) Bhaskara's Sine and Cosine Approximations - Albert Chan - 07-29-2022, 05:13 PM
RE: (12C) Bhaskara's Sine and Cosine Approximations - Thomas Klemm - 07-30-2022, 10:51 AM
|
User(s) browsing this thread: 1 Guest(s)