From: Eleanor McHugh Date: 2009-11-16T11:22:47+09:00 Subject: Re: Trajectories On 16 Nov 2009, at 01:12, Todd Benson wrote: > On Sun, Nov 15, 2009 at 5:32 PM, Eleanor McHugh >> The physical limitations imposed on arbitrary-precision decimal >> computation >> by binary representation are something you should know *before* >> arguing that >> one representation is better than another. > > I think Marnen originally was suggesting that the imprecisions will > stack, like an arrow at a target going more and more off course during > its flight, of course depending on the application. For some apps, > it's totally reasonable to see something go chaotic because of these > things. This isn't an issue of chaotic behaviour (that has a very fixed meaning mathematically) but of unnoticeable error. The difference between 1e10-13 and 2e10-13 matters a lot when working on a system which needs to be accurate to a resolution of 1e10-14 but not when working to a resolution of 1e10-4. The additional nine decimal places tell us nothing meaningful in this latter case as we'll still end up rounding the result to zero. > For a short and unimportant game I'm playing, I wouldn't be upset. > But, for a game that takes 10's of hours and have it ride my butt > later at a crucial moment, I might just call that a bug. That's not a bug but a fundamental outcome of the nature of binary coded non-integral numbers. Many rational non-integral numbers cannot be expressed accurately in binary representations, whilst binary coded decimal brings a whole host of other problems: lower information density, higher memory usage, and heavier processing load. BCD also does nothing to resolve the problem of how to represent irrational numbers such as π. > Does the imprecision in the calculation stack in ballistic calcs? A > virtual magic bullet as it were? I'm not sure, but I'm guessing it > doesn't to great effect. The imprecision can indeed stack for complex ballistics systems, depending on the complexity of the forces involved. However to the extent of the precision chosen for performing these calculations the resultant inaccuracy is irrelevant. http://en.wikipedia.org/wiki/Accuracy_and_precision explains all of this in reasonable detail. Ellie Eleanor McHugh Games With Brains http://slides.games-with-brains.net ---- raise ArgumentError unless @reality.responds_to? :reason