Post Reply 
New guy and programming problem
09-02-2018, 06:14 PM (This post was last modified: 09-02-2018 06:40 PM by Albert Chan.)
Post: #34
RE: New guy and programming problem
Third way to calculate accurate 1 - sin(x), is to remove sine function, replaced with cosine.
We can then pick whatever double angle formula is suitable:

cos(2x) = cos(x)² - sin(x)² = 2 cos(x)² - 1 = 1 - 2 sin(x)²

1 - sin(89.9995°)
= 1 - cos(0.0005°)
= 1 - (1 - 2 sin(0.00025°)²)
= 2 sin(0.00025°)²
= 3.807717747e-11

Note: above same as Klemm difference-to-product formula (post 27), but probably easier to remember.

BTW, you can build multiple angles cosine formula with cosines ... Neat

cos(n x) = 2 cos(x) cos((n-1) x) - cos((n-2) x)
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: New guy and programming problem - Albert Chan - 09-02-2018 06:14 PM
RE: New guy and programming problem - sasa - 09-01-2018, 03:18 PM
RE: New guy and programming problem - sasa - 09-01-2018, 05:33 PM



User(s) browsing this thread: