Sascha Rissel on Thu, 30 Jun 2005 22:18:20 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: Sin(x) |
Thanks for all your quick help. I now do understand this slight difference to the expected values. But why do cheap pocket calculators calculate exact results of sin and cos? Their approximation of Pi shouldn't be more precise than that Pari provides. Do they round the results for reasons of "usability"? Regards, Sascha. Bill Allombert schrieb:
On Thu, Jun 30, 2005 at 06:33:11PM +0200, Sascha Rissel wrote:Hello, I have a qustion about the sin(x)-function.Why is cos(Pi) = -1 as it should be, but sin(Pi) = -5.04870979 E-29 and not exactly 0?Other values of sin(x) are also a bit "out of place"...cos(Pi) is not really -1: ? cos(Pi)+1 %3 = 1.2744735289059618216 E-57 The Pi function returns only an approximation of Pi to the current precision, so the result can only be accurate to that number of decimals. Cheers, Bill.