Reply to post: How Can This Be?

Intel 'underestimates error bounds by 1.3 QUINTILLION'

John Savard

How Can This Be?

With a function like the sine, a conventional implementation which is very accurate for values between plus and minus pi/2 (plus and minus 90 degrees) can still go wrong if you try to take the sine of a very big number.

While the sine of a big number still has a mathematically exact value, usually errors in that case don't matter, because floating-point numbers have limited precision, and usually their accuracy is not greater than their precision. So if you try to take the sine of 3.52 times 10 to the 52nd power, the entire range of the sine function can be produced by just changing stuff beyond the least significant bit.

Using a copy of pi to an enormous precision allows such cases to be taken care of accurately, but that's a waste of time for the normal purposes to which trig functions are put.

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon