POV-Ray : Newsgroups : povray.off-topic : Probability question : Re: Probability question Server Time
4 Sep 2024 17:18:21 EDT (-0400)
  Re: Probability question  
From: Invisible
Date: 10 Feb 2010 04:15:25
Message: <4b72792d@news.povray.org>
>>> Wouldn't that be increadibly unstable, numerically?
>>
>> How could it be?  If you're taking the limit of something that's going 
>> to a finite value in a continuous curve, how could your calculation of 
>> the value closer to the limit have more error than the error 
>> calculated farther from the limit?
> 
> According to Google calculator, sin(1e-14)/1e-14 = 1, but 
> sin(1e-15)/1e-15 = 0.

Indeed, this was going to be my example. When x is small, sin(x) is 
approximately equal to x. But whatever, sin(x)/x when x is small 
involves division by a tiny number - which is equivilant to 
multiplication by a huge number. It's numerically unstable.

(Of course, the limit of sin(x)/x as x approaches zero is just 1, which 
you don't need to "estimate" in the first place. But if you had a 
similar formula which approximates some irrational quantity...)


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.