Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
ramshorns
on March 30, 2022
|
parent
|
context
|
favorite
| on:
Implementing Cosine in C from Scratch (2020)
In that range, just returning x would be way better. Maybe even perfect actually - if x is less than 10^-16, then the error of x^3/6 is less than the machine precision for x.
adgjlsfhk1
on March 30, 2022
[–]
the error isn't when x is small. it's when sin(x) is small. the problem happens for x near multiples of pi
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: